/* GS1 Barcode Portal: Studio design system.
   Ported from the approved 12c "luminous compact" mockup with the clarity fixes
   applied (bloom-ink primary, violet-caps labels, one icon per status pill,
   bloom border = selected/current only). Guide: docs/ui/DESIGN_SYSTEM.md.

   This is the only site-wide stylesheet (the legacy styles.css is gone).
   - Tokens, fonts, the aurora background, the app chrome (.app, .rail, .vwrap,
     .vbar) and the JS-driven pieces (dialog, toasts) are global.
   - Every component rule is scoped under body.studio; every page opts in with
     {% block body_class %}studio{% endblock %}.
   - Page-specific rules live in static/css/pages/area-*.css, loaded by the
     pages that need them. Anything two pages share belongs here instead. */

/* ---------- 1. Fonts (SIL OFL, self-hosted; licences in static/fonts/) ---------- */
@font-face{font-family:"Inter";font-style:normal;font-weight:400 700;font-display:swap;
  src:url("../fonts/inter-var-latin.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:"Inter";font-style:normal;font-weight:400 700;font-display:swap;
  src:url("../fonts/inter-var-latin-ext.woff2") format("woff2");
  unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}
@font-face{font-family:"Be Vietnam Pro";font-style:normal;font-weight:200;font-display:swap;
  src:url("../fonts/be-vietnam-pro-200-latin.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:"Be Vietnam Pro";font-style:normal;font-weight:200;font-display:swap;
  src:url("../fonts/be-vietnam-pro-200-latin-ext.woff2") format("woff2");
  unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}
@font-face{font-family:"Be Vietnam Pro";font-style:normal;font-weight:600;font-display:swap;
  src:url("../fonts/be-vietnam-pro-600-latin.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:"Be Vietnam Pro";font-style:normal;font-weight:600;font-display:swap;
  src:url("../fonts/be-vietnam-pro-600-latin-ext.woff2") format("woff2");
  unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}
@font-face{font-family:"Be Vietnam Pro";font-style:normal;font-weight:700;font-display:swap;
  src:url("../fonts/be-vietnam-pro-700-latin.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:"Be Vietnam Pro";font-style:normal;font-weight:700;font-display:swap;
  src:url("../fonts/be-vietnam-pro-700-latin-ext.woff2") format("woff2");
  unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}
@font-face{font-family:"Be Vietnam Pro";font-style:normal;font-weight:800;font-display:swap;
  src:url("../fonts/be-vietnam-pro-800-latin.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:"Be Vietnam Pro";font-style:normal;font-weight:800;font-display:swap;
  src:url("../fonts/be-vietnam-pro-800-latin-ext.woff2") format("woff2");
  unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}

/* ---------- 2. Tokens ---------- */
:root{
  /* Brand gradients. --bloom is for borders and hairlines only; its light stops
     fail as text. --bloom-ink is the dark variant (every stop >=5.4:1 on white,
     >=4.2:1 on the aurora): the only gradient allowed to carry text or fill a
     primary button. */
  --bloom:linear-gradient(90deg,#9920E7,#F948A1,#F85636);
  --bloom-ink:linear-gradient(90deg,#7B12BF,#B0126F 65%,#C0392B);
  --bloom-dot:linear-gradient(135deg,#9920E7,#F948A1);
  --coral-edge:linear-gradient(90deg,#F94F6C,#F85636);

  --bg:#F7F3FB; --surface:#FFFFFF; --subtle:#EFEDF7; --neutral-bg:#ECEAF3; --row-h:#F3F0FA;
  --line:#E3E0EE; --line-strong:#8A86A0; --line-soft:rgba(90,40,150,.10);
  --ink:#232130; --ink-2:#464358; --ink-3:#3A3750; --muted:#514D57;
  --accent:#7B12BF; --accent-hover:#5E0E94; --accent-soft:#F1E6FA; --eyebrow:#6A12A6;
  --coral:#F94F6C;
  --err:#A81E3C; --err-bg:#FFE6EB; --err-line:#F3B7C3;
  --need:#5E0E94; --need-bg:#F1E6FA; --need-line:#D9BFF0;
  --warn:#7A4E00; --warn-bg:#FBF0D6; --warn-line:#E7CE8F; --dot-warn:#E5A100;
  --info:#1A2FB0; --info-bg:#E8ECFF; --info-line:#C5CEFF;
  --ok:#14691B; --ok-bg:#E4F8E5; --ok-line:#B4E8B7;

  --glass:rgba(255,255,255,.74); --glass-hi:rgba(255,255,255,.84); --glass-b:rgba(90,40,150,.08);
  --glass-blur:blur(22px) saturate(1.4);
  --glass-sh-soft:0 8px 32px rgba(90,40,150,.10),0 1px 2px rgba(90,40,150,.06);
  --glass-sh:inset 0 1px 0 rgba(255,255,255,.95),inset 0 -1px 0 rgba(153,32,231,.05),0 10px 34px rgba(90,40,150,.12);
  --sh-2:0 4px 16px rgba(38,38,38,.10);

  --font:Inter,-apple-system,"Segoe UI",Roboto,system-ui,sans-serif;
  --display:"Be Vietnam Pro",Inter,-apple-system,"Segoe UI",sans-serif;
  --mono:ui-monospace,"SF Mono",Menlo,Consolas,monospace;
  /* Type scale. Every text size on both sites is one of these (the page title h1 at 28 is the only exception).
     12 captions, eyebrows, pills, table heads | 13 tables and dense UI | 14 reading text, nav, buttons |
     16 manufacturer-side text, card titles | 18 section heads, dialogs | 24 KPI numbers.
     Weights: 400 / 500 / 600 (the h1's 200/800 pair is the one deliberate exception). */
  --fs-xs:12px; --fs-sm:13px; --fs-md:14px; --fs-lg:16px; --fs-xl:18px; --fs-2xl:24px;
  --r-md:8px; --r-card:16px; --r-pill:999px;
}

/* ---------- 3. Page base (global) ---------- */
*,*::before,*::after{box-sizing:border-box}
html{background:var(--bg)}
body{font-family:var(--font);color:var(--ink);background:transparent;position:relative;min-height:100vh;margin:0;display:flow-root;-webkit-font-smoothing:antialiased}
/* The aurora: fixed-size washes pinned to the page, drawn once behind everything. */
body::before{content:"";position:absolute;inset:0;z-index:-1;pointer-events:none;background:
  radial-gradient(900px 700px at 4% 6%,rgba(153,32,231,.36),transparent 68%),
  radial-gradient(800px 640px at 30% 22%,rgba(248,86,54,.13),transparent 70%),
  radial-gradient(900px 700px at 96% 4%,rgba(249,72,161,.36),transparent 68%),
  radial-gradient(760px 620px at 70% 55%,rgba(98,235,253,.22),transparent 70%),
  radial-gradient(860px 660px at 90% 98%,rgba(248,86,54,.28),transparent 70%),
  radial-gradient(820px 640px at 6% 96%,rgba(98,235,253,.38),transparent 70%),
  radial-gradient(600px 500px at 46% 100%,rgba(153,32,231,.14),transparent 70%),#F6F1FC}
[hidden]{display:none!important}   /* the one !important: [hidden] must beat any display rule */
.sr{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
.skip:focus{position:fixed;left:16px;top:16px;z-index:100;width:auto;height:auto;clip:auto;padding:8px 14px;background:#fff;color:var(--accent);border-radius:10px;box-shadow:var(--sh-2);font-weight:600}
:focus-visible{outline:3px solid var(--accent);outline-offset:2px;box-shadow:0 0 0 2px #fff}
main:focus{outline:none}
button,input,select,textarea{font:inherit}
@media (prefers-reduced-motion:reduce){*{transition:none!important;animation:none!important}}

/* ---------- 4. Chrome (global; rendered by base.html on every page) ---------- */
.mark{width:24px;height:24px;border-radius:8px;background:var(--bloom);flex:none;position:relative}
.mark::after{content:"";position:absolute;inset:6px;background:repeating-linear-gradient(90deg,#fff 0 1.5px,transparent 1.5px 3.5px)}
/* The Infillion circle mark: faint, pinned to the bottom-right of the window and partly off it, behind
   everything, so it sits in empty background rather than behind the content.
   static/img/infillion-mark.svg is the brand guide's mark copied verbatim (all 28 paths), used as a mask. */
.lburst{position:fixed;z-index:-1;right:-140px;bottom:-140px;width:460px;height:460px;pointer-events:none;opacity:.14;
  background:linear-gradient(125deg,#9920E7,#F948A1 55%,#F85636);
  -webkit-mask:url(../img/infillion-mark.svg) center/contain no-repeat;mask:url(../img/infillion-mark.svg) center/contain no-repeat}

/* Internal: sidebar rail + main column. */
.app{position:relative;max-width:1408px;min-height:calc(100vh - 32px);margin:16px auto;padding:12px;display:grid;grid-template-columns:208px minmax(0,1fr);gap:12px;border:1px solid rgba(255,255,255,.7);border-radius:24px}
.rail{position:sticky;top:16px;align-self:start;display:flex;flex-direction:column;gap:2px;padding:12px 10px;border-radius:20px;
  background:linear-gradient(180deg,rgba(255,255,255,.8),rgba(255,255,255,.66));border:1px solid var(--glass-b);box-shadow:var(--glass-sh);
  -webkit-backdrop-filter:var(--glass-blur);backdrop-filter:var(--glass-blur);font-size:14px;line-height:1.45}
.lockup{display:flex;align-items:center;gap:8px;padding:2px 4px 12px}
.lockup-name{font:600 14px/1.45 var(--display);letter-spacing:-.01em;color:var(--ink);white-space:nowrap}
.rail .nav-i{display:flex;align-items:center;gap:10px;height:auto;min-height:36px;padding:6px 10px;line-height:1.3;border-radius:12px;color:var(--ink-2);text-decoration:none;font-size:14px;font-weight:500}
.rail .nav-i:hover{background:var(--subtle);color:var(--ink-2)}
.rail .nav-i svg{width:16px;height:16px;flex:none}
/* Bloom border = current. Padding drops by the border width so text doesn't shift. */
.rail .nav-i[aria-current=page]{padding:4.5px 8.5px;border:1.5px solid transparent;color:var(--ink);font-weight:600;background:linear-gradient(#fff,#fff) padding-box,var(--bloom) border-box}
.rail .nav-i[aria-current=page] svg{color:#9920E7}
.nav-h{padding:12px 10px 4px;font-size:var(--fs-xs);font-weight:600;letter-spacing:.06em;text-transform:uppercase;color:var(--muted)}
.who{margin-top:auto;padding:12px 10px 4px;border-top:1px solid rgba(90,40,150,.12);font-size:12px;color:var(--muted);overflow-wrap:anywhere}
.main{position:relative;min-width:0;padding:2px 4px 20px}
/* Legacy pages put .container on main; its auto side margins would make the grid
   item shrink-to-fit its widest content and push past the viewport. */
.app>.main{margin:0;max-width:none}

/* Manufacturer: same frame as .app (width, inset, radius), header bar, one column. */
.vwrap .team-banner{margin:10px 0 0}
.vwrap{position:relative;max-width:1408px;min-height:calc(100vh - 32px);margin:16px auto;padding:12px;border:1px solid rgba(255,255,255,.7);border-radius:24px}
.vbar{position:relative;height:48px;padding:0 16px;display:flex;align-items:center;justify-content:space-between;gap:16px;border-radius:16px;
  background:var(--glass);border:1px solid var(--glass-b);box-shadow:var(--glass-sh);-webkit-backdrop-filter:var(--glass-blur);backdrop-filter:var(--glass-blur);font-size:14px;line-height:1.45}
.vbar .lockup{padding:0}
.vbar .lockup-name{font:600 var(--fs-md)/18px var(--display);letter-spacing:-.01em}
.sender{font-size:var(--fs-sm);line-height:16px;color:var(--muted)}
.vnav{display:flex;gap:16px;align-items:center;font-size:13px}
.vbar .vnav a{color:var(--accent);text-decoration:underline;text-underline-offset:2px}
.vbar .vnav a[aria-current=page]{font-weight:600;color:var(--ink);text-decoration:none}
.vbar .vnav .sender a{color:var(--accent)}
.vbody{display:flex;justify-content:center;min-width:0;padding:8vh 16px 48px}
.vbody.top{padding-top:20px;padding-bottom:24px}
/* Single-card pages (sign-in, code, reset, password, expired, errors) have no .top:
   the frame shrinks to the card and sits a little above centre. */
/* The small centred card is for signed-out pages only. Signed in (the header has
   its nav), Password and error pages keep the full shell, so the nav doesn't
   jump and shrink between pages (QA, 10/1). */
.vwrap:has(>main.vbody:not(.top)):not(:has(.vnav)){width:fit-content;max-width:calc(100% - 32px);min-height:0;margin:12vh auto 16px}
.vwrap:has(>main.vbody:not(.top)):not(:has(.vnav))>.vbody{padding:12px 0 0}
.vwrap:has(.vnav)>main.vbody:not(.top){display:flex;justify-content:center;padding-top:32px}
.vcol{width:720px;max-width:100%;min-width:0;display:flex;flex-direction:column;gap:16px}
.vcol.wide{width:820px}

/* ---------- 5. Components (opt-in: body.studio) ---------- */
.studio{font-size:14px;line-height:1.45;font-variant-numeric:tabular-nums}
.studio h1,.studio h2,.studio h3,.studio p{margin:0}
.studio a{color:var(--accent);text-decoration:underline;text-underline-offset:2px}
.studio :focus-visible{outline:3px solid var(--accent);outline-offset:2px;box-shadow:0 0 0 2px #fff}

/* Type */
.studio h1{font:200 28px/34px var(--display);letter-spacing:-.02em;color:var(--ink)}
/* Gradient keyword: display sizes only, and only in --bloom-ink. */
.studio h1 b{font-weight:800;padding-right:.04em;background:var(--bloom-ink);-webkit-background-clip:text;background-clip:text;color:transparent}
.studio h2{font-family:var(--display)}
.studio .pagehead{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;margin-bottom:12px}
.studio .sub{margin-top:2px;font-size:13px;color:var(--ink-3)}
.studio .sub b{color:var(--ink);font-weight:600}
.studio .crumb{margin-bottom:4px;font-size:var(--fs-sm);color:var(--muted)}
.studio .crumb a{color:var(--muted)}
.studio .vcol>div:first-child>p{margin-top:2px;font-size:13px;color:var(--ink-3)}
.studio .vcol h1 b,.studio .signin h1 b{padding-bottom:.06em}
/* Eyebrow / section labels: plain violet caps. Never pill-shaped, never clickable-looking. */
.studio :is(b,strong){font-weight:600}
.studio .sl,.studio .card-h h2,.studio .strip h2{display:block;margin:0;padding:0;border:0;background:none;font:600 var(--fs-xs)/16px var(--font);letter-spacing:.08em;text-transform:uppercase;color:var(--eyebrow);white-space:normal}
.studio .sl{margin-bottom:6px}
.studio .sl.rej{color:var(--err)}
.studio .secg{margin:8px 0 -4px;font-size:12px;font-weight:600;letter-spacing:.06em;text-transform:uppercase;color:#4E3A7A}
.studio .hint{font-size:12px;color:var(--muted)}
.studio .mono{font-family:var(--mono);font-size:13px;letter-spacing:.02em;overflow-wrap:anywhere}
.studio .gs1,.studio code{overflow-wrap:anywhere}
.studio p a,.studio .hint a,.studio .msg a{text-decoration:underline;text-underline-offset:2px}

/* Buttons: outlined secondary, filled --bloom-ink primary (one per screen), both 36px. */
.studio .btn{display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:36px;height:auto;padding:0 12px;border:1px solid var(--line-strong);border-radius:var(--r-pill);background:var(--surface);color:var(--ink);font:500 13px/1.45 var(--font);white-space:nowrap;text-decoration:none;cursor:pointer}
.studio .btn:hover{background:var(--subtle);color:var(--ink);border-color:var(--line-strong)}
.studio .btn.pri{padding:0 16px;border:0;background:var(--bloom-ink);color:#fff;font-size:14px;font-weight:600;text-shadow:0 1px 1px rgba(0,0,0,.18)}
.studio .btn.pri:hover{background:var(--bloom-ink);color:#fff;filter:brightness(.92)}
/* The browser's own "Choose File" button, drawn as a .btn. */
.studio input[type=file]{font:400 13px/1.45 var(--font);color:var(--ink-2)}
.studio input[type=file]::file-selector-button{min-height:32px;margin-right:10px;padding:0 12px;border:1px solid var(--line-strong);border-radius:var(--r-pill);background:var(--surface);color:var(--ink);font:500 13px/1.45 var(--font);cursor:pointer}
.studio input[type=file]::file-selector-button:hover{background:var(--subtle)}
.studio .btn.quiet{min-height:28px;padding:0 8px;border-color:transparent;background:transparent;color:var(--accent)}
.studio .btn.quiet:hover{background:var(--accent-soft);color:var(--accent);border-color:transparent}
.studio .btn.danger{color:var(--err);border-color:var(--coral)}
.studio .btn.danger:hover{background:var(--err-bg)}
/* Filled red: the confirm button of anything that removes, archives, dismisses or discards. */
.studio .btn.pri.danger,dialog.modal .btn.pri.danger{border:0;background:var(--err);color:#fff;text-shadow:none}
.studio .btn.pri.danger:hover,dialog.modal .btn.pri.danger:hover{background:#8C1832;color:#fff;filter:none}
.studio .btn.quiet.danger{color:var(--err);border-color:transparent}
.studio .btn.quiet.danger:hover{background:var(--err-bg)}
.studio .btn.sm{min-height:28px;padding:0 10px;font-size:13px}
.studio .btn.full{width:100%}
.studio .btn[disabled],.studio .btn[aria-disabled=true]{color:var(--muted);border-color:var(--line);background:var(--subtle);cursor:not-allowed;filter:none}
/* Disabled primary: a clear grey, not white on pale pink (QA, 10/1: low contrast). */
.studio .btn.pri[disabled],.studio .btn.pri[aria-disabled=true]{color:var(--muted);background:var(--subtle);border-color:var(--line);opacity:1;filter:none}
.studio .btn.quiet[disabled]{color:var(--muted);background:none;border-color:transparent}
.studio .page-actions{display:flex;gap:8px;align-items:center;margin-left:auto}

/* Cards (glass). Content surfaces are more opaque; the value inherits to glass inside them. */
.studio .card,.studio .strip,.studio .hero,.studio .bc,.studio .opt{--glass:rgba(255,255,255,.9)}
.studio .card{margin:0;padding:0;border-radius:var(--r-card);background:var(--glass);border:1px solid var(--glass-b);box-shadow:var(--glass-sh);-webkit-backdrop-filter:var(--glass-blur);backdrop-filter:var(--glass-blur)}
/* The card's own edge closes a table; a last-row divider would leave a light line under a tinted row. */
.studio .card table>tbody:last-child>tr:last-child>td,.studio .card table>tbody:last-child>tr:last-child>th{border-bottom:0}
.studio .card-h{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 16px;border-bottom:1px solid var(--line-soft)}
.studio .card-b{padding:16px}
.studio .card-b summary{min-height:32px;padding:4px 0}
.studio summary.card-h{justify-content:flex-start;gap:8px}
.studio summary.card-h .hint:last-child{margin-left:auto}
.studio .offer{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));padding:14px 16px}
.studio .offer>*{min-width:0}
.studio .offer div{padding-right:12px}
.studio .offer .k{font-size:var(--fs-xs);font-weight:500;color:var(--muted)}
.studio .offer .v{font-size:var(--fs-md);font-weight:600}
.studio .offer{row-gap:10px}
/* Several barcodes: the summary row and one row per barcode share one set of
   columns (label, dates, then two short values), so the values line up down
   the card. The offer name takes the label and dates columns. */
.studio .offer.multi{--bc-cols:96px minmax(0,1.5fr) minmax(0,1fr) minmax(0,1fr);grid-template-columns:var(--bc-cols)}
.studio .offer.multi .o-name{grid-column:1/3;padding-right:0}
.studio .offer .bc-row{grid-column:1/-1;display:grid;grid-template-columns:var(--bc-cols);row-gap:10px;padding:12px 0 0;border-top:1px solid var(--line-soft)}
.studio .offer .bc-row,.studio .offer .bc-row>div:last-child{padding-right:0}
/* The barcode's name sits on its values' line, under the small labels' line. */
.studio .offer .bc-n{padding-top:calc(var(--fs-xs) * 1.45);font-size:var(--fs-md);font-weight:600;color:var(--ink)}
@media (max-width:640px){
  .studio .offer.multi,.studio .offer .bc-row{--bc-cols:minmax(0,1fr) minmax(0,1fr)}
  .studio .offer.multi .o-name,.studio .offer .bc-n{grid-column:1/-1}
  .studio .offer .bc-n{padding-top:0}
}
/* .hero: the one brand moment per page (the GS1 field). Bloom hairline border. */
.studio .hero{padding:16px;border:1px solid transparent;border-radius:20px;background:linear-gradient(#FDFBFF,#FDFBFF) padding-box,var(--bloom) border-box;box-shadow:var(--glass-sh)}
.studio .hero.bad{background:linear-gradient(#FFFBFB,#FFFBFB) padding-box,var(--coral-edge) border-box}
.studio .hero *{min-width:0}
.studio .hero .lbl{font-size:var(--fs-lg);font-weight:600}
.studio .hero .inp{font-family:var(--mono);letter-spacing:.02em}
.studio .rowcard{display:grid;grid-template-columns:1fr auto;gap:12px;align-items:center;padding:14px 16px}
.studio .rowcard h3{font-size:var(--fs-md);font-weight:600}
.studio .rowcard .m{font-size:13px;color:var(--muted)}
.studio .mini{display:flex;gap:4px;margin-top:6px}
.studio .mini i{width:28px;height:6px;border-radius:6px;background:rgba(90,40,150,.16)}
.studio .mini i.d{background:var(--bloom)}
.studio .mini i.b{background:var(--coral)}
.studio .quote{padding:10px 14px;border:1px solid var(--line);border-radius:12px;background:rgba(255,255,255,.7);font-style:normal}

/* State strip: line 1 the state sentence, line 2 the reason, a disclosure, one primary. */
.studio .strip{position:relative;overflow:hidden;display:flex;flex-wrap:wrap;gap:12px;align-items:flex-start;justify-content:space-between;padding:12px 16px;border-radius:var(--r-card);
  background:var(--glass-hi);border:1px solid var(--glass-b);box-shadow:var(--glass-sh);-webkit-backdrop-filter:var(--glass-blur);backdrop-filter:var(--glass-blur)}
.studio .strip p{margin-top:4px;color:var(--ink-2)}
.studio .strip .state-line{font-size:var(--fs-md);line-height:1.4;font-weight:600;color:var(--ink)}
/* The status pill sits on its own line above the sentence, so the two don't crowd each other. */
.studio .strip .state-line>.pill{display:flex;width:fit-content;margin-bottom:6px}

/* Status pills: one icon + one word per state. Coral = problem only. */
.studio .pill{display:inline-flex;align-items:center;gap:5px;height:22px;min-width:max-content;padding:0 8px;border:1px solid var(--line);border-radius:var(--r-pill);background:rgba(255,255,255,.9);color:var(--ink-2);font-size:12px;font-weight:600;white-space:nowrap;
  --pi:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Ccircle cx='8' cy='8' r='6.2' fill='none' stroke='black' stroke-width='1.6'/%3E%3Cpath d='M8 4.5V8l2.3 1.5' fill='none' stroke='black' stroke-width='1.6' stroke-linecap='round'/%3E%3C/svg%3E")}
.studio .pill::before{content:"";flex:none;width:12px;height:12px;background:currentColor;-webkit-mask:var(--pi) center/contain no-repeat;mask:var(--pi) center/contain no-repeat}
.studio .pill.err{background:var(--err-bg);color:var(--err);border-color:var(--err-line);
  --pi:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Ccircle cx='8' cy='8' r='6.2' fill='none' stroke='black' stroke-width='1.6'/%3E%3Cpath d='M5.6 5.6l4.8 4.8M10.4 5.6l-4.8 4.8' stroke='black' stroke-width='1.6' stroke-linecap='round'/%3E%3C/svg%3E")}
.studio .pill.need{background:var(--need-bg);color:var(--need);border-color:var(--need-line);
  --pi:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M2.5 8h10M8.5 3.5L13 8l-4.5 4.5' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E")}
.studio .pill.warn{background:var(--warn-bg);color:var(--warn);border-color:var(--warn-line);
  --pi:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M8 2l6.5 11.5h-13z' fill='none' stroke='black' stroke-width='1.6' stroke-linejoin='round'/%3E%3Cpath d='M8 6.5v3M8 11.3v.2' stroke='black' stroke-width='1.7' stroke-linecap='round'/%3E%3C/svg%3E")}
.studio .pill.info{background:var(--info-bg);color:var(--info);border-color:var(--info-line)}
.studio .pill.ok{background:var(--ok-bg);color:var(--ok);border-color:var(--ok-line);
  --pi:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3 8.5l3.2 3L13 4.5' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E")}
.studio .pill.tag{background:var(--neutral-bg);color:var(--ink-2)}
.studio .pill.tag::before{display:none}
/* A pill inside an eyebrow heading keeps its own case and spacing. */
.studio .card-h h2 .pill{margin-left:4px;text-transform:none;letter-spacing:0;vertical-align:1px}
.studio .pill.tag.warn{background:var(--warn-bg);color:var(--warn)}
.studio .high-value{color:var(--warn)}
.studio .changed{margin-top:8px}
.studio .changed ul{margin:4px 0 0;padding-left:18px}
.studio .pillrow{display:flex;gap:6px;flex-wrap:wrap;align-items:center}
.studio .chips{display:flex;flex-wrap:wrap;gap:6px}
.studio .chipx{display:inline-flex;align-items:center;height:24px;padding:0 10px;border:1px solid var(--line-strong);border-radius:var(--r-pill);background:#fff;font-size:12px;color:var(--ink-2)}
.studio .chipx.upc{font-family:var(--mono);background:var(--row-h);border-color:#D9D2EA}

/* Notices and field messages */
.studio .notice{display:flex;gap:10px;padding:8px 12px;border:1px solid;border-radius:var(--r-md);font-size:13px}
.studio .notice svg{width:16px;height:16px;flex:none;margin-top:3px}
.studio .notice b{font-weight:600}
.studio .notice .grow{flex:1}
.studio .notice .btn:not(.quiet){color:inherit}
.studio .notice.err{background:var(--err-bg);color:var(--err);border-color:var(--err-line)}
.studio .notice.warn{background:var(--warn-bg);color:var(--warn);border-color:var(--warn-line)}
.studio .notice.ok{background:var(--ok-bg);color:var(--ok);border-color:var(--ok-line)}
.studio .notice.info{background:var(--info-bg);color:var(--info);border-color:var(--info-line)}
.studio .msg{display:flex;gap:6px;align-items:flex-start;font-size:12px}
.studio .msg.err{color:var(--err)}
.studio .msg.warn{color:var(--warn)}
.studio .msg.ok{color:var(--ok)}
.studio .msg.info{color:var(--info)}
.studio .msg.edit{color:var(--muted)}
.studio .ico{width:14px;height:14px;flex:none;margin-top:2px}
/* Base-rendered flash messages, restyled as an info notice on converted pages. */
/* A flash is an info notice (same box, icon and colours); only its spacing is its own. */
.studio .flash{margin:0 0 12px;overflow-wrap:anywhere}
.studio .flash p{margin:0}
.studio .flash p+p{margin-top:4px}
/* Success and empty states */
.studio .celebrate{align-items:center;gap:20px;padding:14px 20px;font-size:14px;line-height:20px}
.studio .celebrate svg{margin:0}
.studio .burst{position:relative;flex:none;display:grid;place-items:center;width:48px;height:48px;border-radius:50%;background:var(--accent);color:#fff;box-shadow:0 0 0 5px #fff,0 0 0 8px rgba(34,212,42,.55),0 0 24px rgba(153,32,231,.25)}
.studio .burst::before{content:"";position:absolute;inset:-16px;border-radius:50%;pointer-events:none;background:radial-gradient(circle 4px at 8% 30%,#F949A1 96%,transparent),radial-gradient(circle 3px at 90% 20%,#22D42A 96%,transparent),radial-gradient(circle 5px at 80% 88%,#F85636 96%,transparent),radial-gradient(circle 3px at 14% 80%,#9920E7 96%,transparent),radial-gradient(circle 4px at 50% 2%,#62EBFD 96%,transparent)}
.studio .burst svg{width:22px;height:22px;margin:0}
.studio .center{text-align:center}
.studio .center .burst{margin:0 auto 12px}
.studio .empty{display:flex;align-items:center;gap:14px;padding:14px 16px 8px}
.studio .empty.big{flex-direction:column;text-align:center;padding:32px 16px}
.studio .empty .blob{flex:none;display:grid;place-items:center;width:64px;height:64px;border-radius:50%;color:var(--accent);background:radial-gradient(circle at 30% 25%,rgba(98,235,253,.6),rgba(249,72,161,.22) 62%,transparent 72%);box-shadow:0 0 0 5px rgba(153,32,231,.06)}
.studio .empty .blob svg{width:40px;height:40px}
.studio .empty b{font:600 var(--fs-lg)/22px var(--display)}

/* KPI tiles: filter buttons. Numerals are solid ink; zero goes quiet; .hot = count above 0 that needs Catalina. */
.studio .kpis{display:flex;flex-wrap:wrap;gap:10px;margin:0 0 16px;padding:0;list-style:none}
.studio .kpis>li{flex:1 1 150px;min-width:0;display:flex}
.studio .kpi{flex:1;display:flex;align-items:center;gap:8px;min-height:56px;padding:10px 12px;border-radius:var(--r-card);background:var(--glass);border:1px solid var(--glass-b);box-shadow:var(--glass-sh);-webkit-backdrop-filter:var(--glass-blur);backdrop-filter:var(--glass-blur);font:inherit;text-align:left;color:inherit;width:100%}
.studio button.kpi{cursor:pointer}
.studio .kpi::before{content:"";flex:none;width:28px;height:28px;border-radius:9px;background:var(--ic) center/16px no-repeat,#9A5BD1}
.studio .kpi .n{font:600 var(--fs-2xl)/28px var(--display);letter-spacing:-.02em;color:var(--ink)}
.studio .kpi .n[data-zero]{color:var(--muted)}
.studio .kpi .t{flex:1;min-width:0;font-size:12px;line-height:16px;font-weight:500;color:var(--ink-3)}
.studio .kpi.hot{background:var(--glass-hi);border-color:var(--coral);box-shadow:var(--glass-sh-soft)}
.studio .kpi.hot .n{color:var(--err)}
.studio .kpi:hover{border-color:var(--accent)}
.studio .kpi[aria-pressed=true]{border:1.5px solid transparent;background:linear-gradient(var(--glass-hi),var(--glass-hi)) padding-box,var(--bloom) border-box}
.studio .kpis>li:nth-child(1)>.kpi{--ic:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M4 6h12M4 10h12M4 14h8' stroke='white' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E")}
.studio .kpis>li:nth-child(2)>.kpi{--ic:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M10 4v7M10 15v.5' stroke='white' stroke-width='2.4' stroke-linecap='round'/%3E%3C/svg%3E")}
.studio .kpis>li:nth-child(3)>.kpi{--ic:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Ccircle cx='10' cy='10' r='6.5' fill='none' stroke='white' stroke-width='2'/%3E%3Cpath d='M10 6.5V10l2.5 1.5' stroke='white' stroke-width='2' stroke-linecap='round' fill='none'/%3E%3C/svg%3E")}
.studio .kpis>li:nth-child(4)>.kpi{--ic:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Crect x='3.5' y='5' width='13' height='11' rx='2.5' fill='none' stroke='white' stroke-width='2'/%3E%3Cpath d='M3.5 9h13M7 3v3M13 3v3' stroke='white' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E")}
.studio .kpis>li:nth-child(5)>.kpi{--ic:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M10 3l8 14H2z' fill='none' stroke='white' stroke-width='2' stroke-linejoin='round'/%3E%3Cpath d='M10 8.5v3.5' stroke='white' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E")}
.studio .kpis>li:nth-child(6)>.kpi{--ic:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M4.5 10.5l3.5 3.5 7.5-8' fill='none' stroke='white' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E")}

/* Toolbar, search, segmented control, tabs */
.studio .toolbar{display:flex;align-items:center;flex-wrap:wrap;gap:8px;margin-bottom:12px}
.studio .toolbar .inp{width:auto}
.studio .search{position:relative;flex:1;min-width:200px;max-width:300px}
.studio .search svg{position:absolute;left:10px;top:10px;width:16px;height:16px;color:var(--muted)}
.studio .search .inp{padding-left:32px}
.studio .search .inp::placeholder{color:#6b6878}
.studio .seg{display:inline-flex;margin-left:auto;overflow:hidden;border:1px solid var(--line-strong);border-radius:var(--r-pill);background:rgba(255,255,255,.75)}
.studio .seg button{height:30px;min-height:34px;padding:0 10px;border:0;border-radius:0;background:transparent;color:var(--ink-2);font-size:13px;font-weight:500;cursor:pointer}
.studio .seg button+button{border-left:1px solid var(--line-strong)}
.studio .seg button[aria-pressed=true]{background:var(--accent-soft);color:var(--accent);font-weight:600}
.studio .tabbar{display:flex;flex-wrap:wrap;gap:6px;margin:0 0 16px}
.studio .tab{display:inline-flex;align-items:center;gap:8px;min-height:32px;margin:0;padding:0 12px;border:1.5px solid transparent;border-radius:var(--r-md);background:none;color:var(--ink-2);font-size:13px;font-weight:500;white-space:nowrap;text-decoration:none;cursor:pointer}
.studio .tab:hover{background:var(--subtle);color:var(--ink-2)}
.studio .tab[aria-selected=true],.studio .tab[aria-current=page]{background:linear-gradient(#fff,#fff) padding-box,var(--bloom) border-box;color:var(--need);font-weight:600}
.studio .tab .bdg{display:inline-grid;place-items:center;min-width:20px;height:20px;padding:0 6px;border-radius:var(--r-pill);background:var(--accent-soft);color:var(--need);font-size:12px;font-weight:600}

/* Layout helpers */
.studio .dash-grid{display:grid;grid-template-columns:minmax(0,1fr) 250px;gap:16px;align-items:start}
.studio .detail{display:grid;grid-template-columns:minmax(0,1fr) 340px;gap:16px;align-items:start}
.studio .split{display:grid;grid-template-columns:minmax(0,1fr) 300px;gap:16px;align-items:start}
.studio .two{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:16px;align-items:start}
.studio .stack>*+*,.studio .gap>*+*{margin-top:16px}
.studio .side{gap:12px}
.studio .row-line{display:flex;align-items:center;gap:12px;flex-wrap:wrap}
.studio .pagehead>.row-line{flex:none;flex-wrap:nowrap;gap:8px}
.studio .pagehead>.row-line form{margin:0}
.studio .row-line .grow{flex:1}
.studio .rel{position:relative}
.studio .sect{margin-bottom:16px}
.studio .tag-line{margin-top:6px}

/* Tables. Wrap in .card.tw. Headers stay put while a long table scrolls (Mason,
   9/29: "frozen headers"). overflow-x:clip keeps the card's rounded corners
   without making the card a scroll container, so a sticky header sticks to the
   window. A table genuinely wider than its card gets .wide from studio.js: the
   card then scrolls both ways inside a window-high box, and the header sticks
   to the card instead. */
.studio .tw{position:relative;overflow-x:clip;overflow-y:visible}
.studio .tw.wide{overflow:auto;max-height:calc(100vh - 48px);overscroll-behavior:contain}
.studio .tw thead th{position:sticky;top:0;z-index:2;background:#F4F1FA;box-shadow:inset 0 -1px 0 var(--line)}
.studio .tw:focus-visible{outline:3px solid var(--accent);outline-offset:2px}
.studio table{width:100%;border-collapse:collapse}
.studio th{height:32px;padding:0 8px;text-align:left;white-space:nowrap;border-bottom:1px solid var(--line);background:rgba(243,240,250,.7);font-size:12px;font-weight:600;letter-spacing:.05em;text-transform:uppercase;color:var(--muted)}
.studio td{height:38px;padding:6px 8px;text-align:start;white-space:nowrap;border-bottom:1px solid rgba(90,40,150,.09);font-size:13px}
.studio tr:hover td{background:rgba(255,255,255,.6)}
.studio th.r,.studio td.r{text-align:right}
.studio td a:not(.btn){color:var(--ink);font-weight:600;text-decoration:none}
.studio td a:not(.btn):hover{text-decoration:underline}
/* Group rows: <tbody><tr class="grp"><th scope="rowgroup" colspan="N">Needs action (4)</th></tr> */
.studio tr.grp th,.studio tr.grp td{height:30px;padding:0 8px;background:rgba(243,240,250,.75);font-size:13px;font-weight:600;letter-spacing:0;text-transform:none;text-align:left;color:var(--ink-2)}
.studio tr.grp:hover td{background:var(--subtle)}
.studio tr.wait td,.studio tr.wait td a{color:var(--muted)}
.studio tr.sel td{background:rgba(251,244,255,.9)}
.studio tr.prob td{height:34px;font-size:var(--fs-sm);color:var(--err);background:rgba(255,230,235,.85)}
.studio tr.prob:hover td{background:var(--err-bg)}
/* Note rows wrap (a one-line "Held back ..." note pushed the dashboard table
   past its card), and held back reads as information, not an error (QA, 10/1). */
.studio tr.prob td{white-space:normal}
.studio tr.prob.held td,.studio tr.prob.held:hover td{color:var(--info);background:var(--info-bg)}
.studio tr.strike td{color:var(--muted)}
.studio tr.strike td:first-child{text-decoration:line-through}
.studio td.row-a{padding-right:8px}
.studio td.chk,.studio th.chk{width:36px;padding-right:0}
.studio td .inp{min-height:32px}
.studio .wrapc{white-space:normal;max-width:300px;overflow-wrap:anywhere}
.studio .own{font-weight:500}
.studio .own.you{color:var(--ink)}
.studio .own.them{color:var(--muted);font-weight:400}
.studio .mt td{height:44px}
.studio .bulk{display:flex;align-items:center;gap:8px;flex-wrap:wrap;padding:10px 16px;border-bottom:1px solid var(--line)}
.studio .sortbtn{display:inline-flex;gap:4px;align-items:center;min-height:28px;padding:0;border:0;background:none;font:inherit;color:inherit;letter-spacing:inherit;text-transform:inherit;cursor:pointer}
.studio .sortbtn:hover{color:var(--need)}
.studio .covbar{height:10px;border-radius:6px;background:rgba(90,40,150,.14);overflow:hidden}
.studio .covbar i{display:block;height:100%;background:var(--accent)}

/* Lists: Recent activity, timeline, definition list, checks */
.studio .chg{list-style:none;margin:0;padding:6px 14px 10px}
.studio .chg li{padding:8px 16px;border-bottom:1px solid var(--line);font-size:13px;color:var(--ink-2);overflow-wrap:anywhere}
/* Long typed names and addresses wrap instead of pushing a card sideways. */
.studio .notice .grow,.studio .card-h h2,.studio h1,.studio h3,.studio .msg{overflow-wrap:anywhere}
.studio .chg li:last-child{border:0}
.studio .chg time{display:block;font-size:12px;color:var(--muted)}
.studio .tl{list-style:none;margin:0;padding:0}
.studio .tl li{position:relative;padding:0 0 16px 20px;font-size:var(--fs-sm)}
.studio .tl li::before{content:"";position:absolute;left:0;top:6px;width:9px;height:9px;border-radius:50%;border:2px solid var(--ink-2);background:var(--ink-2)}
.studio .tl li::after{content:"";position:absolute;left:4px;top:18px;bottom:2px;width:1px;background:var(--line)}
.studio .tl li:last-child::after{display:none}
.studio .tl li.err::before{background:var(--coral);border-color:var(--coral)}
.studio .tl li.future::before{background:#fff;border-color:var(--line-strong)}
.studio .tl time{display:block;font-size:var(--fs-xs);color:var(--muted)}
.studio .dl{display:grid;grid-template-columns:180px 1fr;margin:0}
.studio .dl dt,.studio .dl dd{margin:0;padding:6px 0;border-bottom:1px solid var(--line);font-size:13px;min-width:0;overflow-wrap:anywhere}
.studio .dl dt{font-weight:500;color:var(--muted)}
.studio .dl dt:last-of-type,.studio .dl dd:last-of-type{border-bottom:0}
.studio .chk:not(td):not(th){display:flex;flex-direction:column}
.studio .chk:not(td):not(th) div{display:flex;gap:8px;padding:6px 0;border-bottom:1px solid var(--line);font-size:var(--fs-md)}
.studio .chk:not(td):not(th) div:last-child{border:0}
.studio .fix{padding:8px 0 0 24px;color:var(--ink-2)}
.studio .fix ol,.studio .steps ol{margin:4px 0 0;padding-left:20px}
.studio .bcv{display:block;padding:8px 10px;border:1px solid var(--line);border-radius:var(--r-md);background:var(--subtle);font-family:var(--mono);font-size:14px;word-spacing:.35em}
.studio code.gs1{display:inline-block;padding:6px 10px;border:1px solid var(--line);border-radius:8px;background:var(--subtle);font-family:var(--mono);font-size:13px;letter-spacing:.05em;word-spacing:.3em}
.studio .copyrow{display:grid;grid-template-columns:120px 1fr auto;gap:8px;align-items:center;padding:6px 0;border-bottom:1px solid var(--line)}
.studio .copyrow code{padding:4px 8px;border-radius:8px;background:var(--subtle);font-family:var(--mono);font-size:13px}

/* Disclosures */
.studio details>summary{display:flex;align-items:center;gap:8px;min-height:36px;list-style:none;cursor:pointer}
.studio details>summary::-webkit-details-marker{display:none}
.studio details>summary .chev{flex:none;width:14px;height:14px;color:var(--muted);transition:transform .12s}
.studio details[open]>summary .chev{transform:rotate(90deg)}
.studio .opt{padding:0 14px;border-radius:var(--r-card);background:var(--glass-hi);border:1px solid var(--glass-b);box-shadow:var(--glass-sh);-webkit-backdrop-filter:var(--glass-blur);backdrop-filter:var(--glass-blur)}
.studio .opt summary{font-weight:500}
.studio .tools{margin-top:12px}
.studio .tools .btn{width:100%}

/* Forms */
.studio .field{display:flex;flex-direction:column;gap:4px}
.studio .field label,.studio .lbl{font-size:13px;font-weight:500;color:var(--ink)}
.studio .lblrow{display:flex;justify-content:space-between;align-items:baseline}
.studio .inp{width:100%;max-width:none;height:34px;min-height:36px;margin:0;padding:0 10px;border:1px solid var(--line-strong);border-radius:10px;background:rgba(255,255,255,.92);color:var(--ink);font-size:14px;box-shadow:none}
.studio .inp:hover{border-color:var(--ink-2)}
.studio .inp:focus{border-color:var(--line-strong);box-shadow:none}
.studio .inp.warn{padding:0 9px;border:2px solid var(--dot-warn);background:#FFFCF3}
.studio .inp.err{padding:0 9px;border:2px solid var(--coral)}
.studio textarea.inp{height:auto;min-height:72px;padding:8px 10px;line-height:1.4}
.studio textarea.inp.code{min-height:110px;font-family:var(--mono);font-size:13px}
.studio input[type=checkbox]{width:18px;height:18px;accent-color:var(--accent)}
.studio .grid3{display:grid;grid-template-columns:2fr 1fr 1fr 1fr;gap:12px}
.studio .form-col{max-width:760px;padding-bottom:88px}
.studio .bc{padding:12px 16px;border-radius:14px;background:var(--glass-hi);border:1px solid var(--glass-b);box-shadow:var(--glass-sh);-webkit-backdrop-filter:var(--glass-blur);backdrop-filter:var(--glass-blur)}
.studio .bc+.bc{margin-top:12px}
.studio .bc h3{display:flex;justify-content:space-between;align-items:center;margin-bottom:10px;font-size:var(--fs-md);font-weight:600}
/* Choice card: .sel = chosen (bloom border), .dis = disabled with a reason. */
.studio .radio{display:flex;gap:10px;align-items:flex-start;min-height:44px;margin:0;padding:10px 14px;border:1.5px solid var(--line-strong);border-radius:var(--r-card);background:var(--glass-hi);box-shadow:var(--glass-sh);-webkit-backdrop-filter:var(--glass-blur);backdrop-filter:var(--glass-blur);font-size:inherit;font-weight:inherit;color:inherit}
.studio .radio+.radio{margin-top:8px}
.studio .radio input{width:16px;height:16px;margin-top:3px;accent-color:var(--accent)}
.studio .radio.sel{border:2px solid transparent;background:linear-gradient(#FAF3FF,#FAF3FF) padding-box,var(--bloom) border-box}
.studio .radio.dis{border:1px solid var(--line);background:rgba(240,237,247,.7)}
.studio .radio .t1{font-weight:500}
.studio .radio.dis .t1{color:var(--muted)}
.studio .radio .t2{font-size:var(--fs-sm);color:var(--muted)}
.studio .pw{position:relative}
.studio .pw .inp{padding-right:64px}
.studio .pw button{position:absolute;right:4px;top:4px;min-height:36px;min-width:44px;padding:1px 6px;border:0;border-radius:var(--r-md);background:none;color:var(--accent);font-size:var(--fs-sm);font-weight:600;cursor:pointer}
.studio .addrow{display:grid;grid-template-columns:1fr 1.3fr auto;gap:8px;align-items:start;padding:12px 16px;border-top:1px solid var(--line);border-radius:0 0 var(--r-card) var(--r-card);background:#FAF8FF}
/* Drop zone around a file input. As a <label> the whole zone opens the picker
   (put the input inside with class "sr"); as a <div> it frames a visible input.
   .sm is compact, .lg is the page's main upload. .filled once a file is chosen. */
.studio .drop{display:flex;flex-direction:column;align-items:center;gap:4px;padding:18px 14px;border:1.5px dashed var(--line-strong);border-radius:12px;background:rgba(255,255,255,.7);text-align:center;font-size:13px;color:var(--ink-2)}
.studio .drop>svg{width:22px;height:22px;color:var(--accent)}
.studio .drop b{font-weight:600;color:var(--ink)}
.studio .drop p{margin:6px 0}
.studio .drop input[type=file].inp{max-width:340px;height:auto;padding:6px;margin:0 auto}
.studio .drop .msg{justify-content:center;margin-top:8px}
.studio .drop.sm{padding:12px 14px}
.studio .drop.lg{padding:32px;border-width:2px;border-radius:16px;background:rgba(255,255,255,.6)}
.studio .drop.lg>svg{width:28px;height:28px}
.studio label.drop{cursor:pointer}
.studio .card-b>.hint+*:not(input[type=hidden]),.studio .card-b>input[type=hidden]+.drop{margin-top:12px}
.studio label.drop:hover,.studio .drop.dragover{border-color:var(--accent);background:var(--accent-soft)}
.studio .drop:focus-within{outline:3px solid var(--accent);outline-offset:2px}
.studio .drop.filled{border-style:solid;border-color:var(--ok-line);background:var(--ok-bg);color:var(--ok);font-weight:600}
.studio .confirm-inline{display:inline-flex;align-items:center;gap:6px;font-size:var(--fs-sm);font-weight:500;color:var(--err)}
/* Sticky action bar at the foot of long forms (put the form in .form-col). */
.studio .sticky{position:sticky;bottom:12px;display:flex;align-items:center;gap:12px;margin:16px 0 -8px;padding:8px 16px;border-radius:20px;background:var(--glass);border:1px solid var(--glass-b);box-shadow:var(--glass-sh);-webkit-backdrop-filter:var(--glass-blur);backdrop-filter:var(--glass-blur)}
.studio .sticky .sum{flex:1;font-size:var(--fs-md);color:var(--ink-2)}
.studio .sticky .sum b{color:var(--ink);font-weight:600}

/* Contact groups */
.studio .gtitle{display:flex;gap:10px;align-items:baseline}
.studio .gtitle h2{font:600 18px/24px var(--display);letter-spacing:-.01em;color:var(--ink)}
.studio .gcard .meta{margin-top:2px;font-size:var(--fs-sm);color:var(--muted)}
.studio .gcard+.gcard{margin-top:16px}

/* Stepper (manufacturer progress): <ol class="stepper" aria-label="Progress"> */
.studio .stepper{display:flex;align-items:flex-start;margin:0;padding:0;list-style:none}
.studio .st{position:relative;flex:1;display:flex;flex-direction:column;align-items:center;gap:6px;font-size:14px;font-weight:500;text-align:center;color:var(--muted)}
.studio .st:not(:last-child)::after{content:"";position:absolute;top:9px;left:calc(50% + 15px);right:calc(-50% + 15px);height:6px;border-radius:6px;background:rgba(90,40,150,.14)}
.studio .st.done:not(:last-child)::after{background:var(--bloom)}
.studio .dot{position:relative;z-index:1;display:grid;place-items:center;width:24px;height:24px;border-radius:50%;border:2px solid var(--line-strong);background:var(--surface)}
.studio .dot svg{width:12px;height:12px}
.studio .st.done .dot{border-color:transparent;background:var(--bloom-dot);color:#fff}
.studio .st.cur,.studio .st[aria-current=step]{color:var(--ink);font-weight:600}
.studio .st.cur .dot{border:2px solid transparent;background:linear-gradient(#fff,#fff) padding-box,var(--bloom) border-box}
.studio .st.cur .dot::after{content:"";width:8px;height:8px;border-radius:50%;background:var(--accent)}
.studio .st.bad{color:var(--err);font-weight:600}
.studio .st.bad .dot{border-color:var(--coral);color:var(--err)}

/* Manufacturer surface: sign-in card and bigger controls (put .vend on the frame). */
.studio .vend{font-size:var(--fs-lg)}
.studio .vend p,.studio .vend .hint{font-size:14px}
.studio .vend .field label{font-size:var(--fs-md)}
.studio .vend .inp{min-height:44px}
/* File inputs: centre the 32px Choose File button in the 44px box (it sat on the top edge). */
.studio .vend input[type=file].inp{height:auto;padding:5px 6px}
.studio .signin{width:440px;max-width:100%;padding:24px;border-radius:20px}
.studio .signin h1{margin-bottom:6px}
.studio .trust{margin-top:20px;padding-top:14px;border-top:1px solid var(--line);font-size:var(--fs-sm);color:var(--muted)}
.studio .result{margin-top:12px}

/* Client Pack thumbnail */
.studio .pdfprev{flex:none;display:flex;flex-direction:column;gap:7px;width:200px;height:260px;margin-right:-30px;padding:18px 16px;border-radius:var(--r-md);background:var(--glass);border:1px solid var(--glass-b);box-shadow:var(--glass-sh);transform:scale(.85);transform-origin:top left}
.studio .pdfprev i{display:block;height:6px;border-radius:3px;background:var(--neutral-bg)}
.studio .pdfprev i.h{height:10px;width:60%;background:#C9C6C0}
.studio .pdfprev i.s{width:40%}
.studio .pdfprev i.m{width:80%}
.studio .pdfprev .bar{margin-top:auto;height:34px;background:repeating-linear-gradient(90deg,var(--ink) 0 2px,#fff 2px 4px,var(--ink) 4px 5px,#fff 5px 8px)}

/* Reference docs, email mock, preview frame, workflow lanes (Notes, preview, compare) */
.studio .toc{position:sticky;top:12px;display:flex;flex-direction:column;gap:2px}
.studio .toc a{display:flex;align-items:center;min-height:32px;padding:0 10px;border-radius:10px;color:var(--ink-2);font-size:13px;text-decoration:none}
.studio .toc a:hover{background:var(--accent-soft);color:var(--need)}
.studio .doc h2.dh{display:block;margin:0 0 8px;font:600 18px/26px var(--display);letter-spacing:0;text-transform:none;color:var(--ink)}
.studio .doc section{scroll-margin-top:16px}
.studio .doc section+section{margin-top:24px}
.studio .doc p{max-width:72ch;color:var(--ink-2)}
.studio .doc ul{max-width:72ch;margin:6px 0 0;padding-left:20px;color:var(--ink-2)}
.studio .doc li{margin:2px 0}
.studio .mailmock{overflow:hidden;border:1px solid var(--line-strong);border-radius:14px;background:#fff}
.studio .mailmock .mh{padding:12px 16px;border-bottom:1px solid var(--line);font-size:13px;color:var(--ink-2)}
.studio .mailmock .mh b{color:var(--ink)}
.studio .mailmock .mb{padding:16px;font-size:14px}
.studio .mailbody{padding:8px 0 2px 22px;font-size:13px;color:var(--ink-2);white-space:pre-line}
.studio .frame{overflow:hidden;border:1px solid var(--line-strong);border-radius:var(--r-card);background:rgba(255,255,255,.7)}
.studio .frame .fh{display:flex;align-items:center;gap:10px;padding:8px 14px;border-bottom:1px solid var(--line);background:var(--row-h);font-size:12px;color:var(--ink-2)}
.studio .frame .fb{padding:16px}
.studio .flow{display:flex;align-items:stretch;flex-wrap:nowrap}
/* A flow is best written as an <ol>, so a screen reader hears the steps in order. */
.studio ol.flow{max-width:none;margin:10px 0 0;padding:0;list-style:none;color:inherit}
.studio ol.flow>li{margin:0}
.studio .fn{flex:1 1 0;min-width:0;display:flex;flex-direction:column;justify-content:center;padding:8px;border:1px solid var(--line-strong);border-radius:12px;background:#fff;text-align:center;font-size:13px;font-weight:600}
.studio .fn small{display:block;font-size:12px;font-weight:400;color:var(--muted)}
.studio .fn.c{border-color:var(--need-line);background:#F8F2FD}
.studio .fn.m{border-color:#B9C4FF;background:#F1F3FF}
.studio .fn.ok{border-color:#9FD8A4;background:#EDF9EE}
.studio .fn.bad{border-color:#F3A9B8;background:#FFF1F4}
.studio .arr{position:relative;flex:none;align-self:center;width:18px;height:2px;background:var(--line-strong)}
.studio .arr::after{content:"";position:absolute;right:-1px;top:-4px;border:5px solid transparent;border-left:7px solid var(--line-strong);border-right:0}
.studio .lane{display:grid;grid-template-columns:120px 1fr;gap:12px;align-items:center;padding:10px 0;border-top:1px solid var(--line)}
.studio .lane:first-of-type{border-top:0}
.studio .lane b{font-size:12px;letter-spacing:.06em;text-transform:uppercase;color:var(--eyebrow)}

/* ---------- 5b. Shared pieces promoted from the page files ---------- */
/* Small helpers */
.studio .muted{color:var(--muted)}
.studio .inline-form{display:inline;margin:0}
.studio .stack-s>*+*{margin-top:12px}
.studio .stack-s .quote{margin:0}
.studio .stack-s .hint{margin-top:4px}
.studio .form-foot{display:flex;justify-content:flex-end;gap:8px;margin-top:12px}
/* One label + input + button on a line (create a manufacturer, rename a group). */
.studio .addline{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:8px;align-items:end}
.studio .addline .hint{margin-top:2px}
.studio .vend .addrow .btn{min-height:44px}   /* the manufacturer frame makes inputs 44px */
/* Add rows line up from the top: labels get one fixed line and the button drops
   by that line plus the gap. Aligned by the bottom, anything injected under an
   input (a password manager's icon) lifted that whole column. */
.studio .addrow .field label{line-height:20px;white-space:nowrap}
.studio .addrow>.btn{margin-top:24px}
/* Icon-only remove button (a chip's detach, a grid row's delete); 28px target. */
.studio .icon-x{display:inline-grid;place-items:center;width:28px;height:28px;padding:0;border:0;border-radius:50%;background:none;color:var(--muted);cursor:pointer}
.studio .icon-x svg{width:14px;height:14px}
.studio .icon-x:hover{background:var(--err-bg);color:var(--err)}
.studio .chipx .icon-x{width:22px;height:22px;margin-right:-6px}
.studio .chipx .icon-x svg{width:12px;height:12px}
/* A check result that fills in after an action: empty until then. */
.studio .qa{font-size:12px;font-weight:600}
.studio .qa:empty{display:none}
.studio .qa.ok,.studio .qa.bad{display:inline-flex;align-items:center;height:24px;padding:0 10px;border:1px solid;border-radius:var(--r-pill)}
.studio .qa.ok{color:var(--ok);background:var(--ok-bg);border-color:var(--ok-line)}
.studio .qa.bad{color:var(--err);background:var(--err-bg);border-color:var(--err-line)}
.studio .decode-result:empty{display:none}

/* KPI tiles and .seg as links (server-side filters and views). The applied one
   carries aria-current="true" and looks like aria-pressed. */
.studio a.kpi{text-decoration:none;color:inherit;cursor:pointer}
.studio .kpi[aria-current=true]{border:1.5px solid transparent;background:linear-gradient(var(--glass-hi),var(--glass-hi)) padding-box,var(--bloom) border-box}
.studio .seg a{display:inline-flex;align-items:center;height:30px;padding:0 10px;color:var(--ink-2);font-size:13px;font-weight:500;text-decoration:none}
.studio .seg a+a{border-left:1px solid var(--line-strong)}
.studio .seg a:hover{background:var(--subtle)}
.studio .seg a[aria-current=true]{background:var(--accent-soft);color:var(--accent);font-weight:600}
/* A dialog placed in a table cell (a row's confirm) must not inherit nowrap. */
.studio :is(td,th) dialog{white-space:normal;text-align:left;font-weight:400;text-transform:none;letter-spacing:0}

/* State strip layout: the sentence column grows, the actions sit right. */
.studio .strip-main{flex:1;min-width:280px}
.studio .strip-main .hint{margin-top:4px}
.studio .strip-act{display:flex;flex-direction:column;align-items:flex-end;gap:4px}
.studio .strip-act .page-actions{flex-wrap:wrap;justify-content:flex-end}
.studio .strip-act .page-actions form{margin:0}
.studio .strip-act .hint{text-align:right;max-width:320px}
.studio .strip-more{margin-top:6px}
.studio .strip-more p{margin:0;padding:2px 0 0 22px;color:var(--ink-2)}

/* Why a check failed: _explain.html, on the request page, the manufacturer
   page and the preview. */
.studio details.explain{margin:4px 0 0}
.studio details.explain>summary{min-height:32px;color:var(--accent);font-weight:500;font-size:13px}
/* Silvia, 10/7: it didn't look clickable. Underline the title and add a Show/Hide pill. */
.studio details.explain>summary .chev{color:var(--accent)}
.studio details.explain .xpl-t{text-decoration:underline;text-decoration-style:dotted;text-underline-offset:3px}
.studio details.explain>summary:hover .xpl-t{text-decoration-style:solid}
.studio details.explain .xpl-cue::before{content:"Show how to fix";display:inline-block;padding:1px 8px;border:1px solid currentColor;border-radius:999px;font-size:11px;font-weight:600;line-height:16px;white-space:nowrap}
.studio details.explain[open] .xpl-cue::before{content:"Hide"}
.studio .explain-b{padding:0 0 4px 22px}
.studio .explain-b p{margin:0 0 6px;color:var(--ink-2);font-size:13px}
.studio .explain-b .dl{grid-template-columns:140px 1fr;gap:4px 12px}
/* A list of checks, pass or fail, one per line. */
.studio .checks{list-style:none;margin:0;padding:0;display:grid;gap:6px}
.studio .checks li{display:flex;gap:8px;font-size:13px}
.studio .checks li .ico{color:var(--ok)}
.studio .checks li.bad .ico{color:var(--err)}
.studio .checks+.hint{margin-top:10px}

/* Base renders flashes as the first child of <main>; on the manufacturer frame
   that is a centred flex row, so the flash takes its own line at column width.
   A message shown at the card it belongs to (.at-card) replaces the page copy. */
.studio .vbody{flex-wrap:wrap;align-content:flex-start}
.studio .vbody>.flash{flex:1 0 100%;max-width:720px;margin:0 0 12px}
.studio .vbody:has(.at-card)>.flash{display:none}

/* Sortable and filterable tables (tablekit.js adds these). The caret shows on
   hover or focus until a column is sorted. */
.studio .th-sort{cursor:pointer;user-select:none;position:relative;padding-right:16px}
.studio .th-sort:hover,.studio .th-sort:focus-visible{color:var(--accent)}
.studio .th-sort::after{content:"\2195";position:absolute;right:4px;opacity:0;font-size:10px;font-weight:400}
.studio .th-sort:hover::after,.studio .th-sort:focus-visible::after{opacity:.45}
.studio .th-sort.sorted-asc::after{content:"\2191";opacity:1}
.studio .th-sort.sorted-desc::after{content:"\2193";opacity:1}
.studio .tablekit-bar{display:flex;align-items:center;gap:8px;margin:10px 0}
.studio .tablekit-bar .search{flex:0 1 300px}
.studio .tablekit-count{font-size:12px;color:var(--muted);white-space:nowrap}
/* Inside a card (no padding, clipped) the bar needs its own inset, or it sits on
   the card's edge and the focus ring is cut off. */
.studio .card>.tablekit-bar{margin:0;padding:14px 16px 10px}
.studio .tablekit-bar .inp:focus-visible{outline:2px solid var(--accent);outline-offset:1px;box-shadow:none;border-color:transparent}

/* ---------- 6. Dialog and toasts (global; driven by studio.js) ---------- */
dialog.modal{width:min(460px,92vw);max-width:none;padding:20px;border:1px solid var(--glass-b);border-radius:20px;background:#fff;color:var(--ink);box-shadow:var(--sh-2);font:400 14px/1.45 var(--font)}
dialog.modal[open]{display:block}
dialog::backdrop{background:rgba(35,33,48,.35);-webkit-backdrop-filter:blur(2px);backdrop-filter:blur(2px)}
dialog.modal h2{display:block;margin:0 0 8px;font:600 var(--fs-xl)/24px var(--display);letter-spacing:0;text-transform:none;color:var(--ink)}
dialog.modal p{margin:0}
dialog.modal .row{display:flex;gap:8px;justify-content:flex-end;margin-top:20px}
dialog.modal label.check{display:flex;gap:8px;align-items:center;margin-top:14px;font-weight:500;cursor:pointer}
.toasts{position:fixed;right:24px;bottom:24px;z-index:60;display:flex;flex-direction:column;gap:8px;max-width:380px}
.toast{display:flex;gap:10px;align-items:center;padding:10px 14px;border:1px solid var(--glass-b);border-radius:14px;background:rgba(255,255,255,.94);box-shadow:inset 0 1px 0 #fff,0 10px 34px rgba(90,40,150,.2);-webkit-backdrop-filter:blur(18px);backdrop-filter:blur(18px);font:400 13px/1.45 var(--font);color:var(--ink)}
.toast svg{width:16px;height:16px;flex:none}
.toast.ok svg{color:var(--ok)}
.toast.err svg{color:var(--err)}
.toast button{min-height:28px;padding:0 8px;border:0;border-radius:var(--r-pill);background:transparent;color:var(--accent);font:500 13px/1 var(--font);cursor:pointer}
.toast button:hover{background:var(--accent-soft)}

/* ---------- 7. Element resets (inside .studio) ----------
   Browser defaults the components don't want: a bare <button> is text, a
   fieldset has no box, form controls take their colour from the page. */
.studio label{display:inline;margin:0;font-size:inherit;font-weight:inherit;color:inherit}
.studio button{padding:1px 6px;border:0;border-radius:0;background:none;color:inherit;font-weight:inherit}
.studio :is(input,select,textarea){color:inherit}
.studio :is(input[type=text],input[type=email],input[type=password],input[type=date],input[type=search],input:not([type]),textarea,select){margin:0}
.studio fieldset{margin:0;padding:0;border:0;border-radius:0}

/* Dropdown menus. Where the browser supports it (Chrome 135+), the open list is drawn by the page
   instead of the operating system, so it matches the rest of the portal. Other browsers keep their own menu. */
@supports (appearance:base-select){
  /* A long option wraps onto a second line inside the box rather than overflowing it. */
  .studio select{appearance:base-select;display:inline-flex;align-items:center;gap:8px;height:auto;padding-top:6px;padding-bottom:6px;line-height:1.35;text-align:start}
  .studio select.inp{height:auto;padding-top:7px;padding-bottom:7px}
  .studio select::picker-icon{content:"";flex:none;margin-left:auto;width:14px;height:14px;background:var(--muted);
    -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%23000' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 6l4 4 4-4'/%3E%3C/svg%3E") center/contain no-repeat;
    mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%23000' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 6l4 4 4-4'/%3E%3C/svg%3E") center/contain no-repeat}
  .studio select:open::picker-icon{transform:rotate(180deg)}
  .studio select::picker(select){appearance:base-select;max-height:min(360px,60vh);padding:4px;border:1px solid var(--line);border-radius:12px;background:#fff;box-shadow:0 12px 34px rgba(90,40,150,.18)}
  .studio select option{min-height:32px;padding:6px 10px;border-radius:8px;color:var(--ink);font-size:14px}
  .studio select option:hover,.studio select option:focus-visible{background:var(--accent-soft);color:var(--accent);outline:0}
  .studio select option:checked{font-weight:600}
  .studio select option::checkmark{color:var(--accent)}
}

/* The Copy button beside a barcode value; the value is long, so it sits on its own line in narrow cells. */
.studio code.gs1+.copy-btn{margin-left:6px;vertical-align:middle}
/* A label that opens a file picker is clickable too. */
.studio label:has(+input[type=file]),.studio label:has(input[type=file]),.studio input[type=file]{cursor:pointer}

/* Relative-date hint beside a date ("in 5 days", "yesterday"): small, grey, never instead of the date. */
.studio .rel{display:block;font-size:12px;line-height:1.35;color:var(--muted);white-space:nowrap}
.studio .hint .rel,.studio .rel.inl{display:inline}
