/* "A viagem" — the journey landing. Light by default (a Brazilian morning
   that turns into a German day as you scroll); ?tema=noite for the night
   flight. The body background is set by the script, frame by frame. */
:root {
  --ink: #12213F;
  --muted: #45506B;
  --green: #009C3B;
  --yellow: #F2B705;
  --blue: #002776;
  --coral: #E4572E;
  --card: rgba(255,255,255,.9);
  --glass: rgba(255,255,255,.62);
  --line: rgba(18,33,63,.08);
  --cta-ink: #FFFFFF;
}
html.noite {
  --ink: #F6F1E7;
  --muted: #B8C2DA;
  --green: #19C35A;
  --yellow: #FFD21F;
  --card: rgba(12,26,58,.86);
  --glass: rgba(8,20,48,.6);
  --line: rgba(255,255,255,.1);
  --cta-ink: #06301F;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: #FFF3C4; color: var(--ink);
  font-family: "Atkinson Hyperlegible Next", "Atkinson Hyperlegible", system-ui, -apple-system, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}
html.noite body { background: #06301F; }
#stage { position: fixed; inset: 0; width: 100vw; height: 100vh; display: block; z-index: 0; }
#labels { position: fixed; inset: 0; z-index: 1; pointer-events: none; }
main { position: relative; z-index: 2; }

/* City names and the words on the route, placed by the script. */
#labels span { position: absolute; left: 0; top: 0; transition: opacity .5s ease; white-space: nowrap; will-change: transform; }
#labels .city { font-size: 13px; font-weight: 700; color: var(--ink); margin: -24px 0 0 8px; text-shadow: 0 0 6px rgba(255,255,255,.9); }
html.noite #labels .city { text-shadow: 0 0 6px rgba(0,0,0,.8); }
#labels .word {
  margin: -46px 0 0 -40px; padding: 6px 12px; border-radius: 14px;
  background: var(--card); box-shadow: 0 8px 24px rgba(18,33,63,.12);
  display: flex; gap: 8px; align-items: baseline; font-size: 15px;
}
#labels .word i { font-style: normal; color: var(--muted); }
#labels .word b { color: var(--green); font-size: 18px; }

/* ── Top bar with the route ──────────────────────────────── */
.bar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 5;
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 24px;
  padding: 12px 6vw; background: var(--glass);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.brand { color: var(--ink); text-decoration: none; font-weight: 800; font-size: 19px; }
.brand span { color: var(--green); }
.bar-cta { color: var(--cta-ink); background: var(--green); font-weight: 800; font-size: 15px; text-decoration: none; padding: 10px 16px; border-radius: 22px; }
.route { display: flex; align-items: center; gap: 10px; max-width: 420px; width: 100%; justify-self: center; }
.route .end { font-size: 12px; font-weight: 800; letter-spacing: .08em; padding: 3px 7px; border-radius: 8px; }
.route .br { background: var(--green); color: #FFE680; }
.route .de { background: #1D1B3A; color: #FFCE00; }
.track { position: relative; flex: 1; height: 2px; background-image: linear-gradient(90deg, var(--muted) 50%, transparent 0); background-size: 8px 2px; opacity: .9; }
.plane-icon { position: absolute; top: 50%; left: 0; transform: translate(-50%, -50%) rotate(90deg); color: var(--blue); transition: left .15s linear; display: grid; }
html.noite .plane-icon { color: var(--yellow); }

/* ── Sections ────────────────────────────────────────────── */
.panel {
  min-height: 100vh; padding: 18vh 6vw 12vh;
  display: flex; flex-direction: column; justify-content: center; gap: 18px;
  max-width: 640px;
}
.sheet {
  padding: 16vh 6vw; display: flex; flex-direction: column; gap: 22px;
}
.glass { background: var(--glass); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.chap > * { opacity: 0; transform: translateY(24px); transition: opacity .8s ease, transform .8s cubic-bezier(.2,.8,.2,1); }
.chap.on > * { opacity: 1; transform: none; }
.chap.on > *:nth-child(2) { transition-delay: .08s; }
.chap.on > *:nth-child(3) { transition-delay: .16s; }
.chap.on > *:nth-child(4) { transition-delay: .24s; }

.kicker { margin: 0; font-size: 15px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--green); display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.kicker .arrow { color: var(--yellow); }
.flag { width: 22px; height: 15px; border-radius: 3px; display: inline-block; }
/* Plain flag-colour chips, not the flags: green-yellow-blue and black-red-gold. */
.flag.br { background: radial-gradient(circle at 50% 50%, var(--blue) 0 3px, transparent 3.5px), linear-gradient(135deg, transparent 30%, #FFDF00 30% 70%, transparent 70%), #009C3B; }
.flag.de { background: linear-gradient(#000 33%, #DD0000 33% 66%, #FFCE00 66%); }
h1 { margin: 0; font-size: clamp(36px, 4.2vw, 60px); line-height: 1.03; letter-spacing: -0.025em; font-weight: 800; }
h1 em { font-style: normal; color: var(--green); background: linear-gradient(transparent 62%, rgba(242,183,5,.45) 62%); }
h2 { margin: 0; font-size: clamp(32px, 4.2vw, 56px); line-height: 1.08; letter-spacing: -0.015em; font-weight: 800; }
h3 { margin: 0; font-size: 21px; line-height: 1.25; font-weight: 800; }
p { margin: 0; font-size: clamp(18px, 1.6vw, 21px); line-height: 1.55; color: var(--muted); }
.lead { color: var(--ink); font-size: clamp(20px, 2vw, 25px); }
.small { font-size: 16px; }
sup { font-size: .65em; color: var(--coral); font-weight: 700; }

.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 18px; margin-top: 8px; }
.cta {
  display: inline-flex; align-items: center; min-height: 60px; padding: 0 30px; border-radius: 30px;
  background: var(--green); color: var(--cta-ink); text-decoration: none; font-size: 19px; font-weight: 800;
  box-shadow: 0 10px 30px rgba(0,156,59,.3), inset 0 -4px 0 rgba(0,0,0,.12);
}
.cta:hover { filter: brightness(1.06); }
.cta:focus-visible, .bar-cta:focus-visible { outline: 3px solid var(--yellow); outline-offset: 4px; }
.hint { font-size: 15px; color: var(--muted); line-height: 1.4; }

.pairs { display: flex; flex-wrap: wrap; gap: 10px; }
.pairs span { background: var(--card); border-radius: 16px; padding: 10px 14px; display: flex; gap: 10px; align-items: baseline; box-shadow: 0 6px 18px rgba(18,33,63,.07); }
.pairs i { font-style: normal; color: var(--muted); font-size: 16px; }
.pairs b { color: var(--green); font-size: 20px; }

.card { margin: 6px 0 0; background: var(--card); border-radius: 22px; padding: 20px 22px; box-shadow: 0 10px 30px rgba(18,33,63,.08); }
.phrase { display: flex; flex-direction: column; gap: 6px; }
.phrase .de { font-size: clamp(24px, 2.4vw, 32px); font-weight: 800; color: var(--ink); }
.phrase .pt { font-size: 18px; color: var(--muted); }
.phrase .tip { margin-top: 8px; font-size: 16px; color: var(--ink); background: rgba(242,183,5,.22); border-radius: 12px; padding: 8px 12px; }
.list { display: grid; gap: 12px; }
.list div { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 16px; border-bottom: 1px solid var(--line); padding-bottom: 10px; }
.list div:last-child { border: 0; padding: 0; }
.list dt { font-weight: 800; font-size: 20px; color: var(--ink); }
.list dd { margin: 0; color: var(--muted); font-size: 17px; }

.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; margin-top: 10px; }
.stat { background: var(--card); border-radius: 26px; padding: 26px; display: flex; flex-direction: column; gap: 10px; box-shadow: 0 10px 30px rgba(18,33,63,.07); }
.stat .big { font-size: clamp(40px, 4.4vw, 60px); font-weight: 800; letter-spacing: -0.02em; color: var(--green); line-height: 1; }
.stat:nth-child(2) .big { color: var(--blue); }
html.noite .stat:nth-child(2) .big { color: var(--yellow); }
.stat:nth-child(3) .big { color: var(--coral); }
.stat p { font-size: 17px; }

.steps { list-style: none; padding: 0; margin: 10px 0 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.steps li { background: var(--card); border-radius: 24px; padding: 24px; display: flex; flex-direction: column; gap: 10px; box-shadow: 0 10px 30px rgba(18,33,63,.07); }
.steps .n { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--green); color: #fff; font-weight: 800; }
.steps li:nth-child(3) .n, .steps li:nth-child(4) .n { background: #1D1B3A; color: #FFCE00; }
.steps p { font-size: 17px; }
.note { max-width: 820px; font-size: 18px; background: var(--card); border-left: 4px solid var(--yellow); border-radius: 0 16px 16px 0; padding: 16px 20px; color: var(--ink); }

.faq { display: grid; gap: 12px; max-width: 860px; }
.faq details { background: var(--card); border-radius: 18px; padding: 18px 22px; box-shadow: 0 6px 20px rgba(18,33,63,.06); }
.faq summary { cursor: pointer; font-weight: 800; font-size: 19px; color: var(--ink); list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--green); font-size: 24px; line-height: 1; }
.faq details[open] summary::after { content: "–"; }
.faq details p { margin-top: 10px; font-size: 17px; }

.final { max-width: 720px; }
.hero { max-width: 760px; }
.sources { padding: 32px 6vw 48px; background: var(--glass); }
.sources p { font-size: 13px; line-height: 1.6; max-width: 980px; }
.sources a { color: var(--muted); }

@media (max-width: 960px) {
  .stats { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr 1fr; }
}
/* Phone: the globe owns the top half; the words read below it. */
@media (max-width: 760px) {
  .bar { grid-template-columns: auto auto; padding: 10px 18px; row-gap: 8px; }
  .route { grid-column: 1 / -1; grid-row: 2; max-width: none; }
  .bar-cta { font-size: 13px; padding: 8px 12px; justify-self: end; }
  .panel { padding: 50vh 22px 10vh; justify-content: flex-start; }
  .hero { padding-top: 48vh; }
  .sheet { padding: 10vh 22px; }
  .steps { grid-template-columns: 1fr; }
  #labels .word { font-size: 13px; padding: 4px 9px; }
  #labels .word b { font-size: 15px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .chap > * { opacity: 1; transform: none; transition: none; }
  .plane-icon { transition: none; }
}
