/* CA Vision Beauty -- The Lash Lounge. Design tokens read from the operator's mockups
   (synaxis/intake/reference.palette: background #242424, surface #2c2c2c, accent #a5715a, text #c7bdb4)
   and refined by hand where the reader cannot see (gold headings, rose buttons, hairline borders). */
:root {
  --bg: #1f1d1c;
  --bg-2: #242221;
  --surface: #2a2725;
  --surface-2: #322e2b;
  --line: rgba(201, 162, 126, .22);
  --line-strong: rgba(201, 162, 126, .45);
  --text: #e9e0d6;
  --muted: #a99c90;
  --faint: #7d726a;
  --gold: #c9a27e;
  --gold-2: #e2c3a2;
  --rose: #8a5558;
  --rose-2: #a66a6c;
  --copper: #a5715a;
  --ok: #7fa982;
  --warn: #d4a35a;
  --bad: #c46a60;
  --serif: "Cormorant Garamond", "Cormorant", Georgia, "Times New Roman", serif;
  --sans: "Montserrat", "Segoe UI", system-ui, -apple-system, sans-serif;
  --radius: 12px;
  --shadow: 0 10px 30px rgba(0, 0, 0, .35);
  /* the rest of the surfaces, so a palette is one block */
  --glow: #2c2623;
  --side-a: #24211f;
  --side-b: #1d1b1a;
  --card-a: rgba(50, 46, 43, .92);
  --card-b: rgba(40, 37, 35, .92);
  --field: #1d1b1a;
  --well: #1b1918;
  --photo-bg: #151312;
  --hair: rgba(201, 162, 126, .1);
  --tile: rgba(42, 39, 37, .6);
  --nav-on: rgba(166, 106, 108, .45);
  --nav-on-2: rgba(166, 106, 108, .12);
  --hi: #ffffff;
  --on-accent: #ffffff;
  --ok-t: #a9d0ab;
  --warn-t: #e8c48e;
  --bad-t: #e6a39b;
  --grid: #3a3431;
  --plot: #d79a92;
}
/* Studio palettes a technician can choose (the sidebar's swatches). Espresso & Gold above is the default. */
:root[data-palette="ivory"] {
  --bg: #f5efe7; --bg-2: #efe7dc; --surface: #fbf7f1; --surface-2: #f3ebe1;
  --line: rgba(140, 104, 72, .22); --line-strong: rgba(140, 104, 72, .42);
  --text: #2f2723; --muted: #6f6158; --faint: #8f8075;
  --gold: #9a7148; --gold-2: #7d5a37; --rose: #a8696b; --rose-2: #bd7f80; --copper: #a5715a;
  --ok: #4f8a57; --warn: #b07d2c; --bad: #b0504a;
  --shadow: 0 10px 30px rgba(90, 60, 40, .10);
  --glow: #fffaf3; --side-a: #f1e9de; --side-b: #ebe2d5; --card-a: rgba(255, 252, 247, .96); --card-b: rgba(248, 242, 234, .96);
  --field: #fffdf9; --well: #e9dfd2; --photo-bg: #e9dfd2; --hair: rgba(140, 104, 72, .12); --tile: rgba(255, 252, 247, .7);
  --nav-on: rgba(168, 105, 107, .95); --nav-on-2: rgba(168, 105, 107, .78); --hi: #2f2723;
  --ok-t: #3f7a47; --warn-t: #8a611f; --bad-t: #9b3f3a; --grid: #e4d9cc; --plot: #a8696b;
}
:root[data-palette="rosewood"] {
  --bg: #1b1517; --bg-2: #211a1c; --surface: #2a2124; --surface-2: #33282b;
  --line: rgba(214, 170, 160, .2); --line-strong: rgba(214, 170, 160, .42);
  --text: #efe3e0; --muted: #b09a97; --faint: #8a7573;
  --gold: #d6aa9f; --gold-2: #f0cdc3; --rose: #8e3f55; --rose-2: #a9566c; --copper: #b77a6a;
  --ok: #86ad8a; --warn: #d9a866; --bad: #d0706a;
  --glow: #33232a; --side-a: #231b1e; --side-b: #1a1416; --card-a: rgba(51, 40, 43, .92); --card-b: rgba(40, 31, 34, .92);
  --field: #1c1618; --well: #181213; --photo-bg: #140f11; --hair: rgba(214, 170, 160, .1); --tile: rgba(42, 33, 36, .6);
  --nav-on: rgba(169, 86, 108, .5); --nav-on-2: rgba(169, 86, 108, .12);
  --ok-t: #b0d2b3; --warn-t: #ecc794; --bad-t: #eba59e; --grid: #3d2f33; --plot: #e0a2a8;
}
:root[data-palette="sage"] {
  --bg: #181c1a; --bg-2: #1d2220; --surface: #242a27; --surface-2: #2c3330;
  --line: rgba(196, 190, 160, .2); --line-strong: rgba(196, 190, 160, .42);
  --text: #e8e9e3; --muted: #a3a89e; --faint: #7b8178;
  --gold: #c9bf98; --gold-2: #e6dfc0; --rose: #5e7f6f; --rose-2: #739685; --copper: #9a8f6a;
  --ok: #8fb894; --warn: #d6b067; --bad: #c9786c;
  --glow: #26302b; --side-a: #1f2422; --side-b: #171a19; --card-a: rgba(44, 51, 48, .92); --card-b: rgba(35, 41, 38, .92);
  --field: #171b19; --well: #141716; --photo-bg: #121514; --hair: rgba(196, 190, 160, .1); --tile: rgba(36, 42, 39, .6);
  --nav-on: rgba(115, 150, 133, .45); --nav-on-2: rgba(115, 150, 133, .1);
  --ok-t: #b3d6b7; --warn-t: #e9cb8f; --bad-t: #e3a69c; --grid: #343c38; --plot: #a9c4b2;
}
/* The Lash Library's colour schemes as platform palettes (generated from the books' cover, accent, page and ink
   colours by ebooks/scripts/palettes.py), so the books, the studio and the landing page share one set of colours. */
:root[data-palette="champagne"] { --bg: #1b120e; --bg-2: #211712; --surface: #271b16; --surface-2: #2d1f19; --line: rgba(207, 174, 120, 0.22); --line-strong: rgba(207, 174, 120, 0.45); --text: #f5f0e9; --muted: #a69b92; --faint: #85786f; --gold: #cfae78; --gold-2: #dec8a3; --rose: #644f3a; --rose-2: #7a6856; --copper: #9b805a; --glow: #2b1e18; --side-a: #231813; --side-b: #160e0b; --card-a: rgba(45, 31, 25, 0.92); --card-b: rgba(39, 27, 22, 0.92); --field: #18100d; --well: #160e0b; --photo-bg: #120c09; --hair: rgba(207, 174, 120, 0.1); --tile: rgba(39, 27, 22, 0.6); --nav-on: rgba(100, 79, 58, 0.5); --nav-on-2: rgba(100, 79, 58, 0.12); --grid: #36261f; --plot: #dcc49d; }
:root[data-palette="blush"] { --bg: #382128; --bg-2: #432830; --surface: #4d2e37; --surface-2: #56343e; --line: rgba(214, 160, 143, 0.22); --line-strong: rgba(214, 160, 143, 0.45); --text: #f9f0ee; --muted: #bea5a9; --faint: #a5878e; --gold: #d6a08f; --gold-2: #e3beb3; --rose: #8b5e62; --rose-2: #9b7578; --copper: #b28079; --glow: #53323c; --side-a: #462a32; --side-b: #2d1a20; --card-a: rgba(86, 52, 62, 0.92); --card-b: rgba(77, 46, 55, 0.92); --field: #321e24; --well: #2d1a20; --photo-bg: #24151a; --hair: rgba(214, 160, 143, 0.1); --tile: rgba(77, 46, 55, 0.6); --nav-on: rgba(139, 94, 98, 0.5); --nav-on-2: rgba(139, 94, 98, 0.12); --grid: #663f4a; --plot: #e2bbaf; }
:root[data-palette="midnight"] { --bg: #080e1a; --bg-2: #0b1220; --surface: #0d1526; --surface-2: #10182c; --line: rgba(216, 181, 108, 0.22); --line-strong: rgba(216, 181, 108, 0.45); --text: #f8f6f2; --muted: #989ba3; --faint: #707582; --gold: #d8b56c; --gold-2: #e4cd9b; --rose: #4c4a48; --rose-2: #656362; --copper: #94815a; --glow: #0f182a; --side-a: #0c1322; --side-b: #060b15; --card-a: rgba(16, 24, 44, 0.92); --card-b: rgba(13, 21, 38, 0.92); --field: #070d17; --well: #060b15; --photo-bg: #050911; --hair: rgba(216, 181, 108, 0.1); --tile: rgba(13, 21, 38, 0.6); --nav-on: rgba(76, 74, 72, 0.5); --nav-on-2: rgba(76, 74, 72, 0.12); --grid: #141e35; --plot: #e2cb9a; }
:root[data-palette="bronze"] { --bg: #1d2520; --bg-2: #242d27; --surface: #2a342d; --surface-2: #303b33; --line: rgba(184, 143, 92, 0.22); --line-strong: rgba(184, 143, 92, 0.45); --text: #f1f3ee; --muted: #a4aca4; --faint: #858e86; --gold: #b88f5c; --gold-2: #cfb390; --rose: #615f4a; --rose-2: #777563; --copper: #8e7853; --glow: #2e3932; --side-a: #262f29; --side-b: #171e1a; --card-a: rgba(48, 59, 51, 0.92); --card-b: rgba(42, 52, 45, 0.92); --field: #1a211d; --well: #171e1a; --photo-bg: #131815; --hair: rgba(184, 143, 92, 0.1); --tile: rgba(42, 52, 45, 0.6); --nav-on: rgba(97, 95, 74, 0.5); --nav-on-2: rgba(97, 95, 74, 0.12); --grid: #3a473e; --plot: #cbb18e; }
:root[data-palette="pearl"] { --bg: #09090a; --bg-2: #0d0d0e; --surface: #111112; --surface-2: #141416; --line: rgba(200, 188, 166, 0.22); --line-strong: rgba(200, 188, 166, 0.45); --text: #f7f6f4; --muted: #9a9a99; --faint: #737374; --gold: #c8bca6; --gold-2: #dad1c2; --rose: #4d4a46; --rose-2: #666360; --copper: #8c8477; --glow: #131315; --side-a: #0e0e10; --side-b: #070708; --card-a: rgba(20, 20, 22, 0.92); --card-b: rgba(17, 17, 18, 0.92); --field: #080809; --well: #070708; --photo-bg: #060606; --hair: rgba(200, 188, 166, 0.1); --tile: rgba(17, 17, 18, 0.6); --nav-on: rgba(77, 74, 70, 0.5); --nav-on-2: rgba(77, 74, 70, 0.12); --grid: #1a1a1d; --plot: #d8d0c0; }
:root[data-palette="mocha"] { --bg: #2c1d17; --bg-2: #35241d; --surface: #3d2a22; --surface-2: #452f26; --line: rgba(220, 176, 147, 0.22); --line-strong: rgba(220, 176, 147, 0.45); --text: #f6ede5; --muted: #b3a197; --faint: #988278; --gold: #dcb093; --gold-2: #e7c9b6; --rose: #7e5e4e; --rose-2: #907567; --copper: #ae8871; --glow: #432e25; --side-a: #38251e; --side-b: #231712; --card-a: rgba(69, 47, 38, 0.92); --card-b: rgba(61, 42, 34, 0.92); --field: #281a15; --well: #231712; --photo-bg: #1d130f; --hair: rgba(220, 176, 147, 0.1); --tile: rgba(61, 42, 34, 0.6); --nav-on: rgba(126, 94, 78, 0.5); --nav-on-2: rgba(126, 94, 78, 0.12); --grid: #53392f; --plot: #e4c4ae; }
:root[data-palette="plum"] { --bg: #1c1426; --bg-2: #23192e; --surface: #291d36; --surface-2: #2f213d; --line: rgba(207, 176, 122, 0.22); --line-strong: rgba(207, 176, 122, 0.45); --text: #f5f2f8; --muted: #a79db0; --faint: #867a92; --gold: #cfb07a; --gold-2: #dec9a5; --rose: #67515b; --rose-2: #7c6972; --copper: #9c826b; --glow: #2d203a; --side-a: #241a30; --side-b: #16101e; --card-a: rgba(47, 33, 61, 0.92); --card-b: rgba(41, 29, 54, 0.92); --field: #191222; --well: #16101e; --photo-bg: #120d19; --hair: rgba(207, 176, 122, 0.1); --tile: rgba(41, 29, 54, 0.6); --nav-on: rgba(103, 81, 91, 0.5); --nav-on-2: rgba(103, 81, 91, 0.12); --grid: #392849; --plot: #dcc6a5; }
:root[data-palette="wine"] { --bg: #200a0f; --bg-2: #280d13; --surface: #300f17; --surface-2: #37121b; --line: rgba(201, 160, 106, 0.22); --line-strong: rgba(201, 160, 106, 0.45); --text: #f8f1e6; --muted: #ae9491; --faint: #8f6e6f; --gold: #c9a06a; --gold-2: #dabe9a; --rose: #6e3e38; --rose-2: #825954; --copper: #9d7052; --glow: #35111a; --side-a: #2a0e14; --side-b: #1a080c; --card-a: rgba(55, 18, 27, 0.92); --card-b: rgba(48, 15, 23, 0.92); --field: #1d090e; --well: #1a080c; --photo-bg: #15060a; --hair: rgba(201, 160, 106, 0.1); --tile: rgba(48, 15, 23, 0.6); --nav-on: rgba(110, 62, 56, 0.5); --nav-on-2: rgba(110, 62, 56, 0.12); --grid: #441621; --plot: #d9bb93; }
:root[data-palette="ivorylight"] { --bg: #fbf8f3; --bg-2: #f4ede4; --surface: #fdfcf9; --surface-2: #ece2d4; --line: rgba(74, 58, 46, 0.2); --line-strong: rgba(74, 58, 46, 0.4); --text: #2e221c; --muted: #847c76; --faint: #a59e99; --gold: #8c6d44; --gold-2: #73593c; --rose: #4a3a2e; --rose-2: #65584d; --copper: #b08850; --ok: #4f8a57; --warn: #b07d2c; --bad: #b0504a; --shadow: 0 10px 30px rgba(60, 40, 30, .10); --glow: #fdfcfa; --side-a: #f3ece2; --side-b: #ece2d4; --card-a: rgba(253, 252, 250, 0.96); --card-b: rgba(246, 241, 234, 0.96); --field: #fefdfb; --well: #ece2d4; --photo-bg: #ece2d4; --hair: rgba(74, 58, 46, 0.12); --tile: rgba(253, 252, 250, 0.7); --nav-on: rgba(74, 58, 46, 0.92); --nav-on-2: rgba(74, 58, 46, 0.75); --hi: #2e221c; --ok-t: #3f7a47; --warn-t: #8a611f; --bad-t: #9b3f3a; --grid: #d9cec0; --plot: #4a3a2e; }
:root[data-palette="ivorylight"] .vis-studio { --stage-a: #eeeeef; --stage-b: #c6c7ca; --ink: #26262a; --ink-2: #5d5d63; }
:root[data-palette="blushlight"] { --bg: #fbf2ef; --bg-2: #f6e6e2; --surface: #fdf8f7; --surface-2: #f0dad5; --line: rgba(110, 68, 80, 0.2); --line-strong: rgba(110, 68, 80, 0.4); --text: #4a2f37; --muted: #948184; --faint: #b1a0a2; --gold: #9c6661; --gold-2: #8a595a; --rose: #6e4450; --rose-2: #84606a; --copper: #b5786a; --ok: #4f8a57; --warn: #b07d2c; --bad: #b0504a; --shadow: 0 10px 30px rgba(60, 40, 30, .10); --glow: #fdfaf9; --side-a: #f5e5e1; --side-b: #f0dad5; --card-a: rgba(253, 250, 249, 0.96); --card-b: rgba(248, 235, 231, 0.96); --field: #fefbfa; --well: #f0dad5; --photo-bg: #f0dad5; --hair: rgba(110, 68, 80, 0.12); --tile: rgba(253, 250, 249, 0.7); --nav-on: rgba(110, 68, 80, 0.92); --nav-on-2: rgba(110, 68, 80, 0.75); --hi: #4a2f37; --ok-t: #3f7a47; --warn-t: #8a611f; --bad-t: #9b3f3a; --grid: #e0c8c5; --plot: #6e4450; }
:root[data-palette="blushlight"] .vis-studio { --stage-a: #eeeeef; --stage-b: #c6c7ca; --ink: #26262a; --ink-2: #5d5d63; }
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  background: radial-gradient(1200px 700px at 70% -10%, var(--glow) 0%, var(--bg) 55%) fixed, var(--bg);
  color: var(--text); font: 13px/1.45 var(--sans); letter-spacing: .01em;
}
a { color: var(--gold-2); text-decoration: none; }
a:hover { color: var(--hi); }
h1, h2, h3, .serif { font-family: var(--serif); font-weight: 500; letter-spacing: .04em; }
.app { display: grid; grid-template-columns: 248px 1fr; min-height: 100vh; }

/* sidebar */
.side { border-right: 1px solid var(--line); background: linear-gradient(180deg, var(--side-a), var(--side-b)); padding: 22px 16px; position: sticky; top: 0; height: 100vh; overflow: auto; }
.brand { text-align: center; padding-bottom: 14px; border-bottom: 1px solid var(--line); margin-bottom: 14px; }
.brand .mono { font: 600 40px/1 var(--serif); color: var(--gold); letter-spacing: .02em; }
.brand .name { font: 500 22px/1.1 var(--serif); color: var(--gold-2); letter-spacing: .18em; margin-top: 4px; }
.brand .tag { font-size: 10px; letter-spacing: .3em; color: var(--muted); text-transform: uppercase; margin-top: 6px; }
.nav a { display: flex; gap: 10px; align-items: center; padding: 9px 12px; border-radius: 8px; color: var(--text); opacity: .86; }
.nav a:hover { background: var(--surface); opacity: 1; }
.nav a.on { background: linear-gradient(90deg, var(--nav-on), var(--nav-on-2)); color: var(--on-accent); opacity: 1; }
.nav .ico { width: 18px; text-align: center; color: var(--gold); }
.nav .group { font-size: 10px; letter-spacing: .22em; color: var(--faint); text-transform: uppercase; margin: 14px 12px 6px; }
.whoami { margin-top: 16px; border-top: 1px solid var(--line); padding-top: 14px; }
.whoami label { display: block; font-size: 10px; letter-spacing: .2em; color: var(--faint); text-transform: uppercase; margin-bottom: 6px; }
.signin { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 16px; background: radial-gradient(900px 600px at 50% 0%, var(--glow) 0%, var(--bg) 60%), var(--bg); }
.signin-card { width: min(380px, 100%); }
.signin-card h2 { text-align: center; margin: 4px 0 10px; color: var(--gold-2); }

/* top bar */
.main { padding: 22px 26px 40px; min-width: 0; }
.top { display: flex; align-items: center; gap: 14px; margin-bottom: 18px; }
.top h1 { font-size: 30px; margin: 0; color: var(--gold-2); }
.top .sub { color: var(--muted); font-size: 12px; letter-spacing: .12em; text-transform: uppercase; }
.top .spacer { flex: 1; }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px; border: 1px solid var(--line-strong); color: var(--gold-2); font-size: 11px; }
.pill.ok { border-color: var(--ok); color: var(--ok-t); }
.pill.warn { border-color: var(--warn); color: var(--warn-t); }
.pill.bad { border-color: var(--bad); color: var(--bad-t); }
.pill.vip { background: var(--hair); }

/* grid + cards */
.grid { display: grid; gap: 16px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.g5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.span2 { grid-column: span 2; } .span3 { grid-column: span 3; } .span4 { grid-column: span 4; }
.card { background: linear-gradient(180deg, var(--card-a), var(--card-b)); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; box-shadow: var(--shadow); min-width: 0; }
.card h3 { margin: 0; font: 600 11px var(--sans); letter-spacing: .22em; text-transform: uppercase; color: var(--gold); }
.card .brandline { font: italic 13px var(--serif); color: var(--muted); margin: 2px 0 12px; letter-spacing: .02em; }
.card .head { display: flex; align-items: baseline; gap: 10px; }
.card .head .grow { flex: 1; }
.kpi .v { font: 500 34px/1.1 var(--serif); color: var(--hi); margin-top: 8px; }
.kpi .d { color: var(--muted); font-size: 12px; }
.kpi .up { color: var(--ok-t); }
.muted { color: var(--muted); } .faint { color: var(--faint); } .gold { color: var(--gold-2); }
.small { font-size: 11px; } .big { font: 500 22px var(--serif); }
.row { display: flex; align-items: center; gap: 10px; } .row.wrap { flex-wrap: wrap; } .row.between { justify-content: space-between; }
.stack > * + * { margin-top: 8px; }
hr.sep { border: 0; border-top: 1px solid var(--line); margin: 12px 0; }
.list { list-style: none; margin: 0; padding: 0; }
.list li { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--hair); }
.list li:last-child { border-bottom: 0; }
.list .t { color: var(--gold-2); min-width: 64px; font-variant-numeric: tabular-nums; }
.list .grow { flex: 1; min-width: 0; }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 4px 14px; }
.kv dt { color: var(--muted); } .kv dd { margin: 0; }
.empty { color: var(--faint); font-style: italic; padding: 10px 0; }

/* controls */
button, .btn { font: 600 12px var(--sans); letter-spacing: .06em; color: var(--on-accent); background: linear-gradient(180deg, var(--rose-2), var(--rose)); border: 1px solid rgba(255, 255, 255, .08); border-radius: 8px; padding: 9px 14px; cursor: pointer; }
button:hover { filter: brightness(1.08); }
button:disabled { opacity: .45; cursor: not-allowed; filter: none; }
button.ghost { background: transparent; border-color: var(--line-strong); color: var(--gold-2); }
button.wide { width: 100%; }
button.sm { padding: 5px 10px; font-size: 11px; }
input, select, textarea { font: 13px var(--sans); color: var(--text); background: var(--field); border: 1px solid var(--line-strong); border-radius: 8px; padding: 8px 10px; width: 100%; }
textarea { min-height: 70px; resize: vertical; }
label.f { display: block; font-size: 11px; color: var(--muted); letter-spacing: .1em; text-transform: uppercase; margin: 10px 0 4px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { padding: 6px 12px; border-radius: 8px; border: 1px solid var(--line-strong); background: transparent; color: var(--text); font: 500 12px var(--sans); letter-spacing: .02em; }
.chip.on { background: linear-gradient(180deg, var(--rose-2), var(--rose)); border-color: transparent; color: var(--on-accent); }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin: 6px 0 12px; }
.tabs button { background: transparent; border: 0; border-bottom: 2px solid transparent; border-radius: 0; color: var(--muted); padding: 8px 12px; letter-spacing: .04em; }
.tabs button.on { color: var(--gold-2); border-bottom-color: var(--gold); }

/* calendar + slots */
.cal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; text-align: center; font-size: 12px; }
.cal .dow { color: var(--faint); font-size: 10px; letter-spacing: .12em; }
.cal .d { padding: 7px 0; border-radius: 50%; color: var(--faint); }
.cal .d.open { color: var(--text); cursor: pointer; }
.cal .d.open:hover { background: var(--surface-2); }
.cal .d.sel { background: var(--rose); color: var(--on-accent); }
.slots { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.slots button { background: transparent; border: 1px solid var(--line-strong); color: var(--text); font-weight: 500; }
.slots button.on { background: linear-gradient(180deg, var(--rose-2), var(--rose)); color: var(--on-accent); }

/* checklist */
.check li { border: 0; padding: 5px 0; }
.check .box { width: 16px; height: 16px; border-radius: 50%; border: 1px solid var(--line-strong); display: inline-flex; align-items: center; justify-content: center; font-size: 10px; flex: none; }
.check .done .box { background: var(--ok); border-color: var(--ok); color: #13210f; }
.check .now { color: var(--gold-2); }
.check .now .box { border-color: var(--gold); box-shadow: 0 0 0 3px var(--hair); }
.progress { height: 6px; background: var(--well); border-radius: 99px; overflow: hidden; }
.progress > i { display: block; height: 100%; background: linear-gradient(90deg, var(--rose), var(--gold)); }

/* media */
.photo { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 10px; border: 1px solid var(--line); background: var(--photo-bg); display: block; }
.thumbs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.thumbs figure { margin: 0; } .thumbs figcaption { font-size: 10px; color: var(--muted); text-align: center; margin-top: 4px; letter-spacing: .1em; text-transform: uppercase; }
svg text { font-family: var(--sans); }

/* chat */
.chat { display: flex; flex-direction: column; gap: 8px; max-height: 340px; overflow: auto; padding-right: 4px; }
.bubble { padding: 9px 12px; border-radius: 12px; max-width: 88%; white-space: pre-wrap; }
.bubble.me { align-self: flex-end; background: var(--rose); color: var(--on-accent); border-bottom-right-radius: 3px; }
.bubble.ai { align-self: flex-start; background: var(--surface-2); border: 1px solid var(--line); border-bottom-left-radius: 3px; }
.bubble .src { display: block; font-size: 10px; color: var(--faint); margin-top: 4px; letter-spacing: .08em; }
.bubble .facts { margin: 6px 0 0; padding-left: 18px; white-space: normal; max-height: 160px; overflow-y: auto; }

/* workflow strip */
.flow { display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; }
.flow a { border: 1px solid var(--line); border-radius: 10px; padding: 12px; text-align: center; background: var(--tile); color: var(--text); }
.flow a:hover { border-color: var(--gold); }
.flow .n { font: 500 22px var(--serif); color: var(--gold); }
.flow .l { font-size: 11px; letter-spacing: .1em; text-transform: uppercase; }

/* sanctuary language guide */
.guide { margin-top: 22px; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 18px; text-align: center; }
.guide h2 { margin: 0 0 10px; color: var(--gold); letter-spacing: .3em; font-size: 16px; }
.guide .cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 12px; }
.guide .k { font-size: 10px; letter-spacing: .18em; color: var(--muted); text-transform: uppercase; }
.guide .v { font: 500 16px var(--serif); color: var(--gold-2); }
.motto { text-align: center; color: var(--faint); font: italic 14px var(--serif); margin-top: 14px; }

/* toast + modal-ish */
.toast { position: fixed; right: 18px; bottom: 18px; background: var(--surface-2); border: 1px solid var(--line-strong); border-radius: 10px; padding: 10px 14px; box-shadow: var(--shadow); max-width: 420px; z-index: 9; }
.toast.bad { border-color: var(--bad); }
.notice { border: 1px dashed var(--line-strong); border-radius: 10px; padding: 10px 12px; color: var(--muted); font-size: 12px; }
.badge { min-width: 18px; height: 18px; border-radius: 9px; background: var(--rose); color: var(--on-accent); font-size: 10px; display: inline-flex; align-items: center; justify-content: center; padding: 0 5px; }
.table { width: 100%; border-collapse: collapse; }
.table th { text-align: left; font: 600 10px var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--faint); padding: 6px 8px; border-bottom: 1px solid var(--line); }
.table td { padding: 8px; border-bottom: 1px solid var(--hair); }

/* phone frame for the client app */
.phone { max-width: 390px; margin: 0 auto; border: 1px solid var(--line-strong); border-radius: 34px; padding: 18px 16px 24px; background: var(--well); box-shadow: var(--shadow); }

@media (max-width: 1100px) { .g4, .g5 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g3 { grid-template-columns: 1fr 1fr; } .flow { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 760px) {
  .app { grid-template-columns: 1fr; }
  /* the sidebar becomes a slim top bar; the menu button opens the rest */
  .side { position: sticky; top: 0; z-index: 40; height: auto; max-height: 100vh; padding: 10px 16px; display: grid; grid-template-columns: 1fr auto; align-items: center; border-right: 0; border-bottom: 1px solid var(--line); }
  .side .brand { display: flex; align-items: baseline; gap: 10px; text-align: left; padding: 0; margin: 0; border: 0; }
  .side .brand .mono { font-size: 24px; margin: 0; } .side .brand .name { font-size: 13px; letter-spacing: .18em; } .side .brand .tag { display: none; }
  .side .menu-toggle { display: inline-flex; }
  .side > .nav, .side > .whoami { display: none; grid-column: 1 / -1; }
  .side.open { overflow: auto; } .side.open > .nav, .side.open > .whoami { display: block; }
  .main { padding-bottom: 96px; } .finder-open kbd { display: none; }
  .table.stock th:nth-child(2), .table.stock td:nth-child(2) { display: none; }
  .g2, .g3, .g4, .g5 { grid-template-columns: 1fr; } .span2, .span3, .span4 { grid-column: auto; }
  .main { padding: 16px; } .flow { grid-template-columns: repeat(2, 1fr); }
}
.card .card.kpi { padding: 12px; box-shadow: none; }
.card .card.kpi .v { font-size: 24px; }
.card .card.kpi h3 { letter-spacing: .14em; font-size: 10px; }

/* living visuals (visuals.js) */
.vis { position: relative; width: 100%; overflow: hidden; }
.vis canvas { display: block; width: 100% !important; height: 100% !important; }
.vis-orb { margin: -4px 0 6px; }
.hero { position: relative; }
.hero > .vis-drafting { position: absolute; left: -26px; right: -26px; top: -22px; pointer-events: none;
  -webkit-mask-image: linear-gradient(180deg, #000 45%, transparent); mask-image: linear-gradient(180deg, #000 45%, transparent); }
.hero > .top { position: relative; }

/* the lash studio: a neutral stage -- colour is judged against grey, whatever the palette -- with the palette's
   accent only on the tools and the dimensions */
.vis-studio { --stage-a: #2e2f32; --stage-b: #141516; --ink: #e8e6e3; --ink-2: #9a9893;
  border-radius: 10px; border: 1px solid var(--line); touch-action: none;
  background: radial-gradient(75% 85% at 50% 42%, var(--stage-a), var(--stage-b)); }
:root[data-palette="ivory"] .vis-studio { --stage-a: #eeeeef; --stage-b: #c6c7ca; --ink: #26262a; --ink-2: #5d5d63; }
.vis-studio canvas { -webkit-mask-image: radial-gradient(ellipse 64% 74% at 50% 46%, #000 58%, transparent 100%);
  mask-image: radial-gradient(ellipse 64% 74% at 50% 46%, #000 58%, transparent 100%); }
.vis-studio::after { content: ''; position: absolute; inset: 0; pointer-events: none; border-radius: inherit;
  background-image: linear-gradient(to right, rgba(255, 255, 255, .035) 1px, transparent 1px), linear-gradient(to bottom, rgba(255, 255, 255, .035) 1px, transparent 1px);
  background-size: 24px 24px; }
.vis-studio.compact { border-radius: 8px; }
.vis-studio.pending { background: linear-gradient(100deg, var(--stage-b) 30%, var(--stage-a) 50%, var(--stage-b) 70%) 0 0 / 300% 100%; animation: shimmer 1.6s linear infinite; }
.vis-studio canvas { animation: fade-in .5s ease-out both; }
@keyframes fade-in { from { opacity: 0; } }
.vis-studio.compact .viewname, .vis-studio.compact .spec { display: none; }
.vis-studio.link { cursor: pointer; }
.vis-studio.link:hover { border-color: var(--line-strong); }
.vis-studio.flat { background: none; border: 0; }
.vis-studio .inset { position: absolute; right: 10px; top: 10px; z-index: 3; width: 30%; max-width: 170px; border-radius: 7px; overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .28); box-shadow: 0 6px 18px rgba(0, 0, 0, .45); background: #000; pointer-events: none; }
.vis-studio .inset .photo { border: 0; border-radius: 0; aspect-ratio: 4 / 3; }
.vis-studio .inset span { position: absolute; left: 6px; bottom: 5px; font: 600 9px var(--sans); letter-spacing: .14em; text-transform: uppercase; color: #fff; text-shadow: 0 1px 3px #000; }
.vis-studio:not(.compact) .inset { top: 52px; }
.vis-studio.compact .inset { top: auto; bottom: 10px; width: 34%; }
.vis-studio .hud { position: absolute; inset: 0; pointer-events: none; z-index: 1; font: 11px/1.35 var(--sans); color: var(--ink); }
/* what the tools are doing, said under the eye while a step is performed */
.vis-studio .hud .act { position: absolute; left: 16px; bottom: 58px; transform: translateY(6px); padding: 7px 16px; border-radius: 999px; max-width: min(52%, 360px);
  background: rgba(16, 14, 13, .72); color: #f4ece6; font: 500 13px/1.3 var(--sans); letter-spacing: .01em; opacity: 0; transition: opacity .35s, transform .35s;
  backdrop-filter: blur(4px); }
.vis-studio .hud .act.on { opacity: 1; transform: none; }
.vis-studio .labels { position: absolute; inset: 0; }
.vis-studio .dim { position: absolute; transform: translate(-50%, -110%); white-space: nowrap; padding: 2px 6px; border-radius: 4px;
  background: rgba(10, 10, 12, .62); color: var(--gold-2); font: 600 10.5px/1.2 var(--sans); letter-spacing: .04em; font-variant-numeric: tabular-nums;
  border: 1px solid color-mix(in srgb, var(--gold) 45%, transparent); }
:root[data-palette="ivory"] .vis-studio .dim { background: rgba(255, 255, 255, .82); }
.vis-studio.compact .dim { font-size: 9.5px; padding: 1px 4px; }
.vis-studio .scale { position: absolute; left: 14px; bottom: 56px; display: flex; align-items: center; gap: 8px; color: var(--ink-2); font-size: 10px; letter-spacing: .08em; }
.vis-studio .scale i { display: block; height: 6px; border: 1px solid var(--ink-2); border-top: 0; }
.vis-studio.compact .scale { left: 10px; bottom: 8px; }
.vis-studio .viewname { margin-top: 4px; font-size: 9.5px; letter-spacing: .14em; opacity: .8; }
.vis-studio .title, .vis-studio .spec { position: absolute; padding: 7px 10px; border-radius: 7px; background: rgba(12, 12, 14, .5);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); border: 1px solid rgba(255, 255, 255, .08); }
:root[data-palette="ivory"] .vis-studio .title, :root[data-palette="ivory"] .vis-studio .spec { background: rgba(255, 255, 255, .72); border-color: rgba(0, 0, 0, .1); }
.vis-studio .title { left: 14px; top: 52px; display: flex; flex-direction: column; gap: 2px; }
.vis-studio .title b { font: 600 11px var(--sans); letter-spacing: .2em; text-transform: uppercase; color: var(--ink); }
.vis-studio .title span { color: var(--ink-2); font-size: 11px; }
.vis-studio .spec, .vis-studio .title span { color: #c9c6c0; }
:root[data-palette="ivory"] .vis-studio .spec, :root[data-palette="ivory"] .vis-studio .title span { color: var(--ink-2); }
.vis-studio .spec { right: 14px; bottom: 56px; text-align: right; }
.vis-studio .spec b { color: var(--ink); font-weight: 600; }
.vis-studio .toolbar { position: absolute; left: 10px; right: 10px; top: 10px; z-index: 2; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.vis-studio .toolbar.bottom { top: auto; bottom: 10px; justify-content: center; }
.vis-studio .seg { display: inline-flex; border: 1px solid rgba(255, 255, 255, .12); border-radius: 7px; overflow: hidden; background: rgba(12, 12, 14, .55);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
:root[data-palette="ivory"] .vis-studio .seg { background: rgba(255, 255, 255, .7); border-color: rgba(0, 0, 0, .12); }
.vis-studio .tool { background: transparent; border: 0; border-radius: 0; color: var(--ink-2); font: 600 10.5px var(--sans); letter-spacing: .06em; padding: 6px 10px; box-shadow: none; width: auto; }
.vis-studio .tool + .tool { border-left: 1px solid rgba(255, 255, 255, .08); }
.vis-studio .tool:hover { color: var(--ink); filter: none; }
.vis-studio .tool.on { color: var(--ink); background: color-mix(in srgb, var(--gold) 26%, transparent); }
.vis-studio .tool.idle { opacity: .45; }
.vis-studio select.tool { border: 1px solid rgba(255, 255, 255, .12); border-radius: 7px; background: rgba(12, 12, 14, .55); color: var(--ink); padding: 5px 8px; }
:root[data-palette="ivory"] .vis-studio select.tool { background: rgba(255, 255, 255, .7); border-color: rgba(0, 0, 0, .12); }
.vis-studio .tones { padding: 3px 4px; gap: 4px; align-items: center; }
.vis-studio .tone { width: 18px; height: 18px; padding: 0; border-radius: 50%; background: var(--sw); border: 1px solid rgba(0, 0, 0, .35); box-shadow: none; }
.vis-studio .tone.on { outline: 2px solid var(--gold); outline-offset: 1px; }
.vis-studio:fullscreen { border-radius: 0; height: 100vh !important; }

/* photographs: drawn from the studio's own store through the signed-in session; a missing one is an empty
   frame that says so, never a broken image */
.photo.loading { background: linear-gradient(100deg, var(--well) 30%, var(--surface-2) 50%, var(--well) 70%) 0 0 / 300% 100%; animation: shimmer 1.4s linear infinite; }
@keyframes shimmer { to { background-position: -150% 0; } }
.photo.empty { display: grid; place-items: center; align-content: center; gap: 6px; color: var(--faint); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; }
.photo.empty svg { width: 30px; height: 30px; stroke: var(--faint); fill: none; stroke-width: 1.2; }
/* a screen arrives: its cards rise into place, a breath apart; rings draw in */
@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes arc-in { from { stroke-dasharray: 0 var(--c); } }
.main > div > .grid > *, .main > div > .hero + .grid > * { animation: rise .7s cubic-bezier(.2, .7, .2, 1) both; }
.main > div > .grid > :nth-child(2) { animation-delay: .06s; } .main > div > .grid > :nth-child(3) { animation-delay: .12s; }
.main > div > .grid > :nth-child(4) { animation-delay: .18s; } .main > div > .grid > :nth-child(n+5) { animation-delay: .24s; }
.arc { animation: arc-in 1.3s cubic-bezier(.2, .7, .2, 1) both .15s; }
@media (prefers-reduced-motion: reduce) { .main > div > .grid > *, .arc, .photo.loading, .vis-studio.pending, .vis-studio canvas { animation: none; } }

/* palette swatches */
.palettes { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.palettes button { width: 26px; height: 26px; padding: 0; border-radius: 50%; border: 1px solid var(--line-strong); background: var(--sw); box-shadow: none; }
.palettes button.on { outline: 2px solid var(--gold); outline-offset: 2px; }
.palettes button:focus-visible { outline: 2px solid var(--gold-2); outline-offset: 2px; }

/* the desired look's readings: what the vision models read of the photo, each confirmable */
.readings { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 6px 16px; margin-top: 8px; }
.reading { display: grid; grid-template-columns: 112px minmax(110px, 1fr) 74px; align-items: center; gap: 8px; font-size: 11px; }
.reading .k { color: var(--muted); letter-spacing: .04em; }
.reading select { padding: 4px 6px; font-size: 11.5px; }
.reading .pill { justify-self: start; font-size: 10px; padding: 1px 7px; }
.readings-box { margin-top: 12px; border-top: 1px solid var(--line); padding-top: 8px; }
.readings-box summary { cursor: pointer; font-size: 12px; color: var(--gold-2); }

/* fitting a photo to the eye: five handles on the photograph */
.fit-editor { position: relative; }
.fit-editor .photo { display: block; }
.fit-svg { position: absolute; inset: 0; width: 100%; height: 100%; touch-action: none; }
.fit-lid { fill: none; stroke: var(--gold-2); stroke-dasharray: 4 3; opacity: .85; }
.fit-iris { fill: none; stroke: var(--gold-2); opacity: .85; }
.fit-handle { cursor: grab; }
.fit-handle circle { fill: rgba(20, 16, 14, .35); stroke: var(--gold-2); stroke-width: 1.5; vector-effect: non-scaling-stroke; }
.fit-handle circle.dot { fill: var(--gold-2); stroke: none; }
.fit-handle:hover circle:not(.dot) { fill: rgba(226, 195, 162, .3); }
.vis-studio.no-inset .inset { display: none; }

/* the design's path to the chair: numbered steps, done ones checked, the next one lit */
.stepper { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.stepper li { display: grid; grid-template-columns: 30px minmax(0, 1fr); gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line, rgba(255,255,255,.06)); }
.stepper li:last-child { border-bottom: 0; }
.stepper .dot { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; font-size: 12px;
  border: 1px solid var(--muted, #8a7f76); color: var(--muted, #8a7f76); }
.stepper li.done .dot { background: var(--gold, #c9a27e); border-color: var(--gold, #c9a27e); color: var(--bg, #1f1d1c); }
.stepper li.now .dot { border-color: var(--gold, #c9a27e); color: var(--gold, #c9a27e); box-shadow: 0 0 0 3px color-mix(in srgb, var(--gold, #c9a27e) 22%, transparent); }
.stepper .name { font-weight: 600; }
.stepper li:not(.done):not(.now) .name { opacity: .7; }

/* the studio's reference photos beside the 3D: the matching set large, the rest as thumbnails */
.refs { display: grid; gap: 10px; }
.ref-main { margin: 0; display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 14px; align-items: start; }
.ref-main img { width: 100%; max-height: 340px; object-fit: cover; border-radius: 10px; display: block; }
.ref-main figcaption { display: grid; gap: 6px; }
.ref-strip { display: flex; gap: 8px; flex-wrap: wrap; }
.ref-thumb { width: 74px; height: 56px; padding: 0; border-radius: 8px; overflow: hidden; border: 1px solid var(--line); background: transparent; cursor: pointer; }
.ref-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ref-thumb.on { border-color: var(--gold, #c9a27e); box-shadow: 0 0 0 2px var(--gold, #c9a27e); }
@media (max-width: 720px) { .ref-main { grid-template-columns: 1fr; } }

/* marketing studio: the template gallery, the drawn promotion, and its words */
.promo-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.promo-tile { display: grid; gap: 4px; text-align: left; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line); background: transparent; color: var(--text); cursor: pointer; border-left: 4px solid var(--a, var(--gold)); }
.promo-tile.on { background: color-mix(in srgb, var(--a, var(--gold)) 16%, transparent); border-color: var(--a, var(--gold)); }
.promo-canvas { width: 100%; height: auto; border-radius: 10px; display: block; box-shadow: 0 8px 28px rgba(0,0,0,.28); }
.preview { margin-top: 4px; padding: 8px 10px; border-radius: 8px; background: color-mix(in srgb, var(--text) 6%, transparent); }
@media (max-width: 900px) { .promo-gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* the assistant on every screen: a round button bottom-right, and the conversation in a panel above it */
.ai-fab { position: fixed; right: 22px; bottom: 22px; width: 56px; height: 56px; border-radius: 50%; font-size: 22px; z-index: 60;
  background: var(--gold, #c9a27e); color: var(--bg, #1f1d1c); border: 0; box-shadow: 0 8px 26px rgba(0,0,0,.35); cursor: pointer; transition: transform .15s; }
.ai-fab:hover, .ai-fab.on { transform: scale(1.06); }
.ai-drawer { position: fixed; right: 22px; bottom: 90px; width: min(400px, calc(100vw - 32px)); max-height: min(70vh, 640px); z-index: 60;
  display: flex; flex-direction: column; padding: 14px; border-radius: 16px; background: var(--surface, #2a2725); border: 1px solid var(--line);
  box-shadow: 0 18px 50px rgba(0,0,0,.45); }
.ai-drawer[hidden] { display: none; }
.ai-head { margin-bottom: 8px; }
.ai-log { flex: 1; overflow-y: auto; min-height: 160px; max-height: 46vh; }
.ai-chips { gap: 6px; margin-top: 8px; }
.ai-chips .sm { font-size: 12px; }
/* the microphone, always on screen beside the assistant: one tap and speak */
.ai-mic { position: fixed; right: 88px; bottom: 30px; width: 40px; height: 40px; border-radius: 50%; z-index: 60; display: grid; place-items: center; padding: 0;
  background: var(--surface-2); color: var(--gold); border: 1px solid var(--line); box-shadow: 0 6px 18px rgba(0,0,0,.3); cursor: pointer; }
.ai-mic.on, .ai-drawer .icon.on { color: var(--on-accent); background: var(--rose); border-color: var(--rose); animation: listen 1.2s ease-in-out infinite; }
@keyframes listen { 0%, 100% { box-shadow: 0 0 0 0 rgba(166,106,108,.55); } 50% { box-shadow: 0 0 0 9px rgba(166,106,108,0); } }
.ai-drawer .icon { width: 36px; height: 36px; padding: 0; display: grid; place-items: center; flex: none; border-radius: 50%; }
.ai-drawer select.sm { width: auto; padding: 4px 8px; font-size: 12px; }
.ai-drawer { width: min(460px, calc(100vw - 32px)); }
.review-ai { white-space: normal; margin-top: 8px; display: grid; gap: 10px; }
.review-ai .sec { border-top: 1px solid var(--line); padding-top: 8px; display: grid; gap: 3px; }
.review-ai b { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--gold); }
.review-ai ol, .review-ai ul { margin: 2px 0 0 18px; padding: 0; }
.review-ai .claim { display: grid; gap: 2px; padding: 6px 0; }
.review-ai a.src, .review-ai .claim a { font-size: 11px; color: var(--gold-2); }
.dots { display: inline-flex; gap: 4px; } .dots i { width: 6px; height: 6px; border-radius: 50%; background: var(--faint); animation: dot 1s infinite; }
.dots i:nth-child(2) { animation-delay: .15s; } .dots i:nth-child(3) { animation-delay: .3s; }
@keyframes dot { 0%, 100% { opacity: .25; } 50% { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .ai-mic.on, .dots i { animation: none; } }
@media (max-width: 600px) { .ai-drawer { right: 16px; left: 16px; width: auto; bottom: 84px; } .ai-fab { right: 16px; bottom: 16px; } .ai-mic { right: 80px; bottom: 24px; } }

/* room for the assistant's button at the foot of every page */
.main { padding-bottom: 96px; }

/* the finder */
.finder-open { width: 100%; display: flex; justify-content: space-between; align-items: center; margin: 0 0 12px; padding: 8px 12px; background: var(--surface-2); color: var(--faint); border: 1px solid var(--line); border-radius: 10px; font-size: 13px; }
.finder-open kbd { font: 10px var(--sans); border: 1px solid var(--line); border-radius: 4px; padding: 1px 5px; }
.finder-back { position: fixed; inset: 0; background: rgba(0,0,0,.45); z-index: 80; }
.finder { position: fixed; top: 12vh; left: 50%; transform: translateX(-50%); width: min(560px, calc(100vw - 32px)); z-index: 81; background: var(--surface); border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 24px 60px rgba(0,0,0,.5); padding: 12px; }
.finder > input { font-size: 16px; padding: 12px 14px; }
.finder-list { margin-top: 8px; display: grid; max-height: 56vh; overflow-y: auto; }
.finder-row { display: flex; gap: 12px; align-items: center; padding: 9px 10px; border-radius: 10px; color: inherit; text-decoration: none; }
.finder-row.on, .finder-row:hover { background: var(--surface-2); }
.finder-row .ico { width: 20px; text-align: center; color: var(--gold); }
/* before and after, wiped */
.ba { margin-bottom: 12px; }
.ba-frame { position: relative; border-radius: 12px; overflow: hidden; aspect-ratio: 4 / 3; background: var(--surface-2); }
.ba-frame img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ba-top { position: absolute; inset: 0; }
.ba-l, .ba-r { position: absolute; top: 8px; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; background: rgba(0,0,0,.5); color: #fff; padding: 3px 8px; border-radius: 999px; }
.ba-l { left: 8px; } .ba-r { right: 8px; }
.ba input[type=range] { width: 100%; margin-top: 8px; }

/* the platform map */
.journey { display: flex; flex-wrap: wrap; gap: 8px; align-items: stretch; }
.journey .stop { display: flex; align-items: center; gap: 8px; padding: 10px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface-2); color: inherit; text-decoration: none; position: relative; }
.journey .stop:not(:last-child)::after { content: '›'; position: absolute; right: -8px; color: var(--faint); }
.journey .stop.quiet { border-style: dashed; color: var(--muted, inherit); }
.journey .stop .n { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font-size: 11px; background: var(--gold); color: var(--bg); flex: none; }
.journey a.stop:hover { border-color: var(--gold); }
.maplist { display: grid; }
.maprow { display: flex; gap: 12px; align-items: center; padding: 10px 4px; border-bottom: 1px solid var(--line); color: inherit; text-decoration: none; }
.maprow:last-child { border-bottom: 0; }
.maprow .ico { width: 22px; text-align: center; color: var(--gold); }
a.maprow:hover b { color: var(--gold); }

/* Supplies & Orders: labelled fields, a stock table that keeps its columns, vendor rows that align */
.fields .fld { display: block; margin-top: 8px; min-width: 0; }
.fields .fld > span { display: block; font: 600 10px var(--sans); letter-spacing: .16em; text-transform: uppercase; color: var(--faint); margin-bottom: 4px; }
.fields .fld input { width: 100%; box-sizing: border-box; }
.fields .grid { gap: 10px; }
.table th, .table td { vertical-align: middle; }
.table th { white-space: nowrap; }
.table.stock td.num { white-space: nowrap; font-variant-numeric: tabular-nums; }
.table.stock td.num .pill { margin-left: 8px; }
.table.stock td.acts { text-align: right; white-space: nowrap; }
.table.stock td.acts .row { justify-content: flex-end; flex-wrap: nowrap; }
.list.vendors li { align-items: flex-start; }
.list.vendors .rank { color: var(--gold-2); width: 28px; flex: none; padding-top: 2px; font-variant-numeric: tabular-nums; }
.list.vendors .vname { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; margin-bottom: 2px; }
.list.vendors .pill { flex: none; align-self: center; }

.menu-toggle { display: none; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 10px; border: 1px solid var(--line-strong); background: transparent; color: var(--ink); font-size: 18px; cursor: pointer; }

.preview:empty { display: none; }
.stack.bars { margin-top: 12px; }
.one-point { padding: 18px 0 8px; } .one-point .v { font-size: 34px; color: var(--gold-2); }
.nowrap { white-space: nowrap; } .row.nowrap { flex-wrap: nowrap; }

/* Tutorial: the film, its chapters, the guided tour's highlight and note, the newcomer welcome */
.tutorial-grid { grid-template-columns: minmax(0, 1.75fr) minmax(0, 1fr); align-items: start; }
@media (max-width: 1100px) { .tutorial-grid { grid-template-columns: 1fr; } }
.film { position: relative; aspect-ratio: 16 / 9; border-radius: 12px; overflow: hidden; background: var(--well); border: 1px solid var(--line); }
.film video { width: 100%; height: 100%; display: block; background: #000; object-fit: contain; }
.film.empty video { opacity: .25; }
.film-status { position: absolute; inset: auto 0 0 0; padding: 12px 16px; font-size: 13px; color: var(--muted); background: linear-gradient(transparent, var(--well)); }
.chapters { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.chapter { display: flex; gap: 12px; align-items: baseline; width: 100%; text-align: left; background: transparent; border: 0; border-radius: 8px; padding: 8px; color: var(--ink); cursor: pointer; font: inherit; }
.chapter:hover, .chapter:focus-visible { background: var(--well); }
.chapter .t { color: var(--gold-2); font-variant-numeric: tabular-nums; min-width: 38px; }
.tour-ring { position: fixed; z-index: 70; border-radius: 14px; pointer-events: none; box-shadow: 0 0 0 2px var(--gold), 0 0 0 9999px rgba(10, 8, 7, .55); transition: all .3s cubic-bezier(.2, .7, .2, 1); }
.tour-tip { position: fixed; z-index: 71; background: var(--well); background-image: linear-gradient(180deg, var(--card-a), var(--card-b)); backdrop-filter: blur(14px); border: 1px solid var(--line-strong); border-radius: 14px; padding: 16px 18px; box-shadow: var(--shadow); color: var(--ink); transition: top .3s, left .3s; }
.tour-tip h3 { font: 500 20px/1.2 var(--serif); color: var(--gold-2); margin: 4px 0 6px; }
.tour-tip p { margin: 0; font-size: 14px; line-height: 1.5; }
.tour-count { font-size: 10px; letter-spacing: .2em; text-transform: uppercase; color: var(--faint); }
.welcome { position: fixed; z-index: 60; right: 24px; bottom: 96px; width: min(360px, calc(100vw - 32px)); background: var(--well); background-image: linear-gradient(180deg, var(--card-a), var(--card-b)); backdrop-filter: blur(14px); border: 1px solid var(--line-strong); border-radius: 16px; padding: 18px; box-shadow: var(--shadow); }
.welcome h3 { font: 500 22px/1.2 var(--serif); color: var(--gold-2); margin: 4px 0 6px; } .welcome p { margin: 0 0 12px; font-size: 14px; color: var(--muted); }
/* while the assistant is open, the welcome waits: it sat over the assistant's choice buttons (2026-11-07) */
body:has(.ai-drawer:not([hidden])) .welcome { display: none; }
.welcome .eyebrow { font-size: 10px; letter-spacing: .2em; text-transform: uppercase; color: var(--faint); }
@media (prefers-reduced-motion: reduce) { .tour-ring, .tour-tip { transition: none; } }

/* E-books: covers, the in-page reader */
.books .book { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 16px; align-items: start; }
.book-cover { aspect-ratio: 2 / 3; border-radius: 6px; overflow: hidden; background: var(--well); box-shadow: 0 10px 24px rgba(0, 0, 0, .35); }
.book-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.book-meta h3 { font: 500 20px/1.2 var(--serif); color: var(--gold-2); margin: 2px 0 0; text-transform: none; letter-spacing: 0; }
.book-meta .eyebrow { font-size: 10px; letter-spacing: .18em; text-transform: uppercase; color: var(--faint); }
.section-title { font: 500 22px var(--serif); color: var(--gold-2); margin: 28px 0 12px; }
.reader { position: fixed; inset: 0; z-index: 80; display: flex; flex-direction: column; background: rgba(10, 8, 7, .92); }
.reader-bar { display: flex; gap: 12px; align-items: baseline; padding: 12px 18px; border-bottom: 1px solid var(--line); }
.reader-body { flex: 1; min-height: 0; } .reader-body iframe { width: 100%; height: 100%; border: 0; background: #fff; }
@media (max-width: 760px) { .books .book { grid-template-columns: 90px minmax(0, 1fr); } }

/* the personal look: photo picks */
.thumb-pick { padding: 0; width: 56px; height: 56px; border-radius: 8px; overflow: hidden; border: 1px solid var(--line); background: none; }
.thumb-pick.on { box-shadow: 0 0 0 2px var(--gold); }
.thumb-pick .photo { width: 100%; height: 100%; object-fit: cover; aspect-ratio: auto; }

/* ------------------------------------------------------------ the front door (landing.js) */
.site { min-height: 100vh; background: var(--bg); color: var(--text); }
.site-bar { position: sticky; top: 0; z-index: 30; display: flex; justify-content: space-between; align-items: center; gap: 12px;
  padding: 12px max(16px, 4vw); background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.site-brand { display: flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font: 500 18px var(--serif); letter-spacing: .06em; }
.site-brand .mono { font: 600 20px var(--serif); color: var(--gold); border: 1px solid var(--line-strong); border-radius: 50%; width: 38px; height: 38px; display: grid; place-items: center; }
.site-menu-btn { background: transparent; color: var(--gold-2); border: 1px solid var(--line-strong); }
.site-menu { position: absolute; right: 0; top: calc(100% + 8px); min-width: 280px; background: var(--surface); border: 1px solid var(--line-strong); border-radius: 12px; box-shadow: var(--shadow); padding: 8px; display: grid; gap: 2px; }
.site-menu-head { font-size: 10px; letter-spacing: .18em; text-transform: uppercase; color: var(--faint); padding: 8px 10px 4px; }
.site-menu a { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 8px; color: var(--text); text-decoration: none; }
.site-menu a:hover, .site-menu a:focus-visible { background: var(--surface-2); }
.site-menu a:not(.open) span:first-child { color: var(--muted); }
.hero { background: radial-gradient(70% 60% at 50% 30%, #1a130c 0%, #000 70%); color: #f3e9dc; text-align: center; padding: 40px max(16px, 4vw) 0; display: grid; justify-items: center; gap: 14px; overflow: hidden; }
.hero-seal { width: min(260px, 60vw); height: auto; }
.hero h1 { font: 500 clamp(30px, 5vw, 54px)/1.05 var(--serif); letter-spacing: .08em; text-transform: uppercase; color: #e7c99a; margin: 0; text-wrap: balance; }
.hero-sub { max-width: 60ch; margin: 0; color: #cbbfae; }
.hero-cta { justify-content: center; gap: 10px; margin-top: 6px; }
.hero-cta .ghost { color: #e7c99a; border-color: rgba(231, 201, 154, .5); }
.hero-devices { width: min(1100px, 100%); height: auto; margin-top: 10px; display: block; }
.site-band { padding: 48px max(16px, 4vw); max-width: 1200px; margin: 0 auto; }
.site-band h2 { font: 500 clamp(26px, 3.4vw, 36px) var(--serif); color: var(--gold-2); margin: 0 0 6px; }
.svc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr)); gap: 14px; margin-top: 18px; }
.svc { border: 1px solid var(--line); border-radius: 14px; padding: 16px; background: var(--surface); display: grid; gap: 8px; align-content: start; }
.svc.open { border-color: var(--line-strong); background: linear-gradient(160deg, var(--surface-2), var(--surface)); }
.svc.focus { box-shadow: 0 0 0 2px var(--gold); }
.svc-top { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.svc h3 { font: 500 21px var(--serif); margin: 0; color: var(--text); text-transform: none; letter-spacing: 0; }
.svc:not(.open) h3 { color: var(--muted); }
.svc p { margin: 0; }
.feat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 14px; margin-top: 18px; }
.feat { border-top: 1px solid var(--line-strong); padding-top: 12px; }
.feat h3 { font: 500 19px var(--serif); color: var(--gold-2); margin: 0 0 4px; text-transform: none; letter-spacing: 0; }
.feat p { margin: 0; }
.site-foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; padding: 22px max(16px, 4vw); border-top: 1px solid var(--line); font-size: 13px; }

/* the client's guided intake (portal.js) */
.steps { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; padding: 0; margin: 0 0 14px; counter-reset: step; }
.steps li { counter-increment: step; font-size: 12px; padding: 5px 10px; border-radius: 999px; border: 1px solid var(--line); color: var(--faint); }
.steps li::before { content: counter(step) "  "; }
.steps li.done { color: var(--muted); border-color: var(--line-strong); }
.steps li.now { color: var(--on-accent); background: var(--rose); border-color: var(--rose); }
.guide-say { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 14px; }
.guide-say p { margin: 0; font: 500 19px/1.4 var(--serif); color: var(--text); max-width: 60ch; }
.guide-face { flex: none; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: var(--rose); color: var(--on-accent); }
.cap { max-width: 640px; }
.cap-frame { position: relative; aspect-ratio: 4 / 3; border-radius: 14px; overflow: hidden; background: var(--photo-bg); margin-bottom: 8px; }
.cap-frame video { width: 100%; height: 100%; object-fit: cover; transform: scaleX(-1); display: block; }
.cap-frame.off video { display: none; }
.cap-guide { position: absolute; inset: 0; width: 100%; height: 100%; fill: none; stroke: var(--gold-2); stroke-width: .5; vector-effect: non-scaling-stroke; pointer-events: none; }
.cap-guide path, .cap-guide ellipse, .cap-guide circle, .cap-guide line { stroke-width: 2px; }
.cap-guide .dash { stroke-dasharray: 6 5; opacity: .8; }
.cap-guide .mark { fill: var(--gold-2); }

.app[hidden], .site[hidden] { display: none; }
.site-menu[hidden] { display: none; }
.hero-seal, .hero-devices { mix-blend-mode: lighten; }
.svc .pill, .site-menu .pill { white-space: nowrap; }
/* the interactive reader */
.reader-split { display: grid; grid-template-columns: 260px minmax(0, 1fr); height: 100%; }
.reader-side { overflow: auto; border-right: 1px solid var(--line); padding: 10px; background: var(--surface); }
.reader-toc { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.reader-toc button.linklike { width: 100%; text-align: left; background: none; border: 0; color: var(--text); padding: 6px 8px; border-radius: 6px; font: 400 13px/1.35 var(--sans); cursor: pointer; }
.reader-toc li.on button.linklike { background: var(--nav-on-2); color: var(--gold-2); }
.reader-frame { width: 100%; height: 100%; border: 0; background: #fff; }
@media (max-width: 760px) { .reader-split { grid-template-columns: 1fr; } .reader-side { display: none; } }

/* ---- the learning workspaces: interactive video lessons, assignments, grading ---- */
.lesson { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 16px; align-items: start; }
@media (max-width: 980px) { .lesson { grid-template-columns: 1fr; } }
.lesson-stage { position: relative; }
.lesson-stage .film { position: relative; border-radius: 14px; overflow: hidden; background: #000; }
.lesson-stage video { width: 100%; display: block; }
.lesson-marks { position: relative; height: 8px; margin: 6px 12px 0; border-radius: 4px; background: var(--line, rgba(255,255,255,.12)); }
.lesson-mark { position: absolute; top: -2px; width: 12px; height: 12px; margin-left: -6px; border-radius: 50%; background: var(--gold, #cfae78); box-shadow: 0 0 0 2px var(--bg, #241812); }
.lesson-side { background: var(--card, rgba(255,255,255,.04)); border: 1px solid var(--line, rgba(255,255,255,.12)); border-radius: 14px; padding: 14px; max-height: 70vh; overflow: auto; }
.lesson-cues { list-style: none; margin: 6px 0 0; padding: 0; font-size: 13px; }
.lesson-cues li { padding: 5px 0; border-bottom: 1px dashed var(--line, rgba(255,255,255,.1)); }
.lesson-cues li.ok a { color: var(--ok, #8fbf8f); } .lesson-cues li.miss a { color: var(--warn, #e0a96d); }
.lesson-cues .t { font-variant-numeric: tabular-nums; opacity: .7; margin-right: 4px; }
.lesson-ask { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(10, 6, 4, .72); backdrop-filter: blur(3px); padding: 16px; }
.lesson-ask[hidden] { display: none; }
.lesson-ask-card { width: min(640px, 100%); max-height: 100%; overflow: auto; background: var(--panel, #2e221c); border: 1px solid var(--gold, #cfae78); border-radius: 16px; padding: 18px 20px; box-shadow: 0 20px 60px rgba(0,0,0,.5); }
.lesson-ask-card h3 { margin: 6px 0 10px; }
.lesson-ask-card textarea { width: 100%; margin: 6px 0; }
.lesson-ask-pic { width: 100%; max-height: 220px; object-fit: cover; border-radius: 10px; margin-bottom: 10px; }
.lesson-opts { display: grid; gap: 6px; margin: 6px 0; }
.lesson-opts button { text-align: left; } .lesson-opts button.right { border-color: var(--ok, #8fbf8f); background: rgba(143,191,143,.15); }
.lesson-opts button.wrong { border-color: var(--warn, #e0a96d); background: rgba(224,169,109,.12); }
.lesson-model { margin: 8px 0; padding: 10px; border-left: 3px solid var(--gold, #cfae78); background: rgba(255,255,255,.04); }
.lesson-go { margin-top: 10px; }
.lesson-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; margin-bottom: 18px; }
.lesson-tile { display: block; text-decoration: none; color: inherit; border: 1px solid var(--line, rgba(255,255,255,.12)); border-radius: 14px; overflow: hidden; background: var(--card, rgba(255,255,255,.03)); transition: transform .15s; }
.lesson-tile:hover { transform: translateY(-2px); border-color: var(--gold, #cfae78); }
.lesson-tile img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; display: block; background: #1b120e; }
.lesson-tile-meta { padding: 10px 12px; }
.qa { display: block; margin: 10px 0; } .qa textarea { width: 100%; margin-top: 4px; }
.lab-photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 10px; }
.lab-photos img { width: 100%; border-radius: 10px; display: block; }
.rubric-self li { align-items: flex-start; }
.grade-total { margin: 10px 0; font-size: 18px; }
.kpi-big { font-size: 34px; font-family: var(--display, Georgia); }
.catalog { max-height: 60vh; overflow: auto; }
.work .card { margin-bottom: 14px; }

/* ---------------------------------------------------------------- play buttons on every video (2026-11-08) */
.play-big { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); z-index: 3; width: 84px; height: 84px; padding: 0;
  border-radius: 50%; border: 2px solid var(--gold); background: rgba(14, 12, 12, .62); color: var(--gold-2); font-size: 32px; line-height: 1;
  display: grid; place-items: center; cursor: pointer; box-shadow: 0 10px 30px rgba(0, 0, 0, .35); transition: transform .15s, background .15s; }
.play-big span { margin-left: 6px; }
.play-big:hover, .play-big:focus-visible { transform: translate(-50%, -50%) scale(1.07); background: rgba(14, 12, 12, .78); }
.play-big[hidden] { display: none; }
.tile-pic { position: relative; }
.tile-pic img { display: block; width: 100%; }
.tile-play { position: absolute; right: 12px; bottom: 12px; width: 52px; height: 52px; border-radius: 50%;
  display: grid; place-items: center; padding-left: 4px; font-size: 22px; color: var(--gold-2); background: rgba(14, 12, 12, .62);
  border: 2px solid var(--gold); box-shadow: 0 8px 22px rgba(0, 0, 0, .35); transition: transform .15s; }
.lesson-tile:hover .tile-play { transform: scale(1.1); }
.check-row { display: flex; align-items: flex-start; gap: 8px; text-align: left; justify-content: flex-start; cursor: pointer; }
.check-row input { margin-top: 3px; flex: none; }
.button-list { display: grid; gap: 8px; }
.button-list .btn { text-align: center; }

/* ------------------------------------------------------------------------------------- the academy portal */
.meter { height: 8px; background: var(--well); border-radius: 99px; overflow: hidden; min-width: 80px; margin-top: 4px; }
.meter > i { display: block; height: 100%; background: linear-gradient(90deg, var(--rose), var(--gold)); }
.field { display: grid; gap: 4px; }
.warn-dot { color: var(--warn, #c9963a); font-size: 10px; }
.module-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; margin-top: 8px; }
.module-tile { display: grid; gap: 6px; padding: 16px; border-radius: 14px; border: 1px solid var(--line); background: var(--tile); color: inherit; text-decoration: none; transition: transform .15s, border-color .15s; }
.module-tile:hover { transform: translateY(-2px); border-color: var(--line-strong); }
.module-tile b { font: 500 19px/1.25 var(--serif); color: var(--gold-2); }
.plan-present { background: var(--well); border: 1px solid var(--line); border-radius: 16px; padding: 28px 32px; min-height: 280px; }
.plan-present:fullscreen { display: grid; align-content: center; padding: 6vh 8vw; background: var(--bg); }
.plan-present:fullscreen .plan-big { font-size: 34px; }
.plan-stage .eyebrow { margin-bottom: 14px; }
.plan-big { font: 400 22px/1.55 var(--serif); color: var(--text); margin: 0; }
ol.plan-big { padding-left: 1.4em; display: grid; gap: 8px; }
.plan-dots { display: flex; gap: 6px; align-items: center; }
.plan-dots .dot { width: 10px; height: 10px; padding: 0; border-radius: 50%; border: 1px solid var(--gold); background: transparent; }
.plan-dots .dot.on { background: var(--gold); }
.plan-q { display: grid; gap: 6px; padding: 10px 0; border-bottom: 1px solid var(--hair); justify-items: start; }
.plan-answer { padding: 10px 14px; border-left: 3px solid var(--gold); background: var(--tile); border-radius: 0 10px 10px 0; }
.plan-block { margin: 10px 0; padding: 12px 16px; border-radius: 12px; background: var(--tile); border: 1px solid var(--hair); }
.plan-block.ca { border-left: 3px solid var(--gold); }
.exam-list { display: grid; gap: 14px; padding-left: 1.4em; }
.exam-list li { display: grid; gap: 6px; }
details.case { border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; background: var(--tile); }
details.case summary { display: flex; gap: 8px; align-items: center; cursor: pointer; list-style: none; }
details.case[open] summary { margin-bottom: 8px; }
details summary { cursor: pointer; padding: 6px 0; color: var(--gold-2); }
.kv { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.kv li { display: flex; gap: 12px; }
.kv li span:first-child { min-width: 70px; color: var(--muted); }
/* a checkbox or radio is its own size, never the full width every other field takes */
input[type=checkbox], input[type=radio] { width: auto; flex: none; padding: 0; }

/* A clean 3D view: nothing over the eye but the step's caption; the tools sit in a row beneath the picture */
.vis-studio.clean .spec, .vis-studio.clean .scale { display: none; }
.vis-studio.clean .hud .act { left: 50%; bottom: 16px; transform: translate(-50%, 6px); max-width: 80%; text-align: center; }
.vis-studio.clean .hud .act.on { transform: translate(-50%, 0); }
.vis-controls-row .vis-controls { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: center; margin-top: 10px; }
.vis-controls-row .seg { display: inline-flex; border: 1px solid var(--line); border-radius: 7px; overflow: hidden; background: var(--surface-2); }
.vis-controls-row .tool { background: transparent; border: 0; border-radius: 0; color: var(--muted, #a59f98); font: 600 11px var(--sans); letter-spacing: .06em; padding: 7px 11px; box-shadow: none; width: auto; }
.vis-controls-row .tool + .tool { border-left: 1px solid var(--line); }
.vis-controls-row .tool:hover { color: var(--text, #eee); filter: none; }
.vis-controls-row .tool.on { color: var(--text, #eee); background: color-mix(in srgb, var(--gold) 26%, transparent); }
.vis-controls-row .tool.idle { opacity: .45; }
.vis-controls-row select.tool { border: 1px solid var(--line); border-radius: 7px; background: transparent; padding: 6px 8px; }
.vis-controls-row .tones { padding: 3px 5px; gap: 5px; align-items: center; }
.vis-controls-row .tone { width: 20px; height: 20px; padding: 0; border-radius: 50%; background: var(--sw); border: 1px solid rgba(0, 0, 0, .35); box-shadow: none; }
.vis-controls-row .tone.on { outline: 2px solid var(--gold); outline-offset: 1px; }

/* The step player: one step at a time, large, with its transport and sound */
.step-player .transport { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px; margin: 14px 0 4px; }
.step-player .transport button { min-width: 120px; }
.step-player .transport .play-main { min-width: 190px; font-size: 15px; padding: 11px 22px; }
.step-player .step-head { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.step-player .step-head .n { font: 600 11px var(--sans); letter-spacing: .2em; text-transform: uppercase; color: var(--gold); }
.step-player .step-head h2 { margin: 0; font-size: 26px; }
.step-player .shows { font-size: 15px; line-height: 1.55; margin: 10px 0 0; text-align: center; }
.step-strip { display: flex; gap: 4px; flex-wrap: wrap; }
.step-strip a { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; border: 1px solid var(--line); font: 600 11px var(--sans); color: var(--muted, #a59f98); text-decoration: none; }
.step-strip a.done { border-color: color-mix(in srgb, var(--ok, #7fb38a) 60%, transparent); color: var(--ok, #7fb38a); }
.step-strip a.now { border-color: var(--gold); color: var(--gold); }
.step-strip a.viewing { background: var(--gold); color: #1a1715; border-color: var(--gold); }
.steps-nav li a { color: inherit; text-decoration: none; display: flex; gap: 10px; width: 100%; }
.steps-nav li.viewing { background: color-mix(in srgb, var(--gold) 14%, transparent); border-radius: 6px; }

/* Lesson tiles: the lesson's own number and subject, on its book's colour, over a faded frame from the lesson */
.lesson-tile .tile-pic { position: relative; }
.lesson-tile .tile-pic img { filter: saturate(.55) brightness(.42) blur(1.5px); transform: scale(1.04); }
.lesson-tile .tile-pic::after { content: ''; position: absolute; inset: 0; background: linear-gradient(135deg, var(--tone) 0%, color-mix(in srgb, var(--tone) 35%, transparent) 55%, transparent 100%); opacity: .82; pointer-events: none; }
.lesson-tile .tile-face { position: absolute; inset: 0; z-index: 1; display: flex; flex-direction: column; justify-content: flex-end; padding: 12px 14px; gap: 2px; color: #fff; text-shadow: 0 1px 6px rgba(0,0,0,.45); pointer-events: none; }
.lesson-tile .tile-kind { font: 600 10px var(--sans); letter-spacing: .2em; text-transform: uppercase; opacity: .9; }
.lesson-tile .tile-num { font: 400 46px/1 var(--serif, Georgia, serif); }
.lesson-tile .tile-title { font: 500 15px/1.25 var(--serif, Georgia, serif); max-width: 78%; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.lesson-tile .tile-play { z-index: 2; }
.lesson-tile.tone-rose { --tone: #8a4a55; } .lesson-tile.tone-sage { --tone: #4f6b5a; } .lesson-tile.tone-copper { --tone: #8a5a36; }
.lesson-tile.tone-plum { --tone: #5e3f63; } .lesson-tile.tone-navy { --tone: #34496b; } .lesson-tile.tone-gold { --tone: #8a7135; }

/* The reader's bar: one row of compact controls on a solid ground (the page behind never shows through) */
.reader { background: var(--bg); }
.reader-bar { align-items: center; flex-wrap: wrap; background: var(--bg-2); }
.reader-bar select, .reader-bar button { width: auto; flex: none; }
.reader-bar select { padding: 5px 8px; font-size: 12px; }

/* Terms and the guardian step at sign-up; the account screen */
.terms-box { max-height: 220px; overflow: auto; border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; margin: 8px 0; background: var(--surface-2); font-size: 12.5px; line-height: 1.5; text-align: left; }
.terms-box h4 { margin: 8px 0 4px; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--gold); }
.terms-box h4:first-child { margin-top: 0; }
.terms-box p { margin: 0 0 6px; }
.terms .check-row, .guardian .check-row { text-align: left; font-size: 13px; }
.guardian { display: grid; gap: 6px; margin: 6px 0; padding: 8px; border: 1px dashed var(--line); border-radius: 8px; }
.guardian[hidden] { display: none; }
