/*
  KwiqQnekt public site.

  Colours are taken from the app's own design tokens (theme/app_style.dart)
  so the site and the product look like one thing: Kalahari Amber on
  near-white, with dark charcoal text. Amber is an accent - CTAs, active
  states, key icons - never a background wash.
*/

:root {
  --bg: #ffffff;
  --surface: #f7f6f4;
  --surface-alt: #efede9;
  --divider: #e7e3dd;
  --ink: #221e1a;
  --ink-soft: #6f675e;
  --brand: #e8a33d;
  --brand-dark: #c97f1f;
  --brand-soft: #fbebd3;
  /* Amber for small TEXT. --brand-dark is only ~3:1 against white, fine
     for icons and outlines but below WCAG AA for body-size type; this
     holds 4.5:1 on both --bg and --surface. */
  --brand-text: #9a5c10;
  --success: #2e8b57;

  --radius-card: 16px;
  --radius-pill: 28px;
  --max: 1160px;

  --shadow: 0 4px 16px rgba(0, 0, 0, 0.04);
  --shadow-lift: 0 10px 30px rgba(34, 30, 26, 0.10);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

/* In-page links land below the sticky header (72px) instead of under it. */
[id] { scroll-margin-top: 88px; }

/* Respect a user who has asked the OS for less motion. */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI",
    Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { line-height: 1.15; margin: 0; letter-spacing: -0.02em; }

h1 { font-size: clamp(2.4rem, 5.5vw, 4rem); font-weight: 800; }
h2 { font-size: clamp(1.8rem, 3.4vw, 2.6rem); font-weight: 750; }
h3 { font-size: 1.15rem; font-weight: 700; }

p { margin: 0; }

a { color: inherit; }

.wrap {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 24px;
}

/* Visible focus for keyboard users - never removed, only styled. */
a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--brand-dark);
  outline-offset: 3px;
  border-radius: 6px;
}

/* Lets a keyboard user jump past the nav. */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--ink);
  color: #fff;
  padding: 12px 18px;
  z-index: 100;
}
.skip-link:focus { left: 12px; top: 12px; }

/* ---------- Header ---------- */

header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
header.scrolled {
  border-bottom-color: var(--divider);
  box-shadow: var(--shadow);
}

.nav {
  display: flex;
  align-items: center;
  gap: 28px;
  height: 72px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.15rem;
  text-decoration: none;
  letter-spacing: -0.02em;
}
.brand .mark {
  width: 32px;
  height: 32px;
  border-radius: 9px;
  background: var(--brand-soft);
  display: grid;
  place-items: center;
  color: var(--brand-dark);
}

.nav-links {
  display: flex;
  gap: 26px;
  margin-left: auto;
  align-items: center;
}
.nav-links a {
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--ink-soft);
  transition: color 0.15s ease;
}
.nav-links a:hover { color: var(--ink); }

.nav-toggle {
  display: none;
  margin-left: auto;
  background: none;
  border: 1px solid var(--divider);
  border-radius: 10px;
  padding: 8px 10px;
  cursor: pointer;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 24px;
  border-radius: var(--radius-pill);
  font-weight: 700;
  font-size: 0.98rem;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.12s ease, background 0.15s ease,
    box-shadow 0.15s ease;
}
.btn:active { transform: translateY(1px); }

/* Dark charcoal text on amber: amber is a bright warm tone, so dark text
   holds contrast far better than white - the same rule the app uses. */
.btn-primary { background: var(--brand); color: var(--ink); }
.btn-primary:hover { background: var(--brand-dark); box-shadow: var(--shadow-lift); }

.btn-ghost { background: transparent; color: var(--ink); border-color: var(--divider); }
.btn-ghost:hover { background: var(--surface); }

/* ---------- Hero ---------- */

.hero {
  padding: clamp(56px, 8vw, 104px) 0 clamp(48px, 7vw, 88px);
  background:
    radial-gradient(1100px 380px at 78% -8%, var(--brand-soft), transparent 62%),
    var(--bg);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 56px;
  align-items: center;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--surface);
  border: 1px solid var(--divider);
  color: var(--ink-soft);
  border-radius: var(--radius-pill);
  padding: 7px 15px;
  font-size: 0.83rem;
  font-weight: 600;
  margin-bottom: 22px;
}
.eyebrow .dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--success);
}

.hero p.lead {
  margin-top: 20px;
  font-size: 1.18rem;
  color: var(--ink-soft);
  max-width: 34ch;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}

.hero-note {
  margin-top: 18px;
  font-size: 0.87rem;
  color: var(--ink-soft);
}

/* A stylised product panel rather than a screenshot, so nothing here
   claims to be a real interface that does not exist yet. */
.hero-card {
  background: var(--bg);
  border: 1px solid var(--divider);
  border-radius: 22px;
  box-shadow: var(--shadow-lift);
  padding: 22px;
}
.trip-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 0;
}
.trip-row + .trip-row { border-top: 1px solid var(--divider); }
.pin {
  width: 11px; height: 11px; border-radius: 50%;
  background: var(--brand); flex: none;
}
.pin.dest { border-radius: 3px; background: var(--ink); }
.trip-row .label { font-size: 0.78rem; color: var(--ink-soft); }
.trip-row .value { font-weight: 650; font-size: 0.97rem; }

.fare {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px dashed var(--divider);
}
.fare .amount { font-size: 1.7rem; font-weight: 800; }

/* ---------- Sections ---------- */

section { padding: clamp(56px, 7vw, 96px) 0; }
section.tinted { background: var(--surface); }

.section-head { max-width: 62ch; margin-bottom: 44px; }
.section-head p {
  margin-top: 14px;
  color: var(--ink-soft);
  font-size: 1.05rem;
}

.kicker {
  text-transform: uppercase;
  letter-spacing: 0.09em;
  font-size: 0.76rem;
  font-weight: 800;
  color: var(--brand-text);
  margin-bottom: 12px;
}

.grid { display: grid; gap: 20px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }

.card {
  background: var(--bg);
  border: 1px solid var(--divider);
  border-radius: var(--radius-card);
  padding: 26px;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.card h3 { margin-bottom: 8px; }
.card p { color: var(--ink-soft); font-size: 0.97rem; }

.icon {
  width: 42px; height: 42px;
  border-radius: 12px;
  background: var(--brand-soft);
  color: var(--brand-dark);
  display: grid; place-items: center;
  margin-bottom: 16px;
}

/* Numbered steps */
.steps { counter-reset: step; }
.step { position: relative; padding-left: 62px; }
.step::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  left: 0; top: 0;
  width: 42px; height: 42px;
  border-radius: 50%;
  background: var(--ink);
  color: #fff;
  display: grid; place-items: center;
  font-weight: 800;
}

/* Split panels for the two audiences */
.split {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}
.panel {
  border-radius: 22px;
  padding: 36px;
  border: 1px solid var(--divider);
  background: var(--bg);
  display: flex;
  flex-direction: column;
}
.panel.dark { background: var(--ink); color: #fff; border-color: var(--ink); }
.panel.dark .ticks li { color: rgba(255, 255, 255, 0.82); }
.panel.dark h2 { color: #fff; }

.ticks { list-style: none; padding: 0; margin: 22px 0 28px; }
.ticks li {
  position: relative;
  padding-left: 30px;
  margin-bottom: 12px;
  color: var(--ink-soft);
  font-size: 0.99rem;
}
.ticks li::before {
  content: "";
  position: absolute;
  left: 0; top: 8px;
  width: 8px; height: 14px;
  border: solid var(--brand-dark);
  border-width: 0 2.5px 2.5px 0;
  transform: rotate(45deg);
}
.panel.dark .ticks li::before { border-color: var(--brand); }

.panel .btn { align-self: flex-start; margin-top: auto; }

/* Safety band */
.safety-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.safety-item {
  background: var(--bg);
  border: 1px solid var(--divider);
  border-radius: var(--radius-card);
  padding: 22px;
}
.safety-item strong { display: block; margin-bottom: 6px; }
.safety-item span { color: var(--ink-soft); font-size: 0.93rem; }

.safety-note {
  margin-top: 26px;
  color: var(--ink-soft);
  font-size: 0.93rem;
  max-width: 70ch;
}

/* Get started */
.cta {
  background: var(--ink);
  color: #fff;
  border-radius: 26px;
  padding: clamp(36px, 5vw, 60px);
  text-align: center;
}
.cta h2 { color: #fff; }
.cta p { color: rgba(255, 255, 255, 0.76); margin: 16px auto 0; max-width: 56ch; }
.cta-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 30px;
}
.cta p.cta-note { margin-top: 26px; font-size: 0.88rem; }

/* Sign-up form: a light card inside the dark CTA band, so the fields read
   like every other form a visitor has filled in. */
.signup,
.signup-done {
  background: var(--bg);
  color: var(--ink);
  border-radius: 20px;
  padding: clamp(20px, 3vw, 32px);
  margin: 30px auto 0;
  max-width: 640px;
  text-align: left;
}
.cta .signup p,
.cta .signup-done p { color: var(--ink-soft); margin: 0; max-width: none; }

.role-pick {
  border: 0;
  padding: 0;
  margin: 0 0 18px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}
.role-pick legend { font-weight: 700; margin-bottom: 10px; float: left; width: 100%; }
.role-pick label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--divider);
  border-radius: var(--radius-pill);
  padding: 9px 18px;
  font-weight: 600;
  cursor: pointer;
}
.role-pick label:has(input:checked) {
  border-color: var(--brand-dark);
  background: var(--brand-soft);
}
.role-pick input { accent-color: var(--brand-dark); margin: 0; }

.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-bottom: 14px;
}
.signup label { font-size: 0.9rem; font-weight: 600; }
.field-row label { display: flex; flex-direction: column; gap: 6px; }
.signup input:not([type="radio"]) {
  font: inherit;
  font-weight: 400;
  padding: 11px 13px;
  border: 1px solid var(--divider);
  border-radius: 12px;
  background: var(--bg);
  color: var(--ink);
}
.signup input:focus-visible {
  outline: 3px solid var(--brand-dark);
  outline-offset: 1px;
}
.signup .hint { font-size: 0.85rem; margin: 4px 0 16px; }
.signup .hint a { color: var(--brand-text); font-weight: 600; }
.signup .btn { width: 100%; }
.signup .btn[disabled] { opacity: 0.6; cursor: progress; }

.form-message {
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 16px;
  background: #fdecea;
  color: #8a1c12;
  font-size: 0.93rem;
}
.form-message ul { margin: 0; padding-left: 18px; }

.signup-done { text-align: center; }
.signup-done h3 { margin-bottom: 8px; }
.signup-done .btn { margin-top: 18px; }
.cta .btn-ghost { color: #fff; border-color: rgba(255, 255, 255, 0.28); }
.cta .btn-ghost:hover { background: rgba(255, 255, 255, 0.08); }

/* ---------- Footer ---------- */

footer {
  border-top: 1px solid var(--divider);
  padding: 52px 0 36px;
  background: var(--bg);
}
.foot-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 32px;
}
.foot-brand { margin-bottom: 14px; }
.foot-tagline { color: var(--ink-soft); font-size: 0.94rem; max-width: 34ch; }

footer h4 {
  margin: 0 0 14px;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ink-soft);
}
footer ul { list-style: none; padding: 0; margin: 0; }
footer li { margin-bottom: 10px; }
footer a { text-decoration: none; color: var(--ink-soft); font-size: 0.95rem; }
footer a:hover { color: var(--ink); }

.foot-bottom {
  margin-top: 40px;
  padding-top: 22px;
  border-top: 1px solid var(--divider);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  color: var(--ink-soft);
  font-size: 0.88rem;
}

/* ---------- Responsive ---------- */

@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .hero p.lead { max-width: none; }
  .grid-3, .split, .foot-grid { grid-template-columns: 1fr; }
  .safety-grid { grid-template-columns: repeat(2, 1fr); }
  .foot-grid { gap: 28px; }

  .nav-toggle { display: block; }
  .nav-links {
    display: none;
    position: absolute;
    top: 72px; left: 0; right: 0;
    background: var(--bg);
    border-bottom: 1px solid var(--divider);
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 10px 24px 20px;
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 13px 0; border-bottom: 1px solid var(--divider); }
  .nav-links .btn { margin-top: 14px; justify-content: center; }
}

@media (max-width: 620px) {
  body { font-size: 16px; }
  .safety-grid, .field-row { grid-template-columns: 1fr; }
  .hero-actions .btn { width: 100%; }
  .panel { padding: 26px; }
}
