/* tripinz.app: the Forest look from the apps (tripinz-trek-ios/docs/design-guidelines.md).
   Moss paper, forest green as the one accent, real trek photos, calm cards. Day and night follow the device. */
:root {
  --bg: #EEF1EA;
  --surface: #FFFFFF;
  --ink: #1F2B22;
  --soft: #56645A;
  --rule: #D3DCCF;
  --primary: #2F6B3F;
  --on-primary: #FFFFFF;
  --deep: #2D5A27;
  --accent: #C0485A;
  --tint: #E3EDE3;
  --skyline: #B6CDB8;
  --danger: #C8382F;
  --r-card: 24px;
  --r-tile: 18px;
  --r-sheet: 30px;
  --gutter: 16px;
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --photo-dim: 1;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0E1410;
    --surface: #18201A;
    --ink: #E7EDE6;
    --soft: #A2B0A5;
    --rule: #2A362D;
    --primary: #8CC49A;
    --on-primary: #0E1410;
    --deep: #A9D4B2;
    --accent: #F08A9A;
    --tint: #213026;
    --skyline: #2F4636;
    --danger: #FF6B5E;
    --photo-dim: .78;
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 17px/1.55 var(--font); -webkit-font-smoothing: antialiased; overflow-x: hidden;
  font-variant-numeric: tabular-nums;
}
img { display: block; max-width: 100%; height: auto; }
a { color: var(--primary); }
h1, h2, h3 { color: var(--ink); line-height: 1.12; margin: 0; letter-spacing: -0.015em; }
h2 { font-size: clamp(30px, 4vw, 46px); font-weight: 300; }
h2 b, h1 b { font-weight: 600; }
h3 { font-size: 19px; font-weight: 600; }
p { margin: 0; }
.soft { color: var(--soft); }
.fine { font-size: 14px; color: var(--soft); }
.center { text-align: center; }
.label { margin: 0 0 10px; font-size: 15px; font-weight: 600; color: var(--deep); }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.photo { filter: brightness(var(--photo-dim)); }

/* ---------- buttons and chips ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 8px; min-height: 50px; padding: 0 24px; border-radius: 999px;
  font: 600 16px/1 var(--font); text-decoration: none; border: 0; cursor: pointer; transition: background .2s, transform .2s;
}
.btn:active { transform: scale(.98); }
.btn-primary { background: var(--primary); color: var(--on-primary); }
.btn-primary:hover { background: color-mix(in srgb, var(--primary) 88%, #000); }
.btn-quiet { background: var(--tint); color: var(--primary); }
.btn-quiet:hover { background: color-mix(in srgb, var(--tint) 85%, var(--primary)); }
.btn-light { background: #fff; color: #1F2B22; }
.btn-light:hover { background: #E7EDE6; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.cta-row.center { justify-content: center; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0 0; padding: 0; list-style: none; }
.chip-photo {
  display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border-radius: 999px; font-size: 15px; font-weight: 500;
  color: #fff; background: rgba(0,0,0,.38); border: 1px solid rgba(255,255,255,.55);
}
.chip { display: inline-flex; align-items: center; padding: 6px 12px; border-radius: 999px; font-size: 14px; font-weight: 500; background: var(--tint); color: var(--ink); }

/* ---------- nav ---------- */
.nav {
  position: fixed; inset: 0 0 auto; z-index: 50; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 14px max(20px, calc((100vw - 1120px) / 2 + 24px)); transition: background .25s, border-color .25s;
  border-bottom: 1px solid transparent;
}
.nav.scrolled { background: var(--bg); border-color: var(--rule); }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; font-weight: 600; font-size: 19px; }
.brand img { border-radius: 9px; }
.brand span { font-weight: 300; }
.nav.scrolled .brand { color: var(--ink); }
.nav nav { display: flex; align-items: center; gap: 2px; }
.nav nav a { white-space: nowrap; color: rgba(255,255,255,.9); text-decoration: none; font-size: 15px; font-weight: 500; padding: 8px 12px; border-radius: 999px; }
.nav nav a:hover { background: rgba(255,255,255,.14); }
.nav.scrolled nav a { color: var(--soft); }
.nav.scrolled nav a:hover { background: var(--tint); color: var(--ink); }
.nav nav a.nav-cta { background: #fff; color: #1F2B22; margin-left: 6px; padding: 9px 16px; }
.nav.scrolled nav a.nav-cta { background: var(--primary); color: var(--on-primary); }
/* pages without a photo at the top start with the solid bar */
.nav.solid { position: sticky; background: var(--bg); border-color: var(--rule); }
.nav.solid .brand { color: var(--ink); }
.nav.solid nav a { color: var(--soft); }
.nav.solid nav a.nav-cta { background: var(--primary); color: var(--on-primary); }
@media (max-width: 760px) {
  .nav nav a:not(.nav-cta) { display: none; }
  .nav nav a.nav-trek { display: inline-flex; }
}

/* ---------- hero: full-bleed trek photo, then a sheet slides over it ---------- */
.hero { position: relative; min-height: min(92vh, 920px); display: flex; align-items: flex-end; color: #fff; overflow: hidden; }
.hero > picture img, .hero > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero::before, .hero::after { content: ""; position: absolute; left: 0; right: 0; pointer-events: none; z-index: 1; }
.hero::before { top: 0; height: 40%; background: linear-gradient(180deg, rgba(0,0,0,.55), rgba(0,0,0,0)); }
.hero::after { bottom: 0; height: 100%; background: linear-gradient(0deg, rgba(0,0,0,.72) 0%, rgba(0,0,0,.35) 42%, rgba(0,0,0,0) 75%), linear-gradient(90deg, rgba(0,0,0,.42) 0%, rgba(0,0,0,.18) 50%, rgba(0,0,0,0) 72%); }
.hero-inner { position: relative; z-index: 2; width: 100%; max-width: 1120px; margin: 0 auto; padding: 140px 24px 96px; }
.hero .hello { font-size: 18px; font-weight: 500; opacity: .92; margin-bottom: 8px; }
.hero h1 { color: #fff; font-size: clamp(42px, 7vw, 84px); font-weight: 300; line-height: 1.02; letter-spacing: -0.025em; }
.hero h1 b { font-weight: 600; }
.hero .lead { font-size: clamp(18px, 2vw, 21px); color: rgba(255,255,255,.92); max-width: 46ch; margin-top: 20px; }
.hero .credit { position: absolute; right: 24px; bottom: 44px; z-index: 2; font-size: 12px; color: rgba(255,255,255,.72); }
.hero .credit a { color: inherit; }
.sheet { position: relative; z-index: 2; background: var(--bg); border-radius: var(--r-sheet) var(--r-sheet) 0 0; margin-top: -30px; padding-top: 24px; }

/* ---------- phone screens ---------- */
.phone {
  margin: 0; width: 300px; max-width: 78vw; border-radius: 46px; padding: 9px; background: #1F2B22; flex: none;
}
.phone img { width: 100%; border-radius: 38px; }
@media (prefers-color-scheme: dark) { .phone { background: #2A362D; } }

/* ---------- sections ---------- */
section { scroll-margin-top: 70px; }
.block { padding-top: 88px; padding-bottom: 88px; }
.block + .block { padding-top: 0; }
.head { max-width: 640px; margin-bottom: 36px; }
.head p:not(.label) { color: var(--soft); font-size: 19px; margin-top: 14px; }
.head.center { margin-left: auto; margin-right: auto; }

.feature { display: grid; grid-template-columns: 1fr auto; gap: 72px; align-items: center; }
.feature.flip { grid-template-columns: auto 1fr; }
.feature.flip .phone { order: -1; }
.feature p.body { color: var(--soft); font-size: 19px; margin-top: 16px; max-width: 46ch; }
.ticks { list-style: none; padding: 0; margin: 24px 0 0; display: grid; gap: 12px; }
.ticks li { display: flex; gap: 12px; align-items: flex-start; }
.ticks li::before {
  content: ""; flex: none; width: 24px; height: 24px; border-radius: 8px; margin-top: 1px; background: var(--tint)
  url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='m7 12.5 3.2 3.2L17 9' fill='none' stroke='%232F6B3F' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 18px no-repeat;
}
@media (prefers-color-scheme: dark) {
  .ticks li::before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='m7 12.5 3.2 3.2L17 9' fill='none' stroke='%238CC49A' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); }
}

/* small cards: icon tile + title + text */
.tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.tile { background: var(--surface); border-radius: var(--r-card); padding: 22px; }
.tile .ico { width: 56px; height: 56px; border-radius: var(--r-tile); background: var(--tint); color: var(--primary); display: grid; place-items: center; margin-bottom: 16px; }
.tile .ico svg { width: 26px; height: 26px; }
.tile p { color: var(--soft); font-size: 16px; margin-top: 6px; }

/* safety */
.safety-wrap { display: grid; grid-template-columns: 1fr auto; gap: 64px; align-items: center; }
.safety-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; margin-top: 30px; }
.safety-list .tile .ico.sos { background: color-mix(in srgb, var(--danger) 14%, transparent); color: var(--danger); font-weight: 700; font-size: 15px; }

/* ---------- treks ---------- */
.tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 26px; }
.tabs button {
  font: 500 15px/1 var(--font); border: 0; cursor: pointer; padding: 11px 16px; border-radius: 999px;
  background: var(--tint); color: var(--ink); display: inline-flex; gap: 6px; align-items: center;
}
.tabs button span { color: var(--soft); font-weight: 400; }
.tabs button[aria-selected="true"] { background: var(--primary); color: var(--on-primary); }
.tabs button[aria-selected="true"] span { color: inherit; opacity: .8; }
.trek-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.trek.hide { display: none; }
/* photo card: text on a bottom scrim, fixed height so every card matches */
.trek { position: relative; display: block; height: 340px; border-radius: var(--r-card); overflow: hidden; text-decoration: none; color: #fff; background: var(--skyline); }
.trek img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .5s; filter: brightness(var(--photo-dim)); }
.trek:hover img { transform: scale(1.04); }
.trek::after { content: ""; position: absolute; inset: 0; z-index: 0; background: linear-gradient(0deg, rgba(0,0,0,.72) 0%, rgba(0,0,0,.25) 48%, rgba(0,0,0,0) 70%); }
.trek-body { position: absolute; left: 0; right: 0; bottom: 0; z-index: 1; padding: 20px; }
.trek-body .where { font-size: 14px; font-weight: 500; opacity: .9; }
.trek-body h3 { color: #fff; font-size: 22px; margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.trek-body p { font-size: 15px; color: rgba(255,255,255,.9); margin-top: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.trek-body .chips { margin-top: 12px; flex-wrap: nowrap; }
.trek-body .chip-photo { font-size: 13px; padding: 5px 11px; }
.trek-more { margin-top: 26px; }

/* ---------- pricing ---------- */
.plans { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; max-width: 860px; margin: 0 auto; }
.plan { background: var(--surface); border-radius: var(--r-card); padding: 30px; display: flex; flex-direction: column; }
.plan h3 { font-size: 20px; }
.plan .price { font-size: 44px; font-weight: 300; margin-top: 10px; color: var(--ink); }
.plan .price b { font-weight: 600; }
.plan .price small { font-size: 17px; color: var(--soft); }
.plan .per { color: var(--soft); font-size: 15px; }
.plan .ticks { margin-top: 22px; }
.plan-pro { background: var(--primary); color: var(--on-primary); }
.plan-pro h3, .plan-pro .price, .plan-pro .price small, .plan-pro .per { color: var(--on-primary); }
.plan-pro .per { opacity: .85; }
.plan-pro .ticks li::before { background-color: rgba(255,255,255,.18); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='m7 12.5 3.2 3.2L17 9' fill='none' stroke='white' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); }
@media (prefers-color-scheme: dark) {
  .plan-pro .ticks li::before { background-color: rgba(0,0,0,.14); background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='m7 12.5 3.2 3.2L17 9' fill='none' stroke='%230E1410' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); }
}
.trial { align-self: flex-start; margin-bottom: 14px; font-size: 14px; font-weight: 600; padding: 5px 12px; border-radius: 999px; background: rgba(255,255,255,.18); }
@media (prefers-color-scheme: dark) { .trial { background: rgba(0,0,0,.14); } }

/* partners strip */
.partners { background: var(--tint); border-radius: var(--r-card); padding: 30px 32px; display: flex; gap: 24px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.partners h3 { font-size: 22px; font-weight: 300; }
.partners h3 b { font-weight: 600; }
.partners p { color: var(--soft); margin-top: 6px; max-width: 56ch; }

/* faq */
.faq { max-width: 760px; margin: 0 auto; }
.faq details { background: var(--surface); border-radius: var(--r-tile); padding: 0 22px; margin-bottom: 10px; }
.faq summary { cursor: pointer; list-style: none; padding: 20px 30px 20px 0; font-weight: 600; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 0; top: 16px; font-size: 24px; font-weight: 300; color: var(--primary); }
.faq details[open] summary::after { content: "−"; }
.faq details p { color: var(--soft); padding: 0 0 20px; }

/* ---------- closing photo band ---------- */
.band { position: relative; overflow: hidden; color: #fff; margin-top: 88px; }
.band > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.band::before { content: ""; position: absolute; inset: 0; z-index: 1; background: linear-gradient(90deg, rgba(0,0,0,.72) 0%, rgba(0,0,0,.45) 55%, rgba(0,0,0,.2) 100%); }
.band-inner { position: relative; z-index: 2; max-width: 1120px; margin: 0 auto; padding: 110px 24px; }
.band h2 { color: #fff; }
.band p { color: rgba(255,255,255,.9); font-size: 19px; max-width: 48ch; margin-top: 16px; }
.band .icon { border-radius: 22px; margin-bottom: 24px; }
.band .credit { position: absolute; z-index: 2; right: 24px; bottom: 14px; font-size: 12px; color: rgba(255,255,255,.72); }
.band .credit a { color: inherit; }
.store { display: inline-flex; align-items: center; gap: 10px; min-height: 54px; padding: 0 20px; border-radius: 999px; text-decoration: none; background: #fff; color: #1F2B22; font-weight: 600; }
.store small { display: block; font-size: 11px; font-weight: 500; opacity: .7; line-height: 1.1; }
.store span { line-height: 1.15; }
.store.soon { background: rgba(0,0,0,.38); color: #fff; border: 1px solid rgba(255,255,255,.55); }

/* ---------- footer ---------- */
.foot { border-top: 1px solid var(--rule); padding: 34px 0 44px; font-size: 14px; color: var(--soft); }
.foot-inner { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 14px; margin-bottom: 14px; }
.foot .brand { color: var(--ink); font-size: 17px; }
.foot nav { display: flex; flex-wrap: wrap; gap: 4px 18px; }
.foot nav a { color: var(--soft); text-decoration: none; }
.foot nav a:hover { color: var(--ink); }
.foot p { max-width: 90ch; }

/* ---------- reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s, transform .7s; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } .trek img { transition: none; } }

/* ---------- small screens ---------- */
@media (max-width: 960px) {
  .trek-grid, .tiles { grid-template-columns: repeat(2, 1fr); }
  .feature, .feature.flip, .safety-wrap { grid-template-columns: 1fr; gap: 40px; }
  .feature .phone, .safety-wrap .phone { margin: 0 auto; }
  .feature.flip .phone { order: 0; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .wrap { padding: 0 var(--gutter); }
  .hero { min-height: 86vh; }
  .hero-inner { padding: 120px var(--gutter) 70px; }
  .hero .credit { right: var(--gutter); bottom: 40px; }
  .block { padding-top: 64px; padding-bottom: 64px; }
  .trek-grid, .tiles, .safety-list, .plans { grid-template-columns: 1fr; }
  .trek { height: 300px; }
  .phone { width: 260px; border-radius: 40px; padding: 8px; }
  .phone img { border-radius: 33px; }
  .partners { padding: 24px; }
  .band-inner { padding: 80px var(--gutter); }
  .band { margin-top: 64px; }
  .tabs { flex-wrap: nowrap; overflow-x: auto; margin-left: calc(-1 * var(--gutter)); margin-right: calc(-1 * var(--gutter)); padding: 0 var(--gutter); scrollbar-width: none; }
  .tabs::-webkit-scrollbar { display: none; }
  .tabs button { flex: none; }
}

/* country switch above the region tabs (only when more than one country is live) */
.country-switch { display: inline-flex; gap: 4px; padding: 4px; border-radius: 999px; background: var(--surface); margin-bottom: 14px; }
.country-switch button { font: 600 16px/1 var(--font); border: 0; cursor: pointer; padding: 11px 20px; border-radius: 999px; background: none; color: var(--soft); }
.country-switch button span { font-weight: 400; margin-left: 4px; }
.country-switch button[aria-selected="true"] { background: var(--ink); color: var(--bg); }
.tabs button[hidden] { display: none; }
