/* ===========================================================================
   01 — Design tokens
   The palette is the app's own Cobalt & Papaya system
   (lib/core/theme/app_theme.dart) so the site and the product cannot drift
   apart. Nothing here is invented.

   This file owns colour, type, spacing and both themes. No component styles
   live here, and no other file redefines a token — if a colour looks wrong
   anywhere on the site, it is changed here, once.
   =========================================================================== */

:root{
  /* brand, straight from AppColors */
  --cobalt:#00327D;        /* primary            */
  --cobalt-2:#0047AB;      /* primaryContainer   */
  --cobalt-soft:#DAE2FF;   /* primaryFixed       */
  --papaya:#FC8045;        /* secondaryContainer */
  --burnt:#A33E02;         /* secondary          */
  --ember:#672400;         /* onSecondaryContainer */
  --cream:#FFDBCD;         /* secondaryFixed     */
  --udhaar:#DC2626;
  --paid:#16A34A;

  /* neutrals, biased toward the cobalt so greys never read as default grey */
  --bg:#F5F7FB;
  --surface:#FFFFFF;
  --surface-2:#EFF2F8;
  --ink:#141821;
  --ink-2:#434653;         /* onSurfaceVariant */
  --ink-3:#5E6372;         /* outline, darkened from #737784 so small text passes AA (5.6:1) */
  --rule:#E2E7F1;
  --rule-2:#CFD6E6;

  /* role tokens — components only ever use these */
  --brand-bg:var(--cobalt);
  --brand-bg-2:#002561;
  --on-brand:#FFFFFF;
  --on-brand-dim:#A9BEEA;
  --brand-text:var(--cobalt);
  --accent-text:var(--burnt);
  --cta:var(--papaya);
  --on-cta:#43160B;

  --sh-1:0 1px 2px rgba(10,20,45,.06), 0 1px 1px rgba(10,20,45,.04);
  --sh-2:0 4px 16px rgba(10,20,45,.07), 0 1px 3px rgba(10,20,45,.05);
  --sh-3:0 18px 48px rgba(10,20,45,.14), 0 4px 12px rgba(10,20,45,.07);
  --sh-cta:0 8px 22px rgba(252,128,69,.34);

  --ff-display:"Bricolage Grotesque","Segoe UI",system-ui,sans-serif;
  --ff-body:"Inter","Segoe UI",system-ui,-apple-system,sans-serif;

  --wrap:1180px;
  --gut:16px;
  --r-sm:8px; --r-md:12px; --r-lg:18px; --r-xl:26px;
}

/* Dark theme. The OS preference applies unless the visitor has chosen a
   theme, in which case data-theme on <html> wins in both directions — which
   is why the media query is guarded and then repeated as an attribute rule. */
@media (prefers-color-scheme: dark){
  :root:not([data-theme="light"]){
    --bg:#070D1B;
    --surface:#0E1628;
    --surface-2:#16203A;
    --ink:#EDF1FA;
    --ink-2:#AFB8CD;
    --ink-3:#7C87A2;
    --rule:#1D2740;
    --rule-2:#2A3755;

    --brand-bg:#06234F;
    --brand-bg-2:#041836;
    --on-brand:#FFFFFF;
    --on-brand-dim:#9DB4E6;
    --brand-text:#A5BDFF;
    --accent-text:#FF9F6E;
    --on-cta:#3A1206;
    --udhaar:#FF6B6B;
    --paid:#4ADE80;

    --sh-1:0 1px 2px rgba(0,0,0,.4);
    --sh-2:0 4px 16px rgba(0,0,0,.45);
    --sh-3:0 18px 48px rgba(0,0,0,.6);
    --sh-cta:0 8px 22px rgba(252,128,69,.2);
  }
}
:root[data-theme="dark"]{
  --bg:#070D1B; --surface:#0E1628; --surface-2:#16203A;
  --ink:#EDF1FA; --ink-2:#AFB8CD; --ink-3:#7C87A2;
  --rule:#1D2740; --rule-2:#2A3755;
  --brand-bg:#06234F; --brand-bg-2:#041836;
  --on-brand:#FFFFFF; --on-brand-dim:#9DB4E6;
  --brand-text:#A5BDFF; --accent-text:#FF9F6E; --on-cta:#3A1206;
  --udhaar:#FF6B6B; --paid:#4ADE80;
  --sh-1:0 1px 2px rgba(0,0,0,.4);
  --sh-2:0 4px 16px rgba(0,0,0,.45);
  --sh-3:0 18px 48px rgba(0,0,0,.6);
  --sh-cta:0 8px 22px rgba(252,128,69,.2);
}
