/* ============================================================
   GSUK Redesign — Design Tokens + Two Layered Themes

   Architecture:
     :root           — universal tokens (spacing, radii, type scale)
     .theme-marketing — direction A (editorial / fintech serious)
     .theme-app      — direction B (industrial / utility console)

   Apply by setting class on <body>:
     <body class="theme-marketing"> for marketing pages
     <body class="theme-app">       for the customer dashboard
   ============================================================ */

/* ── Universal tokens ───────────────────────────────────────── */
:root {
  /* Type scale (1.250 minor third) */
  --fs-12:   0.75rem;
  --fs-14:   0.875rem;
  --fs-15:   0.9375rem;
  --fs-16:   1rem;
  --fs-18:   1.125rem;
  --fs-20:   1.25rem;
  --fs-24:   1.5rem;
  --fs-32:   2rem;
  --fs-40:   2.5rem;
  --fs-56:   3.5rem;
  --fs-72:   4.5rem;

  /* Spacing scale (4px base) */
  --sp-1:    0.25rem;
  --sp-2:    0.5rem;
  --sp-3:    0.75rem;
  --sp-4:    1rem;
  --sp-5:    1.25rem;
  --sp-6:    1.5rem;
  --sp-8:    2rem;
  --sp-10:   2.5rem;
  --sp-12:   3rem;
  --sp-16:   4rem;
  --sp-20:   5rem;
  --sp-24:   6rem;
  --sp-32:   8rem;

  /* Line heights */
  --lh-tight:   1.15;
  --lh-snug:    1.3;
  --lh-normal:  1.5;
  --lh-relaxed: 1.7;

  /* Radii — small, restrained */
  --r-sm:    3px;
  --r-md:    6px;
  --r-lg:    10px;

  /* Borders — hairlines only */
  --bw-1:    1px;

  /* Easing */
  --ease:    cubic-bezier(0.2, 0.8, 0.2, 1);
  --dur-1:   120ms;
  --dur-2:   200ms;
}

/* ============================================================
   THEME A — Marketing / Editorial / Fintech-serious
   Light background, single accent (deep indigo), grotesk type,
   no shadows, no gradients, lots of whitespace.
   ============================================================ */
.theme-marketing {
  /* Palette */
  --bg:           #FBFBFA;     /* warm paper white */
  --bg-elevated:  #FFFFFF;
  --bg-section:   #F4F3F0;     /* subtle band for stripes */
  --ink:          #1B1F23;     /* almost-black, with warmth */
  --ink-2:        #3D434A;
  --ink-3:        #6B7178;     /* muted body */
  --ink-4:        #989DA3;     /* labels */
  --rule:         #E6E3DD;     /* hairline */
  --accent:       #2B3FA8;     /* deep indigo, single accent */
  --accent-ink:   #FFFFFF;
  --accent-soft:  #EDF0FA;     /* tint for callouts */
  --good:         #1F7A4D;
  --warn:         #B45309;
  --bad:          #B42318;

  /* Typography */
  --font-display: "Inter Tight", "Inter", system-ui, -apple-system, sans-serif;
  --font-body:    "Inter", system-ui, -apple-system, sans-serif;
  --font-mono:    "JetBrains Mono", "IBM Plex Mono", ui-monospace, monospace;

  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--fs-16);
  line-height: var(--lh-normal);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.theme-marketing h1, .theme-marketing h2, .theme-marketing h3, .theme-marketing h4 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin: 0;
  line-height: var(--lh-tight);
}
.theme-marketing h1 { font-size: var(--fs-56); letter-spacing: -0.03em; }
.theme-marketing h2 { font-size: var(--fs-40); }
.theme-marketing h3 { font-size: var(--fs-24); }
.theme-marketing h4 { font-size: var(--fs-18); }

.theme-marketing p { color: var(--ink-2); line-height: var(--lh-relaxed); margin: 0; }
.theme-marketing a { color: var(--accent); text-decoration: none; }
.theme-marketing a:hover { text-decoration: underline; text-underline-offset: 3px; }

.theme-marketing .container { max-width: 1180px; margin: 0 auto; padding: 0 var(--sp-6); }
.theme-marketing .section   { padding: var(--sp-24) 0; }
.theme-marketing .section--tight { padding: var(--sp-16) 0; }
.theme-marketing .section--band  { background: var(--bg-section); border-top: var(--bw-1) solid var(--rule); border-bottom: var(--bw-1) solid var(--rule); }

.theme-marketing .eyebrow {
  font-family: var(--font-mono);
  font-size: var(--fs-12);
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-4);
}

.theme-marketing .lede { font-size: var(--fs-20); color: var(--ink-2); line-height: var(--lh-relaxed); max-width: 38rem; }

/* Buttons — tight, professional, never dominate the layout */
.theme-marketing .btn {
  display: inline-flex; align-items: center; gap: var(--sp-2);
  padding: 8px 14px;
  font-family: var(--font-body);
  font-size: var(--fs-14);
  font-weight: 500;
  line-height: 1.3;
  border-radius: var(--r-sm);
  border: var(--bw-1) solid transparent;
  cursor: pointer; transition: all var(--dur-1) var(--ease);
  text-decoration: none;
  white-space: nowrap;
}
.theme-marketing .btn--primary { background: var(--ink); color: #FFFFFF; }
.theme-marketing .btn--primary:hover { background: var(--accent); text-decoration: none; }
.theme-marketing .btn--ghost { background: transparent; color: var(--ink-2); border-color: transparent; }
.theme-marketing .btn--ghost:hover { color: var(--ink); text-decoration: none; }
.theme-marketing .btn--lg { padding: 10px 18px; font-size: var(--fs-15); }

/* Nav */
.theme-marketing .nav {
  display: flex; align-items: center; justify-content: space-between;
  height: 64px; border-bottom: var(--bw-1) solid var(--rule);
  background: rgba(251,251,250,0.85);
  backdrop-filter: saturate(180%) blur(8px);
  position: sticky; top: 0; z-index: 50;
}
.theme-marketing .nav__inner { max-width: 1180px; margin: 0 auto; padding: 0 var(--sp-6); display: flex; align-items: center; justify-content: space-between; width: 100%; }
.theme-marketing .nav__brand { font-family: var(--font-display); font-weight: 600; font-size: var(--fs-16); letter-spacing: -0.01em; color: var(--ink); }
.theme-marketing .nav__links { display: flex; gap: var(--sp-8); }
.theme-marketing .nav__links a { color: var(--ink-2); font-size: var(--fs-15); }
.theme-marketing .nav__links a:hover { color: var(--ink); text-decoration: none; }

/* Hero */
.theme-marketing .hero { padding: var(--sp-24) 0 var(--sp-20); }
.theme-marketing .hero h1 { max-width: 18ch; margin-bottom: var(--sp-6); }
.theme-marketing .hero .lede { margin-bottom: var(--sp-8); }
.theme-marketing .hero__actions { display: flex; gap: var(--sp-3); }

/* Stat row (no card, just typographic) */
.theme-marketing .stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--sp-12); padding: var(--sp-12) 0; border-top: var(--bw-1) solid var(--rule); border-bottom: var(--bw-1) solid var(--rule); }
.theme-marketing .stat__num   { font-family: var(--font-display); font-size: var(--fs-40); font-weight: 600; letter-spacing: -0.02em; color: var(--ink); line-height: 1; }
.theme-marketing .stat__label { font-family: var(--font-mono); font-size: var(--fs-12); text-transform: uppercase; letter-spacing: 0.08em; color: var(--ink-4); margin-top: var(--sp-2); }

/* Product grid — flat, no shadow, hairline divider style */
.theme-marketing .product-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--sp-1); background: var(--rule); border: var(--bw-1) solid var(--rule); border-radius: var(--r-md); overflow: hidden; }
.theme-marketing .product { background: var(--bg-elevated); padding: var(--sp-8); display: flex; flex-direction: column; gap: var(--sp-3); transition: background var(--dur-1) var(--ease); text-decoration: none; color: inherit; }
.theme-marketing .product:hover { background: #FAFAF7; text-decoration: none; }
.theme-marketing .product__name  { font-size: var(--fs-20); font-weight: 600; letter-spacing: -0.01em; }
.theme-marketing .product__desc  { color: var(--ink-3); font-size: var(--fs-15); flex: 1; }
.theme-marketing .product__price { font-family: var(--font-mono); font-size: var(--fs-14); color: var(--ink-2); margin-top: var(--sp-3); padding-top: var(--sp-3); border-top: var(--bw-1) solid var(--rule); }
.theme-marketing .product__price strong { color: var(--ink); font-weight: 600; }

/* "How it works" — three numbered columns, no card */
.theme-marketing .steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--sp-12); }
.theme-marketing .step__num { font-family: var(--font-mono); font-size: var(--fs-12); color: var(--accent); letter-spacing: 0.1em; }
.theme-marketing .step__title { font-family: var(--font-display); font-size: var(--fs-20); font-weight: 600; margin: var(--sp-3) 0 var(--sp-3); }
.theme-marketing .step__body { color: var(--ink-3); }

/* Trust strip — logo wall */
.theme-marketing .trust { padding: var(--sp-10) 0; border-bottom: var(--bw-1) solid var(--rule); }
.theme-marketing .trust__label { text-align: center; color: var(--ink-3); font-family: var(--font-mono); font-size: var(--fs-12); text-transform: uppercase; letter-spacing: 0.1em; margin-bottom: var(--sp-6); }
.theme-marketing .trust__row { display: flex; justify-content: space-between; align-items: center; gap: var(--sp-8); flex-wrap: wrap; opacity: 0.65; }
.theme-marketing .trust__logo { font-family: var(--font-display); font-size: var(--fs-18); font-weight: 600; letter-spacing: -0.01em; color: var(--ink-2); }
.theme-marketing .trust__logo--mono { font-family: var(--font-mono); font-weight: 500; font-size: var(--fs-15); letter-spacing: 0.02em; }

/* Problem statement section */
.theme-marketing .problem { padding: var(--sp-24) 0; }
.theme-marketing .problem__grid { display: grid; grid-template-columns: 1fr 1fr; gap: var(--sp-16); align-items: start; }
.theme-marketing .problem__list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: var(--sp-6); }
.theme-marketing .problem__item { display: grid; grid-template-columns: auto 1fr; gap: var(--sp-4); align-items: start; }
.theme-marketing .problem__icon { font-family: var(--font-mono); color: var(--accent); font-size: var(--fs-15); padding-top: 4px; }
.theme-marketing .problem__title { font-weight: 600; color: var(--ink); margin-bottom: var(--sp-1); }
.theme-marketing .problem__body  { color: var(--ink-3); font-size: var(--fs-15); }

/* Outcome / testimonial — quote-led */
.theme-marketing .quote {
  padding: var(--sp-20) 0;
  border-top: var(--bw-1) solid var(--rule);
  border-bottom: var(--bw-1) solid var(--rule);
  background: var(--bg);
}
.theme-marketing .quote__inner { max-width: 720px; margin: 0 auto; text-align: center; }
.theme-marketing .quote__mark { font-family: var(--font-display); font-size: var(--fs-72); color: var(--accent); line-height: 0.5; margin-bottom: var(--sp-6); height: 36px; }
.theme-marketing .quote__text {
  font-family: var(--font-display);
  font-size: var(--fs-32);
  font-weight: 500;
  line-height: var(--lh-snug);
  letter-spacing: -0.02em;
  color: var(--ink);
  margin-bottom: var(--sp-8);
}
.theme-marketing .quote__attribution { display: flex; align-items: center; justify-content: center; gap: var(--sp-4); }
.theme-marketing .quote__avatar { width: 44px; height: 44px; border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-items: center; font-family: var(--font-display); font-size: var(--fs-15); font-weight: 600; }
.theme-marketing .quote__person { text-align: left; }
.theme-marketing .quote__name   { font-weight: 600; color: var(--ink); font-size: var(--fs-15); }
.theme-marketing .quote__title  { color: var(--ink-3); font-size: var(--fs-14); }

/* Pricing strip — clarity, single line */
.theme-marketing .pricing-strip { padding: var(--sp-12) 0; }
.theme-marketing .pricing-strip__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--sp-8); }
.theme-marketing .pricing-strip__item { padding: var(--sp-6); border: var(--bw-1) solid var(--rule); border-radius: var(--r-md); background: var(--bg-elevated); }
.theme-marketing .pricing-strip__price { font-family: var(--font-display); font-size: var(--fs-40); font-weight: 600; letter-spacing: -0.02em; color: var(--ink); line-height: 1; margin-bottom: var(--sp-2); }
.theme-marketing .pricing-strip__price small { font-family: var(--font-body); font-size: var(--fs-15); font-weight: 400; color: var(--ink-3); letter-spacing: 0; }
.theme-marketing .pricing-strip__name { font-weight: 600; color: var(--ink); font-size: var(--fs-15); margin-bottom: var(--sp-2); }
.theme-marketing .pricing-strip__desc { color: var(--ink-3); font-size: var(--fs-14); }

/* FAQ — accordion-ish */
.theme-marketing .faq { padding: var(--sp-20) 0; }
.theme-marketing .faq__grid { display: grid; grid-template-columns: 1fr 2fr; gap: var(--sp-16); align-items: start; }
.theme-marketing .faq details { border-top: var(--bw-1) solid var(--rule); padding: var(--sp-5) 0; }
.theme-marketing .faq details:last-child { border-bottom: var(--bw-1) solid var(--rule); }
.theme-marketing .faq summary { cursor: pointer; font-weight: 600; color: var(--ink); font-size: var(--fs-16); list-style: none; display: flex; justify-content: space-between; align-items: center; gap: var(--sp-4); }
.theme-marketing .faq summary::-webkit-details-marker { display: none; }
.theme-marketing .faq summary::after { content: "+"; font-family: var(--font-mono); color: var(--ink-3); font-size: var(--fs-20); font-weight: 400; transition: transform var(--dur-2) var(--ease); }
.theme-marketing .faq details[open] summary::after { transform: rotate(45deg); color: var(--accent); }
.theme-marketing .faq__answer { color: var(--ink-3); font-size: var(--fs-15); margin-top: var(--sp-3); line-height: var(--lh-relaxed); max-width: 56ch; }

/* Final CTA — single, strong */
.theme-marketing .cta {
  padding: var(--sp-20) 0;
  text-align: center;
}
.theme-marketing .cta__title { font-family: var(--font-display); font-size: var(--fs-40); font-weight: 600; letter-spacing: -0.02em; color: var(--ink); max-width: 22ch; margin: 0 auto var(--sp-5); line-height: var(--lh-tight); }
.theme-marketing .cta__sub { color: var(--ink-3); font-size: var(--fs-16); max-width: 36rem; margin: 0 auto var(--sp-8); }
.theme-marketing .cta__row { display: inline-flex; gap: var(--sp-3); flex-wrap: wrap; justify-content: center; }
.theme-marketing .cta__guarantees { margin-top: var(--sp-6); display: inline-flex; gap: var(--sp-6); flex-wrap: wrap; justify-content: center; color: var(--ink-3); font-size: var(--fs-13, var(--fs-14)); }
.theme-marketing .cta__guarantees span { display: inline-flex; align-items: center; gap: var(--sp-2); }
.theme-marketing .cta__guarantees span::before { content: "·"; color: var(--accent); font-weight: 700; }

/* Page header — used on inner marketing pages (contact, products catalog, etc.) */
.theme-marketing .page-header { padding: var(--sp-16) 0 var(--sp-12); border-bottom: var(--bw-1) solid var(--rule); }
.theme-marketing .page-header h1 { font-size: var(--fs-40); margin-bottom: var(--sp-4); max-width: 22ch; }
.theme-marketing .page-header p { font-size: var(--fs-18); color: var(--ink-3); max-width: 38rem; }

/* Forms */
.theme-marketing .form { display: flex; flex-direction: column; gap: var(--sp-5); }
.theme-marketing .field { display: flex; flex-direction: column; gap: var(--sp-2); }
.theme-marketing .field__label { font-size: var(--fs-14); font-weight: 500; color: var(--ink); }
.theme-marketing .field__hint  { font-size: var(--fs-12); color: var(--ink-4); font-family: var(--font-mono); }
.theme-marketing .input,
.theme-marketing .textarea,
.theme-marketing .select {
  width: 100%;
  padding: 10px 12px;
  font-family: var(--font-body);
  font-size: var(--fs-15);
  color: var(--ink);
  background: var(--bg-elevated);
  border: var(--bw-1) solid var(--rule);
  border-radius: var(--r-sm);
  transition: border-color var(--dur-1) var(--ease), box-shadow var(--dur-1) var(--ease);
  outline: none;
}
.theme-marketing .input:focus,
.theme-marketing .textarea:focus,
.theme-marketing .select:focus { border-color: var(--ink); box-shadow: 0 0 0 3px rgba(43,63,168,0.08); }
.theme-marketing .textarea { resize: vertical; min-height: 140px; line-height: var(--lh-normal); font-family: var(--font-body); }
.theme-marketing .check { display: flex; align-items: center; gap: var(--sp-2); font-size: var(--fs-14); color: var(--ink-2); cursor: pointer; }
.theme-marketing .check input { width: 16px; height: 16px; accent-color: var(--accent); }

/* Auth surface — narrow card on a softly-banded page */
.theme-marketing .auth-page {
  min-height: calc(100vh - 64px);
  display: grid;
  place-items: center;
  padding: var(--sp-12) var(--sp-5);
  background: var(--bg);
}
.theme-marketing .auth-card {
  width: 100%;
  max-width: 420px;
  background: var(--bg-elevated);
  border: var(--bw-1) solid var(--rule);
  border-radius: var(--r-md);
  padding: var(--sp-10) var(--sp-8);
}
.theme-marketing .auth-card h1 { font-size: var(--fs-24); margin-bottom: var(--sp-2); }
.theme-marketing .auth-card .subtitle { color: var(--ink-3); font-size: var(--fs-14); margin-bottom: var(--sp-8); }
.theme-marketing .auth-card .btn { width: 100%; justify-content: center; padding: 11px 16px; }
.theme-marketing .auth-card__footer { text-align: center; color: var(--ink-3); font-size: var(--fs-14); margin-top: var(--sp-6); padding-top: var(--sp-6); border-top: var(--bw-1) solid var(--rule); }

/* Inline alerts on forms */
.theme-marketing .alert { padding: var(--sp-3) var(--sp-4); border-radius: var(--r-sm); font-size: var(--fs-14); margin-bottom: var(--sp-4); border: var(--bw-1) solid; }
.theme-marketing .alert--error   { background: #FAEBE7; border-color: #E5BEB7; color: #B42318; }
.theme-marketing .alert--success { background: #EEF6F0; border-color: #BEDDC9; color: #1F7A4D; }
.theme-marketing .alert--info    { background: var(--accent-soft); border-color: #C8D2EE; color: var(--accent); }

/* Catalog grid — same hairline-divided look as homepage products */
.theme-marketing .catalog { padding: var(--sp-12) 0 var(--sp-20); }
.theme-marketing .catalog__group + .catalog__group { margin-top: var(--sp-12); }
.theme-marketing .catalog__group-title { font-family: var(--font-mono); font-size: var(--fs-12); text-transform: uppercase; letter-spacing: 0.08em; color: var(--ink-4); margin-bottom: var(--sp-5); }

/* Footer */
.theme-marketing .footer { border-top: var(--bw-1) solid var(--rule); padding: var(--sp-12) 0; color: var(--ink-3); font-size: var(--fs-14); }
.theme-marketing .footer__grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: var(--sp-12); }
.theme-marketing .footer h5 { font-family: var(--font-display); font-size: var(--fs-14); font-weight: 600; color: var(--ink); margin: 0 0 var(--sp-4); text-transform: uppercase; letter-spacing: 0.06em; }
.theme-marketing .footer ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: var(--sp-2); }
.theme-marketing .footer a { color: var(--ink-3); }
.theme-marketing .footer a:hover { color: var(--ink); text-decoration: none; }

/* ============================================================
   THEME B — App / Industrial / Utility console
   Off-white work surface, rust accent, mono labels and numbers,
   sharp corners, hairlines, no decorative effects.
   ============================================================ */
.theme-app {
  /* Palette */
  --bg:           #F6F4EE;     /* warm paper, easier on eyes than pure white */
  --bg-canvas:    #ECE9E1;
  --bg-row:       #FBF9F4;
  --bg-row-alt:   #F2EFE7;
  --surface:      #FFFFFF;
  --ink:          #14171A;
  --ink-2:        #3A3F45;
  --ink-3:        #6E727A;
  --ink-4:        #9A9DA3;
  --rule:         #DAD5C8;     /* warm hairline */
  --rule-strong:  #B7B0A0;
  --accent:       #C04A1B;     /* rust orange */
  --accent-ink:   #FFFFFF;
  --accent-soft:  #FCEFE8;
  --good:         #2E7D49;
  --warn:         #B45309;
  --bad:          #A82A18;
  --info:         #1E4D88;

  /* Typography */
  --font-display: "Inter Tight", "Inter", system-ui, -apple-system, sans-serif;
  --font-body:    "Inter", system-ui, -apple-system, sans-serif;
  --font-mono:    "JetBrains Mono", "IBM Plex Mono", ui-monospace, monospace;

  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--fs-15);
  line-height: var(--lh-normal);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.theme-app h1, .theme-app h2, .theme-app h3, .theme-app h4 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--ink);
  margin: 0;
  line-height: var(--lh-tight);
}
.theme-app h1 { font-size: var(--fs-32); }
.theme-app h2 { font-size: var(--fs-20); }
.theme-app h3 { font-size: var(--fs-18); }

.theme-app a { color: var(--accent); text-decoration: none; }
.theme-app a:hover { text-decoration: underline; }

/* Console-style "topbar + sidebar + main" layout */
.theme-app .console { display: grid; grid-template-columns: 232px 1fr; min-height: 100vh; }
.theme-app .sidebar { background: var(--bg-canvas); border-right: var(--bw-1) solid var(--rule); padding: var(--sp-5) 0; }
.theme-app .sidebar__brand { padding: 0 var(--sp-5) var(--sp-6); border-bottom: var(--bw-1) solid var(--rule); margin-bottom: var(--sp-5); display: flex; align-items: center; gap: var(--sp-3); font-family: var(--font-mono); font-size: var(--fs-14); font-weight: 600; color: var(--ink); }
.theme-app .sidebar__brand-mark { width: 22px; height: 22px; background: var(--ink); color: var(--bg); display: grid; place-items: center; font-family: var(--font-mono); font-size: 11px; font-weight: 700; }
.theme-app .sidebar__group-title { font-family: var(--font-mono); font-size: var(--fs-12); text-transform: uppercase; letter-spacing: 0.08em; color: var(--ink-4); padding: var(--sp-4) var(--sp-5) var(--sp-2); }
.theme-app .sidebar__nav { display: flex; flex-direction: column; }
.theme-app .sidebar__link { padding: var(--sp-2) var(--sp-5); color: var(--ink-2); font-size: var(--fs-14); display: flex; align-items: center; gap: var(--sp-3); border-left: 2px solid transparent; }
.theme-app .sidebar__link:hover { background: var(--bg-row); color: var(--ink); text-decoration: none; }
.theme-app .sidebar__link.is-active { color: var(--ink); border-left-color: var(--accent); background: var(--bg-row); }
.theme-app .sidebar__key { font-family: var(--font-mono); font-size: 10px; color: var(--ink-4); margin-left: auto; }

.theme-app .main { padding: 0; display: flex; flex-direction: column; }
.theme-app .topbar { display: flex; align-items: center; justify-content: space-between; padding: var(--sp-3) var(--sp-8); border-bottom: var(--bw-1) solid var(--rule); background: var(--bg); position: sticky; top: 0; z-index: 10; }
.theme-app .breadcrumb { font-family: var(--font-mono); font-size: var(--fs-12); color: var(--ink-3); display: flex; gap: var(--sp-2); align-items: center; }
.theme-app .breadcrumb a { color: var(--ink-3); }
.theme-app .breadcrumb__sep { color: var(--ink-4); }
.theme-app .topbar__user { display: flex; align-items: center; gap: var(--sp-3); font-size: var(--fs-13, var(--fs-14)); color: var(--ink-2); }
.theme-app .topbar__avatar { width: 28px; height: 28px; background: var(--ink); color: var(--bg); display: grid; place-items: center; font-family: var(--font-mono); font-size: 11px; font-weight: 700; border-radius: 50%; }

.theme-app .pane { padding: var(--sp-8); max-width: 1200px; }
.theme-app .pane__header { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: var(--sp-8); padding-bottom: var(--sp-5); border-bottom: var(--bw-1) solid var(--rule); }
.theme-app .pane__title h1 { margin-bottom: var(--sp-2); }
.theme-app .pane__title p { color: var(--ink-3); font-size: var(--fs-14); }

/* Section block — sharp-cornered, hairline border */
.theme-app .block { background: var(--surface); border: var(--bw-1) solid var(--rule); margin-bottom: var(--sp-6); }
.theme-app .block__header { display: flex; align-items: center; justify-content: space-between; padding: var(--sp-3) var(--sp-5); border-bottom: var(--bw-1) solid var(--rule); background: var(--bg-row-alt); }
.theme-app .block__title { font-family: var(--font-mono); font-size: var(--fs-12); text-transform: uppercase; letter-spacing: 0.08em; color: var(--ink-2); }
.theme-app .block__action { font-size: var(--fs-13, var(--fs-14)); color: var(--accent); }
.theme-app .block__body { padding: var(--sp-5); }

/* Service rows — table-like, dense, scannable */
.theme-app .svc-table { width: 100%; border-collapse: collapse; font-size: var(--fs-14); }
.theme-app .svc-table th { text-align: left; font-family: var(--font-mono); font-size: var(--fs-12); text-transform: uppercase; letter-spacing: 0.06em; color: var(--ink-3); font-weight: 500; padding: var(--sp-3) var(--sp-5); border-bottom: var(--bw-1) solid var(--rule); }
.theme-app .svc-table td { padding: var(--sp-4) var(--sp-5); border-bottom: var(--bw-1) solid var(--rule); }
.theme-app .svc-table tr:last-child td { border-bottom: none; }
.theme-app .svc-table tr:hover td { background: var(--bg-row); }
.theme-app .svc-table .col-num { font-family: var(--font-mono); color: var(--ink-2); }
.theme-app .svc-name { font-weight: 600; color: var(--ink); }
.theme-app .svc-tier { display: block; font-family: var(--font-mono); font-size: var(--fs-12); color: var(--ink-3); margin-top: 2px; }

/* Status pills — subtle, sharp corners */
.theme-app .pill { display: inline-flex; align-items: center; gap: var(--sp-2); padding: 2px var(--sp-2); font-family: var(--font-mono); font-size: 11px; text-transform: uppercase; letter-spacing: 0.06em; border: var(--bw-1) solid var(--rule); background: var(--surface); color: var(--ink-2); border-radius: 2px; }
.theme-app .pill::before { content: ""; width: 6px; height: 6px; background: var(--ink-4); border-radius: 50%; }
.theme-app .pill--good   { color: var(--good); border-color: #BEDDC9; background: #EEF6F0; }
.theme-app .pill--good::before { background: var(--good); }
.theme-app .pill--warn   { color: var(--warn); border-color: #E8C9A1; background: #FBF1E2; }
.theme-app .pill--warn::before { background: var(--warn); }
.theme-app .pill--bad    { color: var(--bad);  border-color: #E5BEB7; background: #FAEBE7; }
.theme-app .pill--bad::before { background: var(--bad); }
.theme-app .pill--info   { color: var(--info); border-color: #BCD0E6; background: #ECF2F9; }
.theme-app .pill--info::before { background: var(--info); }

/* Buttons — utility, sized for dense layouts */
.theme-app .btn { display: inline-flex; align-items: center; gap: var(--sp-2); padding: 6px 12px; font-family: var(--font-body); font-size: var(--fs-13, var(--fs-14)); font-weight: 500; line-height: 1.3; border-radius: var(--r-sm); border: var(--bw-1) solid var(--rule); background: var(--surface); color: var(--ink); cursor: pointer; transition: all var(--dur-1) var(--ease); text-decoration: none; white-space: nowrap; }
.theme-app .btn:hover { background: var(--bg-row); border-color: var(--rule-strong); text-decoration: none; }
.theme-app .btn--primary { background: var(--ink); color: #FFFFFF; border-color: var(--ink); }
.theme-app .btn--primary:hover { background: #000; border-color: #000; }
.theme-app .btn--sm { padding: 3px 10px; font-size: var(--fs-12); }

/* Quick actions tile grid */
.theme-app .qa-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--sp-1); background: var(--rule); border: var(--bw-1) solid var(--rule); }
.theme-app .qa { background: var(--surface); padding: var(--sp-5); display: flex; flex-direction: column; gap: var(--sp-2); text-decoration: none; color: inherit; transition: background var(--dur-1) var(--ease); }
.theme-app .qa:hover { background: var(--bg-row); text-decoration: none; }
.theme-app .qa__label { font-family: var(--font-mono); font-size: var(--fs-12); color: var(--ink-3); text-transform: uppercase; letter-spacing: 0.08em; }
.theme-app .qa__title { font-family: var(--font-display); font-size: var(--fs-16); font-weight: 600; color: var(--ink); }
.theme-app .qa__desc  { color: var(--ink-3); font-size: var(--fs-13, var(--fs-14)); }

/* KPI ribbon */
.theme-app .kpi-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--sp-1); background: var(--rule); border: var(--bw-1) solid var(--rule); margin-bottom: var(--sp-6); }
.theme-app .kpi { background: var(--surface); padding: var(--sp-5); display: flex; flex-direction: column; gap: var(--sp-2); }
.theme-app .kpi__label { font-family: var(--font-mono); font-size: var(--fs-12); color: var(--ink-3); text-transform: uppercase; letter-spacing: 0.08em; }
.theme-app .kpi__value { font-family: var(--font-display); font-size: var(--fs-32); font-weight: 600; color: var(--ink); line-height: 1; letter-spacing: -0.02em; }
.theme-app .kpi__sub   { font-family: var(--font-mono); font-size: var(--fs-12); color: var(--ink-3); }
.theme-app .kpi__sub--good { color: var(--good); }
.theme-app .kpi__sub--bad  { color: var(--bad); }

/* Empty state — quiet */
.theme-app .empty { padding: var(--sp-12) var(--sp-5); text-align: center; color: var(--ink-3); }
.theme-app .empty p { margin-bottom: var(--sp-5); }

/* ============================================================
   Responsive — proper mobile pass
   Breakpoints: 980 (tablet), 720 (large phone), 480 (phone)
   ============================================================ */

@media (max-width: 980px) {
  /* Marketing: nav links collapse, stats + grids reduce to 2 cols */
  .theme-marketing .nav__links { display: none; }
  .theme-marketing .container { padding: 0 var(--sp-5); }
  .theme-marketing .hero { padding: var(--sp-16) 0 var(--sp-12); }
  .theme-marketing .section { padding: var(--sp-16) 0; }
  .theme-marketing .product-grid,
  .theme-marketing .steps,
  .theme-marketing .stats,
  .theme-marketing .footer__grid { grid-template-columns: 1fr 1fr; }

  /* App: drop sidebar, simpler topbar */
  .theme-app .console { grid-template-columns: 1fr; }
  .theme-app .sidebar { display: none; }
  .theme-app .pane { padding: var(--sp-5); }
  .theme-app .topbar { padding: var(--sp-3) var(--sp-5); }
  .theme-app .qa-grid, .theme-app .kpi-row { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 720px) {
  /* Marketing typography softens */
  .theme-marketing h1 { font-size: var(--fs-40); letter-spacing: -0.02em; }
  .theme-marketing h2 { font-size: var(--fs-32); }
  .theme-marketing .lede { font-size: var(--fs-18); }
  .theme-marketing .hero h1 { max-width: none; }
  /* Buttons stay inline-sized; just allow the row to wrap */
  .theme-marketing .hero__actions { flex-wrap: wrap; gap: var(--sp-2); }

  /* New funnel sections — collapse to single column */
  .theme-marketing .problem,
  .theme-marketing .quote,
  .theme-marketing .faq,
  .theme-marketing .cta { padding: var(--sp-12) 0; }
  .theme-marketing .problem__grid,
  .theme-marketing .faq__grid { grid-template-columns: 1fr; gap: var(--sp-8); }
  .theme-marketing .pricing-strip__grid { grid-template-columns: 1fr; gap: var(--sp-4); }
  .theme-marketing .quote__text { font-size: var(--fs-24); }
  .theme-marketing .cta__title { font-size: var(--fs-32); }
  .theme-marketing .trust__row { justify-content: center; gap: var(--sp-5); }
  .theme-marketing .page-header h1 { font-size: var(--fs-32); }
  .theme-marketing .page-header p { font-size: var(--fs-16); }
  .theme-marketing .auth-card { padding: var(--sp-8) var(--sp-6); }

  /* Marketing: contact section stacks */
  .theme-marketing .container[style*="grid-template-columns:1.2fr"] {
    grid-template-columns: 1fr !important;
    gap: var(--sp-8) !important;
  }

  /* Marketing: collapse stats and grids to single col */
  .theme-marketing .product-grid,
  .theme-marketing .steps,
  .theme-marketing .stats,
  .theme-marketing .footer__grid { grid-template-columns: 1fr; }
  .theme-marketing .stats { gap: var(--sp-5); padding: var(--sp-8) 0; }
  .theme-marketing .steps { gap: var(--sp-8); }
  .theme-marketing .footer__grid { gap: var(--sp-8); }

  /* App: KPI ribbon and quick actions to single col */
  .theme-app .qa-grid, .theme-app .kpi-row { grid-template-columns: 1fr; }
  .theme-app .pane__header { flex-direction: column; align-items: flex-start; gap: var(--sp-3); }
  .theme-app .pane__header > div:last-child { display: flex; gap: var(--sp-2); flex-wrap: wrap; }
  .theme-app h1 { font-size: var(--fs-24); }

  /* App: side-by-side activity+mandate stacks */
  .theme-app .pane > div[style*="grid-template-columns: 1.5fr"] {
    grid-template-columns: 1fr !important;
  }

  /* App: convert the service table into stacked cards on mobile.
     This gives each row its own block instead of a tiny horizontal table. */
  .theme-app .svc-table,
  .theme-app .svc-table thead,
  .theme-app .svc-table tbody,
  .theme-app .svc-table tr,
  .theme-app .svc-table td,
  .theme-app .svc-table th { display: block; width: 100%; }
  .theme-app .svc-table thead { display: none; }
  .theme-app .svc-table tr {
    border-bottom: var(--bw-1) solid var(--rule);
    padding: var(--sp-4) var(--sp-5);
  }
  .theme-app .svc-table tr:last-child { border-bottom: none; }
  .theme-app .svc-table tr:hover td { background: transparent; }
  .theme-app .svc-table td {
    padding: var(--sp-1) 0;
    border: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: var(--sp-3);
    font-size: var(--fs-14);
  }
  /* Reveal column meaning via data-label so each value reads as "Label: value" */
  .theme-app .svc-table td[data-label]::before {
    content: attr(data-label);
    font-family: var(--font-mono);
    font-size: var(--fs-12);
    color: var(--ink-3);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    flex-shrink: 0;
  }
  /* The first td (service name) gets full-width, no label */
  .theme-app .svc-table td:first-child {
    flex-direction: column;
    align-items: flex-start;
    padding-bottom: var(--sp-3);
    border-bottom: var(--bw-1) dashed var(--rule);
    margin-bottom: var(--sp-3);
  }
  .theme-app .svc-table td:last-child {
    padding-top: var(--sp-3);
    border-top: var(--bw-1) dashed var(--rule);
    margin-top: var(--sp-3);
    justify-content: flex-end;
  }
}

@media (max-width: 480px) {
  /* Phone: tighten padding further, hero scales again */
  .theme-marketing .container { padding: 0 var(--sp-4); }
  .theme-marketing .hero { padding: var(--sp-12) 0 var(--sp-10); }
  .theme-marketing .hero h1 { font-size: var(--fs-32); line-height: 1.1; }
  .theme-marketing .hero .lede { font-size: var(--fs-16); }
  .theme-marketing .section { padding: var(--sp-12) 0; }
  .theme-marketing .product { padding: var(--sp-5); }

  .theme-app .pane { padding: var(--sp-4); }
  .theme-app .topbar { padding: var(--sp-3) var(--sp-4); }
  .theme-app .topbar__user span { display: none; }
  .theme-app h1 { font-size: var(--fs-20); }
  .theme-app .pane__header { padding-bottom: var(--sp-4); margin-bottom: var(--sp-5); }
  .theme-app .kpi { padding: var(--sp-4); }
  .theme-app .kpi__value { font-size: var(--fs-24); }
  .theme-app .qa { padding: var(--sp-4); }
  .theme-app .block__header { padding: var(--sp-3) var(--sp-4); }
  .theme-app .block__body { padding: var(--sp-4); }
}

/* ── Mobile hamburger + drawer (added 2026-05) ─────────────────────── */
.theme-app .topbar__burger{
  display:none;background:transparent;border:1px solid var(--rule);
  width:36px;height:36px;border-radius:6px;cursor:pointer;
  flex-direction:column;align-items:center;justify-content:center;gap:4px;
  margin-right:var(--sp-3);padding:0;
}
.theme-app .topbar__burger span{
  display:block;width:18px;height:2px;background:var(--ink);border-radius:2px;
  transition:transform .2s, opacity .2s;
}
.theme-app .topbar__burger[aria-expanded="true"] span:nth-child(1){transform:translateY(6px) rotate(45deg)}
.theme-app .topbar__burger[aria-expanded="true"] span:nth-child(2){opacity:0}
.theme-app .topbar__burger[aria-expanded="true"] span:nth-child(3){transform:translateY(-6px) rotate(-45deg)}
.theme-app .sidebar-backdrop{
  display:none;position:fixed;inset:0;background:rgba(0,0,0,.4);
  z-index:40;backdrop-filter:blur(2px);
}
.theme-app .sidebar-backdrop.is-open{display:block}

@media (max-width:980px){
  .theme-app .topbar__burger{display:flex}
  .theme-app .sidebar{
    display:block;position:fixed;top:0;left:0;bottom:0;width:260px;
    transform:translateX(-100%);transition:transform .25s ease;
    z-index:50;background:var(--bg-canvas);overflow-y:auto;
    box-shadow:0 0 24px rgba(0,0,0,.15);
  }
  .theme-app .sidebar.is-open{transform:translateX(0)}
  .theme-app .topbar{padding:var(--sp-3) var(--sp-4)}
  .theme-app .topbar__user-name{display:none}
}

/* ── Polish: friendlier hover + active states ──────────────────────── */
.theme-app .sidebar__link{transition:background .12s, color .12s, border-left-color .12s}
.theme-app .sidebar__link:hover{padding-left:calc(var(--sp-5) + 2px)}
.theme-app .topbar{box-shadow:0 1px 0 var(--rule)}
.theme-app .topbar__avatar{box-shadow:0 0 0 2px var(--bg-row)}

/* ============================================================
   GLASSMORPHISM DARK THEME
   ============================================================ */
.theme-glass {
  --bg:           #0a0a0f;
  --bg-elevated:  rgba(255, 255, 255, 0.03);
  --bg-glass:     rgba(255, 255, 255, 0.05);
  --ink:          #f0f0f5;
  --ink-2:        #a0a0b0;
  --ink-3:        #707080;
  --ink-4:        #505060;
  --rule:         rgba(255, 255, 255, 0.08);
  --accent:       #6366f1;
  --accent-ink:   #ffffff;
  --accent-soft:  rgba(99, 102, 241, 0.15);
  --good:         #10b981;
  --warn:         #f59e0b;
  --bad:          #ef4444;

  --font-display: Inter Tight, Inter, system-ui, -apple-system, sans-serif;
  --font-body:    Inter, system-ui, -apple-system, sans-serif;
  --font-mono:    JetBrains Mono, IBM Plex Mono, ui-monospace, monospace;

  background: var(--bg);
  background-image: 
    radial-gradient(ellipse at 20% 0%, rgba(99, 102, 241, 0.15) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 100%, rgba(139, 92, 246, 0.1) 0%, transparent 50%);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--fs-16);
  line-height: var(--lh-normal);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

.theme-glass h1, .theme-glass h2, .theme-glass h3, .theme-glass h4 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin: 0;
  line-height: var(--lh-tight);
}
.theme-glass h1 { font-size: var(--fs-56); letter-spacing: -0.03em; }
.theme-glass h2 { font-size: var(--fs-40); }
.theme-glass h3 { font-size: var(--fs-24); }
.theme-glass h4 { font-size: var(--fs-18); }
.theme-glass p { color: var(--ink-2); line-height: var(--lh-relaxed); margin: 0; }
.theme-glass a { color: var(--accent); text-decoration: none; }
.theme-glass a:hover { text-decoration: underline; }

.theme-glass .container { max-width: 1180px; margin: 0 auto; padding: 0 var(--sp-6); }
.theme-glass .section { padding: var(--sp-24) 0; }

.theme-glass .glass-card {
  background: var(--bg-glass);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--rule);
  border-radius: var(--r-lg);
  padding: var(--sp-8);
}

.theme-glass .glass-card--hover:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.15);
  transform: translateY(-2px);
  transition: all var(--dur-2) var(--ease);
}

.theme-glass .glass-hero {
  text-align: center;
  padding: var(--sp-32) 0;
}

.theme-glass .glass-hero h1 {
  background: linear-gradient(135deg, #fff 0%, #a5b4fc 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: var(--sp-6);
}

.theme-glass .glass-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--sp-6);
}

.theme-glass .nav {
  display: flex; align-items: center; justify-content: space-between;
  height: 64px;
  background: rgba(10, 10, 15, 0.8);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: var(--bw-1) solid var(--rule);
  position: sticky; top: 0; z-index: 50;
}
.theme-glass .nav__inner { max-width: 1180px; margin: 0 auto; padding: 0 var(--sp-6); display: flex; align-items: center; justify-content: space-between; width: 100%; }
.theme-glass .nav__brand { font-family: var(--font-display); font-weight: 600; font-size: var(--fs-16); letter-spacing: -0.01em; color: var(--ink); }
.theme-glass .nav__links { display: flex; gap: var(--sp-8); }
.theme-glass .nav__links a { color: var(--ink-2); font-size: var(--fs-15); }
.theme-glass .nav__links a:hover { color: var(--ink); text-decoration: none; }

.theme-glass .btn {
  display: inline-flex; align-items: center; gap: var(--sp-2);
  padding: 10px 18px;
  font-family: var(--font-body);
  font-size: var(--fs-14);
  font-weight: 500;
  border-radius: var(--r-md);
  border: var(--bw-1) solid transparent;
  cursor: pointer; transition: all var(--dur-1) var(--ease);
  text-decoration: none;
  white-space: nowrap;
}
.theme-glass .btn--primary { 
  background: linear-gradient(135deg, var(--accent) 0%, #8b5cf6 100%); 
  color: #fff; 
  border: none;
}
.theme-glass .btn--primary:hover { 
  transform: translateY(-1px);
  box-shadow: 0 4px 20px rgba(99, 102, 241, 0.4);
  text-decoration: none; 
}
.theme-glass .btn--ghost { background: transparent; color: var(--ink-2); border-color: var(--rule); }
.theme-glass .btn--ghost:hover { color: var(--ink); border-color: var(--ink-3); }

.theme-glass .footer {
  background: rgba(0, 0, 0, 0.3);
  border-top: var(--bw-1) solid var(--rule);
  padding: var(--sp-16) 0 var(--sp-8);
  margin-top: var(--sp-16);
}
.theme-glass .footer__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--sp-8); }
.theme-glass .footer h5 { font-size: var(--fs-14); font-weight: 600; color: var(--ink); margin: 0 0 var(--sp-4); }
.theme-glass .footer ul { list-style: none; padding: 0; margin: 0; }
.theme-glass .footer li { margin-bottom: var(--sp-2); }
.theme-glass .footer a { color: var(--ink-3); font-size: var(--fs-14); }
.theme-glass .footer a:hover { color: var(--ink); }

@media (max-width: 768px) {
  .theme-glass .footer__grid { grid-template-columns: repeat(2, 1fr); }
  .theme-glass h1 { font-size: var(--fs-40); }
  .theme-glass .glass-hero { padding: var(--sp-16) 0; }
}
