/* ==========================================================================
   BixLearn Website — Style Lock v1.0
   Design tokens transcribed from the Stitch design system export
   (stitch_bixlearn_marketing_homepage_design/bixlearn_style_lock_v1.0/DESIGN.md)

   Strictly flat: no shadows, no gradients, no glassmorphism.
   Depth comes from tonal layering + 1px hairline borders only.
   ========================================================================== */

/* ---------- Tokens ---------- */
:root {
  /* Surfaces */
  --surface: #f9f9f9;
  --surface-bright: #f9f9f9;
  --surface-dim: #dadad9;
  --surface-container-lowest: #ffffff;
  --surface-container-low: #f4f3f3;
  --surface-container: #eeeeed;
  --surface-container-high: #e8e8e8;
  --surface-container-highest: #e2e2e2;
  --surface-variant: #e2e2e2;
  --background: #f9f9f9;

  /* Ink */
  --on-surface: #1a1c1c;
  --on-surface-variant: #3e4949;
  --on-background: #1a1c1c;
  --inverse-surface: #2f3131;
  --inverse-on-surface: #f1f1f0;

  /* Lines */
  --outline: #6e7979;
  --outline-variant: #bdc9c8;

  /* Primary teal */
  --primary: #006565;
  --primary-container: #008080;
  --on-primary: #ffffff;
  --on-primary-container: #e3fffe;
  --surface-tint: #006a6a;
  --primary-fixed: #93f2f2;
  --primary-fixed-dim: #76d6d5;
  --on-primary-fixed: #002020;
  --on-primary-fixed-variant: #004f4f;

  /* Amber — Pro / achievement ONLY */
  --secondary: #795900;
  --secondary-container: #ffbf00;
  --secondary-fixed-dim: #fbbc00;
  --on-secondary-container: #6d5000;
  --on-secondary-fixed: #261a00;

  /* Tonal tints used by the design (Level 1 surfaces) */
  --tint-teal: #e6f2f2;
  --tint-teal-soft: #f7fbfb;
  --tint-amber: #fff8e6;
  --tint-amber-border: #ffe082;

  /* Error — genuine system failures only */
  --error: #ba1a1a;

  /* Spacing rhythm */
  --unit: 4px;
  --stack-sm: 8px;
  --stack-md: 16px;
  --gutter: 16px;
  --container-margin: 24px;
  --section-gap: 48px;

  /* Shape */
  --radius-sm: 0.25rem;
  --radius: 0.5rem;
  --radius-md: 0.75rem; /* 12px — containers & cards */
  --radius-lg: 1rem;
  --radius-xl: 1.5rem;
  --radius-full: 9999px;

  /* Layout */
  --content-max: 1200px;
  --measure: 800px;
}

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

* {
  box-shadow: none; /* Style Lock: flat tonal layering only */
}

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

body {
  margin: 0;
  background: var(--background);
  color: var(--on-background);
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size: 16px;
  line-height: 24px;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

h1, h2, h3, h4, p, ul, ol, figure, blockquote {
  margin: 0;
}

ul, ol {
  padding: 0;
}

a {
  color: inherit;
}

button {
  font-family: inherit;
  cursor: pointer;
}

::selection {
  background: var(--primary-fixed);
  color: var(--on-primary-fixed);
}

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

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
}

/* ---------- Type scale ---------- */
.headline-lg {
  font-size: 30px;
  line-height: 36px;
  font-weight: 700;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

@media (min-width: 768px) {
  .headline-lg {
    font-size: 40px;
    line-height: 48px;
    letter-spacing: -0.02em;
  }
}

.headline-md {
  font-size: 24px;
  line-height: 32px;
  font-weight: 600;
  text-wrap: balance;
}

.body-lg {
  font-size: 18px;
  line-height: 28px;
  font-weight: 400;
}

.body-md {
  font-size: 16px;
  line-height: 24px;
  font-weight: 400;
}

.label-md {
  font-size: 14px;
  line-height: 20px;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.label-sm {
  font-size: 12px;
  line-height: 16px;
  font-weight: 700;
  letter-spacing: 0.05em;
}

.eyebrow {
  font-size: 12px;
  line-height: 16px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--primary);
}

.muted {
  color: var(--on-surface-variant);
}

/* ---------- Layout ---------- */
.container {
  max-width: var(--content-max);
  margin-inline: auto;
  padding-inline: var(--container-margin);
}

.section {
  padding-block: 80px;
}

@media (max-width: 767px) {
  .section { padding-block: 56px; }
}

.section-tinted {
  background: var(--tint-teal-soft);
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--primary);
  color: var(--on-primary);
  padding: 12px 20px;
  border-radius: 0 0 var(--radius-md) 0;
  z-index: 100;
  font-size: 14px;
  font-weight: 600;
}

.skip-link:focus {
  left: 0;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  width: 100%;
  background: var(--surface);
  border-bottom: 1px solid var(--outline-variant);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--gutter);
  min-height: 80px;
  max-width: var(--content-max);
  margin-inline: auto;
  padding-inline: var(--container-margin);
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 24px;
  line-height: 32px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--primary);
  text-decoration: none;
}

/* The nav carries the legal pages, so it must never be hidden — below the
   desktop breakpoint it drops to its own full-width row rather than
   disappearing behind a menu the Privacy Policy would be buried in. */
.nav {
  display: flex;
  gap: 32px;
  align-items: center;
}

.nav a {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: var(--on-surface-variant);
  text-decoration: none;
  white-space: nowrap;
  padding-block: 4px;
  border-bottom: 2px solid transparent;
  transition: color 0.15s ease, border-color 0.15s ease;
}

.nav a:hover {
  color: var(--primary);
}

.nav a[aria-current="page"] {
  color: var(--primary);
  font-weight: 700;
  border-bottom-color: var(--primary);
}

@media (max-width: 899px) {
  .site-header__inner {
    padding-block: 12px;
    min-height: 0;
  }

  .nav {
    order: 3;
    width: 100%;
    gap: 24px;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  .nav::-webkit-scrollbar {
    display: none;
  }
}

.header-actions {
  display: flex;
  align-items: center;
  gap: var(--gutter);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: var(--radius-full);
  font-size: 14px;
  line-height: 20px;
  font-weight: 600;
  letter-spacing: 0.01em;
  padding: 12px 24px;
  text-decoration: none;
  border: 1px solid transparent;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
  white-space: nowrap;
}

.btn-primary {
  background: var(--primary);
  color: var(--on-primary);
}

.btn-primary:hover {
  background: var(--surface-tint);
}

.btn-outline {
  background: transparent;
  color: var(--primary);
  border-color: var(--primary);
}

.btn-outline:hover {
  background: var(--tint-teal);
}



.btn-lg {
  padding: 16px 32px;
}

.btn-sm {
  padding: 9px 18px;
}

/* ---------- Hero ---------- */
.hero {
  display: grid;
  gap: 64px;
  align-items: center;
  padding-block: 96px;
}

@media (min-width: 900px) {
  .hero {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 899px) {
  .hero { padding-block: 56px; }
}

.hero__copy {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.hero h1 {
  margin-block: 16px 24px;
  color: var(--on-surface);
}

.hero__lede {
  color: var(--on-surface-variant);
  max-width: 52ch;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

/* Bix mascot artwork. Deliberate Style Lock exception (agreed 14 Aug 2026) —
   the source render carries soft shading and drop shadows the rest of the
   system forbids; a plain frame is the only "flat" thing left to control. */
.hero__art {
  display: block;
  border: 1px solid var(--surface-container-high);
  border-radius: var(--radius-md);
  overflow: hidden;
  line-height: 0;
}

.hero__art img {
  display: block;
  width: 100%;
  height: auto;
}


/* ---------- Section heads ---------- */
.section-head {
  margin-bottom: 64px;
}

.section-head--center {
  text-align: center;
  max-width: 640px;
  margin-inline: auto;
}

.section-head h2 {
  margin-top: 16px;
  color: var(--on-surface);
}

.section-head p {
  margin-top: 12px;
  color: var(--on-surface-variant);
}

/* ---------- Cards ---------- */
/* Six cards, so cap at three columns: auto-fit alone yields a 4 + 2 orphan row. */
.card-grid {
  display: grid;
  gap: 24px;
  grid-template-columns: 1fr;
}

@media (min-width: 640px) {
  .card-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 1000px) {
  .card-grid { grid-template-columns: repeat(3, 1fr); }
}

.card {
  background: var(--surface);
  border: 1px solid var(--surface-container-high);
  border-radius: var(--radius-md);
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.card__icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-full);
  background: var(--tint-teal);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  flex: none;
}

.card h3 {
  font-size: 16px;
  line-height: 24px;
  font-weight: 700;
  color: var(--on-surface);
}

.card p {
  color: var(--on-surface-variant);
  font-size: 16px;
  line-height: 24px;
}

/* The single amber moment in the features grid — Pro entitlement, per Style Lock. */
.tier-tag {
  display: inline-block;
  margin-left: 6px;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  background: var(--tint-amber);
  border: 1px solid var(--tint-amber-border);
  color: var(--secondary);
  font-size: 11px;
  line-height: 16px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  vertical-align: middle;
}

/* ---------- Steps ---------- */
.steps {
  display: grid;
  gap: 48px;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.step__num {
  font-size: 40px;
  line-height: 48px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--primary-fixed-dim);
  display: block;
  margin-bottom: 16px;
  font-variant-numeric: tabular-nums;
}

.step h3 {
  font-size: 18px;
  line-height: 28px;
  font-weight: 600;
  color: var(--on-surface);
  margin-bottom: 8px;
}

.step p {
  color: var(--on-surface-variant);
}






/* ---------- About ---------- */
.about-grid {
  display: grid;
  gap: 64px;
}

@media (min-width: 900px) {
  .about-grid { grid-template-columns: 1fr 1fr; }
}

.about-grid p {
  color: var(--on-surface-variant);
}

.pull-quote {
  font-size: 18px;
  line-height: 28px;
  font-style: italic;
  color: var(--on-surface);
  border-left: 2px solid var(--primary);
  padding-left: 24px;
}

/* ---------- Legal pages ---------- */
.legal-intro {
  max-width: var(--measure);
  padding-block: var(--section-gap);
}

.legal-intro h1 {
  margin-block: 8px 16px;
  color: var(--on-surface);
}

.legal-intro .byline {
  color: var(--on-surface-variant);
}

.legal-layout {
  display: grid;
  gap: var(--section-gap);
  align-items: start;
  padding-bottom: 80px;
}

@media (min-width: 1000px) {
  .legal-layout {
    grid-template-columns: 280px 1fr;
  }
}

.toc {
  display: none;
}

@media (min-width: 1000px) {
  .toc {
    display: block;
    position: sticky;
    top: 112px;
    align-self: start;
  }
}

.toc__label {
  font-size: 12px;
  line-height: 16px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--on-surface-variant);
  margin-bottom: 16px;
}

.toc ol {
  list-style: none;
  margin: 0;
  padding: 0;
  border-left: 2px solid var(--surface-variant);
  max-height: calc(100vh - 200px);
  overflow-y: auto;
}

.toc li a {
  display: flex;
  gap: 10px;
  padding: 6px 0 6px 16px;
  font-size: 14px;
  line-height: 20px;
  color: var(--on-surface-variant);
  text-decoration: none;
  transition: color 0.15s ease;
}

.toc li a:hover {
  color: var(--primary);
}

.toc li a.is-active {
  color: var(--primary);
  font-weight: 700;
}

.toc li a .n {
  color: var(--outline-variant);
  font-variant-numeric: tabular-nums;
  min-width: 18px;
  text-align: right;
  flex: none;
}

.legal-body {
  max-width: var(--measure);
  display: flex;
  flex-direction: column;
  gap: var(--section-gap);
}

.legal-body section {
  scroll-margin-top: 112px;
}

.legal-body h2 {
  display: flex;
  gap: 12px;
  font-size: 24px;
  line-height: 32px;
  font-weight: 600;
  color: var(--on-surface);
  margin-bottom: 16px;
}

.legal-body h2 .n {
  color: var(--outline-variant);
  font-variant-numeric: tabular-nums;
}

.legal-body h3 {
  font-size: 16px;
  line-height: 24px;
  font-weight: 700;
  color: var(--on-surface);
  margin-block: 20px 8px;
}

.legal-body p {
  color: var(--on-surface-variant);
  margin-bottom: 16px;
}

.legal-body p:last-child {
  margin-bottom: 0;
}

.legal-body ul {
  list-style: disc;
  padding-left: 24px;
  margin-bottom: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.legal-body li {
  color: var(--on-surface-variant);
}

.legal-body strong {
  color: var(--on-surface);
  font-weight: 700;
}

.legal-body a:not(.btn) {
  color: var(--primary);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.callout {
  background: var(--tint-teal);
  border-left: 4px solid var(--primary);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  padding: 16px 20px;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  margin-top: 8px;
}

.callout svg {
  color: var(--primary);
  flex: none;
  margin-top: 2px;
}

.callout p {
  color: var(--on-surface);
  margin: 0;
  font-size: 16px;
  line-height: 24px;
}

.contact-block {
  color: var(--on-surface-variant);
  line-height: 28px;
}

.contact-block strong {
  color: var(--on-surface);
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--surface-container-low);
  border-top: 1px solid var(--outline-variant);
  margin-top: var(--section-gap);
}

.site-footer__grid {
  display: grid;
  gap: 32px;
  padding-block: var(--section-gap);
  grid-template-columns: 1fr;
}

@media (min-width: 700px) {
  .site-footer__grid {
    grid-template-columns: 1.6fr repeat(3, 1fr);
  }
}

.site-footer h3 {
  font-size: 12px;
  line-height: 16px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--on-surface-variant);
  margin-bottom: 16px;
}

.site-footer ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.site-footer a {
  font-size: 16px;
  line-height: 24px;
  color: var(--on-surface-variant);
  text-decoration: none;
  transition: color 0.15s ease;
}

.site-footer a:hover {
  color: var(--primary);
}

.site-footer__tagline {
  color: var(--on-surface-variant);
  margin-top: 16px;
  max-width: 30ch;
}

.site-footer__bottom {
  border-top: 1px solid var(--outline-variant);
  padding-block: 24px 32px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: space-between;
  font-size: 14px;
  line-height: 20px;
  color: var(--on-surface-variant);
}

/* ---------- Utilities ---------- */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
