/* ============================================================
   Alkami — Color System
   Source: Alkami Brand Guidelines 1.1, "Color System" (pp.11–15)
   Navy is the hero. Gold is an accent — used less, more intentionally.
   ============================================================ */

:root {
  /* --- Navy / Primary blue (the hero family) --- */
  --navy-900: #071351; /* hero navy — primary one-color logo */
  --navy-800: #152E7C; /* primary */
  --blue-700: #0251B3;
  --blue-600: #1F64C5;
  --blue-500: #357DE4;

  /* --- Teal / Turquoise (secondary) --- */
  --teal-700: #1B9587;
  --teal-600: #1EAF9B;
  --teal-500: #26C4AA;
  --teal-400: #29DBBE;

  /* --- Sky (secondary) --- */
  --sky-600: #50C1EC;
  --sky-500: #67CFEE;
  --sky-400: #7EDEFC;
  --sky-300: #92EAFF;

  /* --- Purple (accent) --- */
  --purple-700: #692E53;
  --purple-600: #773E64;
  --purple-500: #914475;
  --purple-400: #AE5294;

  /* --- Gold (accent — use sparingly & intentionally) --- */
  --gold-600: #F3AB39; /* core accent */
  --gold-500: #F7C94C;
  --gold-400: #FFDC6C;
  --gold-300: #FFEA8F;
  --gold-200: #FFF3AB;
  --gold-grad-end: #FAD564; /* gold gradient terminus */

  /* --- Neutrals --- */
  /* Brand-defined light neutrals */
  --white:    #FFFFFF;
  --gray-50:  #FAFAFA;
  --gray-100: #EFEFEF;
  --gray-200: #DBDBDB;
  /* Extended cool grays (oklch-harmonized to the navy hue — needed for UI,
     not in the printed guide). Flagged in readme. */
  --gray-300: #C2C6D0;
  --gray-400: #9AA0AE;
  --gray-500: #6B7283;
  --gray-600: #474D5E;
  --gray-700: #2C3242;

  /* --- Signature gradients --- */
  --gradient-gold: linear-gradient(135deg, var(--gold-600) 0%, var(--gold-grad-end) 100%);
  --gradient-navy: linear-gradient(160deg, var(--navy-900) 0%, var(--navy-800) 100%);
  --gradient-spectrum: linear-gradient(120deg, var(--navy-800) 0%, var(--blue-500) 38%, var(--teal-500) 72%, var(--sky-400) 100%);

  /* ============================================================
     Semantic aliases
     ============================================================ */
  --color-bg:             var(--gray-50);
  --color-surface:        var(--white);
  --color-surface-subtle: var(--gray-50);
  --color-surface-sunken: var(--gray-100);
  --color-surface-inverse: var(--navy-900);

  --text-primary:   var(--navy-900);
  --text-secondary: var(--gray-600);
  --text-muted:     var(--gray-500);
  --text-on-dark:   var(--white);
  --text-on-dark-muted: rgba(255, 255, 255, 0.72);
  --text-link:      var(--blue-600);

  --brand-primary:  var(--navy-800);
  --brand-hero:     var(--navy-900);
  --brand-accent:   var(--gold-600);
  --brand-teal:     var(--teal-600);
  --brand-sky:      var(--sky-500);
  --brand-purple:   var(--purple-600);

  --border-subtle:  var(--gray-100);
  --border-default: var(--gray-200);
  --border-strong:  var(--gray-300);

  --focus-ring:     var(--blue-500);

  /* Status — brand has no native red; success→teal, info→blue, warning→gold.
     Danger red is oklch-harmonized & flagged in readme. */
  --status-success: var(--teal-600);
  --status-success-surface: #E2F6F2;
  --status-info:    var(--blue-600);
  --status-info-surface: #E4EEFB;
  --status-warning: var(--gold-600);
  --status-warning-surface: #FFF4D6;
  --status-danger:  #D6443F;
  --status-danger-surface: #FBE6E5;
}

/* ============================================================
   Alkami — Typography tokens
   Display/headline: Alverata (subst. Newsreader)  ·  Body: Nunito Sans
   ============================================================ */

:root {
  /* --- Families --- */
  --font-display: 'Newsreader', 'Alverata', Cambria, Georgia, serif; /* Alverata substitute */
  --font-body:    'Nunito Sans', Calibri, system-ui, -apple-system, sans-serif;
  --font-mono:    'IBM Plex Mono', ui-monospace, 'SFMono-Regular', Menlo, monospace;

  /* --- Weights --- */
  --weight-light:    300;
  --weight-regular:  400;
  --weight-medium:   500;
  --weight-semibold: 600;
  --weight-bold:     700;
  --weight-black:    800; /* Alverata Black maps to Newsreader 800 */

  /* --- Type scale (rem, 16px base) --- */
  --text-2xs: 0.6875rem; /* 11px */
  --text-xs:  0.75rem;   /* 12px */
  --text-sm:  0.875rem;  /* 14px */
  --text-base:1rem;      /* 16px */
  --text-md:  1.125rem;  /* 18px */
  --text-lg:  1.375rem;  /* 22px */
  --text-xl:  1.75rem;   /* 28px */
  --text-2xl: 2.25rem;   /* 36px */
  --text-3xl: 3rem;      /* 48px */
  --text-4xl: 4rem;      /* 64px */
  --text-5xl: 5.25rem;   /* 84px */

  /* --- Line heights --- */
  --leading-tight:   1.05;
  --leading-snug:    1.18;
  --leading-normal:  1.45;
  --leading-relaxed: 1.65;

  /* --- Letter spacing --- */
  --tracking-tight:  -0.02em;
  --tracking-snug:   -0.01em;
  --tracking-normal: 0;
  --tracking-wide:   0.04em;
  --tracking-caps:   0.12em; /* eyebrows / overlines */

  /* --- Semantic type roles --- */
  --type-display-font:   var(--font-display);
  --type-display-weight: var(--weight-bold);
  --type-display-leading:var(--leading-tight);
  --type-display-track:  var(--tracking-tight);

  --type-heading-font:   var(--font-display);
  --type-heading-weight: var(--weight-semibold);
  --type-heading-leading:var(--leading-snug);

  --type-body-font:      var(--font-body);
  --type-body-weight:    var(--weight-regular);
  --type-body-leading:   var(--leading-normal);

  --type-eyebrow-font:   var(--font-body);
  --type-eyebrow-weight: var(--weight-bold);
  --type-eyebrow-track:  var(--tracking-caps);
}

/* ============================================================
   Alkami — Spacing, radius, shadow, motion
   8px base grid. Glyphs are built on a geometric grid — the UI follows suit.
   ============================================================ */

:root {
  /* --- Spacing scale (8px grid, with 2/4 micro steps) --- */
  --space-0:  0;
  --space-1:  0.25rem; /* 4 */
  --space-2:  0.5rem;  /* 8 */
  --space-3:  0.75rem; /* 12 */
  --space-4:  1rem;    /* 16 */
  --space-5:  1.5rem;  /* 24 */
  --space-6:  2rem;    /* 32 */
  --space-7:  2.5rem;  /* 40 */
  --space-8:  3rem;    /* 48 */
  --space-9:  4rem;    /* 64 */
  --space-10: 5rem;    /* 80 */
  --space-12: 6rem;    /* 96 */
  --space-16: 8rem;    /* 128 */

  /* --- Radius --- */
  --radius-xs:   4px;
  --radius-sm:   6px;
  --radius-md:   10px;
  --radius-lg:   16px;
  --radius-xl:   24px;
  --radius-2xl:  32px;
  --radius-pill: 999px;

  /* --- Border widths --- */
  --border-width: 1px;
  --border-width-strong: 2px;

  /* --- Shadows — cool, navy-tinted, soft (clay/product-display feel) --- */
  --shadow-xs: 0 1px 2px rgba(7, 19, 81, 0.06);
  --shadow-sm: 0 2px 6px rgba(7, 19, 81, 0.08);
  --shadow-md: 0 8px 20px rgba(7, 19, 81, 0.10);
  --shadow-lg: 0 18px 40px rgba(7, 19, 81, 0.14);
  --shadow-xl: 0 32px 64px rgba(7, 19, 81, 0.18);
  --shadow-focus: 0 0 0 3px rgba(53, 125, 228, 0.35); /* blue-500 @ 35% */
  --shadow-inset: inset 0 1px 2px rgba(7, 19, 81, 0.08);

  /* --- Motion --- */
  --ease-standard: cubic-bezier(0.2, 0, 0.1, 1); /* @kind other */
  --ease-out:      cubic-bezier(0.16, 1, 0.3, 1); /* @kind other */
  --ease-in:       cubic-bezier(0.4, 0, 1, 1); /* @kind other */
  --duration-fast:   120ms; /* @kind other */
  --duration-normal: 200ms; /* @kind other */
  --duration-slow:   340ms; /* @kind other */

  /* --- Layout --- */
  --container-max: 1200px;
  --container-wide: 1440px;
}

/* ============================================================
   Alkami — base element styles & helpers
   Light, optional resets that apply the brand defaults to bare HTML.
   ============================================================ */

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

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: var(--leading-normal);
  color: var(--text-primary);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: var(--weight-semibold);
  line-height: var(--leading-snug);
  letter-spacing: var(--tracking-snug);
  color: var(--text-primary);
  margin: 0 0 var(--space-4);
}
h1 { font-size: var(--text-3xl); font-weight: var(--weight-bold); letter-spacing: var(--tracking-tight); line-height: var(--leading-tight); }
h2 { font-size: var(--text-2xl); }
h3 { font-size: var(--text-xl); }
h4 { font-size: var(--text-lg); }

p { margin: 0 0 var(--space-4); }

a { color: var(--text-link); text-decoration: none; }
a:hover { text-decoration: underline; }

code, pre, kbd { font-family: var(--font-mono); }

/* --- Utility helpers (optional) --- */
.eyebrow {
  font-family: var(--font-body);
  font-weight: var(--weight-bold);
  font-size: var(--text-xs);
  letter-spacing: var(--tracking-caps);
  text-transform: uppercase;
  color: var(--brand-teal);
}

.text-gradient-gold {
  background: var(--gradient-gold);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.surface-card {
  background: var(--color-surface);
  border: var(--border-width) solid var(--border-default);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

:root { --font-display: "alverata", "Alverata", Cambria, Georgia, serif; --font-body: "nunito-sans", "Nunito Sans", Calibri, system-ui, sans-serif; }
    body { margin: 0; background: var(--gray-50); color: var(--navy-900); font-family: var(--font-body); -webkit-font-smoothing: antialiased; }
    a { color: var(--blue-600); text-decoration: none; }
    a:hover { color: var(--navy-800); text-decoration: underline; }
    [data-nav-card]:hover { background: rgba(255,255,255,0.16) !important; transform: translateY(-3px) !important; box-shadow: 0 10px 24px rgba(7,19,81,0.35) !important; }
    [data-nav-card][data-active="true"]:hover { background: #fff !important; }
    [data-nav-card]:active { transform: translateY(-1px) scale(0.98) !important; }
    summary::-webkit-details-marker { display: none; }
    summary { list-style: none; }
    @keyframes bbbSlideIn { from { opacity: 0; transform: translateX(40px); } to { opacity: 1; transform: none; } }
    @keyframes bbbGrowH { to { height: 472px; } }
    @keyframes bbbGrowX { to { transform: scaleX(1); } }
    @keyframes bbbRevealLoop { from { clip-path: inset(0 100% 100% 0); } 25% { clip-path: inset(0 0 100% 0); } 50% { clip-path: inset(0 0 0 0); } 100% { clip-path: inset(0 0 0 0); } }
    @keyframes bbbFadeOnly { from { opacity: 0; } to { opacity: 1; } }
    @keyframes bbbNudge { 0%, 100% { transform: translateX(0); } 50% { transform: translateX(6px); } }
    @keyframes bbbSpin { to { transform: rotate(360deg); } }
    @keyframes bbbStepSpin { 0% { transform: rotate(0deg); } 20% { transform: rotate(90deg); } 25% { transform: rotate(90deg); } 45% { transform: rotate(180deg); } 50% { transform: rotate(180deg); } 70% { transform: rotate(270deg); } 75% { transform: rotate(270deg); } 95% { transform: rotate(360deg); } 100% { transform: rotate(360deg); } }
    @keyframes bbbDraw { to { stroke-dashoffset: 0; } }
    @keyframes bbbPop { from { opacity: 0; transform: translateY(10px) scale(0.92); } to { opacity: 1; transform: none; } }
    @keyframes bbbFade { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
    @media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

/* Alkami design system Button (components/core/Button.jsx) */
.alk-btn { display:inline-flex; align-items:center; justify-content:center; gap:8px; height:44px; padding:0 20px; width:auto; font-family:var(--font-body); font-size:var(--text-base); font-weight:var(--weight-semibold); line-height:1; letter-spacing:var(--tracking-snug); border-radius:var(--radius-pill); cursor:pointer; transition:transform var(--duration-fast) var(--ease-standard), filter var(--duration-fast) var(--ease-standard), box-shadow var(--duration-fast) var(--ease-standard); white-space:nowrap; }
a.alk-btn { box-sizing:border-box; text-decoration:none; }
/* The base link hover (navy text, underline) must not reach link-buttons */
a.alk-btn:hover { text-decoration:none; }
a.alk-btn-primary:hover { color:var(--text-on-dark); }
a.alk-btn-accent:hover { color:var(--navy-900); }
a.alk-btn-ghost:hover { color:var(--navy-800); }
a.alk-btn-inverse:hover { color:var(--navy-900); }
.alk-btn:hover:not(:disabled) { filter:brightness(1.07); }
.alk-btn:active:not(:disabled) { transform:scale(0.97); }
.alk-btn:disabled { cursor:not-allowed; opacity:0.45; }
.alk-btn-sm { gap:6px; height:36px; padding:0 14px; font-size:var(--text-sm); }
.alk-btn-lg { gap:10px; height:52px; padding:0 28px; font-size:var(--text-md); }
.alk-btn-primary { background:var(--navy-800); color:var(--text-on-dark); border:1px solid var(--navy-800); }
.alk-btn-accent { background:var(--gradient-gold); color:var(--navy-900); border:1px solid transparent; font-weight:var(--weight-bold); }
.alk-btn-ghost { background:transparent; color:var(--navy-800); border:1px solid transparent; }
.alk-btn-inverse { background:var(--white); color:var(--navy-900); border:1px solid var(--white); }

/* hover + focus states */
.h0:hover { transform: translateY(-3px) !important; box-shadow: var(--shadow-lg) !important; }
.h1:hover { background: var(--gray-50) !important; }
.h2:hover { background: var(--blue-700) !important; }
.h3:hover { background:#fff !important; box-shadow: var(--shadow-sm) !important; }
