/* TeeOff Club website. Colours come straight from the app's theme
   (lib/core/theme/app_theme.dart) so the site and the app feel like one thing. */

:root {
  --bg: #F7F3ED;
  --bg-deep: #EFE9DF;
  --card: #E9EADD;
  --ink: #2D3D22;
  --ink-soft: #5B6450;
  --muted: #8A8F80;
  --green: #437C18;
  --green-dark: #34601A;
  --olive: #7A8540;
  --yellow: #FEFF73;
  --yellow-edge: #D0D561;
  --line: rgba(45, 61, 34, 0.12);
  --white: #FFFFFF;
  --night: #1F2B17;

  --radius: 28px;
  --radius-sm: 18px;
  --max: 1180px;
  --gutter: clamp(16px, 4vw, 40px);
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }

/* ---------- Header ---------- */

.header {
  position: sticky; top: 0; z-index: 20;
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: saturate(1.4) blur(14px);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid transparent;
}
.header .wrap { display: flex; align-items: center; justify-content: space-between; height: 68px; gap: 16px; }

.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 800; font-size: 19px; letter-spacing: -0.02em; }
.brand img { width: 34px; height: 34px; border-radius: 9px; }

.nav { display: flex; align-items: center; gap: 28px; }
.nav a { text-decoration: none; font-size: 15px; font-weight: 500; color: var(--ink-soft); }
.nav a:hover { color: var(--ink); }
.nav .btn { color: var(--white); }

@media (max-width: 720px) {
  .nav a:not(.btn) { display: none; }
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 0 24px;
  border-radius: 999px;
  background: var(--green); color: var(--white);
  font: inherit; font-weight: 600; font-size: 16px;
  text-decoration: none; border: 0; cursor: pointer;
  transition: background .2s ease, transform .2s ease;
}
.btn:hover { background: var(--green-dark); }
.btn:active { transform: scale(0.98); }
.btn-sm { min-height: 40px; padding: 0 18px; font-size: 15px; }
.btn-ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--line); }
.btn-ghost:hover { background: var(--card); }
.btn svg { width: 20px; height: 20px; flex: none; }

/* App Store badge (drawn in CSS so there's no image to keep up to date) */
.store {
  display: inline-flex; align-items: center; gap: 12px;
  height: 58px; padding: 0 22px 0 18px;
  border-radius: 16px; background: var(--night); color: var(--white);
  text-decoration: none; transition: transform .2s ease, background .2s ease;
}
.store:hover { background: #000; transform: translateY(-1px); }
.store svg { width: 28px; height: 28px; }
.store span { display: flex; flex-direction: column; line-height: 1.1; }
.store small { font-size: 11px; opacity: .8; letter-spacing: .02em; }
.store strong { font-size: 20px; font-weight: 600; letter-spacing: -0.01em; }

/* ---------- Type ---------- */

.eyebrow {
  font-size: 13px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase;
  color: var(--olive); margin: 0 0 18px;
}
.display {
  font-weight: 800; letter-spacing: -0.045em; line-height: .94;
  font-size: clamp(52px, 10vw, 132px); margin: 0;
  text-transform: uppercase;
}
.h2 {
  font-weight: 700; letter-spacing: -0.035em; line-height: 1.02;
  font-size: clamp(38px, 5.6vw, 72px); margin: 0 0 22px;
  text-wrap: balance;
}
.h3 { font-weight: 700; letter-spacing: -0.02em; font-size: 22px; line-height: 1.2; margin: 0 0 8px; }
.lede { font-size: clamp(18px, 2vw, 22px); color: var(--ink-soft); max-width: 34ch; margin: 0; text-wrap: pretty; }
.muted { color: var(--muted); }

/* ---------- Hero ---------- */

.hero { padding: clamp(56px, 9vw, 120px) 0 0; text-align: center; }
.hero .display { max-width: 12ch; margin: 0 auto; }
.hero .lede { margin: 28px auto 36px; max-width: 40ch; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; align-items: center; }

.hero-stage {
  position: relative; margin-top: clamp(56px, 8vw, 96px);
  border-radius: var(--radius) var(--radius) 0 0;
  overflow: hidden;
  height: clamp(420px, 62vw, 720px);
  background: var(--night) url("img/Karen.jpg") center / cover no-repeat;
}
.hero-stage::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(31,43,23,.05) 0%, rgba(31,43,23,.35) 100%);
}
.hero-stage .phone {
  position: absolute; z-index: 1; bottom: -34%; left: 50%;
  transform: translateX(-50%);
  width: clamp(230px, 30vw, 340px);
}
.hero-stage .phone.left  { left: 26%; bottom: -44%; transform: translateX(-50%) rotate(-7deg); width: clamp(190px, 24vw, 280px); }
.hero-stage .phone.right { left: 74%; bottom: -44%; transform: translateX(-50%) rotate(7deg);  width: clamp(190px, 24vw, 280px); }
@media (max-width: 720px) {
  .hero-stage .phone.left, .hero-stage .phone.right { display: none; }
  .hero-stage .phone { bottom: -30%; width: 62vw; }
}

/* ---------- Phone mockup ---------- */

.phone {
  aspect-ratio: 600 / 1222;
  border-radius: 44px;
  padding: 10px;
  background: #151A12;
  box-shadow: 0 40px 80px -30px rgba(31, 43, 23, .55), 0 0 0 1px rgba(255,255,255,.06) inset;
}
.phone img { width: 100%; height: 100%; object-fit: cover; object-position: top; border-radius: 35px; background: var(--bg); }

/* ---------- Manifesto ---------- */

.manifesto { padding: clamp(80px, 12vw, 160px) 0; }
.manifesto p {
  font-size: clamp(28px, 4.2vw, 54px); font-weight: 600; letter-spacing: -0.03em; line-height: 1.12;
  margin: 0; max-width: 22ch; text-wrap: balance;
}
.manifesto p + p { margin-top: .6em; }
.manifesto .dim { color: var(--muted); }

/* ---------- Feature rows ---------- */

.feature { padding: clamp(40px, 6vw, 72px) 0; }
.feature .wrap {
  display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 96px); align-items: center;
}
.feature.flip .copy { order: 2; }
.feature .visual {
  position: relative; border-radius: var(--radius);
  background: var(--card);
  display: grid; place-items: center;
  padding: clamp(40px, 6vw, 72px) 20px 0;
  overflow: hidden;
  aspect-ratio: 1 / 1.06;
}
.feature .visual .phone { width: min(300px, 70%); margin-bottom: -18%; }
.feature .visual.photo { background-size: cover; background-position: center; }
.feature .visual.yellow { background: var(--yellow); }
.feature .visual.dark { background: var(--ink); }
.feature .copy .lede { max-width: 30ch; }
.ticks { list-style: none; padding: 0; margin: 28px 0 0; display: grid; gap: 12px; }
.ticks li { display: flex; gap: 12px; align-items: baseline; color: var(--ink-soft); }
.ticks li::before {
  content: ""; flex: none; width: 8px; height: 8px; border-radius: 50%;
  background: var(--green); transform: translateY(-2px);
}

@media (max-width: 860px) {
  .feature .wrap { grid-template-columns: 1fr; }
  .feature.flip .copy { order: 0; }
}

/* ---------- Everything else grid ---------- */

.grid-section { padding: clamp(80px, 11vw, 140px) 0 clamp(40px, 6vw, 80px); }
.grid-head { display: flex; justify-content: space-between; align-items: end; gap: 24px; flex-wrap: wrap; margin-bottom: 40px; }
.grid-head .h2 { margin: 0; max-width: 14ch; }
.tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.tile {
  background: var(--white); border-radius: var(--radius-sm); padding: 26px 24px 28px;
  display: flex; flex-direction: column; gap: 10px;
}
.tile .icon {
  width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center;
  background: var(--card); color: var(--ink); margin-bottom: 18px;
}
.tile .icon svg { width: 22px; height: 22px; }
.tile p { margin: 0; color: var(--ink-soft); font-size: 15.5px; }
@media (max-width: 1000px) { .tiles { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px)  { .tiles { grid-template-columns: 1fr; } }

/* ---------- Kenya band ---------- */

.band {
  margin: clamp(40px, 6vw, 80px) 0;
  position: relative; color: var(--white);
  background: var(--night) url("img/kenyarailways.jpg") center 40% / cover no-repeat;
}
.band::before { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(31,43,23,.88) 0%, rgba(31,43,23,.55) 55%, rgba(31,43,23,.2) 100%); }
.band .wrap { position: relative; padding-top: clamp(80px, 12vw, 160px); padding-bottom: clamp(80px, 12vw, 160px); }
.band .eyebrow { color: var(--yellow); }
.band .h2 { max-width: 13ch; }
.band .lede { color: rgba(255,255,255,.82); }
.stats { display: flex; flex-wrap: wrap; gap: clamp(28px, 6vw, 72px); margin-top: 48px; }
.stats div { display: flex; flex-direction: column; }
.stats strong { font-size: clamp(40px, 5vw, 60px); font-weight: 700; letter-spacing: -0.04em; line-height: 1; }
.stats span { font-size: 13px; letter-spacing: .12em; text-transform: uppercase; opacity: .75; margin-top: 8px; }

/* ---------- FAQ ---------- */

.faq { padding: clamp(60px, 9vw, 120px) 0; }
.faq .wrap { display: grid; grid-template-columns: 1fr 1.5fr; gap: clamp(32px, 6vw, 96px); align-items: start; }
@media (max-width: 860px) { .faq .wrap { grid-template-columns: 1fr; } }
.faq-list { border-top: 1px solid var(--line); }
details { border-bottom: 1px solid var(--line); }
summary {
  list-style: none; cursor: pointer;
  display: flex; justify-content: space-between; align-items: center; gap: 20px;
  padding: 24px 0; font-size: 19px; font-weight: 600; letter-spacing: -0.01em;
}
summary::-webkit-details-marker { display: none; }
summary::after {
  content: ""; flex: none; width: 34px; height: 34px; border-radius: 50%;
  background: var(--card) center / 14px no-repeat url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 14'%3E%3Cpath d='M7 1v12M1 7h12' stroke='%232D3D22' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E");
  transition: transform .25s ease, background-color .25s ease;
}
details[open] summary::after { transform: rotate(45deg); background-color: var(--yellow); }
details .answer { padding: 0 48px 26px 0; color: var(--ink-soft); }
details .answer p { margin: 0 0 12px; }
details .answer p:last-child { margin: 0; }

/* ---------- CTA ---------- */

.cta { padding: 0 0 clamp(60px, 8vw, 100px); }
.cta-card {
  background: var(--yellow); border-radius: var(--radius);
  padding: clamp(48px, 8vw, 100px) clamp(24px, 6vw, 80px);
  display: grid; grid-template-columns: 1.3fr 1fr; gap: 40px; align-items: center;
  overflow: hidden; position: relative;
}
.cta-card .h2 { margin-bottom: 16px; }
.cta-card .lede { color: var(--ink); opacity: .75; margin-bottom: 32px; }
.cta-card .icon-big { justify-self: center; width: min(260px, 60%); border-radius: 22%; box-shadow: 0 30px 60px -25px rgba(45,61,34,.5); transform: rotate(-6deg); }
@media (max-width: 760px) { .cta-card { grid-template-columns: 1fr; } .cta-card .icon-big { width: 140px; justify-self: start; order: -1; } }

/* ---------- Footer ---------- */

.footer { background: var(--ink); color: rgba(247,243,237,.72); padding: 72px 0 40px; font-size: 15px; }
.footer a { text-decoration: none; }
.footer a:hover { color: var(--white); }
.footer-top { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px; }
.footer .brand { color: var(--white); margin-bottom: 16px; }
.footer h4 { color: var(--white); font-size: 13px; letter-spacing: .12em; text-transform: uppercase; font-weight: 600; margin: 6px 0 16px; }
.footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.footer-bottom { margin-top: 64px; padding-top: 24px; border-top: 1px solid rgba(247,243,237,.14); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; font-size: 14px; }
.footer .wordmark {
  margin-top: 56px; font-weight: 800; letter-spacing: -0.05em; line-height: .8;
  font-size: clamp(64px, 16vw, 220px); color: rgba(247,243,237,.08); text-transform: uppercase;
  white-space: nowrap; overflow: hidden;
}
/* Size the word from the footer's own width, not the window's, so it always
   fits. The word is about 5.95 times as wide as its font size. */
@supports (font-size: 1cqw) {
  .footer .wrap { container-type: inline-size; }
  .footer .wordmark { font-size: 16.5cqw; }
}
@media (max-width: 760px) { .footer-top { grid-template-columns: 1fr 1fr; } .footer-top > :first-child { grid-column: 1 / -1; } }

/* ---------- Document pages (support, privacy, terms) ---------- */

.doc-hero { padding: clamp(56px, 8vw, 100px) 0 clamp(32px, 5vw, 56px); border-bottom: 1px solid var(--line); }
.doc-hero .h2 { font-size: clamp(44px, 7vw, 88px); margin-bottom: 18px; }
.doc-hero .meta { color: var(--muted); font-size: 15px; margin: 0; }

.doc { display: grid; grid-template-columns: 240px 1fr; gap: clamp(32px, 6vw, 88px); padding: clamp(40px, 6vw, 72px) var(--gutter) clamp(80px, 10vw, 120px); }
.toc { position: sticky; top: 96px; align-self: start; font-size: 14.5px; }
.toc p { font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin: 0 0 14px; font-weight: 600; }
.toc ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; counter-reset: toc; }
.toc a { text-decoration: none; color: var(--ink-soft); }
.toc a:hover { color: var(--green); }
@media (max-width: 900px) { .doc { grid-template-columns: 1fr; } .toc { position: static; display: none; } }

.prose { max-width: 70ch; }
.prose h2 { font-size: 26px; letter-spacing: -0.025em; line-height: 1.2; margin: 56px 0 14px; scroll-margin-top: 96px; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { font-size: 18px; margin: 28px 0 8px; }
.prose p, .prose li { color: #3E4834; }
.prose ul { padding-left: 1.2em; }
.prose li { margin: 6px 0; }
.prose a { color: var(--green); text-underline-offset: 3px; }
.prose strong { color: var(--ink); }
.note {
  background: var(--card); border-radius: var(--radius-sm); padding: 22px 24px; margin: 0 0 32px;
}
.note p { margin: 0; }
.prose table { width: 100%; border-collapse: collapse; font-size: 15.5px; margin: 16px 0; }
.prose th, .prose td { text-align: left; vertical-align: top; padding: 12px 14px 12px 0; border-bottom: 1px solid var(--line); }
.prose th { font-size: 13px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.table-scroll { overflow-x: auto; }

/* Support page */
.support-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; padding: clamp(40px, 6vw, 64px) 0 0; }
.support-card {
  background: var(--white); border-radius: var(--radius-sm); padding: 28px; text-decoration: none;
  display: flex; flex-direction: column; gap: 6px; transition: transform .2s ease, box-shadow .2s ease;
}
a.support-card:hover { transform: translateY(-2px); box-shadow: 0 20px 40px -24px rgba(45,61,34,.4); }
.support-card .icon { width: 46px; height: 46px; border-radius: 14px; background: var(--card); display: grid; place-items: center; margin-bottom: 18px; }
.support-card .icon svg { width: 22px; height: 22px; }
.support-card p { margin: 0; color: var(--ink-soft); font-size: 15.5px; }
.support-card .go { margin-top: 14px; color: var(--green); font-weight: 600; font-size: 15px; }
@media (max-width: 860px) { .support-cards { grid-template-columns: 1fr; } }

/* ---------- Motion ---------- */

.reveal { opacity: 0; transform: translateY(24px); transition: opacity .8s ease, transform .8s cubic-bezier(.2,.7,.2,1); }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
}
