/* ==========================================================================
   TekuCredit — design tokens
   Palette: Graphite & Gold
   Every value the rest of the CSS uses is declared here. Change a brand
   decision in this file and nowhere else.
   ========================================================================== */

:root {
  /* --- Brand ------------------------------------------------------------
     --gold is the FUNCTIONAL accent: it clears 4.5:1 against white, so it is
     safe for buttons, links and body-size text.
     --gold-tint is DECORATIVE ONLY (3.84:1). Use it for large display type,
     rules, borders and washes — never for text under 24px / 19px bold.     */
  --graphite:      #1C1F24;
  --graphite-deep: #101216;
  --gold:          #8A6120;
  --gold-tint:     #A9792F;
  --gold-soft:     #F5EDDF;
  --support:       #2E5A86;

  /* --- Neutral ramp (9 steps) ------------------------------------------
     n-600 is the lightest step still safe for text on white (4.93:1).      */
  --n-100: #FAFAFA;
  --n-200: #F1F2F3;
  --n-300: #E2E4E7;
  --n-400: #C9CDD2;
  --n-500: #A2A8AF;
  --n-600: #6B7178;
  --n-700: #51565D;
  --n-800: #31353A;
  --n-900: #17191C;

  --white: #FFFFFF;

  /* --- Semantic --------------------------------------------------------- */
  --success: #1E6F4C;
  --warning: #8A6120;
  --danger:  #A32A22;
  --success-bg: #E8F3ED;
  --warning-bg: #FBF2E2;
  --danger-bg:  #FBEBE9;

  /* --- Applied roles ----------------------------------------------------
     Components reference these, not the raw palette above, so dark mode is
     a single block of overrides at the bottom of this file.                */
  --bg:            var(--white);
  --bg-sunken:     var(--n-100);
  --bg-raised:     var(--white);
  --bg-inverse:    var(--graphite);
  --text:          var(--graphite);
  --text-muted:    var(--n-700);
  --text-subtle:   var(--n-600);
  --text-inverse:  var(--white);
  --text-on-accent:var(--white);
  --border:        var(--n-300);
  --border-strong: var(--n-400);
  --link:          var(--gold);
  --link-hover:    var(--graphite);
  --focus:         var(--support);

  /* --- Type -------------------------------------------------------------
     Self-hosted faces are declared at the foot of this file. The stacks
     below fall back to system faces, so the site renders correctly even
     with assets/fonts/ empty — see README.                                 */
  --font-display: "Space Grotesk", ui-sans-serif, system-ui, -apple-system,
                  "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-body:    "Inter", ui-sans-serif, system-ui, -apple-system,
                  "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  /* Fluid scale, designed at 375px and allowed to grow to 1280px. */
  --step--1: clamp(0.82rem, 0.80rem + 0.10vw, 0.88rem);
  --step-0:  clamp(1.00rem, 0.97rem + 0.15vw, 1.06rem);
  --step-1:  clamp(1.15rem, 1.08rem + 0.32vw, 1.33rem);
  --step-2:  clamp(1.33rem, 1.20rem + 0.58vw, 1.66rem);
  --step-3:  clamp(1.53rem, 1.31rem + 0.96vw, 2.07rem);
  --step-4:  clamp(1.76rem, 1.40rem + 1.53vw, 2.59rem);
  --step-5:  clamp(2.03rem, 1.47rem + 2.36vw, 3.24rem);
  --step-6:  clamp(2.33rem, 1.48rem + 3.60vw, 4.05rem);

  --leading-tight: 1.12;
  --leading-snug:  1.30;
  --leading-body:  1.60;

  --tracking-tight: -0.022em;
  --tracking-snug:  -0.012em;
  --tracking-wide:   0.06em;

  --weight-regular: 400;
  --weight-medium:  500;
  --weight-bold:    700;

  /* --- Spacing (8pt) ----------------------------------------------------- */
  --space-1: 0.25rem;   /*  4px */
  --space-2: 0.5rem;    /*  8px */
  --space-3: 0.75rem;   /* 12px */
  --space-4: 1rem;      /* 16px */
  --space-5: 1.5rem;    /* 24px */
  --space-6: 2rem;      /* 32px */
  --space-7: 3rem;      /* 48px */
  --space-8: 4rem;      /* 64px */
  --space-9: 6rem;      /* 96px */
  --space-10: 8rem;     /* 128px */

  /* Vertical rhythm between page sections, tighter on small screens. */
  --section-y: clamp(3rem, 2rem + 5vw, 6rem);

  /* --- Layout ------------------------------------------------------------ */
  --measure: 68ch;          /* comfortable reading width */
  --measure-tight: 46ch;    /* headings and intros */
  --container: 1120px;
  --container-narrow: 760px;
  --gutter: clamp(1rem, 0.5rem + 2.5vw, 2rem);
  --grid-columns: 12;
  --grid-gap: clamp(1rem, 0.6rem + 1.6vw, 2rem);
  --tap-min: 44px;          /* minimum tap target */

  /* --- Radii ------------------------------------------------------------- */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 14px;
  --radius-pill: 999px;

  /* --- Elevation ---------------------------------------------------------
     Restrained on purpose: borders carry most of the separation.           */
  --shadow-sm: 0 1px 2px rgb(23 25 28 / 0.06);
  --shadow-md: 0 2px 4px rgb(23 25 28 / 0.06), 0 8px 20px rgb(23 25 28 / 0.06);
  --shadow-lg: 0 4px 8px rgb(23 25 28 / 0.07), 0 20px 40px rgb(23 25 28 / 0.09);

  /* --- Motion ------------------------------------------------------------ */
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --dur-fast: 120ms;
  --dur-mid:  220ms;
  --dur-slow: 420ms;

  /* --- Focus ------------------------------------------------------------- */
  --focus-width: 3px;
  --focus-offset: 2px;

  /* --- Z-index ----------------------------------------------------------- */
  --z-header: 100;
  --z-menu:   200;
  --z-banner: 300;
}

/* ==========================================================================
   Dark mode — opt-in via prefers-color-scheme, roles only.
   The gold is lifted to --gold-tint here: on a dark surface it reaches
   6.95:1, so it becomes safe for text, which it is not on white.
   ========================================================================== */
@media (prefers-color-scheme: dark) {
  :root {
    --bg:            #14161A;
    --bg-sunken:     #101216;
    --bg-raised:     #1C1F24;
    --bg-inverse:    #F1F2F3;
    --text:          #ECEEF0;
    --text-muted:    #B4BAC1;
    --text-subtle:   #949BA3;
    --text-inverse:  #14161A;
    --text-on-accent:#14161A;
    --border:        #2C3037;
    --border-strong: #3D434B;
    --link:          #C9973F;
    --link-hover:    #E4B96B;
    --focus:         #7FB2E5;

    --gold:      #C9973F;
    --gold-tint: #E4B96B;
    --gold-soft: #241D10;
    --support:   #7FB2E5;

    --success: #4FBF8B;
    --warning: #D9A441;
    --danger:  #E8776C;
    --success-bg: #14251E;
    --warning-bg: #241D10;
    --danger-bg:  #2A1614;

    --shadow-sm: 0 1px 2px rgb(0 0 0 / 0.4);
    --shadow-md: 0 2px 4px rgb(0 0 0 / 0.4), 0 8px 20px rgb(0 0 0 / 0.35);
    --shadow-lg: 0 4px 8px rgb(0 0 0 / 0.45), 0 20px 40px rgb(0 0 0 / 0.4);
  }
}

/* ==========================================================================
   Self-hosted faces.
   Drop the .woff2 files listed in the README into assets/fonts/ and these
   activate. Until then the system stack in --font-display / --font-body
   renders the site with no layout shift and no network request.
   ========================================================================== */

@font-face {
  font-family: "Space Grotesk";
  src: url("../assets/fonts/space-grotesk-variable.woff2") format("woff2-variations");
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Inter";
  src: url("../assets/fonts/inter-variable.woff2") format("woff2-variations");
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}
/* ==========================================================================
   TekuCredit — reset, typography, bare elements
   ========================================================================== */

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

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

body, h1, h2, h3, h4, p, figure, blockquote, dl, dd, ul, ol, fieldset, legend {
  margin: 0;
  padding: 0;
}

ul[role="list"], ol[role="list"] { list-style: none; }

body {
  min-height: 100svh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: var(--step-0);
  font-weight: var(--weight-regular);
  line-height: var(--leading-body);
  font-feature-settings: "kern" 1;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* --- Headings ------------------------------------------------------------ */

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: var(--weight-bold);
  line-height: var(--leading-tight);
  letter-spacing: var(--tracking-tight);
  text-wrap: balance;
  color: var(--text);
}

h1 { font-size: var(--step-6); }
h2 { font-size: var(--step-4); }
h3 { font-size: var(--step-2); letter-spacing: var(--tracking-snug); }
h4 { font-size: var(--step-1); letter-spacing: var(--tracking-snug); }

p { text-wrap: pretty; }

/* --- Links --------------------------------------------------------------- */

a {
  color: var(--link);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;

  &:hover { color: var(--link-hover); }
}

/* --- Numerals ------------------------------------------------------------
   Any figure anywhere on this site is tabular, so columns of cedi amounts
   line up and digits never jitter between states.                          */

.tabular,
time,
[data-amount],
table td, table th {
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
}

/* --- Media ---------------------------------------------------------------- */

img, picture, svg, video {
  display: block;
  max-width: 100%;
}

img, video { height: auto; }

svg { fill: currentColor; }

/* --- Forms inherit type --------------------------------------------------- */

input, button, textarea, select {
  font: inherit;
  color: inherit;
}

/* --- Focus ---------------------------------------------------------------
   One visible ring everywhere. Never remove it without replacing it.      */

:focus-visible {
  outline: var(--focus-width) solid var(--focus);
  outline-offset: var(--focus-offset);
  border-radius: var(--radius-sm);
}

/* --- Selection ------------------------------------------------------------ */

::selection {
  background: var(--gold-tint);
  color: var(--white);
}

/* --- Skip link ------------------------------------------------------------ */

.skip-link {
  position: absolute;
  left: var(--space-4);
  top: var(--space-4);
  z-index: calc(var(--z-banner) + 1);
  padding: var(--space-3) var(--space-4);
  background: var(--graphite);
  color: var(--white);
  font-weight: var(--weight-medium);
  text-decoration: none;
  border-radius: var(--radius-md);
  transform: translateY(-200%);
  transition: transform var(--dur-fast) var(--ease);

  &:focus { transform: translateY(0); }
}

/* --- Address / small print ------------------------------------------------ */

address {
  font-style: normal;
}

hr {
  border: 0;
  border-top: 1px solid var(--border);
  margin: var(--space-7) 0;
}

/* --- Reduced motion -------------------------------------------------------
   Honour the preference completely: no transitions, no scroll animation,
   no entrance fades.                                                       */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
/* ==========================================================================
   TekuCredit — containers, grid, header, footer
   Designed at 375px first; the breakpoints below only ever add.
   ========================================================================== */

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

.container--narrow { max-width: var(--container-narrow); }

.measure { max-width: var(--measure); }
.measure-tight { max-width: var(--measure-tight); }

/* --- 12-column grid, single column below 768px --------------------------- */

.grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--grid-gap);
}

@media (min-width: 768px) {
  .grid { grid-template-columns: repeat(var(--grid-columns), minmax(0, 1fr)); }
  .col-4 { grid-column: span 4; }
  .col-6 { grid-column: span 6; }
  .col-7 { grid-column: span 7; }
  .col-8 { grid-column: span 8; }
  .col-12 { grid-column: span 12; }
}

/* --- Sections ------------------------------------------------------------- */

.section {
  padding-block: var(--section-y);
}

.section--sunken {
  background: var(--bg-sunken);
  border-block: 1px solid var(--border);
}

.section--inverse {
  background: var(--bg-inverse);
  color: var(--text-inverse);

  & h2, & h3 { color: var(--text-inverse); }
  & a { color: var(--gold-tint); }
  & a:hover { color: var(--white); }
}

.section__title {
  margin-block: var(--space-3) var(--space-5);
  max-width: 20ch;
}

.section__lede {
  max-width: var(--measure);
  font-size: var(--step-1);
  color: var(--text-muted);
  margin-bottom: var(--space-6);
}

.section--inverse .section__lede { color: var(--n-400); }

.eyebrow {
  font-family: var(--font-display);
  font-size: var(--step--1);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  color: var(--gold);
}

.section--inverse .eyebrow { color: var(--gold-tint); }

.prose > * + * { margin-top: var(--space-4); }
.prose { color: var(--text-muted); }

/* --- Split layout (principles + "what we won't do") ---------------------- */

.split {
  display: grid;
  gap: var(--space-7);
  grid-template-columns: 1fr;
}

@media (min-width: 900px) {
  .split { grid-template-columns: 1.1fr 0.9fr; gap: var(--space-8); }
}

/* ==========================================================================
   Header
   ========================================================================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: var(--z-header);
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}

.site-header__inner {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  min-height: 68px;
}

.brand {
  display: inline-flex;
  align-items: center;
  color: var(--text);
  text-decoration: none;
  flex: none;
  /* keeps the tap target at 44px without inflating the visual logo */
  padding-block: var(--space-2);
}

.brand__logo {
  width: 168px;
  height: auto;
}

/* --- Navigation: the no-JS baseline is a visible link row ---------------- */

.site-nav {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: var(--space-5);
}

.site-nav__list {
  display: flex;
  align-items: center;
  gap: var(--space-5);
  list-style: none;
  flex-wrap: wrap;
}

.site-nav__list a {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap-min);
  color: var(--text);
  text-decoration: none;
  font-weight: var(--weight-medium);

  &:hover { color: var(--gold); }

  &[aria-current="page"] {
    color: var(--gold);
    box-shadow: inset 0 -2px 0 var(--gold);
  }
}

.nav-toggle {
  display: none;
}

/* --- Small screens ------------------------------------------------------- */

@media (max-width: 899px) {
  /* Without JS the toggle stays [hidden] and the nav simply wraps below the
     logo as a plain, fully usable list. JS removes [hidden] and adds
     .site-nav--collapsible, which is what turns it into a panel.           */

  .site-header__inner {
    flex-wrap: wrap;
    row-gap: var(--space-2);
    padding-block: var(--space-2);
  }

  .site-nav {
    margin-left: 0;
    width: 100%;
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-1);
  }

  .site-nav__list {
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    gap: 0;
  }

  .site-nav__list a {
    width: 100%;
    padding-block: var(--space-2);
    border-bottom: 1px solid var(--border);
  }

  .site-nav__cta {
    width: 100%;
    margin-top: var(--space-3);
    margin-bottom: var(--space-2);
  }

  .nav-toggle:not([hidden]) {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    margin-left: auto;
    min-height: var(--tap-min);
    min-width: var(--tap-min);
    padding: var(--space-2) var(--space-3);
    background: transparent;
    border: 1px solid var(--border-strong);
    border-radius: var(--radius-md);
    color: var(--text);
    font-family: var(--font-display);
    font-weight: var(--weight-medium);
    cursor: pointer;
  }

  .nav-toggle__bars {
    position: relative;
    width: 18px;
    height: 2px;
    background: currentColor;
    transition: background var(--dur-fast) var(--ease);

    &::before, &::after {
      content: "";
      position: absolute;
      left: 0;
      width: 18px;
      height: 2px;
      background: currentColor;
      transition: transform var(--dur-fast) var(--ease);
    }
    &::before { top: -6px; }
    &::after  { top: 6px; }
  }

  .nav-toggle[aria-expanded="true"] .nav-toggle__bars {
    background: transparent;

    &::before { transform: translateY(6px) rotate(45deg); }
    &::after  { transform: translateY(-6px) rotate(-45deg); }
  }

  /* Applied by JS only. Collapsed by default once JS is in charge. */
  .site-nav--collapsible {
    display: none;
  }

  .site-nav--collapsible.is-open {
    display: flex;
  }
}

/* Body scroll lock while the mobile panel is open. */
body.has-open-nav {
  overflow: hidden;
}

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer {
  background: var(--bg-inverse);
  color: var(--text-inverse);
  padding-block: var(--space-8) var(--space-6);
  margin-top: auto;
}

.site-footer__inner {
  display: grid;
  gap: var(--space-7);
  grid-template-columns: 1fr;
}

@media (min-width: 768px) {
  .site-footer__inner {
    grid-template-columns: 1fr 1.4fr;
    column-gap: var(--space-8);
  }
  .site-footer__legal { grid-column: 1 / -1; }
}

.site-footer__mark {
  width: 40px;
  height: 40px;
  color: var(--gold-tint);
  margin-bottom: var(--space-4);
}

.site-footer__line {
  max-width: 28ch;
  color: var(--n-400);
}

.site-footer__nav {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: var(--space-6);
}

.site-footer__heading {
  font-family: var(--font-display);
  font-size: var(--step--1);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  color: var(--n-500);
  margin-bottom: var(--space-3);
}

.site-footer__col ul {
  list-style: none;
  display: grid;
  gap: var(--space-1);
}

.site-footer__col a {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap-min);
  color: var(--n-200);
  text-decoration: none;

  &:hover { color: var(--gold-tint); text-decoration: underline; }
}

.site-footer__legal {
  border-top: 1px solid var(--n-800);
  padding-top: var(--space-6);
  display: grid;
  gap: var(--space-4);
  font-size: var(--step--1);
  color: var(--n-500);
}

@media (min-width: 768px) {
  .site-footer__legal {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  }
}

.site-footer__registration {
  color: var(--n-300);
  font-weight: var(--weight-medium);
}

.site-footer__address a {
  color: var(--gold-tint);
}

/* Dark mode already has a near-black page; keep the footer distinct. */
@media (prefers-color-scheme: dark) {
  .site-footer {
    background: var(--bg-sunken);
    color: var(--text);
    border-top: 1px solid var(--border);
  }
  .site-footer__col a { color: var(--text-muted); }
  .site-footer__legal { border-top-color: var(--border); }
  .site-footer__registration { color: var(--text-muted); }
  .section--inverse {
    background: var(--bg-raised);
    color: var(--text);
    border-block: 1px solid var(--border);
  }
  .section--inverse h2, .section--inverse h3 { color: var(--text); }
}
/* ==========================================================================
   TekuCredit — buttons, cards, forms, accordion, notices, cookie banner
   ========================================================================== */

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: var(--tap-min);
  padding: var(--space-3) var(--space-5);
  border: 1px solid transparent;
  border-radius: var(--radius-md);
  font-family: var(--font-display);
  font-size: var(--step-0);
  font-weight: var(--weight-medium);
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background var(--dur-fast) var(--ease),
              color var(--dur-fast) var(--ease),
              border-color var(--dur-fast) var(--ease);
}

.btn--sm { min-height: 40px; padding: var(--space-2) var(--space-4); font-size: var(--step--1); }
.btn--lg { padding: var(--space-4) var(--space-6); font-size: var(--step-1); }

.btn--primary {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--text-on-accent);

  &:hover { background: var(--graphite); border-color: var(--graphite); color: var(--white); }
}

.btn--secondary {
  background: var(--bg);
  border-color: var(--border-strong);
  color: var(--text);

  &:hover { border-color: var(--text); }
}

.btn--ghost {
  background: transparent;
  border-color: var(--border-strong);
  color: var(--text);

  &:hover { background: var(--n-200); border-color: var(--text); }
}

.section--inverse .btn--ghost {
  border-color: var(--n-700);
  color: var(--text-inverse);

  &:hover { background: var(--n-800); border-color: var(--n-500); }
}

.btn[disabled], .btn[aria-disabled="true"] {
  opacity: 0.55;
  cursor: not-allowed;
}

@media (prefers-color-scheme: dark) {
  .btn--primary { color: var(--graphite-deep); }
  .btn--primary:hover { background: var(--gold-tint); border-color: var(--gold-tint); color: var(--graphite-deep); }
  .btn--ghost:hover { background: var(--bg-raised); }
}

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

.cards {
  display: grid;
  gap: var(--grid-gap);
  grid-template-columns: 1fr;
  list-style: none;
}

@media (min-width: 620px) { .cards { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .cards { grid-template-columns: repeat(4, 1fr); } }

.card {
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.card__title {
  font-size: var(--step-1);
}

.card__body {
  color: var(--text-muted);
  font-size: var(--step-0);
}

/* --- Principles ----------------------------------------------------------- */

.principles {
  display: grid;
  gap: var(--space-5);
  list-style: none;
}

.principle {
  padding-left: var(--space-5);
  border-left: 2px solid var(--gold-tint);

  & p { color: var(--n-400); margin-top: var(--space-2); }
}

.principle__title { font-size: var(--step-1); }

.never {
  background: rgb(255 255 255 / 0.04);
  border: 1px solid var(--n-800);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
}

.never__title {
  font-size: var(--step-1);
  margin-bottom: var(--space-4);
}

.never__list {
  display: grid;
  gap: var(--space-3);
  list-style: none;
  color: var(--n-300);
}

.never__list li {
  position: relative;
  padding-left: var(--space-6);
}

/* A drawn cross, so it needs no icon font and no extra request. */
.never__list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 14px;
  height: 14px;
  background:
    linear-gradient(currentColor, currentColor) center / 100% 2px no-repeat,
    linear-gradient(currentColor, currentColor) center / 2px 100% no-repeat;
  transform: rotate(45deg);
  color: var(--gold-tint);
}

@media (prefers-color-scheme: dark) {
  .principle p { color: var(--text-muted); }
  .never { background: var(--bg-sunken); border-color: var(--border); }
  .never__list { color: var(--text-muted); }
}

/* --- Forms ---------------------------------------------------------------- */

.form {
  display: grid;
  gap: var(--space-5);
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
}

.field { display: grid; gap: var(--space-2); }

.field__label {
  font-family: var(--font-display);
  font-weight: var(--weight-medium);
  color: var(--text);
}

.field__input {
  width: 100%;
  min-height: var(--tap-min);
  padding: var(--space-3) var(--space-4);
  background: var(--bg);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  color: var(--text);
  transition: border-color var(--dur-fast) var(--ease);

  &::placeholder { color: var(--text-subtle); }
  &:hover { border-color: var(--text-subtle); }
}

.field__select {
  appearance: none;
  padding-right: var(--space-8);
  /* Chevron drawn with gradients — no icon file, no extra request. */
  background-image:
    linear-gradient(45deg, transparent 50%, currentColor 50%),
    linear-gradient(135deg, currentColor 50%, transparent 50%);
  background-position:
    calc(100% - 22px) calc(50% + 2px),
    calc(100% - 16px) calc(50% + 2px);
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
}

textarea.field__input {
  min-height: 9rem;
  resize: vertical;
  line-height: var(--leading-body);
}

.field__hint {
  font-size: var(--step--1);
  color: var(--text-muted);
}

.field__error {
  font-size: var(--step--1);
  font-weight: var(--weight-medium);
  color: var(--danger);
}

.field__error::before {
  content: "";
  display: inline-block;
  width: 1em;
  height: 1em;
  margin-right: 0.4em;
  vertical-align: -0.15em;
  background: currentColor;
  /* exclamation disc, drawn as a mask so it inherits --danger */
  mask: radial-gradient(circle at 50% 50%, #000 49%, transparent 50%) center / 100% 100% no-repeat;
}

.field.is-invalid .field__input {
  border-color: var(--danger);
  border-width: 2px;
}

.fieldset { display: grid; gap: var(--space-3); border: 0; }

.choices {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
}

.choice {
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  min-height: var(--tap-min);
  padding: var(--space-2) var(--space-4);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  cursor: pointer;

  &:hover { border-color: var(--text-subtle); }
  &:has(input:checked) { border-color: var(--gold); box-shadow: inset 0 0 0 1px var(--gold); }
}

.choice input, .consent input {
  width: 20px;
  height: 20px;
  accent-color: var(--gold);
  flex: none;
  cursor: pointer;
}

.consent {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  padding: var(--space-4);
  background: var(--bg-sunken);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  cursor: pointer;
  font-size: var(--step--1);
  color: var(--text-muted);
  line-height: var(--leading-snug);
}

.consent input { margin-top: 0.1em; }

.form__legal {
  font-size: var(--step--1);
  color: var(--text-muted);
}

.form__status {
  font-weight: var(--weight-medium);
  margin: 0;

  &:empty { display: none; }
}

.form__status.is-success { color: var(--success); }
.form__status.is-error { color: var(--danger); }

.form__reference {
  font-variant-numeric: tabular-nums;
  font-family: var(--font-display);
}

/* --- Notices -------------------------------------------------------------- */

.notice {
  padding: var(--space-4) var(--space-5);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  margin-bottom: var(--space-5);
  font-size: var(--step-0);
}

.notice--warning { background: var(--warning-bg); border-color: var(--warning); }
.notice--success { background: var(--success-bg); border-color: var(--success); }

/* --- Accordion ------------------------------------------------------------
   <details>/<summary> does all the work. JS only adds the height animation,
   so with JS off every answer still opens and closes.                      */

.accordion {
  border-top: 1px solid var(--border);
}

.qa {
  border-bottom: 1px solid var(--border);
}

.qa__q {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  min-height: var(--tap-min);
  padding-block: var(--space-4);
  font-family: var(--font-display);
  font-size: var(--step-1);
  font-weight: var(--weight-medium);
  letter-spacing: var(--tracking-snug);
  cursor: pointer;
  list-style: none;

  &::-webkit-details-marker { display: none; }
  &:hover { color: var(--gold); }
}

/* Drawn +/− indicator. */
.qa__q::after {
  content: "";
  flex: none;
  width: 16px;
  height: 16px;
  background:
    linear-gradient(currentColor, currentColor) center / 100% 2px no-repeat,
    linear-gradient(currentColor, currentColor) center / 2px 100% no-repeat;
  transition: transform var(--dur-mid) var(--ease);
}

.qa[open] .qa__q::after {
  transform: rotate(90deg);
  background:
    linear-gradient(currentColor, currentColor) center / 100% 2px no-repeat;
}

.qa__a {
  padding-bottom: var(--space-5);
  color: var(--text-muted);
  max-width: var(--measure);
}

/* JS-driven smooth open. Only applied when js/accordion.js has run. */
.accordion.js-enhanced .qa__a {
  overflow: hidden;
}

/* --- Cookie banner -------------------------------------------------------- */

.cookie-banner {
  position: fixed;
  inset-inline: 0;
  bottom: 0;
  z-index: var(--z-banner);
  background: var(--bg-raised);
  border-top: 1px solid var(--border-strong);
  box-shadow: var(--shadow-lg);
  padding: var(--space-5) 0;

  &[hidden] { display: none; }
}

.cookie-banner__inner {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
  display: grid;
  gap: var(--space-3);
}

.cookie-banner__title { font-size: var(--step-1); }

.cookie-banner__body {
  color: var(--text-muted);
  max-width: var(--measure);
  font-size: var(--step--1);
}

.cookie-banner__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-3);
}

/* Reject carries the same visual weight as Accept — same size, same
   prominence — so the choice is genuine. */
.cookie-banner__actions .btn { flex: 1 1 auto; min-width: 160px; }

.cookie-banner__link {
  margin-left: auto;
  font-size: var(--step--1);
}

@media (min-width: 768px) {
  .cookie-banner__actions .btn { flex: 0 0 auto; }
}

/* --- Entrance animation ---------------------------------------------------
   Added by js/nav.js via IntersectionObserver. Elements are fully visible
   by default; the class only opts them into the fade.                      */

.reveal {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity var(--dur-slow) var(--ease),
              transform var(--dur-slow) var(--ease);
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; }
}
/* ==========================================================================
   TekuCredit — page-specific layouts
   ========================================================================== */

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

.hero {
  padding-block: clamp(2.5rem, 1.5rem + 5vw, 6rem);
  background:
    radial-gradient(80% 120% at 85% 0%, var(--gold-soft) 0%, transparent 62%),
    var(--bg);
  border-bottom: 1px solid var(--border);
  overflow: hidden;
}

.hero__inner {
  display: grid;
  gap: var(--space-7);
  grid-template-columns: 1fr;
  align-items: center;
}

@media (min-width: 900px) {
  .hero__inner {
    grid-template-columns: 1.35fr 0.65fr;
    gap: var(--space-8);
  }
}

.hero__title {
  max-width: 16ch;
}

.hero__lede {
  margin-top: var(--space-5);
  max-width: 54ch;
  font-size: var(--step-1);
  color: var(--text-muted);
}

.hero__actions {
  margin-top: var(--space-6);
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
}

.hero__actions .btn { flex: 1 1 auto; }

@media (min-width: 520px) {
  .hero__actions .btn { flex: 0 0 auto; }
}

/* The one hero interaction: the released quadrant drifts a little further
   out on load, then settles. Cheap on a mid-range device — two transforms,
   no layout, no paint beyond the mark itself. */

.hero__visual {
  display: none;
}

@media (min-width: 900px) {
  .hero__visual {
    display: grid;
    place-items: center;
  }
}

.hero__mark {
  width: min(300px, 100%);
  height: auto;
  color: var(--graphite);
}

.hero__mark-piece {
  transform-origin: 50% 50%;
  animation: tc-release var(--dur-slow) var(--ease) both;
}

.hero__mark-ring {
  animation: tc-settle var(--dur-slow) var(--ease) both;
}

@keyframes tc-release {
  from { transform: translate(-9px, 9px); opacity: 0; }
  to   { transform: translate(0, 0); opacity: 1; }
}

@keyframes tc-settle {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .hero__mark-piece, .hero__mark-ring { animation: none; }
}

@media (prefers-color-scheme: dark) {
  .hero {
    background:
      radial-gradient(80% 120% at 85% 0%, rgb(201 151 63 / 0.10) 0%, transparent 62%),
      var(--bg);
  }
  .hero__mark { color: var(--gold-tint); }
}

/* --- Page header (interior pages) ---------------------------------------- */

.page-header {
  padding-block: clamp(2.5rem, 1.5rem + 4vw, 4.5rem);
  border-bottom: 1px solid var(--border);
  background: var(--bg-sunken);
}

.page-header__title {
  max-width: 18ch;
  margin-top: var(--space-3);
}

.page-header__lede {
  margin-top: var(--space-4);
  max-width: var(--measure);
  font-size: var(--step-1);
  color: var(--text-muted);
}

/* --- Long-form legal / policy pages --------------------------------------- */

.doc {
  max-width: var(--measure);
  color: var(--text-muted);
}

.doc h2 {
  font-size: var(--step-3);
  margin-top: var(--space-8);
  margin-bottom: var(--space-4);
  color: var(--text);
  scroll-margin-top: 90px;
}

.doc h3 {
  font-size: var(--step-1);
  margin-top: var(--space-6);
  margin-bottom: var(--space-3);
  color: var(--text);
}

.doc p + p,
.doc ul + p,
.doc p + ul,
.doc table + p { margin-top: var(--space-4); }

.doc ul, .doc ol {
  margin-top: var(--space-3);
  padding-left: var(--space-5);
  display: grid;
  gap: var(--space-2);
}

.doc li::marker { color: var(--gold); }

.doc__updated {
  font-size: var(--step--1);
  color: var(--text-subtle);
}

.doc__toc {
  background: var(--bg-sunken);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  margin-bottom: var(--space-7);

  & ol { display: grid; gap: var(--space-2); padding-left: var(--space-5); }
}

.doc__toc h2 {
  margin: 0 0 var(--space-3);
  font-size: var(--step-1);
}

/* Data tables in the privacy policy scroll on their own, never the page. */
.table-scroll {
  overflow-x: auto;
  margin-top: var(--space-4);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
}

.doc table {
  width: 100%;
  min-width: 34rem;
  border-collapse: collapse;
  font-size: var(--step--1);
}

.doc th, .doc td {
  text-align: left;
  vertical-align: top;
  padding: var(--space-3) var(--space-4);
  border-bottom: 1px solid var(--border);
}

.doc th {
  font-family: var(--font-display);
  color: var(--text);
  background: var(--bg-sunken);
  white-space: nowrap;
}

.doc tr:last-child td { border-bottom: 0; }

/* --- About: team and office ----------------------------------------------- */

.team {
  display: grid;
  gap: var(--grid-gap);
  grid-template-columns: 1fr;
  list-style: none;
  margin-top: var(--space-6);
}

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

.person {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
}

.person__name { font-size: var(--step-1); }

.person__role {
  font-size: var(--step--1);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  color: var(--gold);
  margin-top: var(--space-1);
}

.person__bio { margin-top: var(--space-3); color: var(--text-muted); }

/* --- Approach: numbered commitments --------------------------------------- */

.commitments {
  counter-reset: commitment;
  display: grid;
  gap: var(--space-6);
  list-style: none;
  margin-top: var(--space-6);
}

.commitment {
  counter-increment: commitment;
  display: grid;
  gap: var(--space-3);
  padding-top: var(--space-5);
  border-top: 1px solid var(--border);
}

@media (min-width: 768px) {
  .commitment { grid-template-columns: 4rem 1fr; column-gap: var(--space-6); }
}

.commitment::before {
  content: counter(commitment, decimal-leading-zero);
  font-family: var(--font-display);
  font-size: var(--step-3);
  font-variant-numeric: tabular-nums;
  color: var(--gold-tint);
  line-height: 1;
}

.commitment__body > p { color: var(--text-muted); }
.commitment__body > p + p { margin-top: var(--space-3); }

/* --- Careers -------------------------------------------------------------- */

.roles {
  display: grid;
  gap: var(--space-4);
  list-style: none;
  margin-top: var(--space-6);
}

.role {
  display: grid;
  gap: var(--space-2);
  padding: var(--space-5);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--bg-raised);
}

@media (min-width: 768px) {
  .role {
    grid-template-columns: 1fr auto;
    align-items: center;
    column-gap: var(--space-5);
  }
}

.role__meta {
  font-size: var(--step--1);
  color: var(--text-subtle);
}

/* --- Contact -------------------------------------------------------------- */

.contact-grid {
  display: grid;
  gap: var(--space-7);
  grid-template-columns: 1fr;
}

@media (min-width: 900px) {
  .contact-grid { grid-template-columns: 1fr 1.25fr; gap: var(--space-8); }
}

.contact-detail + .contact-detail {
  margin-top: var(--space-5);
  padding-top: var(--space-5);
  border-top: 1px solid var(--border);
}

.contact-detail__label {
  font-family: var(--font-display);
  font-size: var(--step--1);
  letter-spacing: var(--tracking-wide);
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: var(--space-2);
}

/* --- 404 ------------------------------------------------------------------ */

.notfound {
  padding-block: clamp(4rem, 2rem + 8vw, 8rem);
  text-align: center;
}

.notfound__code {
  font-family: var(--font-display);
  font-size: var(--step-6);
  font-variant-numeric: tabular-nums;
  color: var(--gold-tint);
  line-height: 1;
}

.notfound__actions {
  margin-top: var(--space-6);
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  justify-content: center;
}
