/* ==========================================================================
   apple-web-kit-dash.css  ·  Digisom "Apple dash" kit  ·  v1.0  ·  2026-09-27
   Reference build: ~/Desktop/Digisoul/realm-app/worker/public/hq/index.html (Realm HQ 2.1)
   Rules it encodes: /hig (Apple 2026, Liquid Glass) for the look; /artifact-standard for the architecture.

   HOW TO USE
   1. Paste this file at the top of the dash's <style> (single-file boards) or link it.
   2. Map the board's lanes onto the palette, on :root, e.g.
        :root{--money:var(--red);--club:var(--teal);--design:var(--amber);--people:var(--indigo);--held:var(--slate)}
      Every lane-aware component reads --lane, set per element: style="--lane:var(--money)".
      Because the palette tokens swap per theme and contrast, mapped lanes follow automatically.
   3. Class vocabulary = the Digisom dash vocabulary (Studio Dash, Realm HQ), so an existing dash
      restyles by swapping its CSS and adding the shell:
        .ak-shell > .ak-sidebar(.glass) + .ak-main > .ak-toolbar + .ak-titlebar(h1.ak-large) + content
      Content: .legend/.lg/.sw/.stamp · .glance/.tile · .drawer · details.sec > summary · .door > button
               · .chev · .bar · .hb · .pill · table · .seg · .kv · .stats/.stat · .note · .held-line
   4. Themes: light on :root; dark via prefers-color-scheme or :root[data-theme="dark"];
      light forced by :root[data-theme="light"]. Increased contrast via prefers-contrast:more or
      :root[data-contrast="more"] (test hook). Reduced transparency / motion handled at the bottom.

   LAWS BAKED IN (do not "fix" them away)
   - Glass (.glass) ONLY on the toolbar groups, sidebar, sheets, menus. Never on cards, rows, tables.
   - Grounds and cards are warm neutral with G <= R in every theme. Lanes are indicators, bars, glyphs,
     figures: never a card or page fill. Status pills: coloured text + rule on a neutral fill.
   - No chip rows: nothing here flex-wraps a row of pills. Filters are .seg or <select>.
   - Doors open in place: summary / .door > button toggle in place; the chevron rotates.
   - Concentric radii: inner radius = outer radius - padding (see --r-* notes).
   - Type: system stack only (SF on Apple devices). Figures tabular. No letter-spacing on SF text.
   ========================================================================== */

:root{
  color-scheme:light;
  /* type: Apple ramp at 17px = 1rem (Large Title 34/41 ... Caption 2 11/13) */
  --font-text:-apple-system,BlinkMacSystemFont,"SF Pro Text",system-ui,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;
  --font-display:-apple-system,BlinkMacSystemFont,"SF Pro Display",system-ui,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;
  --font-rounded:ui-rounded,"SF Pro Rounded",-apple-system,system-ui,sans-serif;
  --font-serif:ui-serif,"New York",Georgia,serif;
  --font-mono:ui-monospace,"SF Mono",Menlo,Consolas,monospace;
  --fs-large:34px;--lh-large:41px;  --fs-t1:28px;--lh-t1:34px;  --fs-t2:22px;--lh-t2:28px;  --fs-t3:20px;--lh-t3:25px;
  --fs-head:17px;--lh-head:22px;    --fs-body:17px;--lh-body:22px; --fs-call:16px;--lh-call:21px; --fs-sub:15px;--lh-sub:20px;
  --fs-foot:13px;--lh-foot:18px;    --fs-cap1:12px;--lh-cap1:16px; --fs-cap2:11px;--lh-cap2:13px;

  /* grounds: Apple grouped background, tinted warm */
  --ground:#F2F0EA;      /* systemGroupedBackground, warm */
  --card:#FFFFFF;        /* secondarySystemGroupedBackground */
  --card2:#F8F6F1;       /* tertiary / sunk rows, inputs */
  --fill:rgba(118,108,86,.12);   /* systemFill, warm: segmented track, neutral pill */
  --fill2:rgba(118,108,86,.07);  /* quaternary fill: hover, row highlight */
  --rule:#DDD9CF;        /* separator */
  --ink:#1D1B16;--ink2:#5C5648;--ink3:#736B59;   /* label / secondary / tertiary (4.7:1 on card) */
  --onlane:#FFFFFF;
  --focus:#39477F;

  /* palette: meaning colours (map lanes onto these). Light / dark / contrast variants below. */
  --red:#A32B1C;--teal:#0F5C48;--amber:#875900;--indigo:#39477F;--violet:#6B3FA0;--slate:#5A6068;
  /* status: never borrow a lane hue */
  --ok:#2F6B3A;--warn:#B4540A;--bad:#A3265C;--out:#736B59;--badge:#FF383C;

  /* Liquid Glass (regular variant: text sits on it) */
  --glass:rgba(248,246,240,.68);
  --glass-edge:rgba(255,255,255,.75);
  --glass-fx:blur(24px) saturate(1.4);
  --glass-shadow:0 8px 28px rgba(40,30,10,.10),0 1px 2px rgba(40,30,10,.06),inset 0 .5px 0 rgba(255,255,255,.8);
  --card-shadow:0 1px 2px rgba(40,30,10,.05);

  /* radii (concentric): sidebar 22 - pad 8 = row 14; card 16 - pad 6 = inner 10; capsule 999 */
  --r-xl:22px;--r-lg:16px;--r-md:10px;--r-sm:6px;--r-cap:999px;

  --ease:cubic-bezier(.32,.72,0,1);--dur:.2s;
}
@media (prefers-color-scheme:dark){:root:not([data-theme="light"]){
  color-scheme:dark;
  --ground:#1C1B19;--card:#2A2825;--card2:#33312D;--fill:rgba(214,204,182,.16);--fill2:rgba(214,204,182,.08);--rule:#3E3B35;
  --ink:#F2EFE6;--ink2:#BDB6A4;--ink3:#A0988A;--onlane:#1C1B19;--focus:#8D9BD8;
  --red:#F18D7B;--teal:#4FBE9C;--amber:#D9A63C;--indigo:#8D9BD8;--violet:#B08BE0;--slate:#9AA1AB;
  --ok:#6FC47F;--warn:#F08A3E;--bad:#E57AA0;--out:#A0988A;--badge:#FF4245;
  --glass:rgba(42,40,37,.64);--glass-edge:rgba(242,239,230,.12);
  --glass-shadow:0 8px 28px rgba(0,0,0,.35),0 1px 2px rgba(0,0,0,.3),inset 0 .5px 0 rgba(255,255,255,.08);
  --card-shadow:0 1px 2px rgba(0,0,0,.25);
}}
:root[data-theme="dark"]{
  color-scheme:dark;
  --ground:#1C1B19;--card:#2A2825;--card2:#33312D;--fill:rgba(214,204,182,.16);--fill2:rgba(214,204,182,.08);--rule:#3E3B35;
  --ink:#F2EFE6;--ink2:#BDB6A4;--ink3:#A0988A;--onlane:#1C1B19;--focus:#8D9BD8;
  --red:#F18D7B;--teal:#4FBE9C;--amber:#D9A63C;--indigo:#8D9BD8;--violet:#B08BE0;--slate:#9AA1AB;
  --ok:#6FC47F;--warn:#F08A3E;--bad:#E57AA0;--out:#A0988A;--badge:#FF4245;
  --glass:rgba(42,40,37,.64);--glass-edge:rgba(242,239,230,.12);
  --glass-shadow:0 8px 28px rgba(0,0,0,.35),0 1px 2px rgba(0,0,0,.3),inset 0 .5px 0 rgba(255,255,255,.08);
  --card-shadow:0 1px 2px rgba(0,0,0,.25);
}
/* increased contrast, light */
@media (prefers-contrast:more) and (prefers-color-scheme:light){:root:not([data-theme="dark"]){
  --ink:#000000;--ink2:#3F3A30;--ink3:#4F4839;--rule:#A89F88;--fill:rgba(80,70,50,.18);
  --red:#8A1F12;--teal:#0A4A3A;--amber:#7A5307;--indigo:#2C3868;--violet:#55308A;--slate:#474C53;
  --ok:#22552C;--warn:#8F4106;--bad:#851C49;--out:#4F4839;--glass:rgba(248,246,240,.96);--glass-edge:#3F3A30;
}}
@media (prefers-contrast:more){:root[data-theme="light"]{
  --ink:#000000;--ink2:#3F3A30;--ink3:#4F4839;--rule:#A89F88;--fill:rgba(80,70,50,.18);
  --red:#8A1F12;--teal:#0A4A3A;--amber:#7A5307;--indigo:#2C3868;--violet:#55308A;--slate:#474C53;
  --ok:#22552C;--warn:#8F4106;--bad:#851C49;--out:#4F4839;--glass:rgba(248,246,240,.96);--glass-edge:#3F3A30;
}}
:root[data-contrast="more"]:not([data-theme="dark"]){
  --ink:#000000;--ink2:#3F3A30;--ink3:#4F4839;--rule:#A89F88;--fill:rgba(80,70,50,.18);
  --red:#8A1F12;--teal:#0A4A3A;--amber:#7A5307;--indigo:#2C3868;--violet:#55308A;--slate:#474C53;
  --ok:#22552C;--warn:#8F4106;--bad:#851C49;--out:#4F4839;--glass:rgba(248,246,240,.96);--glass-edge:#3F3A30;
}
/* increased contrast, dark */
@media (prefers-contrast:more) and (prefers-color-scheme:dark){:root:not([data-theme="light"]){
  --ink:#FFFFFF;--ink2:#DAD4C4;--ink3:#C3BBA7;--rule:#6A6457;--fill:rgba(230,220,200,.24);
  --red:#F28D7B;--teal:#72D8B6;--amber:#ECC063;--indigo:#AEB9EE;--violet:#CBAEF2;--slate:#BAC0C8;
  --ok:#8FD89C;--warn:#F7A566;--bad:#F09CBB;--out:#C3BBA7;--glass:rgba(42,40,37,.97);--glass-edge:#DAD4C4;
}}
@media (prefers-contrast:more){:root[data-theme="dark"]{
  --ink:#FFFFFF;--ink2:#DAD4C4;--ink3:#C3BBA7;--rule:#6A6457;--fill:rgba(230,220,200,.24);
  --red:#F28D7B;--teal:#72D8B6;--amber:#ECC063;--indigo:#AEB9EE;--violet:#CBAEF2;--slate:#BAC0C8;
  --ok:#8FD89C;--warn:#F7A566;--bad:#F09CBB;--out:#C3BBA7;--glass:rgba(42,40,37,.97);--glass-edge:#DAD4C4;
}}
:root[data-contrast="more"][data-theme="dark"]{
  --ink:#FFFFFF;--ink2:#DAD4C4;--ink3:#C3BBA7;--rule:#6A6457;--fill:rgba(230,220,200,.24);
  --red:#F28D7B;--teal:#72D8B6;--amber:#ECC063;--indigo:#AEB9EE;--violet:#CBAEF2;--slate:#BAC0C8;
  --ok:#8FD89C;--warn:#F7A566;--bad:#F09CBB;--out:#C3BBA7;--glass:rgba(42,40,37,.97);--glass-edge:#DAD4C4;
}
@media (prefers-color-scheme:dark){:root[data-contrast="more"]:not([data-theme="light"]){
  --ink:#FFFFFF;--ink2:#DAD4C4;--ink3:#C3BBA7;--rule:#6A6457;--fill:rgba(230,220,200,.24);
  --red:#F28D7B;--teal:#72D8B6;--amber:#ECC063;--indigo:#AEB9EE;--violet:#CBAEF2;--slate:#BAC0C8;
  --ok:#8FD89C;--warn:#F7A566;--bad:#F09CBB;--out:#C3BBA7;--glass:rgba(42,40,37,.97);--glass-edge:#DAD4C4;
}}

