:root {
  --night: #120b16;
  --deep: #1c1022;
  --purple: #6d3b82;
  --purple-light: #b579d2;
  --lilac: #d9a8ff;
  --gold: #d7aa60;
  --cream: #f3e7c8;
  --muted: #c9b9cf;
  --ink: #24142c;
  --danger: #e09494;
  --radius: 20px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 20% 5%, rgba(109, 59, 130, .3), transparent 28rem),
    radial-gradient(circle at 90% 55%, rgba(181, 121, 210, .12), transparent 34rem),
    linear-gradient(145deg, var(--night), #201126 58%, #130b17);
  color: var(--cream);
  font-family: "Montserrat", Arial, sans-serif;
}

button, input { font: inherit; }
button, label.file-button { -webkit-tap-highlight-color: transparent; }

.ambient {
  position: fixed;
  border: 1px solid rgba(217, 168, 255, .11);
  transform: rotate(45deg);
  pointer-events: none;
  z-index: -1;
}
.ambient-one { width: 260px; height: 260px; top: 13%; left: -180px; }
.ambient-two { width: 400px; height: 400px; right: -310px; bottom: 4%; }

.site-header {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  min-height: 84px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(243, 231, 200, .12);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--cream);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 700;
  font-size: 1.45rem;
  text-decoration: none;
}
.brand-gem { color: var(--lilac); filter: drop-shadow(0 0 8px rgba(217,168,255,.8)); }
.location { color: var(--muted); font-size: .75rem; letter-spacing: .16em; text-transform: uppercase; }

main { width: min(1120px, calc(100% - 40px)); margin: 0 auto; }
.screen { display: none; min-height: calc(100vh - 170px); padding: 70px 0; }
.screen.active { display: block; animation: appear .35s ease both; }
.screen.centered.active { display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
@keyframes appear { from { opacity: 0; transform: translateY(8px); } }

#screen-landing.active {
  display: grid;
  grid-template-columns: 1fr .9fr;
  gap: 64px;
  align-items: center;
}

.eyebrow, .step-label {
  display: inline-block;
  color: var(--gold);
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .17em;
  text-transform: uppercase;
}

h1, h2, h3 { font-family: "Cormorant Garamond", Georgia, serif; }
h1 { margin: 14px 0 18px; font-size: clamp(3.4rem, 7.2vw, 6.7rem); line-height: .82; letter-spacing: -.045em; }
h1 em { color: var(--lilac); font-weight: 500; }
h2 { margin: 8px 0 8px; font-size: clamp(2.3rem, 5vw, 3.5rem); line-height: .95; }
h3 { margin: 5px 0 10px; font-size: 1.85rem; }
.lead { max-width: 610px; color: var(--muted); line-height: 1.75; font-size: 1.04rem; }

.offer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 520px;
  margin: 26px 0 16px;
  padding: 18px 20px;
  border: 1px solid rgba(217,168,255,.24);
  border-radius: 14px;
  background: rgba(255,255,255,.035);
}
.offer span { color: var(--gold); font-size: 1.2rem; }

.button {
  border: 0;
  border-radius: 12px;
  padding: 15px 22px;
  cursor: pointer;
  font-weight: 700;
  text-decoration: none;
  text-align: center;
  transition: transform .15s ease, filter .15s ease, border-color .15s ease;
}
.button:hover { transform: translateY(-1px); filter: brightness(1.08); }
.button:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.button.primary { color: #1b0f21; background: linear-gradient(135deg, #e0b8fa, #a85fca); box-shadow: 0 12px 28px rgba(109,59,130,.3); }
.button.secondary { color: var(--cream); background: rgba(255,255,255,.045); border: 1px solid rgba(217,168,255,.35); }
.button.text { color: var(--muted); background: transparent; }
.button.text.danger { color: var(--danger); display: block; margin: 25px auto 0; }
.button.wide { width: min(100%, 520px); }
.microcopy { color: #9c899f; font-size: .73rem; max-width: 520px; text-align: center; }

.sample-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 13px;
  perspective: 1000px;
}
.sample-card {
  position: relative;
  min-height: 230px;
  overflow: hidden;
  border: 1px solid rgba(217,168,255,.24);
  border-radius: 18px;
  box-shadow: 0 22px 50px rgba(0,0,0,.28);
  isolation: isolate;
}
.sample-card::before,
.sample-card::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
}
.sample-card::before {
  background-position: center;
  background-size: cover;
  transform: scale(1.01);
}
.sample-card::after {
  background: linear-gradient(to top, rgba(10,5,12,.94), rgba(10,5,12,.05) 62%);
}
.sample-card:nth-child(even) { transform: translateY(28px); }
.sample-senior::before { background-image: url('/sample-casal-idoso.webp'); }
.sample-couple::before { background-image: url('/sample-casal-maduro.webp'); }
.sample-family::before { background-image: url('/sample-familia.webp'); }
.sample-vintage::before { background-image: url('/sample-retrato-vintage.webp'); }
.sample-young-couple::before { background-image: url('/sample-casal-jovem.webp'); }
.sample-young-family::before { background-image: url('/sample-familia-jovem.webp'); }
.sample-friends::before { background-image: url('/sample-amigos.webp'); }
.sample-card span {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 13px;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 700;
  line-height: .9;
  font-size: 1.22rem;
}
.sample-disclaimer { grid-column: 1 / -1; margin-top: 23px; color: #9c899f; text-align: center; font-size: .68rem; }

.style-showcase { grid-column: 1 / -1; margin-top: 70px; text-align: center; }
.style-showcase > p { max-width: 680px; margin: 0 auto 28px; color: var(--muted); line-height: 1.65; }
.showcase-grid, .style-options { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.showcase-card, .style-option {
  position: relative;
  min-height: 280px;
  overflow: hidden;
  border: 1px solid rgba(217,168,255,.25);
  border-radius: 16px;
  background-position: center;
  background-size: cover;
  box-shadow: 0 18px 40px rgba(0,0,0,.24);
}
.showcase-card::after, .style-option::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(9,4,11,.96), transparent 68%); }
.showcase-card span, .style-option span { position: absolute; z-index: 2; left: 14px; right: 14px; bottom: 15px; font: 700 1.2rem/1 "Cormorant Garamond", Georgia, serif; color: var(--cream); }
.theme-garimpeiro { background-image: url('/sample-retrato-vintage.webp'); }
.theme-tesouro { background-image: url('/sample-familia-jovem.webp'); }
.theme-postal { background-image: url('/sample-casal-maduro.webp'); }
.theme-lenda { background-image: url('/sample-casal-idoso.webp'); }
.theme-guardiao { background-image: url('/sample-aventureira.webp'); }
.theme-vintage { background-image: url('/sample-familia.webp'); }
.theme-realeza { background-image: url('/sample-casal-jovem.webp'); }
.theme-encontrei { background-image: url('/sample-amigos.webp'); }

.how-it-works { grid-column: 1 / -1; text-align: center; margin-top: 45px; }
.how-it-works h2 { font-size: 2rem; }
.steps { display: flex; justify-content: center; gap: 70px; margin-top: 22px; }
.steps div { display: flex; align-items: center; gap: 11px; color: var(--muted); font-size: .88rem; }
.steps b { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; color: var(--lilac); border: 1px solid rgba(217,168,255,.35); }

.panel-heading { max-width: 680px; margin: 0 auto 35px; text-align: center; }
.panel-heading p { color: var(--muted); line-height: 1.6; }
.mode-picker { display: flex; justify-content: center; gap: 10px; margin-bottom: 28px; }
.mode { padding: 13px 18px; color: var(--muted); border: 1px solid rgba(217,168,255,.24); border-radius: 999px; background: rgba(255,255,255,.03); cursor: pointer; }
.mode.selected { color: var(--cream); border-color: var(--purple-light); background: rgba(109,59,130,.35); }

.plan-picker { width: min(100%, 760px); margin: 0 auto 30px; display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.plan { position: relative; min-height: 124px; padding: 20px; display: flex; flex-direction: column; align-items: flex-start; gap: 7px; color: var(--cream); background: rgba(255,255,255,.035); border: 1px solid rgba(217,168,255,.23); border-radius: 16px; cursor: pointer; text-align: left; }
.plan strong { color: var(--gold); font-size: 1.5rem; }
.plan small { color: var(--muted); }
.plan i { position: absolute; top: -10px; right: 12px; padding: 5px 9px; border-radius: 999px; color: var(--ink); background: var(--gold); font-size: .62rem; font-style: normal; font-weight: 800; letter-spacing: .08em; }
.plan.selected { border-color: var(--lilac); background: rgba(109,59,130,.28); box-shadow: 0 0 0 2px rgba(217,168,255,.12); }
.style-options { width: min(100%, 980px); margin: 0 auto; }
.style-option { min-height: 310px; padding: 0; cursor: pointer; filter: saturate(.72) brightness(.76); transition: filter .2s ease, transform .2s ease, border-color .2s ease; }
.style-option:hover { filter: saturate(.95) brightness(.9); transform: translateY(-2px); }
.style-option i { position: absolute; z-index: 3; top: 11px; right: 11px; padding: 6px 9px; border-radius: 999px; color: var(--cream); background: rgba(12,6,15,.8); font-size: .67rem; font-style: normal; font-weight: 700; }
.style-option.selected { filter: none; border-color: var(--lilac); box-shadow: 0 0 0 3px rgba(217,168,255,.22), 0 18px 40px rgba(0,0,0,.3); }
.style-option.selected i { color: var(--ink); background: var(--lilac); }
.style-option.locked { cursor: default; }
.selection-bar { position: sticky; z-index: 5; bottom: 16px; width: min(100%, 760px); margin: 28px auto 0; padding: 13px 14px 13px 20px; display: flex; align-items: center; justify-content: space-between; gap: 20px; border: 1px solid rgba(217,168,255,.3); border-radius: 16px; background: rgba(24,13,29,.94); box-shadow: 0 18px 50px rgba(0,0,0,.42); backdrop-filter: blur(14px); }
.selection-bar span { color: var(--muted); font-size: .85rem; }
.back-photo { display: block; margin: 16px auto 0; }
.payment-assurance { display: grid; gap: 9px; margin: 16px 0 22px; color: var(--muted); font-size: .82rem; }
.payment-assurance span::first-letter { color: var(--lilac); }

.photo-actions, .row { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; }
.file-button input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.camera-box, .selected-photo, .portrait-frame {
  width: min(100%, 560px);
  margin: 0 auto 22px;
  overflow: hidden;
  border: 1px solid rgba(217,168,255,.4);
  border-radius: var(--radius);
  background: #050306;
  box-shadow: 0 22px 55px rgba(0,0,0,.35);
}
.camera-box { position: relative; aspect-ratio: 4 / 3; }
.camera-box video { width: 100%; height: 100%; object-fit: cover; transform: scaleX(-1); }
.camera-guide { position: absolute; inset: 9%; border: 1px dashed rgba(243,231,200,.65); border-radius: 48% 48% 40% 40%; pointer-events: none; }
#btn-capture { display: block; margin: 0 auto 22px; }
.selected-photo img, .portrait-frame img { width: 100%; display: block; max-height: 650px; object-fit: contain; }
.portrait-frame { padding: 9px; background: var(--cream); transform: rotate(-.35deg); }

.consent {
  width: min(100%, 680px);
  margin: 22px auto;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  color: var(--muted);
  font-size: .8rem;
  line-height: 1.55;
}
.consent input { width: 19px; height: 19px; accent-color: var(--purple-light); flex: 0 0 auto; }
.consent a { color: var(--lilac); }

.unlock-card, .payment-value {
  width: min(100%, 560px);
  margin: 0 auto 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.unlock-card { padding: 18px 20px; background: rgba(255,255,255,.04); border: 1px solid rgba(217,168,255,.2); border-radius: 14px; }
.unlock-card div { display: flex; flex-direction: column; gap: 4px; }
.unlock-card span { color: var(--muted); font-size: .78rem; }
.unlock-card > b { color: var(--gold); font-size: 1.25rem; }
#screen-preview > .button { display: block; margin: 12px auto; }

.payment-card, .delivery-card, .upsell {
  width: min(100%, 620px);
  margin: 0 auto 24px;
  padding: 24px;
  border: 1px solid rgba(217,168,255,.22);
  border-radius: var(--radius);
  background: rgba(255,255,255,.045);
}
.payment-value { width: 100%; border-bottom: 1px solid rgba(243,231,200,.12); padding-bottom: 18px; }
.payment-value strong { color: var(--gold); font-size: 1.6rem; }
.qr { width: min(280px, 100%); margin: 22px auto; padding: 12px; background: white; border-radius: 13px; }
.qr img { width: 100%; display: block; }
.qr.small { width: 170px; margin: 0; flex: 0 0 auto; }
.waiting { text-align: center; color: var(--muted); font-size: .8rem; }
.waiting i { display: inline-block; width: 8px; height: 8px; margin-right: 8px; border-radius: 50%; background: var(--gold); animation: blink 1s infinite; }
@keyframes blink { 50% { opacity: .25; } }
.test-note { color: var(--gold); text-align: center; line-height: 1.5; }
#screen-payment > .button { display: block; margin: 0 auto; }

.crystal-loader { color: var(--lilac); font-size: 4rem; animation: crystal 1.2s ease-in-out infinite; filter: drop-shadow(0 0 18px rgba(217,168,255,.9)); }
@keyframes crystal { 50% { transform: scale(1.18) rotate(45deg); opacity: .55; } }
.centered p { max-width: 520px; color: var(--muted); }

.results-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin: 0 auto 28px; }
.result { background: var(--cream); color: var(--ink); padding: 7px; border-radius: 12px; }
.result img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; display: block; border-radius: 8px; }
.result a { display: block; padding: 10px 4px 4px; color: var(--purple); font-weight: 700; font-size: .78rem; text-decoration: none; }
.delivery-card { display: flex; align-items: center; gap: 25px; }
.delivery-card p { color: var(--muted); font-size: .83rem; }
.delivery-card .button { display: inline-block; padding: 12px 16px; }
.upsell { text-align: center; background: linear-gradient(145deg, rgba(109,59,130,.26), rgba(255,255,255,.035)); }
.upsell > span { color: var(--gold); font-size: .72rem; text-transform: uppercase; letter-spacing: .14em; }
.upsell p { color: var(--muted); line-height: 1.55; font-size: .86rem; }

.error-icon { width: 66px; height: 66px; display: grid; place-items: center; border: 1px solid var(--danger); color: var(--danger); border-radius: 50%; font: 700 2rem Georgia,serif; }
#screen-error .button { margin: 6px; }

footer {
  width: min(1120px, calc(100% - 40px));
  min-height: 86px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 20px;
  border-top: 1px solid rgba(243,231,200,.12);
  color: #9c899f;
  font-size: .72rem;
}
footer a { color: var(--muted); }
footer small { margin-left: auto; }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px); padding: 12px 18px; border-radius: 10px; background: var(--cream); color: var(--ink); font-size: .82rem; opacity: 0; pointer-events: none; transition: .2s; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.hidden { display: none !important; }

.legal { max-width: 760px; padding: 70px 0; }
.legal h1 { font-size: clamp(3rem,7vw,5rem); line-height: .9; }
.legal h2 { margin-top: 32px; font-size: 2rem; }
.legal p { color: var(--muted); line-height: 1.75; }
.legal .button { display: inline-block; margin-top: 24px; }

@media (max-width: 800px) {
  .site-header { min-height: 70px; }
  .location { display: none; }
  .screen { padding: 44px 0; }
  #screen-landing.active { grid-template-columns: 1fr; gap: 38px; }
  h1 { font-size: clamp(3.7rem, 17vw, 5.5rem); }
  .hero-copy { text-align: center; }
  .lead, .offer { margin-left: auto; margin-right: auto; }
  .sample-grid { width: min(100%, 560px); margin: 0 auto; }
  .sample-card { min-height: 205px; }
  .steps { gap: 16px; justify-content: space-between; }
  .steps div { flex-direction: column; flex: 1; gap: 7px; }
  .mode-picker { display: grid; grid-template-columns: 1fr 1fr; }
  .mode:last-child { grid-column: 1 / -1; }
  .results-grid { grid-template-columns: 1fr 1fr; }
  .showcase-grid, .style-options { grid-template-columns: repeat(2, 1fr); }
  .style-showcase { margin-top: 42px; }
}

@media (max-width: 520px) {
  main, footer { width: min(100% - 28px, 1120px); }
  .site-header { width: min(100% - 28px, 1180px); }
  .brand { font-size: 1.25rem; }
  .sample-card { min-height: 175px; }
  .showcase-card, .style-option { min-height: 225px; }
  .plan-picker { grid-template-columns: 1fr; }
  .selection-bar { align-items: stretch; flex-direction: column; text-align: center; }
  .selection-bar .button { width: 100%; }
  .photo-actions .button, .row .button { width: 100%; }
  .delivery-card { flex-direction: column; text-align: center; }
  .qr.small { width: 190px; }
  footer { flex-wrap: wrap; justify-content: center; padding: 22px 0; }
  footer small { width: 100%; margin: 0; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; scroll-behavior: auto !important; }
}
