:root{--s-1:4px;--s-2:8px;--s-3:12px;--s-4:16px;--s-5:20px;--s-6:24px;--s-8:32px;--s-10:40px;--s-12:48px;--s-16:64px;--r-2:2px;--r-xs:8px;--r-sm:8px;--r-md:12px;--r-lg:16px;--r-pill:999px;--r-control:8px;--r-card:12px;--r-dialog:16px;--fs-12:12px;--lh-12:16px;--fs-13:13px;--lh-13:18px;--fs-14:14px;--lh-14:20px;--fs-16:16px;--lh-16:24px;--fs-18:18px;--lh-18:26px;--fs-20:20px;--lh-20:28px;--fs-24:24px;--lh-24:32px;--fs-28:28px;--lh-28:36px;--fs-32:32px;--lh-32:40px;--fs-40:40px;--lh-40:48px;--fs-num-sm:64px;--fs-num-hero:min(160px, var(--num-fit, 160px));--hit-min:44px;--hit-main:64px;--hit-xl:96px;--w-rail:240px;--w-rail-collapsed:72px;--w-content:1120px;--w-form:720px;--w-focus:420px;--w-customer:480px;--w-dialog:560px;--w-dialog-wide:720px;--w-sheet:440px;--w-preview:360px;--h-appbar:56px;--h-bottombar:56px;--h-savebar:56px;--h-banner:44px;--h-row:56px;--h-row-dense:40px;--h-table-row:48px;--w-rail-hq:232px;--w-rail-icons:64px;--w-list:1200px;--w-main:760px;--w-aside:320px;--w-subnav:200px;--w-frame:560px;--w-split-form:560px;--w-split-min:360px;--w-palette:640px;--h-palette-list:420px;--h-actbar:44px;--w-date:304px;--w-phone:320px;--w-qr:160px;--w-drop:128px;--h-chart:180px;--w-tile:40px;--w-tile-lg:56px;--h-band:120px;--z-sticky:10;--z-appbar:20;--z-banner:30;--z-popover:40;--z-overlay:50;--z-toast:60;--m-fast:120ms;--m-base:200ms;--m-slow:320ms;--ease:cubic-bezier(.2,0,0,1);--ease-out:cubic-bezier(0,0,0,1);--tv-fs-title:4cqh;--tv-fs-head:3cqh;--tv-fs-code:9cqh;--tv-fs-note:2.4cqh;--tv-r:1.5cqh;--tv-gap:2cqh;--p-sticker-w:90mm;--p-tent-w:100mm;--p-tent-h:140mm;--p-qr:50mm;--p-quiet:4mm;--p-r:4mm;--p-r-lg:6mm;--p-fs-head:7mm;--p-fs-body:4mm;--p-cut:0.3mm;--f-ui:"Inter", "IBM Plex Sans Arabic", system-ui, -apple-system, "Segoe UI", sans-serif;--f-sans:var(--f-ui);--f-num:"Rubik Numerals", "Inter", "IBM Plex Sans Arabic", system-ui, sans-serif;--f-mono:ui-monospace, "SF Mono", Menlo, Consolas, monospace;--f-site:"Bricolage Grotesque", "Rubik", "Inter", "IBM Plex Sans Arabic", system-ui, sans-serif;--f-display:var(--f-ui);--fw-regular:400;--fw-medium:500;--fw-strong:600;--night-50:#eef2ff;--night-100:#dfe5fb;--night-200:#c0cbf3;--night-300:#97a8e6;--night-400:#6b83d6;--night-500:#4560b8;--night-600:#2c4494;--night-700:#1d3173;--night-800:#0f1d4a;--night-900:#0b1430;--night-950:#070c1f;--gold-50:#fffaeb;--gold-100:#fdf0c8;--gold-200:#fbe08e;--gold-300:#f9cd63;--gold-400:#f5b83d;--gold-500:#e8a317;--gold-600:#bf820b;--gold-700:#96650c;--gold-800:#744e10;--gold-900:#5a3d10;--gold-950:#33220a;--dune-50:#f7f6f1;--dune-100:#eceae0;--dune-200:#e0ded3;--dune-300:#c9c7bc;--dune-400:#9aa1b5;--dune-500:#59627d;--dune-600:#3b4560;--dune-700:#1f2a55;--dune-800:#18224a;--dune-900:#0f1733;--dune-950:#070c1f;--dur-1:120ms;--dur-2:200ms;--dur-3:320ms;--ease-standard:cubic-bezier(.2,0,0,1);--ease-exit:cubic-bezier(.4,0,1,1);--kit-radius-sm:12px;--kit-radius:16px;--kit-radius-lg:20px;--c-paper:#ffffff;--c-saffron:#f2a900;--c-saffron-soft:#ffd66b;--c-ok-bg:#e3f3e8;--c-ok-ink:#0b4d2a;--c-wa-bg:#e7f7ee;--c-wa-line:#b9e4c9;--c-wa-solid:#107f43;--c-late-bg:#ffe3d1;--c-late-ink:#a8410c;--c-offer-bg:#fff4d6;--c-tv-panel:#26241f;--t-min:44px;--t-main:64px;--brand:#b5452b;--on-brand:#ffffff}
:root,[data-theme=light]{color-scheme:light;--n-0:#ffffff;--n-1:#f9f8f5;--n-2:#f4f4f1;--n-3:#efede8;--n-4:#e9e7e2;--n-5:#e3e1dc;--n-6:#d6d3cc;--n-7:#c3bfb7;--n-8:#a29d94;--n-9:#8a857d;--n-10:#75716a;--n-11:#5e5a54;--n-12:#161513;--c-bg:#f4f4f1;--c-surface:#ffffff;--c-surface-2:#f9f8f5;--c-ink:#161513;--c-muted:#5e5a54;--c-line:#e3e1dc;--c-line-strong:#8a857d;--c-now:#f2a900;--c-on-now:#161513;--c-now-soft:#fff4d6;--c-ready:#0b6b3a;--c-ready-edge:transparent;--c-ready-soft:#e3f3e8;--c-ready-ink:#0b4d2a;--c-late:#a8410c;--c-late-soft:#ffe3d1;--c-danger:#a3260f;--c-danger-soft:#fde7e2;--c-wa:#107f43;--c-focus:#161513;--c-overlay:rgb(22 21 19 / 0.48);--c-hq:#161513;--c-env-prod:#b5452b;--c-env-staging:#5e5a54;--c-skeleton:#efede8;--c-skeleton-hi:#f9f8f5;--c-chart-axis:#5e5a54;--c-chart-grid:#e3e1dc;--c-chart-good:#0b6b3a;--c-chart-mid:#8a857d;--c-chart-bad:#a8410c;--c-chrome-bg:#1b1a18;--c-chrome-ink:#f4f2ee;--c-chrome-muted:#b5afa6;--c-chrome-line:#2e2c29;--c-chrome-hover:#262522;--c-chrome-selected:#2e2c29;--c-chrome-marker:#f4f2ee;--c-hq-primary:#161513;--c-on-hq-primary:#ffffff;--c-hq-primary-hover:#2e2c29;--c-acting:#3b3a98;--c-on-acting:#ffffff;--c-acting-soft:#ecebfb;--c-acting-ink:#3b3a98;--c-acting-edge:#2b2a7a;--c-site-bg:#f7f6f1;--c-site-surface:#ffffff;--c-site-sunk:#eceae0;--c-site-ink:#0b1430;--c-site-muted:#59627d;--c-site-line:#e0ded3;--c-site-primary:#0f1d4a;--c-site-on-primary:#ffffff;--c-site-primary-hover:#1d3173;--c-site-primary-ink:#1d3173;--c-site-primary-soft:#dfe5fb;--c-site-accent:#e8a317;--c-site-on-accent:#0b1430;--c-site-accent-soft:#fdf0c8;--c-site-glow-1:#f9cd63;--c-site-glow-2:#97a8e6;--c-site-art-stroke:#0b1430;--c-site-art-paper:#ffffff;--c-site-mark-accent:#e8a317;--brand-edge:transparent;--c-accent:var(--brand);--c-on-accent:var(--on-brand);--c-accent-fill-edge:transparent;--c-accent-hover:#9f3a23;--c-accent-press:#8a3220;--c-accent-ink:#a63f27;--c-accent-soft:#fbe9e4;--c-accent-edge:var(--c-accent);--c-accent-ring:var(--c-accent-edge);--c-page-tint:var(--c-bg);--c-band:var(--c-page-tint);--c-on-band:var(--c-ink);--c-band-edge:transparent;--c-alt:var(--c-accent);--c-on-alt:var(--c-on-accent);--c-alt-fill-edge:var(--c-accent-fill-edge);--c-alt-hover:var(--c-accent-hover);--c-alt-press:var(--c-accent-press);--c-alt-ink:var(--c-accent-ink);--c-alt-soft:var(--c-accent-soft);--c-alt-edge:var(--c-accent-edge);--c-brand:var(--c-accent);--c-brand-hover:var(--c-accent-hover);--c-brand-press:var(--c-accent-press);--c-brand-ink:var(--c-accent-ink);--c-brand-soft:var(--c-accent-soft);--c-on-brand:var(--c-on-accent);--c-chart-bar:var(--c-accent-ink);--c-chart-bar-hi:color-mix(in oklab, var(--c-accent-ink) 80%, #000);--e-0:none;--e-1:0 1px 2px rgb(22 21 19 / 0.06);--e-2:0 8px 24px rgb(22 21 19 / 0.12);--e-3:0 24px 64px rgb(22 21 19 / 0.24);}
@media (prefers-color-scheme:dark){:root[data-theme=auto],[data-theme=auto]{color-scheme:dark;--n-0:#1c1b18;--n-1:#24221e;--n-2:#121110;--n-3:#2a2824;--n-4:#2e2c28;--n-5:#36332e;--n-6:#403d37;--n-7:#4f4b44;--n-8:#625e56;--n-9:#77726a;--n-10:#8d877e;--n-11:#a7a199;--n-12:#f4f2ee;--c-bg:#121110;--c-surface:#1c1b18;--c-surface-2:#24221e;--c-ink:#f4f2ee;--c-muted:#a7a199;--c-line:#2e2c28;--c-line-strong:#77726a;--c-now:#f2a900;--c-on-now:#161513;--c-now-soft:#3a2f12;--c-ready:#0b6b3a;--c-ready-edge:#3fa46e;--c-ready-soft:#14301f;--c-ready-ink:#7fd3a0;--c-late:#f0915a;--c-late-soft:#3b2214;--c-danger:#f08a76;--c-danger-soft:#3d1a14;--c-wa:#107f43;--c-focus:#f4f2ee;--c-overlay:rgb(0 0 0 / 0.64);--c-hq:#0b0a09;--c-env-prod:#b5452b;--c-env-staging:#5e5a54;--c-skeleton:#24221e;--c-skeleton-hi:#2e2c28;--c-chart-axis:#a7a199;--c-chart-grid:#2e2c28;--c-chart-good:#2a8f55;--c-chart-mid:#aaa49a;--c-chart-bad:#d9702f;--c-chrome-bg:#0f0e0d;--c-chrome-ink:#f4f2ee;--c-chrome-muted:#b5afa6;--c-chrome-line:#232220;--c-chrome-hover:#1a1917;--c-chrome-selected:#22211f;--c-chrome-marker:#f4f2ee;--c-hq-primary:#f4f2ee;--c-on-hq-primary:#161513;--c-hq-primary-hover:#dcd9d3;--c-acting:#2e2d7a;--c-on-acting:#ffffff;--c-acting-soft:#252454;--c-acting-ink:#c3c1ff;--c-acting-edge:#8f8de8;--c-site-bg:#070c1f;--c-site-surface:#0f1733;--c-site-sunk:#0b1430;--c-site-ink:#f3f1e8;--c-site-muted:#9aa3c0;--c-site-line:#1f2a55;--c-site-primary:#f5b83d;--c-site-on-primary:#070c1f;--c-site-primary-hover:#f9cd63;--c-site-primary-ink:#f9cd63;--c-site-primary-soft:#18224a;--c-site-accent:#97a8e6;--c-site-on-accent:#070c1f;--c-site-accent-soft:#1d2a5c;--c-site-glow-1:#96650c;--c-site-glow-2:#2c4494;--c-site-art-stroke:#f3f1e8;--c-site-art-paper:#18224a;--c-site-mark-accent:#f7f6f1;--brand-edge:transparent;--c-accent:var(--brand);--c-on-accent:var(--on-brand);--c-accent-fill-edge:transparent;--c-accent-hover:#c34f33;--c-accent-press:#a8432c;--c-accent-ink:#e58a6f;--c-accent-soft:#3a221b;--c-accent-edge:var(--c-accent);--c-accent-ring:var(--c-accent-edge);--c-page-tint:var(--c-bg);--c-band:var(--c-page-tint);--c-on-band:var(--c-ink);--c-band-edge:transparent;--c-alt:var(--c-accent);--c-on-alt:var(--c-on-accent);--c-alt-fill-edge:var(--c-accent-fill-edge);--c-alt-hover:var(--c-accent-hover);--c-alt-press:var(--c-accent-press);--c-alt-ink:var(--c-accent-ink);--c-alt-soft:var(--c-accent-soft);--c-alt-edge:var(--c-accent-edge);--c-brand:var(--c-accent);--c-brand-hover:var(--c-accent-hover);--c-brand-press:var(--c-accent-press);--c-brand-ink:var(--c-accent-ink);--c-brand-soft:var(--c-accent-soft);--c-on-brand:var(--c-on-accent);--c-chart-bar:var(--c-accent-ink);--c-chart-bar-hi:color-mix(in oklab, var(--c-accent-ink) 60%, #fff);--e-0:none;--e-1:0 1px 2px rgb(0 0 0 / 0.4);--e-2:0 8px 24px rgb(0 0 0 / 0.5), 0 0 0 1px #2e2c28;--e-3:0 24px 64px rgb(0 0 0 / 0.6), 0 0 0 1px #2e2c28;}}
:root[data-theme=dark],[data-theme=dark]{color-scheme:dark;--n-0:#1c1b18;--n-1:#24221e;--n-2:#121110;--n-3:#2a2824;--n-4:#2e2c28;--n-5:#36332e;--n-6:#403d37;--n-7:#4f4b44;--n-8:#625e56;--n-9:#77726a;--n-10:#8d877e;--n-11:#a7a199;--n-12:#f4f2ee;--c-bg:#121110;--c-surface:#1c1b18;--c-surface-2:#24221e;--c-ink:#f4f2ee;--c-muted:#a7a199;--c-line:#2e2c28;--c-line-strong:#77726a;--c-now:#f2a900;--c-on-now:#161513;--c-now-soft:#3a2f12;--c-ready:#0b6b3a;--c-ready-edge:#3fa46e;--c-ready-soft:#14301f;--c-ready-ink:#7fd3a0;--c-late:#f0915a;--c-late-soft:#3b2214;--c-danger:#f08a76;--c-danger-soft:#3d1a14;--c-wa:#107f43;--c-focus:#f4f2ee;--c-overlay:rgb(0 0 0 / 0.64);--c-hq:#0b0a09;--c-env-prod:#b5452b;--c-env-staging:#5e5a54;--c-skeleton:#24221e;--c-skeleton-hi:#2e2c28;--c-chart-axis:#a7a199;--c-chart-grid:#2e2c28;--c-chart-good:#2a8f55;--c-chart-mid:#aaa49a;--c-chart-bad:#d9702f;--c-chrome-bg:#0f0e0d;--c-chrome-ink:#f4f2ee;--c-chrome-muted:#b5afa6;--c-chrome-line:#232220;--c-chrome-hover:#1a1917;--c-chrome-selected:#22211f;--c-chrome-marker:#f4f2ee;--c-hq-primary:#f4f2ee;--c-on-hq-primary:#161513;--c-hq-primary-hover:#dcd9d3;--c-acting:#2e2d7a;--c-on-acting:#ffffff;--c-acting-soft:#252454;--c-acting-ink:#c3c1ff;--c-acting-edge:#8f8de8;--c-site-bg:#070c1f;--c-site-surface:#0f1733;--c-site-sunk:#0b1430;--c-site-ink:#f3f1e8;--c-site-muted:#9aa3c0;--c-site-line:#1f2a55;--c-site-primary:#f5b83d;--c-site-on-primary:#070c1f;--c-site-primary-hover:#f9cd63;--c-site-primary-ink:#f9cd63;--c-site-primary-soft:#18224a;--c-site-accent:#97a8e6;--c-site-on-accent:#070c1f;--c-site-accent-soft:#1d2a5c;--c-site-glow-1:#96650c;--c-site-glow-2:#2c4494;--c-site-art-stroke:#f3f1e8;--c-site-art-paper:#18224a;--c-site-mark-accent:#f7f6f1;--brand-edge:transparent;--c-accent:var(--brand);--c-on-accent:var(--on-brand);--c-accent-fill-edge:transparent;--c-accent-hover:#c34f33;--c-accent-press:#a8432c;--c-accent-ink:#e58a6f;--c-accent-soft:#3a221b;--c-accent-edge:var(--c-accent);--c-accent-ring:var(--c-accent-edge);--c-page-tint:var(--c-bg);--c-band:var(--c-page-tint);--c-on-band:var(--c-ink);--c-band-edge:transparent;--c-alt:var(--c-accent);--c-on-alt:var(--c-on-accent);--c-alt-fill-edge:var(--c-accent-fill-edge);--c-alt-hover:var(--c-accent-hover);--c-alt-press:var(--c-accent-press);--c-alt-ink:var(--c-accent-ink);--c-alt-soft:var(--c-accent-soft);--c-alt-edge:var(--c-accent-edge);--c-brand:var(--c-accent);--c-brand-hover:var(--c-accent-hover);--c-brand-press:var(--c-accent-press);--c-brand-ink:var(--c-accent-ink);--c-brand-soft:var(--c-accent-soft);--c-on-brand:var(--c-on-accent);--c-chart-bar:var(--c-accent-ink);--c-chart-bar-hi:color-mix(in oklab, var(--c-accent-ink) 60%, #fff);--e-0:none;--e-1:0 1px 2px rgb(0 0 0 / 0.4);--e-2:0 8px 24px rgb(0 0 0 / 0.5), 0 0 0 1px #2e2c28;--e-3:0 24px 64px rgb(0 0 0 / 0.6), 0 0 0 1px #2e2c28;}
:root,[data-density=comfortable]{--ctl-h:40px;--ctl-sm:32px;--row-h:48px;--gutter:32px;--fs-body:14px;--lh-body:20px;--fs-ctl:14px;--lh-ctl:20px;--fs-input:14px;--lh-input:20px;--pad-card:20px;--icon-size:18px;--gap-section:32px;--btn-lg:48px}
[data-density=compact]{--ctl-h:36px;--ctl-sm:28px;--row-h:40px;--gutter:24px;--fs-body:13px;--lh-body:18px;--fs-ctl:13px;--lh-ctl:18px;--fs-input:13px;--lh-input:18px;--pad-card:16px;--icon-size:16px;--gap-section:24px;--btn-lg:44px}
[data-density=touch]{--ctl-h:44px;--ctl-sm:36px;--row-h:56px;--gutter:16px;--fs-body:16px;--lh-body:24px;--fs-ctl:16px;--lh-ctl:24px;--fs-input:16px;--lh-input:24px;--pad-card:16px;--icon-size:1.25em;--gap-section:24px;--btn-lg:64px}
@media (pointer:coarse){:root,[data-density]{--fs-input:16px;--lh-input:24px}}
@media (prefers-reduced-motion:reduce){:root{--dur-1:0ms;--dur-2:0ms;--dur-3:0ms;--m-fast:0ms;--m-base:0ms;--m-slow:0ms}}
@font-face{font-family:"Inter";font-style:normal;font-weight:400 600;font-display:swap;src:url(/assets/fonts/inter-latin-400-600.c940764593.woff2) format("woff2");unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD}
@font-face{font-family:"IBM Plex Sans Arabic";font-style:normal;font-weight:400;font-display:swap;src:url(/assets/fonts/plex-arabic-400.4ed189e865.woff2) format("woff2");unicode-range:U+0600-06FF, U+0750-077F, U+0870-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC, U+102E0-102FB, U+10E60-10E7E, U+10EC2-10EC7, U+10EC9-10EEE, U+10EF0-10EFF, U+1EE00-1EE03, U+1EE05-1EE1F, U+1EE21-1EE22, U+1EE24, U+1EE27, U+1EE29-1EE32, U+1EE34-1EE37, U+1EE39, U+1EE3B, U+1EE42, U+1EE47, U+1EE49, U+1EE4B, U+1EE4D-1EE4F, U+1EE51-1EE52, U+1EE54, U+1EE57, U+1EE59, U+1EE5B, U+1EE5D, U+1EE5F, U+1EE61-1EE62, U+1EE64, U+1EE67-1EE6A, U+1EE6C-1EE72, U+1EE74-1EE77, U+1EE79-1EE7C, U+1EE7E, U+1EE80-1EE89, U+1EE8B-1EE9B, U+1EEA1-1EEA3, U+1EEA5-1EEA9, U+1EEAB-1EEBB, U+1EEF0-1EEF1}
@font-face{font-family:"IBM Plex Sans Arabic";font-style:normal;font-weight:500;font-display:swap;src:url(/assets/fonts/plex-arabic-500.bf2b68e78c.woff2) format("woff2");unicode-range:U+0600-06FF, U+0750-077F, U+0870-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC, U+102E0-102FB, U+10E60-10E7E, U+10EC2-10EC7, U+10EC9-10EEE, U+10EF0-10EFF, U+1EE00-1EE03, U+1EE05-1EE1F, U+1EE21-1EE22, U+1EE24, U+1EE27, U+1EE29-1EE32, U+1EE34-1EE37, U+1EE39, U+1EE3B, U+1EE42, U+1EE47, U+1EE49, U+1EE4B, U+1EE4D-1EE4F, U+1EE51-1EE52, U+1EE54, U+1EE57, U+1EE59, U+1EE5B, U+1EE5D, U+1EE5F, U+1EE61-1EE62, U+1EE64, U+1EE67-1EE6A, U+1EE6C-1EE72, U+1EE74-1EE77, U+1EE79-1EE7C, U+1EE7E, U+1EE80-1EE89, U+1EE8B-1EE9B, U+1EEA1-1EEA3, U+1EEA5-1EEA9, U+1EEAB-1EEBB, U+1EEF0-1EEF1}
@font-face{font-family:"IBM Plex Sans Arabic";font-style:normal;font-weight:600;font-display:swap;src:url(/assets/fonts/plex-arabic-600.0ccee44455.woff2) format("woff2");unicode-range:U+0600-06FF, U+0750-077F, U+0870-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC, U+102E0-102FB, U+10E60-10E7E, U+10EC2-10EC7, U+10EC9-10EEE, U+10EF0-10EFF, U+1EE00-1EE03, U+1EE05-1EE1F, U+1EE21-1EE22, U+1EE24, U+1EE27, U+1EE29-1EE32, U+1EE34-1EE37, U+1EE39, U+1EE3B, U+1EE42, U+1EE47, U+1EE49, U+1EE4B, U+1EE4D-1EE4F, U+1EE51-1EE52, U+1EE54, U+1EE57, U+1EE59, U+1EE5B, U+1EE5D, U+1EE5F, U+1EE61-1EE62, U+1EE64, U+1EE67-1EE6A, U+1EE6C-1EE72, U+1EE74-1EE77, U+1EE79-1EE7C, U+1EE7E, U+1EE80-1EE89, U+1EE8B-1EE9B, U+1EEA1-1EEA3, U+1EEA5-1EEA9, U+1EEAB-1EEBB, U+1EEF0-1EEF1}
@font-face{font-family:"Rubik Numerals";font-style:normal;font-weight:700;font-display:swap;src:url(/assets/fonts/num-digits-700.22277d0e5c.woff2) format("woff2");unicode-range:U+23, U+30-39, U+41-5a, U+660-669}
@font-face{font-family:"Rubik";font-style:normal;font-weight:700;font-display:swap;src:url(/assets/fonts/rubik-arabic-700.59151b4352.woff2) format("woff2");unicode-range:U+0600-06FF, U+0750-077F, U+0870-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC, U+102E0-102FB, U+10E60-10E7E, U+10EC2-10EC7, U+10EC9-10EEE, U+10EF0-10EFF, U+1EE00-1EE03, U+1EE05-1EE1F, U+1EE21-1EE22, U+1EE24, U+1EE27, U+1EE29-1EE32, U+1EE34-1EE37, U+1EE39, U+1EE3B, U+1EE42, U+1EE47, U+1EE49, U+1EE4B, U+1EE4D-1EE4F, U+1EE51-1EE52, U+1EE54, U+1EE57, U+1EE59, U+1EE5B, U+1EE5D, U+1EE5F, U+1EE61-1EE62, U+1EE64, U+1EE67-1EE6A, U+1EE6C-1EE72, U+1EE74-1EE77, U+1EE79-1EE7C, U+1EE7E, U+1EE80-1EE89, U+1EE8B-1EE9B, U+1EEA1-1EEA3, U+1EEA5-1EEA9, U+1EEAB-1EEBB, U+1EEF0-1EEF1}
@font-face{font-family:"Rubik";font-style:normal;font-weight:700;font-display:swap;src:url(/assets/fonts/rubik-latin-700.509f75f53b.woff2) format("woff2");unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD}
@font-face{font-family:"Cairo";font-style:normal;font-weight:700;font-display:swap;src:url(/assets/fonts/cairo-arabic-700.b09783cfa4.woff2) format("woff2");unicode-range:U+0600-06FF, U+0750-077F, U+0870-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC, U+102E0-102FB, U+10E60-10E7E, U+10EC2-10EC7, U+10EC9-10EEE, U+10EF0-10EFF, U+1EE00-1EE03, U+1EE05-1EE1F, U+1EE21-1EE22, U+1EE24, U+1EE27, U+1EE29-1EE32, U+1EE34-1EE37, U+1EE39, U+1EE3B, U+1EE42, U+1EE47, U+1EE49, U+1EE4B, U+1EE4D-1EE4F, U+1EE51-1EE52, U+1EE54, U+1EE57, U+1EE59, U+1EE5B, U+1EE5D, U+1EE5F, U+1EE61-1EE62, U+1EE64, U+1EE67-1EE6A, U+1EE6C-1EE72, U+1EE74-1EE77, U+1EE79-1EE7C, U+1EE7E, U+1EE80-1EE89, U+1EE8B-1EE9B, U+1EEA1-1EEA3, U+1EEA5-1EEA9, U+1EEAB-1EEBB, U+1EEF0-1EEF1}
@font-face{font-family:"Cairo";font-style:normal;font-weight:700;font-display:swap;src:url(/assets/fonts/cairo-latin-700.de34c6c08a.woff2) format("woff2");unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD}
@font-face{font-family:"Almarai";font-style:normal;font-weight:700;font-display:swap;src:url(/assets/fonts/almarai-arabic-700.e6a51b31aa.woff2) format("woff2");unicode-range:U+0600-06FF, U+0750-077F, U+0870-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC, U+102E0-102FB, U+10E60-10E7E, U+10EC2-10EC7, U+10EC9-10EEE, U+10EF0-10EFF, U+1EE00-1EE03, U+1EE05-1EE1F, U+1EE21-1EE22, U+1EE24, U+1EE27, U+1EE29-1EE32, U+1EE34-1EE37, U+1EE39, U+1EE3B, U+1EE42, U+1EE47, U+1EE49, U+1EE4B, U+1EE4D-1EE4F, U+1EE51-1EE52, U+1EE54, U+1EE57, U+1EE59, U+1EE5B, U+1EE5D, U+1EE5F, U+1EE61-1EE62, U+1EE64, U+1EE67-1EE6A, U+1EE6C-1EE72, U+1EE74-1EE77, U+1EE79-1EE7C, U+1EE7E, U+1EE80-1EE89, U+1EE8B-1EE9B, U+1EEA1-1EEA3, U+1EEA5-1EEA9, U+1EEAB-1EEBB, U+1EEF0-1EEF1}
@font-face{font-family:"Almarai";font-style:normal;font-weight:700;font-display:swap;src:url(/assets/fonts/almarai-latin-700.1280f2a079.woff2) format("woff2");unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD}
@font-face{font-family:"Bricolage Grotesque";font-style:normal;font-weight:600 800;font-display:swap;src:url(/assets/fonts/bricolage-latin-600-800.2872cca2eb.woff2) format("woff2");unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD}
@layer reset, base, components, surfaces, utilities;
/* reset.css */
@layer reset {
/* Layer: reset. Removes browser chrome everywhere: spinners, search decorations, autofill yellow, tap flash,
   mouse-focus outlines. Component classes (ui-*) restyle the controls themselves. The only !important allowed in the
   system is [hidden]. */
[hidden] {
  display: none !important;
}
*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
  scrollbar-width: thin;
  scrollbar-color: var(--c-line-strong) transparent;
}
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-thumb {
  background: var(--c-line-strong);
  border-radius: var(--r-pill);
}
::-webkit-scrollbar-track {
  background: transparent;
}
::selection {
  background: var(--c-accent-soft);
  color: var(--c-ink);
}
:focus:not(:focus-visible) {
  outline: none;
}
input::-webkit-search-cancel-button,
input::-webkit-search-decoration,
input::-webkit-search-results-button,
input::-webkit-search-results-decoration {
  -webkit-appearance: none;
  appearance: none;
}
input::-ms-reveal,
input::-ms-clear {
  display: none;
}
input::-webkit-inner-spin-button,
input::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
input[type='number'] {
  -moz-appearance: textfield;
  appearance: textfield;
}
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
textarea:-webkit-autofill {
  -webkit-box-shadow: 0 0 0 1000px var(--c-surface) inset;
  -webkit-text-fill-color: var(--c-ink);
  caret-color: var(--c-ink);
  transition: background-color 9999s;
}

}
/* base.css */
@layer base {
/* Layer: base. Page defaults for ui-* pages, the focus ring, and text primitives (design-system.md §4.41,
   experience-v2 §5.1). Surfaces never set font, font-size or line-height; they pick one of these classes.
   Type: Inter + IBM Plex Sans Arabic (--f-ui), 400 body / 500 labels / 600 titles, nothing heavier in staff UI
   except order numbers (.ui-num, Rubik Numerals). Body size follows the shell's density (--fs-body). */
html {
  font-family: var(--f-ui);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
body {
  font-family: var(--f-ui);
  font-feature-settings: 'cv11' 0, 'ss01' 0;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
.ui-page {
  margin: 0;
  min-height: 100dvh;
  background: var(--c-bg);
  color: var(--c-ink);
  font-family: var(--f-ui);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
}
[data-theme] {
  color: var(--c-ink);
}
/* Staff UI caps weights at 600 (experience-v2 §5.1): browser-bold headings, <b>, <strong> and <th> included. */
:where([data-shell='hq'], [data-shell='workspace'])
  :where(h1, h2, h3, h4, h5, h6, b, strong, th, dt) {
  font-weight: var(--fw-strong);
}
/* Arabic sits at the same nominal size with +4px line height on 13–20 (experience-v2 §5.1). */
:lang(ar) .ui-page,
.ui-page:lang(ar) {
  line-height: calc(var(--lh-body) + 4px);
}

/* One focus ring for every ui-* control: keyboard focus only, visible on fills and in both themes. */
:where([class^='ui-'], [class*=' ui-']):focus-visible {
  outline: none;
  box-shadow:
    0 0 0 2px var(--c-surface),
    0 0 0 4px var(--c-focus);
}

.ui-h1,
.ui-h2,
.ui-h3,
.ui-h4 {
  margin: 0;
  color: var(--c-ink);
  font-family: var(--f-ui);
  font-weight: var(--fw-strong);
  letter-spacing: -0.01em;
}
/* Page title: 24/600 at every width and in every staff shell (R-13). */
.ui-h1 {
  font-size: var(--fs-24);
  line-height: var(--lh-24);
}
.ui-h2 {
  font-size: var(--fs-20);
  line-height: var(--lh-20);
}
.ui-h3 {
  font-size: var(--fs-16);
  line-height: var(--lh-16);
}
.ui-h4 {
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
:lang(ar) .ui-h1,
:lang(ar) .ui-h2,
:lang(ar) .ui-h3,
:lang(ar) .ui-h4 {
  letter-spacing: 0;
}
:lang(ar) .ui-h2 {
  line-height: calc(var(--lh-20) + 4px);
}
:lang(ar) .ui-h3 {
  line-height: calc(var(--lh-16) + 4px);
}
.ui-text {
  margin: 0;
  font-size: var(--fs-body);
  line-height: var(--lh-body);
}
.ui-meta {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.ui-text--sm {
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.ui-text--muted {
  color: var(--c-muted);
}
.ui-eyebrow {
  margin: 0;
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  font-weight: 600;
  color: var(--c-muted);
}
.ui-eyebrow:lang(en) {
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.ui-mono {
  font-family: var(--f-mono);
  font-weight: var(--fw-medium);
  font-size: 0.95em;
}
/* Order numbers only: Rubik Numerals (700 subset, Latin and Arabic-Indic digits), always isolated LTR. */
.ui-num {
  direction: ltr;
  unicode-bidi: isolate;
  font-family: var(--f-num);
  font-variant-numeric: tabular-nums;
}
/* Every other number (tables, stats, times): the UI face with tabular figures. */
.ui-tnum {
  font-variant-numeric: tabular-nums;
}
.ui-truncate {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  min-width: 0;
}
.ui-clamp-2 {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}
:lang(ar) .ui-text--sm,
:lang(ar).ui-text--sm {
  line-height: calc(var(--lh-14) + 4px);
}
:lang(ar) .ui-text,
:lang(ar).ui-text {
  line-height: calc(var(--lh-body) + 4px);
}
.ui-link {
  color: var(--c-accent-ink);
  text-decoration: underline;
  text-underline-offset: 2px;
  border-radius: var(--r-xs);
}
.ui-link:hover {
  text-decoration-thickness: 2px;
}

/* Icons (icons.ts): one stroke family drawn on a 24 unit grid, rendered at 16 (compact) / 18 / 20 (touch) with a
   1.5px stroke at those sizes; currentColor; decorative (the control carries the name). */
.ui-icon {
  width: var(--icon-size);
  height: var(--icon-size);
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  vertical-align: middle;
}
/* Staff densities draw a true 1.5px line at 16/18/20; touch surfaces keep the scaled 2-unit stroke. */
[data-density='compact'] .ui-icon path,
[data-density='comfortable'] .ui-icon path {
  vector-effect: non-scaling-stroke;
  stroke-width: 1.5px;
}
[dir='rtl'] .ui-flip {
  transform: scaleX(-1);
}
[dir='rtl'] [dir='ltr'] .ui-flip {
  transform: none;
}

/* HQ and staff-mode views: primary actions are ink, never Bellou red or a client colour (R-12, R-41). The accent
   tier is remapped on the container, so every component (buttons, checks, chips, tabs) follows without its own
   rule. Only [data-preview-frame] (which always carries data-theme) gets the client theme back from the brand
   stylesheet. The v1 --c-brand* aliases are re-declared here so legacy surface CSS follows too. */
[data-primary='ink'] {
  --c-accent: var(--c-hq-primary);
  --c-on-accent: var(--c-on-hq-primary);
  --c-accent-hover: var(--c-hq-primary-hover);
  --c-accent-press: var(--c-hq-primary-hover);
  --c-accent-ink: var(--c-ink);
  --c-accent-soft: var(--n-4);
  --c-accent-edge: var(--c-ink);
  --c-accent-ring: var(--c-ink);
  --c-accent-fill-edge: transparent;
  --c-chart-bar: var(--n-11);
  --c-chart-bar-hi: var(--c-ink);
  --c-brand: var(--c-accent);
  --c-brand-hover: var(--c-accent-hover);
  --c-brand-press: var(--c-accent-press);
  --c-brand-ink: var(--c-accent-ink);
  --c-brand-soft: var(--c-accent-soft);
  --c-on-brand: var(--c-on-accent);
}

}
/* components/button.css */
@layer components {
/* Button ui-btn, icon button ui-iconbtn, split button ui-split (design-system.md §4.1). One primary per view. */
.ui-btn {
  appearance: none;
  -webkit-appearance: none;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--s-2);
  min-height: var(--ctl-h);
  margin: 0;
  padding-block: 0;
  padding-inline: var(--s-4);
  border: 1px solid transparent;
  border-radius: var(--r-control);
  background: var(--c-surface);
  color: var(--c-ink);
  font-family: var(--f-ui);
  font-size: var(--fs-ctl);
  line-height: var(--lh-ctl);
  font-weight: var(--fw-medium);
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  user-select: none;
  transition:
    background-color var(--dur-1) var(--ease-standard),
    border-color var(--dur-1) var(--ease-standard),
    box-shadow var(--dur-1) var(--ease-standard);
}
.ui-btn:active {
  background-image: linear-gradient(var(--n-5), var(--n-5));
  background-blend-mode: multiply;
}
.ui-btn--primary {
  background: var(--c-accent);
  color: var(--c-on-accent);
}
.ui-btn--primary:hover {
  background: var(--c-accent-hover);
}
.ui-btn--primary:active {
  background: var(--c-accent-press);
}
.ui-btn--secondary {
  border-color: var(--n-7);
}
.ui-btn--secondary:hover,
.ui-btn--ghost:hover {
  background: var(--n-3);
}
.ui-btn--secondary:active,
.ui-btn--ghost:active {
  background: var(--n-5);
}
.ui-btn--ghost {
  background: transparent;
}
.ui-btn--danger {
  border: 2px solid var(--c-danger);
  color: var(--c-danger);
}
.ui-btn--danger:hover {
  background: var(--c-danger-soft);
}
.ui-btn--ready {
  background: var(--c-ready);
  border-color: var(--c-ready-edge);
  color: #fff;
}
.ui-btn--ready-tonal {
  background: var(--c-ready-soft);
  border-color: var(--c-ready-ink);
  color: var(--c-ready-ink);
}
.ui-btn--now {
  background: var(--c-now);
  color: var(--c-on-now);
}
.ui-btn--wa {
  background: var(--c-wa);
  color: #fff;
}
.ui-btn--link {
  min-height: auto;
  padding: 0;
  border: 0;
  background: none;
  color: var(--c-accent-ink);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.ui-btn--sm {
  min-height: var(--ctl-sm);
  padding-inline: var(--s-3);
  gap: var(--s-1);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.ui-btn--lg {
  /* Per density (tokens.ts): 44 HQ, 48 workspace, 64 cashier/guest. Never 64 in a 40 px shell. */
  min-height: var(--btn-lg, var(--hit-main));
  padding-inline: var(--s-6);
  font-size: var(--fs-18);
  line-height: var(--lh-18);
}
.ui-btn--xl {
  min-height: var(--hit-xl);
  padding-inline: var(--s-8);
  font-size: var(--fs-20);
  line-height: var(--lh-20);
  border-radius: var(--r-card);
}
.ui-btn--block {
  display: flex;
  width: 100%;
}
.ui-btn[disabled],
.ui-btn[aria-disabled='true'] {
  opacity: 0.4;
  cursor: not-allowed;
  transform: none;
}
.ui-btn[aria-busy='true'] {
  cursor: progress;
}
.ui-btn[aria-busy='true'] > .ui-icon:first-child {
  display: none;
}
.ui-btn:not([aria-busy='true']) > .ui-spin {
  display: none;
}
.ui-btn__count {
  min-width: var(--s-5);
  padding-inline: var(--s-1);
  border-radius: var(--r-pill);
  background: color-mix(in srgb, currentColor 14%, transparent);
  font-size: var(--fs-12);
  line-height: var(--s-5);
}

.ui-iconbtn {
  appearance: none;
  -webkit-appearance: none;
  display: inline-grid;
  place-items: center;
  width: var(--ctl-h);
  height: var(--ctl-h);
  margin: 0;
  padding: 0;
  border: 1px solid transparent;
  border-radius: var(--r-control);
  background: transparent;
  color: inherit;
  font: inherit;
  cursor: pointer;
}
.ui-iconbtn:hover {
  background: color-mix(in srgb, currentColor 8%, transparent);
}
/* Touch densities keep a 44 px hit box even when the control is drawn smaller. */
[data-density='touch'] .ui-btn--sm,
[data-density='touch'] .ui-iconbtn--sm {
  min-height: var(--hit-min);
}
.ui-iconbtn--secondary {
  border-color: var(--c-line-strong);
  background: var(--c-surface);
}
.ui-iconbtn--sm {
  width: var(--ctl-sm);
  height: var(--ctl-sm);
}

.ui-split {
  display: inline-flex;
}
.ui-split > .ui-btn:first-child {
  border-start-end-radius: 0;
  border-end-end-radius: 0;
}
.ui-split > .ui-btn:last-child {
  border-start-start-radius: 0;
  border-end-start-radius: 0;
  border-inline-start: 1px solid color-mix(in srgb, currentColor 30%, transparent);
  padding-inline: var(--s-3);
}

}
/* components/field.css */
@layer components {
/* Field, text inputs, search, secret, number, code (design-system.md §4.2, §4.3). */
.ui-field {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
  min-width: 0;
}
.ui-field__label {
  color: var(--c-ink);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
  font-weight: 600;
  cursor: default;
}
.ui-field__opt {
  margin-inline-start: var(--s-2);
  color: var(--c-muted);
  font-weight: 400;
}
.ui-field__hint {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.ui-field__error {
  display: flex;
  align-items: flex-start;
  gap: var(--s-1);
  margin: 0;
  color: var(--c-danger);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
  font-weight: 500;
}

.ui-input,
.ui-textarea {
  appearance: none;
  -webkit-appearance: none;
  display: block;
  width: 100%;
  min-height: var(--ctl-h);
  margin: 0;
  padding-block: var(--s-2);
  padding-inline: var(--s-3);
  border: 1px solid var(--c-line-strong);
  border-radius: var(--r-sm);
  background: var(--c-surface);
  color: var(--c-ink);
  font-family: var(--f-sans);
  /* Density: 13/18 compact (36 tall), 14/20 comfortable (40), 16/24 touch (44); phones always 16 (no iOS zoom). */
  font-size: var(--fs-input);
  line-height: var(--lh-input);
  outline: none;
  box-shadow: none;
}
.ui-input::placeholder,
.ui-textarea::placeholder {
  color: var(--c-muted);
  opacity: 1;
}
.ui-input:hover,
.ui-textarea:hover {
  border-color: var(--c-ink);
}
.ui-input:focus-visible,
.ui-textarea:focus-visible {
  border-color: var(--c-ink);
  /* The design-system focus ring (§2.10), same as buttons and input groups. */
  box-shadow:
    0 0 0 2px var(--c-surface),
    0 0 0 4px var(--c-focus);
}
.ui-input[aria-invalid='true'],
.ui-textarea[aria-invalid='true'] {
  border-color: var(--c-danger);
  background: var(--c-danger-soft);
}
.ui-input--lg {
  min-height: calc(var(--ctl-h) + var(--s-3));
  font-size: var(--fs-18);
}
.ui-input--mono {
  font-family: var(--f-mono);
  font-weight: 500;
}
.ui-textarea {
  resize: none;
  min-height: calc(var(--ctl-h) * 2);
}

/* A bordered group holding one borderless input plus affixes or buttons (search, secret, number, combobox). */
.ui-inputgroup {
  display: flex;
  align-items: center;
  min-height: var(--ctl-h);
  border: 1px solid var(--c-line-strong);
  border-radius: var(--r-sm);
  background: var(--c-surface);
  color: var(--c-ink);
}
.ui-inputgroup:hover {
  border-color: var(--c-ink);
}
.ui-inputgroup:focus-within {
  border-color: var(--c-ink);
  box-shadow:
    0 0 0 2px var(--c-surface),
    0 0 0 4px var(--c-focus);
}
.ui-inputgroup[data-invalid] {
  border-color: var(--c-danger);
}
.ui-inputgroup > .ui-input {
  flex: 1;
  min-width: 0;
  min-height: calc(var(--ctl-h) - 2px);
  border: 0;
  background: transparent;
  box-shadow: none;
}
.ui-inputgroup > .ui-input:focus-visible {
  box-shadow: none;
}
.ui-inputgroup__affix {
  display: inline-flex;
  align-items: center;
  padding-inline: var(--s-3);
  color: var(--c-muted);
  white-space: nowrap;
}
.ui-inputgroup__affix + .ui-input {
  padding-inline-start: 0;
}
.ui-inputgroup > .ui-iconbtn {
  height: calc(var(--ctl-h) - 2px);
  border-radius: calc(var(--r-sm) - 1px);
}
.ui-inputgroup > .ui-iconbtn:focus-visible {
  box-shadow: inset 0 0 0 2px var(--c-focus);
}

.ui-readonly {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--s-2);
  min-height: var(--ctl-h);
  padding-block: var(--s-2);
  border-block-end: 1px solid var(--c-line);
}
.ui-readonly__label {
  color: var(--c-muted);
  font-size: var(--fs-14);
}
.ui-readonly__value {
  font-weight: 500;
}

.ui-numberfield .ui-input {
  text-align: center;
  font-variant-numeric: tabular-nums;
}

.ui-code {
  display: flex;
  align-self: flex-start;
  gap: var(--s-2);
  direction: ltr;
}
.ui-code__cell {
  appearance: none;
  -webkit-appearance: none;
  width: var(--s-12);
  height: calc(var(--s-12) + var(--s-2));
  margin: 0;
  padding: 0;
  border: 1px solid var(--c-line-strong);
  border-radius: var(--r-sm);
  background: var(--c-surface);
  color: var(--c-ink);
  font-family: var(--f-mono);
  font-size: var(--fs-24);
  font-weight: var(--fw-strong);
  text-align: center;
  text-transform: uppercase;
  caret-color: var(--c-accent-ink);
  outline: none;
}
.ui-code__cell:focus-visible {
  border-color: var(--c-ink);
}
.ui-code[data-invalid] .ui-code__cell {
  border-color: var(--c-danger);
  background: var(--c-danger-soft);
}
@media (prefers-reduced-motion: no-preference) {
  .ui-code[data-shake] {
    animation: ui-shake var(--m-slow) var(--ease);
  }
}
@keyframes ui-shake {
  25% {
    transform: translateX(calc(var(--s-1) * -1));
  }
  75% {
    transform: translateX(var(--s-1));
  }
}
.ui-secret [aria-pressed='true'] .ui-reveal-show,
.ui-secret [aria-pressed='false'] .ui-reveal-hide {
  display: none;
}

}
/* components/choice.css */
@layer components {
/* Checkbox, CheckboxChips, Switch, SegmentedControl, RadioCards (design-system.md §4.5–4.8). All are <button>s
   with ARIA roles; the value travels in a hidden input next to them. */
.ui-check {
  display: flex;
}
.ui-check__ctl {
  appearance: none;
  display: flex;
  align-items: flex-start;
  gap: var(--s-3);
  min-height: var(--ctl-h);
  margin: 0;
  padding-block: var(--s-3);
  padding-inline: 0;
  border: 0;
  background: none;
  color: var(--c-ink);
  font: inherit;
  text-align: start;
  cursor: pointer;
}
.ui-check__ctl:focus-visible {
  box-shadow: none;
}
.ui-check__box {
  flex: none;
  display: grid;
  place-items: center;
  width: var(--s-5);
  height: var(--s-5);
  margin-block-start: 2px;
  border: 2px solid var(--c-line-strong);
  border-radius: var(--r-xs);
  background: var(--c-surface);
  color: var(--c-on-accent);
}
.ui-check__box .ui-icon {
  width: 0.875em;
  height: 0.875em;
  stroke-width: 3;
  display: none;
}
.ui-check__ctl:hover .ui-check__box {
  border-color: var(--c-ink);
}
.ui-check__ctl:focus-visible .ui-check__box {
  box-shadow:
    0 0 0 2px var(--c-surface),
    0 0 0 4px var(--c-focus);
}
.ui-check__ctl[aria-checked='true'] .ui-check__box,
.ui-check__ctl[aria-checked='mixed'] .ui-check__box {
  border-color: var(--c-accent-edge);
  background: var(--c-accent);
}
.ui-check__ctl[aria-checked='true'] .ui-check__on,
.ui-check__ctl[aria-checked='mixed'] .ui-check__mixed {
  display: block;
}
.ui-check__text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.ui-check__desc {
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.ui-check__ctl[aria-disabled='true'] {
  opacity: 0.4;
  cursor: not-allowed;
}
.ui-checkgroup {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
  border: 0;
}

.ui-chips {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
}
.ui-chip {
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  min-height: var(--ctl-h);
  margin: 0;
  padding-inline: var(--s-4);
  border: 1px solid var(--c-line-strong);
  border-radius: var(--r-pill);
  background: var(--c-surface);
  color: var(--c-ink);
  font: inherit;
  font-weight: 500;
  cursor: pointer;
}
.ui-chip .ui-icon {
  display: none;
  stroke-width: 3;
  width: 1em;
  height: 1em;
}
.ui-chip:hover {
  background: var(--c-surface-2);
}
.ui-chip[aria-checked='true'] {
  border-color: var(--c-accent-edge);
  background: var(--c-accent-soft);
  color: var(--c-accent-ink);
}
.ui-chip[aria-checked='true'] .ui-icon {
  display: block;
}

.ui-switch {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-4);
  min-height: var(--ctl-h);
  padding-block: var(--s-2);
}
.ui-switch__text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  cursor: pointer;
}
.ui-switch__label {
  font-weight: 500;
}
.ui-switch__desc {
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.ui-switch__ctl {
  appearance: none;
  position: relative;
  flex: none;
  width: var(--ctl-h);
  height: calc(var(--s-6) + 2px);
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: var(--r-pill);
  background: var(--c-line-strong);
  cursor: pointer;
  transition: background-color var(--m-fast) var(--ease);
}
.ui-switch__thumb {
  position: absolute;
  inset-block-start: 3px;
  inset-inline-start: 3px;
  width: var(--s-5);
  height: var(--s-5);
  border-radius: var(--r-pill);
  background: #fff;
  box-shadow: var(--e-1);
  transition: inset-inline-start var(--m-fast) var(--ease);
}
.ui-switch__ctl[aria-checked='true'] {
  background: var(--c-accent);
}
.ui-switch__ctl[aria-checked='true'] .ui-switch__thumb {
  inset-inline-start: calc(100% - var(--s-5) - 3px);
}
.ui-switch__ctl[aria-disabled='true'] {
  opacity: 0.4;
  cursor: not-allowed;
}

.ui-seg {
  display: inline-flex;
  flex-wrap: nowrap; /* never two rows inside one pill: more than 3-4 options belong in a Select */
  align-self: flex-start;
  max-width: 100%;
  gap: 2px;
  padding: var(--s-1);
  border: 1px solid var(--c-line);
  border-radius: var(--r-pill);
  background: var(--c-surface-2);
}
.ui-seg--block {
  display: flex;
  align-self: stretch;
}
.ui-seg--block .ui-seg__opt {
  flex: 1;
}
.ui-seg__opt {
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--s-2);
  min-height: calc(var(--ctl-h) - var(--s-2) - 2px);
  margin: 0;
  padding-inline: var(--s-4);
  border: 0;
  border-radius: var(--r-pill);
  background: transparent;
  color: var(--c-muted);
  font: inherit;
  font-weight: 500;
  white-space: nowrap;
  cursor: pointer;
}
.ui-seg__opt:hover {
  color: var(--c-ink);
}
.ui-seg__opt[aria-checked='true'] {
  background: var(--c-surface);
  color: var(--c-ink);
  font-weight: 600;
  box-shadow:
    var(--e-1),
    0 0 0 1px var(--c-line);
}
.ui-seg__opt[aria-checked='true']:focus-visible {
  box-shadow:
    0 0 0 2px var(--c-surface),
    0 0 0 4px var(--c-focus);
}
.ui-seg--sm .ui-seg__opt {
  min-height: calc(var(--ctl-h) - var(--s-4) - 2px);
  padding-inline: var(--s-3);
  font-size: var(--fs-14);
}
.ui-seg__caption {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
}

.ui-radiocards {
  display: grid;
  gap: var(--s-3);
}
@media (min-width: 1024px) {
  .ui-radiocards--2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .ui-radiocards--3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .ui-radiocards--4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
  /* An editor's form column can be narrow (the HQ console's brand form is 360): measured by its own width there,
     four cards go two by two and three stack as on phones, instead of spilling out of their card. */
  .ui-tpl__form-pane .ui-field:has(> .ui-radiocards) {
    container-type: inline-size;
  }
}
@container (max-width: 30rem) {
  .ui-radiocards--4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .ui-radiocards--3 {
    grid-template-columns: minmax(0, 1fr);
  }
}

.ui-radiocard {
  appearance: none;
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: start;
  column-gap: var(--s-3);
  row-gap: var(--s-1);
  margin: 0;
  padding: var(--s-4);
  border: 1px solid var(--c-line-strong);
  border-radius: var(--r-md);
  background: var(--c-surface);
  color: var(--c-ink);
  font: inherit;
  text-align: start;
  cursor: pointer;
}
.ui-radiocard:hover {
  border-color: var(--c-ink);
}
.ui-radiocard[aria-checked='true'] {
  border-color: var(--c-accent-edge);
  background: var(--c-accent-soft);
  box-shadow: inset 0 0 0 1px var(--c-accent-edge);
}
.ui-radiocard[aria-checked='true']:focus-visible {
  box-shadow:
    inset 0 0 0 1px var(--c-accent-edge),
    0 0 0 2px var(--c-surface),
    0 0 0 4px var(--c-focus);
}
.ui-radiocard__dot {
  grid-row: span 3;
  display: grid;
  place-items: center;
  width: var(--s-5);
  height: var(--s-5);
  margin-block-start: 2px;
  border: 2px solid var(--c-line-strong);
  border-radius: var(--r-pill);
  background: var(--c-surface);
}
.ui-radiocard[aria-checked='true'] .ui-radiocard__dot {
  border-color: var(--c-accent-edge);
}
.ui-radiocard[aria-checked='true'] .ui-radiocard__dot::after {
  content: '';
  width: var(--s-2);
  height: var(--s-2);
  border-radius: var(--r-pill);
  background: var(--c-accent-edge);
}
.ui-radiocard__title {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
  font-weight: 600;
}
.ui-radiocard__desc {
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.ui-radiocard[aria-disabled='true'] {
  opacity: 0.4;
  cursor: not-allowed;
}

}
/* components/popover.css */
@layer components {
/* Popover base, Select, Combobox, Menu, Tooltip, ColorField popover (design-system.md §4.4, §4.11, §4.14, §4.42).
   Popovers are positioned against their component root (position:relative) and flip upward via data-placement.
   Below 600px, ui-pop--sheet popovers become bottom sheets. */
.ui-select,
.ui-combobox,
.ui-menu,
.ui-color {
  position: relative;
}
.ui-menu {
  display: inline-block;
}
.ui-pop {
  position: absolute;
  z-index: var(--z-popover);
  inset-block-start: calc(100% + var(--s-1));
  inset-inline-start: 0;
  min-width: 100%;
  max-width: min(22.5rem, calc(100vw - var(--s-8)));
  max-height: 20rem;
  overflow: auto;
  margin: 0;
  padding: var(--s-2);
  border: 1px solid var(--c-line);
  border-radius: var(--r-md);
  background: var(--c-surface);
  color: var(--c-ink);
  box-shadow: var(--e-2);
  overscroll-behavior: contain;
}
.ui-pop:focus-visible {
  box-shadow: var(--e-2);
}
.ui-pop[data-placement='top'] {
  inset-block-start: auto;
  inset-block-end: calc(100% + var(--s-1));
}
.ui-pop[data-align='end'] {
  inset-inline-start: auto;
  inset-inline-end: 0;
}
.ui-combobox .ui-pop {
  max-width: min(30rem, calc(100vw - var(--s-8)));
}
.ui-dialog .ui-pop {
  z-index: calc(var(--z-overlay) + 1);
}
@media (max-width: 599px) {
  .ui-pop--sheet {
    position: fixed;
    z-index: var(--z-overlay);
    inset-inline: 0;
    inset-block-start: auto;
    inset-block-end: 0;
    max-width: none;
    max-height: 85dvh;
    padding-block-end: calc(var(--s-4) + env(safe-area-inset-bottom));
    border-radius: var(--r-lg) var(--r-lg) 0 0;
    /* The second shadow dims the page behind the sheet; a tap there closes it like any outside tap. */
    box-shadow:
      var(--e-3),
      0 0 0 100vmax var(--c-overlay);
  }
  /* Full width even when the menu aligns to the end on wider screens (the account menu). */
  .ui-pop--sheet[data-align='end'] {
    inset-inline: 0;
  }
  /* A sticky bar (z-index appbar) is a stacking context, so a sheet opened from it would sit under the bottom bar,
     which comes later at the same z-index: lift the bar while one of its sheets is open. */
  .ui-appbar:has(.ui-pop--sheet:not([hidden])) {
    z-index: var(--z-overlay);
  }
  .ui-pop--sheet[data-placement='top'] {
    inset-block-end: 0;
  }
  .ui-pop--sheet .ui-option,
  .ui-pop--sheet .ui-menuitem {
    min-height: calc(var(--ctl-h) + var(--s-3));
  }
}

.ui-select__trigger {
  appearance: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-2);
  width: 100%;
  min-height: var(--ctl-h);
  margin: 0;
  padding-inline: var(--s-3);
  border: 1px solid var(--c-line-strong);
  border-radius: var(--r-sm);
  background: var(--c-surface);
  color: var(--c-ink);
  font-family: var(--f-sans);
  font-size: var(--fs-input);
  line-height: var(--lh-input);
  text-align: start;
  cursor: pointer;
}
.ui-select__trigger:hover {
  border-color: var(--c-ink);
}
.ui-select__trigger[aria-invalid='true'] {
  border-color: var(--c-danger);
}
.ui-select__value {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.ui-select__value[data-placeholder] {
  color: var(--c-muted);
}
.ui-chev {
  color: var(--c-muted);
  transition: transform var(--m-fast) var(--ease);
}
[aria-expanded='true'] > .ui-chev,
[aria-expanded='true'] .ui-chev {
  transform: rotate(180deg);
}

.ui-option {
  display: flex;
  align-items: flex-start;
  gap: var(--s-2);
  min-height: var(--ctl-h);
  padding-block: var(--s-2);
  padding-inline: var(--s-2) var(--s-3);
  border-radius: var(--r-sm);
  color: var(--c-ink);
  cursor: pointer;
  user-select: none;
}
.ui-option:hover {
  background: var(--c-surface-2);
}
.ui-option[data-active] {
  background: var(--c-surface-2);
  outline: 2px solid var(--c-focus);
  outline-offset: -2px;
}
.ui-option__check {
  flex: none;
  margin-block-start: 2px;
  color: var(--c-accent-ink);
  visibility: hidden;
}
.ui-option[aria-selected='true'] {
  font-weight: 600;
}
.ui-option[aria-selected='true'] .ui-option__check {
  visibility: visible;
}
.ui-option__text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.ui-option__desc {
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
  font-weight: 400;
}
.ui-option[aria-disabled='true'] {
  opacity: 0.4;
  cursor: not-allowed;
}
.ui-listbox__note {
  padding: var(--s-3);
  color: var(--c-muted);
  font-size: var(--fs-14);
}

.ui-menu__list {
  min-width: 14rem;
}
.ui-menuitem {
  appearance: none;
  display: flex;
  align-items: center;
  gap: var(--s-3);
  width: 100%;
  min-height: var(--ctl-h);
  margin: 0;
  padding-block: var(--s-2);
  padding-inline: var(--s-3);
  border: 0;
  border-radius: var(--r-sm);
  background: none;
  color: var(--c-ink);
  font: inherit;
  text-align: start;
  text-decoration: none;
  cursor: pointer;
}
.ui-menuitem:hover,
.ui-menuitem:focus {
  background: var(--c-surface-2);
}
.ui-menuitem:focus-visible {
  box-shadow: inset 0 0 0 2px var(--c-focus);
}
.ui-menuitem--danger {
  color: var(--c-danger);
}
.ui-menuitem__text {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
}
.ui-menuitem__desc {
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.ui-menuitem__check {
  visibility: hidden;
  color: var(--c-accent-ink);
}
.ui-menuitem[aria-checked='true'] .ui-menuitem__check {
  visibility: visible;
}
.ui-menu__sep {
  height: 1px;
  margin-block: var(--s-1);
  background: var(--c-line);
}
.ui-menu__header {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
  padding: var(--s-2) var(--s-3) var(--s-3);
  margin-block-end: var(--s-1);
  border-block-end: 1px solid var(--c-line);
}
.ui-menu__group {
  padding-block: var(--s-1);
  padding-inline: var(--s-3);
  color: var(--c-muted);
  font-size: var(--fs-12);
  font-weight: 600;
}

.ui-tipwrap {
  position: relative;
  display: inline-flex;
}
.ui-tip {
  position: absolute;
  z-index: var(--z-popover);
  inset-block-end: calc(100% + var(--s-2));
  inset-inline-start: 50%;
  transform: translateX(-50%);
  max-width: 16rem;
  width: max-content;
  padding-block: var(--s-1);
  padding-inline: var(--s-2);
  border-radius: var(--r-xs);
  background: var(--c-ink);
  color: var(--c-bg);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
  font-weight: 500;
  pointer-events: none;
  box-shadow: var(--e-2);
}
[dir='rtl'] .ui-tip {
  transform: translateX(50%);
}
.ui-tip[data-placement='bottom'] {
  inset-block-end: auto;
  inset-block-start: calc(100% + var(--s-2));
}

.ui-color__row {
  display: flex;
  gap: var(--s-2);
  align-items: center;
}
.ui-color__chip {
  flex: none;
  width: var(--s-8);
  height: var(--s-8);
  border-radius: var(--r-xs);
  overflow: hidden;
  box-shadow: inset 0 0 0 1px var(--c-line-strong);
}
.ui-color__chip rect {
  stroke: var(--c-line);
}
.ui-color__hex {
  max-width: 9rem;
}
.ui-color__pop {
  width: 18rem;
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  padding: var(--s-3);
}
.ui-swatches {
  display: grid;
  grid-template-columns: repeat(4, var(--ctl-h));
  gap: var(--s-2);
}
.ui-swatch {
  appearance: none;
  display: grid;
  place-items: center;
  width: var(--ctl-h);
  height: var(--ctl-h);
  margin: 0;
  padding: var(--s-1);
  border: 2px solid transparent;
  border-radius: var(--r-sm);
  background: none;
  color: #fff;
  cursor: pointer;
}
.ui-swatch svg {
  grid-area: 1 / 1;
  width: 100%;
  height: 100%;
  border-radius: var(--r-xs);
}
.ui-swatch .ui-icon {
  grid-area: 1 / 1;
  width: 1.25em;
  height: 1.25em;
  visibility: hidden;
  stroke-width: 3;
}
.ui-swatch[aria-checked='true'] {
  border-color: var(--c-ink);
}
.ui-swatch[aria-checked='true'] .ui-icon {
  visibility: visible;
}
.ui-color__problem {
  margin: 0;
}

}
/* components/overlay.css */
@layer components {
/* Dialog, ConfirmDialog, Sheet, Toast (design-system.md §4.12, §4.13). No <dialog>, no Popover API: divs with roles,
   inert on the rest of the page, our own scrim. */
.ui-dialog {
  position: fixed;
  inset: 0;
  z-index: var(--z-overlay);
  display: grid;
  /* One column that never grows past the viewport: an automatic one would take the content's min-content width,
     and the panel's width: 100% would follow it off a 390 px screen. */
  grid-template-columns: minmax(0, 1fr);
  place-items: center;
  padding: var(--s-4);
}
.ui-scrim {
  position: absolute;
  inset: 0;
  background: var(--c-overlay);
}
.ui-dialog__panel {
  position: relative;
  display: flex;
  flex-direction: column;
  width: min(100%, var(--w-dialog));
  max-height: calc(100dvh - var(--s-8));
  border-radius: var(--r-lg);
  background: var(--c-surface);
  color: var(--c-ink);
  box-shadow: var(--e-3);
  outline: none;
}
.ui-dialog__panel:focus-visible {
  box-shadow: var(--e-3);
}
.ui-dialog--wide .ui-dialog__panel {
  width: min(100%, var(--w-dialog-wide));
}
.ui-dialog__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--s-3);
  padding-block: var(--s-5) var(--s-2);
  padding-inline: var(--s-6) var(--s-3);
}
.ui-dialog__title {
  margin: 0;
  padding-block-start: var(--s-2);
  font-size: var(--fs-20);
  line-height: var(--lh-20);
  font-weight: 600;
}
/* A title with an icon (titleIcon): the icon sits beside the words, never touching them, in either direction. */
.ui-dialog__title:has(.ui-icon) {
  display: flex;
  align-items: center;
  gap: var(--s-2);
}
.ui-dialog__body {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  padding-block: var(--s-2) var(--s-4);
  padding-inline: var(--s-6);
  overflow: auto;
}
.ui-dialog__desc {
  margin: 0;
  color: var(--c-muted);
}
.ui-dialog__foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: var(--s-3);
  padding-block: var(--s-4) var(--s-5);
  padding-inline: var(--s-6);
  border-block-start: 1px solid var(--c-line);
}
.ui-dialog[role='alertdialog'] .ui-dialog__title,
.ui-dialog--alert .ui-dialog__title {
  display: flex;
  align-items: center;
  gap: var(--s-2);
}
.ui-dialog--danger .ui-dialog__title .ui-icon {
  color: var(--c-danger);
}
.ui-dialog--sheet {
  place-items: stretch end;
  padding: 0;
}
.ui-dialog--sheet .ui-dialog__panel {
  width: min(100%, var(--w-sheet));
  max-height: none;
  height: 100%;
  border-radius: 0;
}
@media (max-width: 599px) {
  .ui-dialog,
  .ui-dialog--sheet {
    place-items: end stretch;
    padding: 0;
  }
  .ui-dialog__panel,
  .ui-dialog--wide .ui-dialog__panel,
  .ui-dialog--sheet .ui-dialog__panel {
    width: 100%;
    height: auto;
    max-height: 92dvh;
    border-radius: var(--r-lg) var(--r-lg) 0 0;
    padding-block-end: env(safe-area-inset-bottom);
  }
  .ui-dialog__foot {
    flex-direction: column-reverse;
  }
  .ui-dialog__foot > .ui-btn {
    width: 100%;
  }
}
@media (prefers-reduced-motion: no-preference) {
  .ui-dialog__panel {
    animation: ui-rise var(--m-base) var(--ease-out);
  }
  .ui-scrim {
    animation: ui-fade var(--m-base) var(--ease-out);
  }
  .ui-toast {
    animation: ui-rise var(--m-base) var(--ease-out);
  }
}
@keyframes ui-rise {
  from {
    opacity: 0;
    transform: translateY(var(--s-2));
  }
}
@keyframes ui-fade {
  from {
    opacity: 0;
  }
}

.ui-toasts {
  position: fixed;
  z-index: var(--z-toast);
  inset-inline: var(--s-4);
  inset-block-end: calc(var(--s-4) + env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  pointer-events: none;
}
@media (min-width: 600px) {
  .ui-toasts {
    inset-inline-start: auto;
    width: 24rem;
  }
}
/* On a phone a dialog is a bottom sheet whose footer holds its buttons: while one is open, toasts drop in from the
   top instead of covering Cancel (P06 review; P12 moves the team errors inline). */
@media (max-width: 599px) {
  body:has(#ui-overlays > .ui-dialog:not([hidden])) .ui-toasts {
    inset-block-start: calc(var(--s-2) + env(safe-area-inset-top));
    inset-block-end: auto;
  }
}
.ui-toast {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  min-height: var(--ctl-h);
  padding-block: var(--s-2);
  padding-inline: var(--s-4) var(--s-2);
  border: 1px solid var(--c-line);
  border-inline-start: 4px solid var(--c-ink);
  border-radius: var(--r-md);
  background: var(--c-surface);
  color: var(--c-ink);
  box-shadow: var(--e-3);
  pointer-events: auto;
}
.ui-toast--success {
  border-inline-start-color: var(--c-ready);
}
.ui-toast--success > .ui-icon {
  color: var(--c-ready-ink);
}
.ui-toast--error {
  border-inline-start-color: var(--c-danger);
}
.ui-toast--error > .ui-icon {
  color: var(--c-danger);
}
.ui-toast__msg {
  flex: 1;
  min-width: 0;
  font-weight: 500;
}

}
/* components/disclosure.css */
@layer components {
/* Disclosure, Accordion, Tabs (design-system.md §4.15, §4.16). */
.ui-accordion {
  border-block-start: 1px solid var(--c-line);
}
.ui-disc {
  border-block-end: 1px solid var(--c-line);
}
.ui-disc__head {
  margin: 0;
  font: inherit;
}
.ui-disc__btn {
  appearance: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
  width: 100%;
  min-height: var(--ctl-h);
  margin: 0;
  padding-block: var(--s-3);
  padding-inline: 0;
  border: 0;
  border-radius: var(--r-xs);
  background: none;
  color: var(--c-ink);
  font-family: var(--f-sans);
  font-size: var(--fs-16);
  line-height: var(--lh-16);
  font-weight: 600;
  text-align: start;
  cursor: pointer;
}
.ui-disc__summary {
  display: block;
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
  font-weight: 400;
}
.ui-disc__panel {
  display: grid;
  grid-template-rows: 1fr;
  transition:
    grid-template-rows var(--m-base) var(--ease),
    visibility 0s;
}
.ui-disc[data-state='closed'] > .ui-disc__panel {
  grid-template-rows: 0fr;
  visibility: hidden;
  transition:
    grid-template-rows var(--m-base) var(--ease),
    visibility 0s linear var(--m-base);
}
.ui-disc[data-initial] > .ui-disc__panel {
  transition: none;
}
.ui-disc__inner {
  min-height: 0;
  overflow: hidden;
}
.ui-disc__body {
  padding-block-end: var(--s-4);
  color: var(--c-muted);
}
.ui-disc__chev {
  color: var(--c-muted);
  transition: transform var(--m-fast) var(--ease);
}
.ui-disc__btn[aria-expanded='true'] .ui-disc__chev {
  transform: rotate(180deg);
}

.ui-tabs__list {
  display: flex;
  gap: var(--s-1);
  overflow-x: auto;
  border-block-end: 1px solid var(--c-line);
  scrollbar-width: none;
}
/* Phones: tabs that don't fit scroll sideways; the inline-end edge fades so it's clear there are more, and the
   padding lets the last tab scroll clear of the fade. */
@media (max-width: 599px) {
  .ui-tabs:not(.ui-tabs--seg) .ui-tabs__list {
    scroll-padding-inline: var(--s-6);
    padding-inline-end: var(--s-6);
    mask-image: linear-gradient(to left, transparent, #000 var(--s-6));
  }
  [dir='rtl'] .ui-tabs:not(.ui-tabs--seg) .ui-tabs__list {
    mask-image: linear-gradient(to right, transparent, #000 var(--s-6));
  }
}
.ui-tab {
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  min-height: var(--ctl-h);
  margin: 0 0 -1px;
  padding-inline: var(--s-4);
  border: 0;
  border-block-end: 3px solid transparent;
  border-radius: var(--r-xs) var(--r-xs) 0 0;
  background: none;
  color: var(--c-muted);
  font: inherit;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
}
.ui-tab:hover {
  color: var(--c-ink);
}
.ui-tab[aria-selected='true'] {
  border-block-end-color: var(--c-accent-edge);
  color: var(--c-ink);
}
.ui-tab:focus-visible {
  box-shadow: inset 0 0 0 2px var(--c-focus);
}
.ui-tabs__panel {
  padding-block-start: var(--s-4);
}
.ui-tabs__panel:focus-visible {
  box-shadow: none;
  outline: 2px solid var(--c-focus);
  outline-offset: 2px;
  border-radius: var(--r-xs);
}
.ui-tabs--seg .ui-tabs__list {
  border: 1px solid var(--c-line);
  border-radius: var(--r-pill);
  background: var(--c-surface-2);
  padding: var(--s-1);
}
.ui-tabs--seg .ui-tab {
  flex: 1;
  justify-content: center;
  min-height: calc(var(--ctl-h) - var(--s-2) - 2px);
  margin: 0;
  border: 0;
  border-radius: var(--r-pill);
}
.ui-tabs--seg .ui-tab[aria-selected='true'] {
  background: var(--c-surface);
  box-shadow: var(--e-1);
}

}
/* components/display.css */
@layer components {
/* Badge, Status, Avatar, Callout, LockRow, Banner, EmptyState, Skeleton, Spinner, ProgressBar, Stat, Card,
   Fieldset, CopyField, Steps, Logo tile (design-system.md §4.17–4.36). */
.ui-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--s-1);
  min-height: var(--s-5);
  padding-inline: var(--s-2);
  border-radius: var(--r-pill);
  background: var(--c-surface-2);
  color: var(--c-ink);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  font-weight: var(--fw-medium);
  white-space: nowrap;
  box-shadow: inset 0 0 0 1px var(--c-line);
}
.ui-badge .ui-icon {
  width: 1.1em;
  height: 1.1em;
}
.ui-badge--brand {
  background: var(--c-accent-soft);
  color: var(--c-accent-ink);
  box-shadow: none;
}
.ui-badge--now {
  background: var(--c-now-soft);
  box-shadow: none;
}
.ui-badge--ready {
  background: var(--c-ready-soft);
  color: var(--c-ready-ink);
  box-shadow: none;
}
.ui-badge--late {
  background: var(--c-late-soft);
  color: var(--c-ink);
  box-shadow: none;
}
.ui-badge--danger {
  background: var(--c-danger-soft);
  color: var(--c-danger);
  box-shadow: none;
}
.ui-badge--ink {
  background: var(--c-ink);
  color: var(--c-bg);
  box-shadow: none;
}
/* Indigo: something Bellou did (R-13). Nothing else in the product is indigo. */
.ui-badge--bellou {
  background: var(--c-acting);
  color: var(--c-on-acting);
  box-shadow: none;
}
.ui-badge--outline {
  background: transparent;
}
.ui-badge--strong {
  background: var(--n-4);
  box-shadow: inset 0 0 0 1px var(--n-7);
}
.ui-badge__dot {
  width: calc(var(--s-1) * 1.5);
  height: calc(var(--s-1) * 1.5);
  border-radius: var(--r-pill);
  background: currentColor;
}

.ui-status {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  white-space: nowrap;
  min-height: calc(var(--s-6) + 2px);
  padding-inline: var(--s-2) var(--s-3);
  border-radius: var(--r-pill);
  background: var(--c-surface-2);
  color: var(--c-ink);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
  font-weight: 500;
}
.ui-status__dot {
  width: var(--s-2);
  height: var(--s-2);
  border-radius: var(--r-pill);
  background: currentColor;
}
.ui-status--trial {
  background: var(--c-now-soft);
}
.ui-status--active {
  background: var(--c-ready-soft);
  color: var(--c-ready-ink);
}
.ui-status--suspended {
  background: var(--c-danger-soft);
  color: var(--c-danger);
}
.ui-status--overdue {
  background: var(--c-late-soft);
}
.ui-status--closed .ui-status__dot {
  background: transparent;
  box-shadow: inset 0 0 0 2px currentColor;
}

.ui-avatar {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: var(--s-8);
  height: var(--s-8);
  border-radius: 50%;
  background: var(--n-4);
  color: var(--c-ink);
  font-size: var(--fs-13);
  line-height: 1;
  font-weight: var(--fw-strong);
  text-transform: uppercase;
}
.ui-avatar--24 {
  width: var(--s-6);
  height: var(--s-6);
  font-size: var(--fs-12);
}
.ui-avatar--icon {
  color: var(--c-muted);
}
.ui-avatar--icon .ui-icon {
  width: 60%;
  height: 60%;
}
.ui-avatar--40 {
  width: var(--s-10);
  height: var(--s-10);
  font-size: var(--fs-16);
}
.ui-avatar--hq {
  background: var(--c-acting-soft);
  color: var(--c-acting-ink);
}

.ui-callout {
  display: flex;
  align-items: flex-start;
  gap: var(--s-3);
  padding: var(--s-3) var(--s-4);
  border-radius: var(--r-md);
  background: var(--c-surface-2);
  color: var(--c-ink);
  box-shadow: inset 0 0 0 1px var(--c-line);
}
.ui-callout > .ui-icon {
  margin-block-start: 2px;
}
.ui-callout__body {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
  min-width: 0;
}
.ui-callout__title {
  margin: 0;
  font-weight: 600;
}
.ui-callout__text {
  margin: 0;
}
.ui-callout--warn {
  background: var(--c-late-soft);
  box-shadow: none;
}
.ui-callout--warn > .ui-icon {
  color: var(--c-late);
}
.ui-callout--danger {
  background: var(--c-danger-soft);
  box-shadow: none;
}
.ui-callout--danger > .ui-icon {
  color: var(--c-danger);
}
.ui-callout--success {
  background: var(--c-ready-soft);
  box-shadow: none;
}
.ui-callout--success > .ui-icon {
  color: var(--c-ready-ink);
}

.ui-lockrow {
  display: grid;
  grid-template-columns: auto 1fr;
  column-gap: var(--s-3);
  row-gap: var(--s-1);
  padding-block: var(--s-3);
  border-block-end: 1px solid var(--c-line);
}
.ui-lockrow > .ui-icon {
  grid-row: span 3;
  margin-block-start: 2px;
  color: var(--c-muted);
}
.ui-lockrow:last-child {
  border-block-end: 0;
}
.ui-lockrow__label {
  color: var(--c-ink);
  font-weight: var(--fw-medium);
  font-size: var(--fs-14);
}
/* The action names what happens (R-56) and may be long: it wraps inside the row instead of overflowing it. */
.ui-lockrow > .ui-btn {
  justify-self: start;
  max-width: 100%;
  height: auto;
  min-height: var(--ctl-sm);
  margin-block-start: var(--s-1);
  white-space: normal;
  text-align: start;
}
.ui-lockrow__value {
  font-weight: 500;
}
.ui-lockrow__reason {
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}

.ui-banner {
  position: sticky;
  inset-block-start: 0;
  z-index: var(--z-banner);
  display: flex;
  align-items: center;
  gap: var(--s-3);
  min-height: var(--h-banner);
  padding-inline: var(--s-4);
  background: var(--c-surface-2);
  color: var(--c-ink);
  font-size: var(--fs-14);
  font-weight: 500;
  border-block-end: 1px solid var(--c-line);
}
.ui-banner__text {
  flex: 1;
  min-width: 0;
}
@media (max-width: 599px) {
  .ui-banner__text {
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
  }
}
.ui-banner--support {
  background: var(--c-late-soft);
}
.ui-banner--plan {
  background: var(--c-accent-soft);
}
.ui-banner--env {
  background: var(--c-env-staging);
  color: #fff;
}

.ui-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-2);
  padding: var(--s-10) var(--s-4);
  text-align: center;
}
.ui-empty > .ui-icon {
  width: var(--s-12);
  height: var(--s-12);
  color: var(--c-muted);
  stroke-width: 1.5;
}
.ui-empty__title {
  margin: 0;
  font-size: var(--fs-20);
  line-height: var(--lh-20);
  font-weight: 600;
}
.ui-empty__text {
  margin: 0 0 var(--s-2);
  max-width: 28rem;
  color: var(--c-muted);
}

.ui-skel {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
}
.ui-skel__b {
  display: block;
  height: var(--s-4);
  border-radius: var(--r-sm);
  background: var(--c-skeleton);
}
.ui-skel--text .ui-skel__b {
  width: 60%;
}
.ui-skel--title .ui-skel__b {
  width: 40%;
  height: var(--s-6);
}
.ui-skel--stat .ui-skel__b {
  width: 8rem;
  height: var(--s-10);
}
.ui-skel--row .ui-skel__b {
  height: var(--h-row);
}
.ui-skel--card .ui-skel__b {
  height: 8rem;
  border-radius: var(--r-md);
}
.ui-skel--ticket .ui-skel__b {
  height: 16rem;
  border-radius: var(--r-lg);
}
@media (prefers-reduced-motion: no-preference) {
  .ui-skel__b {
    background: linear-gradient(
      90deg,
      var(--c-skeleton) 30%,
      var(--c-skeleton-hi) 50%,
      var(--c-skeleton) 70%
    );
    background-size: 300% 100%;
    animation: ui-shimmer 1.4s linear infinite;
  }
}
/* Presets (skeletonPreset): table rows, stat cards, chart bars, a detail header, list rows. Shown only after 150 ms
   on client-fetched regions (data-delay), never on server-rendered first paint. */
.ui-skel[data-delay] {
  animation: ui-skel-in var(--dur-1) linear 150ms both;
}
@keyframes ui-skel-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
.ui-skel__head,
.ui-skel__tr {
  display: grid;
  grid-template-columns: 3fr 2fr 2fr 1fr;
  gap: var(--s-4);
  align-items: center;
  min-height: var(--row-h);
}
.ui-skel__head .ui-skel__b {
  height: var(--s-2);
}
.ui-skel--stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--s-4);
}
.ui-skel__stat {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  padding: var(--pad-card);
  border: 1px solid var(--c-line);
  border-radius: var(--r-card);
}
.ui-skel__b--sm {
  width: 50%;
  height: var(--s-3);
}
.ui-skel__b--lg {
  width: 70%;
  height: var(--s-6);
}
.ui-skel__chart {
  display: flex;
  align-items: flex-end;
  gap: var(--s-2);
  height: var(--h-chart);
}
.ui-skel__chart .ui-skel__b {
  flex: 1;
  height: 40%;
}
.ui-skel__chart .ui-skel__b:nth-child(3n) {
  height: 70%;
}
.ui-skel__chart .ui-skel__b:nth-child(4n + 1) {
  height: 25%;
}
.ui-skel__entity {
  display: flex;
  align-items: center;
  gap: var(--s-4);
}
.ui-skel__b--tile {
  width: var(--w-tile-lg);
  height: var(--w-tile-lg);
  border-radius: var(--r-card);
}
.ui-skel__lines {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: var(--s-2);
}
.ui-skel__li {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  min-height: var(--row-h);
}
.ui-skel__b--dot {
  flex: none;
  width: var(--s-8);
  height: var(--s-8);
  border-radius: var(--r-pill);
}
.ui-skel__li .ui-skel__b:not(.ui-skel__b--dot) {
  flex: 1;
}
@keyframes ui-shimmer {
  from {
    background-position: 100% 0;
  }
  to {
    background-position: 0 0;
  }
}

.ui-spin {
  display: inline-block;
  flex: none;
  width: var(--s-5);
  height: var(--s-5);
  border: 2px solid currentColor;
  border-block-start-color: transparent;
  border-radius: 50%;
  opacity: 0.8;
}
.ui-spin--16 {
  width: var(--s-4);
  height: var(--s-4);
}
.ui-spin--24 {
  width: var(--s-6);
  height: var(--s-6);
}
@media (prefers-reduced-motion: no-preference) {
  .ui-spin {
    animation: ui-rotate 0.8s linear infinite;
  }
}
@media (prefers-reduced-motion: reduce) {
  .ui-spin {
    animation: ui-pulse 1.2s ease-in-out infinite;
  }
}
@keyframes ui-rotate {
  to {
    transform: rotate(360deg);
  }
}
@keyframes ui-pulse {
  50% {
    opacity: 0.3;
  }
}

.ui-progressbar {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
}
.ui-progressbar__track {
  position: relative;
  display: flex;
  height: var(--s-1);
  overflow: hidden;
  border-radius: var(--r-pill);
  background: var(--c-surface-2);
  box-shadow: inset 0 0 0 1px var(--c-line);
}
.ui-progressbar--lg .ui-progressbar__track {
  height: var(--s-2);
}
.ui-progressbar__fill {
  border-radius: var(--r-pill);
  background: var(--c-accent);
}
.ui-progressbar[data-complete] .ui-progressbar__fill {
  background: var(--c-ready);
}
.ui-progressbar__label {
  display: flex;
  justify-content: space-between;
  color: var(--c-muted);
  font-size: var(--fs-14);
}
/* Fill widths come from classes (no inline styles): ui-w-0 … ui-w-100 in steps of 5. */
.ui-progressbar__fill.ui-w-0 {
  width: 0%;
}
.ui-progressbar__fill.ui-w-5 {
  width: 5%;
}
.ui-progressbar__fill.ui-w-10 {
  width: 10%;
}
.ui-progressbar__fill.ui-w-15 {
  width: 15%;
}
.ui-progressbar__fill.ui-w-20 {
  width: 20%;
}
.ui-progressbar__fill.ui-w-25 {
  width: 25%;
}
.ui-progressbar__fill.ui-w-30 {
  width: 30%;
}
.ui-progressbar__fill.ui-w-35 {
  width: 35%;
}
.ui-progressbar__fill.ui-w-40 {
  width: 40%;
}
.ui-progressbar__fill.ui-w-45 {
  width: 45%;
}
.ui-progressbar__fill.ui-w-50 {
  width: 50%;
}
.ui-progressbar__fill.ui-w-55 {
  width: 55%;
}
.ui-progressbar__fill.ui-w-60 {
  width: 60%;
}
.ui-progressbar__fill.ui-w-65 {
  width: 65%;
}
.ui-progressbar__fill.ui-w-70 {
  width: 70%;
}
.ui-progressbar__fill.ui-w-75 {
  width: 75%;
}
.ui-progressbar__fill.ui-w-80 {
  width: 80%;
}
.ui-progressbar__fill.ui-w-85 {
  width: 85%;
}
.ui-progressbar__fill.ui-w-90 {
  width: 90%;
}
.ui-progressbar__fill.ui-w-95 {
  width: 95%;
}
.ui-progressbar__fill.ui-w-100 {
  width: 100%;
}
.ui-progressbar[data-indeterminate] .ui-progressbar__fill {
  width: 30%;
}
@media (prefers-reduced-motion: no-preference) {
  .ui-progressbar[data-indeterminate] .ui-progressbar__fill {
    animation: ui-indeterminate 1.2s var(--ease) infinite;
  }
}
@keyframes ui-indeterminate {
  from {
    transform: translateX(-100%);
  }
  to {
    transform: translateX(340%);
  }
}
[dir='rtl'] .ui-progressbar[data-indeterminate] .ui-progressbar__fill {
  animation-direction: reverse;
}
/* The track is a flex row, so the fill already starts at inline-start (the right in Arabic). */

.ui-stat {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
}
.ui-stat__label {
  color: var(--c-muted);
  font-size: var(--fs-14);
  font-weight: 500;
}
.ui-stat__value {
  font-size: var(--fs-28);
  line-height: var(--lh-28);
  font-weight: var(--fw-strong);
  font-variant-numeric: tabular-nums;
}
.ui-stat--compact .ui-stat__value {
  font-size: var(--fs-24);
  line-height: var(--lh-24);
}
.ui-stat__delta {
  display: inline-flex;
  align-items: center;
  gap: var(--s-1);
  font-size: var(--fs-14);
  font-weight: 600;
}
.ui-stat__delta--up {
  color: var(--c-ready-ink);
}
.ui-stat__delta--down {
  color: var(--c-late);
}
.ui-stat__hint {
  color: var(--c-muted);
  font-size: var(--fs-14);
}

.ui-card {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  padding: var(--s-4);
  border: 1px solid var(--c-line);
  border-radius: var(--r-md);
  background: var(--c-surface);
  color: var(--c-ink);
}
@media (min-width: 600px) {
  .ui-card {
    padding: var(--s-6);
  }
}
.ui-card--interactive {
  text-decoration: none;
  cursor: pointer;
}
.ui-card--interactive:hover {
  border-color: var(--c-line-strong);
}
.ui-card__title {
  margin: 0;
  font-size: var(--fs-18);
  line-height: var(--lh-18);
  font-weight: 600;
}
.ui-fieldset {
  margin: 0;
  min-width: 0;
}
.ui-fieldset__head {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
}
.ui-fieldset__desc {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}

.ui-copyfield {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  min-height: var(--ctl-h);
  padding-inline: var(--s-3) var(--s-1);
  border: 1px solid var(--c-line);
  border-radius: var(--r-sm);
  background: var(--c-surface-2);
}
.ui-copyfield__value {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  direction: ltr;
  unicode-bidi: isolate;
  text-align: start;
}
.ui-copyfield__manual {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-14);
}

.ui-steps {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}
.ui-steps__list {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
  list-style: none;
}
.ui-step {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: var(--s-3);
  min-height: var(--h-row);
  padding-block: var(--s-2);
  border-block-end: 1px solid var(--c-line);
}
.ui-step__mark {
  display: grid;
  place-items: center;
  width: var(--s-6);
  height: var(--s-6);
  border: 2px solid var(--c-line-strong);
  border-radius: 50%;
  color: var(--c-on-accent);
}
.ui-step[data-state='done'] .ui-step__mark {
  border-color: var(--c-ready);
  background: var(--c-ready);
}
.ui-step[data-state='next'] {
  align-items: start;
  padding-block: var(--s-4);
}
.ui-step[data-state='next'] .ui-step__mark {
  border-color: var(--c-accent-edge);
}
.ui-step__title {
  font-weight: 600;
}
.ui-step[data-state='done'] .ui-step__title {
  color: var(--c-muted);
  font-weight: 500;
}
.ui-step__why {
  margin: var(--s-1) 0 var(--s-3);
  color: var(--c-muted);
  font-size: var(--fs-14);
}

.ui-logo {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: var(--s-10);
  height: var(--s-10);
  overflow: hidden;
  border-radius: var(--r-sm);
  /* The client's identity (P03 --brand / --on-brand, with its edge for very light brands), never the accent tier:
     inside HQ ink (data-primary=ink) a client's logo tile keeps the client's colour. */
  background: var(--brand);
  box-shadow: inset 0 0 0 1px var(--brand-edge, transparent);
  color: var(--on-brand);
  font-weight: var(--fw-strong);
  font-size: var(--fs-18);
}
/* Bellou's own mark in the HQ app bar is neutral chrome (ink), like every HQ primary. */
.ui-appbar--hq > .ui-appbar__brand .ui-logo:not(.ui-logo--img) {
  background: var(--c-hq-primary);
  box-shadow: none;
  color: var(--c-on-hq-primary);
}
.ui-logo--32 {
  width: var(--s-8);
  height: var(--s-8);
  font-size: var(--fs-14);
}
.ui-logo--56 {
  width: calc(var(--s-12) + var(--s-2));
  height: calc(var(--s-12) + var(--s-2));
  font-size: var(--fs-24);
}
.ui-logo--img {
  background: #fff;
  box-shadow: inset 0 0 0 1px var(--c-line);
}
/* The plate rule (R-65): a white or light logo the white tile would swallow sits on the brand or ink plate. */
.ui-logo--img[data-plate='brand'] {
  background: var(--brand, var(--c-brand));
  box-shadow: inset 0 0 0 1px var(--brand-edge, transparent);
}
.ui-logo--img[data-plate='ink'] {
  background: var(--c-chrome-bg);
  box-shadow: none;
}
.ui-logo img {
  width: 76%;
  height: 76%;
  object-fit: contain;
}

}
/* components/shell.css */
@layer components {
/* AppBar, AccountChip, Nav, PageHeader, BackLink, SaveBar (design-system.md §4.28, §4.29, §4.44). */
.ui-appbar {
  position: sticky;
  inset-block-start: 0;
  z-index: var(--z-appbar);
  display: flex;
  align-items: center;
  gap: var(--s-3);
  min-height: var(--h-appbar);
  padding-inline: var(--s-4);
  border-block-end: 1px solid var(--c-line);
  background: var(--c-surface);
  color: var(--c-ink);
}
.ui-appbar__brand {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  min-width: 0;
  max-width: 40%;
  color: inherit;
  text-decoration: none;
}
.ui-appbar__name {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: var(--fs-16);
  line-height: var(--lh-16);
  font-weight: var(--fw-strong);
}
.ui-appbar__scope {
  color: var(--c-muted);
  font-size: var(--fs-14);
  white-space: nowrap;
}
@media (max-width: 599px) {
  .ui-appbar__scope {
    display: none;
  }
}
.ui-appbar__end {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  margin-inline-start: auto;
}
/* HQ: a LIGHT app bar (experience-v2 §6.1); the graphite is the rail's. */
.ui-appbar--hq {
  min-height: var(--s-12);
  background: var(--c-surface);
  color: var(--c-ink);
}
.ui-appbar--hq .ui-appbar__scope {
  color: var(--c-muted);
}
/* Phones: the "B" mark alone; "Bellou HQ" would be cut to "B…" beside the account chip. */
@media (max-width: 599px) {
  .ui-appbar--hq .ui-appbar__name {
    /* Visually hidden, still the home link's accessible name. */
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
  }
}
.ui-appbar__env {
  display: inline-flex;
  align-items: center;
  min-height: var(--s-5);
  padding-inline: var(--s-2);
  border-radius: var(--r-2);
  background: var(--n-5);
  color: var(--c-ink);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  font-weight: var(--fw-strong);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
/* PROD is red (a warning, the one place red is allowed in HQ chrome), STAGING amber, DEV grey. */
.ui-appbar__env--prod {
  background: var(--c-danger);
  color: var(--c-surface);
}
.ui-appbar__env--staging {
  background: var(--c-now);
  color: var(--c-on-now);
}

.ui-account {
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  min-height: var(--ctl-h);
  margin: 0;
  padding-inline: var(--s-1) var(--s-2);
  border: 1px solid var(--c-line);
  border-radius: var(--r-pill);
  background: var(--c-surface);
  color: var(--c-ink);
  font: inherit;
  cursor: pointer;
}
.ui-account:hover {
  border-color: var(--c-line-strong);
}
.ui-account__name {
  max-width: 16ch;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: var(--fs-13);
  font-weight: var(--fw-medium);
}
.ui-account__scope {
  color: var(--c-muted);
  font-size: var(--fs-12);
  white-space: nowrap;
}
@media (max-width: 1023px) {
  .ui-account__scope {
    display: none;
  }
}
.ui-account__foot {
  display: block;
  padding-block-start: var(--s-1);
  color: var(--c-muted);
  font-size: var(--fs-12);
}
.ui-account__footlink {
  color: inherit;
}
@media (max-width: 599px) {
  .ui-account__name {
    display: none;
  }
}
.ui-account__who {
  font-weight: 600;
}
.ui-account__role {
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}

.ui-nav {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
  padding: var(--s-2);
}
.ui-nav__list {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
  margin: 0;
  padding: 0;
  list-style: none;
}
.ui-nav__item {
  position: relative;
  display: flex;
  align-items: center;
  gap: var(--s-3);
  min-height: var(--ctl-h);
  padding-inline: var(--s-3);
  border-radius: var(--r-sm);
  color: var(--c-ink);
  font-weight: 500;
  text-decoration: none;
}
.ui-nav__item:hover {
  background: var(--c-surface-2);
}
.ui-nav__item[aria-current='page'] {
  background: var(--n-4);
  color: var(--c-ink);
  font-weight: 600;
}
.ui-nav__item[aria-current='page']::before {
  content: '';
  position: absolute;
  inset-block: var(--s-2);
  inset-inline-start: 0;
  width: 3px;
  border-radius: var(--r-pill);
  background: var(--c-accent-edge);
}
.ui-nav--bar .ui-nav__list {
  flex-direction: row;
  justify-content: space-around;
}
.ui-nav--bar .ui-nav__item {
  flex-direction: column;
  gap: 2px;
  padding-block: var(--s-1);
  font-size: var(--fs-12);
}
.ui-nav--bar .ui-nav__item[aria-current='page'] {
  background: none;
}
.ui-nav--bar .ui-nav__item[aria-current='page']::before {
  display: none;
}

.ui-pagehead {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  padding-block: var(--s-6) var(--s-4);
}
.ui-pagehead__row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--s-3);
}
.ui-pagehead__titles {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
  min-width: 0;
}
.ui-pagehead__desc {
  margin: 0;
  color: var(--c-muted);
  max-width: 40rem;
}
.ui-pagehead__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
}
@media (max-width: 599px) {
  .ui-pagehead__actions {
    width: 100%;
  }
  .ui-pagehead__actions > .ui-btn--primary {
    flex: 1;
  }
}
.ui-backlink {
  display: inline-flex;
  align-items: center;
  gap: var(--s-1);
  align-self: flex-start;
  min-height: var(--ctl-h);
  border-radius: var(--r-xs);
  color: var(--c-accent-ink);
  font-weight: 600;
  text-decoration: none;
}
.ui-backlink:hover {
  text-decoration: underline;
}

.ui-savebar {
  position: sticky;
  inset-block-end: 0;
  z-index: var(--z-sticky);
  display: flex;
  align-items: center;
  gap: var(--s-3);
  min-height: var(--h-savebar);
  padding-block: var(--s-2);
  padding-inline: var(--s-4);
  padding-block-end: calc(var(--s-2) + env(safe-area-inset-bottom));
  border-block-start: 1px solid var(--c-line);
  background: var(--c-surface);
  box-shadow: var(--e-1);
}
.ui-savebar__text {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  flex: 1;
  min-width: 0;
  font-weight: 500;
}
.ui-savebar__dot {
  width: var(--s-2);
  height: var(--s-2);
  border-radius: 50%;
  background: var(--c-now);
}

}
/* components/color-field.css */
@layer components {
/* ColorField v2 (P03; prd-branding §5.4). The trigger row (.ui-color__row, chip, hex) is in popover.css; this file
   adds the readout, warnings, the portalled popover and the custom picker. The popover is moved to the overlay
   root while open and positioned by a constructed stylesheet (top/left only), so no container can clip it and no
   style attribute is ever written. Colours on the picker are SVG attributes. */

.ui-color {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}

/* "How it looks": a button in the colour with its derived text and ring, link text in its ink, and the dark
   theme's link on the dark surface, each with its contrast ratio. Wraps under the label on narrow screens. */
.ui-color__preview {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-3);
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.ui-color__sample {
  flex: none;
  width: 18.75rem;
  max-width: 100%;
  height: auto;
  aspect-ratio: 300 / 56;
  font-family: var(--f-sans);
}

.ui-color__warnings {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}
.ui-color__warnings:empty {
  display: none;
}
.ui-color__invalid {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  margin: 0;
  color: var(--c-danger);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
  font-weight: 500;
}
.ui-color__warn {
  padding: var(--s-3);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.ui-color__warn > .ui-icon {
  color: var(--c-muted);
}
.ui-color__warn .ui-callout__body {
  gap: var(--s-2);
}
.ui-color__suggest {
  align-self: flex-start;
  min-height: calc(var(--ctl-h) - var(--s-2));
  padding-inline: var(--s-2) var(--s-3);
  font-size: var(--fs-14);
}
.ui-color__suggest-chip {
  width: var(--s-5);
  height: var(--s-5);
  border-radius: var(--r-pill);
  box-shadow: inset 0 0 0 1px var(--c-line-strong);
}
.ui-color__suggest-label {
  font-family: var(--f-mono);
  font-size: var(--fs-14);
}

/* The popover, portalled. Without adoptedStyleSheets it stays centred on screen, still never clipped. */
.ui-color__pop {
  width: 20rem;
  min-width: 0;
  max-height: none;
  overflow: visible;
  gap: var(--s-4);
  padding: var(--s-4);
}
.ui-color__pop[data-portal] {
  position: fixed;
  z-index: var(--z-popover);
  inset: auto;
  top: 50%;
  left: 50%; /* rtl-ok: centred fallback; JS positions it against the trigger in both directions */
  translate: -50% -50%;
  max-width: calc(100vw - var(--s-8));
}
.ui-color__pop[data-portal][data-placement] {
  translate: none;
}
.ui-dialog .ui-color__pop,
#ui-overlays .ui-color__pop {
  z-index: calc(var(--z-overlay) + 1);
}
.ui-color__pop[data-portal][data-sheet] {
  inset: auto 0 0;
  translate: none;
  width: auto;
  max-width: none;
  max-height: 85dvh;
  overflow: auto;
  padding-block-end: calc(var(--s-4) + env(safe-area-inset-bottom));
  border-radius: var(--r-lg) var(--r-lg) 0 0;
  box-shadow: var(--e-3);
}
.ui-color__group {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}
.ui-color__group-label {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
.ui-color__pop .ui-swatches {
  grid-template-columns: repeat(6, var(--ctl-h));
  justify-content: space-between;
}
.ui-color__pop[data-sheet] .ui-swatches {
  grid-template-columns: repeat(auto-fill, var(--ctl-h));
  justify-content: start;
}
/* A swatch's check reads on light and dark swatches alike. */
.ui-color__pop .ui-swatch .ui-icon {
  color: #fff;
  filter: drop-shadow(0 0 1px #000) drop-shadow(0 0 2px color-mix(in srgb, #000 50%, transparent));
}
.ui-color__pop .ui-swatch svg {
  box-shadow: inset 0 0 0 1px color-mix(in srgb, #000 12%, transparent);
}
.ui-color__foot {
  display: flex;
  justify-content: space-between;
  gap: var(--s-2);
  padding-block-start: var(--s-1);
  border-block-start: 1px solid var(--c-line);
}
.ui-color__foot .ui-btn {
  margin-block-start: var(--s-3);
}

/* Picker: a saturation/brightness area and a hue strip. Colour runs left to right in every language. */
.ui-picker {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
}
.ui-picker__area,
.ui-picker__hue {
  position: relative;
  display: block;
  border-radius: var(--r-xs);
  cursor: crosshair;
  touch-action: none;
  user-select: none;
  -webkit-user-select: none;
  /* The colours are the content: keep them in high-contrast modes. */
  forced-color-adjust: none;
}
.ui-picker__area {
  aspect-ratio: 160 / 100;
}
.ui-picker__hue {
  aspect-ratio: 160 / 20;
  cursor: ew-resize;
}
.ui-picker__svg {
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
}
.ui-picker__area:focus-visible,
.ui-picker__hue:focus-visible {
  outline: 2px solid var(--c-focus);
  outline-offset: 3px;
}

}
/* components/fill-edge.css */
@layer components {
/* P03 fill rule (release-v2 R-65, WCAG 1.4.11). The client's colour fills controls exactly as typed, so a white,
   yellow or pastel fill could vanish on a white surface. The theme sets --c-accent-fill-edge (and --brand-edge for
   identity fills) to `transparent` when the fill already has 3:1 against its surface, else to a shade that does;
   every brand-filled control ALWAYS draws its 1 px ring in that token, so a strong fill shows no ring and a light
   one is outlined. Non-text indicators (selected borders, progress, markers) use --c-accent-edge (>= 3:1).
   Interim home until P08 folds these into each component; Bellou red renders exactly as before. */

.ui-btn--primary {
  border-color: var(--c-accent-fill-edge);
}

.ui-check__ctl[aria-checked='true'] .ui-check__box,
.ui-check__ctl[aria-checked='mixed'] .ui-check__box {
  border-color: var(--c-accent-edge);
}

.ui-chip[aria-checked='true'] {
  border-color: var(--c-accent-edge);
}

.ui-switch__ctl[aria-checked='true'] {
  box-shadow: inset 0 0 0 1px var(--c-accent-fill-edge);
}

.ui-radiocard[aria-checked='true'] {
  border-color: var(--c-accent-edge);
  box-shadow: inset 0 0 0 1px var(--c-accent-edge);
}
.ui-radiocard[aria-checked='true']:focus-visible {
  box-shadow:
    inset 0 0 0 1px var(--c-accent-edge),
    0 0 0 2px var(--c-surface),
    0 0 0 4px var(--c-focus);
}
.ui-radiocard[aria-checked='true'] .ui-radiocard__dot {
  border-color: var(--c-accent-edge);
}
.ui-radiocard[aria-checked='true'] .ui-radiocard__dot::after {
  background: var(--c-accent-edge);
}

.ui-progressbar__fill {
  background: var(--c-accent-edge);
}
.ui-step[data-state='next'] .ui-step__mark {
  border-color: var(--c-accent-edge);
}

/* Identity: the monogram tile is the brand as typed, with what reads on it and its edge. */
.ui-logo:not(.ui-logo--img) {
  color: var(--on-brand);
  box-shadow: inset 0 0 0 1px var(--brand-edge);
}


}
/* components/data.css */
@layer components {
/* Data display (P08): DataTable + ListRow fallback, Pagination, FilterBar, FilterChips, DescriptionList, Timeline,
   BarChart, StatCard. Rows are --row-h tall; numbers right-aligned with tabular figures; density from the shell. */

/* ── DataTable ───────────────────────────────────────────────────────────────────────────────────────────── */
.ui-table {
  position: relative;
  background: var(--c-surface);
  border: 1px solid var(--c-line);
  border-radius: var(--r-card);
  overflow: clip;
}
.ui-table__scroll {
  overflow-x: auto;
}
.ui-table__t {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: var(--fs-body);
  line-height: var(--lh-body);
}
.ui-th {
  position: sticky;
  inset-block-start: 0;
  z-index: 1;
  height: var(--ctl-h);
  padding-block: 0;
  padding-inline: var(--s-4);
  background: var(--n-1);
  border-block-end: 1px solid var(--c-line);
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  font-weight: var(--fw-medium);
  text-align: start;
  white-space: nowrap;
}
.ui-th--end {
  text-align: end;
}
.ui-th--check,
.ui-td--check {
  width: var(--s-10);
  padding-inline-end: 0;
}
.ui-th__btn {
  all: unset;
  display: inline-flex;
  align-items: center;
  gap: var(--s-1);
  cursor: pointer;
  border-radius: var(--r-control);
  color: inherit;
}
.ui-th__btn:hover {
  color: var(--c-ink);
}
.ui-th__btn:focus-visible {
  box-shadow:
    0 0 0 2px var(--c-surface),
    0 0 0 4px var(--c-focus);
}
.ui-th--end .ui-th__btn {
  flex-direction: row-reverse;
}
.ui-th__sort {
  display: inline-flex;
  opacity: 0;
  transition: opacity var(--dur-1) var(--ease-standard);
}
.ui-th__sort .ui-icon {
  width: var(--s-3);
  height: var(--s-3);
}
.ui-th__btn:hover .ui-th__sort,
.ui-th[data-sorted] .ui-th__sort {
  opacity: 1;
}
.ui-th[data-sorted] {
  color: var(--c-ink);
}
.ui-td {
  height: var(--row-h);
  padding-block: var(--s-2);
  padding-inline: var(--s-4);
  border-block-end: 1px solid var(--c-line);
  vertical-align: middle;
  color: var(--c-ink);
}
.ui-tr:last-child > .ui-td {
  border-block-end: 0;
}
.ui-td--end {
  text-align: end;
  white-space: nowrap;
}
.ui-td--grow {
  width: 100%;
}
.ui-tr {
  position: relative;
}
.ui-tr:hover > .ui-td,
.ui-tr:focus-within > .ui-td {
  background: var(--n-1);
}
.ui-tr[aria-selected='true'] > .ui-td {
  background: var(--c-accent-soft);
}
/* One link per row, stretched over the whole row; other controls in the row sit above it. */
.ui-row-link {
  color: inherit;
  font-weight: var(--fw-medium);
  text-decoration: none;
  border-radius: var(--r-2);
}
.ui-tr--link .ui-row-link::after,
.ui-listrow--link .ui-row-link::after {
  content: '';
  position: absolute;
  inset: 0;
}
.ui-row-link:focus-visible {
  box-shadow: none;
}
.ui-tr--link:focus-within {
  outline: 2px solid var(--c-focus);
  outline-offset: -2px;
}
.ui-tr--link:hover {
  cursor: pointer;
}
.ui-tr .ui-menu,
.ui-tr .ui-check,
.ui-tr .ui-btn,
.ui-listrow .ui-menu {
  position: relative;
  z-index: 1;
}
/* Each of those is its own stacking context (z-index 1), so an open menu would sit under the rows after it, whose
   buttons share that z-index and come later: lift the one that is open above them. */
.ui-tr .ui-menu:has(> .ui-pop:not([hidden])),
.ui-listrow .ui-menu:has(> .ui-pop:not([hidden])) {
  z-index: var(--z-popover);
}
.ui-tr--skel .ui-skel__b {
  display: block;
  height: var(--s-3);
  border-radius: var(--r-2);
  background: var(--c-skeleton);
}
.ui-table__state {
  padding-block: var(--s-10);
  padding-inline: var(--s-6);
}
.ui-table__state--after {
  padding-block: var(--s-8);
  border-block-start: 1px solid var(--c-line);
}
.ui-table__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
  min-height: var(--ctl-h);
  padding-block: var(--s-2);
  padding-inline: var(--s-4);
  border-block-start: 1px solid var(--c-line);
  background: var(--n-1);
  color: var(--c-muted);
  font-size: var(--fs-13);
}
.ui-check--bare .ui-check__text {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.ui-check--bare .ui-check__ctl {
  min-height: 0;
  padding: 0;
}
/* Responsive tables: the table from lg, the ListRow list below. */
.ui-table--responsive .ui-table__list {
  display: none;
}
@media (max-width: 1023px) {
  .ui-table--responsive .ui-table__scroll {
    display: none;
  }
  .ui-table--responsive .ui-table__list {
    display: block;
  }
}
@media (max-width: 1023px) {
  .ui-hide-below-lg {
    display: none;
  }
}
@media (max-width: 599px) {
  .ui-hide-below-md {
    display: none;
  }
}

/* ── ListRow ─────────────────────────────────────────────────────────────────────────────────────────────── */
.ui-listrows {
  margin: 0;
  padding: 0;
  list-style: none;
}
.ui-listrow {
  position: relative;
  display: flex;
  align-items: center;
  gap: var(--s-3);
  min-height: var(--row-h);
  padding-block: var(--s-2);
  padding-inline: var(--s-4);
  border-block-end: 1px solid var(--c-line);
}
.ui-listrow:last-child {
  border-block-end: 0;
}
.ui-listrow--link:hover {
  background: var(--n-1);
}
.ui-listrow__main {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-width: 0;
}
.ui-listrow__title {
  overflow: hidden;
  color: var(--c-ink);
  font-weight: var(--fw-medium);
  text-overflow: ellipsis;
  white-space: nowrap;
}
.ui-listrow__meta {
  overflow: hidden;
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
  text-overflow: ellipsis;
  white-space: nowrap;
}
.ui-listrow__end {
  flex: none;
  color: var(--c-muted);
  font-size: var(--fs-13);
}

/* ── Pagination ──────────────────────────────────────────────────────────────────────────────────────────── */
.ui-pager {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
  width: 100%;
}
.ui-pager__range {
  color: var(--c-muted);
  font-size: var(--fs-13);
}

/* ── FilterBar and FilterChips ───────────────────────────────────────────────────────────────────────────── */
.ui-filterbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
  padding-block: var(--s-2);
}
.ui-filterbar--sticky {
  position: sticky;
  inset-block-start: var(--h-appbar);
  z-index: var(--z-sticky);
  background: var(--c-bg);
}
.ui-filterbar__search {
  flex: 1 1 var(--w-aside);
  min-width: 0;
  max-width: var(--w-aside);
}
.ui-filterbar__search .ui-field,
.ui-filterbar__filters .ui-field {
  gap: 0;
}
.ui-filterbar__search .ui-field__label,
.ui-filterbar__filters .ui-field__label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.ui-filterbar__chips,
.ui-filterbar__filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
}
.ui-filterbar__clear,
.ui-filterbar__end {
  margin-inline-start: auto;
}
.ui-fchips {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
}
.ui-fchip {
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  min-height: var(--ctl-sm);
  margin: 0;
  padding-block: 0;
  padding-inline: var(--s-3);
  border: 1px solid var(--n-6);
  border-radius: var(--r-pill);
  background: var(--c-surface);
  color: var(--c-ink);
  font: inherit;
  font-size: var(--fs-13);
  line-height: var(--lh-13);
  font-weight: var(--fw-medium);
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
}
.ui-fchip:hover {
  background: var(--n-3);
}
.ui-fchip[aria-checked='true'],
.ui-fchip[aria-current='true'] {
  border-color: var(--c-ink);
  background: var(--c-ink);
  color: var(--c-surface);
}
.ui-fchip__count {
  color: inherit;
  opacity: 0.72;
}

/* ── DescriptionList ─────────────────────────────────────────────────────────────────────────────────────── */
.ui-dl {
  display: grid;
  margin: 0;
}
.ui-dl__row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2fr) auto;
  align-items: center;
  gap: var(--s-4);
  min-height: var(--row-h);
  padding-block: var(--s-2);
  border-block-end: 1px solid var(--c-line);
}
.ui-dl__row:last-child {
  border-block-end: 0;
}
.ui-dl__term {
  color: var(--c-muted);
  font-size: var(--fs-13);
}
.ui-dl__value {
  margin: 0;
  min-width: 0;
  overflow-wrap: anywhere;
}
.ui-dl__action {
  margin: 0;
}
.ui-dl--2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: var(--s-6);
}
@media (max-width: 599px) {
  .ui-dl__row {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: var(--s-1) var(--s-3);
  }
  .ui-dl__term {
    grid-column: 1 / -1;
  }
  .ui-dl--2 {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ── Timeline ────────────────────────────────────────────────────────────────────────────────────────────── */
.ui-tlgroup__title {
  margin: 0;
  margin-block-end: var(--s-2);
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  font-weight: var(--fw-medium);
}
.ui-tl {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
  list-style: none;
}
.ui-tl__item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: var(--s-3);
  padding-block: var(--s-3);
  border-block-end: 1px solid var(--c-line);
}
.ui-tl__item:last-child {
  border-block-end: 0;
}
.ui-tl--nested {
  margin-block-start: var(--s-2);
  padding-inline-start: var(--s-3);
  border-inline-start: 2px solid var(--c-acting-soft);
}
.ui-tl--nested .ui-tl__item {
  padding-block: var(--s-2);
}
.ui-tl__body {
  min-width: 0;
}
.ui-tl__line {
  margin: 0;
  color: var(--c-ink);
}
.ui-tl__line .ui-badge {
  vertical-align: baseline;
}
.ui-tl__reason {
  margin: 0;
  margin-block-start: var(--s-1);
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.ui-tl__time {
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  white-space: nowrap;
}

/* ── BarChart ────────────────────────────────────────────────────────────────────────────────────────────── */
.ui-chart {
  margin: 0;
}
/* Columns (rebuilt 2026-11-09): an axis rail of gridlines behind an ordered list of columns. Plot height is fixed;
   widths follow the container, but text is never scaled and a bar is never wider than 24 px. */
.ui-cols {
  position: relative;
  container-type: inline-size;
  padding-block-start: var(--s-6);
  padding-inline-start: var(--s-8);
}
.ui-cols__grid {
  position: absolute;
  inset-block: var(--s-6) var(--s-6);
  inset-inline: 0;
  pointer-events: none;
}
.ui-cols__tick {
  position: absolute;
  inset-inline: 0;
  border-block-start: 1px solid var(--c-chart-grid);
}
.ui-cols__tick--0 {
  inset-block-end: 0;
  border-block-start-color: var(--c-line-strong);
}
.ui-cols__tick--50 {
  inset-block-end: 50%;
}
.ui-cols__tick--100 {
  inset-block-end: 100%;
}
.ui-cols__tickval {
  position: absolute;
  inset-inline-start: 0;
  inset-block-start: 0;
  transform: translateY(-50%);
  color: var(--c-chart-axis);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  background: var(--c-surface);
  padding-inline-end: var(--s-1);
}
.ui-cols__plot {
  position: relative;
  display: flex;
  margin: 0;
  padding: 0;
  list-style: none;
}
.ui-cols__col {
  position: relative;
  display: flex;
  flex: 1 1 0;
  flex-direction: column;
  align-items: center;
  min-width: 0;
  border-radius: var(--r-xs);
  outline: none;
}
.ui-cols__col:hover,
.ui-cols__col:focus-visible {
  background: color-mix(in oklab, var(--c-chart-grid) 45%, transparent);
}
.ui-cols__col:focus-visible {
  box-shadow: 0 0 0 2px var(--c-focus);
}
.ui-cols__track {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  inline-size: 100%;
  block-size: var(--h-chart);
}
.ui-cols__bar {
  position: relative;
  inline-size: min(var(--s-6), 64%);
  min-inline-size: 3px;
  block-size: var(--pct);
  min-block-size: 2px;
  border-start-start-radius: 4px;
  border-start-end-radius: 4px;
  background: var(--c-chart-bar);
  opacity: 0.78;
  transition:
    opacity var(--dur-1) var(--ease-standard),
    background-color var(--dur-1) var(--ease-standard);
}
.ui-cols--dense .ui-cols__bar {
  border-start-start-radius: 2px;
  border-start-end-radius: 2px;
}
.ui-cols__bar--zero {
  min-block-size: 0;
  block-size: 0;
}
.ui-cols__col--marked .ui-cols__bar,
.ui-cols__col:hover .ui-cols__bar,
.ui-cols__col:focus-visible .ui-cols__bar {
  opacity: 1;
}
.ui-cols__col:hover .ui-cols__bar,
.ui-cols__col:focus-visible .ui-cols__bar {
  background: var(--c-chart-bar-hi);
}
/* The marked bar's value sits on its cap; the full tip ("Thu 6 Nov · 211") shows on hover and focus. */
.ui-cols__val,
.ui-cols__tip {
  position: absolute;
  inset-block-end: 100%;
  inset-inline-start: 50%;
  transform: translateX(-50%);
  margin-block-end: var(--s-1);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  font-weight: var(--fw-strong);
  white-space: nowrap;
}
[dir='rtl'] .ui-cols__val,
[dir='rtl'] .ui-cols__tip {
  transform: translateX(50%);
}
.ui-cols__val {
  color: var(--c-ink);
}
/* Near the edges a label leans inwards instead of spilling out of the card. */
.ui-cols__col--start .ui-cols__val,
.ui-cols__col--start .ui-cols__tip,
[dir='rtl'] .ui-cols__col--start .ui-cols__val,
[dir='rtl'] .ui-cols__col--start .ui-cols__tip {
  inset-inline-start: 0;
  transform: none;
}
.ui-cols__col--end .ui-cols__val,
.ui-cols__col--end .ui-cols__tip,
[dir='rtl'] .ui-cols__col--end .ui-cols__val,
[dir='rtl'] .ui-cols__col--end .ui-cols__tip {
  inset-inline-start: auto;
  inset-inline-end: 0;
  transform: none;
}
.ui-cols__tip {
  z-index: 1;
  padding: 2px var(--s-2);
  border-radius: var(--r-xs);
  background: var(--c-ink);
  color: var(--c-surface);
  box-shadow: var(--e-2);
  visibility: hidden;
}
.ui-cols__col:hover .ui-cols__tip,
.ui-cols__col:focus-visible .ui-cols__tip {
  visibility: visible;
}
/* While a column is pointed at, the marked value steps back so two labels never collide. */
.ui-cols__plot:hover .ui-cols__val,
.ui-cols__plot:focus-within .ui-cols__val {
  visibility: hidden;
}
.ui-cols__x {
  block-size: var(--s-6);
  padding-block-start: var(--s-2);
  color: var(--c-chart-axis);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  white-space: nowrap;
}
.ui-cols__x--off {
  visibility: hidden;
}
@container (max-width: 540px) {
  .ui-cols__x--wide {
    visibility: hidden;
  }
}
.ui-chart__peak,
.ui-chart__empty {
  margin: 0;
  margin-block-start: var(--s-2);
  color: var(--c-muted);
  font-size: var(--fs-13);
}
.ui-chart--empty {
  display: grid;
  place-items: center;
  min-height: var(--h-chart);
}

/* StackBar: one whole in a few parts, 2 px surface gaps, a legend with counts and shares. */
.ui-stack {
  margin: 0;
}
.ui-stack__bar {
  display: flex;
  gap: 2px;
  block-size: var(--s-3);
  border-radius: var(--r-pill);
  overflow: hidden;
  background: var(--c-chart-grid);
}
.ui-stack__seg {
  inline-size: var(--pct);
  min-inline-size: var(--s-1);
}
.ui-stack__seg--good {
  background: var(--c-chart-good);
}
.ui-stack__seg--mid {
  background: var(--c-chart-mid);
}
.ui-stack__seg--bad {
  background: var(--c-chart-bad);
}
.ui-stack__legend {
  display: grid;
  grid-template-columns: auto 1fr auto auto;
  gap: var(--s-2) var(--s-3);
  align-items: center;
  margin: var(--s-4) 0 0;
  padding: 0;
  list-style: none;
}
.ui-stack__item {
  display: contents;
}
.ui-stack__key {
  inline-size: var(--s-3);
  block-size: var(--s-3);
  border-radius: 3px;
}
.ui-stack__name {
  color: var(--c-ink);
  font-size: var(--fs-14);
}
.ui-stack__val {
  color: var(--c-ink);
  font-size: var(--fs-14);
  font-weight: var(--fw-medium);
  text-align: end;
}
.ui-stack__share {
  min-inline-size: 3.5em;
  color: var(--c-muted);
  font-size: var(--fs-13);
  text-align: end;
}

/* Whole percents as classes (strict CSP: no style=): `pctClass()` picks one; bars and segments read --pct. */
.ui-pct-0 {
  --pct: 0%;
}
.ui-pct-1 {
  --pct: 1%;
}
.ui-pct-2 {
  --pct: 2%;
}
.ui-pct-3 {
  --pct: 3%;
}
.ui-pct-4 {
  --pct: 4%;
}
.ui-pct-5 {
  --pct: 5%;
}
.ui-pct-6 {
  --pct: 6%;
}
.ui-pct-7 {
  --pct: 7%;
}
.ui-pct-8 {
  --pct: 8%;
}
.ui-pct-9 {
  --pct: 9%;
}
.ui-pct-10 {
  --pct: 10%;
}
.ui-pct-11 {
  --pct: 11%;
}
.ui-pct-12 {
  --pct: 12%;
}
.ui-pct-13 {
  --pct: 13%;
}
.ui-pct-14 {
  --pct: 14%;
}
.ui-pct-15 {
  --pct: 15%;
}
.ui-pct-16 {
  --pct: 16%;
}
.ui-pct-17 {
  --pct: 17%;
}
.ui-pct-18 {
  --pct: 18%;
}
.ui-pct-19 {
  --pct: 19%;
}
.ui-pct-20 {
  --pct: 20%;
}
.ui-pct-21 {
  --pct: 21%;
}
.ui-pct-22 {
  --pct: 22%;
}
.ui-pct-23 {
  --pct: 23%;
}
.ui-pct-24 {
  --pct: 24%;
}
.ui-pct-25 {
  --pct: 25%;
}
.ui-pct-26 {
  --pct: 26%;
}
.ui-pct-27 {
  --pct: 27%;
}
.ui-pct-28 {
  --pct: 28%;
}
.ui-pct-29 {
  --pct: 29%;
}
.ui-pct-30 {
  --pct: 30%;
}
.ui-pct-31 {
  --pct: 31%;
}
.ui-pct-32 {
  --pct: 32%;
}
.ui-pct-33 {
  --pct: 33%;
}
.ui-pct-34 {
  --pct: 34%;
}
.ui-pct-35 {
  --pct: 35%;
}
.ui-pct-36 {
  --pct: 36%;
}
.ui-pct-37 {
  --pct: 37%;
}
.ui-pct-38 {
  --pct: 38%;
}
.ui-pct-39 {
  --pct: 39%;
}
.ui-pct-40 {
  --pct: 40%;
}
.ui-pct-41 {
  --pct: 41%;
}
.ui-pct-42 {
  --pct: 42%;
}
.ui-pct-43 {
  --pct: 43%;
}
.ui-pct-44 {
  --pct: 44%;
}
.ui-pct-45 {
  --pct: 45%;
}
.ui-pct-46 {
  --pct: 46%;
}
.ui-pct-47 {
  --pct: 47%;
}
.ui-pct-48 {
  --pct: 48%;
}
.ui-pct-49 {
  --pct: 49%;
}
.ui-pct-50 {
  --pct: 50%;
}
.ui-pct-51 {
  --pct: 51%;
}
.ui-pct-52 {
  --pct: 52%;
}
.ui-pct-53 {
  --pct: 53%;
}
.ui-pct-54 {
  --pct: 54%;
}
.ui-pct-55 {
  --pct: 55%;
}
.ui-pct-56 {
  --pct: 56%;
}
.ui-pct-57 {
  --pct: 57%;
}
.ui-pct-58 {
  --pct: 58%;
}
.ui-pct-59 {
  --pct: 59%;
}
.ui-pct-60 {
  --pct: 60%;
}
.ui-pct-61 {
  --pct: 61%;
}
.ui-pct-62 {
  --pct: 62%;
}
.ui-pct-63 {
  --pct: 63%;
}
.ui-pct-64 {
  --pct: 64%;
}
.ui-pct-65 {
  --pct: 65%;
}
.ui-pct-66 {
  --pct: 66%;
}
.ui-pct-67 {
  --pct: 67%;
}
.ui-pct-68 {
  --pct: 68%;
}
.ui-pct-69 {
  --pct: 69%;
}
.ui-pct-70 {
  --pct: 70%;
}
.ui-pct-71 {
  --pct: 71%;
}
.ui-pct-72 {
  --pct: 72%;
}
.ui-pct-73 {
  --pct: 73%;
}
.ui-pct-74 {
  --pct: 74%;
}
.ui-pct-75 {
  --pct: 75%;
}
.ui-pct-76 {
  --pct: 76%;
}
.ui-pct-77 {
  --pct: 77%;
}
.ui-pct-78 {
  --pct: 78%;
}
.ui-pct-79 {
  --pct: 79%;
}
.ui-pct-80 {
  --pct: 80%;
}
.ui-pct-81 {
  --pct: 81%;
}
.ui-pct-82 {
  --pct: 82%;
}
.ui-pct-83 {
  --pct: 83%;
}
.ui-pct-84 {
  --pct: 84%;
}
.ui-pct-85 {
  --pct: 85%;
}
.ui-pct-86 {
  --pct: 86%;
}
.ui-pct-87 {
  --pct: 87%;
}
.ui-pct-88 {
  --pct: 88%;
}
.ui-pct-89 {
  --pct: 89%;
}
.ui-pct-90 {
  --pct: 90%;
}
.ui-pct-91 {
  --pct: 91%;
}
.ui-pct-92 {
  --pct: 92%;
}
.ui-pct-93 {
  --pct: 93%;
}
.ui-pct-94 {
  --pct: 94%;
}
.ui-pct-95 {
  --pct: 95%;
}
.ui-pct-96 {
  --pct: 96%;
}
.ui-pct-97 {
  --pct: 97%;
}
.ui-pct-98 {
  --pct: 98%;
}
.ui-pct-99 {
  --pct: 99%;
}
.ui-pct-100 {
  --pct: 100%;
}

/* ── StatCard ────────────────────────────────────────────────────────────────────────────────────────────── */
.ui-statgrid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--s-4);
}
@media (max-width: 1023px) {
  .ui-statgrid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
.ui-statcard {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
  min-width: 0;
  padding: var(--pad-card);
  border: 1px solid var(--c-line);
  border-radius: var(--r-card);
  background: var(--c-surface);
  color: var(--c-ink);
  text-decoration: none;
}
.ui-statcard--link:hover {
  border-color: var(--n-7);
}
.ui-statcard__label {
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
  font-weight: var(--fw-medium);
}
.ui-statcard__value {
  font-size: var(--fs-28);
  line-height: var(--lh-28);
  font-weight: var(--fw-strong);
  letter-spacing: -0.02em;
}
.ui-statcard__delta {
  display: inline-flex;
  align-items: center;
  gap: var(--s-1);
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.ui-statcard__delta .ui-icon {
  width: var(--s-4);
  height: var(--s-4);
}
.ui-statcard__delta[data-tone='good'] {
  color: var(--c-ready-ink);
}
.ui-statcard__delta[data-tone='bad'] {
  color: var(--c-late);
}
.ui-statcard__hint {
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
}
.ui-spark {
  width: 100%;
  height: var(--s-6);
  margin-block-start: auto;
  padding-block-start: var(--s-2);
}
.ui-spark polyline {
  fill: none;
  stroke: var(--c-chart-bar);
  stroke-width: 1.5px;
  stroke-linecap: round;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
}

/* ── Person cell ─────────────────────────────────────────────────────────────────────────────────────────── */
.ui-person {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  min-width: 0;
}
.ui-person > .ui-avatar {
  flex: none;
}
.ui-person__text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.ui-person__name {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  min-width: 0;
  color: var(--c-ink);
  font-weight: var(--fw-medium);
}
.ui-person__name > bdi,
.ui-person__meta > bdi {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.ui-person__name > .ui-badge {
  flex: none;
}
.ui-person__meta {
  display: flex;
  min-width: 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
@media (min-width: 1024px) {
  .ui-person__meta--sm {
    display: none;
  }
}

}
/* components/nav.css */
@layer components {
/* Navigation (P08): Rail (workspace light / HQ graphite in both themes), PhoneBottomBar + More sheet, env ribbon,
   EntityHeader, SubNav, CommandPalette, Kbd and the palette trigger. */

/* ── Rail ────────────────────────────────────────────────────────────────────────────────────────────────── */
.ui-rail {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: var(--s-4);
  height: 100%;
  padding-block: var(--s-3);
  padding-inline: var(--s-2);
  overflow-y: auto;
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.ui-rail--workspace {
  background: var(--c-surface);
  color: var(--c-ink);
}
/* HQ: graphite in light AND dark (the strongest "where am I" signal, experience-v2 §6.1). */
.ui-rail--hq {
  background: var(--c-chrome-bg);
  color: var(--c-chrome-muted);
  color-scheme: dark;
}
.ui-rail__group {
  margin: 0;
  padding-block: var(--s-3) var(--s-1);
  padding-inline: var(--s-3);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  font-weight: var(--fw-medium);
  color: var(--c-muted);
}
.ui-rail--hq .ui-rail__group {
  color: var(--c-chrome-muted);
  opacity: 0.8;
}
.ui-rail__list {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
  margin: 0;
  padding: 0;
  list-style: none;
}
.ui-rail__item {
  position: relative;
  display: flex;
  align-items: center;
  gap: var(--s-3);
  min-height: var(--ctl-h);
  padding-inline: var(--s-3);
  border-radius: var(--r-control);
  color: inherit;
  font-weight: var(--fw-medium);
  text-decoration: none;
  transition: background-color var(--dur-1) var(--ease-standard);
}
.ui-rail__item > .ui-icon {
  color: var(--c-muted);
}
.ui-rail--hq .ui-rail__item > .ui-icon {
  color: var(--c-chrome-muted);
}
.ui-rail--workspace .ui-rail__item:hover {
  background: var(--n-3);
}
.ui-rail--hq .ui-rail__item:hover {
  background: var(--c-chrome-hover);
  color: var(--c-chrome-ink);
}
.ui-rail--workspace .ui-rail__item[aria-current='page'] {
  background: var(--n-4);
  color: var(--c-ink);
  font-weight: var(--fw-strong);
}
.ui-rail--workspace .ui-rail__item[aria-current='page'] > .ui-icon {
  color: var(--c-ink);
}
.ui-rail--hq .ui-rail__item[aria-current='page'] {
  background: var(--c-chrome-selected);
  color: var(--c-chrome-ink);
  font-weight: var(--fw-strong);
}
.ui-rail--hq .ui-rail__item[aria-current='page'] > .ui-icon {
  color: var(--c-chrome-ink);
}
/* The 2px marker at inline-start of the selected item. */
.ui-rail__item[aria-current='page']::before {
  content: '';
  position: absolute;
  inset-block: var(--s-2);
  inset-inline-start: 0;
  width: 2px;
  border-radius: var(--r-2);
  background: var(--c-ink);
}
.ui-rail--hq .ui-rail__item[aria-current='page']::before {
  background: var(--c-chrome-marker);
}
.ui-rail--hq .ui-rail__item:focus-visible {
  box-shadow: 0 0 0 2px var(--c-chrome-marker);
}
.ui-rail__label {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.ui-rail__count {
  min-width: var(--s-5);
  padding-inline: var(--s-1);
  border-radius: var(--r-pill);
  background: var(--n-4);
  color: var(--c-ink);
  font-size: var(--fs-12);
  line-height: var(--s-5);
  text-align: center;
}
.ui-rail--hq .ui-rail__count {
  background: var(--c-chrome-line);
  color: var(--c-chrome-ink);
}
.ui-rail__ext {
  width: var(--s-3);
  height: var(--s-3);
  opacity: 0.6;
}
.ui-rail__foot {
  padding-block-start: var(--s-3);
  border-block-start: 1px solid var(--c-line);
}
.ui-rail--hq .ui-rail__foot {
  border-color: var(--c-chrome-line);
}
/* Icon rail (md): labels stay for screen readers. */
@media (min-width: 600px) and (max-width: 1023px) {
  .ui-rail__item {
    justify-content: center;
    padding-inline: 0;
  }
  .ui-rail__label,
  .ui-rail__count,
  .ui-rail__ext,
  .ui-rail__group {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
  }
}

/* ── PhoneBottomBar ──────────────────────────────────────────────────────────────────────────────────────── */
.ui-bottombar {
  position: sticky;
  inset-block-end: 0;
  z-index: var(--z-appbar);
  border-block-start: 1px solid var(--c-line);
  background: var(--c-surface);
  padding-block-end: env(safe-area-inset-bottom);
}
.ui-bottombar__list {
  display: grid;
  grid-auto-columns: minmax(0, 1fr);
  grid-auto-flow: column;
  margin: 0;
  padding: 0;
  list-style: none;
}
.ui-bottombar__item {
  appearance: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--s-1);
  width: 100%;
  min-height: var(--h-bottombar);
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  color: var(--c-muted);
  font: inherit;
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  font-weight: var(--fw-medium);
  text-decoration: none;
  cursor: pointer;
}
.ui-bottombar__item[aria-current='page'],
.ui-bottombar__item--current {
  color: var(--c-ink);
}
.ui-bottombar__item[aria-current='page'] .ui-icon,
.ui-bottombar__item--current .ui-icon {
  color: var(--c-accent-ink);
}
@media (min-width: 600px) {
  .ui-bottombar {
    display: none;
  }
}
.ui-sheetnav {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
  list-style: none;
}
.ui-sheetnav__item {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  min-height: var(--hit-min);
  padding-inline: var(--s-2);
  border-radius: var(--r-control);
  color: var(--c-ink);
  font-weight: var(--fw-medium);
  text-decoration: none;
}
.ui-sheetnav__item > span {
  flex: 1;
}
.ui-sheetnav__item:hover,
.ui-sheetnav__item[aria-current='page'] {
  background: var(--n-3);
}

/* ── EntityHeader ────────────────────────────────────────────────────────────────────────────────────────── */
.ui-entity {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
}
.ui-entity__row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: var(--s-4);
}
.ui-entity__tile {
  display: grid;
  place-items: center;
  width: var(--w-tile-lg);
  height: var(--w-tile-lg);
  border-radius: var(--r-card);
  background: var(--n-3);
  color: var(--c-muted);
}
.ui-entity__titles {
  display: flex;
  flex: 1 1 var(--w-aside);
  flex-direction: column;
  gap: var(--s-1);
  min-width: 0;
}
.ui-entity__name {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2) var(--s-3);
}
.ui-entity__sub {
  color: var(--c-muted);
  font-size: var(--fs-13);
}
.ui-entity__sub a {
  color: inherit;
}
.ui-entity__badges {
  display: inline-flex;
  flex-wrap: wrap;
  gap: var(--s-1);
}
.ui-entity__meta {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.ui-entity__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
}
.ui-entity__warnings {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}

/* ── SubNav ──────────────────────────────────────────────────────────────────────────────────────────────── */
.ui-subnav {
  position: relative;
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.ui-subnav__trigger {
  display: none;
}
.ui-subnav__group {
  margin: 0;
  padding-block: var(--s-4) var(--s-1);
  padding-inline: var(--s-3);
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  font-weight: var(--fw-medium);
}
.ui-subnav__list {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
  margin: 0;
  padding: 0;
  list-style: none;
}
.ui-subnav__item {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  min-height: var(--ctl-h);
  padding-inline: var(--s-3);
  border-radius: var(--r-control);
  color: var(--c-ink);
  text-decoration: none;
}
.ui-subnav__item > span:first-of-type {
  flex: 1;
}
.ui-subnav__item:hover {
  background: var(--n-3);
}
.ui-subnav__item[aria-current='page'] {
  background: var(--n-4);
  font-weight: var(--fw-strong);
}
.ui-subnav__count {
  color: var(--c-muted);
  font-size: var(--fs-12);
}
/* md: Tabs under the header. */
@media (min-width: 600px) and (max-width: 1023px) {
  .ui-subnav__panel {
    display: flex;
    gap: var(--s-1);
    overflow-x: auto;
    border-block-end: 1px solid var(--c-line);
  }
  .ui-subnav__group {
    display: none;
  }
  .ui-subnav__list {
    flex-direction: row;
  }
  .ui-subnav__item {
    border-radius: 0;
    white-space: nowrap;
  }
  .ui-subnav__item[aria-current='page'] {
    background: none;
    box-shadow: inset 0 -2px 0 var(--c-ink);
  }
}
/* sm: one trigger naming the section; the list opens under it. */
@media (max-width: 599px) {
  .ui-subnav__trigger {
    display: flex;
    width: 100%;
  }
  .ui-subnav__panel {
    display: none;
    margin-block-start: var(--s-2);
    padding: var(--s-2);
    border: 1px solid var(--c-line);
    border-radius: var(--r-card);
    background: var(--c-surface);
    box-shadow: var(--e-2);
  }
  .ui-subnav[data-open] .ui-subnav__panel {
    display: block;
  }
}

/* ── CommandPalette, Kbd, trigger ───────────────────────────────────────────────────────────────────────── */
.ui-kbds {
  display: inline-flex;
  gap: 2px;
}
.ui-kbd {
  display: inline-grid;
  place-items: center;
  min-width: var(--s-5);
  height: var(--s-5);
  padding-inline: var(--s-1);
  border: 1px solid var(--n-6);
  border-block-end-width: 2px;
  border-radius: var(--r-2);
  background: var(--n-1);
  color: var(--c-muted);
  font-family: var(--f-ui);
  font-size: var(--fs-12);
  line-height: 1;
  font-weight: var(--fw-medium);
}
.ui-palette-trigger {
  appearance: none;
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  flex: 0 1 var(--w-palette);
  min-width: 0;
  height: var(--ctl-h);
  margin: 0;
  padding-inline: var(--s-3);
  border: 1px solid var(--n-6);
  border-radius: var(--r-control);
  background: var(--n-1);
  color: var(--c-muted);
  font: inherit;
  font-size: var(--fs-13);
  text-align: start;
  cursor: pointer;
}
.ui-palette-trigger:hover {
  border-color: var(--n-7);
  background: var(--c-surface);
}
.ui-palette-trigger__label {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
@media (max-width: 599px) {
  .ui-palette-trigger {
    flex: none;
    width: var(--ctl-h);
    padding: 0;
    justify-content: center;
  }
  .ui-palette-trigger__label,
  .ui-palette-trigger .ui-kbds {
    display: none;
  }
}
.ui-palette .ui-dialog__panel {
  align-self: start;
  width: min(var(--w-palette), calc(100vw - var(--s-8)));
  margin-block-start: 12vh;
  padding: 0;
  overflow: hidden;
}
.ui-palette__search {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding-inline: var(--s-4);
  border-block-end: 1px solid var(--c-line);
}
.ui-palette__search > .ui-icon {
  color: var(--c-muted);
}
.ui-palette__input {
  flex: 1;
  min-width: 0;
  height: var(--s-12);
  border: 0;
  background: none;
  color: var(--c-ink);
  font: inherit;
  font-size: var(--fs-16);
  outline: none;
}
/* The search row is the focus indicator (the input is the dialog's only field): no ring box inside the header. */
.ui-palette__input:focus-visible {
  box-shadow: none;
}
.ui-palette__search:focus-within {
  border-block-end-color: var(--c-focus);
  box-shadow: inset 0 -1px 0 var(--c-focus);
}
.ui-palette__list {
  max-height: var(--h-palette-list);
  overflow-y: auto;
  padding: var(--s-2);
}
.ui-palette__group + .ui-palette__group {
  margin-block-start: var(--s-2);
}
.ui-palette__group[hidden] {
  display: none;
}
.ui-palette__glabel {
  margin: 0;
  padding-block: var(--s-2) var(--s-1);
  padding-inline: var(--s-2);
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  font-weight: var(--fw-medium);
}
.ui-palette__item {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  min-height: var(--s-10);
  padding-inline: var(--s-2);
  border-radius: var(--r-control);
  color: var(--c-ink);
  cursor: pointer;
}
.ui-palette__item[hidden] {
  display: none;
}
.ui-palette__item > .ui-icon {
  color: var(--c-muted);
}
.ui-palette__item[aria-selected='true'] {
  background: var(--n-4);
}
.ui-palette__label {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.ui-palette__hint {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  color: var(--c-muted);
  font-size: var(--fs-13);
  text-overflow: ellipsis;
  white-space: nowrap;
}
.ui-palette__go {
  margin-inline-start: auto;
  opacity: 0;
}
.ui-palette__item[aria-selected='true'] .ui-palette__go {
  opacity: 1;
}
.ui-palette__empty {
  margin: 0;
  padding: var(--s-6);
  color: var(--c-muted);
  text-align: center;
}
.ui-palette__foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
  padding-block: var(--s-2);
  padding-inline: var(--s-4);
  border-block-start: 1px solid var(--c-line);
  background: var(--n-1);
  color: var(--c-muted);
  font-size: var(--fs-12);
}
.ui-palette__foot > span:not(.ui-kbds) {
  margin-inline-end: var(--s-2);
}

}
/* components/flow.css */
@layer components {
/* Flows (P08): Stepper, WizardFrame, SortableList, DatePicker, date filter, multi-select Combobox, ReasonDialog,
   the dialog note line. */

/* ── Stepper ─────────────────────────────────────────────────────────────────────────────────────────────── */
.ui-stepper {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}
.ui-stepper__count {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
  font-weight: var(--fw-medium);
}
.ui-stepper__list {
  display: flex;
  gap: var(--s-2);
  margin: 0;
  padding: 0;
  list-style: none;
}
.ui-stepper__step {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: var(--s-2);
  min-width: 0;
}
.ui-stepper__mark {
  position: relative;
  display: block;
  height: 4px;
  border-radius: var(--r-pill);
  background: var(--n-5);
}
.ui-stepper__mark .ui-icon {
  display: none;
}
.ui-stepper__step[data-state='done'] .ui-stepper__mark,
.ui-stepper__step[data-state='current'] .ui-stepper__mark {
  background: var(--c-accent-edge);
}
.ui-stepper__label {
  overflow: hidden;
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  text-overflow: ellipsis;
  white-space: nowrap;
}
.ui-stepper__step[data-state='current'] .ui-stepper__label {
  color: var(--c-ink);
  font-weight: var(--fw-medium);
}
@media (max-width: 599px) {
  .ui-stepper__label {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
  }
}

/* ── WizardFrame ─────────────────────────────────────────────────────────────────────────────────────────── */
.ui-wizard {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}
.ui-wizard__top {
  display: flex;
  flex-direction: column;
  gap: var(--s-5);
  margin-block-end: var(--s-2);
}
.ui-wizard__logo {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
}
.ui-wizard__title:focus {
  outline: none;
}
.ui-wizard__desc {
  margin: 0;
  margin-block-start: calc(var(--s-2) * -1);
  color: var(--c-muted);
}
.ui-wizard__body {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}
.ui-wizard__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
  padding-block-start: var(--s-2);
}
.ui-wizard__next {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
  margin-inline-start: auto;
}
/* An empty Back slot (first step, or only a hidden Back button) takes no room, so the gap doesn't narrow the primary. */
.ui-wizard__back:empty,
.ui-wizard__back:not(:has(> :not([hidden]))) {
  display: none;
}
.ui-wizard__actions--done {
  justify-content: flex-start;
}
.ui-wizard__done-mark {
  display: grid;
  place-items: center;
  width: var(--s-12);
  height: var(--s-12);
  border-radius: var(--r-pill);
  background: var(--c-ready-soft);
  color: var(--c-ready-ink);
}
.ui-wizard__done-mark .ui-icon {
  width: var(--s-6);
  height: var(--s-6);
}
@media (max-width: 599px) {
  .ui-wizard__actions {
    position: sticky;
    inset-block-end: 0;
    margin-inline: calc(var(--s-4) * -1);
    padding: var(--s-3) var(--s-4);
    border-block-start: 1px solid var(--c-line);
    background: var(--c-surface);
  }
  .ui-wizard__next {
    flex: 1;
    flex-direction: column-reverse;
    align-items: stretch;
  }
  .ui-wizard__next .ui-btn--primary {
    width: 100%;
  }
}

/* ── SortableList ────────────────────────────────────────────────────────────────────────────────────────── */
.ui-sortable {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
  list-style: none;
}
.ui-sortable__item {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  min-height: var(--row-h);
  padding-inline: var(--s-2);
  border-block-end: 1px solid var(--c-line);
  background: var(--c-surface);
}
.ui-sortable__item:last-child {
  border-block-end: 0;
}
.ui-sortable__item[data-grabbed] {
  position: relative;
  z-index: 1;
  border-radius: var(--r-control);
  box-shadow: var(--e-2);
}
.ui-sortable__item[data-dragging] {
  opacity: 0.6;
}
.ui-sortable__handle {
  appearance: none;
  display: grid;
  place-items: center;
  width: var(--ctl-sm);
  height: var(--ctl-sm);
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: var(--r-control);
  background: none;
  color: var(--c-muted);
  cursor: grab;
  touch-action: none;
}
.ui-sortable__handle:hover {
  background: var(--n-3);
  color: var(--c-ink);
}
.ui-sortable__item[data-grabbed] .ui-sortable__handle {
  background: var(--c-ink);
  color: var(--c-surface);
  cursor: grabbing;
}
.ui-sortable__body {
  flex: 1;
  min-width: 0;
}

/* ── DatePicker ──────────────────────────────────────────────────────────────────────────────────────────── */
.ui-date {
  position: relative;
}
.ui-date__trigger {
  gap: var(--s-2);
}
.ui-date__trigger > .ui-icon {
  color: var(--c-muted);
}
.ui-date__pop {
  width: var(--w-date);
  padding: var(--s-3);
}
.ui-date__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-2);
  margin-block-end: var(--s-2);
}
.ui-date__month {
  margin: 0;
  font-size: var(--fs-14);
  font-weight: var(--fw-strong);
}
.ui-date__grid {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}
.ui-date__grid th {
  height: var(--s-8);
  color: var(--c-muted);
  font-size: var(--fs-12);
  font-weight: var(--fw-medium);
}
.ui-date__grid td {
  padding: 1px;
  text-align: center;
}
.ui-date__day {
  appearance: none;
  display: grid;
  place-items: center;
  width: 100%;
  aspect-ratio: 1;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: var(--r-control);
  background: none;
  color: var(--c-ink);
  font: inherit;
  font-size: var(--fs-13);
  font-variant-numeric: tabular-nums;
  cursor: pointer;
}
.ui-date__day:hover {
  background: var(--n-3);
}
.ui-date__day[aria-disabled='true'] {
  color: var(--n-8);
  cursor: not-allowed;
}
.ui-date__day[data-outside] {
  color: var(--c-muted);
}
.ui-date__day[data-today] {
  box-shadow: inset 0 0 0 1px var(--n-7);
}
.ui-date__day[aria-selected='true'] {
  background: var(--c-accent);
  color: var(--c-on-accent);
  box-shadow: inset 0 0 0 1px var(--c-accent-fill-edge);
}
.ui-date__foot {
  display: flex;
  justify-content: space-between;
  margin-block-start: var(--s-2);
}
.ui-datefilter {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
}
.ui-datefilter__range {
  display: flex;
  gap: var(--s-2);
}

/* ── Multi-select Combobox ───────────────────────────────────────────────────────────────────────────────── */
.ui-multi {
  position: relative;
}
.ui-multi__box {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-1);
  min-height: var(--ctl-h);
  padding-block: var(--s-1);
  padding-inline: var(--s-2);
  border: 1px solid var(--n-7);
  border-radius: var(--r-control);
  background: var(--c-surface);
  cursor: text;
}
.ui-multi__box:focus-within {
  border-color: var(--c-ink);
  box-shadow: 0 0 0 1px var(--c-ink);
}
.ui-multi__box[data-invalid] {
  border-color: var(--c-danger);
}
.ui-multi__chips {
  display: contents;
}
.ui-multi__chip {
  display: inline-flex;
  align-items: center;
  gap: var(--s-1);
  max-width: 100%;
  min-height: var(--s-6);
  padding-inline: var(--s-2) var(--s-1);
  border-radius: var(--r-pill);
  background: var(--n-4);
  color: var(--c-ink);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.ui-multi__remove {
  appearance: none;
  display: grid;
  place-items: center;
  width: var(--s-5);
  height: var(--s-5);
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: var(--r-pill);
  background: none;
  color: var(--c-muted);
  cursor: pointer;
}
.ui-multi__remove:hover {
  background: var(--n-6);
  color: var(--c-ink);
}
.ui-multi__remove .ui-icon {
  width: var(--s-3);
  height: var(--s-3);
}
.ui-multi__input {
  flex: 1 0 var(--s-16);
  min-width: var(--s-16);
  height: var(--s-6);
  border: 0;
  background: none;
  color: var(--c-ink);
  font: inherit;
  font-size: var(--fs-input);
  outline: none;
}

/* ── ReasonDialog ────────────────────────────────────────────────────────────────────────────────────────── */
.ui-reason {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}
.ui-reason__row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: var(--s-4);
  align-items: start;
}
@media (max-width: 599px) {
  .ui-reason__row {
    grid-template-columns: minmax(0, 1fr);
  }
}
.ui-dialog__note {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
}

}
/* components/acting.css */
@layer components {
/* ActingBar (P08, R-64): one line, never taller than 48 px (--h-actbar 44), sticky under the HQ app bar, content
   width. Indigo only while Bellou acts; neutral while viewing or after a session ended. Never the client brand. */
.ui-actbar {
  position: sticky;
  inset-block-start: var(--h-appbar);
  z-index: var(--z-banner);
  display: flex;
  align-items: center;
  min-height: var(--h-actbar);
  max-height: var(--s-12);
  padding-inline: var(--gutter);
  border-block-end: 1px solid var(--c-line);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.ui-actbar--neutral {
  background: var(--c-surface-2);
  color: var(--c-ink);
}
.ui-actbar--acting {
  border-block-end-color: var(--c-acting-edge);
  background: var(--c-acting);
  color: var(--c-on-acting);
  color-scheme: dark;
}
.ui-actbar__full {
  display: flex;
  flex: 1;
  align-items: center;
  gap: var(--s-2);
  min-width: 0;
}
.ui-actbar__full > .ui-icon,
.ui-actbar__open > .ui-icon:not(.ui-chev) {
  flex: none;
  opacity: 0.9;
}
.ui-actbar .ui-logo {
  width: var(--s-6);
  height: var(--s-6);
  border-radius: var(--r-2);
  font-size: var(--fs-12);
}
.ui-actbar__line {
  flex: 1;
  min-width: 0;
  margin: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: var(--fw-medium);
}
.ui-actbar__actions {
  display: flex;
  flex: none;
  align-items: center;
  gap: var(--s-1);
}
.ui-actbar__btn {
  min-height: var(--ctl-sm);
  font-size: var(--fs-13);
}
.ui-actbar--acting .ui-actbar__btn {
  border-color: transparent;
  background: transparent;
  color: var(--c-on-acting);
}
.ui-actbar--acting .ui-actbar__btn:hover {
  background: var(--c-acting-edge);
}
.ui-actbar--acting .ui-actbar__btn--main {
  border-color: var(--c-on-acting);
}
.ui-actbar--acting .ui-btn:focus-visible,
.ui-actbar--acting .ui-actbar__open:focus-visible {
  box-shadow: 0 0 0 2px var(--c-on-acting);
}
.ui-actbar__fc {
  display: none;
}
.ui-actbar__compact {
  display: none;
  flex: 1;
  align-items: center;
  gap: var(--s-2);
  min-width: 0;
}
.ui-actbar__open {
  appearance: none;
  display: flex;
  flex: 1;
  align-items: center;
  gap: var(--s-2);
  min-width: 0;
  min-height: var(--h-actbar);
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  text-align: start;
  cursor: pointer;
}
.ui-actbar__sheet-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
  margin-block-start: var(--s-4);
}
@media (max-width: 1023px) {
  .ui-actbar__full {
    display: none;
  }
  .ui-actbar__compact {
    display: flex;
  }
}
/* Forced colours: the indigo fill is gone, so the bar says it in words and keeps a border. */
@media (forced-colors: active) {
  .ui-actbar {
    border: 2px solid CanvasText;
  }
  .ui-actbar__fc {
    display: inline;
    padding-inline: var(--s-1);
    border: 1px solid CanvasText;
    font-weight: var(--fw-strong);
  }
}

/* SuspendedBanner (standalone; on HQ it merges into the ActingBar line). */
.ui-banner--suspended {
  background: var(--c-late-soft);
  color: var(--c-ink);
}
.ui-banner--suspended > .ui-icon {
  color: var(--c-late);
}

}
/* components/media.css */
@layer components {
/* QrCard, Dropzone, CropDialog, StateBlock/StatePage, the preview frame (P08). */

/* ── QrCard ──────────────────────────────────────────────────────────────────────────────────────────────── */
.ui-qrcard {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-4);
  padding: var(--pad-card);
  border: 1px solid var(--c-line);
  border-radius: var(--r-card);
  background: var(--c-surface);
}
/* Always ink on white with a quiet zone, in both themes: scan reliability first. */
.ui-qrcard__code {
  flex: none;
  width: var(--w-qr);
  padding: var(--s-3);
  border-radius: var(--r-control);
  background: #fff;
  color: #000;
}
.ui-qrcard__code svg {
  display: block;
  width: 100%;
  height: auto;
}
.ui-qrcard--lg .ui-qrcard__code {
  width: calc(var(--w-qr) * 1.5);
}
.ui-qrcard__text {
  display: flex;
  flex: 1 1 var(--w-date);
  flex-direction: column;
  gap: var(--s-1);
  min-width: 0;
}
.ui-qrcard__title {
  margin: 0;
  font-weight: var(--fw-strong);
}
.ui-qrcard__desc {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
}
.ui-qrcard__url {
  margin: 0;
  overflow-wrap: anywhere;
  color: var(--c-muted);
  font-family: var(--f-mono);
  font-size: var(--fs-12);
}
.ui-qrcard__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
  margin-block-start: var(--s-2);
}

/* ── Dropzone ────────────────────────────────────────────────────────────────────────────────────────────── */
.ui-drop {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: var(--w-drop);
  padding: var(--s-4);
  border: 1px dashed var(--n-8);
  border-radius: var(--r-card);
  background: var(--n-1);
  transition:
    background-color var(--dur-1) var(--ease-standard),
    border-color var(--dur-1) var(--ease-standard);
}
.ui-drop[data-state='over'] {
  border-style: solid;
  border-color: var(--c-ink);
  background: var(--n-3);
}
.ui-drop[data-state='done'] {
  border-style: solid;
  border-color: var(--c-line);
  background: var(--c-surface);
}
.ui-drop:has(.ui-drop__error) {
  border-color: var(--c-danger);
}
.ui-drop__empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-2);
  text-align: center;
}
.ui-drop__empty > .ui-icon {
  color: var(--c-muted);
}
.ui-drop__lead {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: var(--s-2);
  margin: 0;
}
.ui-drop__hint {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-12);
}
.ui-drop__progress {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}
.ui-drop__file {
  margin: 0;
  min-width: 0;
  overflow: hidden;
  font-size: var(--fs-13);
  text-overflow: ellipsis;
  white-space: nowrap;
}
.ui-drop__done {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-3);
}
.ui-drop__preview {
  display: grid;
  place-items: center;
  width: var(--w-tile-lg);
  height: var(--w-tile-lg);
  overflow: hidden;
  border: 1px solid var(--c-line);
  border-radius: var(--r-control);
  background: var(--c-surface);
}
.ui-drop__preview img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}
.ui-drop__done .ui-drop__file {
  flex: 1;
}
.ui-drop__actions {
  display: flex;
  gap: var(--s-1);
}
.ui-drop__error {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  margin: 0;
  margin-block-start: var(--s-2);
  color: var(--c-danger);
  font-size: var(--fs-13);
}
.ui-drop--wide {
  min-height: var(--w-qr);
}

/* ── CropDialog (Fit / Fill only, R-68) ─────────────────────────────────────────────────────────────────── */
.ui-crop {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-4);
}
.ui-crop__frame {
  width: calc(var(--w-qr) * 1.5);
  aspect-ratio: 1;
  overflow: hidden;
  border: 1px solid var(--c-line);
  border-radius: var(--r-card);
  background-color: var(--n-3);
  background-image:
    linear-gradient(45deg, var(--n-4) 25%, transparent 25%, transparent 75%, var(--n-4) 75%),
    linear-gradient(45deg, var(--n-4) 25%, transparent 25%, transparent 75%, var(--n-4) 75%);
  background-position:
    0 0,
    var(--s-2) var(--s-2);
  background-size: var(--s-4) var(--s-4);
}
.ui-crop__img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.ui-crop[data-mode='fill'] .ui-crop__img {
  object-fit: cover;
}

/* ── StateBlock / StatePage (§15) ───────────────────────────────────────────────────────────────────────── */
.ui-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-2);
  max-width: var(--w-frame);
  margin-inline: auto;
  padding-block: var(--s-8);
  padding-inline: var(--s-4);
  text-align: center;
}
.ui-state--page {
  padding-block: var(--s-16);
}
.ui-state__icon {
  display: grid;
  place-items: center;
  width: var(--s-12);
  height: var(--s-12);
  margin-block-end: var(--s-1);
  border-radius: var(--r-pill);
  background: var(--n-3);
  color: var(--c-muted);
}
.ui-state__icon .ui-icon {
  width: var(--s-6);
  height: var(--s-6);
}
.ui-state[data-state='error'] .ui-state__icon {
  background: var(--c-danger-soft);
  color: var(--c-danger);
}
.ui-state[data-state='done'] .ui-state__icon {
  background: var(--c-ready-soft);
  color: var(--c-ready-ink);
}
.ui-state__title {
  margin: 0;
  color: var(--c-ink);
  font-size: var(--fs-16);
  line-height: var(--lh-16);
  font-weight: var(--fw-strong);
}
.ui-state--page .ui-state__title {
  font-size: var(--fs-20);
  line-height: var(--lh-20);
}
.ui-state__text {
  margin: 0;
  max-width: var(--w-form);
  color: var(--c-muted);
}
.ui-state__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--s-2);
  margin-block-start: var(--s-2);
}

/* ── Preview frame (the only client-themed area in staff UI) ────────────────────────────────────────────── */
.ui-preview {
  overflow: hidden;
  border: 1px solid var(--c-line);
  border-radius: var(--r-card);
  background: var(--c-bg);
  color: var(--c-ink);
}
.ui-preview--phone {
  width: var(--w-phone);
  max-width: 100%;
  margin-inline: auto;
  border-radius: var(--r-dialog);
}
.ui-preview--screen {
  aspect-ratio: 16 / 9;
}
.ui-preview--sheet {
  aspect-ratio: 210 / 297;
}

}
/* templates.css */
@layer components {
/* Page templates (P08, experience-v2 §13.0): ListPage, DetailPage, SettingsPage, SplitEditor, FocusWizard, and
   the one PageHeader. Layout only: columns, max widths, the template gutters (--gap-section) and the responsive
   switches. Content is left-aligned to the rail, never centred (except FocusWizard). */

.ui-tpl {
  display: flex;
  flex-direction: column;
  gap: var(--s-6);
  width: 100%;
  min-width: 0;
}

/* ── PageHeader ──────────────────────────────────────────────────────────────────────────────────────────── */
.ui-pagehead {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}
/* Inside a template the template's gap spaces the header; the v1 header padding applies to legacy pages only. */
.ui-tpl > .ui-pagehead {
  padding-block: 0;
}
.ui-pagehead__row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--s-3) var(--s-6);
}
.ui-pagehead__titles {
  display: flex;
  flex: 1 1 var(--w-aside);
  flex-direction: column;
  gap: var(--s-1);
  min-width: 0;
}
.ui-pagehead__title {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2) var(--s-3);
}
.ui-pagehead__title .ui-h1:focus {
  outline: none;
}
.ui-pagehead__badges {
  display: inline-flex;
  flex-wrap: wrap;
  gap: var(--s-1);
}
.ui-pagehead__meta,
.ui-pagehead__desc {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
[data-density='compact'] .ui-pagehead__meta,
[data-density='compact'] .ui-pagehead__desc {
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.ui-pagehead__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
}
@media (max-width: 599px) {
  .ui-pagehead__actions {
    width: 100%;
  }
  .ui-pagehead__actions > .ui-btn--primary {
    flex: 1 1 auto;
    order: 2;
  }
  .ui-pagehead__actions > .ui-menu {
    order: 3;
  }
}

/* ── ListPage ────────────────────────────────────────────────────────────────────────────────────────────── */
.ui-tpl--list {
  max-width: var(--w-list);
  gap: var(--s-4);
}
.ui-tpl--list > .ui-pagehead {
  margin-block-end: var(--s-2);
}
.ui-tpl__list {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  min-width: 0;
}
.ui-tpl__state {
  padding: 0;
}

/* ── DetailPage ──────────────────────────────────────────────────────────────────────────────────────────── */
.ui-tpl--detail {
  max-width: var(--w-list);
}
.ui-tpl__cols {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--s-6);
  align-items: start;
}
.ui-tpl__main {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  min-width: 0;
  max-width: var(--w-main);
}
.ui-tpl--wide .ui-tpl__main {
  max-width: none;
}
.ui-tpl__aside {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  min-width: 0;
}
@media (min-width: 1024px) {
  .ui-tpl--subnav .ui-tpl__cols {
    grid-template-columns: var(--w-subnav) minmax(0, 1fr);
  }
  .ui-tpl__subnav {
    position: sticky;
    inset-block-start: calc(var(--h-appbar) + var(--s-4));
  }
}
/* Without an aside the page is only as wide as its content column, so the header (and its ⋯ menu) ends where
   the content ends instead of at the full main width. */
.ui-tpl--detail:not(.ui-tpl--wide):not(.ui-tpl--aside) {
  max-width: var(--w-main);
}
@media (min-width: 1024px) {
  .ui-tpl--detail.ui-tpl--subnav:not(.ui-tpl--wide):not(.ui-tpl--aside) {
    max-width: calc(var(--w-subnav) + var(--s-6) + var(--w-main));
  }
}
@media (min-width: 1440px) {
  .ui-tpl--aside .ui-tpl__cols {
    grid-template-columns: minmax(0, 1fr) var(--w-aside);
  }
  .ui-tpl--subnav.ui-tpl--aside .ui-tpl__cols {
    grid-template-columns: var(--w-subnav) minmax(0, 1fr) var(--w-aside);
  }
}

/* ── SettingsPage ────────────────────────────────────────────────────────────────────────────────────────── */
.ui-tpl--settings {
  max-width: var(--w-main);
  gap: var(--s-4);
}
.ui-tpl__form {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}
.ui-tpl__section {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}
.ui-tpl__section-head {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
}
.ui-tpl__section-desc {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}

/* ── SplitEditor ─────────────────────────────────────────────────────────────────────────────────────────── */
.ui-tpl--split {
  max-width: var(--w-list);
}
.ui-tpl__panes {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--s-6);
  align-items: start;
}
.ui-tpl__form-pane {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  min-width: 0;
}
.ui-tpl__preview-pane {
  min-width: 0;
}
.ui-tpl__panes-switch {
  display: none;
}
@media (min-width: 1024px) {
  /* The preview keeps at least a phone's width (320): the form gives up room first. */
  .ui-tpl__panes {
    grid-template-columns: minmax(var(--w-split-min), var(--w-split-form)) minmax(20rem, 1fr);
  }
  .ui-tpl--split-narrow > .ui-tpl__panes {
    grid-template-columns: var(--w-split-min) minmax(0, 1fr);
  }
  .ui-tpl__preview-pane {
    position: sticky;
    inset-block-start: calc(var(--h-appbar) + var(--s-4));
  }
}
@media (max-width: 1023px) {
  .ui-tpl__panes-switch {
    display: block;
  }
  .ui-tpl--split[data-pane='form'] .ui-tpl__preview-pane,
  .ui-tpl--split[data-pane='preview'] .ui-tpl__form-pane {
    display: none;
  }
}
/* In the HQ console a client's section sits beside two navigation columns, so below 1280 the form and the preview
   don't both fit: they switch, as on a tablet. */
@media (min-width: 1024px) and (max-width: 1279px) {
  [data-view='staff'] .ui-tpl__panes,
  [data-view='staff'] .ui-tpl--split-narrow > .ui-tpl__panes {
    grid-template-columns: minmax(0, 1fr);
  }
  [data-view='staff'] .ui-tpl__panes-switch {
    display: block;
  }
  [data-view='staff'] .ui-tpl__preview-pane {
    position: static;
  }
  [data-view='staff'] .ui-tpl--split[data-pane='form'] .ui-tpl__preview-pane,
  [data-view='staff'] .ui-tpl--split[data-pane='preview'] .ui-tpl__form-pane {
    display: none;
  }
}

/* ── FocusWizard ─────────────────────────────────────────────────────────────────────────────────────────── */
.ui-tpl--focus {
  align-items: center;
  justify-content: center;
  min-height: calc(100dvh - var(--h-appbar));
  padding-block: var(--s-10);
}
.ui-tpl--focus.ui-tpl--inline {
  align-items: flex-start;
  justify-content: flex-start;
  min-height: 0;
  padding-block: 0;
}
.ui-tpl__focus {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  width: 100%;
  max-width: var(--w-frame);
}
.ui-tpl__top {
  display: flex;
  justify-content: flex-end;
}
.ui-tpl__frame {
  padding: var(--s-8);
  border: 1px solid var(--c-line);
  border-radius: var(--r-dialog);
  background: var(--c-surface);
  box-shadow: var(--e-1);
}
.ui-tpl__foot {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-1);
  color: var(--c-muted);
  font-size: var(--fs-12);
}
.ui-tpl--panel {
  flex-direction: row;
  align-items: stretch;
  padding: 0;
}
.ui-tpl__panel {
  display: none;
}
@media (min-width: 1024px) {
  .ui-tpl--panel .ui-tpl__panel {
    display: flex;
    flex: 1;
    flex-direction: column;
    justify-content: center;
    padding: var(--s-16);
    background: var(--brand);
    color: var(--on-brand);
    box-shadow: inset 0 0 0 1px var(--brand-edge);
  }
  .ui-tpl--panel .ui-tpl__focus {
    flex: 1;
    align-self: center;
    margin-inline: auto;
    padding: var(--s-10);
  }
}
@media (max-width: 599px) {
  .ui-tpl--focus {
    justify-content: flex-start;
    padding-block: 0;
  }
  .ui-tpl__frame {
    padding: var(--s-4);
    border: 0;
    border-radius: 0;
    box-shadow: none;
  }
}

}
/* surfaces/shared.css */
@layer surfaces {
/* Surface: c- j- (shared + customer waiting page). Moved verbatim from counter.css; owned by that surface.
   Layout-only once migrated (design-system.md §1.1): colour, borders, padding and type come from ui-* components. */
/* Direction C, "Counter". Values come from tokensCss() (tokens.ts); this file only reads var(--…). */
/* `hidden` must win over any `display` a class sets (e.g. a flex section filtered out by search). */
[hidden] {
  display: none !important;
}
*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  -webkit-text-size-adjust: 100%;
}
body {
  margin: 0;
  background: var(--c-bg);
  color: var(--c-ink);
  font-family: var(--f-sans);
  font-variant-numeric: tabular-nums;
  line-height: 1.4;
}
:lang(ar) {
  letter-spacing: 0;
}
html[data-big] {
  font-size: 118%;
}
.c-mono {
  font-family: var(--f-mono);
}
.c-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.c-root {
  min-height: 100vh;
  min-height: 100dvh;
  max-width: 480px;
  margin-inline: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.c-top {
  display: flex;
  align-items: center;
  gap: 10px;
}
.c-logo {
  width: 40px;
  height: 40px;
  border-radius: var(--r-sm);
  background: var(--brand);
  color: var(--on-brand);
  box-shadow: inset 0 0 0 1px var(--brand-edge);
  display: grid;
  place-items: center;
  font-weight: var(--fw-strong);
  font-size: 18px;
  flex: none;
  overflow: hidden;
}
.c-logo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.c-place {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.c-place b {
  font-size: 1rem;
  font-weight: var(--fw-strong);
}
.c-place span {
  font-size: 0.8125rem;
  color: var(--c-muted);
}
.c-tools {
  margin-inline-start: auto;
  display: flex;
  gap: 8px;
}
.c-tool {
  appearance: none;
  min-height: var(--t-min);
  min-width: var(--t-min);
  padding: 0 12px;
  border-radius: var(--r-sm);
  border: 1.5px solid var(--c-line);
  background: var(--c-paper);
  color: var(--c-ink);
  font: 600 15px/1 var(--f-sans);
  cursor: pointer;
  text-decoration: none;
  display: inline-grid;
  place-items: center;
}

.c-ticket {
  background: var(--c-paper);
  border-radius: var(--r-lg) var(--r-lg) 0 0;
  padding: 20px 20px 28px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  position: relative;
  box-shadow:
    0 1px 0 var(--c-line),
    0 10px 30px rgba(22, 21, 19, 0.06);
  -webkit-mask:
    linear-gradient(#000 0 0) top / 100% calc(100% - 10px) no-repeat,
    radial-gradient(10px 10px at 50% 100%, transparent 98%, #000) bottom / 20px 10px repeat-x;
  mask:
    linear-gradient(#000 0 0) top / 100% calc(100% - 10px) no-repeat,
    radial-gradient(10px 10px at 50% 100%, transparent 98%, #000) bottom / 20px 10px repeat-x;
}
.c-ticket .stripe {
  position: absolute;
  inset: 0 0 auto 0;
  height: 8px;
  background: var(--c-accent);
  border-radius: var(--r-lg) var(--r-lg) 0 0;
}
.c-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--c-muted);
}
.c-num {
  font-weight: var(--fw-strong);
  font-size: 128px;
  line-height: 0.85;
  letter-spacing: -0.03em;
  direction: ltr;
  unicode-bidi: isolate;
}
.c-num.sm {
  font-size: 84px;
}
.c-dash {
  border-top: 2px dashed var(--c-line);
}
.c-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
}
.c-col {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.c-facts {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 12px;
}
.c-fact b {
  display: block;
  font-size: 1.625rem;
  font-weight: var(--fw-strong);
  line-height: 1.1;
}
.c-fact span {
  font-size: 0.8125rem;
  color: var(--c-muted);
}
.c-end {
  text-align: end;
}

.c-steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.c-steps li {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--c-muted);
}
.c-steps i {
  height: 8px;
  border-radius: var(--r-pill);
  background: var(--c-line);
  display: block;
}
.c-steps li.done i {
  background: var(--c-ink);
}
.c-steps li.done {
  color: var(--c-ink);
}
.c-steps li.now i {
  background: var(--c-saffron);
}
.c-steps li.now {
  color: var(--c-ink);
  font-weight: var(--fw-strong);
}
@media (prefers-reduced-motion: no-preference) {
  .c-steps li.now i {
    background: linear-gradient(
        90deg,
        var(--c-saffron) 0 40%,
        var(--c-saffron-soft) 50%,
        var(--c-saffron) 60%
      )
      0 0 / 250% 100%;
    animation: c-move 1.8s linear infinite;
  }
}
@keyframes c-move {
  to {
    background-position: -250% 0;
  }
}

.c-h {
  margin: 0;
  font-size: 1.25rem;
  font-weight: var(--fw-strong);
  line-height: 1.3;
}
.c-p {
  margin: 0;
  font-size: 0.9375rem;
  line-height: 1.5;
  color: var(--c-muted);
}
.c-push {
  margin-top: auto;
}

.c-btn {
  appearance: none;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  min-height: var(--t-main);
  border-radius: var(--r-md);
  border: 0;
  font: 600 18px/1.2 var(--f-ui);
  cursor: pointer;
  padding: 0 18px;
  text-decoration: none;
  text-align: center;
  color: var(--c-ink);
}
.c-btn.main {
  background: var(--c-saffron);
}
.c-btn.wa {
  background: var(--c-wa-bg);
  color: var(--c-ok-ink);
  border: 1.5px solid var(--c-wa-line);
}
.c-btn.wa.solid {
  background: var(--c-wa-solid);
  color: #fff;
  border: 0;
}
.c-btn.quiet {
  background: transparent;
  min-height: 48px;
  font-weight: 500;
  font-size: 16px;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.c-btn.white {
  background: #fff;
  color: var(--c-ready);
}
.c-btn:disabled {
  opacity: 0.55;
  cursor: default;
}
/* ui-* controls draw their own ring (base.css); this outline is for legacy markup only. */
:focus-visible:not([class^='ui-'], [class*=' ui-']) {
  outline: 3px solid var(--c-focus);
  outline-offset: 3px;
}
.c-note {
  font-size: 0.8125rem;
  color: var(--c-muted);
  text-align: center;
}

.c-pickup {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--c-paper);
  border-radius: var(--r-md);
  padding: 12px 14px;
  font-size: 1rem;
  box-shadow: 0 1px 0 var(--c-line);
}
.c-pickup b {
  font-weight: var(--fw-strong);
}
.c-on {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--c-ok-bg);
  color: var(--c-ok-ink);
  border-radius: 14px;
  padding: 12px 14px;
  font-size: 0.9375rem;
  font-weight: 600;
}
.c-warn {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--c-late-bg);
  color: var(--c-late-ink);
  border-radius: 14px;
  padding: 12px 14px;
  font-size: 0.9375rem;
  font-weight: 600;
}

.c-lines {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.875rem;
}
.c-lines div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.c-tiles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(96px, 1fr));
  gap: 10px;
}
.c-tile {
  appearance: none;
  background: var(--c-paper);
  border: 1.5px solid var(--c-line);
  border-radius: var(--r-md);
  min-height: 92px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font: 600 14px/1.2 var(--f-sans);
  color: var(--c-ink);
  cursor: pointer;
  padding: 8px;
  text-decoration: none;
}
.c-tile.on,
.c-tile[aria-pressed='true'] {
  border-color: var(--c-ink);
  border-width: 2px;
}
.c-offer {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--c-offer-bg);
  border-radius: var(--r-md);
  padding: 14px;
}
.c-offer img {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  object-fit: cover;
  flex: none;
}
.c-offer b {
  font-size: 1rem;
}
.c-offer span {
  font-size: 0.875rem;
  color: var(--c-muted);
}
.c-price {
  margin-inline-start: auto;
  font-weight: var(--fw-strong);
  font-size: 1rem;
  white-space: nowrap;
}

.c-bead {
  appearance: none;
  width: 168px;
  height: 168px;
  border-radius: 50%;
  border: 0;
  cursor: pointer;
  background: var(--c-ink);
  color: #fff;
  display: grid;
  place-items: center;
  box-shadow:
    0 0 0 8px var(--c-paper),
    0 0 0 10px var(--c-line);
  transition: transform 100ms;
}
.c-bead:active {
  transform: scale(0.96);
}
.c-bead span {
  font-size: 60px;
  font-weight: var(--fw-strong);
}

.c-msg {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}
.c-msg .c-logo {
  width: 36px;
  height: 36px;
  font-size: 15px;
  border-radius: 50%;
}
.c-bubble {
  background: var(--c-paper);
  border-start-start-radius: 4px;
  border-start-end-radius: 18px;
  border-end-start-radius: 18px;
  border-end-end-radius: 18px;
  padding: 14px 16px;
  font-size: 1.0625rem;
  line-height: 1.45;
  box-shadow: 0 1px 0 var(--c-line);
}
.c-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--c-late-bg);
  color: var(--c-late-ink);
  border-radius: var(--r-pill);
  padding: 6px 12px;
  font-size: 0.875rem;
  font-weight: var(--fw-strong);
}
.c-flip {
  transform: scaleX(var(--c-dir, 1));
}
[dir='rtl'] {
  --c-dir: -1;
}

/* READY: one full-screen green, the same for every client. No flashing. */
.c-ready {
  background: var(--c-ready);
  color: #fff;
}
.c-ready .c-root {
  padding: 24px 16px 20px;
  gap: 20px;
}
.c-ready .c-ticket {
  color: var(--c-ink);
  align-items: center;
  text-align: center;
  padding: 28px 20px 34px;
}
.c-ready .c-num {
  font-size: 160px;
}
.c-ready h1 {
  margin: 8px 0 0;
  font-size: 64px;
  font-weight: var(--fw-strong);
  line-height: 1;
  letter-spacing: -0.02em;
}
.c-ready .c-go {
  display: flex;
  align-items: center;
  gap: 14px;
  background: rgba(255, 255, 255, 0.14);
  border-radius: 18px;
  padding: 16px 18px;
}
.c-ready .c-go b {
  font-size: 1.625rem;
  font-weight: var(--fw-strong);
  display: block;
}
.c-done-mark {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--c-ok-bg);
  color: var(--c-ready);
  display: grid;
  place-items: center;
}

/* Small layout helpers, so pages need no inline styles (strict CSP). */
.c-g2 {
  gap: 2px;
}
.c-g10 {
  gap: 10px;
}
.c-g12 {
  gap: 12px;
}
.c-h17 {
  font-size: 1.0625rem;
}
.c-h18 {
  font-size: 1.125rem;
}
.c-endx {
  align-items: flex-end;
  gap: 8px;
}
.c-self {
  align-self: flex-start;
}
.c-gap-top {
  margin-top: 24px;
}
.c-brandline {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1rem;
  font-weight: 600;
}
.c-hero {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 24px 4px 8px;
}
.c-big {
  margin: 8px 0 0;
  font-size: 2.5rem;
  font-weight: var(--fw-strong);
  line-height: 1.05;
}

}
/* surfaces/cashier.css */
@layer surfaces {
/* Surface: k- (cashier tablet). Moved verbatim from counter.css; owned by that surface.
   Layout-only once migrated (design-system.md §1.1): colour, borders, padding and type come from ui-* components. */
/* ── Cashier tablet (M-08). Landscape tablet first; stacks on a phone. ───────────────── */
.k-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 16px;
  padding: 12px 20px;
  background: var(--c-paper);
  box-shadow: 0 1px 0 var(--c-line);
  position: sticky;
  top: 0;
  z-index: 2;
}
.k-biz {
  font-size: 1.125rem;
  font-weight: 800;
}
.k-muted {
  color: var(--c-muted);
}
.k-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--c-muted);
}
.k-field select,
.k-field input {
  min-height: var(--t-min);
  border-radius: var(--r-sm);
  border: 1.5px solid var(--c-line);
  background: var(--c-paper);
  color: var(--c-ink);
  font: 500 16px/1.2 var(--f-sans);
  padding: 0 12px;
}
.k-root {
  display: grid;
  grid-template-columns: minmax(260px, 320px) minmax(0, 1fr) minmax(0, 1fr);
  gap: 20px;
  padding: 20px;
  align-items: start;
}
@media (max-width: 900px) {
  .k-root {
    grid-template-columns: minmax(0, 1fr);
  }
}
.k-wide {
  margin: 12px 20px 0;
}
.k-side {
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: sticky;
  top: 88px;
}
.k-new {
  min-height: 120px;
  font-size: 1.5rem;
  border-radius: var(--r-lg);
}
.k-col {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
}
.k-title {
  margin: 0;
  font-size: 1.125rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 8px;
}
.k-count {
  min-width: 28px;
  height: 28px;
  border-radius: var(--r-pill);
  background: var(--c-ink);
  color: #fff;
  display: inline-grid;
  place-items: center;
  font-size: 0.875rem;
  padding: 0 8px;
}
.k-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.k-empty {
  margin: 0;
  padding: 24px;
  border: 2px dashed var(--c-line);
  border-radius: var(--r-lg);
  color: var(--c-muted);
  text-align: center;
}
.k-card {
  background: var(--c-paper);
  border-radius: var(--r-lg);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  box-shadow: 0 1px 0 var(--c-line);
  border-inline-start: 0;
}
.k-card.k-is-ready {
  box-shadow: 0 0 0 2px var(--c-ready);
}
.k-card.k-late {
  box-shadow: 0 0 0 3px var(--c-late-ink);
  background: var(--c-late-bg);
}
.k-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.k-num {
  font-size: 56px;
  font-weight: 800;
  line-height: 0.9;
  letter-spacing: -0.02em;
  direction: ltr;
  unicode-bidi: isolate;
}
.k-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
  font-size: 0.875rem;
  color: var(--c-muted);
  text-align: end;
}
.k-meta b {
  color: var(--c-ink);
}
.k-items {
  font-family: var(--f-mono);
  font-size: 0.875rem;
  color: var(--c-muted);
}
.k-actions {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
  gap: 10px;
}
.k-actions > :only-child {
  grid-column: 1 / -1;
}
.k-second {
  background: var(--c-paper);
  border: 1.5px solid var(--c-line);
  font-size: 16px;
}
.k-go {
  background: var(--c-ready);
  color: #fff;
}
.k-link {
  appearance: none;
  background: none;
  border: 0;
  padding: 8px 0;
  min-height: var(--t-min);
  color: var(--c-muted);
  font: 500 14px/1 var(--f-sans);
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
  align-self: flex-start;
}
.k-compose {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.k-qr {
  align-items: center;
  text-align: center;
}
.k-qr-code {
  width: 100%;
  max-width: 240px;
  aspect-ratio: 1;
  background: #fff;
  padding: 8px;
  border-radius: var(--r-md);
}
.k-qr-code svg {
  width: 100%;
  height: 100%;
  display: block;
}
.k-toast {
  position: fixed;
  inset-block-end: 20px;
  inset-inline: 20px;
  max-width: 640px;
  margin-inline: auto;
  display: flex;
  align-items: center;
  gap: 16px;
  background: var(--c-ink);
  color: #fff;
  border-radius: var(--r-md);
  padding-block: 12px;
  padding-inline: 20px 12px;
  font-weight: 600;
  z-index: 5;
}
.k-toast .c-btn {
  width: auto;
  min-height: 52px;
  margin-inline-start: auto;
  color: var(--c-ink);
}
.k-toast-error {
  background: var(--c-late-ink);
}
.k-overlay {
  position: fixed;
  inset: 0;
  background: rgba(22, 21, 19, 0.45);
  display: grid;
  place-items: center;
  padding: 20px;
  z-index: 10;
}
.k-dialog {
  width: min(440px, 100%);
}
.c-staff {
  background: var(--c-bg);
}
.c-signin {
  max-width: 420px;
}

/* M-10: will the customer hear it? Shape (filled vs hollow dot) and words differ, not color alone. */
.k-pgs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 12px;
  font-size: 0.8125rem;
  font-weight: 600;
}
.k-pg {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--c-muted);
}
.k-pg i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 2px solid currentColor;
  flex: none;
}
.k-pg-ringing {
  color: var(--c-ok-ink);
}
.k-pg-ringing i {
  background: currentColor;
}
.k-pg-muted,
.k-pg-background {
  color: var(--c-late-ink);
}
.k-pg-wa {
  color: var(--c-ok-ink);
}

/* ══ Operations revamp (surfaces.md B1, B3–B5): op- = cashier tablet, staff sign-in, invite, support pages. ══
   Built on ui-* components; these rules are layout plus the cashier-only OrderCard and QR takeover. The k- rules
   above stay until the other surfaces stop using k-field / k-bar / k-second. */

/* App bar extras: branch Select, mode badge. */
.op-bar__branch {
  min-width: 0;
  max-width: 14rem;
}
.op-bar__branch .ui-field {
  gap: 0;
}
.op-bar__branch .ui-select__trigger {
  min-height: var(--s-10);
  font-weight: 600;
}
.op-bar__mode {
  display: inline-flex;
  flex: none;
}
@media (max-width: 599px) {
  .op-bar .ui-appbar__brand {
    max-width: 45%;
  }
  /* Several branches on a phone: the picker names the place, so the business name gives way (logo stays) and
     the picker takes the room; "Cashier mode" sits in the row below. */
  .op-bar--multi .ui-appbar__brand {
    flex: none;
  }
  .op-bar--multi .ui-appbar__name {
    display: none;
  }
  .op-bar--multi .ui-appbar__end {
    flex: 1;
    min-width: 0;
  }
  .op-bar--multi .op-bar__branch {
    flex: 1;
    max-width: none;
  }
}

.op-modebar {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  padding: var(--s-2) var(--s-4) 0;
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
  font-weight: 600;
}
.op-banners:empty {
  display: none;
}
.op-muted {
  color: var(--c-muted);
}

/* Board: New order panel, Making, Ready. Below lg one column at a time, picked by the sticky tabs. */
.op-main {
  min-height: calc(100dvh - var(--h-appbar));
}
.op-board {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-areas: 'side side' 'making ready';
  align-items: start;
  gap: var(--s-5) var(--s-6);
  max-width: 120rem;
  margin-inline: auto;
  padding: var(--s-6);
}
.op-board--kitchen {
  grid-template-areas: 'making ready';
}
.op-board--single {
  display: block;
}
/* The New order strip spans both columns, so each column keeps room for one-line cards. */
.op-side {
  grid-area: side;
  display: flex;
  flex-wrap: wrap;
  /* Everything lines up on the New order button's row (its hint hangs below), not on the hint's baseline. */
  align-items: flex-start;
  gap: var(--s-3) var(--s-6);
}
.op-side .ui-split {
  display: flex;
}
.op-side__new {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  flex: 0 1 26rem;
}
.op-side > .ui-field {
  flex: 0 1 16rem;
  min-height: var(--hit-xl);
  justify-content: center;
}
.op-side .ui-split > .op-new {
  flex: 1;
  border-start-end-radius: 0;
  border-end-end-radius: 0;
}
.op-new__more {
  border-start-start-radius: 0;
  border-end-start-radius: 0;
  border-inline-start: 1px solid color-mix(in srgb, var(--c-on-brand) 35%, transparent);
  padding-inline: var(--s-4);
}
.op-side__foot {
  display: flex;
  align-items: center;
  min-height: var(--hit-xl);
  margin-inline-start: auto;
}
.op-hint {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.op-col--making {
  grid-area: making;
}
.op-col--ready {
  grid-area: ready;
}
.op-col {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
}
.op-colhead {
  margin: 0;
  display: flex;
  align-items: center;
  gap: var(--s-2);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--c-muted);
}
.op-count {
  min-width: var(--s-6);
  padding-inline: var(--s-2);
  border-radius: var(--r-pill);
  background: var(--c-ink);
  color: var(--c-bg);
  text-align: center;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0;
}
.op-tabs {
  display: none;
}
.op-fab {
  display: none;
}
@media (max-width: 1023px) {
  .op-board,
  .op-board--kitchen {
    grid-template-columns: 1fr;
    grid-template-areas: 'tabs' 'col';
    gap: var(--s-3);
    padding: 0 var(--s-4) calc(var(--hit-xl) + var(--s-8));
  }
  .op-tabs {
    display: block;
    grid-area: tabs;
    position: sticky;
    inset-block-start: var(--h-appbar);
    z-index: var(--z-sticky);
    margin-inline: calc(-1 * var(--s-4));
    padding: var(--s-3) var(--s-4);
    background: var(--c-bg);
  }
  .op-col {
    grid-area: col;
  }
  .op-colhead {
    display: none;
  }
  .op-board[data-tab='making'] .op-col--ready,
  .op-board[data-tab='ready'] .op-col--making {
    display: none;
  }
  .op-fab {
    position: fixed;
    inset-block-end: calc(var(--s-4) + env(safe-area-inset-bottom));
    inset-inline: var(--s-4);
    z-index: var(--z-sticky);
    display: flex;
    justify-content: flex-end;
    gap: var(--s-2);
    pointer-events: none;
  }
  .op-fab > .ui-split {
    pointer-events: auto;
    display: flex;
    border-radius: var(--r-md);
    box-shadow: var(--e-2);
  }
  .op-fab .op-new {
    padding-inline: var(--s-6);
    border-start-end-radius: 0;
    border-end-end-radius: 0;
  }
}

/* OrderCard (design-system §4.37): number, meta, one tonal action + ⋯. 96px tall. */
.op-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}
.op-card {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: var(--s-4);
  min-height: var(--hit-xl);
  padding: var(--s-3) var(--s-4);
  border: 1px solid var(--c-line);
  border-radius: var(--r-md);
  background: var(--c-surface);
  box-shadow: var(--e-1);
}
.op-card--ready {
  border-color: var(--c-ready-edge);
}
.op-card--late {
  border-color: var(--c-late);
  background: var(--c-late-soft);
}
.op-card--undo {
  border-style: dashed;
  border-color: var(--c-line-strong);
  background: var(--c-surface-2);
  box-shadow: none;
}
.op-card__num {
  min-width: 3ch;
  font-size: var(--fs-40);
  line-height: var(--lh-40);
  font-weight: 800;
  letter-spacing: -0.02em;
}
.op-card__body {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
}
.op-card__meta {
  display: flex;
  align-items: center;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  gap: var(--s-2);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
  font-weight: 600;
  color: var(--c-muted);
}
.op-card__undo {
  color: var(--c-ink);
}
.op-card__items {
  margin: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.op-card__acts {
  display: flex;
  align-items: center;
  gap: var(--s-1);
}
@media (max-width: 599px) {
  .op-card {
    grid-template-columns: auto 1fr;
    gap: var(--s-2) var(--s-3);
  }
  .op-card__acts {
    grid-column: 1 / -1;
  }
  .op-card__acts > .ui-btn {
    flex: 1;
  }
}

/* M-10: will the customer hear it? Shape (filled vs hollow dot) and words differ, not colour alone. */
.op-pgs {
  display: flex;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  gap: var(--s-1) var(--s-3);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  font-weight: 600;
}
.op-pg {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: var(--s-1);
  color: var(--c-muted);
}
.op-pg i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 2px solid currentColor;
  flex: none;
}
.op-pg--ringing,
.op-pg--on {
  color: var(--c-ready-ink);
}
.op-pg--ringing i {
  background: currentColor;
}
.op-pg--muted,
.op-pg--background {
  color: var(--c-late);
}
.op-older {
  margin-block-start: var(--s-2);
}

/* QR takeover: full screen, the QR always on its own light tile. */
#op-qr {
  padding: 0;
}
#op-qr .ui-dialog__panel {
  width: 100%;
  max-width: none;
  height: 100%;
  max-height: none;
  border-radius: 0;
}
#op-qr .ui-dialog__body {
  flex: 1;
  justify-content: center;
}
/* The heading is for screen readers; the big number says it on screen. */
#op-qr .ui-dialog__title {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
#op-qr .ui-dialog__head {
  justify-content: flex-end;
}
.op-qr {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-4);
  text-align: center;
}
.op-qr__text {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-2);
}
@media (min-width: 600px) and (orientation: landscape) {
  .op-qr {
    flex-direction: row;
    justify-content: center;
    gap: var(--s-12);
  }
}
.op-qr__num {
  margin: 0;
  font-size: var(--fs-num-hero);
  line-height: 1;
  font-weight: 800;
}
.op-qr__tile {
  padding: var(--s-4);
  border-radius: var(--r-md);
  background: #fff;
  color: #000;
}
.op-qr__tile svg {
  display: block;
  width: min(400px, 62dvh, 80vw);
  height: auto;
}
.op-qr__say {
  margin: 0;
  font-size: var(--fs-20);
  line-height: var(--lh-20);
  font-weight: 600;
}
.op-qr__ok,
.op-ok {
  margin: 0;
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  color: var(--c-ready-ink);
  font-weight: 600;
}
#op-qr .ui-dialog__foot {
  justify-content: center;
}
#op-qr .ui-dialog__foot > .ui-btn {
  min-width: 12rem;
}
.op-reasons {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}
.op-tv__h {
  margin: var(--s-4) 0 0;
}
.op-tvs {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
}
.op-tvs li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
  min-height: var(--h-row);
  border-block-end: 1px solid var(--c-line);
}
.op-tvs__name {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  min-width: 0;
}
.op-tvs__name > span {
  display: flex;
  flex-direction: column;
  min-width: 0;
  font-size: var(--fs-14);
}

/* Focus template (sign-in, verify, invite, support): one centred card. */
.op-focus {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--s-6);
  padding: var(--s-6) var(--s-4);
  background: var(--c-bg);
}
.op-focus__top {
  position: absolute;
  inset-block-start: var(--s-4);
  inset-inline-end: var(--s-4);
}
.op-focus__card {
  width: min(100%, var(--w-focus));
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  padding: var(--s-8);
}
@media (max-width: 599px) {
  .op-focus {
    justify-content: flex-start;
    padding-block-start: var(--s-16);
  }
  .op-focus__card {
    padding: var(--s-6) var(--s-5);
  }
}
.op-focus__brand {
  display: flex;
  align-items: center;
  gap: var(--s-3);
}
.op-eyebrow {
  margin: 0;
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--c-muted);
}
.op-focus__card .ui-h1 {
  margin: 0;
}
.op-focus__biz {
  margin: calc(-1 * var(--s-3)) 0 0;
  color: var(--c-muted);
  font-weight: 600;
}
.op-focus__lead {
  margin: 0 0 var(--s-4);
}
.op-focus__foot {
  margin: 0;
  display: flex;
  align-items: center;
  gap: var(--s-2);
  max-width: var(--w-focus);
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.op-sent {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
}
.op-sent:focus {
  outline: none;
}
.op-sent .ui-h2 {
  margin: 0;
  font-size: var(--fs-20);
  line-height: var(--lh-20);
}
.op-sent__icon {
  display: inline-grid;
  place-items: center;
  width: var(--s-12);
  height: var(--s-12);
  border-radius: 50%;
  background: var(--c-ready-soft);
  color: var(--c-ready-ink);
}
.op-sent__icon .ui-icon {
  width: var(--s-6);
  height: var(--s-6);
}
.op-sent__acts {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
  margin-block-start: var(--s-2);
}
.op-wait {
  display: flex;
  align-items: center;
  gap: var(--s-3);
}
.op-modebar .ui-badge {
  flex: none;
  white-space: nowrap;
}
.op-modebar bdi {
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

/* "Call to counter": the small control under the order. */
.op-card__call {
  display: flex;
  margin-block-start: var(--s-2);
}

/* "Call to counter": a called card gets the amber edge of the guest's screen, so the cashier spots who to expect. */
.op-card--called {
  box-shadow: inset 4px 0 0 var(--c-now);
}
[dir='rtl'] .op-card--called {
  box-shadow: inset -4px 0 0 var(--c-now);
}

}
/* surfaces/cashier-history.css */
@layer surfaces {
/* Surface: the cashier's "Recent orders" history (P07, release-v2 R-34). Layout only: colour, type and
   radius come from tokens; badges and the empty state are ui-* components. Logical properties throughout (RTL). */
/* The board's toolbar ("Recent orders"): at the end of the New order strip on large screens (.op-side__foot), in
   its own row under the tabs below lg and on a kitchen board (no strip), so it is there on both tabs. */
.op-tools {
  grid-area: tools;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: var(--s-2);
}
.op-board--kitchen.op-board--tools {
  grid-template-areas: 'tools tools' 'making ready';
}
@media (max-width: 1023px) {
  .op-board.op-board--tools {
    grid-template-areas: 'tabs' 'tools' 'col';
  }
}
.op-recent {
  min-block-size: 12rem;
}
.op-recent__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
}
.op-recent__row {
  display: grid;
  grid-template-columns: minmax(3.5ch, auto) 1fr auto;
  align-items: center;
  gap: var(--s-3);
  padding-block: var(--s-3);
  border-block-end: 1px solid var(--c-line);
}
.op-recent__row:last-child {
  border-block-end: 0;
}
.op-recent__num {
  font-size: var(--fs-24);
  line-height: var(--lh-24);
  font-weight: 800;
  letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums;
}
.op-recent__row--auto .op-recent__num {
  color: var(--c-muted);
}
.op-recent__main {
  min-inline-size: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--s-1);
}
.op-recent__note {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
  overflow-wrap: anywhere;
}
.op-recent__when {
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.op-recent__foot {
  margin: 0;
  padding-block-start: var(--s-3);
  border-block-start: 1px solid var(--c-line);
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.op-recent__retry {
  display: flex;
  justify-content: center;
  padding-block-start: var(--s-3);
}
@media (max-width: 30rem) {
  .op-recent__row {
    grid-template-columns: minmax(3ch, auto) 1fr;
  }
  .op-recent__when {
    grid-column: 2;
  }
}

}
/* surfaces/kitchen.css */
@layer surfaces {
/* Surface: kd- (kitchen mode on /cashier, release-v2 P13, experience-v2 §13 O2). Owned by P13.
   One queue, oldest first, as big tiles (number in Rubik 700, one 96 px action each), then the Ready strip with
   Recall. Touch density. A kitchen *screen* (`.c-kds--screen`, a paired device) is always dark (the page sets
   data-theme=dark) and high contrast here, whatever the guests' appearance; a kitchen member on their own phone
   keeps their appearance. */

.op-main--kitchen {
  padding: var(--s-6);
}
.kd-board {
  max-width: 120rem;
  margin-inline: auto;
  display: flex;
  flex-direction: column;
  gap: var(--s-6);
}

/* "Making 4 · Oldest first … Recent orders" */
.kd-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2) var(--s-4);
  margin-block-end: var(--s-4);
}
.kd-head__title,
.kd-ready__title {
  margin: 0;
  display: flex;
  align-items: center;
  gap: var(--s-2);
  font-size: var(--fs-20, 1.25rem);
  line-height: 1.3;
  font-weight: 700;
}
.kd-head__hint {
  color: var(--c-muted);
  font-size: var(--fs-14);
}
.kd-head__tools {
  margin-inline-start: auto;
}

/* Tiles: as many columns as fit at 15rem, one column on phones. */
.kd-tiles {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr));
  gap: var(--s-4);
}
.kd-tile {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  min-height: 15rem;
  padding: var(--s-5);
  border: 2px solid var(--c-line);
  border-radius: var(--r-lg);
  background: var(--c-surface);
  box-shadow: var(--e-1);
}
.kd-tile--started {
  border-color: var(--c-now);
}
.kd-tile--late {
  border-color: var(--c-late);
  background: var(--c-late-soft);
}
.kd-tile__num {
  font-family: var(--f-num);
  font-size: 4rem;
  line-height: 1;
  font-weight: 700;
  letter-spacing: -0.02em;
  direction: ltr;
  unicode-bidi: isolate;
  align-self: flex-start;
}
.kd-tile__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
  font-size: var(--fs-16, 1rem);
  font-weight: 600;
  color: var(--c-muted);
}
.kd-tile__items {
  margin: 0;
  font-size: var(--fs-16, 1rem);
  line-height: 1.4;
  overflow-wrap: anywhere;
}
.kd-tile__act {
  margin-block-start: auto;
}
.kd-tile__act .ui-btn {
  min-height: var(--hit-xl);
}

/* Ready strip: numbers waiting for pickup, each with Recall (or Undo in the 5 s window). */
.kd-ready {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  padding: var(--s-4) var(--s-5);
  border-radius: var(--r-lg);
  background: var(--c-ready-soft);
  box-shadow: inset 0 0 0 1px var(--c-ready-edge);
}
.kd-ready__title {
  color: var(--c-ready-ink);
}
.kd-ready__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2) var(--s-4);
}
.kd-ready__item {
  display: flex;
  align-items: center;
  gap: var(--s-1);
  padding-inline-start: var(--s-3);
  border-radius: var(--r-md);
  background: var(--c-surface);
}
.kd-ready__num {
  font-family: var(--f-num);
  font-size: 1.75rem;
  font-weight: 700;
  direction: ltr;
  unicode-bidi: isolate;
}
.kd-ready__none {
  margin: 0;
  color: var(--c-muted);
}

@media (max-width: 599px) {
  .op-main--kitchen {
    padding: var(--s-4);
  }
  .kd-tiles {
    grid-template-columns: 1fr;
  }
  .kd-tile {
    min-height: 0;
  }
}

/* The kitchen screen: larger type, and higher contrast than the regular dark appearance (critique 1.15). */
.c-kds--screen {
  --c-bg: #000;
  --c-surface: #111;
  --c-line: #3d3d3d;
  --c-muted: #c9c9c9;
  --c-ink: #fff;
}
.c-kds--screen .kd-tile {
  border-width: 3px;
}
.c-kds--screen .kd-tile__num {
  font-size: 5rem;
}
.c-kds--screen .kd-tile__meta,
.c-kds--screen .kd-tile__items {
  font-size: 1.25rem;
}
.c-kds--screen .kd-head__title,
.c-kds--screen .kd-ready__title {
  font-size: 1.75rem;
}
.c-kds--screen .kd-ready__num {
  font-size: 2.25rem;
}

/* A paired device's app bar: its kind and name where a person's chip would be. */
.op-device {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  min-height: var(--ctl-sm, 2.25rem);
  padding-inline: var(--s-3);
  border-radius: var(--r-pill);
  background: var(--c-surface);
  box-shadow: inset 0 0 0 1px var(--c-line);
  font-size: var(--fs-14);
  font-weight: 600;
  white-space: nowrap;
}
.op-device .ui-icon {
  width: 1.125rem;
  height: 1.125rem;
  flex: none;
}
.op-device__kind {
  color: var(--c-muted);
}
@media (max-width: 599px) {
  .op-device__kind,
  .op-device > [aria-hidden='true'] {
    display: none;
  }
}

/* The live board's staged banner (5 s reconnecting, 60 s offline): the offline stage is louder. */
.op-live--offline {
  background: var(--c-late-soft);
  box-shadow: inset 0 0 0 1px var(--c-late);
}

}
/* surfaces/editor.css */
@layer surfaces {
/* Surface: e- (waiting-page editor, C8, inside the shared workspace shell `sh-` or the HQ console frame). Layout
   only: colour, type and controls come from ui-* components and tokens (design-system.md §1.1, §1.6 template
   `split`). P20: four sections (Content, Extras, Alerts, Branch overrides) and the Brand studio's preview frame. */

/* ── Editor page (split): content column + sticky phone preview ─────────────────────────────────────────── */
.e-page {
  max-width: var(--w-content);
  margin-inline: auto;
  padding-block-end: var(--s-8);
}
.e-page .ui-savebar {
  margin-inline: calc(var(--s-4) * -1);
}
.e-scope {
  width: 280px;
  max-width: 100%;
}
@media (max-width: 599px) {
  .e-scope {
    width: 100%;
  }
}
.e-scope__text {
  margin: var(--s-2) 0 0;
  color: var(--c-muted);
}
.e-scope__text b {
  color: var(--c-ink);
}
.e-viewswitch {
  margin-block-end: var(--s-4);
}
@media (min-width: 1024px) {
  .e-viewswitch {
    display: none;
  }
}
.e-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--s-6);
  align-items: start;
}
@media (min-width: 1024px) {
  .e-split {
    grid-template-columns: minmax(0, 1fr) var(--w-preview);
    gap: var(--s-8);
  }
}
@media (max-width: 1023px) {
  .e-page[data-view='edit'] .e-preview,
  .e-page[data-view='preview'] .e-content {
    display: none;
  }
}
.e-content {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  min-width: 0;
}
.e-sections {
  border: 1px solid var(--c-line);
  border-radius: var(--r-lg);
  background: var(--c-surface);
  overflow: clip;
}
.e-sections .ui-disc + .ui-disc {
  border-block-start: 1px solid var(--c-line);
}
.e-sections .ui-disc__btn {
  padding-inline: var(--s-5);
}
.e-sections .ui-disc__body {
  display: flex;
  flex-direction: column;
  gap: var(--s-5);
  padding: 0 var(--s-5) var(--s-6);
}
.e-lead {
  margin: 0;
  color: var(--c-muted);
}
.e-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--s-3);
}
@media (min-width: 600px) {
  .e-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Branch colour: inherited value as text with an Override action. */
.e-inherit {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-3);
  padding: var(--s-3);
  border: 1px solid var(--c-line);
  border-radius: var(--r-md);
  background: var(--c-surface-2);
}
.e-inherit__chip {
  width: var(--s-8);
  height: var(--s-8);
  flex: none;
}
.e-inherit__text {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
}
.e-custom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-1);
  margin: 0;
  color: var(--c-muted);
}

/* Extras: one row per extra; its fields open under it when it's on. */
.e-extras {
  display: flex;
  flex-direction: column;
}
.e-extra {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  padding-block: var(--s-4);
}
.e-extra + .e-extra {
  border-block-start: 1px solid var(--c-line);
}
.e-extra__head {
  display: flex;
  flex-direction: column;
}
.e-extra__label {
  font-weight: 600;
}
.e-extra__desc {
  color: var(--c-muted);
}
.e-extra__body {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  padding-inline-start: var(--s-4);
  border-inline-start: 2px solid var(--c-line);
}
.e-extra__body[hidden] {
  display: none;
}

/* How customers are told: read-only rows. */
.e-told {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  margin: 0;
  padding: 0;
  list-style: none;
}
.e-told__row {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding: var(--s-3);
  border: 1px solid var(--c-line);
  border-radius: var(--r-md);
}
.e-told__text {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
}
.e-told__label {
  font-weight: 600;
}
.e-told__desc {
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}

/* Step names: a row per step, EN | AR side by side from md. */
.e-steps {
  display: flex;
  flex-direction: column;
  gap: var(--s-5);
}
.e-step {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}
.e-step__name {
  color: var(--c-ink);
  font-weight: 600;
}

/* ── Preview: PhoneFrame (§4.38) with its own theme, language and brand set ────────────────────────────── */
.e-preview {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}
@media (min-width: 1024px) {
  .e-preview {
    position: sticky;
    inset-block-start: calc(var(--h-appbar) + var(--s-4));
  }
  /* Phone and its controls fit the window, so the controls never scroll away. */
  .e-phone {
    max-height: calc(100dvh - var(--h-appbar) - 200px);
  }
}
.e-phone {
  width: 100%;
  max-width: var(--w-preview);
  aspect-ratio: 360 / 700;
  margin-inline: auto;
  border: 1px solid var(--c-line-strong);
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--c-bg);
  color: var(--c-ink);
  box-shadow: var(--e-1);
  container-type: inline-size;
}
.e-screen {
  height: 100%;
  overflow: auto;
  background: var(--c-bg);
  color: var(--c-ink);
}
.e-screen.c-ready {
  background: var(--c-ready);
  color: #fff;
}
.e-screen .c-root {
  min-height: 100%;
}
.e-screen > .ui-skel {
  padding: var(--s-4);
}
.e-controls {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
}
.e-controls__row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-3);
}

/* P14: where the brand went (a pointer to Brand, v1's pasted-logo banner) and a branch's old colour, above the
   content sections; the offer image is an upload (Dropzone, wide). */
.e-brandnote .ui-callout__body {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--s-3);
}
.e-branchcolor {
  margin-block-end: var(--s-2);
}
.e-offer-img {
  display: block;
  max-width: 100%;
  max-height: 100%;
  object-fit: cover;
}

/* ── P20 (C8): the café's lines, the step names group, branch overrides, the preview frame ───────────────── */
.e-line__hint {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.e-subhead {
  font-weight: 600;
}
.e-steps > .e-line__hint {
  margin-block-start: calc(var(--s-4) * -1);
}
.e-extras--menu {
  padding-block-start: var(--s-1);
  border-block-start: 1px solid var(--c-line);
}
.e-branches {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
  list-style: none;
  border: 1px solid var(--c-line);
  border-radius: var(--r-md);
}
.e-branch {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  min-height: var(--h-row, 56px);
  padding: var(--s-3) var(--s-4);
}
.e-branch + .e-branch {
  border-block-start: 1px solid var(--c-line);
}
.e-branch__text {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-width: 0;
}
.e-branch__name {
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.e-branch__note {
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.e-scopenote .ui-callout__body {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-2);
}
/* The same frame as the Brand studio's waiting preview: a phone, as tall as the window allows. */
#e-frame {
  position: relative;
  container-type: inline-size;
}
#e-frame.ui-preview--phone {
  block-size: min(680px, calc(100dvh - var(--h-appbar, 56px) - 220px));
  min-block-size: 480px;
}
#e-frame > .e-screen {
  block-size: 100%;
}

/* ── In the HQ console (staff view) ─────────────────────────────────────────────────────────────────────────
   The console's main column is ~780 px on a 1280 screen, so the template's 560 px form would squeeze the phone
   preview to ~190 px. Sized by the editor's own width instead of the screen's: side by side with a readable phone
   when there is room, else the template's Edit | Preview switch. */
.e-root[data-view='staff'] {
  container: e-root / inline-size;
}
@container e-root (min-width: 760px) {
  .e-root[data-view='staff'] .ui-tpl__panes {
    grid-template-columns: minmax(0, 1fr) minmax(300px, 340px);
  }
}
@container e-root (max-width: 759px) {
  .e-root[data-view='staff'] .ui-tpl__panes {
    grid-template-columns: minmax(0, 1fr);
  }
  .e-root[data-view='staff'] .ui-tpl__panes-switch {
    display: block;
  }
  .e-root[data-view='staff'] .ui-tpl--split[data-pane='form'] .ui-tpl__preview-pane,
  .e-root[data-view='staff'] .ui-tpl--split[data-pane='preview'] .ui-tpl__form-pane {
    display: none;
  }
  .e-root[data-view='staff'] .ui-tpl__preview-pane {
    position: static;
  }
}

}
/* surfaces/brand.css */
@layer surfaces {
/* Brand studio `/dashboard/brand` and its HQ console twin (release-v2 P14; experience-v2 §9, §13 C7).
   SplitEditor: form cards at inline-start, sticky preview at inline-end. Everything client-coloured sits inside a
   [data-preview-frame] (the big preview, the logo tiles, the background samples), themed from the draft by a
   constructed stylesheet; the form, SaveBar and dialogs keep the page's own tokens (HQ ink in the console). */

.bs-form {
  display: flex;
  flex-direction: column;
  gap: var(--gap-section, var(--s-6));
  min-width: 0;
}
.bs-sec {
  display: flex;
  flex-direction: column;
  gap: var(--s-5);
}
.bs-sec__head {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
}
.bs-sec__desc {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.bs-sec__body {
  display: flex;
  flex-direction: column;
  gap: var(--s-6);
  min-width: 0;
}
.bs-sec--plain {
  gap: 0;
}
.bs-grid {
  display: grid;
  gap: var(--s-4);
  grid-template-columns: minmax(0, 1fr);
}
@media (min-width: 600px) {
  .bs-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* ── Logo slots ───────────────────────────────────────────────────────────────────────────────────────────── */
.bs-slots {
  display: flex;
  flex-direction: column;
  gap: var(--s-6);
}
.bs-slot {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  min-width: 0;
}
.bs-slot__hint {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-13, 13px);
  line-height: var(--lh-13, 18px);
}
.bs-drop__img {
  display: block;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}
/* The upload thumbnail on its plate (R-65): a white logo is visible on the brand or ink tile. */
.bs-drop__thumb {
  display: grid;
  place-items: center;
  inline-size: 100%;
  block-size: 100%;
  padding: var(--s-1);
  box-sizing: border-box;
  overflow: hidden;
}
.bs-drop__thumb[data-plate='white'] {
  background: #fff;
  box-shadow: inset 0 0 0 1px var(--c-line);
}
.bs-drop__thumb[data-plate='brand'] {
  background: var(--brand);
  box-shadow: inset 0 0 0 1px var(--brand-edge, transparent);
}
.bs-drop__thumb[data-plate='ink'] {
  background: #151412;
}
.bs-tiles {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-3);
}
/* A logo on a light and a dark surface, with the plate it gets there. */
.bs-tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--s-2);
  margin: 0;
  inline-size: 152px;
  block-size: 92px;
  padding: var(--s-3);
  border: 1px solid var(--c-line);
  border-radius: var(--r-md, 12px);
  background: var(--c-surface);
  color: var(--c-muted);
}
.bs-tile__logo {
  display: inline-grid;
  place-items: center;
  block-size: 44px;
  max-inline-size: 128px;
  padding: var(--s-1) var(--s-2);
  border-radius: var(--r-sm, 8px);
}
.bs-tile__logo img {
  display: block;
  max-block-size: 32px;
  max-inline-size: 112px;
  object-fit: contain;
}
.bs-tile__cap {
  font-size: var(--fs-12, 12px);
  line-height: 1;
}

/* Plates (R-65), on the tiles and on every logo the previews render. */
.bs-tile__logo[data-plate='white'],
[data-preview-frame] .bs-plated[data-plate='white'] {
  background: #fff;
  box-shadow: inset 0 0 0 1px var(--c-line);
}
.bs-tile__logo[data-plate='brand'],
[data-preview-frame] .bs-plated[data-plate='brand'] {
  background: var(--brand);
  box-shadow: inset 0 0 0 1px var(--brand-edge, transparent);
}
.bs-tile__logo[data-plate='ink'],
[data-preview-frame] .bs-plated[data-plate='ink'] {
  background: #151412;
  box-shadow: none;
}
.bs-tile__logo[data-plate='none'],
[data-preview-frame] .bs-plated[data-plate='none'] {
  background: transparent;
  box-shadow: none;
}

/* "Match your color to your new logo?" */
.bs-match .ui-callout__body {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
}
.bs-match__swatches {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
}
.bs-swatch {
  gap: var(--s-2);
}
.bs-swatch__chip {
  inline-size: 20px;
  block-size: 20px;
  flex: none;
}

/* ── Style samples ────────────────────────────────────────────────────────────────────────────────────────── */
.bs-aa {
  font-size: var(--fs-24, 24px);
  line-height: 1.2;
  font-weight: 600;
  color: var(--c-ink);
  white-space: nowrap;
}
.bs-aa--plex {
  font-family: var(--f-ui);
}
.bs-aa--rubik {
  font-family: rubik, system-ui, sans-serif;
}
.bs-aa--cairo {
  font-family: cairo, system-ui, sans-serif;
}
.bs-aa--almarai {
  font-family: almarai, system-ui, sans-serif;
}
.bs-corner {
  display: block;
  inline-size: 44px;
  block-size: 30px;
  border: 2px solid var(--c-ink);
  border-block-end: 0;
  border-inline-start: 0;
}
.bs-corner--rounded {
  border-start-end-radius: 16px;
}
.bs-corner--soft {
  border-start-end-radius: 8px;
}
.bs-corner--square {
  border-start-end-radius: 2px;
}
.bs-mini {
  display: grid;
  grid-template-rows: 12px 1fr;
  inline-size: 84px;
  block-size: 52px;
  overflow: hidden;
  border: 1px solid var(--c-line);
  border-radius: var(--r-sm, 8px);
  background: var(--c-bg);
}
.bs-mini__bar {
  background: transparent;
}
.bs-mini__card {
  margin: var(--s-1) var(--s-2) var(--s-2);
  border-radius: 4px;
  background: var(--c-surface);
  box-shadow: inset 0 0 0 1px var(--c-line);
}
.bs-mini--tinted {
  background: var(--c-accent-soft);
}
.bs-mini--header .bs-mini__bar {
  background: var(--brand);
}

/* ── Preview ──────────────────────────────────────────────────────────────────────────────────────────────── */
.bs-preview {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  min-width: 0;
}
.bs-pctl {
  min-width: 0;
}
.bs-pctl > .ui-field {
  min-width: 0;
}
.bs-pctl__row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--s-3);
}
#bs-frame {
  position: relative;
  container-type: inline-size;
}
#bs-frame.ui-preview--phone {
  block-size: min(680px, calc(100dvh - var(--h-appbar, 56px) - 220px));
  min-block-size: 480px;
}
.bs-screen {
  block-size: 100%;
  overflow: auto;
  background: var(--c-bg);
  color: var(--c-ink);
}
/* Wide surfaces are drawn at their real size and scaled to the frame (brand-client.ts sets the zoom). */
.bs-screen--cashier {
  inline-size: 1024px;
  block-size: 576px;
}
.bs-screen--tv {
  inline-size: 1280px;
  block-size: 720px;
  overflow: hidden;
}
.bs-screen--sticker {
  inline-size: 210mm;
  block-size: 297mm;
  overflow: hidden;
  background: #fff;
}
.bs-screen--email {
  inline-size: 640px;
  block-size: auto;
  background: var(--c-bg);
  padding-block: var(--s-4);
}
#bs-frame:has(.bs-screen--email) {
  max-block-size: 560px;
  overflow: auto;
}
.bs-screen--sticker .p-sheet {
  box-shadow: none;
}
.bs-screen .c-root,
.bs-screen .op-main {
  min-block-size: 100%;
}
.bs-screen > .ui-skel {
  padding: var(--s-4);
}
@media (min-width: 1024px) {
  .bs-preview {
    position: sticky;
    inset-block-start: calc(var(--h-appbar, 56px) + var(--s-4));
  }
}
@media (max-width: 599px) {
  .bs-tile {
    inline-size: calc(50% - var(--s-2));
  }
}

/* A filled slot needs no drop target's height: the file row is enough (and the file line wraps under the tile
   on phones instead of truncating). */
.bs-slot .ui-drop[data-state='done'] {
  min-height: 0;
  padding: var(--s-3);
}
.bs-slot .ui-drop__done .ui-drop__file {
  flex: 1 1 8rem;
  white-space: normal;
}
.bs-slot .ui-drop--wide:not([data-state='done']) {
  min-height: var(--w-drop);
}

}
/* surfaces/print.css */
@layer surfaces {
/* Surface: p- j- (printed QR materials, join page). Moved verbatim from counter.css; owned by that surface.
   Layout-only once migrated (design-system.md §1.1): colour, borders, padding and type come from ui-* components. */
/* ── Printed QR materials (M-07). Millimetres, so 100% scale prints true to size. ─────── */
/* QR & print page (C8, template `split`): options card + scaled preview of the real sheet. */
.p-page {
  max-width: var(--w-content);
  margin-inline: auto;
  padding-block-end: var(--s-8);
}
.p-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--s-6);
  align-items: start;
}
@media (min-width: 1024px) {
  .p-split {
    grid-template-columns: 380px minmax(0, 1fr);
    gap: var(--s-8);
  }
}
.p-options {
  display: flex;
  flex-direction: column;
  gap: var(--s-5);
}
.p-link {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--s-1);
}
.p-link > .ui-field {
  align-self: stretch;
}
.p-go {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}
.p-go p {
  margin: 0;
}
.p-preview {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  min-width: 0;
}
@media (min-width: 1024px) {
  .p-preview {
    position: sticky;
    inset-block-start: calc(var(--h-appbar) + var(--s-4));
  }
}
.p-preview__title,
.p-preview__note {
  margin: 0;
}
/* The sheet is laid out in mm; on screen it is zoomed to fit the column, in print it is true size. */
.p-stage {
  display: grid;
  place-items: center;
  padding: var(--s-4);
  border-radius: var(--r-lg);
  background: var(--c-surface-2);
  overflow: hidden;
  zoom: 0.4;
}
@media (min-width: 600px) {
  .p-stage {
    zoom: 0.62;
  }
}
/* P08: the page is a SplitEditor with a 360 form, so the preview pane is ~300 px at 1024 and ~600 at 1280. */
@media (min-width: 1024px) {
  .p-stage {
    zoom: 0.36;
  }
}
@media (min-width: 1280px) {
  .p-stage {
    zoom: 0.7;
  }
}
@media (min-width: 1440px) {
  .p-stage {
    zoom: 0.85;
  }
}
.p-sheetwrap[hidden] {
  display: none;
}
.p-sheet {
  background: #fff;
  color: var(--c-ink);
  box-shadow: 0 2px 16px rgba(22, 21, 19, 0.15);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.p-paper-a4 {
  width: 210mm;
  height: 297mm;
}
.p-paper-letter {
  width: 216mm;
  height: 279mm;
}
.p-cut {
  border: 0.4mm dashed var(--c-muted);
  border-radius: 6mm;
  padding: 6mm;
}
.p-cutnote {
  margin: 4mm 0 0;
  font-size: 9pt;
  color: var(--c-muted);
}
.p-panel {
  position: relative;
  background: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4mm;
  text-align: center;
  border-radius: 4mm;
  overflow: hidden;
}
.p-sticker {
  width: 100mm;
  padding: 10mm 7mm 7mm;
}
.p-tent {
  width: 170mm;
  padding: 8mm 10mm 6mm;
  display: grid;
  grid-template-columns: 76mm minmax(0, 1fr);
  grid-template-areas: 'qr head' 'qr place' 'qr headline' 'qr steps' 'qr foot';
  column-gap: 8mm;
  row-gap: 3mm;
  text-align: start;
  align-items: center;
}
.p-tent .p-qr {
  grid-area: qr;
}
.p-tent .p-headline {
  grid-area: headline;
}
.p-tent .p-steps {
  grid-area: steps;
}
.p-tent .p-foot {
  grid-area: foot;
}
/* P17: the client's band at the top of the panel: brand fill, on-brand text, the logo master (300 dpi at this
   size) on its plate, the display typeface. The QR below is always black on white. */
.p-band {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3mm;
  min-height: 18mm;
  padding: 3mm 5mm;
  background: var(--brand);
  color: var(--on-brand);
  box-shadow: inset 0 -0.4mm 0 var(--brand-edge, transparent);
  -webkit-print-color-adjust: exact;
  print-color-adjust: exact;
}
.p-sticker .p-band {
  align-self: stretch;
  margin: -10mm -7mm 0;
}
.p-tent .p-band {
  grid-area: head;
  justify-content: flex-start;
  border-radius: 3mm;
}
.p-band__name {
  display: flex;
  flex-direction: column;
  min-width: 0;
  font-family: var(--f-display, var(--f-sans));
  font-size: 15pt;
  line-height: 1.15;
  overflow-wrap: anywhere;
}
.p-logo {
  width: 12mm;
  height: 12mm;
  font-size: 16pt;
}
/* The monogram on the band: inverted so it never melts into the fill. */
.p-band .p-logo:not(.p-logo--img) {
  display: grid;
  place-items: center;
  border-radius: 2.5mm;
  background: var(--on-brand);
  color: var(--brand);
  font-family: var(--f-display, var(--f-sans));
  font-weight: 800;
}
.p-logo--img {
  width: auto;
  height: auto;
  background: none;
}
.p-logo--img img {
  display: block;
  height: 12mm;
  width: auto;
  max-width: 40mm;
  object-fit: contain;
}
.p-logo--img[data-plate='white'],
.p-logo--img[data-plate='brand'],
.p-logo--img[data-plate='ink'] {
  padding: 1.5mm 2.5mm;
  border-radius: 2mm;
}
.p-logo--img[data-plate='white'] {
  background: #fff;
}
.p-logo--img[data-plate='brand'] {
  background: var(--brand);
}
.p-logo--img[data-plate='ink'] {
  background: var(--c-chrome-bg);
}
.p-place {
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5mm;
  font-size: 10.5pt;
  font-weight: 700;
}
.p-tent .p-place {
  grid-area: place;
  align-items: flex-start;
}
.p-place__addr {
  font-size: 8.5pt;
  font-weight: 400;
  color: var(--c-muted);
}
.p-qr {
  background: #fff;
}
.p-headline {
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 1mm;
  font-size: 17pt;
  font-weight: 800;
  line-height: 1.15;
  font-family: var(--f-display, var(--f-sans));
}
.p-qr svg {
  display: block;
  width: 100%;
  height: 100%;
}
.p-sticker .p-qr {
  width: 70mm;
  height: 70mm;
}
.p-tent .p-qr {
  width: 76mm;
  height: 76mm;
}
.p-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 2mm;
  font-size: 9.5pt;
  text-align: start;
}
.p-steps li {
  display: flex;
  gap: 2.5mm;
  align-items: flex-start;
}
.p-steps li > b {
  width: 5.5mm;
  height: 5.5mm;
  border-radius: 50%;
  background: var(--c-ink);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 8pt;
  flex: none;
}
.p-both {
  display: flex;
  flex-direction: column;
  gap: 0.5mm;
}
.p-both [lang='ar'],
.p-headline [lang='ar'],
.p-foot [lang='ar'] {
  font-weight: 600;
}
.p-foot {
  margin: 0;
  font-size: 8.5pt;
  color: var(--c-muted);
  display: flex;
  gap: 2mm;
  flex-wrap: wrap;
  justify-content: center;
}
.p-half {
  height: 50%;
  width: 100%;
  display: grid;
  place-items: center;
}
.p-flip {
  transform: rotate(180deg);
} /* the far side of the tent reads from across the table */
.p-fold {
  width: 100%;
  border-top: 0.3mm dashed var(--c-muted);
  position: relative;
  height: 0;
}
.p-fold span {
  position: absolute;
  inset-inline: 0;
  margin-inline: auto;
  width: max-content;
  top: -2.5mm;
  background: #fff;
  padding: 0 2mm;
  font-size: 7pt;
  color: var(--c-muted);
}
.j-number {
  font-size: 32px !important;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-align: center;
  min-height: 72px !important;
}
@media print {
  body {
    background: #fff;
  }
  /* Exactly one sheet per page: nothing else on the page may add height. */
  body > :not(#app),
  #app > :not(.sh-app),
  .sh-app > :not(.sh-body),
  .sh-body > :not(.sh-main),
  /* The page is a split template (#p-split): only its preview pane prints, whichever pane a phone was showing. */
  .p-page > :not(#p-split),
  #p-split > :not(.ui-tpl__panes),
  .ui-tpl__panes > :not(.ui-tpl__preview-pane),
  .ui-tpl__preview-pane > :not(.p-preview),
  .p-preview > :not(.p-stage),
  .p-noprint {
    display: none !important;
  }
  .sh-app,
  .sh-body,
  .sh-main,
  .p-page,
  #p-split,
  #p-split .ui-tpl__panes,
  #p-split .ui-tpl__preview-pane,
  .p-preview {
    display: block !important;
    position: static;
    overflow: visible;
    min-height: 0;
    /* The shell's main pads itself per breakpoint with more specific rules; on paper the sheet starts at the edge. */
    padding: 0 !important;
    margin: 0;
    max-width: none;
  }
  .p-paper-a4 {
    height: 296mm;
  }
  .p-paper-letter {
    height: 278mm;
  }
  .p-stage {
    zoom: 1;
    padding: 0;
    display: block;
    background: none;
    border-radius: 0;
  }
  .p-sheet {
    box-shadow: none;
  }
}

}
/* surfaces/tv.css */
@layer surfaces {
/* Surface: t- (TV board, surfaces.md B2). Template `display`: always dark (<html data-theme=dark>), no buttons,
   container units so one layout fits any 16:9 or portrait screen. Owned by the TV surface. */
.c-tv {
  background: var(--c-bg);
  color: var(--c-ink);
  overflow: hidden;
}
.t-root {
  container-type: size;
  height: 100vh;
  height: 100dvh;
  display: flex;
  flex-direction: column;
  padding: 3cqh 3cqw;
  gap: 3cqh;
  box-sizing: border-box;
}
.t-head {
  display: flex;
  align-items: center;
  gap: 1.5cqw;
}
.t-head .ui-logo {
  width: 6cqh;
  height: 6cqh;
  font-size: 3cqh;
}
.t-biz {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.t-biz > bdi:first-child {
  font-size: var(--tv-fs-head);
  font-weight: 800;
  line-height: 1.1;
}
.t-biz__branch {
  font-size: var(--tv-fs-note);
  color: var(--c-muted);
}
.t-clock {
  margin-inline-start: auto;
  font-size: var(--tv-fs-head);
  font-weight: 700;
}
/* Bilingual labels: English then Arabic, side by side where they fit (each keeps its own direction). */
.t-colhead,
.t-more,
.t-empty,
.t-offline > span:last-child {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  column-gap: 0.8em;
}

/* Board: Ready takes two thirds (the thing customers look for), Being made the rest. */
.t-board {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: var(--tv-gap);
}
@container (max-aspect-ratio: 1/1) {
  .t-board {
    grid-template-columns: 1fr;
    grid-template-rows: 2fr 1fr;
  }
}
.t-col {
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: var(--tv-gap);
  padding: 3cqh 2.5cqw;
  border-radius: var(--tv-r);
  background: var(--c-surface);
  overflow: hidden;
}
.t-ready {
  background: var(--c-ready-soft);
  box-shadow: inset 0 0 0 0.3cqh var(--c-ready-edge);
}
.t-colhead {
  margin: 0;
  font-size: var(--tv-fs-head);
  font-weight: 800;
  line-height: 1.2;
}
.t-ready .t-colhead {
  color: var(--c-ready-ink);
}
.t-making .t-colhead {
  color: var(--c-muted);
}
.t-nums {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  align-content: flex-start;
  gap: 1.5cqh 1.5cqw;
}
.t-nums li {
  direction: ltr;
  unicode-bidi: isolate;
  font-variant-numeric: tabular-nums;
  font-weight: 800;
  line-height: 1;
}
.t-making .t-nums li {
  font-size: 6cqh;
  color: var(--c-ink);
}
.t-big {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}
.t-big li {
  display: grid;
  place-items: center;
  min-height: 16cqh;
  border-radius: var(--tv-r);
  background: var(--c-surface);
  color: var(--c-ink);
  font-size: 11cqh;
}
.t-big li.t-new {
  background: var(--c-ready);
  color: #fff;
  animation: t-arrive 1.2s var(--ease-out) 2;
}
@keyframes t-arrive {
  50% {
    transform: scale(1.06);
  }
}
@media (prefers-reduced-motion: reduce) {
  .t-big li.t-new {
    animation: none;
  }
}
.t-more,
.t-empty {
  margin: 0;
  font-size: var(--tv-fs-note);
  font-weight: 700;
  color: var(--c-muted);
}
.t-empty {
  flex: 1;
  justify-content: center;
  align-content: center;
  text-align: center;
  font-size: var(--tv-fs-title);
}

/* Live-board resilience (P13, critique 1.15): the last board always stays. ≥ 5 s without the stream a
   bilingual "Reconnecting… showing the board from 09:12" pill shows; ≥ 60 s it says offline and the numbers dim
   (never hidden, never blank). */
.t-root--stale .t-nums,
.t-root--stale .t-more {
  opacity: 0.55;
}
.t-offline {
  align-self: center;
  display: flex;
  align-items: center;
  gap: 1.2cqw;
  padding: 1.2cqh 2.4cqw;
  border-radius: var(--r-pill);
  background: var(--c-surface);
  box-shadow: var(--e-2);
  font-size: var(--tv-fs-note);
  font-weight: 700;
}
.t-offline--long {
  background: var(--c-late-soft);
  color: var(--c-ink);
  box-shadow: inset 0 0 0 0.25cqh var(--c-late), var(--e-2);
}
.t-notice__text {
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 1cqh;
  font-size: var(--tv-fs-note);
  color: var(--c-muted);
}
.t-offline .ui-icon,
.t-pairnote .ui-icon,
.t-notice > .ui-icon {
  width: 1.2em;
  height: 1.2em;
  flex: none;
}

/* Pairing: one big code, then how to use it. */
.t-pair .t-pairbox,
.t-notice {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4cqh;
  text-align: center;
}
.t-pairtitle,
.t-notice__title {
  margin: 0;
  font-size: var(--tv-fs-title);
  font-weight: 800;
  display: flex;
  flex-direction: column;
  gap: 1cqh;
}
.t-code {
  margin: 0;
  display: flex;
  gap: min(1.4cqw, 1.6cqh);
}
/* Sized by height on a TV, capped by width so six cells always fit a portrait tablet or phone (/pair at 390). */
.t-code__cell {
  display: grid;
  place-items: center;
  width: min(11cqh, 13cqw);
  height: min(15cqh, 17.7cqw);
  border-radius: var(--tv-r);
  background: var(--c-surface);
  box-shadow: inset 0 0 0 0.3cqh var(--c-line-strong);
  font: 800 min(var(--tv-fs-code), 10.5cqw) / 1 var(--f-mono);
  color: var(--c-ink);
}
.t-pairhow {
  margin: 0;
  max-width: min(70cqw, 52ch);
  display: flex;
  flex-direction: column;
  gap: 1.2cqh;
  font-size: var(--tv-fs-note);
  line-height: 1.4;
  text-wrap: balance;
}
/* Both languages side by side on a TV; on a narrow (portrait) screen each takes its own line. */
.t-pairnote {
  margin: 0;
  max-width: 70cqw;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.6cqh 1cqw;
  font-size: var(--tv-fs-note);
  color: var(--c-muted);
  text-wrap: balance;
}
.t-notice > .ui-icon {
  width: 12cqh;
  height: 12cqh;
  color: var(--c-muted);
}

/* No pairing code yet: one big spinner (stops under reduced motion like every ui-spin). */
.t-notice > .t-spin {
  width: 10cqh;
  height: 10cqh;
  border-width: 1cqh;
}

}
/* surfaces/cashier-tv.css */
@layer surfaces {
/* Surface: k-tv* (cashier: TV pairing list). Moved verbatim from counter.css; owned by that surface.
   Layout-only once migrated (design-system.md §1.1): colour, borders, padding and type come from ui-* components. */
.k-tvcode {
  font: 800 28px/1 var(--f-mono) !important;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  text-align: center;
}
.k-h3 {
  font-size: 1rem;
  margin-top: 8px;
}
.k-tvs {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.k-tvs li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.k-tvs li > span {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.k-tvs .c-btn {
  width: auto;
  min-height: var(--t-min);
}

}
/* surfaces/extras.css */
@layer surfaces {
/* Waiting page extras (P-04; release-v2 P20): the masbaha and kids game panels, which waiting-extras.js renders,
   and the placeholder while it loads. Part of the guest stylesheet (guest-manifest.json). Prefix w-. */

.w-panel {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
}
.w-dhikr {
  margin: 0;
  text-align: center;
  font-size: var(--fs-32);
  line-height: 1.5;
  font-weight: 700;
}
.w-bead {
  appearance: none;
  align-self: center;
  display: grid;
  place-items: center;
  width: 10rem;
  height: 10rem;
  margin: 0;
  border: 0;
  border-radius: 50%;
  background: var(--c-brand);
  color: var(--c-on-brand);
  font: inherit;
  font-size: var(--fs-40);
  font-weight: 800;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}
.w-bead:active {
  background: var(--c-brand-press);
  transform: scale(0.98);
}
.w-count {
  margin: 0;
  text-align: center;
  font-weight: 600;
}
.w-hud {
  display: flex;
  justify-content: space-between;
  color: var(--c-muted);
}
.w-hud b {
  color: var(--c-ink);
}
.w-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s-2);
  direction: ltr;
}
.w-cell {
  appearance: none;
  display: grid;
  place-items: center;
  aspect-ratio: 1;
  min-height: var(--hit-main);
  margin: 0;
  border: 1px solid var(--c-line);
  border-radius: var(--r-md);
  background: var(--c-surface-2);
  color: var(--c-ink);
  cursor: pointer;
  touch-action: manipulation;
}
.w-cell[disabled] {
  cursor: default;
}
.w-lit {
  border-color: var(--c-accent-edge);
  background: var(--c-accent-soft);
}
.w-bean {
  width: 60%;
  height: 60%;
  fill: var(--c-ink);
  stroke: var(--c-accent-soft);
  stroke-width: 1.6;
  stroke-linecap: round;
}
.w-bean path {
  fill: none;
}
.w-panel--wait {
  min-height: calc(var(--s-16) * 4);
}
.w-panel__ph {
  display: block;
  flex: 1 1 auto;
  border-radius: var(--r-md);
}
/* The prayer-bead counter is a brand fill: ring it like every other filled control (P03 fill-edge rule). */
.w-bead {
  box-shadow: inset 0 0 0 1px var(--c-accent-fill-edge);
}

}
/* surfaces/admin.css */
@layer surfaces {
/* Surface: a- (back office). Moved verbatim from counter.css; owned by that surface.
   Layout-only once migrated (design-system.md §1.1): colour, borders, padding and type come from ui-* components. */
/* ── admins.bellou.io back office (M-17, M-18) ──────────────────────────────── */
.a-root {
  max-width: 1180px;
  margin-inline: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.a-nav {
  display: flex;
  gap: 4px;
}
.a-nav a {
  padding: 10px 14px;
  border-radius: var(--r-sm);
  color: var(--c-ink);
  text-decoration: none;
  font-weight: 600;
  min-height: var(--t-min);
  display: inline-flex;
  align-items: center;
}
.a-nav a[aria-current='page'] {
  background: var(--c-bg);
  box-shadow: inset 0 -3px 0 var(--c-accent-edge);
}
.a-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: end;
}
.a-grow {
  flex: 1 1 280px;
}
.a-filters input {
  min-height: var(--t-min);
  border-radius: var(--r-sm);
  border: 1.5px solid var(--c-line);
  padding: 0 12px;
  font: 500 16px/1.2 var(--f-sans);
}
.a-table {
  overflow-x: auto;
  background: var(--c-paper);
  border-radius: var(--r-lg);
  box-shadow: 0 1px 0 var(--c-line);
}
.a-table table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9375rem;
}
.a-table th,
.a-table td {
  padding: 12px 14px;
  text-align: start;
  border-block-end: 1px solid var(--c-line);
  vertical-align: top;
}
.a-table thead th {
  font-size: 0.8125rem;
  color: var(--c-muted);
  font-weight: 600;
  white-space: nowrap;
}
.a-table a {
  color: var(--c-ink);
}
.a-slug {
  display: block;
  font-family: var(--f-mono);
  font-size: 0.8125rem;
  color: var(--c-muted);
  direction: ltr;
  text-align: start;
}
.a-num {
  font-variant-numeric: tabular-nums;
  text-align: end !important;
}
.a-status {
  display: inline-flex;
  border-radius: var(--r-pill);
  padding: 3px 10px;
  font-size: 0.8125rem;
  font-weight: var(--fw-strong);
  background: var(--c-bg);
}
.a-active {
  background: var(--c-ok-bg);
  color: var(--c-ok-ink);
}
.a-suspended,
.a-closed {
  background: var(--c-late-bg);
  color: var(--c-late-ink);
}
.a-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}
.a-head .c-tool {
  margin-inline-start: auto;
}
.a-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 16px;
}
.a-plan {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.a-plan .c-btn {
  grid-column: 1 / -1;
}
.a-choice {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: var(--t-min);
  padding: 0 12px;
  border: 1.5px solid var(--c-line);
  border-radius: var(--r-sm);
  font-weight: 600;
  cursor: pointer;
}
.a-choice:has(input:checked) {
  border-color: var(--c-ink);
  border-width: 2px;
}
.a-features select {
  min-height: var(--t-min);
  border-radius: var(--r-sm);
  border: 1.5px solid var(--c-line);
  background: var(--c-paper);
  font: 500 15px/1.2 var(--f-sans);
  padding: 0 10px;
}
.a-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 2px solid var(--c-muted);
  display: inline-block;
}
.a-dot-on {
  background: var(--c-ok-ink);
  border-color: var(--c-ok-ink);
}
.a-details {
  color: var(--c-muted);
  font-family: var(--f-mono);
  font-size: 0.8125rem;
  word-break: break-all;
}
.a-qr {
  width: 200px;
  height: 200px;
  background: #fff;
  padding: 8px;
  border-radius: var(--r-md);
  align-self: center;
}
.a-qr svg {
  width: 100%;
  height: 100%;
  display: block;
}
.a-key {
  font-family: var(--f-mono);
  direction: ltr;
}

}
/* surfaces/shell.css */
@layer surfaces {
/* Surface: sh- (the signed-in workspace shell: apps/web/src/shell/shell-view.ts, release-v2 P08). Layout only:
   the app bar, rail, bottom bar, account chip and banners are ui-* components.
   Rail: 240 from lg, a 64 icon rail from md, the bottom bar below md. It NEVER changes width by page or template
   (XP-VQ-3), and its column runs the full height of the page (so the rail and the page background reach the
   bottom of long pages: dashboard, editor, print). */
.sh-app {
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  background: var(--c-bg);
  color: var(--c-ink);
}
.sh-appbar {
  gap: var(--s-3);
  padding-inline: var(--s-4);
}
.sh-appbar .ui-appbar__brand {
  max-width: none;
  flex: 0 1 auto;
}
.sh-mode {
  white-space: nowrap;
}
@media (max-width: 599px) {
  .sh-mode {
    display: none;
  }
}
/* The branch scope Select sits after the business name. */
.sh-scope {
  min-width: 0;
}
.sh-scope .ui-field {
  gap: 0;
}
.sh-scope .ui-field__label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.sh-scope .ui-select__trigger {
  min-height: var(--ctl-sm);
  border-color: transparent;
  background: var(--n-3);
  font-size: var(--fs-13);
}
@media (max-width: 599px) {
  .sh-scope {
    display: none;
  }
}

.sh-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  flex: 1;
  align-items: stretch;
}
.sh-railcol {
  display: none;
  border-inline-end: 1px solid var(--c-line);
  background: var(--c-surface);
}
@media (min-width: 600px) {
  .sh-body {
    grid-template-columns: var(--w-rail-icons) minmax(0, 1fr);
  }
  .sh-railcol {
    display: block;
  }
}
@media (min-width: 1024px) {
  .sh-body {
    grid-template-columns: var(--w-rail) minmax(0, 1fr);
  }
}
.sh-rail {
  position: sticky;
  inset-block-start: var(--h-appbar);
  height: calc(100dvh - var(--h-appbar));
}

.sh-main {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  padding-block: var(--s-8) var(--s-12);
  padding-inline: var(--gutter);
}
.sh-main:focus {
  outline: none;
}
/* Legacy pages that don't use a template yet stay readable. */
.sh-main > :not(.ui-tpl):not(.sh-state) {
  max-width: var(--w-list);
}
@media (max-width: 599px) {
  .sh-main {
    padding-block: var(--s-4) calc(var(--h-bottombar) + var(--s-8) + env(safe-area-inset-bottom));
    padding-inline: var(--s-4);
  }
}
/* While a form is dirty the SaveBar takes the bottom bar's place (design-system §1.5 bottom stack). */
@media (max-width: 599px) {
  .sh-app:has(.ui-savebar:not([hidden])) .ui-bottombar {
    display: none;
  }
}
.sh-app .ui-bottombar {
  position: fixed;
  inset-inline: 0;
  inset-block-end: 0;
}

/* State pages inside or outside the shell: centred, one action. */
.sh-state {
  display: grid;
  place-items: center;
  min-height: 60dvh;
}
.sh-state .ui-empty {
  max-width: var(--w-focus);
}
.sh-focus {
  display: grid;
  place-items: center;
  min-height: 100dvh;
  padding-inline: var(--s-4);
  background: var(--c-bg);
}

/* Skip link (focus order: first stop on every workspace page; HQ has a-skip). Off-screen until focused. */
.ui-skip {
  position: absolute;
  inset-inline-start: var(--s-2);
  inset-block-start: calc(-1 * var(--s-16));
  z-index: var(--z-toast);
  padding: var(--s-2) var(--s-4);
  border-radius: var(--r-sm);
  background: var(--c-surface);
  color: var(--c-ink);
  font-weight: var(--fw-strong);
}
.ui-skip:focus {
  inset-block-start: var(--s-2);
}

}
/* surfaces/dashboard.css */
@layer surfaces {
/* Surface: d- (the workspace: Home, Team, Branches, Settings; apps/web/src/dashboard/*). Layout only
   (design-system §1.1): cards, rows, stats, fields and buttons are ui-* components; these classes place them. */

.d-home,
.d-settings {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}
.d-muted {
  margin: 0;
  color: var(--c-muted);
}
.d-loading {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  padding-block-start: var(--s-6);
}
.d-error {
  align-items: flex-start;
  flex-direction: row;
  flex-wrap: wrap;
  gap: var(--s-3);
}
.d-error > .ui-icon {
  color: var(--c-danger);
}

/* ── Home: go-live, optional steps, numbers ── */
.d-optional .d-opts,
.d-tasks {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
  list-style: none;
}
.d-opt {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: var(--s-3);
  min-height: var(--h-row);
  padding-block: var(--s-2);
  border-block-end: 1px solid var(--c-line);
}
.d-opt:last-child {
  border-block-end: 0;
}
.d-opt > .d-lock {
  grid-column: 1 / -1;
}
.d-opt__mark {
  display: grid;
  place-items: center;
  width: var(--s-6);
  height: var(--s-6);
  border: 2px dashed var(--c-line-strong);
  border-radius: 50%;
  color: var(--c-on-accent);
}
.d-opt[data-state='done'] .d-opt__mark {
  border: 0;
  background: var(--c-ready);
}
.d-opt__mark .ui-icon {
  width: var(--s-4);
  height: var(--s-4);
}
.d-opt__text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.d-opt__title {
  font-weight: 600;
}
.d-opt[data-state='done'] .d-opt__title {
  color: var(--c-muted);
  font-weight: 500;
}
.d-opt__why {
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.d-opt__act {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: var(--s-2);
}
@media (max-width: 599px) {
  .d-opt {
    grid-template-columns: auto minmax(0, 1fr);
  }
  .d-opt__act {
    grid-column: 2;
    justify-content: flex-start;
  }
}
.d-live .ui-field {
  margin-block: var(--s-3);
}
.d-task {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  min-height: var(--h-row);
  border-block-end: 1px solid var(--c-line);
  color: var(--c-ink);
  font-weight: 500;
  text-decoration: none;
}
.d-task > span {
  flex: 1;
}
.d-task:hover {
  color: var(--c-accent-ink);
}
/* Plan lock row: feature, which plan has it, and Ask Bellou (or "Ask the owner") at the end. */
.d-lock {
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  border-block-end: 0;
}
.d-lock > .ui-icon {
  grid-row: span 2;
  align-self: start;
}
.d-lock > .ui-lockrow__label {
  grid-column: 2;
  color: var(--c-ink);
  font-size: var(--fs-16);
  font-weight: 500;
}
.d-lock > .ui-lockrow__reason {
  grid-column: 2;
}
.d-lock > .ui-btn,
.d-lock > .ui-lockrow__value {
  grid-column: 3;
  grid-row: 1 / span 2;
}
.d-lock > .ui-lockrow__value {
  color: var(--c-muted);
  font-size: var(--fs-14);
}
.d-home > .d-lock,
.d-panel > .d-lock,
.ui-tabs + .d-lock {
  padding-inline: var(--s-4);
  border: 1px solid var(--c-line);
  border-radius: var(--r-md);
  background: var(--c-surface);
}
.d-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
}
.d-filters > .ui-field {
  margin: 0;
}
.d-branchpick {
  min-width: 12rem;
}
.d-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--s-4);
}
@media (min-width: 600px) {
  .d-stats {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
  .d-stats--hero {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
.d-stats--hero {
  padding-block-end: var(--s-4);
  border-block-end: 1px solid var(--c-line);
}
.d-stats--hero .ui-stat__value {
  font-size: var(--fs-40);
  line-height: var(--lh-40);
}
.d-chart {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  margin: 0;
  padding-block-start: var(--s-2);
}
.d-bars {
  display: flex;
  align-items: flex-end;
  gap: var(--s-1);
  height: calc(var(--s-16) * 2.25);
  border-block-end: 1px solid var(--c-chart-axis);
  /* Time runs left to right in both languages. */
  direction: ltr;
}
.d-col {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  gap: var(--s-1);
  min-width: 0;
  height: 100%;
}
.d-col__h {
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  font-variant-numeric: tabular-nums;
}
.d-bar {
  width: 100%;
  max-width: var(--s-8);
  border-radius: var(--r-xs) var(--r-xs) 0 0;
  background: var(--c-chart-bar);
}
.d-col:hover .d-bar {
  background: var(--c-chart-bar-hi);
}
@media (max-width: 599px) {
  .d-col:nth-child(even) .d-col__h {
    visibility: hidden;
  }
}
/* Bar heights in 5% steps: the strict CSP allows classes, not inline styles. */
.d-h0 {
  height: 0%;
}
.d-h5 {
  height: 5%;
}
.d-h10 {
  height: 10%;
}
.d-h15 {
  height: 15%;
}
.d-h20 {
  height: 20%;
}
.d-h25 {
  height: 25%;
}
.d-h30 {
  height: 30%;
}
.d-h35 {
  height: 35%;
}
.d-h40 {
  height: 40%;
}
.d-h45 {
  height: 45%;
}
.d-h50 {
  height: 50%;
}
.d-h55 {
  height: 55%;
}
.d-h60 {
  height: 60%;
}
.d-h65 {
  height: 65%;
}
.d-h70 {
  height: 70%;
}
.d-h75 {
  height: 75%;
}
.d-h80 {
  height: 80%;
}
.d-h85 {
  height: 85%;
}
.d-h90 {
  height: 90%;
}
.d-h95 {
  height: 95%;
}
.d-h100 {
  height: 100%;
}

/* ── Lists (team, branches, counters, screens) ── */
.d-list {
  gap: var(--s-2);
}
.d-list__head {
  display: flex;
  align-items: center;
  gap: var(--s-2);
}
.d-rows {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
  list-style: none;
}
.ui-card.d-rows {
  gap: 0;
  padding: var(--s-1) var(--s-4);
}
.d-alone {
  gap: 0;
  padding-block: var(--s-1) 0;
}
.d-alone > .d-rows {
  border-block-end: 1px solid var(--c-line);
}
.d-rows > li + li > .d-row,
.d-rows > .d-row + .d-row {
  border-block-start: 1px solid var(--c-line);
}
.d-row {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  min-height: var(--h-row);
  padding-block: var(--s-2);
}
.d-row--link {
  color: var(--c-ink);
  text-decoration: none;
  border-radius: var(--r-sm);
}
.d-row--link:hover .d-row__title {
  color: var(--c-accent-ink);
}
.d-row__icon {
  flex: none;
  color: var(--c-muted);
}
.d-row__mail {
  background: var(--c-surface-2);
  color: var(--c-muted);
}
.d-row__main {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-width: 0;
}
.d-row__title {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
  overflow-wrap: anywhere;
  font-weight: 600;
}
.d-row__meta {
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.d-row__badge,
.d-row__act {
  flex: none;
}
.d-row__chev {
  flex: none;
  color: var(--c-muted);
}
@media (max-width: 599px) {
  .d-row {
    flex-wrap: wrap;
  }
  .d-row__main {
    flex-basis: 0;
  }
}

/* ── Branch page ── */
.d-facts {
  gap: 0;
  padding-block: 0;
}
.d-fact {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
  margin: 0;
  padding-block: var(--s-4);
}
.d-fact + .d-fact {
  border-block-start: 1px solid var(--c-line);
}
.d-fact--stack {
  flex-direction: column;
  align-items: stretch;
}
.d-fact > *,
.d-live .ui-callout__body {
  min-width: 0;
  max-width: 100%;
}
/* An icon-only ⋯ menu stays next to the title on phones. */
.sh-main .ui-pagehead__row:has(> .ui-pagehead__actions > .ui-menu:only-child) {
  flex-wrap: nowrap;
}
.sh-main .ui-pagehead__actions:has(> .ui-menu:only-child) {
  width: auto;
}
.d-fact__text {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: var(--s-1);
  min-width: 14rem;
}
.d-panel__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
}
.d-inline {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: var(--s-3);
}
.d-inline > .ui-field {
  flex: 1;
  min-width: 12rem;
}
.ui-tabs + .d-lock {
  margin-block-start: var(--s-4);
}
.d-panel > .d-lock {
  border: 0;
  padding-inline: 0;
}
.d-howto {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  margin: 0;
  padding-inline-start: var(--s-6);
}
.d-howto > li::marker {
  color: var(--c-accent-ink);
  font-weight: var(--fw-strong);
}

/* ── Try it yourself sheet ── */
.d-try {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-2);
  text-align: center;
}
.d-try__qr {
  width: min(16rem, 70vw);
  padding: var(--s-3);
  border-radius: var(--r-md);
  /* QR tiles stay light in dark mode so phones can read them. */
  background: #fff;
}
.d-try__qr svg {
  display: block;
  width: 100%;
  height: auto;
}
.d-try__copy {
  width: 100%;
  text-align: start;
}
/* On a computer the owner scans the QR with their phone; the copyable link is for phones (one device only). */
@media (min-width: 600px) {
  .d-try__copy {
    display: none;
  }
}
.d-try__status {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  margin: 0;
  color: var(--c-muted);
}

/* ── Team dialogs ── */
.d-ownerwarn[hidden],
.d-branchfield[hidden] {
  display: none;
}

/* ── Settings ── */
.d-facts-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr));
  gap: var(--s-3);
  margin: 0;
}
.d-facts-list dt {
  color: var(--c-muted);
  font-size: var(--fs-14);
}
.d-facts-list dd {
  margin: var(--s-1) 0 0;
}
.d-included {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}
.d-included__list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(12rem, 1fr));
  gap: var(--s-2);
  margin: 0;
  padding: 0;
  list-style: none;
}
.d-included__list li {
  display: flex;
  align-items: center;
  gap: var(--s-2);
}
.d-included__list .ui-icon {
  color: var(--c-ready);
}
/* 0039: the Demo plan on Home. Running: a card with days and orders left; ended: a warn callout. */
.d-demo {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}
.d-demo__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--s-2) var(--s-4);
}
.d-demo__ends,
.d-demo__body {
  margin: 0;
  color: var(--c-muted);
}
@media (min-width: 600px) {
  .d-demo__stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
.d-demo--ended .ui-cluster-2 {
  margin-block-start: var(--s-3);
}

}
/* surfaces/branches.css */
@layer surfaces {
/* Surface: br- (Branches and a branch) and dv- (Branch › Devices and the Add device wizard), release-v2 P13,
   experience-v2 §8.2 and §13 C5. Owned by P13. Layout only: colour, type and controls come from ui-* components
   and the d- dashboard surface. Works in both densities (the HQ console renders the same view compact). */

/* ── List ── */
.br-name {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  min-width: 0;
}
.br-name__icon {
  flex: none;
  color: var(--c-muted);
}
.br-name__text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.br-name__title {
  font-weight: 600;
}
.br-name__meta {
  color: var(--c-muted);
  font-size: var(--fs-14);
}
.br-listtabs {
  margin-block-end: var(--s-4);
}
.br-alt {
  color: var(--c-muted);
}
.br-muted {
  color: var(--c-muted);
}
.br-mgr {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  min-width: 0;
  white-space: nowrap;
}
.br-mgr__names {
  display: inline-flex;
  align-items: baseline;
  gap: var(--s-1);
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.br-mgr__more {
  color: var(--c-muted);
  font-variant-numeric: tabular-nums;
}
.br-mgr--none {
  gap: var(--s-1);
}
.br-mgr__assign {
  position: relative;
  z-index: 1; /* above the row's stretched link */
  color: var(--c-accent-ink);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 0.2em;
}
[data-primary='ink'] .br-mgr__assign {
  color: var(--c-ink);
}
.br-lock {
  margin-block-end: var(--s-4);
}

/* ── Detail header: the Branch manager chip under the title ── */
.br-chip {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
  margin-block-start: var(--s-2);
  font-size: var(--fs-14);
}
.br-chip__label {
  color: var(--c-muted);
}
.br-closed {
  margin-block-start: var(--s-4);
}

/* ── Overview: Get this branch ready ── */
.br-ready {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}
.br-ready__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--s-3);
}
.br-ready__head .ui-h3 {
  margin: 0;
}
.br-ready__count {
  color: var(--c-muted);
  font-size: var(--fs-14);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.br-ready__all {
  margin: 0;
  display: flex;
  align-items: center;
  gap: var(--s-2);
  color: var(--c-ready-ink);
  font-weight: 600;
}
.br-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
}
.br-step {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: var(--s-3);
  min-height: var(--row-h, 3rem);
  padding-block: var(--s-2);
}
.br-step + .br-step {
  border-block-start: 1px solid var(--c-line);
}
.br-step--locked {
  display: block;
}
.br-step--locked .ui-lockrow {
  margin: 0;
}
.br-step__mark {
  display: grid;
  place-items: center;
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 50%;
  box-shadow: inset 0 0 0 2px var(--c-line-strong);
}
.br-step--done .br-step__mark {
  background: var(--c-ready);
  box-shadow: none;
  color: #fff;
}
.br-step--done .br-step__mark .ui-icon {
  width: 1rem;
  height: 1rem;
}
.br-step--current .br-step__mark {
  box-shadow: inset 0 0 0 2px var(--c-accent);
}
[data-primary='ink'] .br-step--current .br-step__mark {
  box-shadow: inset 0 0 0 2px var(--c-ink);
}
.br-step__text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.br-step__label {
  font-weight: 600;
}
.br-step--done .br-step__label {
  color: var(--c-muted);
}
.br-step__hint {
  color: var(--c-muted);
  font-size: var(--fs-14);
}

/* The aside (guests' link) sits beside the content from xl; below it, it follows the Get-ready card. */
.br-aside {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--s-3);
}
.br-aside .ui-h3 {
  margin: 0;
}
.br-aside > .ui-field,
.br-aside .ui-copyfield {
  align-self: stretch;
}
.br-aside-wrap {
  margin-block-start: var(--s-4);
}

/* ── Counters ── */
.br-k {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: var(--s-1) var(--s-3);
  min-width: 0;
}
.br-k__name {
  font-weight: 600;
}
.br-k__alt {
  color: var(--c-muted);
}
.br-counters .ui-sortable {
  margin-block-start: var(--s-3);
}
.br-hidden {
  margin-block-start: var(--s-6);
  padding-block-start: var(--s-4);
  border-block-start: 1px solid var(--c-line);
}
.br-hidden .ui-h4 {
  margin: 0 0 var(--s-1);
}
.br-note {
  margin: var(--s-3) 0 0;
  display: flex;
  align-items: center;
  gap: var(--s-2);
  color: var(--c-muted);
  font-size: var(--fs-14);
}
.br-note .ui-icon {
  flex: none;
}

/* ── Details and the danger zone ── */
.br-details {
  max-width: var(--w-form, 35rem);
}
.br-danger {
  margin-block-start: var(--s-4);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3) var(--s-6);
  box-shadow: inset 0 0 0 1px var(--c-danger-soft);
}
.br-danger__text .ui-h3 {
  margin: 0 0 var(--s-1);
}
.br-danger__text p {
  margin: 0;
}
.br-closebody p {
  margin: 0;
}

/* ── Devices ── */
.dv-panel .ui-status,
.dv-kind {
  white-space: nowrap;
}
/* The row menu keeps a fixed width; the name column gives way (390 px: Rename and Disconnect stay reachable). */
.dv-panel .ui-td:last-child,
.dv-panel .ui-th:last-child {
  width: var(--s-12, 3rem);
  padding-inline: var(--s-1);
}
.dv-panel .ui-td--grow {
  min-width: 0;
  overflow-wrap: anywhere;
}
/* Below md: "Counter tablet · Online · seen 1 min ago" under the name (the Status column is hidden). */
.dv-meta__status::before {
  content: '';
  display: inline-block;
  width: 0.5rem;
  height: 0.5rem;
  margin-inline-end: var(--s-1);
  border-radius: 50%;
  vertical-align: 0.05em;
  background: var(--c-line-strong);
}
.dv-meta__status--on::before {
  background: var(--c-ready);
}
.dv-open {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}
.dv-busy {
  margin: var(--s-3) 0 0;
  display: flex;
  align-items: center;
  gap: var(--s-2);
  color: var(--c-muted);
}
.dv-wizard .ui-dialog__body {
  padding-block: var(--s-2);
}
.dv-wizard .ui-wizard {
  box-shadow: none;
  padding: 0;
  max-width: none;
  background: transparent;
}
.dv-wizard .ui-radiocard__preview .ui-icon {
  width: 1.5rem;
  height: 1.5rem;
}

@media (max-width: 599px) {
  .br-step {
    grid-template-columns: auto 1fr;
  }
  .br-step__act {
    grid-column: 2;
    justify-self: start;
  }
  .br-danger .ui-btn {
    width: 100%;
  }
}

}
/* surfaces/site.css */
@layer surfaces {
/* Surface: s- (bellou.io: marketing site, pricing, contact, legal, sign-in, sign-up; experience-v2 §12.5 P1–P5,
   release-v2 P21). Owned by apps/web/src/site. Spacing on the --s-* grid, type on the --fs-* scale, controls from
   ui-* components. Logical properties only, so Arabic mirrors. No inline styles anywhere: the screenshots carry
   their own width/height attributes.

   Colour: Gulf night (founder, 2026-11-08; was Gulf night), bellou.io only. The site reads the --c-site-* roles and the
   --night/--gold/--dune shade scales (tokens.ts). `.s-page` points the product's roles (--c-bg, --c-accent, the
   neutral steps …) at them, so the shared ui-* controls on these pages follow the site palette without a single
   component rule; no client, HQ or guest surface carries .s-page. READY green (--c-ready*) is never remapped. */

/* ── The site palette ────────────────────────────────────────────────────────────────────────────────────── */
.s-page {
  /* Page roles. Aliases (--c-brand*, --c-band, --c-alt*) are re-declared here because a custom property that
     reads another is resolved where it is declared (:root), not where it is used. */
  --c-bg: var(--c-site-bg);
  --c-surface: var(--c-site-surface);
  --c-surface-2: var(--c-site-sunk);
  --c-ink: var(--c-site-ink);
  --c-muted: var(--c-site-muted);
  --c-line: var(--c-site-line);
  --c-line-strong: color-mix(in oklab, var(--c-site-muted) 80%, var(--c-site-surface));
  --brand: var(--c-site-primary);
  --on-brand: var(--c-site-on-primary);
  --c-accent: var(--c-site-primary);
  --c-on-accent: var(--c-site-on-primary);
  --c-accent-hover: var(--c-site-primary-hover);
  --c-accent-press: color-mix(in oklab, var(--c-site-primary-hover) 82%, var(--c-site-ink));
  --c-accent-ink: var(--c-site-primary-ink);
  --c-accent-soft: var(--c-site-primary-soft);
  --c-accent-edge: var(--c-site-primary);
  --c-accent-ring: var(--c-site-primary);
  --c-page-tint: var(--c-site-bg);
  --c-brand: var(--c-accent);
  --c-brand-hover: var(--c-accent-hover);
  --c-brand-press: var(--c-accent-press);
  --c-brand-ink: var(--c-accent-ink);
  --c-brand-soft: var(--c-accent-soft);
  --c-on-brand: var(--c-on-accent);
  --c-band: var(--c-site-bg);
  --c-alt: var(--c-accent);
  --c-on-alt: var(--c-on-accent);
  --c-alt-hover: var(--c-accent-hover);
  --c-alt-press: var(--c-accent-press);
  --c-alt-ink: var(--c-accent-ink);
  --c-alt-soft: var(--c-accent-soft);
  --c-alt-edge: var(--c-accent-edge);
  /* The neutral steps the controls hover and press on, warmed: mixed from the site roles, so both themes follow. */
  --n-0: var(--c-site-surface);
  --n-1: color-mix(in oklab, var(--c-site-sunk) 50%, var(--c-site-surface));
  --n-2: var(--c-site-bg);
  --n-3: color-mix(in oklab, var(--c-site-line) 55%, var(--c-site-surface));
  --n-4: color-mix(in oklab, var(--c-site-line) 80%, var(--c-site-surface));
  --n-5: var(--c-site-line);
  --n-6: var(--c-site-line);
  --n-7: color-mix(in oklab, var(--c-site-muted) 40%, var(--c-site-line));
  --n-8: color-mix(in oklab, var(--c-site-muted) 65%, var(--c-site-line));
  --n-9: color-mix(in oklab, var(--c-site-muted) 85%, var(--c-site-line));
  --n-10: color-mix(in oklab, var(--c-site-muted) 92%, var(--c-site-line));
  --n-11: var(--c-site-muted);
  --n-12: var(--c-site-ink);
  /* Warm shadows: ember-950, never grey. */
  --e-1: 0 1px 2px color-mix(in oklab, var(--night-950) 10%, transparent);
  --e-2:
    0 1px 2px color-mix(in oklab, var(--night-950) 8%, transparent),
    0 0.75rem 2rem -0.25rem color-mix(in oklab, var(--night-900) 16%, transparent);
  --e-3:
    0 2px 4px color-mix(in oklab, var(--night-950) 8%, transparent),
    0 2rem 4.5rem -0.75rem color-mix(in oklab, var(--night-900) 28%, transparent);

  /* The site's own locals. Tints are mixed from the theme-aware roles; the few that need a hand-picked shade per
     theme are set again for dark below. */
  --s-tint-ember: color-mix(in oklab, var(--c-site-primary-soft) 55%, var(--c-site-bg));
  --s-tint-saffron: color-mix(in oklab, var(--c-site-accent-soft) 60%, var(--c-site-bg));
  --s-tint-sand: color-mix(in oklab, var(--c-site-sunk) 65%, var(--c-site-line));
  --s-sec-bg: var(--c-site-bg);
  --s-chip-bg: var(--c-site-accent-soft);
  --s-chip-ink: var(--gold-800);
  --s-chip-dot: var(--c-site-primary);
  /* Light: navy into indigo only; a navy-to-gold blend turns brown on a light page. Dark keeps its gold end. */
  --s-heat: linear-gradient(100deg, var(--night-800) 0%, var(--night-600) 50%, var(--night-500) 100%);
  --s-heat-fill: linear-gradient(135deg, var(--night-500), var(--night-700));
  --s-deep: linear-gradient(135deg, var(--night-900) 0%, var(--night-800) 45%, var(--night-700) 100%);
  --s-deep-ink: #fff;
  --s-deep-muted: var(--night-100);
  --s-deep-hl: var(--gold-300);
  --s-glow-a: color-mix(in oklab, var(--c-site-glow-1) 26%, transparent);
  --s-glow-b: color-mix(in oklab, var(--c-site-glow-2) 34%, transparent);
  --s-ring-warm: color-mix(in oklab, var(--c-site-primary) 30%, var(--c-site-line));

  background: var(--c-bg);
  color: var(--c-ink);
}
:root[data-theme='dark'] .s-page {
  --s-chip-ink: var(--gold-300);
  --s-heat: linear-gradient(100deg, var(--night-400) 0%, var(--night-300) 45%, var(--gold-300) 100%);
  --s-deep: linear-gradient(135deg, var(--night-950) 0%, var(--night-900) 55%, var(--night-800) 100%);
  --s-deep-muted: var(--night-200);
  --s-glow-a: color-mix(in oklab, var(--c-site-glow-1) 30%, transparent);
  --s-glow-b: color-mix(in oklab, var(--c-site-glow-2) 30%, transparent);
  --s-ring-warm: color-mix(in oklab, var(--c-site-primary) 35%, var(--c-site-line));
  --e-2:
    0 1px 2px color-mix(in oklab, #000 40%, transparent),
    0 0.75rem 2rem -0.25rem color-mix(in oklab, #000 50%, transparent), 0 0 0 1px var(--c-site-line);
  --e-3:
    0 2px 4px color-mix(in oklab, #000 40%, transparent),
    0 2rem 4.5rem -0.75rem color-mix(in oklab, #000 60%, transparent), 0 0 0 1px var(--c-site-line);
}
@media (prefers-color-scheme: dark) {
  :root[data-theme='auto'] .s-page {
    --s-chip-ink: var(--gold-300);
    --s-heat: linear-gradient(100deg, var(--night-400) 0%, var(--night-300) 45%, var(--gold-300) 100%);
    --s-deep: linear-gradient(135deg, var(--night-950) 0%, var(--night-900) 55%, var(--night-800) 100%);
    --s-deep-muted: var(--night-200);
    --s-glow-a: color-mix(in oklab, var(--c-site-glow-1) 30%, transparent);
    --s-glow-b: color-mix(in oklab, var(--c-site-glow-2) 30%, transparent);
    --s-ring-warm: color-mix(in oklab, var(--c-site-primary) 35%, var(--c-site-line));
    --e-2:
      0 1px 2px color-mix(in oklab, #000 40%, transparent),
      0 0.75rem 2rem -0.25rem color-mix(in oklab, #000 50%, transparent), 0 0 0 1px var(--c-site-line);
    --e-3:
      0 2px 4px color-mix(in oklab, #000 40%, transparent),
      0 2rem 4.5rem -0.75rem color-mix(in oklab, #000 60%, transparent), 0 0 0 1px var(--c-site-line);
  }
}
html:has(> .s-page) {
  background: var(--c-site-bg);
}
.s-page ::selection {
  background: var(--c-site-accent-soft);
  color: var(--c-site-ink);
}

/* A full-bleed band behind a section in the page column: painted by border-image outset, which never scrolls. */
.s-home > .s-scrub,
.s-home > .s-cardsec,
.s-home > #pricing {
  border-block-start: 0;
  border-image-source: linear-gradient(var(--s-sec-bg), var(--s-sec-bg));
  border-image-slice: 0 fill;
  border-image-width: 0;
  border-image-outset: 0 100vmax;
}

/* ── Focus ring for the site's own links ─────────────────────────────────────────────────────────────────── */
.s-skip:focus-visible,
.s-brand:focus-visible,
.s-nav__link:focus-visible,
.s-foot__link:focus-visible,
.s-toc a:focus-visible,
.s-table-wrap:focus-visible,
.s-main:focus-visible,
.s-focuspage:focus-visible {
  outline: none;
  box-shadow:
    0 0 0 2px var(--c-bg),
    0 0 0 4px var(--c-focus);
}
.s-main:focus,
.s-focuspage:focus {
  outline: none;
}

.s-skip {
  position: absolute;
  inset-inline-start: var(--s-4);
  inset-block-start: calc(-1 * var(--s-16));
  z-index: var(--z-toast);
  padding: var(--s-2) var(--s-4);
  border-radius: var(--r-sm);
  background: var(--c-ink);
  color: var(--c-bg);
  font-weight: 600;
  text-decoration: none;
}
.s-skip:focus {
  inset-block-start: var(--s-2);
}

/* ── The Bellou mark: the ringing line bell (packages/ui/src/pixel-logo.ts); its line and clapper follow the theme.
   Sized in whole multiples of its 16-pixel grid (32 px, 48 px) so every pixel stays square. ──────────────────── */
.s-mark {
  display: inline-block;
  flex: none;
  width: var(--s-8);
  height: var(--s-8);
  line-height: 0;
}
.s-mark svg {
  display: block;
  width: 100%;
  height: 100%;
  image-rendering: pixelated;
}
.s-px-o {
  /* The line: midnight on light, gold on dark (the site's primary in each theme). */
  fill: var(--c-site-primary);
}
.s-px-a {
  fill: var(--c-site-mark-accent);
}
/* The name beside it: BELLOU in the logo's 8-bit letters (pixelWordmarkSvg), at the bell's pixel size. The letters
   take the link's colour; the drop shadow is gold in both themes. */
.s-brand__name {
  display: inline-flex;
  line-height: 0;
}
.s-brand__name svg {
  display: block;
  image-rendering: pixelated;
}
.s-word-sh {
  fill: var(--gold-600);
}
.ui-wizard__logo .s-mark {
  width: var(--s-12);
  height: var(--s-12);
}

/* ── Top bar ─────────────────────────────────────────────────────────────────────────────────────────────── */
.s-bar {
  position: sticky;
  inset-block-start: 0;
  z-index: var(--z-appbar);
  /* Solid, no backdrop-filter: a filter would trap the menu's fixed bottom sheet inside the bar. A hairline of
     heat along the top edge. */
  background:
    linear-gradient(90deg, var(--night-600), var(--night-500) 45%, var(--gold-400)) top / 100% 3px no-repeat,
    var(--c-bg);
  border-block-end: 1px solid var(--c-line);
}
.s-bar__in {
  max-width: calc(var(--w-list) + 2 * var(--s-8));
  min-height: var(--s-16);
  margin-inline: auto;
  padding-inline: var(--s-8);
  display: flex;
  align-items: center;
  gap: var(--s-8);
}
.s-brand {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  min-height: var(--hit-min);
  border-radius: var(--r-sm);
  color: var(--c-ink);
  font-size: var(--fs-18);
  line-height: var(--lh-18);
  font-weight: 600;
  letter-spacing: -0.01em;
  text-decoration: none;
}
.s-nav ul {
  display: flex;
  gap: var(--s-1);
  margin: 0;
  padding: 0;
  list-style: none;
}
.s-nav__link {
  display: inline-flex;
  align-items: center;
  min-height: var(--ctl-h);
  padding-inline: var(--s-3);
  border-radius: var(--r-sm);
  color: var(--c-muted);
  font-size: var(--fs-14);
  font-weight: 500;
  text-decoration: none;
}
.s-nav__link:hover {
  background: var(--s-tint-ember);
  color: var(--c-ink);
}
.s-nav__link[aria-current='page'] {
  color: var(--c-site-primary-ink);
  background: var(--c-site-primary-soft);
}
.s-bar__end {
  margin-inline-start: auto;
  display: flex;
  align-items: center;
  gap: var(--s-2);
}
.s-cta {
  display: inline-flex;
}
.s-menu {
  display: none;
}
@media (max-width: 1023px) {
  .s-nav,
  .s-signin {
    display: none;
  }
  .s-menu {
    display: inline-flex;
  }
}
@media (max-width: 599px) {
  .s-bar__in {
    padding-inline: var(--s-4);
    gap: var(--s-3);
  }
  .s-cta {
    display: none;
  }
}

/* ── Page body and type ──────────────────────────────────────────────────────────────────────────────────── */
.s-main {
  max-width: calc(var(--w-list) + 2 * var(--s-8));
  margin-inline: auto;
  padding-inline: var(--s-8);
}
@media (max-width: 599px) {
  .s-main {
    padding-inline: var(--s-4);
  }
}
.s-display {
  margin: 0;
  font-size: var(--fs-40);
  line-height: var(--lh-40);
  font-weight: 600;
  letter-spacing: -0.02em;
  text-wrap: balance;
}
.s-h2 {
  margin: 0;
  font-size: var(--fs-28);
  line-height: var(--lh-28);
  font-weight: 600;
  letter-spacing: -0.01em;
  text-wrap: balance;
}
.s-h3 {
  margin: 0;
  font-size: var(--fs-18);
  line-height: var(--lh-18);
  font-weight: 600;
}
.s-display:lang(ar),
.s-h2:lang(ar) {
  letter-spacing: 0;
}
.s-display:lang(ar) {
  line-height: calc(var(--lh-40) + var(--s-2));
}
@media (max-width: 599px) {
  .s-display {
    font-size: var(--fs-32);
    line-height: var(--lh-32);
  }
  .s-display:lang(ar) {
    line-height: calc(var(--lh-32) + var(--s-2));
  }
  .s-h2 {
    font-size: var(--fs-24);
    line-height: var(--lh-24);
  }
}
.s-lead {
  margin: 0;
  max-width: 40em;
  color: var(--c-muted);
  font-size: var(--fs-18);
  line-height: var(--lh-18);
  text-wrap: pretty;
}
.s-text {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-16);
  line-height: var(--lh-16);
}
.s-text--muted {
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.s-lead:lang(ar),
.s-text:lang(ar) {
  line-height: calc(var(--lh-16) + var(--s-1));
}
/* Eyebrows are saffron chips with an ember dot. */
.s-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  width: fit-content;
  margin: 0;
  padding: var(--s-1) var(--s-3);
  border-radius: var(--r-pill);
  background: var(--s-chip-bg);
  box-shadow: inset 0 0 0 1px color-mix(in oklab, var(--c-site-accent) 35%, transparent);
  color: var(--s-chip-ink);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
  font-weight: 600;
}
.s-eyebrow::before {
  content: '';
  flex: none;
  width: 0.45rem;
  height: 0.45rem;
  border-radius: var(--r-pill);
  background: var(--s-chip-dot);
  box-shadow: 0 0 0 3px color-mix(in oklab, var(--s-chip-dot) 22%, transparent);
}
.s-eyebrow[hidden] {
  display: none;
}
.s-head {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  max-width: var(--w-main);
}
.s-checks,
.s-ticks {
  margin: 0;
  padding: 0;
  list-style: none;
}
.s-checks {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.s-ticks {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2) var(--s-5);
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.s-ticks li,
.s-checks li {
  display: flex;
  align-items: flex-start;
  gap: var(--s-2);
}
.s-ticks .ui-icon,
.s-checks .ui-icon {
  flex: none;
  width: var(--s-4);
  height: var(--s-4);
  margin-block-start: 2px;
  color: var(--c-site-primary);
}

/* ── Sections ────────────────────────────────────────────────────────────────────────────────────────────── */
.s-sec {
  display: flex;
  flex-direction: column;
  gap: var(--s-8);
  padding-block: var(--s-16);
  border-block-start: 1px solid var(--c-line);
  scroll-margin-block-start: var(--s-16);
}
.s-sec--first {
  position: relative;
  isolation: isolate;
  border-block-start: 0;
  padding-block-start: var(--s-12);
}
/* A page's opening section sits in a warm glow (pricing, contact). */
.s-sec--first::before,
.h-hero::before,
.lg-head::before,
.s-notfound::before {
  content: '';
  position: absolute;
  z-index: -1;
  inset-block-start: calc(-1 * var(--s-16));
  inset-inline-start: calc(-1 * var(--s-16));
  width: min(44rem, 90vw);
  height: 26rem;
  background:
    radial-gradient(closest-side, var(--s-glow-a), transparent) 0 0 / 70% 80% no-repeat,
    radial-gradient(closest-side, var(--s-glow-b), transparent) 100% 30% / 60% 70% no-repeat;
  filter: blur(2rem);
  opacity: 0.85;
  pointer-events: none;
}
@media (max-width: 599px) {
  .s-sec {
    gap: var(--s-6);
    padding-block: var(--s-12);
  }
  .s-sec--first {
    padding-block-start: var(--s-8);
  }
}

/* ── Device frames around the real product screens ──────────────────────────────────────────────────────── */
.s-device {
  margin: 0;
  background: var(--dune-900);
  box-shadow:
    0 0 0 1px color-mix(in oklab, var(--dune-700) 80%, transparent),
    var(--e-3);
}
.s-num {
  font-weight: 600;
  color: var(--c-ink);
}
.s-shot {
  display: block;
  width: 100%;
  height: auto;
  background: var(--c-surface-2);
}
.s-device--phone {
  width: 100%;
  max-width: var(--w-phone);
  padding: var(--s-2);
  border-radius: calc(var(--r-lg) * 2);
}
.s-device--phone .s-shot {
  border-radius: calc(var(--r-lg) * 2 - var(--s-2));
}
.s-device--tablet {
  padding: var(--s-3);
  border-radius: calc(var(--r-lg) + var(--s-2));
}
.s-device--tablet .s-shot {
  border-radius: var(--r-sm);
}
.s-device--tv {
  padding: var(--s-2);
  border-radius: var(--r-md);
}
.s-device--tv .s-shot {
  border-radius: var(--r-xs);
}
.s-caption {
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}

/* ── Features ────────────────────────────────────────────────────────────────────────────────────────────── */
.s-feature {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  padding: var(--s-6);
  border: 1px solid var(--c-line);
  border-radius: var(--r-card);
  background: var(--c-surface);
  box-shadow: var(--e-1);
  transition:
    transform var(--m-base, 0.2s) var(--ease-out, ease),
    box-shadow var(--m-base, 0.2s) var(--ease-out, ease),
    border-color var(--m-base, 0.2s) var(--ease-out, ease);
}
.s-feature:hover {
  border-color: var(--s-ring-warm);
  box-shadow: var(--e-2);
  transform: translateY(-2px);
}
.s-feature .s-text {
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
@media (max-width: 599px) {
  .s-feature {
    padding: var(--s-5);
  }
}

/* ── Plans and the comparison table ──────────────────────────────────────────────────────────────────────── */
.s-plans {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--s-4);
  margin: 0;
  padding: 0;
  list-style: none;
}
/* Each tier carries its own shade along the top: sand, saffron, ember, deep ember.
   The cards share the row's five tracks (top, button, limits, "Everything in…", features) through subgrid, so each
   button and list starts at the same height whatever the text above it. */
.s-plan {
  --s-tier: var(--dune-300);
  position: relative;
  display: grid;
  grid-row: span 5;
  grid-template-rows: subgrid;
  align-content: start;
  row-gap: var(--s-4);
  padding: var(--s-6);
  padding-block-start: calc(var(--s-6) + var(--s-1));
  overflow: hidden;
  border: 1px solid var(--c-line);
  border-radius: var(--r-card);
  background:
    linear-gradient(var(--s-tier), var(--s-tier)) top / 100% var(--s-1) no-repeat,
    linear-gradient(color-mix(in oklab, var(--s-tier) 9%, var(--c-surface)), var(--c-surface) 9rem),
    var(--c-surface);
  box-shadow: var(--e-1);
}
.s-plan[data-plan='branch'] {
  --s-tier: var(--gold-400);
}
.s-plan[data-plan='business'] {
  --s-tier: var(--night-500);
}
.s-plan[data-plan='chain'] {
  --s-tier: var(--night-800);
}
:root[data-theme='dark'] .s-plan[data-plan='chain'] {
  --s-tier: var(--night-300);
}
@media (prefers-color-scheme: dark) {
  :root[data-theme='auto'] .s-plan[data-plan='chain'] {
    --s-tier: var(--night-300);
  }
}
.s-plan--pick {
  border-color: var(--c-accent-edge);
  box-shadow:
    0 0 0 1px var(--c-accent-edge),
    0 1.5rem 3rem -1rem color-mix(in oklab, var(--c-site-primary) 35%, transparent);
}
.s-plan--pick .s-plan__price {
  background: var(--s-heat);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.s-plan__top {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
}
.s-plan__name {
  margin: 0;
  color: var(--c-site-primary-ink);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
  font-weight: 600;
}
.s-plan__price {
  margin: 0;
  font-size: var(--fs-24);
  line-height: var(--lh-24);
  font-weight: 600;
}
.s-plan__note {
  margin: 0;
  min-height: calc(2 * var(--lh-14));
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.s-plan__limits {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.s-plan__limits li {
  padding-block: var(--s-2);
  border-block-start: 1px solid var(--c-line);
}
.s-plan__limits li:last-child {
  border-block-end: 1px solid var(--c-line);
}
.s-plan__inc {
  margin: 0;
  color: var(--s-chip-ink);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
  font-weight: 600;
}
/* "Unlimited pagers on every plan": its own saffron strip above the cards, and the same mark on each card. */
.s-pagers {
  display: flex;
  align-items: center;
  gap: var(--s-4) var(--s-6);
  margin-block-end: var(--s-6);
  padding: var(--s-4) var(--s-6);
  border: 1px solid color-mix(in oklab, var(--gold-400) 55%, var(--c-site-line));
  border-radius: var(--r-card);
  background:
    radial-gradient(closest-side, color-mix(in oklab, var(--gold-300) 35%, transparent), transparent) 0 50% / 16rem 100% no-repeat,
    color-mix(in oklab, var(--gold-400) 16%, var(--c-site-bg));
}
.s-pagers__copy {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
  min-width: 0;
}
.s-pagers__title {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  margin: 0;
  color: var(--s-chip-ink);
  font-size: var(--fs-20);
  line-height: var(--lh-20);
  font-weight: 700;
  text-wrap: balance;
}
.s-pagers__sub {
  margin: 0;
  max-width: var(--w-main);
  color: var(--c-site-ink);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.s-inf {
  flex: none;
  width: 1.25em;
  height: 1.25em;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.25;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.s-plan__limits li.s-plan__pagers {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  margin-block-end: var(--s-1);
  padding: var(--s-2) var(--s-3);
  border: 1px solid color-mix(in oklab, var(--gold-400) 60%, transparent);
  border-radius: var(--r-pill);
  background: color-mix(in oklab, var(--gold-400) 24%, var(--c-surface));
  color: var(--s-chip-ink);
  font-weight: 600;
}
.s-cell--pagers {
  color: var(--s-chip-ink);
  font-weight: 600;
}
.s-cell--pagers .s-inf {
  vertical-align: -0.3em;
  margin-inline-end: var(--s-1);
}
@media (max-width: 599px) {
  .s-pagers {
    flex-direction: column;
    align-items: flex-start;
    padding: var(--s-4);
  }
  .s-pagers__title {
    font-size: var(--fs-16);
    line-height: var(--lh-16);
  }
}
.s-plans__foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3) var(--s-6);
}
@media (max-width: 1023px) {
  .s-plans {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 599px) {
  .s-plans {
    grid-template-columns: minmax(0, 1fr);
  }
  .s-plan__note {
    min-height: 0;
  }
}
.s-invoice {
  max-width: var(--w-main);
}

.s-table-wrap {
  /* Positioned, so the cells' visually hidden labels (absolute) stay inside the scroller, not the page. */
  position: relative;
  overflow-x: auto;
  border: 1px solid var(--c-line);
  border-radius: var(--r-card);
  background: var(--c-surface);
  box-shadow: var(--e-1);
}
.s-table {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.s-table th,
.s-table td {
  padding: var(--s-3) var(--s-4);
  border-block-start: 1px solid var(--c-line);
  text-align: center;
  font-weight: 400;
}
.s-table thead th {
  border-block-start: 0;
  border-block-end: 2px solid var(--s-ring-warm);
  background: var(--s-tint-ember);
  color: var(--c-site-primary-ink);
  font-weight: 600;
}
.s-table thead th.s-table__feat {
  color: var(--c-ink);
}
.s-table th[scope='row'],
.s-table .s-table__feat {
  text-align: start;
}
.s-table tbody th[scope='row'] {
  position: sticky;
  inset-inline-start: 0;
  background: var(--c-surface);
}
.s-table__group th {
  padding-block: var(--s-2);
  background: var(--s-tint-saffron);
  color: var(--s-chip-ink);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
  font-weight: 600;
  text-align: start;
}
.s-cell {
  display: inline-flex;
  vertical-align: middle;
}
.s-cell--yes .ui-icon {
  width: var(--s-5);
  height: var(--s-5);
  color: var(--c-site-primary);
}
.s-cell--no {
  color: var(--c-muted);
}

/* ── FAQ and the closing band ────────────────────────────────────────────────────────────────────────────── */
.s-faqsec {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
  gap: var(--s-12);
  align-items: start;
}
.s-faq__a {
  margin: 0;
  color: var(--c-muted);
}
.s-faq__more {
  margin: var(--s-4) 0 0;
}
@media (max-width: 1023px) {
  .s-faqsec {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--s-6);
  }
}
.s-band {
  padding-block-end: var(--s-16);
}
/* The closing band: deep ember with saffron light, the same in spirit in both themes. On it, anything that reads
   the site's primary (a highlighted word) turns saffron, so it stays readable on the ember. */
.s-band__in {
  --c-site-primary: var(--gold-300);
  --c-site-primary-ink: var(--gold-200);
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-6) var(--s-10);
  padding: var(--s-12) var(--s-10);
  border-radius: calc(var(--r-lg) * 1.5);
  background: var(--s-deep);
  color: var(--s-deep-ink);
  box-shadow: var(--e-3);
}
.s-band__in::before,
.s-band__in::after {
  content: '';
  position: absolute;
  z-index: -1;
  border-radius: var(--r-pill);
  pointer-events: none;
}
.s-band__in::before {
  inset-block-start: -40%;
  inset-inline-end: -8%;
  width: 26rem;
  height: 26rem;
  background: radial-gradient(
    closest-side,
    color-mix(in oklab, var(--gold-400) 55%, transparent),
    transparent
  );
}
.s-band__in::after {
  inset-block-end: -55%;
  inset-inline-start: 20%;
  width: 30rem;
  height: 22rem;
  background: radial-gradient(
    closest-side,
    color-mix(in oklab, var(--night-500) 50%, transparent),
    transparent
  );
}
.s-band__copy {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  max-width: var(--w-main);
}
.s-band .s-h2 {
  color: var(--s-deep-ink);
}
.s-band .s-lead {
  color: var(--s-deep-muted);
}
.s-band .ui-btn--secondary,
.s-band .ui-btn--primary {
  border-color: transparent;
  background: var(--gold-400);
  color: var(--dune-900);
  box-shadow: 0 0.5rem 1.5rem -0.5rem color-mix(in oklab, var(--gold-500) 70%, transparent);
}
.s-band .ui-btn--secondary:hover,
.s-band .ui-btn--primary:hover {
  background: var(--gold-300);
}
.s-band .ui-btn--secondary:active,
.s-band .ui-btn--primary:active {
  background: var(--gold-500);
}
.s-band .ui-btn:focus-visible {
  box-shadow:
    0 0 0 2px var(--night-900),
    0 0 0 4px var(--gold-200);
}
@media (max-width: 599px) {
  .s-band__in {
    padding: var(--s-8) var(--s-6);
  }
  .s-band__act,
  .s-band__act .ui-btn {
    width: 100%;
  }
}

/* ── Contact ─────────────────────────────────────────────────────────────────────────────────────────────── */
.s-contact {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: var(--s-12);
  align-items: start;
}
.s-contact__intro {
  display: flex;
  flex-direction: column;
  gap: var(--s-6);
}
.s-contact__card {
  position: relative;
  overflow: hidden;
  padding: var(--s-8);
  border: 1px solid var(--c-line);
  border-radius: calc(var(--r-card) + var(--s-1));
  background:
    linear-gradient(90deg, var(--night-600), var(--night-500) 50%, var(--gold-400)) top / 100% var(--s-1)
      no-repeat,
    var(--c-surface);
  box-shadow: var(--e-3);
}
.s-contact__mail {
  display: flex;
  align-items: center;
  gap: var(--s-2);
}
.s-contact__mail .ui-icon {
  flex: none;
  color: var(--c-site-primary);
}
.s-next__title {
  margin-block-end: calc(-1 * var(--s-3));
}
.s-next {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: var(--fs-16);
  line-height: var(--lh-16);
}
.s-next li {
  display: flex;
  align-items: flex-start;
  gap: var(--s-3);
}
.s-next__n {
  display: inline-grid;
  flex: none;
  place-items: center;
  width: var(--s-6);
  height: var(--s-6);
  border-radius: var(--r-pill);
  background: var(--s-heat-fill);
  color: #fff;
  font-size: var(--fs-13);
  font-weight: 600;
}
.s-form {
  display: flex;
  flex-direction: column;
  gap: var(--s-5);
}
.s-form__pair {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--s-5) var(--s-4);
}
.s-form__privacy {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.s-form__status:empty {
  display: none;
}
.s-done {
  padding-block: var(--s-8);
}
.s-done:focus {
  outline: none;
}
@media (max-width: 1023px) {
  .s-contact {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--s-8);
  }
}
@media (max-width: 599px) {
  .s-contact__card {
    padding: var(--s-5);
  }
  .s-form__pair {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ── Footer ──────────────────────────────────────────────────────────────────────────────────────────────── */
/* The footer is espresso in both themes (sand-900), lit by a saffron glow and a heat hairline. */
.s-foot {
  --c-ink: var(--dune-50);
  --c-muted: var(--dune-300);
  --c-line: color-mix(in oklab, var(--dune-600) 70%, var(--dune-900));
  --c-focus: var(--dune-50);
  --c-bg: var(--dune-900);
  position: relative;
  overflow: hidden;
  isolation: isolate;
  border-block-start: 0;
  background:
    linear-gradient(90deg, var(--night-600), var(--night-500) 45%, var(--gold-400)) top / 100% 3px no-repeat,
    radial-gradient(
      60rem 22rem at 85% 0%,
      color-mix(in oklab, var(--night-700) 30%, transparent),
      transparent
    ),
    radial-gradient(
      40rem 18rem at 5% 100%,
      color-mix(in oklab, var(--night-600) 30%, transparent),
      transparent
    ),
    var(--dune-900);
  color: var(--dune-50);
}
.s-foot .s-brand {
  color: var(--dune-50);
}
/* The footer is dark in both themes: the mark takes its dark-background colours there. */
.s-foot .s-px-o {
  fill: var(--gold-400);
}
.s-foot .s-px-a {
  fill: var(--dune-50);
}
.s-foot__title {
  color: var(--gold-300);
}
.s-foot__in {
  max-width: calc(var(--w-list) + 2 * var(--s-8));
  margin-inline: auto;
  padding-inline: var(--s-8);
}
.s-foot__in {
  display: grid;
  grid-template-columns: minmax(0, 2fr) repeat(3, minmax(0, 1fr));
  gap: var(--s-8);
  padding-block: var(--s-12);
}
.s-foot__brand {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--s-2);
}
.s-foot__note {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.s-foot__title {
  margin: 0 0 var(--s-3);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
  font-weight: 600;
}
.s-foot__col ul,
.s-foot__row {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
  margin: 0;
  padding: 0;
  list-style: none;
}
.s-foot__link {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  min-height: var(--s-8);
  border-radius: var(--r-sm);
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
  text-decoration: none;
}
.s-foot__link:hover,
.s-foot__link[aria-current='page'] {
  color: var(--c-ink);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.s-foot__link .ui-icon {
  width: var(--s-4);
  height: var(--s-4);
}
.s-foot__base {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
  /* The divider spans the content column only: margins, not padding, so the border lines up with the columns. */
  max-width: var(--w-list);
  margin-inline: max(var(--s-8), calc((100% - var(--w-list)) / 2));
  padding-block: var(--s-4);
  padding-inline: 0;
  border-block-start: 1px solid var(--c-line);
}
.s-foot--slim {
  --c-ink: var(--c-site-ink);
  --c-muted: var(--c-site-muted);
  --c-line: var(--c-site-line);
  --c-focus: var(--c-site-ink);
  --c-bg: var(--c-site-bg);
  background: transparent;
  color: var(--c-site-ink);
}
.s-foot__row {
  flex-direction: row;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--s-1) var(--s-5);
  padding: var(--s-4);
}
@media (max-width: 1023px) {
  .s-foot__in {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .s-foot__brand {
    grid-column: 1 / -1;
  }
}
@media (max-width: 599px) {
  .s-foot__in {
    padding-inline: var(--s-4);
  }
  .s-foot__base {
    margin-inline: var(--s-4);
  }
  .s-foot__in {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--s-6);
    padding-block: var(--s-10);
  }
  .s-foot__link {
    min-height: var(--hit-min);
  }
}

/* ── Focus pages (sign in to your café, sign-up, status): the FocusWizard template ───────────────────────── */
.s-focuspage {
  position: relative;
  isolation: isolate;
  display: block;
  padding-inline: var(--s-4);
}
.s-focuspage::before {
  content: '';
  position: absolute;
  z-index: -1;
  inset-block-start: 0;
  inset-inline: 0;
  height: 32rem;
  background:
    radial-gradient(32rem 18rem at 30% 10%, var(--s-glow-a), transparent),
    radial-gradient(28rem 16rem at 72% 25%, var(--s-glow-b), transparent);
  opacity: 0.7;
  pointer-events: none;
}
.s-focuspage .ui-tpl--focus {
  min-height: calc(100dvh - 2 * var(--s-16) - var(--s-12));
}
.s-focuspage .ui-tpl__foot {
  text-align: center;
}
.s-focuspage .ui-tpl__foot p {
  margin: 0;
}
.s-wiz .ui-wizard__actions--done {
  flex-direction: column;
  align-items: stretch;
}
.s-rule {
  margin-block: var(--s-6) var(--s-2);
  border-block-start: 1px solid var(--c-line);
}
.s-stack {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
}
@media (max-width: 599px) {
  .s-focuspage {
    padding-inline: 0;
  }
  .s-focuspage .ui-tpl--focus {
    min-height: 0;
  }
}

/* ── Sign-up steps ───────────────────────────────────────────────────────────────────────────────────────── */
.su-step {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}
.su-step__title {
  margin: 0;
  font-size: var(--fs-16);
  line-height: var(--lh-16);
  font-weight: 600;
}
.su-step__title:focus {
  outline: none;
}
.su-slug:empty {
  display: none;
}
.su-slug__line {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  margin: 0;
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.su-slug__line .ui-icon {
  flex: none;
  width: var(--s-4);
  height: var(--s-4);
}
.su-slug__line--ok {
  color: var(--c-ready-ink);
}
.su-slug__line--bad {
  color: var(--c-danger);
}
.su-slug__line--checking {
  color: var(--c-muted);
}
.su-slug__try {
  margin-block-start: var(--s-2);
}
.su-free {
  display: flex;
  align-items: flex-start;
  gap: var(--s-2);
  margin: var(--s-4) 0 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.su-free .ui-icon {
  flex: none;
  width: var(--s-4);
  height: var(--s-4);
}

/* ── Legal pages (privacy, terms) ────────────────────────────────────────────────────────────────────────── */
.lg-root {
  display: grid;
  grid-template-columns: var(--w-subnav) minmax(0, var(--w-main));
  gap: var(--s-12);
  align-items: start;
  padding-block: var(--s-12) var(--s-16);
}
.lg-head {
  position: relative;
  isolation: isolate;
  grid-column: 1 / -1;
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  max-width: var(--w-main);
}
.lg-meta {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.s-toc {
  position: sticky;
  inset-block-start: calc(var(--s-16) + var(--s-6));
}
.s-toc ol {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
  margin: var(--s-3) 0 0;
  padding: 0;
  list-style: none;
}
.s-toc a {
  display: block;
  padding: var(--s-1) var(--s-3);
  border-inline-start: 2px solid var(--c-line);
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
  text-decoration: none;
}
.s-toc a:hover {
  border-inline-start-color: var(--c-site-primary);
  background: var(--s-tint-ember);
  color: var(--c-ink);
}
.lg-doc {
  display: flex;
  flex-direction: column;
  gap: var(--s-10);
}
.lg-sec {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  scroll-margin-block-start: calc(var(--s-16) + var(--s-6));
}
.lg-sec h2 {
  margin: 0;
  font-size: var(--fs-20);
  line-height: var(--lh-20);
  font-weight: 600;
}
.lg-sec p,
.lg-sec li {
  margin: 0;
  font-size: var(--fs-16);
  line-height: var(--lh-16);
}
.lg-sec p:lang(ar),
.lg-sec li:lang(ar) {
  line-height: calc(var(--lh-16) + var(--s-2));
}
.lg-sec ul {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  margin: 0;
  padding-inline-start: var(--s-6);
}
@media (max-width: 1023px) {
  .lg-root {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--s-8);
  }
  .s-toc {
    position: static;
    padding: var(--s-4) var(--s-5);
    border: 1px solid var(--c-line);
    border-radius: var(--r-card);
    background: var(--c-surface);
  }
}
@media (max-width: 599px) {
  .lg-root {
    padding-block: var(--s-8) var(--s-12);
  }
}

/* ── Page not found on bellou.io ── */
.s-notfound {
  position: relative;
  isolation: isolate;
  display: grid;
  place-items: center;
  min-height: 60dvh;
  text-align: center;
}
.s-notfound::before {
  inset-block-start: 10%;
  inset-inline: 0;
  margin-inline: auto;
}
.s-notfound .ui-state__icon {
  color: var(--c-site-primary);
}
.s-notfound .ui-state__actions {
  align-items: center;
  column-gap: var(--s-4);
}

}
/* surfaces/site-home.css */
@layer surfaces {
/* bellou.io home (apps/web/src/site/site-view.ts renderSite; the scroll story is site/home-motion.ts). Colours come
   only from tokens, so the page follows light and dark (the bar's switch, or the device). Headlines use --f-site
   (Bricolage Grotesque; Arabic falls through to Rubik).

   Two layouts:
   - The static one below: every screen, and wide screens without script or with reduced motion. Complete on its own.
   - The pinned one: wide screens with script and motion allowed (the media query at the end). The hero fills the
     screen and its stage waits at half size for home-motion.ts to grow it; the story section fills the screen; the
     cards stick and stack. */

/* ── Hero ────────────────────────────────────────────────────────────────────────────────────────────────── */
.s-hero {
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-12);
  padding-block: var(--s-16);
  text-align: center;
}
/* Warm light behind the headline: an ember glow and a saffron one. */
.s-hero::before {
  content: '';
  position: absolute;
  z-index: -1;
  inset-block-start: calc(-1 * var(--s-8));
  inset-inline: 0;
  height: min(46rem, 100%);
  background:
    radial-gradient(closest-side, var(--s-glow-a), transparent) 18% 8% / 58% 62% no-repeat,
    radial-gradient(closest-side, var(--s-glow-b), transparent) 86% 18% / 50% 55% no-repeat,
    radial-gradient(closest-side, color-mix(in oklab, var(--s-glow-a) 60%, transparent), transparent) 50%
      70% / 70% 40% no-repeat;
  filter: blur(1.5rem);
  pointer-events: none;
}
.s-hero__head {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-5);
}
.s-hero__title {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0 0.22em;
  margin: 0;
  font-family: var(--f-site);
  font-size: clamp(3rem, 8.5vw, 8rem);
  line-height: 0.92;
  font-weight: 800;
  letter-spacing: -0.045em;
}
.s-hero__title:lang(ar) {
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: 0;
}
.s-hero__title span {
  display: inline-block;
}
/* The headline's second half in the ember→saffron heat (large type only: the light end is 3:1 on the page). */
.s-hero__b {
  background: var(--s-heat);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
  padding-block-end: 0.06em;
}
@media (forced-colors: active) {
  .s-hero__b {
    background: none;
    color: CanvasText;
  }
}
.s-hero .s-lead {
  max-width: 34em;
}
.s-ctas {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--s-3);
  padding-block-start: var(--s-2);
}
.s-hero__stage {
  width: 100%;
  max-width: 60rem;
}
@media (max-width: 599px) {
  .s-hero {
    gap: var(--s-10);
    padding-block: var(--s-10) var(--s-12);
  }
  .s-ctas {
    width: 100%;
  }
  .s-ctas > .ui-btn {
    flex: 1 1 auto;
  }
}

/* The stage: a guest's order page, drawn in the page's own tokens. Sizes follow the stage (container units), so it
   reads the same as a card, at half the screen, or filling it. */
.s-stage {
  position: relative;
  container-type: size;
  overflow: hidden;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: calc(var(--r-lg) * 2);
  background:
    radial-gradient(70cqw 60cqh at 100% 0%, var(--s-tint-saffron), transparent),
    radial-gradient(60cqw 60cqh at 0% 100%, var(--s-tint-ember), transparent), var(--c-surface);
  box-shadow:
    0 0 0 1px var(--s-ring-warm),
    var(--e-3),
    0 3rem 6rem -2rem color-mix(in oklab, var(--c-site-primary) 30%, transparent);
  text-align: start;
}
.s-stage__layer {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 6cqmin;
}
.s-stage__ready {
  opacity: 0;
  background: var(--c-ready);
  color: #fff;
}
.s-wp {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: 6cqmin;
  align-items: center;
  width: min(100%, 160cqh);
}
.s-wp__main {
  display: flex;
  flex-direction: column;
  gap: 2.4cqmin;
}
.s-wp__cafe {
  display: flex;
  align-items: center;
  gap: 2cqmin;
  margin: 0;
  font-size: 3.4cqmin;
  font-weight: 600;
}
.s-wp__tile {
  display: grid;
  place-items: center;
  width: 2.4em;
  height: 2.4em;
  border-radius: 0.6em;
  background: var(--s-heat-fill);
  color: #fff;
  font-family: var(--f-site);
  font-weight: 800;
}
.s-wp__label {
  margin: 0;
  color: var(--c-muted);
  font-size: 2.2cqmin;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.s-wp__label:lang(ar) {
  letter-spacing: 0;
}
.s-wp__n,
.s-ready__n {
  margin: 0;
  font-family: var(--f-site);
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}
.s-wp__n {
  font-size: 34cqmin;
  line-height: 0.85;
}
.s-wp__card {
  display: flex;
  flex-direction: column;
  gap: 2.4cqmin;
  padding: 4cqmin;
  border: 1px solid var(--c-line);
  border-radius: 4cqmin;
  background: color-mix(in oklab, var(--c-site-sunk) 70%, var(--c-surface));
  box-shadow: var(--e-2);
  font-size: 2.6cqmin;
}
.s-wp__steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.4cqmin;
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--c-muted);
  font-size: 2cqmin;
}
.s-wp__steps li::before {
  content: '';
  display: block;
  height: 1cqmin;
  margin-block-end: 1cqmin;
  border-radius: var(--r-pill);
  background: var(--c-line);
}
.s-wp__steps .is-done::before {
  background: linear-gradient(90deg, var(--night-600), var(--gold-400));
}
.s-wp__status {
  margin: 0;
  font-size: 3.2cqmin;
  font-weight: 600;
}
.s-wp__items {
  margin: 0;
  color: var(--c-muted);
}
.s-wp__ring {
  display: inline-flex;
  align-items: center;
  gap: 1.4cqmin;
  width: fit-content;
  margin: 0;
  padding: 1.4cqmin 2.4cqmin;
  border-radius: var(--r-pill);
  background: var(--c-ready-soft);
  color: var(--c-ready-ink);
  font-weight: 600;
}
.s-wp__ring .ui-icon {
  width: 1.2em;
  height: 1.2em;
}
.s-ready {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2cqmin;
  text-align: center;
}
.s-ready__word {
  margin: 0;
  font-family: var(--f-site);
  font-size: 8cqmin;
  font-weight: 800;
  letter-spacing: -0.03em;
}
.s-ready__n {
  font-size: 40cqmin;
  line-height: 0.85;
}
.s-ready__where {
  margin: 0;
  font-size: 3.4cqmin;
  opacity: 0.88;
}
@media (max-width: 599px) {
  .s-stage {
    aspect-ratio: 4 / 5;
    border-radius: var(--r-dialog);
  }
  .s-wp {
    grid-template-columns: minmax(0, 1fr);
    gap: 5cqmin;
  }
  .s-wp__cafe {
    font-size: 4.6cqmin;
  }
  .s-wp__label,
  .s-wp__steps {
    font-size: 3.2cqmin;
  }
  .s-wp__n {
    font-size: 40cqmin;
  }
  .s-wp__card {
    font-size: 3.8cqmin;
  }
  .s-wp__status {
    font-size: 4.4cqmin;
  }
}

/* ── The counter story ───────────────────────────────────────────────────────────────────────────────────── */
.s-scrub {
  --s-sec-bg: var(--s-tint-sand);
  padding-block: calc(var(--s-16) * 1.5);
  border-block-start: 1px solid var(--c-line);
}
.s-scrub__in {
  display: flex;
  flex-direction: column;
  gap: var(--s-8);
}
.s-scrub__text {
  max-width: 21em;
  margin: 0;
  font-family: var(--f-site);
  font-size: clamp(1.75rem, 4.2vw, 3.75rem);
  line-height: 1.12;
  font-weight: 600;
  letter-spacing: -0.025em;
}
.s-scrub__text:lang(ar) {
  line-height: 1.55;
  letter-spacing: 0;
}
/* The highlighted phrases: ember ink over a saffron marker stroke. */
.s-scrub__hl {
  color: var(--c-site-primary-ink);
  background: linear-gradient(
    transparent 62%,
    color-mix(in oklab, var(--c-site-accent) 38%, transparent) 62%,
    color-mix(in oklab, var(--c-site-accent) 38%, transparent) 92%,
    transparent 92%
  );
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}
.s-scrub__w {
  display: inline-block;
  white-space: nowrap;
}
.s-scrub__note {
  margin: 0;
  color: var(--c-muted);
  font-size: clamp(1.25rem, 2.6vw, 2.25rem);
  line-height: 1.4;
  font-weight: 600;
}

/* ── Cards: one per part of the counter ──────────────────────────────────────────────────────────────────── */
.s-cardsec {
  --s-sec-bg: var(--s-tint-ember);
}
/* The home page's sections are separated by their bands, not by rules. */
.s-home > .s-sec {
  border-block-start: 0;
}
.s-home > #pricing {
  --s-sec-bg: var(--s-tint-saffron);
}
.s-cards {
  display: flex;
  flex-direction: column;
  gap: var(--s-6);
  margin: 0;
  padding: 0;
  list-style: none;
}
.s-card__in {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: var(--s-10);
  align-items: center;
  padding: var(--s-10);
  border: 1px solid var(--c-line);
  border-radius: calc(var(--r-lg) * 2);
  background: var(--c-surface);
  box-shadow: var(--e-3);
  transform-origin: 50% 0;
}
/* As the next card covers this one, home-motion.ts fades it toward the page (--s-dim), in either theme. */
.s-card__in {
  --s-dim: 0;
  position: relative;
}
.s-card__in::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: var(--s-sec-bg);
  opacity: var(--s-dim);
  pointer-events: none;
}
.s-card:nth-child(even) .s-card__in {
  background: color-mix(in oklab, var(--c-site-accent-soft) 35%, var(--c-surface));
}
.s-card__copy {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  min-width: 0;
}
.s-card__who {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  margin: 0;
  color: var(--c-site-primary-ink);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
  font-weight: 600;
}
.s-card__n {
  display: inline-grid;
  place-items: center;
  width: var(--s-6);
  height: var(--s-6);
  border-radius: var(--r-pill);
  background: var(--s-heat-fill);
  color: #fff;
  font-size: var(--fs-13);
  font-variant-numeric: tabular-nums;
}
.s-card__title {
  margin: 0;
  font-family: var(--f-site);
  font-size: clamp(1.6rem, 3vw, 2.5rem);
  line-height: 1.05;
  font-weight: 800;
  letter-spacing: -0.03em;
  text-wrap: balance;
}
.s-card__title:lang(ar) {
  line-height: 1.35;
  font-weight: 700;
  letter-spacing: 0;
}
.s-card__media {
  display: grid;
  place-items: center;
  min-width: 0;
}
.s-card__phone {
  max-width: calc(var(--w-phone) - var(--s-10));
}
.s-pair {
  position: relative;
  width: 100%;
  padding-block-end: var(--s-10);
  padding-inline-end: var(--s-16);
}
.s-pair__phone {
  position: absolute;
  inset-block-end: 0;
  inset-inline-end: 0;
  width: 30%;
}
.s-twins {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--s-6);
  align-items: start;
  width: 100%;
  max-width: 32rem;
}
.s-twins__ar {
  margin-block-start: var(--s-10);
}
.s-bubbles {
  display: grid;
  gap: var(--s-3);
  width: 100%;
  max-width: 28rem;
}
.s-bubble {
  justify-self: start;
  max-width: 92%;
  padding: var(--s-3) var(--s-4);
  border: 1px solid var(--c-line);
  border-radius: var(--r-dialog);
  border-end-start-radius: var(--r-xs);
  background: var(--c-surface);
  box-shadow: var(--e-1);
}
.s-bubble:nth-child(2) {
  justify-self: end;
  border-end-start-radius: var(--r-dialog);
  border-end-end-radius: var(--r-xs);
}
.s-bubble p {
  margin: 0;
}
.s-bubble__from {
  margin-block-end: var(--s-1);
  color: var(--c-ready-ink);
  font-size: var(--fs-13);
  font-weight: 600;
}
.s-bubble__meta {
  margin-block-start: var(--s-1);
  color: var(--c-muted);
  font-size: var(--fs-12);
}
@media (max-width: 1023px) {
  .s-card__in {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--s-8);
  }
}
@media (max-width: 599px) {
  .s-card__in {
    padding: var(--s-5);
    border-radius: var(--r-dialog);
  }
  /* Too narrow to overlap: the TV, then the phone below it. */
  .s-pair {
    display: grid;
    gap: var(--s-4);
    padding: 0;
  }
  .s-pair__phone {
    position: static;
    width: 48%;
    margin-inline: auto;
  }
  .s-twins {
    gap: var(--s-3);
  }
  .s-twins__ar {
    margin-block-start: var(--s-6);
  }
}

/* ── Bento: the smaller things ───────────────────────────────────────────────────────────────────────────── */
.s-bento {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--s-4);
  margin: 0;
  padding: 0;
  list-style: none;
}
.s-bento > :first-child,
.s-bento > :last-child {
  grid-column: span 2;
}
@media (max-width: 1023px) {
  .s-bento {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .s-bento > :first-child,
  .s-bento > :last-child {
    grid-column: auto;
  }
}
@media (max-width: 599px) {
  .s-bento {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ── The bar's switches ──────────────────────────────────────────────────────────────────────────────────── */
.s-switches {
  display: inline-flex;
  align-items: center;
  gap: var(--s-1);
}
.s-themeswitch__sun,
.s-themeswitch[aria-pressed='true'] .s-themeswitch__moon {
  display: none;
}
.s-themeswitch[aria-pressed='true'] .s-themeswitch__sun {
  display: inline-block;
}
@media (max-width: 599px) {
  .s-langswitch {
    padding-inline: var(--s-2);
  }
}

/* ── Smooth scrolling (Lenis adds these classes to <html>) ───────────────────────────────────────────────── */
html.lenis,
html.lenis body {
  height: auto;
}
html.lenis.lenis-smooth {
  scroll-behavior: auto;
}
html.lenis.lenis-stopped {
  overflow: clip;
}

/* ── The pinned layout (every width: phones get the desktop story too) ───────────────────────────────────────────────────────────────────────────────────── */
@media (prefers-reduced-motion: no-preference) and (scripting: enabled) {
  .s-home {
    /* The stage spans the whole window, wider than the page column; nothing may scroll sideways. */
    overflow-x: clip;
  }
  .s-home .s-hero {
    height: 100vh;
    height: 100svh;
    justify-content: flex-start;
    padding-block: var(--s-12) 0;
  }
  .s-home .s-hero__stage {
    position: absolute;
    inset-block: 0;
    inset-inline: calc(50% - 50vw);
    z-index: 3;
    display: grid;
    place-items: center;
    width: auto;
    max-width: none;
    pointer-events: none;
  }
  /* Where home-motion.ts starts it: half size, below the headline. */
  .s-home .s-stage {
    width: 100vw;
    height: 100vh;
    height: 100svh;
    aspect-ratio: auto;
    border-radius: calc(var(--r-lg) * 3);
    transform: translateY(24%) scale(0.5);
  }
  .s-home .s-scrub {
    display: grid;
    align-content: center;
    min-height: 100vh;
    min-height: 100svh;
  }
  .s-home .s-card {
    position: sticky;
    inset-block-start: calc(var(--s-16) + var(--s-8));
  }
  .s-home .s-card:nth-child(2) {
    inset-block-start: calc(var(--s-16) + var(--s-8) + var(--s-5));
  }
  .s-home .s-card:nth-child(3) {
    inset-block-start: calc(var(--s-16) + var(--s-8) + var(--s-5) * 2);
  }
  .s-home .s-card:nth-child(4) {
    inset-block-start: calc(var(--s-16) + var(--s-8) + var(--s-5) * 3);
  }
  .s-home .s-card:nth-child(5) {
    inset-block-start: calc(var(--s-16) + var(--s-8) + var(--s-5) * 4);
  }
  .s-home .s-cardsec {
    padding-block-end: calc(var(--s-16) * 2);
  }
}

}
/* surfaces/site-process.css */
@layer surfaces {
/* bellou.io home: "How it works" (apps/web/src/site/process.ts; the motion is site/process-motion.ts). Four steps,
   each with a hand-drawn SVG scene coloured only from tokens: the theme-independent Gulf night shades for
   things (devices, cups, paper, confetti) and the theme-aware --c-site-* roles for surfaces and text. READY is
   --c-ready, never branded.

   Three layouts:
   - Narrow, static (< 1024 px, no script or reduced motion): a vertical timeline down the inline-start side.
   - Wide, static: the four steps in a row, joined by a line across.
   - Live (script and motion allowed), every width: the section pins and the line fills from one step to the next.
     Wide: the steps list on the inline-start side, the active scene in a panel beside it. Narrow: the active scene
     on top, the four dots in a row under it, and the active step's words below.
   Each scene's loops play only on the step marked `is-on` once process-motion.ts has set [data-live]; otherwise it
   rests on its final frame. */

/* ── Layout ─────────────────────────────────────────────────────────────────────────────────────────────── */
.s-proc {
  --pr-dot: 2.75rem;
  --pr-gap: var(--s-10);
  --pr-ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  --pr-fill: linear-gradient(var(--night-500), var(--gold-400));
}
.s-proc__defs {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}
.s-proc__steps {
  display: grid;
  gap: var(--pr-gap);
  margin: 0;
  padding: 0;
  list-style: none;
}
.s-proc__step {
  /* How far the line from this step to the next has filled (process-motion.ts scrubs it; 1 without motion). */
  --pr-p: 1;
  display: grid;
  grid-template-columns: var(--pr-dot) minmax(0, 1fr);
  grid-template-rows: auto 1fr auto;
  column-gap: var(--s-5);
}
.s-proc__dot {
  position: relative;
  z-index: 1;
  grid-column: 1;
  grid-row: 1;
  display: grid;
  place-items: center;
  width: var(--pr-dot);
  height: var(--pr-dot);
  border-radius: 50%;
  background: var(--c-site-primary);
  box-shadow: 0 0 0 var(--s-1) var(--c-site-primary-soft);
  color: var(--c-site-on-primary);
  font-family: var(--f-site);
  font-size: var(--fs-18);
  font-weight: 800;
  transition:
    background-color 0.4s,
    color 0.4s,
    box-shadow 0.4s;
}
.s-proc__line {
  grid-column: 1;
  grid-row: 2 / span 2;
  justify-self: center;
  width: 3px;
  margin-block: var(--s-2) calc(-1 * var(--pr-gap) + var(--s-2));
  overflow: hidden;
  border-radius: var(--r-pill);
  background: var(--c-site-line);
}
.s-proc__step:last-child .s-proc__line {
  display: none;
}
.s-proc__fill {
  display: block;
  width: 100%;
  height: 100%;
  background: var(--pr-fill);
  transform: scaleY(var(--pr-p));
  transform-origin: 50% 0;
}
.s-proc__copy {
  grid-column: 2;
  grid-row: 1 / span 2;
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  padding-block-start: var(--s-1);
}
.s-proc__who {
  margin: 0;
  color: var(--c-site-primary-ink);
  font-size: var(--fs-13);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.s-proc__who:lang(ar) {
  letter-spacing: 0;
}
.s-proc__title {
  margin: 0;
  color: var(--c-site-ink);
  font-family: var(--f-site);
  font-size: var(--fs-24);
  line-height: 1.15;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.s-proc__title:lang(ar) {
  line-height: 1.4;
  letter-spacing: 0;
}
.s-proc__body {
  margin: 0;
  max-width: 34em;
  color: var(--c-site-muted);
}
.s-proc__art {
  grid-column: 2;
  grid-row: 3;
  width: 100%;
  max-width: 30rem;
  margin-block-start: var(--s-5);
  overflow: hidden;
  border-radius: var(--r-dialog);
  background: var(--c-site-surface);
  box-shadow:
    0 0 0 1px var(--c-site-line),
    0 var(--s-3) var(--s-8) color-mix(in oklab, var(--night-900) 10%, transparent);
  transition:
    opacity 0.5s var(--pr-ease),
    transform 0.6s var(--pr-ease);
}
.s-pr {
  display: block;
  width: 100%;
  height: auto;
}
@media (max-width: 599px) {
  .s-proc {
    --pr-dot: 2.25rem;
    --pr-gap: var(--s-8);
  }
  .s-proc__step {
    column-gap: var(--s-4);
  }
  .s-proc__title {
    font-size: var(--fs-20);
  }
  .s-proc__dot {
    font-size: var(--fs-16);
  }
}

/* Wide and static: the steps in a row, the line running from each dot to the next. */
@media (min-width: 1024px) {
  .s-proc {
    --pr-gap: var(--s-6);
  }
  .s-proc__steps {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
  .s-proc__step {
    grid-template-rows: auto auto 1fr;
    row-gap: var(--s-5);
  }
  .s-proc__art {
    grid-column: 1 / -1;
    grid-row: 1;
    max-width: none;
    margin: 0;
  }
  .s-proc__dot {
    grid-row: 2;
  }
  .s-proc__line {
    grid-column: 2;
    grid-row: 2;
    align-self: center;
    justify-self: stretch;
    width: auto;
    height: 3px;
    margin-block: 0;
    margin-inline: calc(var(--s-2) - var(--s-5)) calc(-1 * var(--pr-gap) - var(--s-1));
  }
  .s-proc__fill {
    background: linear-gradient(to right, var(--night-500), var(--gold-400));
    transform: scaleX(var(--pr-p));
    transform-origin: 0 50%;
  }
  [dir='rtl'] .s-proc__fill {
    background: linear-gradient(to left, var(--night-500), var(--gold-400));
    transform-origin: 100% 50%;
  }
  .s-proc__copy {
    grid-column: 1 / -1;
    grid-row: 3;
    padding: 0;
  }
  .s-proc__title {
    font-size: var(--fs-20);
  }
}

/* Live (any width): steps not reached yet wait, quieter; the one in view glows. */
.s-proc[data-live] .s-proc__step:not(.is-on, .is-done) .s-proc__dot {
  background: var(--c-site-surface);
  box-shadow: inset 0 0 0 2px var(--c-site-line);
  color: var(--c-site-muted);
}
.s-proc[data-live] .s-proc__step:not(.is-on, .is-done) .s-proc__art {
  opacity: 0.55;
  transform: scale(0.97);
}

/* Wide and live: pinned, the steps on one side and the active scene in a panel on the other. */
@media (min-width: 1024px) and (prefers-reduced-motion: no-preference) and (scripting: enabled) {
  .s-home .s-proc {
    --pr-gap: var(--s-5);
    --pr-top: calc(var(--s-16) + var(--s-8));
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    grid-template-rows: auto auto;
    align-content: center;
    column-gap: var(--s-12);
    row-gap: var(--s-8);
    min-height: 100vh;
    padding-block: var(--pr-top) var(--s-10);
  }
  .s-home .s-proc::after {
    content: '';
    position: absolute;
    inset-block: var(--pr-top) var(--s-10);
    inset-inline-end: 0;
    width: calc(58.3% - var(--s-6));
    border-radius: calc(var(--r-lg) * 2);
    background: var(--c-site-surface);
    box-shadow:
      0 0 0 1px var(--c-site-line),
      0 var(--s-6) var(--s-16) color-mix(in oklab, var(--night-900) 12%, transparent);
  }
  .s-home .s-proc__head {
    grid-column: 1;
  }
  .s-home .s-proc__steps {
    grid-column: 1;
    grid-template-columns: minmax(0, 1fr);
  }
  .s-home .s-proc__step {
    grid-template-rows: auto 1fr;
    row-gap: 0;
  }
  .s-home .s-proc__dot {
    grid-row: 1;
  }
  .s-home .s-proc__line {
    grid-column: 1;
    grid-row: 2;
    align-self: stretch;
    justify-self: center;
    width: 3px;
    height: auto;
    margin-block: var(--s-1) calc(-1 * var(--pr-gap) - var(--s-1));
    margin-inline: 0;
  }
  .s-home .s-proc__fill,
  [dir='rtl'] .s-home .s-proc__fill {
    background: var(--pr-fill);
    transform: scaleY(var(--pr-p));
    transform-origin: 50% 0;
  }
  .s-home .s-proc__copy {
    grid-column: 2;
    grid-row: 1 / span 2;
    gap: var(--s-1);
    opacity: 0.45;
    transition: opacity 0.4s;
  }
  .s-home .s-proc__step.is-on .s-proc__copy {
    opacity: 1;
  }
  .s-home .s-proc__title {
    font-size: var(--fs-20);
  }
  .s-home .s-proc__body {
    font-size: var(--fs-14);
  }
  .s-home .s-proc__art,
  .s-home .s-proc[data-live] .s-proc__step:not(.is-on, .is-done) .s-proc__art {
    position: absolute;
    z-index: 1;
    inset-block: var(--pr-top) var(--s-10);
    inset-inline-end: 0;
    display: grid;
    place-items: center;
    width: calc(58.3% - var(--s-6));
    max-width: none;
    margin: 0;
    padding: var(--s-6);
    background: none;
    box-shadow: none;
    opacity: 0;
    transform: translateY(var(--s-6)) scale(0.94);
    pointer-events: none;
  }
  .s-home .s-proc .s-proc__step.is-on .s-proc__art {
    opacity: 1;
    transform: none;
  }
  .s-home .s-proc__art .s-pr {
    width: 100%;
    height: 100%;
  }
}
/* Narrow and live (phones, tablets): pinned like the wide layout, stacked. */
@media (max-width: 1023px) and (prefers-reduced-motion: no-preference) and (scripting: enabled) {
  .s-home .s-proc {
    --pr-dot: 2.25rem;
    --pr-art: 42svh;
    --pr-copy: 10.5rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: var(--s-4);
    min-height: 100vh;
    min-height: 100svh;
    padding-block: calc(var(--s-16) + var(--s-2)) var(--s-4);
  }
  .s-home .s-proc__head .s-lead {
    display: none;
  }
  /* The scene and the words are placed against the whole list: grid-column/row go back to auto, or the list's grid
     would hand each the area of its step's column. */
  .s-home .s-proc__steps {
    position: relative;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0;
    padding-block: calc(var(--pr-art) + var(--s-5)) calc(var(--pr-copy) + var(--s-5));
  }
  .s-home .s-proc__step {
    grid-template-rows: auto;
    column-gap: 0;
  }
  .s-home .s-proc__dot {
    grid-row: 1;
  }
  .s-home .s-proc__line {
    grid-column: 2;
    grid-row: 1;
    align-self: center;
    justify-self: stretch;
    width: auto;
    height: 3px;
    margin: 0 var(--s-1);
  }
  .s-home .s-proc__fill {
    background: linear-gradient(to right, var(--night-500), var(--gold-400));
    transform: scaleX(var(--pr-p));
    transform-origin: 0 50%;
  }
  [dir='rtl'] .s-home .s-proc__fill {
    background: linear-gradient(to left, var(--night-500), var(--gold-400));
    transform-origin: 100% 50%;
  }
  .s-home .s-proc__art,
  .s-home .s-proc[data-live] .s-proc__step:not(.is-on, .is-done) .s-proc__art {
    position: absolute;
    grid-column: auto;
    grid-row: auto;
    inset-block-start: 0;
    inset-inline: 0;
    display: grid;
    place-items: center;
    height: var(--pr-art);
    max-width: none;
    margin: 0;
    opacity: 0;
    transform: translateY(var(--s-4)) scale(0.96);
    pointer-events: none;
  }
  .s-home .s-proc .s-proc__step.is-on .s-proc__art {
    opacity: 1;
    transform: none;
  }
  .s-home .s-proc__art .s-pr {
    width: 100%;
    height: 100%;
  }
  .s-home .s-proc__copy {
    position: absolute;
    grid-column: auto;
    grid-row: auto;
    inset-block-end: 0;
    inset-inline: 0;
    height: var(--pr-copy);
    padding: 0;
    opacity: 0;
    transform: translateY(var(--s-2));
    transition:
      opacity 0.4s var(--pr-ease),
      transform 0.5s var(--pr-ease);
  }
  .s-home .s-proc__step.is-on .s-proc__copy {
    opacity: 1;
    transform: none;
  }
}
@media (min-width: 1440px) and (prefers-reduced-motion: no-preference) and (scripting: enabled) {
  .s-home .s-proc__title {
    font-size: var(--fs-24);
  }
  .s-home .s-proc__body {
    font-size: var(--fs-16);
  }
}

/* ── The scenes: colours ────────────────────────────────────────────────────────────────────────────────── */
.s-pr text {
  font-family: var(--f-site);
  font-weight: 800;
  text-anchor: middle;
}
.s-prs-blob-a {
  stop-color: var(--c-site-primary-soft);
}
.s-prs-blob-b {
  stop-color: var(--c-site-accent-soft);
}
.s-prs-device-a {
  stop-color: var(--dune-700);
}
.s-prs-device-b {
  stop-color: var(--dune-900);
}
.s-prs-ember-a {
  stop-color: var(--night-400);
}
.s-prs-ember-b {
  stop-color: var(--night-600);
}
.s-prs-saffron-a {
  stop-color: var(--gold-300);
}
.s-prs-saffron-b {
  stop-color: var(--gold-500);
}
.s-prs-paper-a {
  stop-color: #fff;
}
.s-prs-paper-b {
  stop-color: var(--dune-100);
}
.s-prs-scan-a {
  stop-color: var(--night-400);
  stop-opacity: 0;
}
.s-prs-scan-b {
  stop-color: var(--night-400);
  stop-opacity: 0.55;
}
.s-prs-glass-a {
  stop-color: #fff;
  stop-opacity: 0.2;
}
.s-prs-glass-b {
  stop-color: #fff;
  stop-opacity: 0;
}

.s-pr-blob {
  fill: url(#s-prg-blob);
}
.s-pr-speck--saffron {
  fill: var(--gold-300);
}
.s-pr-speck--ember {
  fill: var(--night-300);
}
.s-pr-shadow {
  fill: var(--night-950);
  opacity: 0.12;
}
.s-pr-spark--a {
  fill: var(--gold-400);
}
.s-pr-spark--b {
  fill: var(--night-400);
}
.s-pr-device {
  fill: url(#s-prg-device);
}
.s-pr-depth {
  fill: var(--dune-950);
  opacity: 0.85;
}
.s-pr-depth--soft {
  fill: var(--night-950);
  opacity: 0.14;
}
.s-pr-edge {
  fill: none;
  stroke: var(--dune-600);
  stroke-width: 1.5;
}
.s-pr-stand {
  fill: var(--dune-700);
}
.s-pr-notch,
.s-pr-cam {
  fill: var(--dune-950);
}
.s-pr-sheen {
  fill: url(#s-prg-glass);
  pointer-events: none;
}
.s-pr-screen {
  fill: var(--c-site-art-paper);
}
.s-pr-ln {
  fill: var(--c-site-muted);
  opacity: 0.5;
}
.s-pr-ln--soft {
  opacity: 0.25;
}
.s-pr-tile {
  fill: var(--night-500);
}
.s-pr-tilet {
  fill: #fff;
  font-size: 0.625rem;
}
.s-pr-sunk,
.s-pr-track {
  fill: color-mix(in oklab, var(--c-site-ink) 7%, var(--c-site-art-paper));
}
.s-pr-dig {
  fill: var(--c-site-ink);
  font-size: 2.125rem;
}
.s-pr-caret {
  fill: var(--night-500);
}
.s-pr-btn {
  fill: url(#s-prg-ember);
}
.s-pr-tick {
  fill: none;
  stroke: var(--night-600);
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.s-pr-tick--on {
  stroke: #fff;
  stroke-width: 3;
}
.s-pr-tick--sm {
  stroke-width: 2;
}
.s-pr-key {
  --pr-key: color-mix(in oklab, var(--c-site-ink) 7%, var(--c-site-art-paper));
  fill: var(--pr-key);
}
.s-pr-key--soft {
  --pr-key: var(--gold-100);
}
.s-pr-key--go {
  --pr-key: var(--night-100);
}
.s-pr-keyt {
  fill: var(--c-site-muted);
  font-size: 0.6875rem;
  font-weight: 600;
  pointer-events: none;
}
.s-pr-tap {
  fill: var(--night-400);
  opacity: 0;
}
.s-pr-chipbg {
  fill: url(#s-prg-saffron);
}
.s-pr-chipdot {
  fill: #fff;
}
.s-pr-chipt {
  fill: var(--dune-900);
  font-size: 0.9375rem;
}

/* Scan */
.s-pr-paper {
  fill: url(#s-prg-paper);
}
.s-pr-pline {
  fill: var(--dune-300);
}
.s-pr-pline--dark {
  fill: var(--dune-500);
}
.s-pr-qrbg {
  fill: #fff;
}
.s-pr-qr {
  fill: var(--dune-900);
}
.s-pr-qr-f {
  fill: none;
  stroke: var(--dune-900);
  stroke-width: 2.6;
}
.s-pr-view {
  fill: var(--dune-900);
}
.s-pr-dim {
  fill: var(--dune-600);
}
.s-pr-brk {
  fill: none;
  stroke: var(--gold-300);
  stroke-width: 3.5;
  stroke-linecap: round;
}
.s-pr-scanline {
  fill: var(--night-400);
}
.s-pr-scanglow {
  fill: url(#s-prg-scan);
}
.s-pr-onbtn {
  fill: #fff;
  opacity: 0.7;
}

/* Progress */
.s-pr-saucer {
  fill: var(--dune-200);
}
.s-pr-saucer-d {
  fill: var(--dune-400);
}
.s-pr-cup {
  fill: url(#s-prg-ember);
}
.s-pr-handle {
  fill: none;
  stroke: var(--night-600);
  stroke-width: 8;
  stroke-linecap: round;
}
.s-pr-cuphi {
  fill: none;
  stroke: var(--night-200);
  stroke-width: 4;
  stroke-linecap: round;
  opacity: 0.6;
}
.s-pr-rim {
  fill: var(--night-300);
}
.s-pr-coffee {
  fill: var(--gold-900);
}
.s-pr-badge {
  fill: var(--gold-300);
}
.s-pr-badgebell {
  fill: var(--night-700);
}
.s-pr-steam {
  fill: none;
  stroke: var(--c-site-muted);
  stroke-width: 4;
  stroke-linecap: round;
  opacity: 0.35;
}
.s-pr-num {
  fill: var(--c-site-ink);
  font-size: 2.5rem;
}
.s-pr-bar {
  fill: url(#s-prg-bar);
}
.s-pr-stepd {
  fill: var(--night-500);
}
.s-pr-stepd--now {
  fill: var(--gold-400);
}
.s-pr-ring {
  fill: none;
  stroke: color-mix(in oklab, var(--c-site-ink) 9%, var(--c-site-art-paper));
  stroke-width: 4;
}
.s-pr-arc {
  fill: none;
  stroke: var(--night-500);
  stroke-width: 4;
  stroke-linecap: round;
}
.s-pr-none {
  fill: none;
}
.s-pr-handl {
  fill: none;
  stroke: var(--c-site-ink);
  stroke-width: 2;
  stroke-linecap: round;
}
.s-pr-pin {
  fill: var(--c-site-ink);
}

/* Ready: green, never branded */
.s-pr-ready {
  fill: var(--c-ready);
}
.s-pr-rhalo {
  fill: #fff;
  opacity: 0.18;
}
.s-pr-rtick {
  fill: none;
  stroke: #fff;
  stroke-width: 4;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 26;
}
.s-pr-rword {
  fill: #fff;
  font-size: 1.125rem;
}
.s-pr-rnum {
  fill: #fff;
  font-size: 2.125rem;
}
.s-pr-rbar {
  fill: #fff;
  opacity: 0.5;
}
.s-pr-ripple {
  fill: none;
  stroke: var(--c-ready);
  stroke-width: 2;
  opacity: 0;
}
.s-pr-vib {
  fill: none;
  stroke: var(--night-400);
  stroke-width: 3.5;
  stroke-linecap: round;
}
.s-pr-bellb {
  fill: url(#s-prg-saffron);
}
.s-pr-bellhi {
  fill: none;
  stroke: var(--gold-100);
  stroke-width: 4;
  stroke-linecap: round;
  opacity: 0.8;
}
.s-pr-clap {
  fill: var(--night-600);
}
.s-pr-knob {
  fill: var(--gold-600);
}
.s-pr-wave {
  fill: none;
  stroke: var(--gold-400);
  stroke-width: 5;
  stroke-linecap: round;
}
.s-pr-bub {
  fill: var(--c-site-art-paper);
  stroke: var(--c-site-line);
  stroke-width: 1.5;
}
.s-pr-wa {
  fill: var(--c-wa);
}
.s-pr-waglyph {
  fill: #fff;
}
.s-pr-sms {
  fill: var(--gold-100);
}
.s-pr-smsdot {
  fill: var(--gold-500);
}
.s-pr-smsln {
  fill: var(--gold-700);
  opacity: 0.45;
}
.s-pr-smsln--soft {
  opacity: 0.25;
}
.s-pr-c--ember {
  fill: var(--night-500);
}
.s-pr-c--ember-l {
  fill: var(--night-300);
}
.s-pr-c--saffron {
  fill: var(--gold-400);
}
.s-pr-c--saffron-d {
  fill: var(--gold-600);
}

/* ── The scenes: resting frames and motion ──────────────────────────────────────────────────────────────── */
/* Everything that moves turns around its own box. */
.s-pr-press1,
.s-pr-press2,
.s-pr-tap,
.s-pr-d1,
.s-pr-d2,
.s-pr-send,
.s-pr-chip,
.s-pr-spark--a,
.s-pr-spark--b,
.s-pr-rcpt,
.s-pr-bob,
.s-pr-brks,
.s-pr-scan,
.s-pr-found,
.s-pr-steam,
.s-pr-barwrap,
.s-pr-bar,
.s-pr-hand,
.s-pr-stepd--now,
.s-pr-ripple,
.s-pr-vib,
.s-pr-shake,
.s-pr-bell,
.s-pr-wave,
.s-pr-b1,
.s-pr-b2,
.s-pr-bit,
.s-pr-rword,
.s-pr-rnum,
.s-pr-rhalo {
  transform-box: fill-box;
  transform-origin: center;
}
/* Resting frames: the scan line mid-sweep, the bar two thirds full, the clock hand a third of the way round. */
.s-pr-scan {
  transform: translateY(240%);
}
.s-pr-bar {
  transform: scaleX(0.64);
  transform-origin: 0 50%;
}
[dir='rtl'] .s-pr-barwrap {
  transform: scaleX(-1);
}
.s-pr-hand {
  transform: rotate(124deg);
}
.s-pr-bell {
  transform-origin: 50% 0;
}
.s-pr-caret {
  opacity: 0;
}

@media (prefers-reduced-motion: no-preference) {
  /* 1 · Cashier, 4.8 s: 4 is pressed, then 2, then Send, and the order chip pops up. */
  .s-proc[data-live] .is-on .s-pr-press1 {
    animation: s-pr-press1 4.8s infinite;
  }
  .s-proc[data-live] .is-on .s-pr-press2 {
    animation: s-pr-press2 4.8s infinite;
  }
  .s-proc[data-live] .is-on .s-pr-tap1 {
    animation: s-pr-tap1 4.8s infinite;
  }
  .s-proc[data-live] .is-on .s-pr-tap2 {
    animation: s-pr-tap2 4.8s infinite;
  }
  .s-proc[data-live] .is-on .s-pr-d1 {
    animation: s-pr-d1 4.8s var(--pr-ease) infinite;
  }
  .s-proc[data-live] .is-on .s-pr-d2 {
    animation: s-pr-d2 4.8s var(--pr-ease) infinite;
  }
  .s-proc[data-live] .is-on .s-pr-caret {
    animation: s-pr-caret 4.8s steps(1) infinite;
  }
  .s-proc[data-live] .is-on .s-pr-send {
    animation: s-pr-send 4.8s infinite;
  }
  .s-proc[data-live] .is-on .s-pr-chip {
    animation: s-pr-chip 4.8s infinite;
  }

  /* 2 · Scan, 4 s: the receipt floats, the line sweeps the code twice, the order opens. */
  .s-proc[data-live] .is-on .s-pr-rcpt {
    animation: s-pr-float 4s ease-in-out infinite;
  }
  .s-proc[data-live] .is-on .s-pr-bob {
    animation: s-pr-bob 4s ease-in-out infinite;
  }
  .s-proc[data-live] .is-on .s-pr-scan {
    animation: s-pr-scan 4s ease-in-out infinite;
  }
  .s-proc[data-live] .is-on .s-pr-brks {
    animation: s-pr-brks 4s ease-in-out infinite;
  }
  .s-proc[data-live] .is-on .s-pr-found {
    animation: s-pr-found 4s infinite;
  }

  /* 3 · Kitchen, 6 s: steam rises, the bar fills, the clock runs. */
  .s-proc[data-live] .is-on .s-pr-steam {
    animation: s-pr-steam 3s ease-in-out infinite;
  }
  .s-proc[data-live] .is-on .s-pr-steam2 {
    animation-delay: -1s;
  }
  .s-proc[data-live] .is-on .s-pr-steam3 {
    animation-delay: -2s;
  }
  .s-proc[data-live] .is-on .s-pr-bar {
    animation: s-pr-bar 6s var(--pr-ease) infinite;
  }
  .s-proc[data-live] .is-on .s-pr-arc {
    animation: s-pr-arc 6s linear infinite;
  }
  .s-proc[data-live] .is-on .s-pr-hand {
    animation: s-pr-hand 6s linear infinite;
  }
  .s-proc[data-live] .is-on .s-pr-stepd--now {
    animation: s-pr-pulse 1.2s ease-in-out infinite;
  }

  /* 4 · Ready, 4 s: the page lands green, the phone shakes, the bell swings, messages pop in, confetti. */
  .s-proc[data-live] .is-on .s-pr-shake {
    animation: s-pr-shake 4s infinite;
  }
  .s-proc[data-live] .is-on .s-pr-vib {
    animation: s-pr-vib 4s infinite;
  }
  .s-proc[data-live] .is-on .s-pr-ripple1 {
    animation: s-pr-ripple 2s ease-out infinite;
  }
  .s-proc[data-live] .is-on .s-pr-ripple2 {
    animation: s-pr-ripple 2s ease-out -1s infinite;
  }
  .s-proc[data-live] .is-on .s-pr-bell {
    animation: s-pr-bell 4s ease-in-out infinite;
  }
  .s-proc[data-live] .is-on .s-pr-wave {
    animation: s-pr-wave 4s infinite;
  }
  .s-proc[data-live] .is-on .s-pr-rhalo {
    animation: s-pr-halo 4s var(--pr-ease) infinite;
  }
  .s-proc[data-live] .is-on .s-pr-rtick {
    animation: s-pr-draw 4s var(--pr-ease) infinite;
  }
  .s-proc[data-live] .is-on .s-pr-rword {
    animation: s-pr-word 4s var(--pr-ease) infinite;
  }
  .s-proc[data-live] .is-on .s-pr-rnum {
    animation: s-pr-word 4s var(--pr-ease) 0.08s infinite;
  }
  .s-proc[data-live] .is-on .s-pr-b1 {
    animation: s-pr-b1 4s var(--pr-ease) infinite;
  }
  .s-proc[data-live] .is-on .s-pr-b2 {
    animation: s-pr-b2 4s var(--pr-ease) infinite;
  }
  .s-proc[data-live] .is-on .s-pr-bit {
    animation: s-pr-bit 4s cubic-bezier(0.1, 0.7, 0.3, 1) infinite;
  }
  .s-proc[data-live] .is-on .s-pr-bit2,
  .s-proc[data-live] .is-on .s-pr-bit6 {
    animation-delay: 0.06s;
  }
  .s-proc[data-live] .is-on .s-pr-bit3,
  .s-proc[data-live] .is-on .s-pr-bit7 {
    animation-delay: 0.12s;
  }
  .s-proc[data-live] .is-on .s-pr-bit4,
  .s-proc[data-live] .is-on .s-pr-bit8 {
    animation-delay: 0.18s;
  }
  .s-proc[data-live] .is-on .s-pr-bit5,
  .s-proc[data-live] .is-on .s-pr-bit9 {
    animation-delay: 0.24s;
  }

  /* Every scene's sparkles twinkle. */
  .s-proc[data-live] .is-on .s-pr-spark--a {
    animation: s-pr-twinkle 2.4s ease-in-out infinite;
  }
  .s-proc[data-live] .is-on .s-pr-spark--b {
    animation: s-pr-twinkle 2.4s ease-in-out -1.2s infinite;
  }
  /* The step in view: its number breathes. */
  .s-proc[data-live] .is-on .s-proc__dot {
    animation: s-pr-dot 2.4s ease-in-out infinite;
  }
}

@keyframes s-pr-press1 {
  0%,
  6%,
  16%,
  100% {
    transform: none;
    fill: var(--pr-key);
  }
  10% {
    transform: scale(0.84);
    fill: var(--night-300);
  }
}
@keyframes s-pr-press2 {
  0%,
  24%,
  34%,
  100% {
    transform: none;
    fill: var(--pr-key);
  }
  28% {
    transform: scale(0.84);
    fill: var(--night-300);
  }
}
@keyframes s-pr-tap1 {
  0%,
  8% {
    opacity: 0;
    transform: scale(0.3);
  }
  10% {
    opacity: 0.5;
  }
  22%,
  100% {
    opacity: 0;
    transform: scale(1.6);
  }
}
@keyframes s-pr-tap2 {
  0%,
  26% {
    opacity: 0;
    transform: scale(0.3);
  }
  28% {
    opacity: 0.5;
  }
  40%,
  100% {
    opacity: 0;
    transform: scale(1.6);
  }
}
@keyframes s-pr-d1 {
  0%,
  9% {
    opacity: 0;
    transform: translateY(30%) scale(0.6);
  }
  15%,
  92% {
    opacity: 1;
    transform: none;
  }
  98%,
  100% {
    opacity: 0;
  }
}
@keyframes s-pr-d2 {
  0%,
  27% {
    opacity: 0;
    transform: translateY(30%) scale(0.6);
  }
  33%,
  92% {
    opacity: 1;
    transform: none;
  }
  98%,
  100% {
    opacity: 0;
  }
}
@keyframes s-pr-caret {
  0%,
  10%,
  20%,
  30%,
  40%,
  50%,
  60%,
  70%,
  80%,
  90% {
    opacity: 1;
  }
  5%,
  15%,
  25%,
  35%,
  45%,
  55%,
  65%,
  75%,
  85%,
  95% {
    opacity: 0;
  }
}
@keyframes s-pr-send {
  0%,
  44%,
  54%,
  100% {
    transform: none;
  }
  48% {
    transform: scale(0.92);
  }
}
@keyframes s-pr-chip {
  0%,
  50% {
    opacity: 0;
    transform: translateY(40%) scale(0.4);
  }
  58% {
    opacity: 1;
    transform: translateY(-8%) scale(1.08);
  }
  64%,
  90% {
    opacity: 1;
    transform: none;
  }
  97%,
  100% {
    opacity: 0;
    transform: translateY(-20%);
  }
}

@keyframes s-pr-float {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }
  50% {
    transform: translateY(-3%) rotate(1.5deg);
  }
}
@keyframes s-pr-bob {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-2%);
  }
}
@keyframes s-pr-scan {
  0% {
    transform: translateY(0);
    opacity: 0;
  }
  5% {
    opacity: 1;
  }
  25% {
    transform: translateY(480%);
  }
  45% {
    transform: translateY(0);
  }
  58% {
    transform: translateY(240%);
    opacity: 1;
  }
  64%,
  100% {
    transform: translateY(240%);
    opacity: 0;
  }
}
@keyframes s-pr-brks {
  0%,
  56%,
  100% {
    transform: none;
  }
  28% {
    transform: scale(1.05);
  }
  62% {
    transform: scale(0.94);
  }
}
@keyframes s-pr-found {
  0%,
  58% {
    opacity: 0;
    transform: translateY(30%) scale(0.7);
  }
  66% {
    opacity: 1;
    transform: translateY(-6%) scale(1.06);
  }
  72%,
  94% {
    opacity: 1;
    transform: none;
  }
  100% {
    opacity: 0;
  }
}

@keyframes s-pr-steam {
  0% {
    opacity: 0;
    transform: translateY(14%) scaleY(0.8);
  }
  40% {
    opacity: 0.45;
  }
  100% {
    opacity: 0;
    transform: translateY(-18%) scaleY(1.1);
  }
}
@keyframes s-pr-bar {
  0% {
    transform: scaleX(0.08);
  }
  85%,
  100% {
    transform: scaleX(1);
  }
}
@keyframes s-pr-arc {
  from {
    stroke-dashoffset: 75.4;
  }
  to {
    stroke-dashoffset: 0;
  }
}
@keyframes s-pr-hand {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}
@keyframes s-pr-pulse {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.35);
  }
}

@keyframes s-pr-shake {
  0%,
  30%,
  100% {
    transform: none;
  }
  3%,
  11%,
  19% {
    transform: translateX(-2%) rotate(-3deg);
  }
  7%,
  15%,
  23% {
    transform: translateX(2%) rotate(3deg);
  }
  27% {
    transform: rotate(-1deg);
  }
}
@keyframes s-pr-vib {
  0%,
  28%,
  100% {
    opacity: 0;
    transform: scale(0.8);
  }
  4%,
  24% {
    opacity: 1;
    transform: none;
  }
}
@keyframes s-pr-ripple {
  0% {
    opacity: 0.5;
    transform: scale(0.7);
  }
  100% {
    opacity: 0;
    transform: scale(1.25);
  }
}
@keyframes s-pr-bell {
  0%,
  34%,
  100% {
    transform: none;
  }
  4% {
    transform: rotate(16deg);
  }
  10% {
    transform: rotate(-14deg);
  }
  16% {
    transform: rotate(10deg);
  }
  22% {
    transform: rotate(-6deg);
  }
  28% {
    transform: rotate(3deg);
  }
}
@keyframes s-pr-wave {
  0%,
  30%,
  100% {
    opacity: 0;
  }
  6%,
  24% {
    opacity: 1;
  }
}
@keyframes s-pr-halo {
  0% {
    transform: scale(0.4);
    opacity: 0;
  }
  10% {
    transform: scale(1.3);
    opacity: 0.3;
  }
  20%,
  100% {
    transform: none;
    opacity: 0.18;
  }
}
@keyframes s-pr-draw {
  0%,
  4% {
    stroke-dashoffset: 26;
  }
  16%,
  100% {
    stroke-dashoffset: 0;
  }
}
@keyframes s-pr-word {
  0%,
  6% {
    opacity: 0;
    transform: translateY(25%) scale(0.7);
  }
  14% {
    opacity: 1;
    transform: scale(1.12);
  }
  20%,
  100% {
    opacity: 1;
    transform: none;
  }
}
@keyframes s-pr-b1 {
  0%,
  16% {
    opacity: 0;
    transform: translateX(-12%) scale(0.5);
  }
  24% {
    opacity: 1;
    transform: scale(1.06);
  }
  30%,
  92% {
    opacity: 1;
    transform: none;
  }
  100% {
    opacity: 0;
  }
}
@keyframes s-pr-b2 {
  0%,
  32% {
    opacity: 0;
    transform: translateX(-12%) scale(0.5);
  }
  40% {
    opacity: 1;
    transform: scale(1.06);
  }
  46%,
  92% {
    opacity: 1;
    transform: none;
  }
  100% {
    opacity: 0;
  }
}
@keyframes s-pr-bit {
  0%,
  6% {
    opacity: 0;
    transform: translateY(260%) scale(0.2) rotate(0deg);
  }
  12% {
    opacity: 1;
  }
  34%,
  80% {
    opacity: 1;
    transform: none;
  }
  100% {
    opacity: 0;
    transform: translateY(160%) rotate(160deg);
  }
}
@keyframes s-pr-twinkle {
  0%,
  100% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(0.45) rotate(45deg);
    opacity: 0.5;
  }
}
@keyframes s-pr-dot {
  0%,
  100% {
    box-shadow: 0 0 0 var(--s-1) var(--c-site-primary-soft);
  }
  50% {
    box-shadow: 0 0 0 var(--s-2) var(--c-site-primary-soft);
  }
}

}
/* surfaces/site-art.css */
@layer surfaces {
/* bellou.io illustrations (apps/web/src/site/art.ts). One set: light from the top start, rounded geometry, flat
   shapes with soft gradients. Every colour is set here from the Gulf night scales (--night-*, --gold-*,
   --dune-*, the same in both themes) and the theme-aware --c-site-* roles (paper, line, soft backdrops), so the
   art follows light and dark. Gradients are shared (art.ts artDefs) and their stops are coloured below. The idle
   motion lives in one prefers-reduced-motion: no-preference block at the end; without it everything is still. */

/* ── Frame ───────────────────────────────────────────────────────────────────────────────────────────────── */
.s-art-defs {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
  pointer-events: none;
}
.s-art {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}
.s-art g[class],
.s-art path[class*='a-vap'],
.s-art .a-led,
.s-art .a-bar,
.s-art .a-twinkle {
  transform-box: fill-box;
  transform-origin: 50% 50%;
}

/* ── Gradient stops ──────────────────────────────────────────────────────────────────────────────────────── */
.as-e4 {
  stop-color: var(--night-400);
}
.as-e6 {
  stop-color: var(--night-600);
}
.as-e8 {
  stop-color: var(--night-800);
}
.as-s1 {
  stop-color: var(--gold-100);
}
.as-s2 {
  stop-color: var(--gold-200);
}
.as-s3 {
  stop-color: var(--gold-300);
}
.as-s4 {
  stop-color: var(--gold-400);
}
.as-s6 {
  stop-color: var(--gold-600);
}
.as-pa {
  stop-color: var(--c-site-art-paper);
}
.as-su {
  stop-color: var(--c-site-sunk);
}
.as-d7 {
  stop-color: var(--dune-700);
}
.as-d9 {
  stop-color: var(--dune-900);
}

/* ── Fills ───────────────────────────────────────────────────────────────────────────────────────────────── */
.a-e,
.a-drop {
  fill: url(#sa-e);
}
.a-ed {
  fill: url(#sa-ed);
}
.a-s {
  fill: url(#sa-s);
}
.a-sd {
  fill: url(#sa-sd);
}
.a-p {
  fill: url(#sa-p);
}
.a-dv {
  fill: url(#sa-dv);
  stroke: var(--dune-500);
  stroke-width: 1.5;
}
.a-gl {
  fill: url(#sa-gl);
}
.a-pp {
  fill: var(--c-site-art-paper);
}
.a-cream {
  fill: var(--gold-100);
}
.a-sand {
  fill: var(--dune-300);
}
.a-dot {
  fill: var(--night-600);
}
.a-ln {
  fill: var(--c-site-line);
}
.a-chip {
  fill: var(--c-site-sunk);
}
.a-sh {
  fill: var(--c-site-line);
  opacity: 0.8;
}
.a-blob {
  fill: var(--c-site-primary-soft);
}
.a-blob2 {
  fill: var(--c-site-accent-soft);
}
.a-ready {
  fill: var(--c-ready);
}
.a-onready {
  fill: #fff;
  font-family: var(--f-num);
  font-weight: 700;
}
.a-num {
  fill: var(--night-600);
  font-family: var(--f-num);
  font-weight: 700;
}
.a-tvn {
  fill: var(--c-site-ink);
  font-family: var(--f-num);
  font-weight: 700;
}
.a-q {
  fill: #fff;
  font-family: var(--f-site);
  font-weight: 800;
}
.a-q2 {
  fill: var(--night-600);
}
.a-q3 {
  fill: var(--dune-900);
}
.a-glyph {
  fill: #fff;
  font-family: var(--f-ui);
  font-weight: 700;
}
.a-glyph2 {
  fill: var(--dune-900);
}
.a-spark {
  fill: var(--gold-400);
}
.a-sealmark {
  fill: var(--gold-200);
}
.a-step {
  fill: var(--night-500);
}
.a-stepnow {
  fill: var(--gold-400);
}
.a-dotm {
  fill: var(--c-site-muted);
}
.a-leaf {
  fill: var(--gold-300);
  opacity: 0.45;
}
.a-puck {
  fill: var(--dune-800);
}
.a-led {
  fill: var(--night-400);
}
.a-spill {
  fill: var(--gold-700);
  opacity: 0.35;
}
.a-bit.a-be {
  fill: var(--night-500);
}
.a-bit.a-bs {
  fill: var(--gold-400);
}
.a-small {
  font-weight: 700;
}

/* ── Strokes ─────────────────────────────────────────────────────────────────────────────────────────────── */
.a-edge,
.a-edgec {
  stroke: var(--c-site-line);
  stroke-width: 1.5;
}
.a-edgec {
  fill: none;
  stroke-width: 2;
}
.a-hls,
.a-vap,
.a-wave,
.a-handle,
.a-band,
.a-rib,
.a-track,
.a-trackon,
.a-divider,
.a-trend,
.a-hand,
.a-tassel,
.a-ground,
.a-flap,
.a-check,
.a-checkw,
.a-checkd,
.a-stream,
.a-pulse,
.a-trail,
.a-ringin {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.a-hls {
  stroke: #fff;
  stroke-width: 3;
  opacity: 0.5;
}
.a-thin {
  stroke-width: 2;
}
.a-vap {
  stroke: var(--dune-300);
  stroke-width: 2.5;
  opacity: 0.8;
}
.a-wave {
  stroke: var(--night-400);
  stroke-width: 2.5;
}
.a-wave2 {
  opacity: 0.5;
}
.a-handle {
  stroke: var(--gold-600);
  stroke-width: 5;
}
.a-band {
  stroke: var(--night-500);
  stroke-width: 3;
}
.a-rib {
  stroke: var(--gold-300);
  stroke-width: 2.5;
  opacity: 0.6;
}
.a-track {
  stroke: var(--c-site-line);
  stroke-width: 2;
}
.a-trackon {
  stroke: var(--night-500);
  stroke-width: 2;
}
.a-divider,
.a-ground {
  stroke: var(--c-site-line);
  stroke-width: 1.5;
}
.a-ground {
  stroke-width: 2;
}
.a-trend {
  stroke: var(--night-600);
  stroke-width: 2.5;
}
.a-hand {
  stroke: var(--dune-900);
  stroke-width: 2.5;
}
.a-hand2 {
  stroke: var(--night-600);
}
.a-tassel {
  stroke: var(--night-700);
  stroke-width: 1.5;
}
.a-flap {
  stroke: var(--dune-300);
  stroke-width: 2;
}
.a-check,
.a-checkd {
  stroke: var(--dune-900);
  stroke-width: 3;
}
.a-checkw {
  stroke: #fff;
  stroke-width: 2.5;
}
.a-stream {
  stroke: var(--gold-700);
  stroke-width: 2.5;
  opacity: 0.7;
}
.a-pulse {
  stroke: var(--night-400);
  stroke-width: 2.5;
  stroke-dasharray: 8 6;
}
.a-trail {
  stroke: var(--dune-300);
  stroke-width: 2;
  stroke-dasharray: 2 7;
}
.a-ringin {
  stroke: var(--c-site-line);
  stroke-width: 1.5;
}

/* ── Where each illustration sits ───────────────────────────────────────────────────────────────────────── */

/* The hero: café objects in the side gutters, behind the headline (its head is z-index 2, the stage 3). */
.s-art-hero {
  position: absolute;
  inset: 0;
  z-index: 1;
  overflow: clip;
  pointer-events: none;
}
.s-art-hero__i {
  position: absolute;
  display: block;
}
.s-art-hero__frond1 {
  inset-block-start: 2%;
  inset-inline-start: -2%;
  width: 11rem;
}
.s-art-hero__frond2 {
  inset-block-start: 44%;
  inset-inline-end: -2%;
  width: 12rem;
  transform: scaleX(-1) rotate(-12deg);
}
.s-art-hero__cup {
  inset-block-start: 8%;
  inset-inline-start: 2.5%;
  width: 5.25rem;
}
.s-art-hero__ticket {
  inset-block-start: 7%;
  inset-inline-end: 3%;
  width: 5.25rem;
}
.s-art-hero__bell {
  inset-block-start: 30%;
  inset-inline-end: 4%;
  width: 7.5rem;
}
.s-art-hero__dallah {
  inset-block-start: 29%;
  inset-inline-start: 3%;
  width: 7rem;
}
@media (max-width: 1023px) {
  .s-art-hero__bell,
  .s-art-hero__dallah {
    display: none;
  }
}
/* Phones: the headline fills the width, so the cup and the ticket had nowhere to sit but on the label above it;
   only the frond stays, behind. */
@media (max-width: 599px) {
  .s-art-hero__frond2,
  .s-art-hero__cup,
  .s-art-hero__ticket {
    display: none;
  }
  .s-art-hero__frond1 {
    width: 7rem;
  }
}

/* Feature tiles: a spot illustration above the title. */
.s-feature__art {
  display: grid;
  place-items: center;
  margin-block-end: var(--s-2);
}
.s-feature__art .s-art {
  width: auto;
  max-width: 100%;
  height: 8.5rem;
}

/* Tour cards: a small sticker at the corner of the media. */
.s-card__media:has(.s-card__accent) {
  position: relative;
}
.s-card__accent {
  position: absolute;
  inset-block-end: calc(-1 * var(--s-4));
  inset-inline-end: calc(-1 * var(--s-3));
  z-index: 2;
  width: 5.5rem;
  pointer-events: none;
}
.s-card__accent--5 {
  width: 6.5rem;
}
@media (max-width: 599px) {
  .s-card__accent {
    width: 4rem;
  }
}

/* Plan cards: the tier's scene above its name. */
.s-plan__art {
  display: block;
  margin-block-end: var(--s-2);
}
.s-plan__art .s-art {
  width: auto;
  max-width: 100%;
  height: 4.5rem;
}

/* FAQ: under the heading on wide screens; hidden where the heading sits above the list. */
.s-faq__art {
  margin-block-start: var(--s-8);
  max-width: 15rem;
}
@media (max-width: 1023px) {
  .s-faq__art {
    display: none;
  }
}

/* The closing band: coffee poured, at the start. */
.s-band__art {
  flex: none;
  width: 12rem;
}
.s-band__in:has(.s-band__art) .s-band__copy {
  flex: 1 1 18rem;
}
@media (max-width: 599px) {
  .s-band__art {
    width: 8rem;
  }
}

/* Above the plan cards: the fan of ringing phones. */
.s-pagers__art {
  flex: none;
  width: 9rem;
}
@media (max-width: 599px) {
  .s-pagers__art {
    width: 7rem;
  }
}

/* Contact: the header scene, and a picture beside each next step (its number rides on the picture's corner). */
.s-contact__art {
  max-width: 20rem;
}
.s-next li:has(.s-next__art) {
  position: relative;
  align-items: center;
}
.s-next__art {
  flex: none;
  width: 3.5rem;
  padding: var(--s-1);
  border-radius: var(--r-card);
  background: var(--c-site-accent-soft);
}
.s-next__art + .s-next__n {
  position: absolute;
  inset-block-start: calc(-1 * var(--s-1));
  inset-inline-start: calc(3.5rem - var(--s-4));
}

/* Help, legal, status and page not found. */
.h-hero__art {
  width: 15rem;
}
.lg-head__art {
  width: 8.5rem;
}
.st-art {
  width: 12rem;
  margin-inline: auto;
  margin-block-end: var(--s-2);
}
.s-notfound__art {
  width: min(24rem, 100%);
  margin-inline: auto;
}
@media (max-width: 599px) {
  .h-hero__art {
    width: 11rem;
  }
  .s-contact__art {
    max-width: 15rem;
  }
}

/* ── Idle motion (none under reduced motion) ─────────────────────────────────────────────────────────────── */
@media (prefers-reduced-motion: no-preference) {
  .s-art .a-float {
    animation: a-float 6s ease-in-out infinite alternate;
  }
  .s-art .a-d2 {
    animation-delay: -2s;
  }
  .s-art .a-d3 {
    animation-delay: -4s;
  }
  .s-art .a-vap {
    animation: a-vap 3.2s ease-in infinite;
  }
  .s-art .a-vap2 {
    animation-delay: -1.1s;
  }
  .s-art .a-vap3 {
    animation-delay: -2.2s;
  }
  .s-art .a-ring .a-bellt {
    transform-origin: 50% 100%;
    animation: a-ring 5s ease-in-out infinite;
  }
  .s-art .a-waves {
    animation: a-waves 5s ease-out infinite;
  }
  .s-art .a-twinkle {
    animation: a-twinkle 2.8s ease-in-out infinite;
  }
  .s-art .a-typing circle {
    animation: a-type 1.4s ease-in-out infinite;
  }
  .s-art .a-typing circle:nth-child(2) {
    animation-delay: 0.2s;
  }
  .s-art .a-typing circle:nth-child(3) {
    animation-delay: 0.4s;
  }
  .s-art .a-blink {
    animation: a-blink 2.4s ease-in-out infinite;
  }
  .s-art .a-buzz {
    animation: a-buzz 4s linear infinite;
  }
  .s-art .a-sway {
    transform-origin: 50% 0;
    animation: a-sway 5s ease-in-out infinite alternate;
  }
  .s-art .a-clock {
    transform-origin: 0 0;
    animation: a-spin 8s linear infinite;
  }
  .s-art .a-spin {
    animation: a-bob 7s ease-in-out infinite alternate;
  }
  .s-art .a-lost {
    animation: a-lost 3.6s ease-in-out infinite;
  }
  .s-art .a-led {
    animation: a-led 1.5s steps(1) infinite;
  }
  .s-art .a-led1 {
    animation-delay: 0.3s;
  }
  .s-art .a-led2 {
    animation-delay: 0.6s;
  }
  .s-art .a-led3 {
    animation-delay: 0.9s;
  }
  .s-art .a-led4 {
    animation-delay: 1.2s;
  }
  .s-art .a-pulse {
    animation: a-dash 1.6s linear infinite;
  }
  .s-art .a-trail {
    animation: a-dash 2.4s linear infinite;
  }
  .s-art .a-stream {
    stroke-dasharray: 10 6;
    animation: a-dash 1.2s linear infinite;
  }
  .s-art .a-pour {
    transform-origin: 60% 90%;
    animation: a-pour 6s ease-in-out infinite alternate;
  }
  .s-art .a-pop {
    animation: a-pop 5s ease-in-out infinite;
  }
  .s-art .a-sw {
    transform-origin: 50% 100%;
  }
  .s-art .a-sw,
  .s-art .a-bar {
    transition: transform var(--m-slow) var(--ease-out);
  }
  .s-art .a-bar {
    transform-origin: 50% 100%;
  }

  /* Hover: the tile's picture answers. */
  .s-feature:hover .a-ring .a-bellt,
  .s-plan:hover .a-ring .a-bellt {
    animation-duration: 0.9s;
  }
  .s-feature:hover .a-fan > g:first-child .a-sw {
    transform: rotate(-8deg);
  }
  .s-feature:hover .a-fan > g:last-child .a-sw {
    transform: rotate(8deg);
  }
  .s-feature:hover .a-bar {
    transform: scaleY(1.12);
  }
  .s-feature:hover .a-buzz {
    animation-duration: 1s;
  }
}

@keyframes a-float {
  to {
    transform: translateY(-7%);
  }
}
@keyframes a-vap {
  0% {
    opacity: 0;
    transform: translateY(20%);
  }
  30% {
    opacity: 0.8;
  }
  100% {
    opacity: 0;
    transform: translateY(-25%);
  }
}
@keyframes a-ring {
  0%,
  70%,
  100% {
    transform: rotate(0);
  }
  74% {
    transform: rotate(-9deg);
  }
  78% {
    transform: rotate(8deg);
  }
  82% {
    transform: rotate(-6deg);
  }
  86% {
    transform: rotate(4deg);
  }
  90% {
    transform: rotate(-2deg);
  }
}
@keyframes a-waves {
  0%,
  70% {
    opacity: 0;
  }
  76%,
  88% {
    opacity: 1;
  }
  100% {
    opacity: 0;
  }
}
@keyframes a-twinkle {
  0%,
  100% {
    opacity: 1;
    transform: scale(1) rotate(0);
  }
  50% {
    opacity: 0.4;
    transform: scale(0.6) rotate(45deg);
  }
}
@keyframes a-type {
  0%,
  60%,
  100% {
    opacity: 0.35;
    transform: translateY(0);
  }
  30% {
    opacity: 1;
    transform: translateY(-30%);
  }
}
@keyframes a-blink {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.55;
  }
}
@keyframes a-buzz {
  0%,
  80%,
  100% {
    transform: rotate(0);
  }
  82%,
  86%,
  90%,
  94% {
    transform: rotate(-4deg);
  }
  84%,
  88%,
  92%,
  96% {
    transform: rotate(4deg);
  }
}
@keyframes a-sway {
  from {
    transform: rotate(-3deg);
  }
  to {
    transform: rotate(3deg);
  }
}
@keyframes a-spin {
  to {
    transform: rotate(360deg);
  }
}
@keyframes a-bob {
  from {
    transform: rotate(-8deg) translateY(0);
  }
  to {
    transform: rotate(8deg) translateY(-4%);
  }
}
@keyframes a-lost {
  0%,
  100% {
    transform: rotate(0) translateX(0);
  }
  20% {
    transform: rotate(-4deg) translateX(-2%);
  }
  40% {
    transform: rotate(3deg) translateX(2%);
  }
  60% {
    transform: rotate(0) translateX(0);
  }
}
@keyframes a-led {
  0% {
    fill: var(--gold-200);
  }
  20% {
    fill: var(--night-400);
  }
}
@keyframes a-dash {
  to {
    stroke-dashoffset: -28;
  }
}
@keyframes a-pour {
  from {
    transform: rotate(0);
  }
  to {
    transform: rotate(-6deg);
  }
}
@keyframes a-pop {
  0%,
  100% {
    transform: scale(1);
  }
  8% {
    transform: scale(1.06);
  }
  16% {
    transform: scale(1);
  }
}

}
/* surfaces/site-fx.css */
@layer surfaces {
/* Surface: s-fx (bellou.io's delight layer: the headline's entrance, the ready moment, confetti, heading reveals, the
   shimmering word and the micro-interactions). Owned by apps/web/src/site/fx*.ts and confetti.ts. Everything here
   is a finishing touch: at rest (no script, or reduced motion) the page reads exactly as without it. Movement only
   under `prefers-reduced-motion: no-preference`; transforms and opacity only, so nothing shifts the layout.
   Logical properties; directions mirror in Arabic. */

.s-page {
  --fx-ease: cubic-bezier(0.22, 1, 0.36, 1);
  --fx-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  /* The sheen: a lighter indigo on the light page (navy through gold reads brown), gold at night. */
  --fx-gold: var(--night-400);
  --fx-from: 0%;
}
:root[data-theme='dark'] .s-page {
  --fx-gold: var(--gold-300);
}
@media (prefers-color-scheme: dark) {
  :root[data-theme='auto'] .s-page {
    --fx-gold: var(--gold-300);
  }
}
[dir='rtl'] .s-page,
.s-page[dir='rtl'] {
  --fx-from: 100%;
}

/* ── Confetti (confetti.ts): one canvas over everything, never in the way ──────────────────────────────────── */
.s-fx-confetti {
  position: fixed;
  inset: 0;
  z-index: 9999;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

/* ── The headline's entrance (fx-split.ts): letters in English, whole words in Arabic ───────────────────────── */
.s-fx-type {
  display: inline-block;
}
.s-fx-type > span {
  display: inline-block;
}
/* The second half wears the heat gradient as clipped text; transformed pieces can't share their parent's, so each
   piece carries its own slice of it (--fx-n pieces, this one at --fx-i). */
.s-hero__title .s-hero__b:has(.s-fx-type) {
  background: none;
  color: inherit;
}
.s-hero__b .s-fx-type > span {
  background: var(--s-heat);
  background-size: calc(var(--fx-n, 1) * 100%) 100%;
  background-position: calc(var(--fx-i, 0) / max(var(--fx-n, 1) - 1, 1) * 100%) 0;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  padding-block-end: 0.06em;
}
[dir='rtl'] .s-hero__b .s-fx-type > span {
  background-position: calc((1 - var(--fx-i, 0) / max(var(--fx-n, 1) - 1, 1)) * 100%) 0;
}
@media (forced-colors: active) {
  .s-hero__b .s-fx-type > span {
    background: none;
    color: CanvasText;
  }
}
.s-fx-n2 {
  --fx-n: 2;
}
.s-fx-n3 {
  --fx-n: 3;
}
.s-fx-n4 {
  --fx-n: 4;
}
.s-fx-n5 {
  --fx-n: 5;
}
.s-fx-n6 {
  --fx-n: 6;
}
.s-fx-n7 {
  --fx-n: 7;
}
.s-fx-n8 {
  --fx-n: 8;
}
.s-fx-n9 {
  --fx-n: 9;
}
.s-fx-n10 {
  --fx-n: 10;
}
.s-fx-n11 {
  --fx-n: 11;
}
.s-fx-n12 {
  --fx-n: 12;
}
.s-fx-n13 {
  --fx-n: 13;
}
.s-fx-n14 {
  --fx-n: 14;
}
.s-fx-n15 {
  --fx-n: 15;
}
.s-fx-n16 {
  --fx-n: 16;
}
.s-fx-type > span:nth-child(2) {
  --fx-i: 1;
}
.s-fx-type > span:nth-child(3) {
  --fx-i: 2;
}
.s-fx-type > span:nth-child(4) {
  --fx-i: 3;
}
.s-fx-type > span:nth-child(5) {
  --fx-i: 4;
}
.s-fx-type > span:nth-child(6) {
  --fx-i: 5;
}
.s-fx-type > span:nth-child(7) {
  --fx-i: 6;
}
.s-fx-type > span:nth-child(8) {
  --fx-i: 7;
}
.s-fx-type > span:nth-child(9) {
  --fx-i: 8;
}
.s-fx-type > span:nth-child(10) {
  --fx-i: 9;
}
.s-fx-type > span:nth-child(11) {
  --fx-i: 10;
}
.s-fx-type > span:nth-child(12) {
  --fx-i: 11;
}
.s-fx-type > span:nth-child(13) {
  --fx-i: 12;
}
.s-fx-type > span:nth-child(14) {
  --fx-i: 13;
}
.s-fx-type > span:nth-child(15) {
  --fx-i: 14;
}
.s-fx-type > span:nth-child(n + 16) {
  --fx-i: 15;
}
@media (prefers-reduced-motion: no-preference) {
  .s-fx-type > span {
    animation: s-fx-letter 0.9s var(--fx-ease) backwards;
    animation-delay: calc(var(--fx-base, 0s) + var(--fx-i, 0) * 0.04s);
  }
  .s-hero__b {
    --fx-base: 0.28s;
  }
}
/* Phones and tablets: the page is still settling (address bar, fonts) when it starts, so start a beat later. */
@media (max-width: 1023px) and (prefers-reduced-motion: no-preference) {
  .s-hero__a {
    --fx-base: 0.35s;
  }
  .s-hero__b {
    --fx-base: 0.63s;
  }
  /* Arabic words are fewer and longer: a slower, wider stagger. */
  .s-fx-type:lang(ar) > span {
    animation-duration: 1.1s;
    animation-delay: calc(var(--fx-base, 0s) * 1.4 + var(--fx-i, 0) * 0.12s);
  }
}
@keyframes s-fx-letter {
  from {
    opacity: 0;
    transform: translateY(0.5em) rotate(4deg) scale(0.9);
    filter: blur(0.1em);
  }
  60% {
    filter: none;
  }
}

/* ── The ready moment (fx-home.ts rolls the digits in) ──────────────────────────────────────────────────────── */
.s-fx-digit {
  display: inline-block;
  backface-visibility: hidden;
}

/* ── Section headings rise into view (fx.ts adds .s-fx-rise only below the fold, then .is-in) ─────────────── */
@media (prefers-reduced-motion: no-preference) {
  .s-fx-rise {
    opacity: 0;
    transform: translateY(0.6em);
    clip-path: inset(0 -0.2em 100% -0.2em);
    transition:
      opacity 0.5s var(--fx-ease),
      transform 0.8s var(--fx-ease),
      clip-path 0.8s var(--fx-ease);
  }
  .s-fx-rise.is-in {
    opacity: 1;
    transform: none;
    clip-path: inset(-0.3em -0.2em -0.3em -0.2em);
  }
}

/* ── The highlighted word: the site's primary, a slow shimmer passing through it ──────────────────────────────── */
.s-fx-shine {
  background-image: linear-gradient(
    100deg,
    var(--c-site-primary-ink) 0%,
    var(--c-site-primary) 30%,
    var(--fx-gold) 50%,
    var(--c-site-primary) 70%,
    var(--c-site-primary-ink) 100%
  );
  background-size: 250% 100%;
  background-position: var(--fx-from) 50%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}
@media (prefers-reduced-motion: no-preference) {
  .s-fx-shine {
    animation: s-fx-shine 6s ease-in-out infinite alternate;
  }
  [dir='rtl'] .s-fx-shine {
    animation-name: s-fx-shine-rtl;
  }
}
@keyframes s-fx-shine {
  to {
    background-position: 100% 50%;
  }
}
@keyframes s-fx-shine-rtl {
  to {
    background-position: 0% 50%;
  }
}
@media (forced-colors: active) {
  .s-fx-shine {
    color: CanvasText;
    background: none;
  }
}

/* ── Buttons: press, a sheen on hover, a little magnetic lean (fx.ts animates `translate`) ─────────────────────── */
@media (prefers-reduced-motion: no-preference) {
  .s-page .ui-btn {
    transition:
      background-color var(--dur-1) var(--ease-standard),
      border-color var(--dur-1) var(--ease-standard),
      box-shadow var(--dur-1) var(--ease-standard),
      scale 0.15s var(--fx-ease),
      translate 0.3s var(--fx-ease);
  }
  .s-page .ui-btn:active {
    scale: 0.96;
  }
  .s-page .ui-btn--primary {
    overflow: hidden;
    isolation: isolate;
  }
  .s-page .ui-btn--primary::after {
    content: '';
    position: absolute;
    inset-block: 0;
    inset-inline-start: 0;
    z-index: -1;
    width: 60%;
    background: linear-gradient(100deg, transparent, color-mix(in oklab, #fff 28%, transparent), transparent);
    transform: translateX(-120%) skewX(-18deg);
    pointer-events: none;
  }
  [dir='rtl'] .s-page .ui-btn--primary::after,
  .s-page[dir='rtl'] .ui-btn--primary::after {
    transform: translateX(120%) skewX(18deg);
  }
  .s-page .ui-btn--primary:hover::after {
    transform: translateX(260%) skewX(-18deg);
    transition: transform 0.75s var(--fx-ease);
  }
  [dir='rtl'] .s-page .ui-btn--primary:hover::after,
  .s-page[dir='rtl'] .ui-btn--primary:hover::after {
    transform: translateX(-260%) skewX(18deg);
  }
}

/* ── Cards: a warm lift and a glow that follows the pointer (fx.ts sets --fx-x/--fx-y) ─────────────────────── */
.s-fx-glow {
  --fx-x: 50%;
  --fx-y: 0%;
  isolation: isolate;
}
.s-fx-glow::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  background: radial-gradient(
    18rem circle at var(--fx-x) var(--fx-y),
    color-mix(in oklab, var(--gold-300) 30%, transparent),
    color-mix(in oklab, var(--night-400) 10%, transparent) 45%,
    transparent 70%
  );
  opacity: 0;
  transition: opacity 0.3s var(--fx-ease);
  pointer-events: none;
}
.s-fx-glow:hover::before {
  opacity: 1;
}
.s-feature.s-fx-glow {
  position: relative;
}
@media (prefers-reduced-motion: no-preference) {
  .s-plan {
    transition:
      translate 0.3s var(--fx-ease),
      box-shadow 0.3s var(--fx-ease);
  }
  .s-plan:hover {
    translate: 0 -0.25rem;
    box-shadow:
      0 0 0 1px var(--c-site-line),
      0 1.25rem 2.5rem -1rem color-mix(in oklab, var(--night-600) 32%, transparent);
  }
  .s-plan--pick:hover {
    box-shadow:
      0 0 0 1px var(--c-accent-edge),
      0 1.75rem 3.5rem -1rem color-mix(in oklab, var(--c-site-primary) 45%, transparent);
  }
  .s-feature:hover {
    box-shadow:
      var(--e-1),
      0 1.25rem 2.5rem -1.25rem color-mix(in oklab, var(--night-600) 30%, transparent);
  }
}

/* ── The bar: nav links underline from the reading side; the switches turn ─────────────────────────────────── */
.s-nav__link {
  position: relative;
}
.s-nav__link::after {
  content: '';
  position: absolute;
  inset-inline: var(--s-3);
  inset-block-end: 0.35rem;
  height: 2px;
  border-radius: 1px;
  background: linear-gradient(90deg, var(--c-site-primary), var(--fx-gold));
  scale: 0 1;
  transform-origin: var(--fx-from) 50%;
  pointer-events: none;
}
@media (prefers-reduced-motion: no-preference) {
  .s-nav__link::after {
    transition: scale 0.25s var(--fx-ease);
  }
}
.s-nav__link:hover::after,
.s-nav__link[aria-current='page']::after {
  scale: 1 1;
}
@media (prefers-reduced-motion: no-preference) {
  .s-themeswitch[data-fx-turned] .s-themeswitch__sun {
    animation: s-fx-sun 0.5s var(--fx-spring);
  }
  .s-themeswitch[data-fx-turned] .s-themeswitch__moon {
    animation: s-fx-moon 0.5s var(--fx-spring);
  }
  .s-themeswitch:active .ui-icon {
    scale: 0.85;
  }
  .s-langswitch .ui-icon {
    transition: rotate 0.4s var(--fx-spring);
  }
  .s-langswitch:hover .ui-icon {
    rotate: 25deg;
  }
  [dir='rtl'] .s-langswitch:hover .ui-icon {
    rotate: -25deg;
  }
}
@keyframes s-fx-sun {
  from {
    opacity: 0;
    transform: rotate(-120deg) scale(0.3);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
@keyframes s-fx-moon {
  from {
    opacity: 0;
    transform: rotate(80deg) scale(0.3);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

/* ── FAQ: the question warms on hover, the answer settles in ───────────────────────────────────────────────── */
@media (prefers-reduced-motion: no-preference) {
  .s-faq .ui-disc__btn {
    transition: color 0.2s var(--fx-ease);
  }
  .s-faq .ui-disc__chev {
    transition: translate 0.3s var(--fx-spring);
  }
  .s-faq .ui-disc__btn:hover .ui-disc__chev {
    translate: 0 0.125rem;
  }
  .s-faq .ui-disc[data-state='open'] .s-faq__a {
    animation: s-fx-settle 0.4s var(--fx-ease);
  }
}
.s-faq .ui-disc__btn:hover {
  color: var(--c-site-primary-ink);
}
@keyframes s-fx-settle {
  from {
    opacity: 0;
    transform: translateY(-0.25rem);
  }
}

}
/* surfaces/admin-misc.css */
@layer surfaces {
/* Surface: a- (back office: slug, messages). Moved verbatim from counter.css; owned by that surface.
   Layout-only once migrated (design-system.md §1.1): colour, borders, padding and type come from ui-* components. */
.a-narrow {
  max-width: 560px;
}
.a-msg {
  max-width: 28em;
  color: var(--c-muted);
}
.a-slugfield {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--f-mono);
}
.a-slugfield input {
  flex: 1;
  min-height: var(--t-min);
  border-radius: var(--r-sm);
  border: 1.5px solid var(--c-line);
  padding: 0 12px;
  font: 500 16px/1.2 var(--f-mono);
}
.a-table select {
  min-height: var(--t-min);
  border-radius: var(--r-sm);
  border: 1.5px solid var(--c-line);
  background: var(--c-paper);
  font: 500 14px/1.2 var(--f-sans);
  padding: 0 8px;
}

}
/* surfaces/support.css */
@layer surfaces {
/* Surface: x-help (release-v2 P19, R-64; experience-v2 §7.6, §13 H20, O2): Bellou helping in a client's account.
   apps/web/src/staff/support-banner.ts renders it; this file owns its look. Indigo (--c-acting) is Bellou's own
   signal and is used nowhere else, so the bar can never be mistaken for a status or for the client's brand.

   .x-help      the bar on every staff screen (workspace under the app bar, the cashier above the board): one line,
                at most 48 px, sticky. Phones show the compact line.
   .x-helpchip  the kitchen screen's corner chip in its app bar: the height of the bar's other controls, so the
                tile grid never moves.
   Never in print: on the screens that show it, @media print hides it (print views also never render it). */

.x-help {
  position: sticky;
  inset-block-start: 0;
  z-index: var(--z-banner);
  display: flex;
  align-items: center;
  gap: var(--s-2);
  min-height: var(--h-actbar);
  max-height: var(--s-12);
  padding-block: var(--s-1);
  padding-inline: var(--s-4);
  border-block-end: 1px solid var(--c-acting-edge);
  background: var(--c-acting);
  color: var(--c-on-acting);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
  color-scheme: dark;
}
.x-help__mark {
  display: inline-flex;
  flex: none;
}
.x-help__mark .ui-icon {
  width: var(--s-5);
  height: var(--s-5);
}
.x-help__fc {
  display: none;
}
.x-help__line {
  flex: 1;
  min-width: 0;
  margin: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: var(--fw-medium);
}
.x-help__line--compact {
  display: none;
}
.x-help__end {
  flex: none;
  min-height: var(--ctl-sm);
  border-color: var(--c-on-acting);
  background: transparent;
  color: var(--c-on-acting);
  font-size: var(--fs-13);
}
.x-help__end:hover {
  background: var(--c-acting-edge);
}
.x-help .ui-btn:focus-visible {
  box-shadow: 0 0 0 2px var(--c-on-acting);
}
@media (max-width: 639px) {
  .x-help {
    padding-inline: var(--s-3);
  }
  .x-help__line--full {
    display: none;
  }
  .x-help__line--compact {
    display: block;
  }
}

/* The cashier: the bar heads the banners region, full width above the board. */
.op-banners > .x-help {
  position: relative;
}

/* The kitchen screen's corner chip (O2): never taller than the app bar's own controls. */
.x-helpchip {
  display: inline-flex;
  flex: none;
  align-items: center;
  gap: var(--s-1);
  max-height: var(--ctl-sm);
  padding-block: var(--s-1);
  padding-inline: var(--s-2);
  border-radius: var(--r-pill);
  background: var(--c-acting);
  color: var(--c-on-acting);
  font-size: var(--fs-12);
  font-weight: var(--fw-medium);
  line-height: 1;
  white-space: nowrap;
}
.x-helpchip .ui-icon {
  width: var(--s-4);
  height: var(--s-4);
}

/* Forced colours: the indigo fill is gone, so the bar says it in words and keeps a border. */
@media (forced-colors: active) {
  .x-help,
  .x-helpchip {
    border: 2px solid CanvasText;
  }
  .x-help__fc {
    display: inline;
    padding-inline: var(--s-1);
    border: 1px solid CanvasText;
    font-weight: var(--fw-strong);
  }
}

/* R-64: never on paper. */
@media print {
  .ui-acting,
  .x-help,
  .x-helpchip {
    display: none !important;
  }
}

/* HQ console › Account (P19): Open as owner and the account status card. */
.x-ownerlist {
  border-block: 1px solid var(--c-line);
}
.x-ownerlist > .ui-listrow {
  padding-inline: 0;
}
.x-ownerlist__end {
  display: flex;
  align-items: center;
  gap: var(--s-3);
}
.x-ownerlist__left {
  color: var(--c-muted);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.x-ownerfoot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
}
.x-ownerfoot > .ui-text {
  flex: 1 1 20rem;
  margin: 0;
}
.x-ownerfoot__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
  margin-inline-start: auto;
}
.x-acctstatus {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: var(--s-3);
}
.x-acctstatus > .ui-status {
  flex: none;
}
.x-acctstatus__text {
  display: flex;
  flex: 1 1 18rem;
  flex-direction: column;
  gap: var(--s-1);
  min-width: 0;
  padding-block-start: 2px;
}
.x-acctstatus__line,
.x-acctstatus__text > .ui-text {
  margin: 0;
}
.x-acctstatus__line {
  color: var(--c-ink);
  font-weight: var(--fw-medium);
}
.x-acctstatus__action {
  flex: none;
  margin-inline-start: auto;
}

/* HQ Live support sessions (P19): the client cell (name over its subdomain), times on one line. */
.x-live__clientcell {
  display: flex;
  flex-direction: column;
  min-width: 9rem;
}
.x-live__clientcell > * {
  white-space: nowrap;
}
.x-live__client {
  color: var(--c-ink);
  font-weight: var(--fw-medium);
  text-decoration: none;
}
.x-live__client:hover {
  text-decoration: underline;
}
.x-live__slug {
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.x-live-table td:has(time),
.x-live-table td:has([data-mask]) {
  white-space: nowrap;
}

}
/* surfaces/help.css */
@layer surfaces {
/* Surface: h- (help centre on bellou.io, surfaces.md E2; restyled by release-v2 P21). Owned by apps/web/src/site.
   Colour from the site palette (Gulf night, site.css). The .d-steps rules after it belong to the dashboard and were left where
   counter.css had them. */
.h-root {
  display: flex;
  flex-direction: column;
  gap: var(--s-10);
  padding-block: var(--s-12) var(--s-16);
}
.h-hero {
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  gap: var(--s-5);
  max-width: var(--w-main);
}
.h-search .ui-input {
  min-height: var(--s-12);
  font-size: var(--fs-16);
}
.h-search {
  border-radius: var(--r-md);
  box-shadow: var(--e-2);
}
.h-body {
  display: grid;
  grid-template-columns: var(--w-subnav) minmax(0, var(--w-main));
  gap: var(--s-12);
  align-items: start;
}
.h-topics {
  position: sticky;
  inset-block-start: calc(var(--s-16) + var(--s-6));
  padding: var(--s-2);
  border: 1px solid var(--c-line);
  border-radius: var(--r-card);
  background: color-mix(in oklab, var(--s-tint-saffron) 50%, var(--c-surface));
  box-shadow: var(--e-1);
}
.h-topics ul {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
  margin: 0;
  padding: 0;
  list-style: none;
}
.h-topic {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  min-height: var(--ctl-h);
  padding-inline: var(--s-2) var(--s-3);
  border-radius: var(--r-sm);
  color: var(--c-ink);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
  font-weight: 500;
  text-decoration: none;
}
.h-topic:hover {
  background: var(--s-tint-ember);
}
.h-topic:focus-visible {
  outline: none;
  box-shadow:
    0 0 0 2px var(--c-bg),
    0 0 0 4px var(--c-focus);
}
.h-topic__icon {
  display: grid;
  flex: none;
  place-items: center;
  width: var(--s-8);
  height: var(--s-8);
  border-radius: var(--r-sm);
  background: var(--c-site-primary-soft);
  color: var(--c-site-primary-ink);
}
.h-topics li:nth-child(3n + 2) .h-topic__icon {
  background: var(--c-site-accent-soft);
  color: var(--s-chip-ink);
}
.h-topics li:nth-child(3n) .h-topic__icon {
  background: var(--s-heat-fill);
  color: #fff;
}
.h-topic__icon .ui-icon {
  width: var(--s-4);
  height: var(--s-4);
}
.h-topic__title {
  flex: 1;
  min-width: 0;
}
.h-topic__n {
  min-width: var(--s-6);
  padding-inline: var(--s-2);
  border-radius: var(--r-pill);
  background: var(--c-site-sunk);
  color: var(--c-muted);
  text-align: center;
  font-size: var(--fs-13);
  font-variant-numeric: tabular-nums;
}
.h-main {
  display: flex;
  flex-direction: column;
  gap: var(--s-10);
  min-width: 0;
}
.h-sec {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  scroll-margin-block-start: calc(var(--s-16) + var(--s-4));
}
.h-sec__title {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  margin: 0;
  font-size: var(--fs-20);
  line-height: var(--lh-20);
  font-weight: 600;
}
.h-sec__title .ui-icon {
  flex: none;
  box-sizing: content-box;
  padding: var(--s-1);
  border-radius: var(--r-sm);
  background: var(--c-site-primary-soft);
  color: var(--c-site-primary-ink);
}
.h-list .ui-disc {
  scroll-margin-block-start: calc(var(--s-16) + var(--s-4));
}
.h-answer {
  margin: 0;
  color: var(--c-muted);
}
.h-none .ui-empty {
  padding-block: var(--s-8);
}
@media (max-width: 1023px) {
  .h-body {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--s-8);
  }
  .h-topics {
    position: static;
    padding: 0;
    border: 0;
    background: none;
    box-shadow: none;
  }
  .h-topics ul {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--s-2);
  }
  .h-topic {
    padding: var(--s-2) var(--s-3);
    border: 1px solid var(--c-line);
    background: var(--c-surface);
    box-shadow: var(--e-1);
  }
}
@media (max-width: 599px) {
  .h-root {
    gap: var(--s-8);
    padding-block: var(--s-8) var(--s-12);
  }
  .h-topics ul {
    grid-template-columns: minmax(0, 1fr);
  }
}

.d-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.d-steps li {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: var(--t-min);
}
.d-steps a {
  color: var(--c-ink);
  font-weight: 600;
}
.d-steps s {
  color: var(--c-muted);
}
.d-check {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid var(--c-line);
  flex: none;
}
.d-done .d-check {
  background: var(--c-ok-ink);
  border-color: var(--c-ok-ink);
}

}
/* surfaces/status.css */
@layer surfaces {
/* Surface: st- (status page on bellou.io, surfaces.md E3; on the FocusWizard frame with a StatePage since
   release-v2 P21). Owned by apps/web/src/site. Layout only: state is shown in words, icon and colour together
   (StatePage + Badge), never colour alone. */
.st-root .ui-tpl__frame {
  display: flex;
  flex-direction: column;
  gap: var(--s-6);
}
.st-frame .ui-state {
  padding-block: var(--s-4) 0;
}
.st-ok .ui-state__icon {
  color: var(--c-ready-ink);
}
.st-degraded .ui-state__icon {
  color: var(--c-late);
}
.st-down .ui-state__icon {
  color: var(--c-danger);
}
.st-card {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--c-line);
  border-radius: var(--r-card);
}
.st-card__title {
  margin: 0;
  padding: var(--s-3) var(--s-4);
  border-block-end: 1px solid var(--c-line);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
  font-weight: 600;
}
.st-list {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
  list-style: none;
}
.st-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-3);
  min-height: var(--row-h);
  padding-inline: var(--s-4);
  border-block-start: 1px solid var(--c-line);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.st-row:first-child {
  border-block-start: 0;
}
.st-row__name {
  min-width: 0;
}
.st-meta {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
  text-align: center;
}

}
/* surfaces/ds.css */
@layer surfaces {
/* Surface: ds- (design-system gallery, /_ds in development). Layout only. */
.ds-root {
  max-width: var(--w-content);
  margin-inline: auto;
  padding: var(--s-6) var(--s-4) var(--s-16);
}
.ds-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--s-4);
  padding-block-end: var(--s-4);
}
.ds-head__titles {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  max-width: 40rem;
}
.ds-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-4);
}
.ds-toc ul {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2) var(--s-4);
  margin: 0;
  padding: 0;
  list-style: none;
}
.ds-main {
  display: flex;
  flex-direction: column;
  gap: var(--s-10);
  padding-block-start: var(--s-6);
}
.ds-sec {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  padding-block-start: var(--s-6);
  border-block-start: 1px solid var(--c-line);
  scroll-margin-block-start: var(--s-4);
}
.ds-row {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}
.ds-row__items {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-3);
}
.ds-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--s-6);
}
@media (min-width: 1024px) {
  .ds-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
  }
}
.ds-compare {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--s-6);
}
@media (min-width: 600px) {
  .ds-compare {
    grid-template-columns: 1fr 1fr;
  }
}
.ds-compare__col {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}
.ds-before {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  min-height: var(--hit-main);
  padding-inline: var(--s-6);
  border-radius: var(--r-sm);
  background: var(--c-now);
  color: var(--c-on-now);
  font-weight: 600;
}
.ds-banners {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}
.ds-banners .ui-banner {
  position: static;
}
.ds-stats {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--s-6);
}
@media (min-width: 600px) {
  .ds-stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
.ds-shell {
  border: 1px solid var(--c-line);
  border-radius: var(--r-md);
  background: var(--c-bg);
  overflow: clip;
}
.ds-shell .ui-appbar {
  position: static;
}
.ds-shell__body {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
}
@media (min-width: 1024px) {
  .ds-shell__body {
    grid-template-columns: var(--w-rail) 1fr;
  }
}
@media (max-width: 1023px) {
  .ds-shell__body > .ui-nav {
    display: none;
  }
}
@media (min-width: 1024px) {
  .ds-shell > .ui-nav--bar {
    display: none;
  }
}
.ds-shell > .ui-nav--bar {
  border-block-start: 1px solid var(--c-line);
  background: var(--c-surface);
}
.ds-shell__main {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  padding-inline: var(--s-4);
  min-width: 0;
}
.ds-matrix {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--s-4);
}
@media (min-width: 1024px) {
  .ds-matrix {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
.ds-pane {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  padding: var(--s-4);
  border: 1px solid var(--c-line);
  border-radius: var(--r-md);
  background: var(--c-bg);
}
.ds-tablewrap {
  overflow-x: auto;
}
.ds-table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--fs-14);
}
.ds-table th,
.ds-table td {
  padding: var(--s-2) var(--s-3);
  border-block-end: 1px solid var(--c-line);
  text-align: start;
  vertical-align: middle;
}
.ds-swatches {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
}
.ds-swatch {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
}
.ds-swatch .ui-color__chip {
  width: var(--s-6);
  height: var(--s-6);
}
.ds-icons {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(8rem, 1fr));
  gap: var(--s-3);
  margin: 0;
  padding: 0;
  list-style: none;
}
.ds-icons li {
  display: flex;
  align-items: center;
  gap: var(--s-2);
}

/* ── Design system v2 gallery (P08) ───────────────────────────────────────────────────────────────────────── */
.ds-v2sws {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
}
.ds-v2sw {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-1);
  font-size: var(--fs-12);
}
.ds-v2sw__chip {
  width: var(--s-10);
  height: var(--s-10);
  border-radius: var(--r-control);
  box-shadow: inset 0 0 0 1px var(--c-line);
}
.ds-v2sw__chip[data-var='n-0'] {
  background: var(--n-0);
}
.ds-v2sw__chip[data-var='n-1'] {
  background: var(--n-1);
}
.ds-v2sw__chip[data-var='n-2'] {
  background: var(--n-2);
}
.ds-v2sw__chip[data-var='n-3'] {
  background: var(--n-3);
}
.ds-v2sw__chip[data-var='n-4'] {
  background: var(--n-4);
}
.ds-v2sw__chip[data-var='n-5'] {
  background: var(--n-5);
}
.ds-v2sw__chip[data-var='n-6'] {
  background: var(--n-6);
}
.ds-v2sw__chip[data-var='n-7'] {
  background: var(--n-7);
}
.ds-v2sw__chip[data-var='n-8'] {
  background: var(--n-8);
}
.ds-v2sw__chip[data-var='n-9'] {
  background: var(--n-9);
}
.ds-v2sw__chip[data-var='n-10'] {
  background: var(--n-10);
}
.ds-v2sw__chip[data-var='n-11'] {
  background: var(--n-11);
}
.ds-v2sw__chip[data-var='n-12'] {
  background: var(--n-12);
}
.ds-v2sw__chip[data-var='c-chrome-bg'] {
  background: var(--c-chrome-bg);
}
.ds-v2sw__chip[data-var='c-chrome-ink'] {
  background: var(--c-chrome-ink);
}
.ds-v2sw__chip[data-var='c-chrome-muted'] {
  background: var(--c-chrome-muted);
}
.ds-v2sw__chip[data-var='c-chrome-line'] {
  background: var(--c-chrome-line);
}
.ds-v2sw__chip[data-var='c-chrome-selected'] {
  background: var(--c-chrome-selected);
}
.ds-v2sw__chip[data-var='c-acting'] {
  background: var(--c-acting);
}
.ds-v2sw__chip[data-var='c-on-acting'] {
  background: var(--c-on-acting);
}
.ds-v2sw__chip[data-var='c-acting-soft'] {
  background: var(--c-acting-soft);
}
.ds-v2sw__chip[data-var='c-acting-ink'] {
  background: var(--c-acting-ink);
}
.ds-v2densities {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(var(--w-aside), 1fr));
  gap: var(--s-4);
  width: 100%;
}
.ds-v2density {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  padding: var(--pad-card);
  border: 1px solid var(--c-line);
  border-radius: var(--r-card);
  background: var(--c-surface);
  font-size: var(--fs-body);
}
.ds-v2radius {
  display: grid;
  place-items: center;
  width: var(--s-16);
  height: var(--s-12);
  border: 1px solid var(--n-7);
  background: var(--n-1);
  font-size: var(--fs-12);
}
.ds-v2radius[data-r='control'] {
  border-radius: var(--r-control);
}
.ds-v2radius[data-r='card'] {
  border-radius: var(--r-card);
}
.ds-v2radius[data-r='dialog'] {
  border-radius: var(--r-dialog);
}
.ds-v2radius[data-r='pill'] {
  border-radius: var(--r-pill);
}
.ds-v2type {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}
.ds-v2type__row {
  display: flex;
  align-items: baseline;
  gap: var(--s-4);
  margin: 0;
}
.ds-v2type__row .ui-mono {
  min-width: var(--s-16);
  color: var(--c-muted);
  font-size: var(--fs-12);
}
.ds-v2type__row[data-fs='28'] span:last-child {
  font-size: var(--fs-28);
  line-height: var(--lh-28);
}
.ds-v2type__row[data-fs='24'] span:last-child {
  font-size: var(--fs-24);
  line-height: var(--lh-24);
}
.ds-v2type__row[data-fs='20'] span:last-child {
  font-size: var(--fs-20);
  line-height: var(--lh-20);
}
.ds-v2type__row[data-fs='16'] span:last-child {
  font-size: var(--fs-16);
  line-height: var(--lh-16);
}
.ds-v2type__row[data-fs='14'] span:last-child {
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.ds-v2type__row[data-fs='13'] span:last-child {
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.ds-v2type__row[data-fs='12'] span:last-child {
  font-size: var(--fs-12);
  line-height: var(--lh-12);
}
.ds-v2bignum {
  margin: 0;
  font-size: var(--fs-40);
  line-height: var(--lh-40);
}
.ds-v2ic {
  display: inline-grid;
  place-items: center;
  width: var(--s-6);
  height: var(--s-6);
}
.ds-v2ic .ui-icon {
  width: var(--s-4);
  height: var(--s-4);
}
.ds-v2ic--20 .ui-icon {
  width: var(--s-5);
  height: var(--s-5);
}
.ds-v2states {
  display: flex;
  flex-direction: column;
  gap: var(--s-6);
  width: 100%;
}
.ds-v2state {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  width: 100%;
}
.ds-v2frame {
  width: 100%;
  padding: var(--s-6);
  border: 1px dashed var(--n-7);
  border-radius: var(--r-card);
  background: var(--c-bg);
}
.ds-v2frame--focus {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(var(--w-aside), 1fr));
  gap: var(--s-6);
}
.ds-v2pad {
  padding: var(--pad-card);
}
.ds-v2w {
  width: 100%;
  max-width: var(--w-frame);
}
.ds-v2grid2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(var(--w-aside), 1fr));
  gap: var(--s-4);
  width: 100%;
}
.ds-v2grid3 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(var(--w-date), 1fr));
  gap: var(--s-4);
  width: 100%;
}
.ds-v2person {
  display: flex;
  align-items: center;
  gap: var(--s-3);
}
.ds-v2person__t {
  display: flex;
  flex-direction: column;
}
.ds-v2shell {
  width: 100%;
  overflow: hidden;
  border: 1px solid var(--c-line);
  border-radius: var(--r-card);
  background: var(--c-bg);
}
.ds-v2shell .ui-appbar {
  position: static;
}
.ds-v2shell .ui-actbar {
  position: static;
}
.ds-v2shell__body {
  display: grid;
  grid-template-columns: var(--w-rail-hq) minmax(0, 1fr);
  min-height: calc(var(--h-chart) * 2);
}
.ds-v2shell__rail {
  background: var(--c-chrome-bg);
}
.ds-v2shell__rail--ws {
  border-inline-end: 1px solid var(--c-line);
  background: var(--c-surface);
}
.ds-v2shell__main {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  min-width: 0;
}
@media (max-width: 1023px) {
  .ds-v2shell__body {
    grid-template-columns: var(--w-rail-icons) minmax(0, 1fr);
  }
}
.ds-v2acct {
  cursor: default;
}
.ds-v2guest {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-3);
  max-width: var(--w-phone);
  margin-inline: auto;
  padding: var(--s-6);
  text-align: center;
}
.ds-v2phone {
  position: relative;
  width: var(--w-phone);
  max-width: 100%;
  overflow: hidden;
  border: 1px solid var(--c-line);
  border-radius: var(--r-dialog);
}
.ds-v2phone .ui-bottombar {
  position: static;
  display: block;
}
.ds-v2acting {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  width: 100%;
}
.ds-v2acting__item {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
}
.ds-v2acting .ui-actbar {
  position: static;
  border-radius: var(--r-control);
}
.ds-v2font {
  font-size: var(--fs-24);
  line-height: var(--lh-24);
  font-weight: var(--fw-strong);
}
.ds-v2font[data-font='rubik'] {
  font-family: 'Rubik', var(--f-ui);
}
.ds-v2font[data-font='cairo'] {
  font-family: 'Cairo', var(--f-ui);
}
.ds-v2font[data-font='almarai'] {
  font-family: 'Almarai', var(--f-ui);
}

}
/* surfaces/w.css */
@layer surfaces {
/* Customer waiting page and its state pages (template `customer`, surfaces.md A1/A3). Prefix w-.
   Reads design tokens only, so it works in light, dark (data-theme=auto) and Arabic without extra rules.
   P20: part of the guest stylesheet (guest-manifest.json): every colour is a brand-set or semantic token, so
   Bellou red can't reach a café's guests, and READY is Bellou's fixed green. */

/* Live regions and the no-script note (page.ts), which the guest sheet carries itself (no staff CSS here). */
.c-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.c-note {
  margin: var(--s-4);
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
  text-align: center;
}

body.ui-page.w-ready {
  background: var(--c-ready);
}
body.ui-page.w-called {
  background: var(--c-now);
}

.w-root {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  /* The kit's surface style (experience-v2 §10.1): neutral = the page background, tinted = the brand's tint. */
  background: var(--c-page-tint, var(--c-bg));
  color: var(--c-ink);
}
/* "Brand header": the app bar is the brand band, with its readable text and edge (P03 band roles). */
.w-root[data-surface='header'] .ui-appbar {
  border-block-end-color: transparent;
  background: var(--c-band);
  color: var(--c-on-band);
  box-shadow: inset 0 -1px 0 var(--c-band-edge, transparent);
}
.w-root[data-surface='header'] .ui-appbar .ui-iconbtn,
.w-root[data-surface='header'] .ui-appbar .ui-btn--ghost,
.w-root[data-surface='header'] .ui-appbar__scope {
  color: inherit;
}
/* The kit's display typeface: the café's name, the ticket label and headings; body text stays the UI face. */
.w-root .ui-appbar__name,
.w-ticket__label,
.w-root .ui-h1,
.w-root .ui-h3,
.w-ready__title,
.w-called__title {
  font-family: var(--f-display, inherit);
}
/* Larger text (⋯ menu): one switch scales the whole page, tokens included. */
:root[data-big] .w-root {
  zoom: 1.2;
}

/* The app bar spans the screen; its content lines up with the 480 column on wide screens. */
.w-root .ui-appbar {
  padding-inline: max(var(--s-4), calc((100% - var(--w-customer)) / 2 + var(--s-4)));
}
.w-root .ui-appbar__brand {
  max-width: none;
  flex: 1 1 auto;
}
/* The branch name may shrink too (it never squeezes the café's name out). */
.w-root .ui-appbar__scope {
  flex: 0 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}
/* The café's name is cut at its own end: an English name on an Arabic page ends "…" on the right, not the left. */
.w-root .ui-appbar__name {
  unicode-bidi: plaintext;
  min-width: 0;
}
.w-root .ui-appbar__name:empty {
  display: none;
}
/* G-11 (prd-guest §4.4): a café with several branches keeps the branch on phones, as a second line under the bar's
   first row (the shared app bar hides the scope below 600 px). */
@media (max-width: 599px) {
  .w-root .ui-appbar:has(.w-scope--multi) {
    flex-wrap: wrap;
    row-gap: 0;
    padding-block: var(--s-2);
  }
  .w-root .ui-appbar__scope.w-scope--multi {
    display: block;
    order: 3;
    flex: 1 0 100%;
    padding-block-start: var(--s-1);
    font-size: var(--fs-14);
    line-height: var(--lh-14);
    white-space: nowrap;
  }
}

/* The café's logo in the app bar (experience-v2 §10.2: at most 140×32), on the plate the P03 rule picked. */
.w-logo {
  display: inline-flex;
  align-items: center;
  flex: none;
  height: var(--s-10);
  max-width: calc(140px + var(--s-4));
}
.w-logo img {
  display: block;
  height: var(--s-8);
  width: auto;
  max-width: 140px;
  object-fit: contain;
}
.w-logo[data-plate='white'],
.w-logo[data-plate='brand'],
.w-logo[data-plate='ink'] {
  padding: var(--s-1) var(--s-2);
  border-radius: var(--r-sm);
}
.w-logo[data-plate='white'] img,
.w-logo[data-plate='brand'] img,
.w-logo[data-plate='ink'] img {
  height: var(--s-6);
}
.w-logo[data-plate='white'] {
  background: #fff;
  box-shadow: inset 0 0 0 1px var(--c-line);
}
.w-logo[data-plate='brand'] {
  background: var(--brand);
  box-shadow: inset 0 0 0 1px var(--brand-edge, transparent);
}
.w-logo[data-plate='ink'] {
  background: var(--c-chrome-bg);
}
.w-bigitem[aria-checked='false'] .ui-icon {
  visibility: hidden;
}

.w-body {
  flex: 1 0 auto;
  width: 100%;
  max-width: var(--w-customer);
  margin-inline: auto;
  padding: var(--s-4) var(--s-4) calc(var(--s-6) + env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  box-sizing: border-box;
}
.w-body--state {
  justify-content: center;
}
.w-center {
  text-align: center;
  align-self: center;
}
.w-strong {
  font-weight: 600;
}
.w-foot {
  margin: auto 0 0;
  padding-block-start: var(--s-4);
  text-align: center;
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
}

/* ── Ticket: number hero, pickup line, items. Same size and place in every live stage. */
.w-ticket {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-2);
  padding: var(--s-5);
  overflow: hidden;
  border: 1px solid var(--c-line);
  border-radius: var(--kit-radius-lg, var(--r-lg));
  background: var(--c-surface);
  color: var(--c-ink);
  text-align: center;
  container-type: inline-size;
}
.w-ticket__stripe {
  position: absolute;
  inset-inline: 0;
  inset-block-start: 0;
  height: calc(var(--s-1) * 1.5);
  background: var(--brand);
  /* P03 fill rule: a hairline under a pale stripe (yellow, white) so it still reads on the white card. */
  box-shadow: inset 0 -1px 0 var(--brand-edge, transparent);
}
.w-num {
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.02em;
  font-size: min(10rem, var(--num-fit));
}
.w-num--l1,
.w-num--l2 {
  --num-fit: calc((100cqi - var(--s-10)) / 2 * 1.6);
}
.w-num--l3 {
  --num-fit: calc((100cqi - var(--s-10)) / 3 * 1.6);
}
.w-num--l4 {
  --num-fit: calc((100cqi - var(--s-10)) / 4 * 1.6);
}
.w-num--l5 {
  --num-fit: calc((100cqi - var(--s-10)) / 5 * 1.6);
}
.w-num--l6 {
  --num-fit: calc((100cqi - var(--s-10)) / 6 * 1.6);
}
.w-ticket__where {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  font-size: var(--fs-18);
  line-height: var(--lh-18);
  font-weight: 600;
}
.w-ticket__where .ui-icon {
  color: var(--c-brand-ink);
}
.w-ticket__items {
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
/* The number's line box is fixed for its length class, so the web font swapping in never moves the page (CLS). */
.w-num {
  display: block;
  height: 1em;
}

/* The café's welcome line (prd-guest §4.1), under the ticket while the order is on its way. */
.w-welcome {
  margin: 0;
  text-align: center;
  color: var(--c-ink);
  font-size: var(--fs-16);
  line-height: var(--lh-16);
  font-weight: 500;
}

/* "Last updated N s ago" (prd-guest §6 Offline). */
.w-stale .ui-callout__text {
  font-variant-numeric: tabular-nums;
}

/* Branch buttons on the not-found page (prd-guest §6: at most six). */
.w-branches {
  display: flex;
  flex-direction: column;
  align-self: stretch;
  gap: var(--s-2);
  margin-block-start: var(--s-3);
}
.w-hero .w-branches .ui-btn {
  margin: 0;
  justify-content: space-between;
}
.w-hero .ui-link {
  font-weight: 600;
}

/* ── Progress: three steps, the current one filled. Steps sit in DOM order, so Arabic mirrors itself. */
.w-progress {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--s-2);
  margin: 0;
  padding: 0;
  list-style: none;
}
.w-progress__step {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  min-width: 0;
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.w-progress__bar {
  height: var(--s-2);
  border-radius: var(--r-pill);
  background: var(--c-line);
  overflow: hidden;
}
.w-progress__step[data-state='done'] .w-progress__bar {
  background: var(--c-ink);
}
.w-progress__step[data-state='now'] {
  color: var(--c-ink);
  font-weight: 700;
}
/* The current step is the café's colour (prd-guest §6, A10), ringed when the fill is too pale to see (P03). */
.w-progress__step[data-state='now'] .w-progress__bar {
  background: var(--c-accent);
  box-shadow: inset 0 0 0 1px var(--c-accent-fill-edge);
}
@media (prefers-reduced-motion: no-preference) {
  .w-progress__step[data-state='now'] .w-progress__bar {
    background: linear-gradient(90deg, var(--c-accent) 30%, var(--c-accent-soft) 50%, var(--c-accent) 70%) 0
      0 / 300% 100%;
    animation: w-progress 2.4s linear infinite;
  }
}
@keyframes w-progress {
  to {
    background-position: -150% 0;
  }
}

/* ── Status line under the progress. */
.w-status {
  display: flex;
  align-items: flex-start;
  gap: var(--s-2);
  margin: 0;
}
.w-status__text {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
}
.w-status b {
  font-size: var(--fs-20);
  line-height: var(--lh-20);
  font-weight: 700;
}
.w-status__text span {
  color: var(--c-muted);
}
.w-status--late .ui-icon,
.w-status--late b {
  color: var(--c-late);
}
.w-status--late .ui-icon {
  font-size: var(--fs-20);
  margin-block-start: var(--s-1);
}

/* ── Notify chooser, then its confirmation row. */
.w-notify {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}
.w-notify--on {
  gap: var(--s-3);
}
.w-on {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  margin: 0;
  padding: var(--s-3) var(--s-4);
  border-radius: var(--r-sm);
  background: var(--c-ready-soft);
  color: var(--c-ready-ink);
  font-weight: 600;
}
.w-backup {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: var(--s-1) var(--s-3);
}
.w-note {
  margin: 0;
  text-align: center;
}
.w-sms {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
}
/* §8.4 (AC-22): an iPhone rung only by the page: the silent-switch note and the safer way, under "Ringing on". */
.w-silent {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-1) var(--s-3);
  padding: var(--s-3) var(--s-4);
  border-radius: var(--r-sm);
  background: var(--c-surface-2);
  color: var(--c-ink);
}
.w-silent > .ui-icon {
  flex: none;
  font-size: var(--fs-20);
}
.w-silent > p {
  flex: 1 1 12rem;
  margin: 0;
}
/* G-06: the in-app browser callout's one action. */
.w-inapp__act {
  margin-block-start: var(--s-2);
}
/* G-12: "What could we do better?" after "Too long". */
.w-better {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
}

/* ── While you wait: tiles, one open panel, the offer. */
.w-extras {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
}
.w-tiles {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(6rem, 1fr));
  gap: var(--s-3);
}
.w-tile {
  appearance: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--s-2);
  min-height: calc(var(--hit-main) + var(--s-6));
  margin: 0;
  padding: var(--s-3);
  border: 1px solid var(--c-line-strong);
  border-radius: var(--r-md);
  background: var(--c-surface);
  color: var(--c-ink);
  font: inherit;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
}
.w-tile .ui-icon {
  font-size: var(--fs-24);
}
.w-tile:hover {
  border-color: var(--c-ink);
}
.w-tile[aria-expanded='true'] {
  border-color: var(--c-accent-edge);
  background: var(--c-brand-soft);
  box-shadow: inset 0 0 0 1px var(--c-accent-edge);
}
.w-tile:focus-visible,
.w-face:focus-visible,
.w-bead:focus-visible,
.w-cell:focus-visible {
  outline: none;
  box-shadow:
    0 0 0 2px var(--c-surface),
    0 0 0 4px var(--c-focus);
}
.w-offer {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding: var(--s-3) var(--s-4);
  border-radius: var(--kit-radius, var(--r-md));
  background: var(--c-accent-soft);
  color: var(--c-ink);
}
.w-offer img {
  width: var(--s-12);
  height: var(--s-12);
  border-radius: var(--r-sm);
  object-fit: cover;
}
.w-offer__text {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-width: 0;
}
.w-offer__text span {
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.w-offer__price {
  font-weight: 700;
}

/* ── Done, cancelled, expired, not found, error: one centred message. */
.w-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-3);
  padding-block: var(--s-8) var(--s-4);
  text-align: center;
}
.w-hero .ui-btn {
  margin-block-start: var(--s-3);
}
.w-hero__mark {
  display: grid;
  place-items: center;
  width: var(--s-16);
  height: var(--s-16);
  border-radius: var(--r-pill);
  background: var(--c-surface-2);
  color: var(--c-muted);
  font-size: var(--fs-32);
}
.w-hero__mark--ok {
  background: var(--c-ready-soft);
  color: var(--c-ready-ink);
}
.w-rate {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}
.w-faces {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--s-3);
}
.w-face {
  appearance: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-2);
  min-height: calc(var(--hit-main) + var(--s-8));
  margin: 0;
  padding: var(--s-3) var(--s-2);
  border: 1px solid var(--c-line-strong);
  border-radius: var(--r-md);
  background: var(--c-surface);
  color: var(--c-ink);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}
.w-face:hover {
  border-color: var(--c-ink);
}
.w-face .ui-icon {
  font-size: var(--fs-32);
}
.w-links {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
}

/* ── Ready: the whole screen turns green, in both themes; text is white except on the ticket. */
.w-root[data-stage='ready'] {
  background: var(--c-ready);
  color: #fff;
}
.w-root[data-stage='ready'] .ui-appbar {
  border-block-end-color: transparent;
  background: transparent;
  color: #fff;
}
.w-root[data-stage='ready'] .w-logo[data-ready-plate] {
  padding: var(--s-1) var(--s-2);
  border-radius: var(--r-sm);
}
.w-root[data-stage='ready'] .w-logo[data-ready-plate] img {
  height: var(--s-6);
}
/* R-65 on the Ready green: a logo that would disappear into it sits on the plate the rule picked for it. */
.w-root[data-stage='ready'] .w-logo[data-ready-plate='white'] {
  background: #fff;
  box-shadow: none;
}
.w-root[data-stage='ready'] .w-logo[data-ready-plate='brand'] {
  background: var(--brand);
  box-shadow: inset 0 0 0 1px var(--brand-edge, transparent);
}
.w-root[data-stage='ready'] .w-logo[data-ready-plate='ink'] {
  background: var(--c-chrome-bg);
  box-shadow: none;
}
.w-root[data-stage='ready'] .ui-appbar .ui-iconbtn {
  color: #fff;
}
.w-root[data-stage='ready'] .w-ticket {
  border-color: var(--c-ready-edge);
}
.w-root[data-stage='ready'] .w-ticket__where {
  font-size: var(--fs-24);
  line-height: var(--lh-24);
  font-weight: 700;
}
.w-root[data-stage='ready'] .w-ticket__where .ui-icon {
  color: var(--c-ready-ink);
}
.w-ready__head {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-2);
  margin-block-start: var(--s-2);
}
.w-ready__mark {
  display: grid;
  place-items: center;
  width: var(--s-16);
  height: var(--s-16);
  border-radius: var(--r-pill);
  background: #fff;
  color: var(--c-ready);
  font-size: var(--fs-32);
}
.w-ready__note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--s-2);
  margin: 0;
  padding: var(--s-3) var(--s-4);
  border-radius: var(--r-md);
  background: rgb(255 255 255 / 0.14);
  color: #fff;
  font-weight: 600;
}
.w-ready__note .ui-icon {
  flex: none;
  font-size: var(--fs-20);
}
.w-ready__title {
  margin: 0;
  text-align: center;
  font-size: var(--fs-40);
  line-height: var(--lh-40);
  font-weight: 800;
}
.w-ready__title:focus {
  outline: none;
}
.w-ready__hint {
  margin: 0;
  text-align: center;
  font-size: var(--fs-18);
  line-height: var(--lh-18);
}
.w-ready__stop.ui-btn {
  border-color: transparent;
  background: #fff;
  color: var(--c-ready);
}
/* "I've picked it up": the quieter of the two, outlined in white on the fixed green. */
.w-ready__done.ui-btn {
  border-color: #fff;
  background: transparent;
  color: #fff;
}
.w-root[data-stage='ready'] .w-foot {
  color: #fff;
}
.w-root[data-stage='ready'] :focus-visible {
  outline: none;
  box-shadow:
    0 0 0 2px var(--c-ready),
    0 0 0 5px #fff;
}

/* ── Called to the counter: the whole screen turns Bellou's fixed amber ("now"), in both themes and every café,
   so it reads as "come over" and never as READY green. Dark ink on the amber (about 10:1). */
.w-root[data-stage='called'] {
  background: var(--c-now);
  color: var(--c-on-now);
}
.w-root[data-stage='called'] .ui-appbar {
  border-block-end-color: transparent;
  background: transparent;
  color: var(--c-on-now);
}
.w-root[data-stage='called'] .ui-appbar .ui-iconbtn {
  color: var(--c-on-now);
}
/* The café's logo sits on a white plate here: the amber is not its colour. */
.w-root[data-stage='called'] .w-logo:has(img) {
  padding: var(--s-1) var(--s-2);
  border-radius: var(--r-sm);
  background: #fff;
}
.w-root[data-stage='called'] .w-ticket__where {
  font-size: var(--fs-24);
  line-height: var(--lh-24);
  font-weight: 700;
}
.w-called__head {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-2);
  margin-block-start: var(--s-2);
  text-align: center;
}
.w-called__mark {
  display: grid;
  place-items: center;
  width: var(--s-16);
  height: var(--s-16);
  border-radius: var(--r-pill);
  background: var(--c-on-now);
  color: var(--c-now);
  font-size: var(--fs-32);
}
.w-called__title {
  margin: 0;
  font-size: var(--fs-32);
  line-height: var(--lh-32);
  font-weight: 800;
  text-wrap: balance;
}
.w-called__title:focus {
  outline: none;
}
.w-called__why {
  margin: 0;
  font-size: var(--fs-18);
  line-height: var(--lh-18);
  max-width: 28em;
}
.w-called__ack.ui-btn {
  border-color: transparent;
  background: var(--c-on-now);
  color: #fff;
}
.w-root[data-stage='called'] .w-ready__note {
  background: color-mix(in oklab, var(--c-on-now) 10%, transparent);
  color: var(--c-on-now);
}
.w-root[data-stage='called'] .w-foot {
  color: var(--c-on-now);
}
.w-root[data-stage='called'] :focus-visible {
  outline: none;
  box-shadow:
    0 0 0 2px var(--c-now),
    0 0 0 5px var(--c-on-now);
}

}
/* surfaces/j.css */
@layer surfaces {
/* Join by number /b/<branch> (template `focus`, surfaces.md A2). Prefix j-. Uses the customer shell from w.css. */

.w-body--focus {
  max-width: calc(var(--w-focus) + var(--s-8));
  padding-block-start: var(--s-6);
}
.j-card {
  display: flex;
  flex-direction: column;
  gap: var(--s-5);
}
.j-head {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
}
/* A small receipt sketch that shows where the number is. Decorative (aria-hidden). */
.j-receipt {
  display: flex;
  align-items: center;
  gap: var(--s-4);
  padding: var(--s-3) var(--s-4);
  border: 1px solid var(--c-line);
  border-radius: var(--r-sm);
  background: var(--c-surface-2);
  color: var(--c-muted);
}
.j-receipt > .ui-icon {
  font-size: var(--fs-24);
}
.j-receipt__lines {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  gap: var(--s-2);
}
.j-receipt__lines span {
  height: var(--s-1);
  border-radius: var(--r-pill);
  background: var(--c-line);
}
.j-receipt__lines span + span {
  width: 60%;
}
.j-receipt__order {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: var(--s-1) var(--s-3);
  border: 2px solid var(--c-accent-edge);
  border-radius: var(--r-xs);
  color: var(--c-ink);
}
.j-receipt__num {
  font-size: var(--fs-24);
  line-height: var(--lh-24);
  font-weight: 800;
}
.j-field .ui-input {
  font-size: var(--fs-24);
  text-align: center;
}

}
/* surfaces/hq.css */
@layer surfaces {
/* Surface: a- (Bellou HQ back office, rebuilt on the design system; surfaces D). Layout only: colour, type and
   controls come from ui-* components and tokens. The older a- rules in admin.css / admin-misc.css are still read
   by the dashboard until it migrates; class names here never reuse them. */

.a-page {
  margin: 0;
  background: var(--c-bg);
  color: var(--c-ink);
  /* HQ is compact: 13/18 body from the density tokens (html[data-density=compact]). */
  font-size: var(--fs-body);
  line-height: var(--lh-body);
}
.a-page:lang(ar) {
  line-height: calc(var(--lh-body) + 4px);
}
.a-skip {
  position: absolute;
  inset-inline-start: var(--s-2);
  inset-block-start: calc(-1 * var(--s-16));
  z-index: var(--z-toast);
  padding: var(--s-2) var(--s-4);
  border-radius: var(--r-sm);
  background: var(--c-surface);
  color: var(--c-ink);
  font-weight: 600;
}
.a-skip:focus {
  inset-block-start: var(--s-2);
}

/* ── Shell: light app bar · graphite rail (both themes) · main · bottom bar (P08) ── */
.a-app {
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  background: var(--c-bg);
}
.a-app .ui-appbar--hq {
  padding-inline: var(--s-4);
}
.a-search {
  margin-inline-end: var(--s-2);
}
@media (min-width: 1024px) {
  .a-search {
    margin-inline-end: auto;
    margin-inline-start: var(--s-6);
  }
  .a-app .ui-appbar__end {
    flex: 1;
  }
}
.a-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  flex: 1;
  align-items: stretch;
}
.a-railcol {
  display: none;
  background: var(--c-chrome-bg);
}
.a-railcol .ui-rail {
  position: sticky;
  inset-block-start: var(--s-12);
  height: calc(100dvh - var(--s-12));
}
.a-main {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  padding-block: var(--s-6) calc(var(--h-bottombar) + var(--s-8) + env(safe-area-inset-bottom));
  padding-inline: var(--s-4);
}
.a-main:focus {
  outline: none;
}
.a-main > :not(.ui-tpl) {
  max-width: var(--w-list);
}
.a-app > .ui-bottombar {
  position: fixed;
  inset-inline: 0;
  inset-block-end: 0;
}
.a-main .ui-savebar {
  inset-block-end: calc(var(--h-bottombar) + env(safe-area-inset-bottom));
  margin-inline: calc(-1 * var(--s-4));
}
@media (min-width: 600px) {
  .a-body {
    grid-template-columns: var(--w-rail-icons) minmax(0, 1fr);
  }
  .a-railcol {
    display: block;
  }
  .a-main {
    padding-inline: var(--gutter);
    padding-block-end: var(--s-16);
  }
  .a-main .ui-savebar {
    inset-block-end: 0;
    margin-inline: calc(-1 * var(--gutter));
  }
}
@media (min-width: 1024px) {
  .a-body {
    grid-template-columns: var(--w-rail-hq) minmax(0, 1fr);
  }
}
.a-app--bare .a-main {
  padding-block-end: var(--s-12);
}

/* ── Focus and state pages (authenticator, denied) ─────────────────────────── */
.a-focus {
  display: flex;
  justify-content: center;
  padding-block-start: var(--s-8);
}
/* Two classes, so it outranks `.a-main > :not(.ui-tpl)` (the 1200px list width), which stretched the card. */
.a-focus > .a-focus__card {
  width: 100%;
  max-width: var(--w-focus);
  box-sizing: border-box;
  padding: var(--s-6);
}
.a-eyebrow {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  font-weight: 600;
}
.a-focus__who {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-1);
  margin: 0;
  color: var(--c-muted);
}
.a-focus__icon {
  width: var(--s-8);
  height: var(--s-8);
  color: var(--c-muted);
}
.a-state .ui-empty {
  padding-block: var(--s-6);
}
.a-steps {
  display: flex;
  flex-direction: column;
  gap: var(--s-6);
  margin: 0;
  padding: 0;
  list-style: none;
}
.a-steps > li {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: var(--s-3);
}
.a-steps__n {
  display: grid;
  place-items: center;
  width: var(--s-8);
  height: var(--s-8);
  border-radius: var(--r-pill);
  background: var(--c-ink);
  color: var(--c-surface);
  font-size: var(--fs-14);
  font-weight: var(--fw-strong);
}
.a-qrbox {
  width: 12.5rem;
  height: 12.5rem;
  padding: var(--s-2);
  border: 1px solid var(--c-line);
  border-radius: var(--r-md);
  background: #fff;
  box-sizing: border-box;
}
.a-qrbox svg {
  display: block;
  width: 100%;
  height: 100%;
}

/* ── Page parts ────────────────────────────────────────────────────────────── */
.a-loading {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  padding-block: var(--s-6);
}
.a-headmeta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
}
.a-headline {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.a-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: var(--s-3);
  margin-block-end: var(--s-2);
}
.a-toolbar > .ui-field,
.a-toolbar__full {
  margin: 0;
}
.a-toolbar__grow {
  flex: 1 1 16rem;
  min-width: 0;
}
.a-toolbar__fixed {
  flex: 0 1 13rem;
  min-width: 10rem;
}
.a-toolbar__full {
  flex-basis: 100%;
}
@media (max-width: 599px) {
  .a-toolbar__fixed {
    flex: 1 1 100%;
  }
}
.a-results {
  min-width: 0;
}
.a-footnote {
  margin-block: var(--s-3) 0;
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
}

/* Data table (lg and up) */
.a-dt {
  overflow-x: auto;
  border: 1px solid var(--c-line);
  border-radius: var(--r-md);
  background: var(--c-surface);
}
.a-dt table {
  width: 100%;
  border-collapse: collapse;
}
.a-dt th,
.a-dt td {
  padding: var(--s-3) var(--s-4);
  border-block-end: 1px solid var(--c-line);
  text-align: start;
  vertical-align: middle;
}
.a-dt th {
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  font-weight: 600;
  white-space: nowrap;
}
.a-dt tbody tr {
  position: relative;
  height: var(--h-table-row);
}
.a-dt tbody tr:last-child td {
  border-block-end: 0;
}
.a-dt tbody tr:hover {
  background: var(--c-surface-2);
}
.a-dt .a-n {
  text-align: end;
  font-variant-numeric: tabular-nums;
}
.a-nowrap {
  white-space: nowrap;
}
.a-rowlink {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  color: inherit;
  text-decoration: none;
  border-radius: var(--r-xs);
}
/* The whole row is the link's hit area. */
.a-rowlink::after {
  content: '';
  position: absolute;
  inset: 0;
}
.a-rowlink:hover .a-name {
  text-decoration: underline;
}
.a-name {
  font-weight: 600;
}
.a-sub {
  display: inline-block;
  color: var(--c-muted);
  font-family: var(--f-mono);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  direction: ltr;
  unicode-bidi: isolate;
}

/* List rows (phones and tablets; leads everywhere) */
.a-rows {
  margin: 0;
  padding: 0;
  list-style: none;
  border: 1px solid var(--c-line);
  border-radius: var(--r-md);
  background: var(--c-surface);
  overflow: hidden;
}
.a-rows > li + li {
  border-block-start: 1px solid var(--c-line);
}
.a-row {
  appearance: none;
  display: flex;
  align-items: center;
  gap: var(--s-3);
  box-sizing: border-box;
  width: 100%;
  min-height: var(--h-row);
  margin: 0;
  padding: var(--s-3) var(--s-4);
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  text-align: start;
  text-decoration: none;
  cursor: pointer;
}
.a-row:hover {
  background: var(--c-surface-2);
}
.a-row__main {
  display: flex;
  flex: 1;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  min-width: 0;
}
.a-row__meta {
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.a-row__end {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: var(--s-2);
  color: var(--c-muted);
}
.a-row__time {
  font-size: var(--fs-12);
  white-space: nowrap;
}
@media (max-width: 599px) {
  .a-row {
    flex-wrap: wrap;
  }
  .a-row__end {
    justify-content: flex-start;
  }
}

/* Forms */
.a-form,
.a-done {
  max-width: var(--w-form);
}
.a-formfoot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
}
.a-done__actions {
  justify-content: center;
}

/* Client record */
.a-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--s-3);
}
.a-stats > .ui-stat {
  min-width: 0;
  padding: var(--s-3) var(--s-4);
  border: 1px solid var(--c-line);
  border-radius: var(--r-md);
  background: var(--c-surface);
}
.a-card__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-2);
}
.a-card__head .ui-h3 {
  margin: 0;
}
.a-danger {
  border-color: var(--c-danger);
}
.a-fgroup + .a-fgroup {
  margin-block-start: var(--s-2);
}
.a-fgroup__title {
  margin: 0 0 var(--s-1);
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
  font-weight: 600;
}
.a-flist {
  margin: 0;
  padding: 0;
  list-style: none;
}
.a-feature {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--s-2);
  padding-block: var(--s-3);
  border-block-end: 1px solid var(--c-line);
}
.a-feature__text {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
}
.a-feature__name {
  font-weight: 500;
}
@media (min-width: 600px) {
  .a-feature {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
  }
}

/* Audit sentences */
.a-audit {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
  list-style: none;
  border: 1px solid var(--c-line);
  border-radius: var(--r-md);
  background: var(--c-surface);
}
.a-card .a-audit {
  border: 0;
  background: none;
}
.a-audit__row {
  display: flex;
  align-items: flex-start;
  gap: var(--s-3);
  padding: var(--s-3) var(--s-4);
}
.a-card .a-audit__row {
  padding-inline: 0;
}
.a-audit__row + .a-audit__row {
  border-block-start: 1px solid var(--c-line);
}
.a-audit__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: var(--s-1);
  min-width: 0;
}
.a-audit__text {
  margin: 0;
  overflow-wrap: anywhere;
}
.a-audit__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.a-audit__meta a {
  color: var(--c-accent-ink);
  font-weight: 500;
}
.a-audit__time {
  border-radius: var(--r-xs);
  cursor: default;
}
.a-code {
  margin: 0;
  padding: var(--s-3);
  overflow-x: auto;
  border-radius: var(--r-sm);
  background: var(--c-surface-2);
  font-family: var(--f-mono);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  white-space: pre-wrap;
  word-break: break-all;
  text-align: left; /* rtl-ok: JSON reads left to right */
}

/* "Details" under an audit sentence: a quiet inline toggle, not a full-width row. */
.a-audit .ui-disc {
  border: 0;
}
.a-audit .ui-disc__btn {
  width: auto;
  justify-content: flex-start;
  gap: var(--s-1);
  padding-block: 0;
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
  font-weight: 500;
}
@media (min-width: 1024px) {
  .a-audit .ui-disc__btn {
    min-height: var(--s-8);
  }
}
.a-audit .ui-disc__body {
  padding-block-end: var(--s-2);
}

/* Lead sheet */
.a-sheet__meta {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-14);
}
.a-quote {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
  padding: var(--s-3);
  border-radius: var(--r-sm);
  background: var(--c-surface-2);
}
.a-quote p {
  margin: 0;
  white-space: pre-wrap;
}
/* "Delete request" sits at the start of the sheet's footer, away from the main action, in the danger colour. */
.ui-btn.a-lead__delete {
  margin-inline-end: auto;
  color: var(--c-danger);
}

}
/* surfaces/hq-team.css */
@layer surfaces {
/* Surface: P11 HQ (a-): the clients list v2 (H2), the Bellou team (H18) and a teammate (H19). Layout only, on the
   4 px grid; colour, type and controls come from ui-* components and tokens. HQ density is compact. */

/* ── Clients list (H2): every row the 1280×800 budget allows (≥ 12 one-line rows of 40) ── */
.a-cl > .ui-pagehead {
  margin-block-end: 0;
}
.a-cl-health {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2) var(--s-4);
}
.a-cl-banner {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  margin: 0;
  margin-inline-start: auto;
  padding: var(--s-1) var(--s-3);
  border: 1px solid var(--c-late);
  border-radius: var(--r-pill);
  background: var(--c-late-soft);
  color: var(--c-ink);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.a-cl-banner .ui-icon {
  color: var(--c-late);
}
.a-cl-filters {
  display: grid;
  gap: var(--s-2);
}
.a-cl .ui-filterbar {
  padding-block: 0;
}
.a-cl .ui-filterbar__filters .ui-field {
  min-width: 10rem;
  margin: 0;
}
/* Phone: search full width, then the three filters two to a row, so nothing ends short of the gutter. */
@media (max-width: 599px) {
  .a-cl .ui-filterbar__search {
    flex-basis: 100%;
    max-width: none;
  }
  .a-cl .ui-filterbar__filters {
    display: grid;
    flex: 1 1 100%;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .a-cl .ui-filterbar__filters .ui-field {
    min-width: 0;
  }
  /* An odd one out (the account-manager filter) takes the whole row rather than half of it, cut short. */
  .a-cl .ui-filterbar__filters .ui-field:last-child:nth-child(odd) {
    grid-column: 1 / -1;
  }
  .a-cl-banner {
    margin-inline-start: 0;
  }
}
#a-bulk-slot:empty {
  display: none;
}
.a-cl-client {
  display: flex;
  align-items: baseline;
  gap: var(--s-2);
  min-width: 0;
}
.a-cl-name {
  flex: 0 0 auto;
  max-width: 75%;
  overflow: hidden;
  font-weight: 600;
  color: var(--c-ink);
  text-overflow: ellipsis;
  white-space: nowrap;
}
.a-cl-sub {
  flex: 1 1 0;
  min-width: 0;
  overflow: hidden;
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  text-overflow: ellipsis;
  white-space: nowrap;
  unicode-bidi: isolate;
}
.a-muted {
  color: var(--c-muted);
}
.a-cl .ui-td {
  padding-block: 0;
  white-space: nowrap;
}
.a-cl .ui-td--grow {
  max-width: 0;
  width: 38%;
}
/* 1024–1439 (a 1280 laptop beside the rail): nine columns leave the client's name ~180 px. Tighter cells and no
   "Branches" (it stays on the client's page; H2 keeps "Since") give the name and address the width H2 draws.
   clients-view.ts names Branches' position (a-cl-t--bN: after the selection column, and without the
   account-manager column on an account manager's list). */
@media (min-width: 1024px) and (max-width: 1439px) {
  .a-cl .ui-th,
  .a-cl .ui-td {
    padding-inline: var(--s-3);
  }
  .a-cl-t--b4 .ui-table__t tr > :nth-child(4),
  .a-cl-t--b5 .ui-table__t tr > :nth-child(5),
  .a-cl-t--b6 .ui-table__t tr > :nth-child(6) {
    display: none;
  }
}
/* Phone rows: the meta line may wrap to a second line rather than cut plan or account manager short; the
   address alone is cut with an ellipsis. */
@media (max-width: 1023px) {
  .a-cl .ui-listrow__meta {
    white-space: normal;
  }
  .a-cl-addr {
    display: inline-block;
    max-width: 100%;
    overflow: hidden;
    vertical-align: bottom;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
}

/* Bulk "Assign to…": a quiet bar above the table while rows are selected. */
.a-bulk {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: var(--s-3) var(--s-4);
  padding: var(--s-3) var(--s-4);
  border: 1px solid var(--c-line-strong);
  border-radius: var(--r-md);
  background: var(--c-surface-2);
}
.a-bulk__count {
  margin: 0;
  align-self: center;
  font-weight: 600;
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.a-bulk .ui-field {
  margin: 0;
}
.a-bulk__am {
  flex: 1 1 14rem;
  max-width: 22rem;
}
.a-bulk__actions {
  display: flex;
  gap: var(--s-2);
  margin-inline-start: auto;
}
@media (max-width: 599px) {
  .a-bulk__actions {
    flex-basis: 100%;
    margin-inline-start: 0;
  }
  .a-bulk__actions .ui-btn--primary {
    flex: 1;
  }
}

/* ── Bellou team (H18) ── */
.a-team-overlap {
  display: block;
  margin-block-start: var(--s-1);
}
/* The authenticator state, the Status cell's second line. */
.a-team-totp {
  display: block;
  margin-block-start: var(--s-1);
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
  white-space: nowrap;
}
.a-team-totp[data-on] {
  color: var(--c-ready-ink);
}

/* The role guide Sheet */
.a-guide {
  display: grid;
  gap: var(--s-6);
}
.a-guide__role {
  display: grid;
  gap: var(--s-2);
}
.a-guide__title {
  margin: 0;
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.a-guide__summary {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.a-guide__list {
  display: grid;
  gap: var(--s-2);
  margin: 0;
  padding: 0;
  list-style: none;
}
.a-guide__item {
  position: relative;
  padding-inline-start: var(--s-6);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.a-guide__item::before {
  content: '';
  position: absolute;
  inset-inline-start: var(--s-1);
  inset-block-start: var(--s-1);
  width: var(--s-3);
  height: var(--s-3);
  border-radius: var(--r-pill);
  background: var(--c-ready);
}
.a-guide__item[data-claim='cannot'] {
  color: var(--c-muted);
}
.a-guide__item[data-claim='cannot']::before {
  background: transparent;
  border: 1px solid var(--c-line-strong);
}

/* Invite dialog */
.a-invite__row {
  display: grid;
  gap: var(--s-4);
}
@media (min-width: 600px) {
  .a-invite__row {
    grid-template-columns: 1fr 1fr;
  }
}

/* ── A teammate (H19): DetailPage, cards in the content column ── */
.a-member__card .ui-card__title {
  margin-block-end: var(--s-1);
}
.a-member__desc {
  margin: 0 0 var(--s-3);
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.a-member__role {
  margin: 0;
}
.a-member__clients,
.a-member__sessions {
  margin: 0 0 var(--s-3);
  padding: 0;
  border: 1px solid var(--c-line);
  border-radius: var(--r-md);
}
.a-member__add {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: var(--s-2);
}
.a-member__add .ui-field {
  flex: 1 1 16rem;
  margin: 0;
}
.a-member__plain {
  display: grid;
  gap: var(--s-1);
  margin: 0;
  padding-inline-start: var(--s-5);
}
.a-member__card--warn {
  border-color: var(--c-late);
}

/* Confirmations: what changes */
.a-change {
  display: grid;
  gap: var(--s-2);
}
.a-change__title {
  margin: 0;
  font-weight: 600;
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.a-change__sub {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
}
.a-change__list {
  display: grid;
  gap: var(--s-1);
  margin: 0 0 var(--s-2);
  padding-inline-start: var(--s-5);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.a-change__list[data-kind='loss'] {
  color: var(--c-muted);
}
.a-takeover {
  display: grid;
  gap: var(--s-3);
  max-height: 16rem;
  overflow-y: auto;
  padding-inline-end: var(--s-1);
}
.a-cl .ui-th--grow {
  width: 36%;
}

}
/* surfaces/theme-lab.css */
@layer surfaces {
/* Surface: tl- (Theme lab, /_ds/theme in development; P03). Reads the client theme tokens only, so what it shows
   is exactly what the /_brand/2/… stylesheet does. */
.tl-title {
  font-family: var(--f-display);
}
.tl-form {
  display: flex;
  flex-direction: column;
  gap: var(--s-5);
  padding: var(--s-5);
}
.tl-form__colors {
  display: grid;
  gap: var(--s-5);
}
.tl-form__styles {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-4) var(--s-6);
}
.tl-form__styles .ui-field {
  margin: 0;
}
.tl-form__foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-3) var(--s-5);
}
.tl-href {
  margin: 0;
  overflow-wrap: anywhere;
}
.tl-presets {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
}
.tl-preset {
  min-height: calc(var(--hit-min) - var(--s-2));
  padding-inline: var(--s-2) var(--s-3);
  text-decoration: none;
  font-size: var(--fs-14);
}
.tl-preset[aria-current='true'] {
  border-color: var(--c-ink);
  box-shadow: inset 0 0 0 1px var(--c-ink);
}
.tl-preset__chip {
  width: var(--s-5);
  height: var(--s-5);
  border-radius: var(--r-pill);
  box-shadow: inset 0 0 0 1px var(--c-line-strong);
}

.tl-roles {
  display: grid;
  gap: var(--s-4);
}
.tl-roles__col {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  min-width: 0;
  padding: var(--s-4);
  border-radius: var(--r-md);
  background: var(--c-surface);
  color: var(--c-ink);
  box-shadow: inset 0 0 0 1px var(--c-line);
}
.tl-roles__col .ds-table {
  color: var(--c-ink);
}

.tl-plates td {
  vertical-align: top;
}
.tl-plates td > .ui-text--sm {
  display: block;
  margin-block-start: var(--s-2);
  color: var(--c-muted);
}
.tl-surf {
  display: grid;
  place-items: center;
  min-width: 8.5rem;
  height: 4.5rem;
  border-radius: var(--r-sm);
}
.tl-surf--card {
  background: #fff;
  box-shadow: inset 0 0 0 1px var(--c-line);
}
.tl-surf--page {
  background: #f4f4f1;
}
.tl-surf--tv {
  background: #121110;
}
.tl-surf--brand {
  background: var(--brand);
  box-shadow: inset 0 0 0 1px var(--brand-edge);
}
.tl-plate {
  display: inline-grid;
  place-items: center;
  padding: var(--s-2) var(--s-3);
  border-radius: var(--r-xs);
}
.tl-plate--white {
  background: #fff;
}
.tl-plate--edge {
  box-shadow: inset 0 0 0 1px #8a857d;
}
.tl-plate--ink {
  background: #151412; /* PLATE_INK */
}
.tl-plate--brand {
  background: var(--brand);
  box-shadow: inset 0 0 0 1px var(--brand-edge);
}
.tl-logo {
  display: block;
  width: 5.5rem;
  height: auto;
}

.tl-pane {
  gap: var(--s-4);
  overflow: hidden;
}
.tl-band {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  margin: calc(var(--s-4) * -1) calc(var(--s-4) * -1) 0;
  padding: var(--s-3) var(--s-4);
  background: var(--brand);
  color: var(--on-brand);
  box-shadow: inset 0 -1px 0 var(--brand-edge);
}
.tl-band .ui-logo {
  background: var(--c-surface);
  color: var(--c-accent-ink);
}
.tl-band__name {
  font-family: var(--f-display);
  font-weight: 700;
}
.tl-ticket {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
  padding: var(--s-5) var(--s-4) var(--s-4);
  overflow: hidden;
  border-radius: var(--kit-radius);
  background: var(--c-surface);
  box-shadow: inset 0 0 0 1px var(--c-line);
}
.tl-ticket__stripe {
  position: absolute;
  inset: 0 0 auto;
  height: 6px;
  background: var(--brand);
  box-shadow: inset 0 -1px 0 var(--brand-edge);
}
.tl-ticket__num {
  font-size: var(--fs-32);
  line-height: var(--lh-32);
  font-weight: 800;
}

@media (min-width: 600px) {
  .tl-form__colors {
    grid-template-columns: 1fr 1fr;
  }
}
@media (min-width: 1024px) {
  .tl-roles {
    grid-template-columns: 1fr 1fr;
  }
}

}
/* surfaces/fill-edge.css */
@layer surfaces {
/* P03 fill rule on surfaces that still draw identity fills themselves (P08 moves them onto components).
   Guest ticket stripes: a hairline under a pale stripe so it reads on the white card; transparent otherwise. */
.w-ticket__stripe,
.c-ticket .stripe {
  box-shadow: inset 0 -1px 0 var(--brand-edge);
}

/* The prayer-bead counter on the waiting page is a brand fill: ring it like every other filled control. */
.w-bead {
  box-shadow: inset 0 0 0 1px var(--c-accent-fill-edge);
}

/* The printed card's top stripe is the identity colour: a hairline under it when it is too pale for white paper. */
.p-stripe {
  box-shadow: inset 0 -1px 0 var(--brand-edge);
}

}
/* surfaces/team.css */
@layer surfaces {
/* Team (P12; experience-v2 §13 C6): sections, the invitee/invited-by lines, expiry, the devices summary, the
   Invite dialog's two-up Name/Email, the "What this role does" summary, the change line and the role guide Sheet.
   Logical properties only (RTL mirrors); colours are tokens (the client's accent never paints status). */

.d-team .d-section {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
}
.d-team .d-section + .d-section {
  margin-block-start: var(--s-8);
}
.d-team .d-section__head {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  margin: 0;
}
.d-team-invited {
  display: block;
  margin-block-start: var(--s-1);
  padding-inline-start: calc(var(--s-8) + var(--s-3)); /* the .ui-avatar width plus the .ui-person gap */
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
}
.d-team-expiry {
  display: inline-flex;
  align-items: center;
  gap: var(--s-1);
  color: var(--c-muted);
  white-space: nowrap;
}
.d-team-expiry--late {
  color: var(--c-late);
}
.d-team-expiry .ui-icon {
  width: 16px;
  height: 16px;
}
/* "Expired 2 days ago  Resend": side by side when they fit, Resend on its own line when not. Either way the
   button's label lines up with the text (the ghost button's own padding is pulled back), never indented. */
.d-team-last {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  column-gap: calc(var(--s-3) + var(--s-2)); /* s-2 of visible space once Resend's padding is pulled back */
}
.d-team-resend {
  margin-inline-start: calc(-1 * var(--s-3)); /* .ui-btn--sm padding-inline */
}

/* Phones: the search field takes the whole row (to the end gutter), the filters wrap under it. */
@media (max-width: 599px) {
  .d-team .ui-filterbar__search {
    flex-basis: 100%;
    inline-size: 100%;
    max-width: none;
  }
}

/* Devices summary card. */
.d-team-devices__card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: var(--s-3) var(--s-4);
  align-items: start;
  padding: var(--s-4);
}
.d-team-devices__icon {
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: var(--r-md);
  background: var(--c-surface-2);
  color: var(--c-muted);
}
.d-team-devices__text {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
}
.d-team-devices__text .ui-text {
  margin: 0;
}
.d-team-devices__links {
  grid-column: 2;
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2) var(--s-4);
  margin: 0;
  padding: 0;
  list-style: none;
}
.d-team-devices__links a {
  display: inline-flex;
  align-items: center;
  gap: var(--s-1);
}

/* Invite dialog. */
.d-team-who {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--s-4);
}
@media (max-width: 599px) {
  .d-team-who {
    grid-template-columns: minmax(0, 1fr);
  }
}
.d-team-lock .ui-lockrow {
  margin: 0;
}
.d-team-cando {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  padding: var(--s-3) var(--s-4);
  border-radius: var(--r-md);
  background: var(--c-surface-2);
}
.d-team-cando__label {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  font-weight: var(--fw-medium);
}
.d-team-cando .ui-btn--link {
  align-self: flex-start;
}
.d-team-erract {
  margin-block-start: var(--s-2);
}
.d-team-formerr[hidden] {
  display: none;
}

/* Success step. */
.d-team-sent {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--s-2);
  margin-block-end: var(--s-4);
}
.d-team-sent__icon {
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--c-ready-soft);
  color: var(--c-ready-ink);
}
.d-team-sent__title {
  margin: 0;
}
.d-team-sent .ui-text {
  margin: 0;
}

/* "From Cashier at Olaya → Branch manager at Olaya, Malqa". */
.d-team-change {
  display: flex;
  gap: var(--s-2);
  align-items: flex-start;
  margin: 0;
  padding: var(--s-3) var(--s-4);
  border-radius: var(--r-md);
  background: var(--c-surface-2);
  color: var(--c-ink);
}
.d-team-change > .ui-icon {
  flex: none;
  /* Centred on the first line of text, whatever the line height. */
  margin-block-start: calc((var(--lh-14) - 16px) / 2);
  color: var(--c-muted);
}
.d-team-change strong {
  font-weight: var(--fw-strong);
}
.d-team-change__arrow .ui-icon {
  width: 16px;
  height: 16px;
  vertical-align: middle;
  color: var(--c-muted);
}

/* Role guide (Sheet, and the lists reused in the Invite dialog). */
.d-guide {
  display: flex;
  flex-direction: column;
  gap: var(--s-6);
}
.d-guide__role {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  padding-block-end: var(--s-6);
  border-block-end: 1px solid var(--c-line);
}
.d-guide__role:last-child {
  padding-block-end: 0;
  border-block-end: 0;
}
.d-guide__role--on {
  padding: var(--s-4);
  border: 1px solid var(--c-line-strong);
  border-radius: var(--r-md);
}
.d-guide__title {
  margin: 0;
}
.d-guide__summary {
  margin: 0;
  color: var(--c-muted);
}
.d-guide__list {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  margin: 0;
  padding: 0;
  list-style: none;
}
.d-guide__list li {
  display: grid;
  grid-template-columns: 16px minmax(0, 1fr);
  gap: var(--s-2);
  align-items: start;
  font-size: var(--fs-14);
  line-height: var(--lh-14);
}
.d-guide__list .ui-icon {
  width: 16px;
  height: 16px;
  margin-block-start: calc((var(--lh-14) - 16px) / 2);
}
.d-guide__list--can .ui-icon {
  color: var(--c-ready);
}
.d-guide__list--cannot .ui-icon {
  color: var(--c-muted);
}
.d-guide__list--cannot li {
  color: var(--c-muted);
}

/* The invite page (P12): "You'll work at Olaya, Malqa" under the intro, and the state panel for a link that no
   longer works (one icon, the title, whom to ask, Sign in). Lives on the client's branded focus card. */
.d-invite-at {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  margin: 0 0 var(--s-4);
  font-weight: 600;
}
.d-invite-at .ui-icon {
  flex: none;
  width: var(--s-5);
  height: var(--s-5);
  color: var(--c-muted);
}
.d-invite-dead {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
}
.d-invite-dead .ui-h1,
.d-invite-dead .op-focus__lead {
  margin: 0;
}
.d-invite-dead__icon {
  display: inline-grid;
  place-items: center;
  width: var(--s-12);
  height: var(--s-12);
  border-radius: 50%;
  background: var(--c-late-soft);
  color: var(--c-late-ink);
}
.d-invite-dead__icon .ui-icon {
  width: var(--s-6);
  height: var(--s-6);
}
.d-invite-dead__member {
  margin: var(--s-2) 0 0;
}


}
/* surfaces/activity.css */
@layer surfaces {
/* Activity (P12; experience-v2 §13 C11): one card per day with the Timeline in it, the Bellou work-session
   group (indigo is reserved for "Bellou is acting": the badge and the nested rule only), views, load more. */

.d-act .ui-tpl__list {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}
.d-act__day {
  padding: var(--s-4) var(--s-5);
}
.d-act__day .ui-tlgroup__title {
  margin-block-end: var(--s-1);
}
.d-act__who {
  font-weight: var(--fw-strong);
}
.d-act__role,
.d-act__via,
.d-act__span,
.d-act__count,
.d-act__sep {
  color: var(--c-muted);
}
.d-act__part {
  display: inline-block;
  white-space: nowrap;
}
.d-act__sep {
  padding-inline-end: var(--s-1);
}
@media (max-width: 599px) {
  .d-act__meta {
    display: block;
  }
  .d-act__meta > .d-act__part:first-child > .d-act__sep {
    display: none;
  }
}
/* The group's "Show changes (4)": a quiet control under the reason, not a section heading. */
.d-act .ui-tl__item .ui-disc__head {
  margin: 0;
}
.d-act .ui-tl__item .ui-disc__btn {
  width: auto;
  min-height: 0;
  padding-block: var(--s-1);
  padding-inline: 0;
  justify-content: flex-start;
  gap: var(--s-1);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
  font-weight: var(--fw-medium);
  color: var(--c-acting-ink);
}
.d-act .ui-tl__item .ui-disc__title {
  font-size: inherit;
  font-weight: inherit;
}
.d-act .ui-tl__item .ui-disc {
  border: 0;
}
.d-act__views {
  color: var(--c-muted);
}
.d-act__children .ui-tlgroup {
  margin: 0;
}
.d-act__children .ui-tl {
  padding-inline-start: var(--s-3);
  border-inline-start: 2px solid var(--c-acting-soft);
}
.d-act__children .ui-tl__item {
  padding-block: var(--s-2);
}
.d-act__children .ui-tl__item .ui-avatar {
  width: 24px;
  height: 24px;
}
.d-act__more {
  margin: var(--s-2) 0 0;
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
}
.d-act .ui-tl__item .ui-disc {
  margin-block-start: var(--s-2);
}
.d-act__pager {
  display: flex;
  justify-content: center;
  margin-block-start: var(--s-4);
}
.d-act__end {
  margin: var(--s-4) 0 0;
  text-align: center;
  color: var(--c-muted);
  font-size: var(--fs-13);
}
@media (max-width: 599px) {
  .d-act__day {
    padding: var(--s-3) var(--s-4);
  }
  /* On phones the time sits under the sentence. */
  .d-act .ui-tl__item {
    grid-template-columns: auto minmax(0, 1fr);
  }
  .d-act .ui-tl__time {
    grid-column: 2;
  }
}
/* Filters (C11): on desktop the Who/What/Branch/date filters sit inline and the "Filters (n)" button is hidden;
   on phones only the quick filter stays inline and the rest folds behind that button (aria-expanded). */
.d-act__filters {
  display: contents;
}
.d-act__filtersbtn {
  display: none;
}
@media (max-width: 599px) {
  /* One row, always: the quick filter shrinks (and scrolls sideways if it must), "Filters (n)" keeps its place,
     so setting a filter never moves the button onto a line of its own. */
  .d-act .ui-filterbar__chips {
    width: 100%;
    flex-wrap: nowrap;
  }
  .d-act .ui-filterbar__chips > .ui-fchips {
    flex: 1 1 auto;
    min-width: 0;
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
    /* Room for the chips' focus ring inside the scroller. */
    padding: 3px;
    margin: -3px;
  }
  .d-act .ui-filterbar__chips > .ui-fchips::-webkit-scrollbar {
    display: none;
  }
  .d-act__filtersbtn {
    display: inline-flex;
    flex: none;
    margin-inline-start: auto;
  }
  .d-act:not([data-filters='open']) .ui-filterbar__filters,
  .d-act:not([data-filters='open']) .ui-filterbar__clear {
    display: none;
  }
  .d-act[data-filters='open'] .ui-filterbar__filters {
    width: 100%;
    padding: var(--s-3);
    border: 1px solid var(--c-line);
    border-radius: var(--r-card);
    background: var(--c-surface);
  }
  .d-act[data-filters='open'] .ui-filterbar__clear {
    margin-inline-start: 0;
  }
}

}
/* surfaces/console.css */
@layer surfaces {
/* HQ console (release-v2 P15; experience-v2 §7.3, §7.4, §13 H4–H14, H20): admins.bellou.io/clients/<id>/<section>.
   The ActingBar sits directly under the HQ app bar over the content column (never over the rail), and comes first in
   the DOM so it is the first focus stop after the app bar. HQ ink everywhere; only [data-preview-frame] takes the
   client's colours. No inline styles: every state is a class or a data attribute. */

/* ── The acting bar's slot ──────────────────────────────────────────────────────────────────────────────────── */
.a-body--acting {
  grid-template-rows: auto minmax(0, 1fr);
}
.c-actslot {
  position: sticky;
  inset-block-start: var(--s-12); /* the HQ app bar is --s-12 high (shell.css .ui-appbar--hq), not --h-appbar */
  z-index: var(--z-banner);
  grid-row: 1;
  grid-column: 1 / -1;
  align-self: start;
}
.c-actslot .ui-actbar {
  position: static;
}
.a-body--acting > .a-main {
  grid-row: 2;
}
@media (min-width: 600px) {
  .c-actslot,
  .a-body--acting > .a-main {
    grid-column: 2;
  }
  .a-body--acting > .a-railcol {
    grid-row: 1 / span 2;
    grid-column: 1;
  }
}
.c-sheet {
  display: grid;
  gap: var(--s-2);
  margin: 0;
}
.c-sheetrow {
  display: flex;
  justify-content: space-between;
  gap: var(--s-4);
  font-size: var(--fs-14);
}
.c-sheetrow dt {
  color: var(--c-muted);
}
.c-sheetrow dd {
  margin: 0;
  text-align: end;
  font-weight: var(--fw-medium);
}

/* ── Header and sub-nav ─────────────────────────────────────────────────────────────────────────────────────── */
.c-console .ui-entity {
  margin-block-end: var(--s-2);
}
.c-host {
  display: inline-flex;
  align-items: center;
  gap: var(--s-1);
  color: var(--c-muted);
  font-size: var(--fs-13);
  text-decoration: none;
}
.c-host:hover {
  color: var(--c-ink);
  text-decoration: underline;
}
.c-host .ui-icon {
  width: 14px;
  height: 14px;
}
.c-am {
  display: inline-flex;
  align-items: center;
  gap: var(--s-1);
  padding-inline: var(--s-2);
  border: 1px solid var(--c-line);
  border-radius: var(--r-pill);
  color: var(--c-ink);
  font-size: var(--fs-12);
  line-height: 20px;
}
.c-am .ui-icon {
  width: 12px;
  height: 12px;
  color: var(--c-muted);
}
.c-warns {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
}

/* ── The gate ───────────────────────────────────────────────────────────────────────────────────────────────── */
.c-gatebar {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  margin-block-end: var(--s-4);
  padding: var(--s-3) var(--s-4);
  border: 1px solid var(--c-line);
  border-radius: var(--r-card);
  background: var(--c-surface-2);
}
.c-gatebar > .ui-icon {
  flex: none;
  color: var(--c-muted);
}
.c-gatebar__text {
  flex: 1;
  min-width: 0;
}
.c-gatebar__title {
  margin: 0;
  font-weight: var(--fw-medium);
  font-size: var(--fs-14);
}
.c-gatebar__desc {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
}
.c-gatebar__btn {
  flex: none;
}
.c-gate[data-gate='open'] .c-gatebar {
  display: none;
}
.c-gate__body {
  position: relative;
}
.c-gate__veil {
  position: absolute;
  inset: 0;
  z-index: var(--z-sticky);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  border-radius: var(--r-card);
  background: transparent;
  cursor: pointer;
}
.c-gate__veil[hidden] {
  display: none;
}
.c-gate__veil:focus-visible {
  outline: 2px solid var(--c-focus);
  outline-offset: 2px;
}
.c-gate__drop {
  display: none;
  position: sticky;
  inset-block-start: calc(var(--s-12) + var(--h-actbar) + var(--s-6));
  align-items: center;
  gap: var(--s-2);
  margin-block-start: var(--s-8);
  padding: var(--s-3) var(--s-4);
  border: 2px dashed var(--c-line-strong);
  border-radius: var(--r-card);
  background: var(--c-surface);
  color: var(--c-ink);
  font-weight: var(--fw-medium);
}
.c-gate[data-drag='1'] .c-gate__veil {
  background: color-mix(in srgb, var(--c-surface) 72%, transparent);
}
.c-gate[data-drag='1'] .c-gate__drop {
  display: inline-flex;
}
.c-gate[data-gate='on'] .c-section,
.c-gate[data-gate='closed'] .c-section {
  user-select: none;
}

/* ── Overview (H4) ──────────────────────────────────────────────────────────────────────────────────────────── */
.c-ov {
  display: grid;
  gap: var(--s-4);
  grid-template-columns: minmax(0, 1fr);
  grid-template-areas: 'health' 'golive' 'owners' 'account' 'recent';
}
@media (min-width: 1024px) {
  .c-ov {
    grid-template-columns: minmax(0, 3fr) minmax(0, 2fr);
    grid-template-areas: 'health account' 'owners recent' 'golive golive';
    align-items: start;
  }
  .c-ov--setup {
    grid-template-areas: 'golive golive' 'health account' 'owners recent';
  }
}
.c-ov__health {
  grid-area: health;
}
.c-ov__golive {
  grid-area: golive;
}
.c-ov__owners {
  grid-area: owners;
}
.c-ov__account {
  grid-area: account;
}
.c-ov__recent {
  grid-area: recent;
}
.c-card {
  display: grid;
  gap: var(--s-3);
  align-content: start;
}
.c-card__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--s-3);
}
.c-card__head .ui-h3 {
  margin: 0;
}
.c-kvs {
  display: grid;
  margin: 0;
}
.c-kv {
  display: grid;
  grid-template-columns: minmax(7rem, 1fr) minmax(0, 2fr);
  gap: var(--s-3);
  align-items: baseline;
  padding-block: var(--s-2);
  border-block-start: 1px solid var(--c-line);
  font-size: var(--fs-14);
}
.c-kv:first-child {
  border-block-start: 0;
  padding-block-start: 0;
}
.c-kv dt {
  color: var(--c-muted);
}
.c-kv dd {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-1) var(--s-2);
  margin: 0;
  min-width: 0;
}
.c-kv__act {
  margin-inline-start: auto;
  font-size: var(--fs-13);
}
.c-muted {
  color: var(--c-muted);
}
.c-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: var(--r-pill);
  background: var(--c-muted);
}
.c-dot--ok {
  background: var(--c-ready);
}
.c-dot--warn {
  background: var(--c-late);
}
.c-warnlist {
  display: grid;
  gap: var(--s-1);
  width: 100%;
  margin: 0;
  padding: 0;
  list-style: none;
}
.c-warnlist li {
  display: flex;
  gap: var(--s-2);
  align-items: flex-start;
}
.c-warnlist .ui-icon {
  flex: none;
  width: 16px;
  height: 16px;
  margin-block-start: 2px;
  color: var(--c-late);
}
.c-cardlink {
  font-size: var(--fs-13);
}
.c-people {
  display: grid;
  gap: var(--s-1);
  margin: 0;
  padding: 0;
  list-style: none;
}
.c-person {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  padding-block: var(--s-2);
}
.c-person__text {
  display: grid;
  flex: 1;
  min-width: 0;
}
.c-person__name {
  overflow: hidden;
  font-weight: var(--fw-medium);
  font-size: var(--fs-14);
  text-overflow: ellipsis;
  white-space: nowrap;
}
.c-person__sub {
  overflow: hidden;
  color: var(--c-muted);
  font-size: var(--fs-13);
  text-align: start;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.c-person__end {
  flex: none;
  font-size: var(--fs-13);
}
@media (max-width: 599px) {
  .c-kv {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--s-1);
  }
  .c-person {
    flex-wrap: wrap;
  }
  .c-person__end {
    width: 100%;
    padding-inline-start: calc(32px + var(--s-3));
  }
}

/* ── HQ-only sections and the reason dialog ─────────────────────────────────────────────────────────────────── */
.c-hqsection {
  max-width: var(--w-main);
}
.c-reason .c-reason__other[hidden] {
  display: none;
}
.c-reason__new {
  margin-block-end: var(--s-1);
}
.c-reason__row {
  display: grid;
  gap: var(--s-4);
  grid-template-columns: minmax(0, 1fr);
}
@media (min-width: 768px) {
  .c-reason__row {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
  }
}
.c-confirm-reason {
  display: flex;
  gap: var(--s-2);
  align-items: flex-start;
  margin: var(--s-3) 0 0;
  padding: var(--s-2) var(--s-3);
  border-inline-start: 3px solid var(--c-acting);
  border-radius: var(--r-sm);
  background: var(--c-acting-soft);
  color: var(--c-acting-ink);
  font-size: var(--fs-13);
}
.c-confirm-reason .ui-icon {
  flex: none;
  width: 16px;
  height: 16px;
  margin-block-start: 1px;
}
@media (forced-colors: active) {
  .c-confirm-reason {
    border: 1px solid CanvasText;
  }
}

/* Print & QR inside the console: the preview pane is narrower than on the client's host (the rail, the sub-nav), so
   the sheet is zoomed further to fit it. */
@media (min-width: 1024px) {
  .c-section .p-stage {
    zoom: 0.34;
  }
}
@media (min-width: 1440px) {
  .c-section .p-stage {
    zoom: 0.5;
  }
}

/* A client view that is itself a DetailPage (a branch, with its own aside) nests inside the console's DetailPage:
   the console's sub-nav column must not leak into it (templates.css lays columns out with descendant selectors). */
@media (min-width: 1024px) {
  .c-console .c-section .ui-tpl:not(.ui-tpl--subnav) > .ui-tpl__cols {
    grid-template-columns: minmax(0, 1fr);
  }
  .c-console > .ui-tpl__cols > .ui-tpl__subnav {
    inset-block-start: calc(var(--s-12) + var(--h-actbar) + var(--s-4));
  }
}
@media (min-width: 1440px) {
  .c-console .c-section .ui-tpl--aside:not(.ui-tpl--subnav) > .ui-tpl__cols {
    grid-template-columns: minmax(0, 1fr) var(--w-aside);
  }
}

}
/* surfaces/signin.css */
@layer surfaces {
/* P17: client-branded sign-in and state pages (experience-v2 §13 F1), the fixed HQ bar, the neutral entry pages
   (unknown subdomain, closed and paused cafés) and the workspace switcher. Brand colours come only from the brand
   stylesheet's tokens (--brand, --on-brand, --c-accent…, --c-band, --c-page-tint, --f-display); nothing here is a
   client colour, and the HQ bar uses chrome tokens a client can never set. */

/* ── Page and surface styles ─────────────────────────────────────────────────────────────────────────────── */
.by-signin {
  position: relative;
}
/* Tinted: the card sits on the brand's page tint. Brand header: a band at the top of the card. */
.by-signin[data-surface='tinted'] {
  background: var(--c-page-tint, var(--c-bg));
}
.by-signin__card {
  position: relative;
  overflow: hidden;
}
.by-signin__card--band {
  padding-block-start: 0;
}
.by-band {
  display: flex;
  align-items: center;
  justify-content: center;
  height: var(--h-band);
  margin-inline: calc(-1 * var(--s-8));
  margin-block-end: var(--s-2);
  background: var(--c-band, var(--brand));
  color: var(--c-on-band, var(--on-brand));
  box-shadow: inset 0 -1px 0 var(--c-band-edge, transparent);
}
@media (max-width: 599px) {
  .by-band {
    height: calc(var(--s-16) + var(--s-8));
    margin-inline: calc(-1 * var(--s-5));
  }
}
.by-signin__brand {
  min-height: var(--s-16);
}
.by-signin__eyebrow {
  margin-block-end: calc(-1 * var(--s-2));
}
.by-signin__h1 {
  font-family: var(--f-display, var(--f-sans));
  overflow-wrap: anywhere;
}

/* The invite page's state blocks stack like the card itself. */
.by-signin [data-invite='body'],
.by-signin [data-invite='signin'] {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}
.by-signin [data-invite][hidden] {
  display: none;
}

/* ── The client's mark: logo (h64; h48 on phones) with its plate, or the App icon tile (64) ─────────────── */
.by-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
}
.by-mark--logo img {
  display: block;
  height: var(--s-16);
  width: auto;
  max-width: min(100%, calc(var(--s-16) * 4));
  object-fit: contain;
}
@media (max-width: 599px) {
  .by-mark--logo img {
    height: var(--s-12);
  }
}
.by-mark--logo[data-plate='white'],
.by-mark--logo[data-plate='brand'],
.by-mark--logo[data-plate='ink'] {
  padding: var(--s-2) var(--s-3);
  border-radius: var(--r-md);
}
.by-mark--logo[data-plate='white'] {
  background: #fff;
  box-shadow: inset 0 0 0 1px var(--c-line);
}
.by-mark--logo[data-plate='brand'] {
  background: var(--brand);
  box-shadow: inset 0 0 0 1px var(--brand-edge, transparent);
}
.by-mark--logo[data-plate='ink'] {
  background: var(--c-chrome-bg);
}
.by-band .by-mark--logo[data-plate='white'] {
  box-shadow: none;
}
.by-tile {
  width: var(--s-16);
  height: var(--s-16);
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--brand);
  box-shadow: inset 0 0 0 1px var(--brand-edge, transparent);
  color: var(--on-brand);
  font-family: var(--f-display, var(--f-sans));
  font-size: var(--fs-28);
  line-height: 1;
  font-weight: var(--fw-strong);
}
.by-tile--img {
  background: var(--c-surface);
  box-shadow: inset 0 0 0 1px var(--c-line);
}
.by-tile--img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.by-band .by-tile {
  box-shadow: inset 0 0 0 1px var(--c-on-band, transparent);
}

/* ── Footer: the real host, then "Powered by Bellou" ───────────────────────────────────────────────────── */
.by-hostline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: var(--s-2);
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.by-hostline__host {
  font-family: var(--f-mono);
  unicode-bidi: isolate;
}
.by-hostline__sep {
  opacity: 0.6;
}

/* ── Link expired / used, loading ───────────────────────────────────────────────────────────────────────── */
.by-dead {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}
.by-dead[hidden] {
  display: none;
}
.by-dead__icon {
  display: inline-grid;
  place-items: center;
  width: var(--s-12);
  height: var(--s-12);
  border-radius: 50%;
  background: var(--c-accent-soft, var(--c-surface-2));
  color: var(--c-accent-ink, var(--c-ink));
}
.by-dead__icon .ui-icon {
  width: var(--s-6);
  height: var(--s-6);
}
.by-loading {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  min-height: var(--s-16);
  color: var(--c-muted);
}

/* ── admins.bellou.io: the fixed HQ bar (never themable) ───────────────────────────────────────────────── */
/* The same LIGHT bar and mark as the signed-in HQ app bar (shell.css .ui-appbar--hq), so staff see one identity
   on both sides of signing in. Neutral tokens only: the admins host never carries a client theme. */
.by-hqbar {
  position: sticky;
  inset-block-start: 0;
  z-index: var(--z-appbar);
  display: flex;
  align-items: center;
  gap: var(--s-3);
  min-height: var(--s-12);
  padding-inline: var(--s-4);
  border-block-end: 1px solid var(--c-line);
  background: var(--c-surface);
  color: var(--c-ink);
}
.by-hqbar__mark {
  display: inline-flex;
  align-items: center;
  gap: var(--s-3);
  min-width: 0;
  font-weight: var(--fw-strong);
  font-size: var(--fs-16);
  line-height: var(--lh-16);
}
/* Bellou's "B" tile is ink, like every HQ primary (display.css .ui-appbar--hq rule). */
.by-hqbar__mark .ui-logo {
  background: var(--c-hq-primary);
  box-shadow: none;
  color: var(--c-on-hq-primary);
}
.by-hqbar__word {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.by-hqbar__host {
  margin-inline-start: auto;
  color: var(--c-muted);
  font-family: var(--f-mono);
  font-size: var(--fs-13);
  unicode-bidi: isolate;
}
.by-hqbar + .op-focus {
  min-height: calc(100dvh - var(--s-12));
}

/* ── Neutral entry pages (unknown subdomain, closed, paused) ────────────────────────────────────────────── */
.by-entry__bar {
  position: absolute;
  inset-block-start: 0;
  inset-inline: 0;
  display: flex;
  align-items: center;
  min-height: var(--h-appbar);
  padding-inline: var(--s-4);
}
.by-wordmark {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  color: var(--c-ink);
  font-weight: var(--fw-strong);
  font-size: var(--fs-18);
  text-decoration: none;
}
/* Bellou's mark (packages/ui/src/pixel-logo.ts): the gold bell on its midnight tile, the same in both themes;
   32 px, twice its 16-pixel grid. */
.by-wordmark__mark {
  display: block;
  width: var(--s-8);
  height: var(--s-8);
  line-height: 0;
}
.by-wordmark__mark svg {
  display: block;
  width: 100%;
  height: 100%;
}
.by-wordmark__name {
  display: inline-flex;
  line-height: 0;
}
.by-wordmark__name svg {
  display: block;
}
.by-word-sh {
  fill: var(--gold-600);
}
.by-px-t {
  fill: var(--night-800);
}
.by-px-o {
  fill: var(--gold-400);
}
.by-px-a {
  fill: var(--dune-50);
}
.by-entry__acts {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--s-2);
}

/* ── Workspace switcher (account menu) ──────────────────────────────────────────────────────────────────── */
.ws-switch {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
  min-width: 0;
}
.ws-switch[hidden] {
  display: none;
}
/* Until the script finds a second workspace the slot stays hidden: hide its menu block and divider with it, or the
   menu shows an empty band between two lines. */
.ui-menu__header:has(> .ws-switch[hidden]),
.ui-menu__sep:has(+ .ui-menu__header > .ws-switch[hidden]) {
  display: none;
}
.ws-switch__title {
  margin: 0;
  padding-block: var(--s-1);
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  font-weight: var(--fw-strong);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.ws-switch__item {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  width: 100%;
  min-height: var(--hit-min);
  padding: var(--s-1) var(--s-2);
  border: 0;
  border-radius: var(--r-sm);
  background: transparent;
  color: var(--c-ink);
  font: inherit;
  text-align: start;
  cursor: pointer;
}
.ws-switch__item:hover:not([aria-current='true']) {
  background: var(--c-surface-2);
}
.ws-switch__item:focus-visible {
  outline: 2px solid var(--c-accent-ring, var(--c-ink));
  outline-offset: 1px;
}
.ws-switch__item[aria-current='true'] {
  cursor: default;
}
.ws-switch__tile {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: var(--s-8);
  height: var(--s-8);
  overflow: hidden;
  border-radius: var(--r-sm);
  background: var(--c-surface-2);
  box-shadow: inset 0 0 0 1px var(--c-line);
  color: var(--c-ink);
  font-weight: var(--fw-strong);
  font-size: var(--fs-14);
}
.ws-switch__tile img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.ws-switch__tile--img {
  background: var(--c-surface);
}
.ws-switch__name {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-weight: var(--fw-medium);
}
.ws-switch__meta {
  flex: none;
  color: var(--c-muted);
  font-size: var(--fs-13);
}
.ws-switch__item[aria-current='true'] .ws-switch__meta {
  color: var(--c-ready-ink);
}

}
/* surfaces/brand-surfaces.css */
@layer surfaces {
/* P17: the client's brand on the operations surfaces (experience-v2 §6.3): the TV's header band and its logo
   plates, the "newest ready" highlight, and the live-board banners on the TV, cashier and kitchen. Colours come only
   from the brand stylesheet's tokens; numbers keep system contrast. */

/* ── TV header band: brand fill, on-brand text, the fill-edge rule, the display typeface ───────────────────── */
.t-root[data-theme] {
  background: var(--c-bg);
  color: var(--c-ink);
}
/* The board's padding in viewport units, in one place: the band cancels exactly that much to run edge to edge.
   (cq units inside .t-root measure its content box, while .t-root's own 3cqh/3cqw padding resolves against the
   viewport, so a -3cq margin fell 2px short of the edges.) This sheet loads after tv.css, so it wins. */
.t-root {
  --t-pad-y: 3vh;
  --t-pad-x: 3vw;
  padding: var(--t-pad-y) var(--t-pad-x);
}
/* Brand studio draws the board on a fixed 1280 × 720 screen (brand.css .bs-screen--tv), not the viewport. */
.bs-screen--tv .t-root {
  --t-pad-y: 21.6px;
  --t-pad-x: 38.4px;
}
.t-band {
  margin: calc(-1 * var(--t-pad-y)) calc(-1 * var(--t-pad-x)) 0;
  padding: 2cqh var(--t-pad-x);
  background: var(--brand);
  color: var(--on-brand);
  box-shadow: inset 0 -0.3cqh 0 var(--brand-edge, transparent);
}
.t-band .t-biz > bdi:first-child {
  font-family: var(--f-display, var(--f-sans));
}
.t-band .t-biz__branch {
  color: inherit;
  opacity: 0.85;
}
/* The monogram tile on a brand band: inverted, so it never disappears into the band. */
.t-band .ui-logo:not(.ui-logo--img) {
  background: var(--on-brand);
  box-shadow: none;
  color: var(--brand);
}
.t-logo {
  display: inline-flex;
  align-items: center;
  flex: none;
}
.t-logo img {
  display: block;
  height: 7cqh;
  width: auto;
  max-width: 36cqw;
  object-fit: contain;
}
.t-logo[data-plate='white'],
.t-logo[data-plate='brand'],
.t-logo[data-plate='ink'] {
  padding: 0.8cqh 1.2cqw;
  border-radius: var(--tv-r);
}
.t-logo[data-plate='white'] {
  background: #fff;
}
.t-logo[data-plate='brand'] {
  background: var(--brand);
  box-shadow: inset 0 0 0 0.2cqh var(--on-brand);
}
.t-logo[data-plate='ink'] {
  background: var(--c-chrome-bg);
}
/* The newest ready number: system green and white (contrast first), ringed in the brand's edge colour. */
.t-big li.t-new {
  box-shadow: 0 0 0 0.6cqh var(--brand-edge, transparent);
}
/* Reconnecting / offline on the TV: the brand's edge marks the notice as this café's screen. */
.t-offline {
  border-inline-start: 0.5cqw solid var(--c-accent-edge, var(--c-line));
}

/* ── Cashier and kitchen: the live-board banners in the client's accent ─────────────────────────────────── */
.op-live {
  border-inline-start: 4px solid var(--c-accent);
}
.op-live .ui-icon {
  color: var(--c-accent-ink, currentColor);
}

/* Cashier and kitchen app bars: the client's logo at its own shape (a wide wordmark isn't squeezed into a square
   tile), on its white plate so dark artwork reads in dark mode too. The monogram tile stays square. */
.op-bar .ui-appbar__brand .ui-logo--img {
  width: auto;
  max-width: calc(var(--s-16) * 2);
  padding-inline: var(--s-1);
}
.op-bar .ui-appbar__brand .ui-logo--img img {
  width: auto;
  height: calc(var(--s-8) * 0.76); /* a fixed length: a % height resolves against the inline-grid's own auto row */
  max-width: 100%;
}
/* On a phone the business name needs the room: the logo plate gives way first (P17 review). */
@media (max-width: 599px) {
  .op-bar .ui-appbar__brand .ui-logo--img {
    max-width: 72px;
  }
}

/* The waiting page's header: the logo at its own shape too (at most 32 px high, 140 px wide), never squeezed into
   the square tile. The monogram tile stays square. */
.w-root .ui-appbar__brand .ui-logo--img {
  width: auto;
  height: var(--s-8);
  max-width: 140px;
  padding-inline: var(--s-1);
}
.w-root .ui-appbar__brand .ui-logo--img img {
  width: auto;
  height: calc(var(--s-8) * 0.76);
  max-width: 100%;
}

}
/* surfaces/onboarding.css */
@layer surfaces {
/* C0 First-run wizard (release-v2 P16; experience-v2 §13 C0): FocusWizard on the client's brand, no rail. The
   frame is 560 wide (640 in the HQ console's inline frame); the café step puts the fields and the live mini-preview
   side by side from md, stacked on phones. The preview is SVG with fill attributes (CSP: no inline style). */

.ob-app .sh-main.ob-main {
  display: block;
  min-height: calc(100dvh - 56px);
  padding: var(--s-8) var(--s-4) var(--s-12);
}
.ob .ui-tpl--focus {
  max-width: 640px;
}
/* On the client's own host the frame is centred (560); in the HQ console it stays left-aligned in the content. */
.ob[data-view='member'] .ui-tpl--focus {
  max-width: 600px;
  margin-inline: auto;
}
.ob-top__name {
  font-weight: var(--fw-strong);
  font-size: var(--fs-16);
  overflow-wrap: anywhere;
}
.ob .ui-wizard__logo {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  min-width: 0;
}
.ob-cafe {
  display: grid;
  gap: var(--s-6);
  align-items: start;
}
@media (min-width: 720px) {
  .ob-cafe:not(.ob-cafe--stack) {
    grid-template-columns: minmax(0, 1fr) 248px;
  }
}
/* "We set this up for you": what Bellou chose reads as one list, the preview under it. */
.ob-cafe--stack .ob-preview {
  max-width: 340px;
}
.ob-cafe__fields {
  min-width: 0;
}
.ob-muted {
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: 1.5;
}

/* "We picked this red from your logo. Change it?" and the swatches (toggle buttons). */
.ob-picked .ui-callout__title {
  margin-block-end: var(--s-2);
}
.ob-swatches {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
}
.ob-swatch {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  min-height: 40px;
  padding-block: var(--s-1);
  padding-inline: var(--s-1) var(--s-3);
  border: 1px solid var(--c-line);
  border-radius: var(--r-pill);
  background: var(--c-surface);
  color: var(--c-ink);
  font: inherit;
  font-size: var(--fs-13);
  font-variant-numeric: tabular-nums;
  cursor: pointer;
}
.ob-swatch:hover {
  border-color: var(--c-line-strong);
}
.ob-swatch[aria-pressed='true'] {
  border-color: var(--c-ink);
  box-shadow: inset 0 0 0 1px var(--c-ink);
}
.ob-swatch:focus-visible {
  outline: 2px solid var(--c-focus);
  outline-offset: 2px;
}
.ob-swatch__chip {
  inline-size: 28px;
  block-size: 28px;
  border-radius: var(--r-pill);
  flex: none;
}
.ob-swatch__check {
  display: inline-flex;
  color: var(--c-ink);
}
.ob-swatch__check .ui-icon {
  inline-size: 16px;
  block-size: 16px;
}

/* The live mini-preview: the waiting page's header and the sign-in button, in the draft's colour. */
.ob-preview {
  position: relative;
  margin: 0;
  padding: var(--s-3);
  border: 1px solid var(--c-line);
  border-radius: var(--r-card);
  background: var(--c-bg);
}
.ob-preview__cap {
  margin-block-end: var(--s-2);
  color: var(--c-muted);
  font-size: var(--fs-12);
  font-weight: var(--fw-medium);
  text-transform: none;
}
.ob-preview__svg {
  display: block;
  inline-size: 100%;
  block-size: auto;
  border-radius: var(--r-md);
  box-shadow: 0 1px 2px rgb(0 0 0 / 0.08);
}
/* "We set this up for you": what Bellou chose, each with Change. */
.ob .ui-dl dd {
  min-width: 0;
}
.ob-dl__logo {
  inline-size: 40px;
  block-size: 40px;
  object-fit: contain;
  border-radius: var(--r-sm);
  background: var(--c-surface);
  border: 1px solid var(--c-line);
}
.ob-dl__color {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  font-variant-numeric: tabular-nums;
}
.ob-dl__chip {
  inline-size: 20px;
  block-size: 20px;
  border-radius: var(--r-xs);
}
.ob-notice {
  margin-block-end: var(--s-4);
}

/* Try it: the QR card, then what's happening on the phone. */
.ob-try {
  display: grid;
  gap: var(--s-5);
}
.ob-try--start {
  justify-items: start;
  padding: var(--s-5);
  border: 1px dashed var(--c-line-strong);
  border-radius: var(--r-card);
}
.ob-try--start > .ui-icon {
  inline-size: 32px;
  block-size: 32px;
  color: var(--c-accent-ink);
}
.ob-try__lead {
  margin: 0;
  font-size: var(--fs-16);
  font-weight: var(--fw-medium);
}
.ob-try__how {
  margin: 0;
  padding-inline-start: var(--s-5);
  display: grid;
  gap: var(--s-1);
  color: var(--c-muted);
}
.ob-try__state {
  display: grid;
  gap: var(--s-2);
}
.ob-try__note {
  margin: 0;
}
.ob-status {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  margin: 0;
  font-weight: var(--fw-medium);
}
.ob-status[data-tone='ready'] {
  color: var(--c-ready-ink);
}
.ob-status[data-tone='seen'] {
  color: var(--c-accent-ink);
}
.ob-status .ui-icon {
  inline-size: 20px;
  block-size: 20px;
}

@media (max-width: 599px) {
  .ob-app .sh-main.ob-main {
    padding: 0;
  }
}

}
/* surfaces/home.css */
@layer surfaces {
/* C2 Home (release-v2 P16; experience-v2 §13 C2): the analytics dashboard, guests' notes, the one-time
   downgrade Callout. Help (critique 3.12): who to ask first, then the topics, then Privacy and Terms. */

/* The analytics dashboard (2026-11-09): a head row (title, "changes compare with …", the period), four KPIs, then
   panels on a two-column grid from 1024 px (the trend, pickups and the branch table span both). */
.an-dash {
  display: flex;
  flex-direction: column;
  gap: var(--s-5);
  transition: opacity var(--dur-1) var(--ease-standard);
}
.an-dash.is-refreshing > :not(.an-head) {
  opacity: 0.55;
}
.an-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--s-3) var(--s-4);
}
.an-head__title {
  margin: 0;
}
.an-head__vs {
  margin: var(--s-1) 0 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.an-kpis {
  display: grid;
  gap: var(--s-3);
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
@media (min-width: 1024px) {
  .an-kpis {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: var(--s-4);
  }
}
.an-grid {
  display: grid;
  gap: var(--s-4);
  grid-template-columns: minmax(0, 1fr);
}
@media (min-width: 1024px) {
  .an-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .an-panel--wide {
    grid-column: 1 / -1;
  }
}
.an-panel {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  min-width: 0;
  padding: var(--pad-card);
  border: 1px solid var(--c-line);
  border-radius: var(--r-card);
  background: var(--c-surface);
}
@media (max-width: 599px) {
  .an-panel {
    padding: var(--s-4);
  }
  .ui-card.an-dash {
    padding-inline: var(--s-3);
  }
}
.an-panel__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--s-1) var(--s-3);
}
.an-panel__head .ui-h3 {
  margin: 0;
}
.an-panel__aside,
.an-panel__empty {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.an-facts {
  display: grid;
  gap: var(--s-3);
  margin: 0;
}
.an-facts--row {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
@media (min-width: 1024px) {
  .an-facts--row {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}
.an-facts:not(.an-facts--row) .an-fact {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: baseline;
  gap: 0 var(--s-3);
  padding-block-end: var(--s-3);
  border-block-end: 1px solid var(--c-line);
}
.an-facts:not(.an-facts--row) .an-fact:last-child {
  padding-block-end: 0;
  border-block-end: 0;
}
.an-fact__label {
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.an-fact__value {
  margin: 0;
  color: var(--c-ink);
  font-size: var(--fs-18);
  line-height: var(--lh-18);
  font-weight: var(--fw-strong);
}
.an-facts:not(.an-facts--row) .an-fact__value {
  text-align: end;
}
.an-fact__hint {
  grid-column: 1 / -1;
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
}
.an-dash .ui-statcard {
  background: var(--c-surface-2);
}
/* The branch table sits in its panel: no second card frame. */
.an-branches .ui-table {
  border: 0;
  border-radius: 0;
}

/* G-12: what guests said after "Too long". */
.hm-notes__list {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  margin: var(--s-3) 0 0;
  padding: 0;
  list-style: none;
}
.hm-note {
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
  padding: var(--s-3) var(--s-4);
  border-radius: var(--r-md);
  background: var(--c-surface-2);
}
.hm-note__text {
  quotes: none;
  overflow-wrap: anywhere;
}
.hm-downgrade {
  margin-block-end: var(--s-4);
}
.hm-downgrade .ui-cluster-2 {
  margin-block-start: var(--s-3);
}

/* Help */
.hp-main {
  display: grid;
  gap: var(--s-5);
  max-width: 760px;
}
.hp-contact {
  padding: var(--s-5);
}
.hp-am {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  margin: 0 0 var(--s-2);
}
.hp-lead {
  margin: 0 0 var(--s-4);
  color: var(--c-muted);
}
.hp-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
}
.hp-number {
  margin: var(--s-2) 0 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
  font-variant-numeric: tabular-nums;
  text-align: start;
}
[dir='rtl'] .hp-number {
  text-align: end;
}
.hp-sec {
  padding: var(--s-4) var(--s-5);
}
.hp-sec__title {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  margin: 0 0 var(--s-2);
}
.hp-legal {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-5);
  padding-block: var(--s-2);
  font-size: var(--fs-14);
}
@media (max-width: 599px) {
  .hp-actions .ui-btn {
    flex: 1 1 100%;
  }
}

}
/* surfaces/orders.css */
@layer surfaces {
/* C3 Orders (release-v2 P16; experience-v2 §13 C3, H5): ( Today | History ), the FilterBar, the DataTable with
   ListRows on phones, and the order timeline Sheet. Numbers in the tenant's digits, tabular. */

.ord-tabs {
  margin-block-end: var(--s-4);
}
.ord-filters {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
  align-items: center;
}
.ord-filtersbtn {
  display: none;
}
@media (max-width: 767px) {
  .ord-filtersbtn {
    display: inline-flex;
  }
  .ord .ord-filters {
    display: none;
  }
  .ord[data-filters='open'] .ord-filters {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    inline-size: 100%;
  }
}
.ord-num {
  font-weight: var(--fw-strong);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.ord-code {
  font-family: var(--f-mono);
  font-size: var(--fs-13);
  letter-spacing: 0.04em;
  color: var(--c-muted);
}
.ord-day {
  color: var(--c-muted);
}
.ord-muted {
  color: var(--c-muted);
}
.ord-by {
  display: inline-flex;
  align-items: center;
  gap: var(--s-1);
  min-width: 0;
}
.ord-by .ui-icon {
  inline-size: 16px;
  block-size: 16px;
  flex: none;
  color: var(--c-muted);
}
.ord-by--bellou {
  color: var(--c-acting-ink, var(--c-ink));
}
.ord-by--bellou .ui-icon {
  color: inherit;
}

/* The Sheet */
.ord-sheet {
  display: grid;
  gap: var(--s-4);
}
.ord-sheet__status {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
  margin: 0;
}
.ord-sheet__where {
  color: var(--c-muted);
}
.ord-sheet__facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--s-3);
  margin: 0;
}
.ord-sheet__facts dt {
  color: var(--c-muted);
  font-size: var(--fs-12);
}
.ord-sheet__facts dd {
  margin: 0;
  font-weight: var(--fw-medium);
}
.ord-sheet__h {
  margin: 0;
}
.ord-ev {
  font-weight: var(--fw-medium);
}
.ord-ev__by {
  color: var(--c-muted);
}
.ord-sheet__privacy {
  display: flex;
  align-items: flex-start;
  gap: var(--s-2);
  margin: 0;
  font-size: var(--fs-13);
}
.ord-sheet__privacy .ui-icon {
  inline-size: 16px;
  block-size: 16px;
  flex: none;
  margin-block-start: 2px;
}

/* Settings (P16): the subdomain line, Integrations and the Danger zone. */
/* One row: "Web address  demo-cafe.bellou.io ......... Ask Bellou to change", one divider under all of it, the
   link on the value's baseline at the row's end. */
.set-sub {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--s-1) var(--s-4);
  border-block-end: 1px solid var(--c-line);
}
.set-sub .ui-readonly {
  flex: 1 1 auto;
  justify-content: flex-start;
  gap: var(--s-4);
  border-block-end: 0;
}
.set-muted {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-14);
}
.set-int {
  display: grid;
  gap: var(--s-5);
}
.set-int__item {
  display: grid;
  gap: var(--s-2);
}
.set-int__line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
  margin: 0;
}
.set-locs {
  display: grid;
  gap: var(--s-1);
  margin: 0;
  padding: 0;
  list-style: none;
}
.set-loc {
  display: flex;
  align-items: center;
  gap: var(--s-2);
}
.set-loc__id {
  font-family: var(--f-mono);
  font-size: var(--fs-13);
}
.set-loc .ui-icon {
  inline-size: 16px;
  block-size: 16px;
  color: var(--c-muted);
}
[dir='rtl'] .set-loc .ui-icon {
  transform: scaleX(-1);
}
.set-map {
  display: grid;
  gap: var(--s-3);
  max-width: 440px;
}
#d-fs-danger {
  border-color: var(--c-danger-soft);
}

}
/* surfaces/new-client.css */
@layer surfaces {
/* H3 New client (release-v2 P16; experience-v2 §13 H3): a FocusWizard in the HQ shell, compact, HQ ink, a 640 frame
   left-aligned in the content area. The subdomain's live line sits under its field. */

.nc-page .a-main {
  padding-block: var(--s-6);
}
.nc.ui-tpl--focus {
  max-width: 640px;
}
.nc-fields {
  display: grid;
  gap: var(--s-5);
}
.nc-slugfield {
  display: grid;
  gap: var(--s-2);
}
/* A web address reads left to right in Arabic too: "demo-cafe" then ".bellou.io", the suffix on the right. */
.nc-slugfield .ui-inputgroup {
  direction: ltr;
}
/* The typed name sits right against its suffix, so the box reads as one address ("my-cafe.bellou.io") in both
   languages, never as a name at one edge and ".bellou.io" alone at the other. */
.nc-slugfield .ui-inputgroup > .ui-input {
  padding-inline-end: 0;
  text-align: end; /* the group is direction: ltr, so this is the side next to the suffix */
}
.nc-slugfield .ui-inputgroup > .ui-input + .ui-inputgroup__affix {
  padding-inline-start: 0;
}
/* Hints at caption size, like the plan's "Billed by invoice" next to them (compact HQ density). */
.nc-fields .ui-field__hint {
  font-size: var(--fs-12);
  line-height: var(--lh-12);
}
.nc-slug {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
  min-height: 24px;
  margin: 0;
  font-size: var(--fs-13);
  color: var(--c-muted);
}
.nc-slug p {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  margin: 0;
}
.nc-slug .ui-icon {
  inline-size: 16px;
  block-size: 16px;
  flex: none;
}
.nc-slug[data-state='ok'] {
  color: var(--c-ready-ink);
}
.nc-slug[data-state='bad'] {
  color: var(--c-danger);
}
.nc-ideas {
  display: inline-flex;
  flex-wrap: wrap;
  gap: var(--s-1);
}
.nc-swatches {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
}
.nc-swatch {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  min-height: 36px;
  padding-block: var(--s-1);
  padding-inline: var(--s-1) var(--s-3);
  border: 1px solid var(--c-line);
  border-radius: var(--r-pill);
  background: var(--c-surface);
  color: var(--c-ink);
  font: inherit;
  font-size: var(--fs-13);
  font-variant-numeric: tabular-nums;
  cursor: pointer;
}
.nc-swatch[aria-pressed='true'] {
  border-color: var(--c-ink);
  box-shadow: inset 0 0 0 1px var(--c-ink);
}
.nc-swatch:focus-visible {
  outline: 2px solid var(--c-focus);
  outline-offset: 2px;
}
.nc-swatch__chip {
  inline-size: 24px;
  block-size: 24px;
  border-radius: var(--r-pill);
}
.nc-phase {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  margin: 0;
  color: var(--c-muted);
}

}
/* surfaces/hq-plans.css */
@layer surfaces {
/* HQ commercial ops (release-v2 P18; experience-v2 §13 H12, H13, H17): the console's Plan & features and
   Integrations sections (.hp-*), and the Requests and Audit ListPages (.hq-*). HQ compact density, HQ ink, logical
   properties only (Arabic mirrors), no colour without a word. */

/* ── Console: Plan & features (H12) ─────────────────────────────────────────────────────────────────────────── */
.hp {
  display: grid;
  gap: var(--s-5);
}
/* The section's cards (never the legacy .c-card, which paints paper white in dark mode). */
.hp-card {
  display: grid;
  gap: var(--s-3);
  align-content: start;
}
.hp-card__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--s-3);
}
.hp-card__head .ui-h3 {
  margin: 0;
}
.hp-plan__desc,
.hp-feat__desc,
.hp-int__desc {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.hp-plan .ui-radiocards {
  gap: var(--s-3);
}
.hp-plan .ui-radiocard__desc {
  font-size: var(--fs-12);
  line-height: var(--lh-12);
}
.hp-plan__foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: var(--s-3);
}
.hp-plan__foot:empty,
.hp-plan__foot:has(> [hidden]:only-child) {
  display: none;
}
.hp-plan__foot p {
  flex: 1 1 16rem;
  margin: 0;
  font-size: var(--fs-13);
}

/* Read-only plan cards (account managers, a closed client): the current one is marked, nothing is clickable. */
.hp-plans {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--s-3);
  margin: 0;
  padding: 0;
  list-style: none;
}
@media (min-width: 900px) {
  .hp-plans {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}
.hp-plans__item {
  display: grid;
  gap: var(--s-1);
  align-content: start;
  padding: var(--s-3);
  border: 1px solid var(--c-line);
  border-radius: var(--r-control);
  color: var(--c-muted);
}
.hp-plans__item[aria-current='true'] {
  border-color: var(--c-ink);
  box-shadow: inset 0 0 0 1px var(--c-ink);
  color: var(--c-ink);
}
.hp-plans__name {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
  color: var(--c-ink);
  font-weight: var(--fw-strong);
  font-size: var(--fs-14);
}
.hp-plans__desc {
  font-size: var(--fs-12);
  line-height: var(--lh-12);
}

/* Open plan requests on this client. */
.hp-reqs {
  display: grid;
  gap: var(--s-2);
  padding-block-start: var(--s-3);
  border-block-start: 1px solid var(--c-line);
}
.hp-reqs__title {
  margin: 0;
  font-size: var(--fs-13);
  font-weight: var(--fw-strong);
}
.hp-reqs__list {
  display: grid;
  gap: var(--s-2);
  margin: 0;
  padding: 0;
  list-style: none;
}
.hp-req {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2) var(--s-3);
}
.hp-req__text {
  display: grid;
  flex: 1 1 18rem;
  min-width: 0;
}
.hp-req__ask {
  font-weight: var(--fw-medium);
  font-size: var(--fs-14);
}
.hp-req__meta,
.hp-req__note {
  color: var(--c-muted);
  font-size: var(--fs-13);
}
.hp-req__acts {
  display: flex;
  gap: var(--s-2);
}

/* Features table. */
.hp-feat__head {
  flex-wrap: wrap;
  align-items: flex-start;
}
.hp-feat__head .ui-field {
  margin: 0;
}
.hp-table .ui-table__t td {
  vertical-align: middle;
}
.hp-feat__name {
  font-weight: var(--fw-medium);
}
.hp-table .c-muted,
.hp-table .ui-td:last-child {
  white-space: nowrap;
}
.hp-switch__btn .ui-chev {
  width: 16px;
  height: 16px;
  color: var(--c-muted);
}
.hp-switch {
  display: inline-grid;
  justify-items: start;
  gap: 2px;
}
.hp-switch__btn {
  min-width: 10.5rem;
  justify-content: space-between;
}
.hp-switch__ro {
  font-size: var(--fs-14);
}
.hp-switch__note {
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
}
.hp-switch__note--soon {
  color: var(--c-late);
  font-weight: var(--fw-medium);
}
.hp-eff {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  font-weight: var(--fw-medium);
}
.hp-eff__dot {
  width: 8px;
  height: 8px;
  border-radius: var(--r-pill);
  background: var(--c-ready);
}
.hp-eff--off {
  color: var(--c-muted);
}
.hp-eff--off .hp-eff__dot {
  background: transparent;
  box-shadow: inset 0 0 0 1.5px var(--c-line-strong);
}
.hp-eff__by {
  color: var(--c-muted);
  font-size: var(--fs-12);
}
/* Phone ListRows: the switch, and under it what they actually have. */
.hp-lend {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: var(--s-1);
}
.hp-lend__eff {
  display: inline-flex;
  align-items: center;
  gap: var(--s-1);
  font-size: var(--fs-12);
  color: var(--c-ink);
}
.hp-lend__lbl {
  color: var(--c-muted);
}

/* Plan dialogs: the impact lists and the reason. */
.hp-form {
  display: grid;
  gap: var(--s-4);
}
.hp-reason {
  display: grid;
  gap: var(--s-3);
}
.hp-impact {
  display: grid;
  gap: var(--s-3);
}
.hp-impact__group {
  display: grid;
  gap: var(--s-1);
}
.hp-impact__title {
  margin: 0;
  font-size: var(--fs-13);
  font-weight: var(--fw-strong);
}
.hp-impact__list {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-1) var(--s-4);
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: var(--fs-14);
}
.hp-impact__list li {
  display: inline-flex;
  align-items: center;
  gap: var(--s-1);
}
.hp-impact__list .ui-icon {
  width: 16px;
  height: 16px;
  color: var(--c-muted);
}
.hp-impact__keeps {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
}

/* ── Console: Integrations (H13) ────────────────────────────────────────────────────────────────────────────── */
.hp-int__head {
  align-items: flex-start;
}
.hp-int__body {
  display: grid;
  gap: var(--s-2);
}
.hp-int__line {
  margin: 0;
  font-weight: var(--fw-medium);
  font-size: var(--fs-14);
}
.hp-int__meta,
.hp-int__ro {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
}
.hp-int__acts {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
  padding-block-start: var(--s-3);
  border-block-start: 1px solid var(--c-line);
}
.hp-int__acts:empty {
  display: none;
}
.hp-int__link {
  margin: 0;
  font-size: var(--fs-13);
}
.hp-int__foot {
  margin: 0;
}

/* ── Requests (/requests) ───────────────────────────────────────────────────────────────────────────────────── */
.hq-req__tabs .ui-tab {
  text-decoration: none;
}
.hq-req__tabs .ui-tab[aria-current='page'] {
  border-block-end-color: var(--c-ink);
  color: var(--c-ink);
}
.hq-req__bar {
  margin-block-end: var(--s-3);
}
.hq-client {
  display: grid;
  min-width: 0;
  max-width: 16rem;
}
.hq-req-table .hq-acts,
.hq-req-table .hq-when {
  white-space: nowrap;
}
.hq-client__name {
  overflow: hidden;
  font-weight: var(--fw-medium);
  text-overflow: ellipsis;
  white-space: nowrap;
}
a.hq-client__name {
  color: inherit;
}
.hq-client__meta,
.hq-ask__note,
.hq-outcome__by,
.hq-outcome__note {
  overflow: hidden;
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  text-overflow: ellipsis;
}
.hq-ask {
  display: block;
}
.hq-ask__note {
  display: block;
  max-width: 28rem;
  white-space: normal;
}
.hq-acts {
  display: inline-flex;
  gap: var(--s-2);
  /* Above the row's stretched link. */
  position: relative;
  z-index: 1;
}
.hq-outcome {
  display: grid;
  justify-items: start;
  gap: 2px;
}
.hq-linkbtn {
  appearance: none;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  font-weight: var(--fw-medium);
  text-align: start;
  cursor: pointer;
}
.hq-linkbtn:hover {
  text-decoration: underline;
}
.hq-linkbtn:focus-visible {
  border-radius: var(--r-xs);
  box-shadow: 0 0 0 2px var(--c-focus);
  outline: none;
}

/* ── Audit (/audit, H17) ────────────────────────────────────────────────────────────────────────────────────── */
.hq-af {
  display: grid;
  gap: var(--s-3);
}
.hq-af .ui-filterbar__search {
  flex: 1 1 16rem;
  max-width: 20rem;
}
.hq-af .ui-filterbar__filters .ui-field {
  min-width: 9.5rem;
}
.hq-af__date .ui-datefilter {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: var(--s-3);
}
.hq-af__date .ui-datefilter__range {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-3);
}
.hq-audit-table .ui-table__t td {
  vertical-align: top;
}
.hq-when {
  white-space: nowrap;
  color: var(--c-muted);
  font-size: var(--fs-13);
}
.hq-who {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  min-width: 0;
}
.hq-who__text {
  display: grid;
  min-width: 0;
}
.hq-who__name {
  overflow: hidden;
  font-weight: var(--fw-medium);
  text-overflow: ellipsis;
  white-space: nowrap;
}
.hq-who__meta {
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
}
.hq-what {
  display: block;
}
/* Details: a quiet inline toggle under the sentence, not an accordion row. */
.hq-audit-table .ui-disc {
  margin-block-start: 2px;
  border: 0;
}
.hq-audit-table .ui-disc__btn {
  justify-content: flex-start;
  gap: var(--s-1);
  width: auto;
  min-height: 0;
  padding-block: 2px;
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
  font-weight: var(--fw-medium);
}
.hq-audit-table .ui-disc__btn:hover {
  color: var(--c-ink);
}
.hq-audit-table .ui-disc__chev {
  width: 14px;
  height: 14px;
}
.hq-audit-table .ui-disc__body {
  padding-block-end: var(--s-2);
}
.hq-audit-table a.hq-client__name,
.hq-req-table .ui-row-link {
  text-decoration: none;
}
.hq-audit-table a.hq-client__name:hover {
  text-decoration: underline;
}
.hq-kvs {
  display: grid;
  gap: var(--s-2);
  margin: 0;
  padding-block: var(--s-2);
}
.hq-kv {
  display: grid;
  grid-template-columns: minmax(6rem, auto) minmax(0, 1fr);
  gap: var(--s-3);
  font-size: var(--fs-13);
}
.hq-kv dt {
  color: var(--c-muted);
}
.hq-kv dd {
  margin: 0;
  min-width: 0;
}
.hq-diff {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: var(--s-2);
}
.hq-diff__v {
  padding: 2px var(--s-2);
  border-radius: var(--r-xs);
  background: var(--c-surface-2);
  font-family: var(--f-mono);
  font-size: var(--fs-12);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.hq-diff__arrow {
  color: var(--c-muted);
}
[dir='rtl'] .hq-diff__arrow {
  transform: scaleX(-1);
  display: inline-block;
}
@media (max-width: 599px) {
  .hq-af .ui-filterbar__search {
    max-width: none;
  }
  .hq-kv {
    grid-template-columns: minmax(0, 1fr);
    gap: 2px;
  }
}

/* Grid children of the console cards never grow past the card (the features list on phones). */
.hp .hp-card > * {
  min-width: 0;
}
.hp .ui-listrow__main {
  min-width: 0;
}
@media (max-width: 599px) {
  .hp-switch__btn {
    min-width: 0;
  }
  .hp-plan__foot {
    justify-content: stretch;
  }
  .hp-plan__foot .ui-btn {
    flex: 1 1 100%;
  }
}
.hq-req-table .hq-client {
  min-width: 10rem;
}
/* An email or slug stays on one line (shortened with …), never broken at its hyphen. */
.hq-req-table .hq-client__meta {
  white-space: nowrap;
}
.hq-audit-table .hq-who {
  min-width: 10rem;
}
/* 0039: the Demo plan on the Plan card: running or ended, the last day, orders used, "Extend demo…". */
.hp-demo {
  display: grid;
  gap: var(--s-2);
  padding-block-start: var(--s-3);
  border-block-start: 1px solid var(--c-line);
}
.hp-demo__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
}
.hp-demo__title {
  margin: 0;
  font-size: var(--fs-13);
  font-weight: var(--fw-strong);
}
.hp-demo__facts {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2) var(--s-6);
  margin: 0;
}
.hp-demo__fact {
  display: grid;
  gap: var(--s-1);
}
.hp-demo__fact dt {
  color: var(--c-muted);
  font-size: var(--fs-13);
}
.hp-demo__fact dd {
  margin: 0;
  font-weight: var(--fw-medium);
  font-variant-numeric: tabular-nums;
}
.hp-demo__desc {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
}
.hp-demo__acts {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-2);
}

}
/* surfaces/pricing.css */
@layer surfaces {
/* Surface: prices by country (0040). Layout and text only; every colour is a token.

   bellou.io   .s-plan__price--set   a paid plan's price on its card ("SAR 149" over "per month")
               .s-price-switch       "Prices for Saudi Arabia, in Saudi Riyal [Change country ▾]" above the cards
               .s-price-note         the line under the cards (currency, per month, invoice, VAT)
   HQ          .pr-*                 HQ → Pricing (admins.bellou.io/pricing) and its edit dialog (.pr-dlg__*)
               .hp-price*            the "Price list" card on a client's Plan section */

/* ── bellou.io ─────────────────────────────────────────────────────────────────────────────────────────── */
.s-plan__price--set {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0 var(--s-2);
}
.s-plan__amount {
  font-variant-numeric: tabular-nums;
  unicode-bidi: isolate;
}
.s-plan__per {
  color: var(--c-muted);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
  font-weight: var(--fw-regular);
}
/* The picked plan's amount takes the gradient text; its "per month" stays plain and readable. */
.s-plan--pick .s-plan__price--set {
  background: none;
  color: inherit;
}
.s-plan--pick .s-plan__amount {
  background: var(--s-heat);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.s-price-switch {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2) var(--s-3);
  max-width: var(--w-main);
  margin-block-end: var(--s-4);
  color: var(--c-muted);
}
.s-price-switch > .ui-icon {
  flex: none;
  width: var(--s-5);
  height: var(--s-5);
}
.s-price-switch__text {
  margin: 0;
  color: var(--c-ink);
  font-size: var(--fs-14);
  line-height: var(--lh-14);
  font-weight: 600;
}
.s-price-note {
  max-width: var(--w-main);
  margin-block: var(--s-4) 0;
  color: var(--c-muted);
}

/* ── HQ → Pricing ──────────────────────────────────────────────────────────────────────────────────────── */
.pr-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr); /* the table never widens the card past the page on phones */
  gap: var(--s-3);
  align-content: start;
}
.pr-card__head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--s-3);
}
.pr-card__head .ui-h3 {
  margin: 0;
}
.pr-card__desc {
  margin: var(--s-1) 0 0;
  max-width: var(--w-form);
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.pr-name {
  display: grid;
  gap: 0;
  min-width: 0;
}
.pr-name__title {
  font-weight: 600;
}
.pr-name__sub,
.pr-changed {
  color: var(--c-muted);
  font-size: var(--fs-12);
  line-height: var(--lh-12);
}
.pr-amount {
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.pr-none {
  color: var(--c-muted);
}
.pr-acts {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--s-3);
  white-space: nowrap;
}
.pr-preview {
  font-size: var(--fs-13);
}
.pr-order__list {
  display: grid;
  gap: var(--s-2);
  margin: 0;
  padding-inline-start: var(--s-5);
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}

/* The edit dialog. */
.pr-dlg__form {
  display: grid;
  gap: var(--s-4);
}
.pr-dlg__row,
.pr-dlg__amounts {
  display: grid;
  gap: var(--s-3);
}
.pr-dlg__fixed,
.pr-dlg__hint {
  margin: 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
@media (min-width: 600px) {
  .pr-dlg__row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .pr-dlg__amounts {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* ── A client's Plan section: Price list ───────────────────────────────────────────────────────────────── */
.hp-price {
  grid-template-columns: minmax(0, 1fr);
}
.hp-price__head {
  align-items: flex-start;
  flex-wrap: wrap;
}
.hp-price__desc {
  margin: var(--s-1) 0 0;
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.hp-price__acts {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
}
.hp-price__where {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: var(--s-1) var(--s-3);
  margin: 0;
}
.hp-price__country {
  font-weight: 600;
}
.hp-price__from {
  color: var(--c-muted);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.hp-price__list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--s-3);
  margin: 0;
  padding: 0;
  list-style: none;
}
.hp-price__row {
  display: grid;
  gap: var(--s-1);
  align-content: start;
  padding: var(--s-3);
  border: 1px solid var(--c-line);
  border-radius: var(--r-md);
}
.hp-price__row[aria-current='true'] {
  border-color: var(--c-ink);
}
.hp-price__plan {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-2);
  font-size: var(--fs-13);
  line-height: var(--lh-13);
}
.hp-price__amount {
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  justify-self: start;
}
.hp-price__amount--none {
  color: var(--c-muted);
  font-weight: var(--fw-regular);
}
@media (max-width: 599px) {
  .hp-price__list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
/* Phones: a list row's prices wrap rather than being cut off. */
.pr-table .ui-listrow__meta {
  white-space: normal;
}

}
/* utilities.css */
@layer utilities {
/* Layer: utilities. Layout helpers so pages need no inline styles (strict CSP). Last layer: these win. */
.ui-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}
.ui-stack-1,
.ui-stack-2,
.ui-stack-3,
.ui-stack-4,
.ui-stack-6,
.ui-stack-8 {
  display: flex;
  flex-direction: column;
}
.ui-stack-1 {
  gap: var(--s-1);
}
.ui-stack-2 {
  gap: var(--s-2);
}
.ui-stack-3 {
  gap: var(--s-3);
}
.ui-stack-4 {
  gap: var(--s-4);
}
.ui-stack-6 {
  gap: var(--s-6);
}
.ui-stack-8 {
  gap: var(--s-8);
}
.ui-cluster-1,
.ui-cluster-2,
.ui-cluster-3,
.ui-cluster-4 {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
}
.ui-cluster-1 {
  gap: var(--s-1);
}
.ui-cluster-2 {
  gap: var(--s-2);
}
.ui-cluster-3 {
  gap: var(--s-3);
}
.ui-cluster-4 {
  gap: var(--s-4);
}
.ui-cluster--end {
  justify-content: flex-end;
}
.ui-cluster--between {
  justify-content: space-between;
}
.ui-grow {
  flex: 1;
  min-width: 0;
}
.ui-ltr {
  direction: ltr;
  unicode-bidi: isolate;
}
@media (max-width: 599px) {
  .ui-hide-sm {
    display: none;
  }
}
@media (min-width: 600px) and (max-width: 1023px) {
  .ui-hide-md {
    display: none;
  }
}
@media (min-width: 1024px) {
  .ui-hide-lg {
    display: none;
  }
}
@media (prefers-reduced-motion: reduce) {
  .ui-page *,
  [data-theme] * {
    animation-duration: 0.01ms;
    transition-duration: 0.01ms;
  }
}
/* A short phrase that must not break inside (a branch name, "كل الفروع"); lists wrap between items. */
.ui-nowrap {
  white-space: nowrap;
}

}