/* ==========================================================================
   Truck Fuel Book — "Night Haul" theme
   Self-hosted fonts, dark asphalt + amber diesel-gauge accent.
   ========================================================================== */

@font-face {
  font-family: "Barlow";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/barlow-400.woff2") format("woff2");
}

@font-face {
  font-family: "Barlow";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/barlow-600.woff2") format("woff2");
}

@font-face {
  font-family: "Barlow Condensed";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/barlow-condensed-600.woff2") format("woff2");
}

@font-face {
  font-family: "Barlow Condensed";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/assets/fonts/barlow-condensed-700.woff2") format("woff2");
}

:root {
  --bg: #0a1220;
  --bg-deep: #070d17;
  --surface: #101b2d;
  --surface-raised: #142238;
  --card: #0e1929;
  --line: rgba(148, 176, 214, 0.14);
  --line-strong: rgba(148, 176, 214, 0.3);
  --text: #f2f6fc;
  --muted: #a7b9d0;
  --faint: #7a8ea8;
  --amber: #ffb454;
  --amber-deep: #e8940f;
  --amber-glow: rgba(255, 180, 84, 0.14);
  --blue: #6fb3ff;
  --shadow: 0 18px 48px rgba(2, 6, 14, 0.5);
  --radius-lg: 20px;
  --radius-md: 14px;
  --radius-sm: 10px;
  --content: 1080px;
  --font-body: "Barlow", "Segoe UI", "Helvetica Neue", sans-serif;
  --font-display: "Barlow Condensed", "Arial Narrow", "Barlow", sans-serif;
}

* {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(ellipse 90% 40% at 50% -5%, rgba(31, 61, 105, 0.55), transparent),
    radial-gradient(circle at 88% 12%, var(--amber-glow), transparent 26%),
    linear-gradient(180deg, var(--bg-deep) 0%, var(--bg) 40%, #0b1524 100%);
  background-attachment: fixed;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  overflow-x: hidden;
  overflow-wrap: break-word;
}

::selection {
  background: var(--amber);
  color: #1a1002;
}

a {
  color: var(--blue);
  text-decoration: none;
}

a:hover {
  color: #a8d0ff;
}

:focus-visible {
  outline: 2px solid var(--amber);
  outline-offset: 3px;
  border-radius: 4px;
}

/* --------------------------------------------------------------------------
   Shell + header
   -------------------------------------------------------------------------- */

.site-shell {
  position: relative;
  z-index: 1;
  width: min(calc(100% - 32px), var(--content));
  margin: 0 auto;
  padding: 20px 0 48px;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px 20px;
  padding: 12px 0 18px;
  margin-bottom: 26px;
  border-bottom: 1px solid var(--line);
  position: relative;
}

/* highway lane marking under the header */
.site-header::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 100%;
  height: 3px;
  background-image: linear-gradient(90deg, var(--amber) 0 34px, transparent 34px 58px);
  background-size: 58px 3px;
  opacity: 0.55;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--text);
  min-width: 0;
}

.brand:hover {
  color: var(--text);
}

.brand-mark {
  flex: none;
  width: 46px;
  height: 46px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 14px rgba(2, 6, 14, 0.6);
}

.brand-logo {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
}

.brand-text strong {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.35rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
}

.brand-text small {
  color: var(--faint);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.site-nav a {
  padding: 9px 15px;
  border-radius: 999px;
  color: var(--muted);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.02rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  border: 1px solid transparent;
  transition: color 160ms ease, background 160ms ease, border-color 160ms ease;
}

.site-nav a:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.05);
}

.site-nav a.is-active {
  color: #ffd394;
  border-color: rgba(255, 180, 84, 0.4);
  background: var(--amber-glow);
}

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

main {
  display: grid;
  gap: 22px;
}

.hero-card {
  display: grid;
  grid-template-columns: 1.6fr 0.9fr;
  gap: 30px;
  padding: 40px 38px 42px;
  background: linear-gradient(160deg, var(--surface-raised) 0%, var(--surface) 55%, #0d1828 100%);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}

/* gauge tick marks in the hero corner */
.hero-card::before {
  content: "";
  position: absolute;
  top: -70px;
  right: -70px;
  width: 240px;
  height: 240px;
  border-radius: 50%;
  border: 2px dashed rgba(255, 180, 84, 0.18);
  pointer-events: none;
}

.hero-card::after {
  content: "";
  position: absolute;
  top: -40px;
  right: -40px;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  border: 1px solid rgba(148, 176, 214, 0.12);
  pointer-events: none;
}

.hero-card.compact {
  grid-template-columns: 1fr;
  padding: 32px 34px;
}

.eyebrow {
  margin: 0 0 14px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--amber);
  font-family: var(--font-display);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  font-size: 0.92rem;
}

.eyebrow::before {
  content: "";
  width: 26px;
  height: 2px;
  background: var(--amber);
}

.hero-copy h1 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.1rem, 5.2vw, 3.6rem);
  line-height: 1.04;
  letter-spacing: 0.005em;
  text-transform: uppercase;
  text-wrap: balance;
}

.hero-copy h1 em {
  font-style: normal;
  color: var(--amber);
}

.hero-text {
  margin: 18px 0 0;
  max-width: 62ch;
  color: var(--muted);
  font-size: 1.08rem;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 12px 22px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line-strong);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: transform 140ms ease, filter 140ms ease, border-color 140ms ease, background 140ms ease;
}

.button:active {
  transform: translateY(1px);
}

.button-primary {
  color: #221302;
  background: linear-gradient(160deg, #ffc46f, var(--amber) 45%, var(--amber-deep));
  border-color: transparent;
  box-shadow: 0 8px 22px rgba(232, 148, 15, 0.28);
}

.button-primary:hover {
  color: #221302;
  filter: brightness(1.07);
}

.button-secondary {
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
}

.button-secondary:hover {
  color: var(--text);
  border-color: var(--amber);
  background: rgba(255, 180, 84, 0.08);
}

/* --------------------------------------------------------------------------
   Voice input promotion
   -------------------------------------------------------------------------- */

.voice-promo {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 26px;
  padding: 30px 34px;
  background:
    radial-gradient(circle at 8% 50%, rgba(111, 179, 255, 0.16), transparent 26%),
    linear-gradient(120deg, rgba(255, 180, 84, 0.12), transparent 62%),
    var(--surface);
  border: 1px solid rgba(255, 180, 84, 0.32);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

.voice-promo-icon {
  width: 92px;
  height: 92px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #0a4fa8;
  border: 4px solid #ff9800;
  box-shadow: 0 16px 32px rgba(2, 6, 14, 0.42);
}

.voice-promo-icon img {
  display: block;
  width: 54%;
  height: 54%;
}

.voice-promo .eyebrow {
  margin-bottom: 8px;
}

.voice-promo h2 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1;
  letter-spacing: 0.01em;
  text-transform: uppercase;
}

.voice-promo p:not(.eyebrow) {
  max-width: 76ch;
  margin: 12px 0 0;
  color: var(--muted);
}

.voice-promo-points {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.voice-promo-points span {
  padding: 7px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.035);
  color: #dbe9fa;
  font-size: 0.9rem;
  line-height: 1.35;
}

/* spec-sheet panel */
.hero-panel {
  display: grid;
  gap: 0;
  align-content: start;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  overflow: hidden;
  align-self: start;
}

.hero-stat {
  padding: 16px 20px;
}

.hero-stat + .hero-stat {
  border-top: 1px dashed var(--line-strong);
}

.hero-stat span {
  display: block;
  color: var(--faint);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.82rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  margin-bottom: 4px;
}

.hero-stat strong {
  display: block;
  font-size: 1.04rem;
  line-height: 1.4;
}

/* --------------------------------------------------------------------------
   Cards
   -------------------------------------------------------------------------- */

.content-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.info-card {
  padding: 26px 24px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  border-top: 3px solid rgba(255, 180, 84, 0.5);
}

.info-card h2 {
  margin: 0 0 14px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.45rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.info-card p {
  color: var(--muted);
  margin: 0 0 8px;
}

.feature-list {
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--muted);
}

.feature-list li {
  position: relative;
  padding-left: 24px;
}

.feature-list li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 0.62em;
  width: 12px;
  height: 2px;
  background: var(--amber);
}

.feature-list li + li {
  margin-top: 10px;
}

.stack-links {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  margin-top: 14px;
}

.stack-links a {
  padding: 8px 0;
  font-weight: 600;
}

.cta-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 32px 34px;
  background:
    linear-gradient(120deg, rgba(255, 180, 84, 0.1), transparent 55%),
    var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

.cta-card h2 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.7rem, 3.4vw, 2.4rem);
  line-height: 1.08;
  letter-spacing: 0.01em;
  text-transform: uppercase;
}

.cta-card p {
  color: var(--muted);
  margin: 12px 0 0;
  max-width: 60ch;
}

.cta-card .button {
  flex: none;
}

/* --------------------------------------------------------------------------
   Legal pages (privacy / terms) — readability first
   -------------------------------------------------------------------------- */

.legal-content {
  padding: 34px 38px 40px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

.legal-content > p,
.legal-content > ul {
  max-width: 72ch;
}

.legal-content p {
  margin: 0 0 16px;
  color: var(--muted);
  line-height: 1.75;
}

.legal-content h2 {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin: 36px 0 14px;
  padding-top: 26px;
  border-top: 1px dashed var(--line-strong);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.5rem;
  letter-spacing: 0.03em;
  line-height: 1.2;
  text-transform: uppercase;
  color: var(--text);
}

.legal-content h2:first-of-type {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

.legal-content h2 .sec-num {
  flex: none;
  color: var(--amber);
  font-size: 0.95em;
}

.legal-list {
  margin: 0 0 16px;
  padding: 0;
}

.legal-list li {
  line-height: 1.7;
}

.legal-list strong {
  color: var(--text);
}

.updated-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 16px 0 0;
  padding: 7px 14px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.03);
  color: var(--muted);
  font-size: 0.9rem;
}

.updated-chip::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--amber);
}

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

.faq-content {
  padding: 22px;
}

.faq-content details {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  transition: border-color 160ms ease;
}

.faq-content details + details {
  margin-top: 12px;
}

.faq-content details[open] {
  border-color: rgba(255, 180, 84, 0.45);
}

.faq-content summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 16px 18px;
  font-weight: 600;
  font-size: 1.06rem;
  line-height: 1.45;
  -webkit-tap-highlight-color: transparent;
}

.faq-content summary::-webkit-details-marker {
  display: none;
}

.faq-content summary::after {
  content: "+";
  flex: none;
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  color: var(--amber);
  font-family: var(--font-display);
  font-size: 1.25rem;
  line-height: 1;
  transition: transform 180ms ease;
}

.faq-content details[open] summary::after {
  transform: rotate(45deg);
  border-color: rgba(255, 180, 84, 0.5);
}

.faq-content details p {
  margin: 0;
  padding: 0 18px 18px;
  color: var(--muted);
  line-height: 1.7;
  max-width: 72ch;
}

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

.site-footer {
  margin-top: 26px;
  padding: 26px 4px 0;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px 24px;
  flex-wrap: wrap;
  border-top: 1px solid var(--line);
  position: relative;
}

.site-footer::before {
  content: "";
  position: absolute;
  left: 0;
  top: -2px;
  width: 100%;
  height: 3px;
  background-image: linear-gradient(90deg, var(--amber) 0 34px, transparent 34px 58px);
  background-size: 58px 3px;
  opacity: 0.35;
}

.site-footer strong {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.site-footer p {
  margin: 6px 0 0;
  color: var(--faint);
  font-size: 0.95rem;
  max-width: 46ch;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 8px;
  justify-content: flex-end;
}

.footer-links a {
  padding: 8px 10px;
  color: var(--muted);
  border-radius: var(--radius-sm);
}

.footer-links a:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.05);
}

/* --------------------------------------------------------------------------
   Motion — one staggered page-load reveal
   -------------------------------------------------------------------------- */

@media (prefers-reduced-motion: no-preference) {
  main > * {
    animation: rise-in 560ms cubic-bezier(0.2, 0.7, 0.3, 1) both;
  }

  main > *:nth-child(2) { animation-delay: 90ms; }
  main > *:nth-child(3) { animation-delay: 180ms; }
  main > *:nth-child(4) { animation-delay: 270ms; }

  @keyframes rise-in {
    from {
      opacity: 0;
      transform: translateY(14px);
    }
    to {
      opacity: 1;
      transform: none;
    }
  }
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */

@media (max-width: 900px) {
  .hero-card {
    grid-template-columns: 1fr;
    padding: 30px 26px;
  }

  .content-grid {
    grid-template-columns: 1fr;
  }

  .cta-card {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 640px) {
  body {
    font-size: 1rem;
    background-attachment: scroll;
  }

  .site-shell {
    width: min(calc(100% - 24px), var(--content));
    padding-top: 12px;
  }

  .site-header {
    padding-bottom: 14px;
    margin-bottom: 20px;
  }

  .brand-mark {
    width: 40px;
    height: 40px;
  }

  .brand-text strong {
    font-size: 1.2rem;
  }

  .site-nav {
    width: 100%;
    gap: 4px;
  }

  .site-nav a {
    padding: 9px 12px;
    font-size: 0.98rem;
  }

  .hero-card,
  .hero-card.compact {
    padding: 24px 18px 26px;
  }

  .hero-text {
    font-size: 1.02rem;
  }

  .hero-actions .button {
    flex: 1 1 auto;
  }

  .voice-promo {
    grid-template-columns: 1fr;
    padding: 24px 18px;
  }

  .voice-promo-icon {
    width: 76px;
    height: 76px;
    border-width: 4px;
  }

  .info-card {
    padding: 22px 18px;
  }

  .legal-content {
    padding: 22px 18px 28px;
  }

  .legal-content h2 {
    font-size: 1.32rem;
    margin-top: 30px;
    padding-top: 22px;
  }

  .faq-content {
    padding: 14px;
  }

  .faq-content summary {
    padding: 15px 14px;
    font-size: 1.02rem;
  }

  .faq-content details p {
    padding: 0 14px 16px;
  }

  .cta-card {
    padding: 24px 18px;
  }

  .cta-card .button {
    width: 100%;
  }

  .footer-links {
    justify-content: flex-start;
    width: 100%;
  }
}
