/* Atlas & Reel. Editorial travel magazine meets modern studio.
   Shape rule: buttons are pills, cards are 28px shells with 22px cores, fields are 14px.
   One accent (terracotta). One theme per visitor: light by default, dark follows the system. */

@font-face {
  font-family: "Display";
  src: url("/fonts/display.woff2") format("woff2");
  font-weight: 200 800;
  font-display: swap;
}
@font-face {
  font-family: "Body";
  src: url("/fonts/body.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}
/* Metric-matched fallbacks so the swap does not shift the layout. */
@font-face {
  font-family: "Display Fallback";
  src: local("Arial");
  size-adjust: 97%;
  ascent-override: 93%;
  descent-override: 25%;
  line-gap-override: 0%;
}
@font-face {
  font-family: "Body Fallback";
  src: local("Arial");
  size-adjust: 101%;
  ascent-override: 92%;
  descent-override: 24%;
  line-gap-override: 0%;
}

:root {
  --bg: #eef0ea;
  --bg-2: #e3e8e0;
  --ink: #13211f;
  --muted: #475754;
  --line: rgba(19, 33, 31, 0.14);
  --shell: rgba(19, 33, 31, 0.055);
  --shell-ring: rgba(19, 33, 31, 0.1);
  --accent: #c2410c;
  --accent-ink: #ffffff;
  --deep: #12302c;
  --deep-ink: #eaf1ed;
  --deep-muted: #a9c0b9;
  --field: #ffffff;
  --field-line: #6a7a76;
  --glass: rgba(238, 240, 234, 0.78);
  --shadow: 0 24px 60px -28px rgba(19, 48, 44, 0.45);

  --f-display: "Display", "Display Fallback", Arial, sans-serif;
  --f-body: "Body", "Body Fallback", Arial, sans-serif;
  --ease: cubic-bezier(0.32, 0.72, 0, 1);
  --gutter: clamp(20px, 4vw, 48px);
  --wrap: 1240px;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0d1615;
    --bg-2: #132120;
    --ink: #eceee8;
    --muted: #a8b6b2;
    --line: rgba(236, 238, 232, 0.16);
    --shell: rgba(236, 238, 232, 0.06);
    --shell-ring: rgba(236, 238, 232, 0.12);
    --accent: #ff8a5c;
    --accent-ink: #1b0b04;
    --deep: #183832;
    --deep-ink: #eaf1ed;
    --deep-muted: #a9c0b9;
    --field: #0a1211;
    --field-line: #8a9b96;
    --glass: rgba(13, 22, 21, 0.72);
    --shadow: 0 24px 60px -28px rgba(0, 0, 0, 0.7);
  }
}

*,
*::before,
*::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 88px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 1.0625rem/1.6 var(--f-body);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, picture { display: block; max-width: 100%; }
h1, h2, h3, p { margin: 0; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 6px; }
[data-hidden] { display: none !important; }

.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: 999px; text-decoration: none; }
.skip:focus { top: 12px; }
.wrap { width: min(var(--wrap), 100% - 2 * var(--gutter)); margin-inline: auto; }
.ic { width: 1.25em; height: 1.25em; fill: currentColor; flex: none; }

h1, h2, h3, .wordmark { font-family: var(--f-display); font-weight: 700; letter-spacing: -0.035em; }
h1 { font-size: clamp(2.4rem, 0.9rem + 3.6vw, 3.9rem); line-height: 1.04; text-wrap: balance; }
h2 { font-size: clamp(2rem, 1.2rem + 2.6vw, 3.4rem); line-height: 1.06; text-wrap: balance; }
h3 { font-size: 1.35rem; line-height: 1.2; letter-spacing: -0.02em; }
.lead { font-size: clamp(1.1rem, 1rem + 0.5vw, 1.3rem); line-height: 1.5; color: var(--muted); max-width: 36ch; }
.muted { color: var(--muted); }
section { padding-block: clamp(88px, 11vw, 168px); }

/* ---------- buttons ---------- */
.btn {
  --pad: 8px;
  display: inline-flex; align-items: center; gap: 14px;
  padding: var(--pad) var(--pad) var(--pad) 26px;
  min-height: 52px;
  border-radius: 999px; border: 0; cursor: pointer;
  background: var(--accent); color: var(--accent-ink);
  font: 600 1rem/1.2 var(--f-body); text-decoration: none; white-space: nowrap;
  transition: transform 0.6s var(--ease), box-shadow 0.6s var(--ease);
  box-shadow: 0 14px 30px -16px var(--accent);
}
.btn .go {
  display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%;
  background: rgba(255, 255, 255, 0.22);
  transition: transform 0.6s var(--ease);
}
@media (prefers-color-scheme: dark) { .btn .go { background: rgba(27, 11, 4, 0.16); } }
.btn:hover .go { transform: translate(3px, -2px) scale(1.06); }
.btn:active { transform: scale(0.98); }
.btn[disabled] { opacity: 0.7; cursor: progress; }
.link { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; text-decoration: none; padding: 12px 4px; border-bottom: 1px solid var(--line); transition: border-color 0.4s var(--ease); }
.link:hover { border-color: var(--ink); }

/* ---------- nav ---------- */
.nav {
  position: fixed; z-index: 40; top: 14px; left: 50%; transform: translateX(-50%);
  width: min(960px, 100% - 24px);
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 7px 7px 7px 22px;
  border-radius: 999px; background: var(--glass);
  -webkit-backdrop-filter: blur(18px) saturate(140%); backdrop-filter: blur(18px) saturate(140%);
  box-shadow: inset 0 0 0 1px var(--shell-ring), var(--shadow);
}
.wordmark { font-size: 1.3rem; text-decoration: none; white-space: nowrap; }
.wordmark i { font-style: normal; color: var(--accent); }
.nav ul { display: none; list-style: none; margin: 0 auto 0 12px; padding: 0; gap: 4px; }
.nav ul a { display: block; padding: 10px 14px; border-radius: 999px; text-decoration: none; font-size: 0.95rem; color: var(--muted); transition: color 0.3s var(--ease), background 0.3s var(--ease); }
.nav ul a:hover { color: var(--ink); background: var(--shell); }
.nav .btn { --pad: 5px; min-height: 44px; font-size: 0.9rem; gap: 10px; padding-left: 18px; }
.nav .btn .go { width: 34px; height: 34px; }
.nav .long { display: none; }
.btn .lbl { display: inline; }
@media (min-width: 900px) {
  .nav ul { display: flex; }
  .nav .long { display: inline; }
}

@media (max-width: 599px) {
  .btn { white-space: normal; text-align: left; max-width: 100%; }
  .actions .btn { width: 100%; justify-content: space-between; }
  .nav { padding-left: 18px; }
  .nav .btn { padding: 0 16px; font-size: 0.85rem; }
  .nav .btn .go { display: none; }
}

/* ---------- hero ---------- */
.hero { min-height: 100dvh; padding-block: 104px 56px; display: grid; align-items: center; }
.hero .wrap { display: grid; gap: 48px; align-items: center; }
.hero h1 { max-width: 16ch; }
.hero .lead { margin-top: 22px; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 28px; margin-top: 34px; }
.hero-media { position: relative; justify-self: center; width: min(100%, 440px); }
.hero-small { display: none; }
@media (min-width: 900px) {
  .hero .wrap { grid-template-columns: 1.3fr 0.7fr; gap: clamp(32px, 5vw, 80px); }
  .hero h1 { max-width: none; }
  .hero-media { width: min(100%, 470px, calc(74dvh * 0.8)); justify-self: end; aspect-ratio: 4 / 5; }
  .hero-media > .shell:first-child, .hero-media > .shell:first-child picture, .hero-media > .shell:first-child img { height: 100%; }
  .hero-small { display: block; position: absolute; left: -34%; bottom: -30px; width: 52%; transform: rotate(-3deg); z-index: 1; box-shadow: var(--shadow); border-radius: 28px; }
}

/* ---------- double bezel image shell ---------- */
.shell { padding: 6px; border-radius: 28px; background: var(--shell); box-shadow: inset 0 0 0 1px var(--shell-ring); }
.shell > .core, .shell > picture, .shell > .core > picture { display: block; }
.core { border-radius: 22px; overflow: hidden; background: var(--bg-2); }
.shell img { width: 100%; height: 100%; object-fit: cover; border-radius: 22px; background: var(--bg-2); }
.hero-small.shell { background: var(--bg); }

/* ---------- problem ---------- */
.problem .wrap { display: grid; gap: 48px; }
.problem h2 span { display: inline-block; }
.problem h2 + .lead { margin-top: 20px; }
.pains { list-style: none; margin: 0; padding: 0; }
.pains li { padding: 30px 0 34px; border-top: 1px solid var(--line); }
.pains li:last-child { padding-bottom: 0; }
.pains h3 { margin-bottom: 10px; }
.pains p { color: var(--muted); max-width: 52ch; }
@media (min-width: 900px) {
  .problem .wrap { grid-template-columns: 1fr 1fr; gap: clamp(48px, 8vw, 120px); align-items: start; }
  .problem .intro { position: sticky; top: 120px; }
  .pains li:first-child { padding-top: 0; border-top: 0; }
}

/* ---------- build / bento ---------- */
.build { background: var(--bg-2); }
.build .head { max-width: 40rem; margin-bottom: clamp(40px, 6vw, 72px); }
.build .head .lead { margin-top: 20px; max-width: 46ch; }
.bento { display: grid; gap: 16px; }
.card { display: flex; flex-direction: column; }
.card .core { flex: 1; display: flex; flex-direction: column; }
.card .pic { padding: 0; }
.card .pic img { aspect-ratio: 16 / 10; height: auto; border-radius: 22px 22px 0 0; }
.card.guide .pic img { aspect-ratio: 4 / 3; }
.card .body { padding: 26px 26px 30px; display: flex; flex-direction: column; gap: 12px; }
.card p { color: var(--muted); max-width: 44ch; }
.badge { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%; background: var(--shell); box-shadow: inset 0 0 0 1px var(--shell-ring); font-size: 1.25rem; }
.card .core.site, .card .core.guide { background: var(--bg); }
.card .core.book { background: var(--accent); color: var(--accent-ink); }
.card .core.book p { color: inherit; opacity: 0.92; }
.card .core.book .badge { background: rgba(255, 255, 255, 0.2); box-shadow: none; }
@media (prefers-color-scheme: dark) { .card .core.book .badge { background: rgba(27, 11, 4, 0.14); } }
.card .core.studio { background: var(--deep); color: var(--deep-ink); }
.card .core.studio p { color: var(--deep-muted); }
.card .core.studio .badge { background: rgba(234, 241, 237, 0.1); box-shadow: inset 0 0 0 1px rgba(234, 241, 237, 0.18); }
.card .core.book .body, .card .core.studio .body { padding: 32px 30px 34px; }
.todo-list { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 10px; }
.todo-list li { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-radius: 14px; background: rgba(234, 241, 237, 0.08); box-shadow: inset 0 0 0 1px rgba(234, 241, 237, 0.12); }
.todo-list .ic { color: var(--accent); width: 1.3em; height: 1.3em; }
@media (min-width: 900px) {
  .bento { grid-template-columns: repeat(12, 1fr); gap: 20px; }
  .card.site { grid-column: span 7; }
  .card.guide { grid-column: span 5; }
  .card.book { grid-column: span 5; }
  .card.studio { grid-column: span 7; }
  .card.book .body, .card.studio .body { justify-content: flex-end; min-height: 320px; }
}

/* ---------- how it works ---------- */
.how .head { max-width: 40rem; margin-bottom: clamp(36px, 5vw, 60px); }
.band { position: relative; }
.band .core { aspect-ratio: 4 / 3; }
.band img { width: 100%; height: 100%; object-fit: cover; }
.steps { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 14px; position: relative; }
.step { padding: 8px; border-radius: 28px; background: var(--bg); box-shadow: inset 0 0 0 1px var(--shell-ring), var(--shadow); }
.step > div { padding: 22px 22px 26px; border-radius: 22px; background: var(--shell); }
.step h3 { margin-bottom: 10px; }
.step p { color: var(--muted); font-size: 1rem; }
@media (min-width: 900px) {
  .band .core { aspect-ratio: 21 / 9; }
  .steps { grid-template-columns: repeat(4, 1fr); gap: 18px; margin-top: -110px; padding-inline: clamp(12px, 2.4vw, 36px); align-items: start; }
  .step:nth-child(2) { margin-top: 34px; }
  .step:nth-child(3) { margin-top: 68px; }
  .step:nth-child(4) { margin-top: 102px; }
}

/* ---------- founder placeholder + hidden case study ---------- */
.founder { padding-block: clamp(40px, 6vw, 80px); }
.placeholder { border: 2px dashed var(--field-line); border-radius: 28px; padding: clamp(28px, 5vw, 56px); display: grid; gap: 14px; max-width: 52rem; }
.placeholder h2 { font-size: clamp(1.6rem, 1.2rem + 1.4vw, 2.3rem); }
.placeholder p { color: var(--muted); max-width: 52ch; }
.case { padding-block: clamp(60px, 8vw, 110px); }

/* ---------- faq ---------- */
.faq .wrap { display: grid; gap: 40px; }
.faq-list { display: grid; }
details { border-top: 1px solid var(--line); }
details:last-child { border-bottom: 1px solid var(--line); }
summary {
  list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 24px 0; font: 600 1.15rem/1.35 var(--f-display); letter-spacing: -0.015em;
}
summary::-webkit-details-marker { display: none; }
summary .ic { width: 1.5rem; height: 1.5rem; transition: transform 0.5s var(--ease); color: var(--accent); }
details[open] summary .ic { transform: rotate(45deg); }
details p { padding: 0 0 26px; color: var(--muted); max-width: 60ch; }
@media (min-width: 900px) {
  .faq .wrap { grid-template-columns: repeat(12, 1fr); gap: 0 20px; }
  .faq h2 { grid-column: 1 / span 7; margin-bottom: 56px; }
  .faq-list { grid-column: 4 / -1; }
}

/* ---------- opt-in ---------- */
.optin { background: var(--bg-2); }
.optin .wrap { display: grid; gap: 44px; align-items: start; }
.optin .art { display: none; }
.optin h2 + .lead { margin-top: 16px; max-width: 44ch; }
.form-shell { margin-top: 32px; padding: 8px; border-radius: 28px; background: var(--shell); box-shadow: inset 0 0 0 1px var(--shell-ring); }
form, .done { background: var(--bg); border-radius: 22px; padding: clamp(22px, 3vw, 34px); }
.row { display: grid; gap: 18px; }
.field { display: grid; gap: 8px; margin-bottom: 18px; }
label, legend { font-weight: 600; font-size: 0.97rem; }
.opt { font-weight: 400; color: var(--muted); }
.help { font-size: 0.9rem; color: var(--muted); }
.err { font-size: 0.92rem; color: var(--accent); font-weight: 600; min-height: 0; }
.err:empty { display: none; }
.consent-err { margin: -12px 0 18px; }
input[type="text"], input[type="email"], select, textarea {
  width: 100%; font: inherit; font-size: 1rem; color: var(--ink);
  background: var(--field); border: 1.5px solid var(--field-line); border-radius: 14px; padding: 14px 16px; min-height: 52px;
  transition: border-color 0.3s var(--ease), box-shadow 0.3s var(--ease);
}
textarea { min-height: 110px; resize: vertical; }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 35%, transparent); }
[aria-invalid="true"] { border-color: var(--accent); }
.select { position: relative; }
.select select { appearance: none; -webkit-appearance: none; padding-right: 48px; }
.select::after { content: ""; position: absolute; right: 18px; top: 50%; width: 10px; height: 10px; border-right: 2px solid var(--ink); border-bottom: 2px solid var(--ink); transform: translateY(-70%) rotate(45deg); pointer-events: none; }
.consent { display: grid; grid-template-columns: 24px 1fr; gap: 12px; align-items: start; margin: 4px 0 22px; font-size: 0.95rem; }
.consent input { width: 22px; height: 22px; margin: 2px 0 0; accent-color: var(--accent); }
.consent label { font-weight: 400; }
.consent a { text-underline-offset: 3px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-error { margin-top: 16px; padding: 14px 16px; border-radius: 14px; background: color-mix(in srgb, var(--accent) 14%, var(--bg)); color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--accent); }
.form-error:empty { display: none; }
form .btn { width: 100%; justify-content: space-between; }
.done h3 { font-size: 1.7rem; margin-bottom: 12px; }
.done p { color: var(--muted); }
.done .badge { margin-bottom: 18px; background: var(--accent); color: var(--accent-ink); box-shadow: none; }
@media (min-width: 900px) {
  .optin .wrap { grid-template-columns: 0.8fr 1.2fr; gap: clamp(40px, 6vw, 96px); }
  .optin .art { display: block; position: sticky; top: 96px; }
  .optin .art img { aspect-ratio: 4 / 5; }
  .row.two { grid-template-columns: 1fr 1fr; gap: 18px; }
}

/* ---------- footer ---------- */
footer { padding-block: 72px 40px; border-top: 1px solid var(--line); }
footer .big { font-family: var(--f-display); font-weight: 700; letter-spacing: -0.045em; font-size: clamp(3rem, 1rem + 9vw, 9rem); line-height: 0.95; }
footer .big i { font-style: normal; color: var(--accent); }
.foot { display: grid; gap: 28px; margin-top: 48px; }
.foot ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 24px; }
.foot a { display: inline-block; padding: 10px 0; text-underline-offset: 4px; }
.foot small { color: var(--muted); font-size: 0.92rem; }
@media (min-width: 900px) { .foot { grid-template-columns: 1fr auto; align-items: end; } }

/* ---------- plain pages (thanks, privacy, imprint, credits) ---------- */
.page { padding-block: 148px 96px; }
.page .wrap { max-width: 760px; }
.page h1 { font-size: clamp(2.2rem, 1.2rem + 3.4vw, 3.6rem); margin-bottom: 28px; }
.page h2 { font-size: 1.5rem; margin: 44px 0 12px; letter-spacing: -0.02em; }
.page p, .page li { color: var(--muted); max-width: 62ch; }
.page p + p { margin-top: 14px; }
.page ul { padding-left: 1.2em; display: grid; gap: 8px; }
.page a:not(.btn) { text-underline-offset: 3px; color: var(--ink); }
.page .btn { margin-top: 32px; }
.page .placeholder { margin-top: 20px; }

/* ---------- motion (only when the visitor allows it) ---------- */
@media (prefers-reduced-motion: no-preference) {
  .hero h1, .hero .lead, .hero .actions { animation: rise 1s var(--ease) both; }
  .hero .lead { animation-delay: 0.08s; }
  .hero .actions { animation-delay: 0.16s; }
  @keyframes rise { from { transform: translateY(22px); } to { transform: none; } }
}
@media (scripting: enabled) and (prefers-reduced-motion: no-preference) {
  .reveal { opacity: 0; transform: translateY(36px); transition: opacity 0.9s var(--ease), transform 0.9s var(--ease); transition-delay: var(--d, 0s); }
  .reveal.in { opacity: 1; transform: none; }
  .reveal.d1 { --d: 0.08s; }
  .reveal.d2 { --d: 0.15s; }
  .reveal.d3 { --d: 0.22s; }
  @supports (animation-timeline: view()) {
    .band img { animation: drift linear both; animation-timeline: view(); animation-range: entry 0% exit 100%; }
    @keyframes drift { from { transform: scale(1.14) translateY(-3%); } to { transform: scale(1.04) translateY(3%); } }
  }
}
