
/* ───────────────────────── Tokens ───────────────────────── */
:root {
  --menubar-h: 28px;
  --font: "Schibsted Grotesk", "IBM Plex Sans Arabic", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --serif: "Hubot Sans", "IBM Plex Sans Arabic", "Schibsted Grotesk", system-ui, sans-serif; /* display */
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-drawer: cubic-bezier(0.32, 0.72, 0, 1);

  /* LIGHT: airy studio */
  --accent: #6f4ff0;
  --on-accent: #fff;
  --ink: #141312;
  --ink-2: rgba(20, 19, 18, 0.68);
  --ink-3: rgba(20, 19, 18, 0.5);
  --chrome: rgba(255, 255, 255, 0.62);
  --menu-bg: rgba(255, 255, 255, 0.86);
  --menu-hi: rgba(20, 19, 18, 0.08);
  --hairline: rgba(20, 19, 18, 0.1);
  --win-bg: #ffffff;
  --win-side: rgba(247, 246, 243, 0.9);
  --win-line: rgba(20, 19, 18, 0.07);
  --win-shadow: 0 0 0 1px rgba(20, 19, 18, 0.06), 0 34px 80px -26px rgba(70, 50, 110, 0.32), 0 12px 28px -14px rgba(40, 28, 16, 0.18);
  --win-shadow-idle: 0 0 0 1px rgba(20, 19, 18, 0.06), 0 18px 44px -20px rgba(70, 50, 110, 0.22);
  --field: rgba(20, 19, 18, 0.05);
  --hover: rgba(20, 19, 18, 0.045);
  --sel-row: rgba(20, 19, 18, 0.07);
  --widget-bg: rgba(255, 255, 255, 0.6);
  --glass-edge: rgba(255, 255, 255, 0.85);
  --scroll: rgba(20, 19, 18, 0.2);
  --ok: #1f9d5a;
  --card-shadow: 0 1px 1px rgba(30, 20, 10, 0.06), 0 8px 18px -10px rgba(40, 28, 16, 0.32), 0 18px 34px -22px rgba(70, 50, 110, 0.32);
  --folder-sat: 1;
  --ctl-bg: rgba(20, 19, 18, 0.055);
  --ctl-bg-hover: rgba(20, 19, 18, 0.1);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { 
  /* DARK: minimal gallery */
  --accent: #f3eee6;
  --on-accent: #0b0b0b;
  --ink: #f3eee6;
  --ink-2: rgba(243, 238, 230, 0.72);
  --ink-3: rgba(243, 238, 230, 0.52);
  --chrome: rgba(9, 9, 9, 0.72);
  --menu-bg: rgba(22, 22, 22, 0.96);
  --menu-hi: rgba(243, 238, 230, 0.1);
  --hairline: rgba(243, 238, 230, 0.1);
  --win-bg: #111111;
  --win-side: #0c0c0c;
  --win-line: rgba(243, 238, 230, 0.07);
  --win-shadow: 0 0 0 1px rgba(243, 238, 230, 0.09), inset 0 1px 0 rgba(255, 255, 255, 0.05), 0 40px 90px -30px rgba(0, 0, 0, 0.95);
  --win-shadow-idle: 0 0 0 1px rgba(243, 238, 230, 0.06), 0 24px 60px -30px rgba(0, 0, 0, 0.9);
  --field: rgba(243, 238, 230, 0.07);
  --hover: rgba(243, 238, 230, 0.05);
  --sel-row: rgba(243, 238, 230, 0.08);
  --widget-bg: rgba(17, 17, 17, 0.82);
  --glass-edge: rgba(243, 238, 230, 0.08);
  --scroll: rgba(243, 238, 230, 0.2);
  --ok: #4fd08a;
  --card-shadow: 0 0 0 1px rgba(255, 255, 255, 0.06), 0 14px 30px -16px rgba(0, 0, 0, 0.95);
  --folder-sat: 0.8;
  --ctl-bg: rgba(243, 238, 230, 0.07);
  --ctl-bg-hover: rgba(243, 238, 230, 0.13);
  color-scheme: dark;
 } }
:root[data-theme="dark"] { 
  /* DARK: minimal gallery */
  --accent: #f3eee6;
  --on-accent: #0b0b0b;
  --ink: #f3eee6;
  --ink-2: rgba(243, 238, 230, 0.72);
  --ink-3: rgba(243, 238, 230, 0.52);
  --chrome: rgba(9, 9, 9, 0.72);
  --menu-bg: rgba(22, 22, 22, 0.96);
  --menu-hi: rgba(243, 238, 230, 0.1);
  --hairline: rgba(243, 238, 230, 0.1);
  --win-bg: #111111;
  --win-side: #0c0c0c;
  --win-line: rgba(243, 238, 230, 0.07);
  --win-shadow: 0 0 0 1px rgba(243, 238, 230, 0.09), inset 0 1px 0 rgba(255, 255, 255, 0.05), 0 40px 90px -30px rgba(0, 0, 0, 0.95);
  --win-shadow-idle: 0 0 0 1px rgba(243, 238, 230, 0.06), 0 24px 60px -30px rgba(0, 0, 0, 0.9);
  --field: rgba(243, 238, 230, 0.07);
  --hover: rgba(243, 238, 230, 0.05);
  --sel-row: rgba(243, 238, 230, 0.08);
  --widget-bg: rgba(17, 17, 17, 0.82);
  --glass-edge: rgba(243, 238, 230, 0.08);
  --scroll: rgba(243, 238, 230, 0.2);
  --ok: #4fd08a;
  --card-shadow: 0 0 0 1px rgba(255, 255, 255, 0.06), 0 14px 30px -16px rgba(0, 0, 0, 0.95);
  --folder-sat: 0.8;
  --ctl-bg: rgba(243, 238, 230, 0.07);
  --ctl-bg-hover: rgba(243, 238, 230, 0.13);
  color-scheme: dark;
 }

/* Label colour follows the wallpaper */
body[data-wall="wash"], body[data-wall="fold"], body[data-wall="mat"], body[data-wall="swatches"], body[data-wall="notes"] { --label: #141312; --label-shadow: 0 1px 1px rgba(255, 255, 255, 0.6); --sel-art: rgba(20, 19, 18, 0.08); }
body[data-wall="arc"], body[data-wall="graphite"], body[data-wall="dots"], body[data-wall="files"] { --label: #f3eee6; --label-shadow: 0 1px 2px rgba(0, 0, 0, 0.8); --sel-art: rgba(243, 238, 230, 0.1); }

/* ───────────────────────── Base ───────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  overflow: hidden;
  background: #fbfaf7;
  color: var(--ink);
  font: 13px/1.4 var(--font);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  transition: color 300ms ease;
}
:root[data-theme="dark"] body { background: #070707; }
button, input { font: inherit; color: inherit; }
button { cursor: default; }
a { color: var(--accent); text-underline-offset: 3px; }
::selection { background: color-mix(in oklch, var(--accent) 32%, transparent); }
input { caret-color: var(--accent); }
:focus { outline: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
* { scrollbar-width: thin; scrollbar-color: var(--scroll) transparent; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: var(--scroll); border-radius: 10px; border: 3px solid transparent; background-clip: content-box; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
svg.defs { position: absolute; width: 0; height: 0; }

/* ───────────────────────── Wallpaper ───────────────────────── */
.walls { position: fixed; inset: 0; z-index: 0; }
.wall { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; visibility: hidden; transition: opacity 800ms ease, visibility 0s linear 800ms; }
.wall.is-on { opacity: 1; visibility: visible; transition: opacity 800ms ease; }
/* Light · Cutting mat: a designer's desk surface */
.wall-mat {
  background:
    linear-gradient(rgba(255, 255, 255, 0.55) 1px, transparent 1px) 0 0 / 120px 120px,
    linear-gradient(90deg, rgba(255, 255, 255, 0.55) 1px, transparent 1px) 0 0 / 120px 120px,
    linear-gradient(rgba(255, 255, 255, 0.28) 1px, transparent 1px) 0 0 / 24px 24px,
    linear-gradient(90deg, rgba(255, 255, 255, 0.28) 1px, transparent 1px) 0 0 / 24px 24px,
    repeating-linear-gradient(45deg, transparent 0 239px, rgba(255, 255, 255, 0.22) 239px 240px),
    #b9ccbb;
}
/* Light · Swatches: a fan deck of colours from the work */
.wall-swatches { background: radial-gradient(40vw 34vw at 58% 70%, rgba(255, 214, 186, 0.28), transparent 70%), #fbfaf7; }
.fan { position: absolute; left: 50%; bottom: 14vh; width: 0; height: 0; }
.fan span {
  position: absolute; left: -34px; bottom: 0; width: 68px; height: 260px; border-radius: 6px; transform-origin: 50% 94%; rotate: var(--r);
  background: linear-gradient(var(--c) 0 58%, #fffdf9 58%); box-shadow: 0 0 0 0.5px rgba(0, 0, 0, 0.08), 0 10px 22px -12px rgba(40, 28, 16, 0.4);
  display: flex; flex-direction: column; justify-content: flex-end; padding: 0 7px 30px; font-family: var(--font); color: #141312;
}
.fan span b { font-size: 7.5px; font-weight: 700; line-height: 1.15; }
.fan span i { font-style: normal; font-size: 7px; color: rgba(20, 19, 18, 0.5); margin-top: 3px; }
/* The rivet sits on the pivot every card turns around: 6% up from the card's foot (260px × 0.06 = 15.6px) */
.fan::after {
  content: ""; position: absolute; left: 0; bottom: 15.6px; width: 14px; height: 14px; translate: -50% 50%; border-radius: 50%; z-index: 1;
  background: radial-gradient(circle at 38% 34%, #ffffff 0 18%, #dcd7cf 46%, #b3ada3 100%);
  box-shadow: 0 1px 1.5px rgba(40, 28, 16, 0.35), inset 0 0 0 0.5px rgba(0, 0, 0, 0.18);
}
/* Light · Notes: feedback every designer has heard */
.wall-notes { background: radial-gradient(rgba(20, 19, 18, 0.07) 1px, transparent 1.3px) 0 0 / 22px 22px, #fbfaf7; }
.note {
  position: absolute; left: max(var(--x), 440px); top: var(--y); width: 150px; min-height: 140px; padding: 26px 16px 14px; rotate: var(--r);
  background: var(--c); color: #2b2a28; font: 600 22px/1.05 "Caveat", "Bradley Hand", cursive;
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.06), 0 12px 22px -14px rgba(40, 28, 16, 0.45);
}
.note::before { content: ""; position: absolute; top: -9px; left: 50%; width: 58px; height: 20px; translate: -50% 0; rotate: -2deg; background: rgba(255, 255, 255, 0.55); box-shadow: 0 0 0 0.5px rgba(0, 0, 0, 0.05); }
/* Dark · Dots: a quiet dot grid */
.wall-dots { background: radial-gradient(70vw 60vw at 55% 45%, transparent, rgba(0, 0, 0, 0.6)), radial-gradient(rgba(243, 238, 230, 0.13) 1px, transparent 1.4px) 0 0 / 24px 24px, #080808; }
/* Dark · Files: every designer's folder at 2am */
.wall-files { background: radial-gradient(50vw 40vw at 55% 50%, rgba(143, 115, 255, 0.07), transparent 70%), #080808; }
.ghost-files { position: absolute; left: 38%; top: 20%; margin: 0; padding: 0; list-style: none; display: grid; gap: 14px; }
.ghost-files li { display: flex; align-items: center; gap: 10px; font: 500 13px var(--font); color: rgba(243, 238, 230, 0.2); white-space: nowrap; }
.ghost-files li:nth-child(n) { translate: calc(var(--i, 0) * 1px) 0; }
.ghost-files li::before { content: ""; width: 16px; height: 20px; border-radius: 2px 6px 2px 2px; background: rgba(243, 238, 230, 0.12); box-shadow: inset 0 0 0 1px rgba(243, 238, 230, 0.12); }
.ghost-files li:nth-child(7) { color: rgba(243, 238, 230, 0.34); }

/* Each wallpaper answers the mouse in its own way (vars set by wallFx) */
.wall-fx { position: absolute; inset: 0; z-index: 1; width: 100%; height: 100%; pointer-events: none; }
body:not([data-wall="notes"]):not([data-wall="wash"]) .wall-glow { display: none; }
.note { translate: calc(var(--px, 0) * 1px) calc(var(--py, 0) * 1px + var(--lift, 0) * -9px); scale: calc(1 + var(--lift, 0) * 0.04); }
.wall-notes .note { rotate: calc(var(--r) * (1 - var(--lift, 0) * 0.7)); box-shadow: 0 1px 1px rgba(0, 0, 0, 0.06), 0 calc(12px + var(--lift, 0) * 18px) calc(22px + var(--lift, 0) * 20px) -14px rgba(40, 28, 16, 0.45); }
.wall-swatches .fan span { rotate: calc(var(--r) * (1 + var(--spread, 0) * 0.16)); transform: scaleY(calc(1 + var(--lift, 0) * 0.1)); transform-origin: 50% 94%; }
.wall-fold svg { will-change: transform; transform: perspective(1600px) rotateY(calc(var(--dx, 0) * 8deg)) rotateX(calc(var(--dy, 0) * -5deg)); transform-origin: 40% 50%; }
.mat-cross { position: absolute; inset: 0; opacity: var(--e, 0); pointer-events: none; }
.mat-cross i, .mat-tag { position: absolute; left: 0; top: 0; transition: translate 90ms cubic-bezier(0.2, 0.8, 0.2, 1); }
.mat-cross .mx { width: 100%; height: 1px; background: rgba(255, 86, 48, 0.8); translate: 0 var(--gy, -10px); box-shadow: 0 0 0 0.5px rgba(40, 70, 48, 0.15); }
.mat-cross .my { width: 1px; height: 100%; background: rgba(255, 86, 48, 0.8); translate: var(--gx, -10px) 0; box-shadow: 0 0 0 0.5px rgba(40, 70, 48, 0.15); }
.mat-tag { translate: calc(var(--gx, -99px) + 10px) calc(var(--gy, -99px) + 10px); padding: 3px 7px; border-radius: 5px; background: #ff5630; color: #fff; font: 600 11px var(--font); letter-spacing: 0.02em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.ghost-files.lit { mask-image: radial-gradient(170px 170px at var(--lx, -999px) var(--ly, -999px), #000 25%, transparent 100%); -webkit-mask-image: radial-gradient(170px 170px at var(--lx, -999px) var(--ly, -999px), #000 25%, transparent 100%); opacity: var(--e, 0); }
.ghost-files.lit li { color: rgba(243, 238, 230, 0.92); }
.ghost-files.lit li::before { background: rgba(143, 115, 255, 0.45); box-shadow: inset 0 0 0 1px rgba(190, 172, 255, 0.6); }
.ghost-files li.secret { color: transparent; }
.ghost-files li.secret::before { opacity: 0; }
.ghost-files.lit li.secret { color: #ffb38a; }
.ghost-files.lit li.secret::before { opacity: 1; background: rgba(255, 179, 138, 0.35); }

/* Objects on the wallpaper sit above the glow; the glow tints the surface beneath them */
.note, .fan, .ghost-files { z-index: 2; }

/* Pointer glow: colour gathers where the mouse moves, then settles away */
.wall-glow {
  position: absolute; left: 0; top: 0; z-index: 1; width: 64vmax; height: 64vmax; border-radius: 50%;
  pointer-events: none; opacity: 0; will-change: transform, opacity;
  background: radial-gradient(closest-side, rgba(186, 164, 255, 0.48), rgba(168, 202, 255, 0.33) 40%, rgba(255, 200, 168, 0.2) 66%, rgba(255, 200, 168, 0) 100%);
}
:root[data-theme="dark"] .wall-glow {
  background: radial-gradient(closest-side, rgba(255, 184, 140, 0.18), rgba(214, 196, 255, 0.09) 55%, rgba(214, 196, 255, 0) 100%);
}
@media (prefers-reduced-motion: reduce) { .wall-glow { display: none; } }
/* Light · Wash: mostly white, one off-centre diffused wash of lilac, pale blue and apricot */
.wall-wash {
  background:
    #fbfaf7;
}
.wb { position: absolute; inset: 0; will-change: transform; }
.wb1 { background: radial-gradient(34vw 30vw at 62% 26%, rgba(210, 196, 255, 0.5), rgba(210, 196, 255, 0) 70%); transform: translate3d(calc(var(--dx, 0) * 14vw), calc(var(--dy, 0) * 12vh), 0); }
.wb2 { background: radial-gradient(30vw 26vw at 74% 62%, rgba(190, 216, 255, 0.5), rgba(190, 216, 255, 0) 70%); transform: translate3d(calc(var(--dx, 0) * 9vw), calc(var(--dy, 0) * 8vh), 0); }
.wb3 { background: radial-gradient(26vw 24vw at 50% 86%, rgba(255, 214, 186, 0.5), rgba(255, 214, 186, 0) 72%); transform: translate3d(calc(var(--dx, 0) * 5vw), calc(var(--dy, 0) * 5vh), 0); }
/* Light · Fold: an oversized translucent folded sheet near the edge */
.wall-fold { background: radial-gradient(40vw 40vw at 50% 50%, rgba(214, 206, 255, 0.22), transparent 70%), #fbfaf7; }
.wall-fold svg { position: absolute; left: 30vw; top: -8vh; height: 120vh; width: auto; }
/* Dark · Arc: near-black, one barely visible curved form revealed by soft light */
.wall-arc { background: radial-gradient(60vw 50vw at 60% 110%, rgba(130, 110, 90, 0.12), transparent 70%), #070707; }
.wall-arc svg { position: absolute; left: 12vw; bottom: -62vw; width: 110vw; height: 110vw; }
/* Dark · Graphite: faint texture, restrained tonal gradient */
.wall-graphite {
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .05 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"),
    linear-gradient(160deg, #171717 0%, #0b0b0b 55%, #050505 100%);
}

/* ───────────────────────── Menu bar ───────────────────────── */
.menubar {
  position: fixed; inset: 0 0 auto 0; height: var(--menubar-h); z-index: 1000;
  display: flex; align-items: center; gap: 2px; padding: 0 8px;
  background: var(--chrome);
  -webkit-backdrop-filter: blur(30px) saturate(180%);
  backdrop-filter: blur(30px) saturate(180%);
  box-shadow: 0 0.5px 0 var(--hairline);
  font-size: 13px; letter-spacing: 0.005em;
  user-select: none;
}
.mb-item {
  height: 22px; padding: 0 9px; border: 0; border-radius: 5px; background: transparent;
  display: inline-flex; align-items: center; gap: 6px; white-space: nowrap;
}
.mb-item[aria-expanded="true"], .mb-item:active { background: var(--menu-hi); }
.mb-item.is-app { font-weight: 700; }
.mb-mono { font-family: var(--serif); font-stretch: 110%; font-size: 17px; font-weight: 800; letter-spacing: -0.02em; line-height: 1; padding: 0 10px 1px; }
.mb-spacer { flex: 1; }
.mb-status { display: inline-flex; align-items: center; gap: 6px; padding: 0 8px; color: var(--ink-2); }
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 2px color-mix(in oklch, var(--ok) 25%, transparent); }
.mb-clock { font-variant-numeric: tabular-nums; padding: 0 8px; white-space: nowrap; }
.mb-icon svg { width: 15px; height: 15px; }

/* ───────────────────────── Menus ───────────────────────── */
.menu {
  position: fixed; z-index: 1200; min-width: 230px; padding: 5px;
  background: var(--menu-bg);
  -webkit-backdrop-filter: blur(40px) saturate(180%);
  backdrop-filter: blur(40px) saturate(180%);
  border-radius: 10px;
  box-shadow: 0 0 0 0.5px var(--hairline), 0 12px 32px -8px rgba(0, 0, 0, 0.3), inset 0 0.5px 0 var(--glass-edge);
  font-size: 13px;
}
.menu-item {
  width: 100%; height: 24px; padding: 0 10px; border: 0; border-radius: 5px; background: transparent;
  display: flex; align-items: center; gap: 8px; text-align: left; white-space: nowrap;
}
.menu-item:hover, .menu-item:focus-visible { background: var(--accent); color: var(--on-accent); outline: none; }
.menu-item:hover .mi-key, .menu-item:focus-visible .mi-key { color: rgba(255, 255, 255, 0.8); }
.menu-item[disabled] { opacity: 0.4; pointer-events: none; }
.mi-label { flex: 1; }
.mi-key { color: var(--ink-3); font-variant-numeric: tabular-nums; }
.mi-icon { width: 18px; height: 16px; display: grid; place-items: center; }
.mi-icon svg { width: 18px; height: 15px; }
.menu-sep { height: 1px; margin: 5px 10px; background: var(--hairline); }

/* ───────────────────────── Desktop ───────────────────────── */
.desktop { position: fixed; inset: 0; z-index: 1; }
.widgets {
  position: absolute; top: calc(var(--menubar-h) + 20px); left: 24px;
  width: 384px; display: grid; grid-template-columns: 1fr 1fr; gap: 14px;
}
.widget {
  position: relative;
  background: var(--widget-bg);
  -webkit-backdrop-filter: blur(26px) saturate(170%);
  backdrop-filter: blur(26px) saturate(170%);
  border-radius: 26px;
  box-shadow: inset 0 0 0 0.5px var(--glass-edge), 0 1px 1px rgba(0, 0, 0, 0.04), 0 18px 40px -22px rgba(60, 40, 90, 0.35);
  color: var(--ink);
}
/* Intro: a designer's card */
.w-intro { grid-column: 1 / -1; padding: 24px 24px 18px; }
.stamp { position: absolute; top: 18px; right: 18px; width: 78px; height: 78px; }
.stamp-disc { fill: #8f73ff; }
:root[data-theme="dark"] .stamp-disc { fill: #7d62f0; }
.stamp-text { font: 700 9.4px var(--font); letter-spacing: 0.02em; fill: #fff7ef; }
.stamp-star { fill: #fff7ef; }
.stamp-spin { transform-origin: 60px 60px; }
@media (hover: hover) and (pointer: fine) { .w-intro:hover .stamp-spin { animation: stampSpin 14s linear infinite; } }
@keyframes stampSpin { to { transform: rotate(360deg); } }
.w-name { position: relative; margin: 6px 0 0; font: 800 clamp(42px, 5.8vh, 65px)/0.92 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; }
.w-name em { display: block; margin-top: 4px; font-style: normal; font-weight: 300; letter-spacing: 0; }
.w-role { margin: 18px 0 0; font-size: 15px; font-weight: 700; letter-spacing: 0.005em; }
.w-copy { margin: 6px 0 0; font-size: 13.5px; line-height: 1.5; color: var(--ink-2); max-width: 34ch; text-wrap: pretty; }
.w-palette { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 18px; }
.pal {
  position: relative; width: 30px; height: 22px; padding: 0; border: 0; border-radius: 5px 5px 6px 6px; cursor: pointer;
  background: linear-gradient(165deg, color-mix(in oklch, var(--c1), white 22%), var(--c1));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.55), 0 3px 6px -3px rgba(0, 0, 0, 0.35);
  filter: saturate(var(--folder-sat)); transition: translate 220ms var(--ease-out);
}
.pal::before { content: ""; position: absolute; left: 0; top: -4px; width: 44%; height: 6px; border-radius: 3px 4px 0 0; background: var(--c2); z-index: -1; }
@media (hover: hover) and (pointer: fine) { .pal:hover { translate: 0 -3px; } }
.pal:active { scale: 0.94; }
.w-hint { margin: 0; font-size: 12px; color: var(--ink-3); display: flex; align-items: center; gap: 6px; }
.w-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 16px; padding-top: 14px; border-top: 1px dashed var(--hairline); }
.w-status { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; }
.w-hello { height: 34px; padding: 0 15px; border-radius: 99px; font-weight: 700; }
.w-hello span, .w-note .btn span { transition: translate 200ms var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .w-hello:hover span, .w-note .btn:hover span { translate: 3px 0; } }
.w-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
/* Clock: quiet and simple */
.w-clock { height: 168px; padding: 16px; display: grid; place-items: center; }
.w-clock svg { position: absolute; inset: 16px; width: calc(100% - 32px); height: calc(100% - 32px); overflow: visible; filter: drop-shadow(0 6px 12px rgba(40, 28, 16, 0.12)) drop-shadow(0 1px 2px rgba(40, 28, 16, 0.08)); }
.w-clock .c-face { fill: var(--fc1); stroke: var(--ring); stroke-width: 0.8; }
.w-clock .tick { stroke: var(--mark-2); stroke-linecap: round; }
.w-clock .tick.major { stroke: var(--mark); }
.w-clock .hand { stroke: var(--mark); stroke-linecap: round; transform-origin: 60px 60px; }
.w-clock .sec { transform-origin: 60px 60px; transition: rotate 180ms cubic-bezier(0.4, 2.2, 0.6, 1); }
.w-clock .sec line { stroke: var(--sec); stroke-linecap: round; }
.w-clock .cap { fill: var(--mark); }
.w-clock .cap-dot { fill: var(--sec); }
:root { --fc1: #ffffff; --ring: rgba(20, 19, 18, 0.08); --mark: #141312; --mark-2: rgba(20, 19, 18, 0.32); --sec: #ff5a1f; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --fc1: #151515; --ring: rgba(243, 238, 230, 0.1); --mark: #f3eee6; --mark-2: rgba(243, 238, 230, 0.34); --sec: #ff7a3d; } }
:root[data-theme="dark"] { --fc1: #151515; --ring: rgba(243, 238, 230, 0.1); --mark: #f3eee6; --mark-2: rgba(243, 238, 230, 0.34); --sec: #ff7a3d; }
/* Selected work */
.w-note { height: 168px; padding: 18px 18px 16px; display: flex; flex-direction: column; justify-content: space-between; }
.w-note h3 { margin: 0; font: 800 18px/0.95 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; }
.w-note p { margin: 7px 0 0; font-size: 12.5px; line-height: 1.45; color: var(--ink-2); }
.w-note .btn { align-self: flex-start; border-radius: 99px; font-weight: 700; }


kbd {
  font: 600 11px/1 var(--font); padding: 3px 5px; border-radius: 4px;
  background: var(--field); box-shadow: inset 0 -1px 0 var(--hairline); color: var(--ink-2);
}

/* Desktop icons */
.icons { position: absolute; inset: 0; margin: 0; padding: 0; list-style: none; pointer-events: none; }
.icons li { position: absolute; top: 0; left: 0; }
.icon {
  pointer-events: auto; position: absolute; top: 0; left: 0;
  width: 92px; padding: 2px 2px 4px; border: 0; background: none;
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  color: var(--label); font-size: 12px; line-height: 1.25; font-weight: 500; text-align: center;
  touch-action: none; user-select: none;
}
.icon.is-settling { transition: translate 420ms var(--ease-drawer); }
.icon.is-dragging { z-index: 5; opacity: 0.9; }
.icon-art { width: 74px; height: 62px; display: grid; place-items: center; border-radius: 7px; }
.icon-art > svg { width: 66px; height: 55px; filter: drop-shadow(0 1px 1.5px rgba(0, 0, 0, 0.18)); transition: scale 120ms var(--ease-out); }
.icon:active .icon-art > * { scale: 0.96; }
/* Sculptural folder */
.sf { position: relative; display: block; width: 66px; aspect-ratio: 1.28; perspective: 420px; filter: saturate(var(--folder-sat)); transition: scale 140ms var(--ease-out); }
.sf-back { position: absolute; inset: 12% 0 0 0; border-radius: 8px; background: linear-gradient(180deg, color-mix(in oklch, var(--c2), white 8%), var(--c2)); }
.sf-back::before { content: ""; position: absolute; left: 0; top: -13%; width: 44%; height: 22%; border-radius: 6px 9px 0 0; background: color-mix(in oklch, var(--c2), white 8%); }
.sf-peek { position: absolute; inset: 2% 8% 34% 8%; }
.sf-peek img { position: absolute; bottom: 0; width: 64%; height: auto; aspect-ratio: 1.6; object-fit: cover; border-radius: 3px; box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25); transition: transform 460ms var(--ease-drawer); }
.sf-peek img:first-child { left: 0; transform: rotate(-7deg); }
.sf-peek img:nth-child(2) { right: 0; transform: rotate(6deg); }
.sf-front {
  position: absolute; left: 0; right: 0; bottom: 0; height: 72%; border-radius: 8px; transform-origin: 50% 100%;
  background: linear-gradient(165deg, color-mix(in oklch, var(--c1), white 24%) 0%, var(--c1) 72%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.6), inset 0 -8px 14px -10px rgba(0, 0, 0, 0.32);
  display: grid; place-items: center; transform: rotateX(-8deg); transition: transform 460ms var(--ease-drawer);
}
.sf-front svg { width: 32%; height: auto; color: rgba(255, 255, 255, 0.92); filter: drop-shadow(0 1px 0 rgba(0, 0, 0, 0.12)); }
.sf-shadow { position: absolute; left: 6%; right: 6%; bottom: -6px; height: 12px; background: radial-gradient(50% 50% at 50% 50%, rgba(0, 0, 0, 0.3), transparent 72%); z-index: -1; }
@media (hover: hover) and (pointer: fine) {
  .icon:hover .sf-front { transform: rotateX(-28deg); }
  .icon:hover .sf-peek img:first-child { transform: translateY(-36%) rotate(-10deg); }
  .icon:hover .sf-peek img:nth-child(2) { transform: translateY(-28%) rotate(9deg); }
}
.icon:focus-visible .sf-front, .icon.is-selected .sf-front { transform: rotateX(-22deg); }
.icon:focus-visible .sf-peek img:first-child { transform: translateY(-30%) rotate(-10deg); }
.empty .sf { width: 96px; margin-bottom: 8px; }
.icon-label { padding: 1px 5px; border-radius: 4px; max-width: 90px; text-shadow: var(--label-shadow); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.icon.is-selected .icon-art { background: var(--sel-art); }
.icon.is-selected .icon-label { background: var(--accent); color: var(--on-accent); text-shadow: none; }
/* A new folder's name being edited, then typed over (easter egg) */
.icon .icon-label.is-renaming { background: var(--win-bg); color: var(--ink); text-shadow: none; box-shadow: 0 0 0 2px color-mix(in oklch, var(--accent) 55%, transparent); }
.rn.is-sel { background: color-mix(in oklch, var(--accent) 30%, transparent); border-radius: 2px; }
.dock-item.is-drop .dock-icon { filter: brightness(0.78); transition: filter 120ms ease; }
.is-renaming .rn:not(.is-sel) { padding-right: 1px; border-right: 1px solid currentColor; }
.icon:focus-visible { outline: none; }
.icon:focus-visible .icon-art { outline: 2px solid var(--accent); outline-offset: 1px; }

.f-back { fill: oklch(0.67 0.105 var(--h)); }
.f-front { fill: oklch(0.8 0.095 var(--h)); }
.f-glyph { stroke: oklch(0.56 0.12 var(--h)); }

.marquee {
  position: fixed; z-index: 3; pointer-events: none; display: none;
  border: 1px solid color-mix(in oklch, var(--accent) 75%, transparent);
  background: color-mix(in oklch, var(--accent) 16%, transparent);
  border-radius: 2px;
}

/* ───────────────────────── Buttons ───────────────────────── */
.btn {
  height: 30px; padding: 0 14px; border: 0; border-radius: 8px;
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  background: var(--field); color: var(--ink); font-size: 13px; font-weight: 600; text-decoration: none; white-space: nowrap;
  transition: scale 120ms var(--ease-out), background-color 150ms ease;
}
.btn:active { scale: 0.97; }
.btn-primary { background: var(--accent); color: var(--on-accent); }
@media (hover: hover) and (pointer: fine) {
  .btn:hover { background: color-mix(in oklch, var(--field), var(--ink) 6%); }
  .btn-primary:hover { background: color-mix(in oklch, var(--accent), black 8%); }
}
.btn svg { width: 14px; height: 14px; }
.icon-btn {
  width: 30px; height: 28px; border: 0; border-radius: 6px; background: transparent; color: var(--ink-2);
  display: grid; place-items: center; transition: background-color 150ms ease, scale 120ms var(--ease-out);
}
.icon-btn:active { scale: 0.94; }
@media (hover: hover) and (pointer: fine) { .icon-btn:hover:not(:disabled) { background: var(--hover); color: var(--ink); } }
.icon-btn:disabled { opacity: 0.35; }
.icon-btn svg { width: 16px; height: 16px; }

/* ───────────────────────── Windows ───────────────────────── */
.win {
  position: fixed; top: 0; left: 0; z-index: 200;
  display: flex; flex-direction: column;
  background: var(--win-bg); border-radius: 12px; overflow: hidden;
  box-shadow: var(--win-shadow-idle);
  transition: box-shadow 200ms ease;
}
.win.is-active { box-shadow: var(--win-shadow); }
.win.is-min { visibility: hidden; pointer-events: none; }
.win.is-zooming { transition: translate 380ms var(--ease-drawer), width 380ms var(--ease-drawer), height 380ms var(--ease-drawer); }
.win.is-settling { transition: translate 360ms var(--ease-drawer); }
.win-bar {
  height: 40px; flex: none; display: flex; align-items: center; justify-content: center;
  padding: 0 80px; border-bottom: 1px solid var(--win-line); user-select: none;
}
.win-title { margin: 0; font-size: 13px; font-weight: 600; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.win:not(.is-active) .win-title { color: var(--ink-3); }
.win-body { flex: 1; min-height: 0; position: relative; }

.win { border-radius: 16px; }
.win-bar { justify-content: flex-start; padding: 0 170px 0 20px; height: 48px; }
.win-title { font-size: 13.5px; font-weight: 700; letter-spacing: -0.01em; }
.wctl { position: absolute; top: var(--ctl-top, 9px); right: 10px; z-index: 4; display: flex; align-items: center; gap: 6px; }
.wc {
  height: 30px; min-width: 30px; padding: 0; border: 0; border-radius: 99px; background: var(--ctl-bg); color: var(--ink-2);
  display: inline-grid; place-items: center; transition: background-color 160ms ease, color 160ms ease, scale 120ms var(--ease-out);
}
.wc svg { width: 15px; height: 15px; }
.wc:active { scale: 0.94; }
.wc-close { display: inline-flex; align-items: center; gap: 5px; padding: 0 12px 0 9px; font-size: 12.5px; font-weight: 700; color: var(--ink); }
@media (hover: hover) and (pointer: fine) { .wc:hover { background: var(--ctl-bg-hover); color: var(--ink); } }
.win:not(.is-active) .wc { opacity: 0.6; }

/* Finder */
.finder { --ctl-top: 11px; }
.finder .win-bar { display: none; }
.finder .win-body { display: grid; grid-template-columns: 208px 1fr; }
.sb {
  background: var(--win-side);
  -webkit-backdrop-filter: blur(30px) saturate(160%);
  backdrop-filter: blur(30px) saturate(160%);
  border-right: 1px solid var(--win-line);
  padding: 16px 10px 14px; overflow: auto;
}
.sb h3 { margin: 12px 10px 4px; font-size: 11px; font-weight: 600; color: var(--ink-3); }
.sb h3:first-child { margin-top: 0; }
.sb-item {
  width: 100%; height: 28px; padding: 0 8px; border: 0; border-radius: 6px; background: transparent;
  display: flex; align-items: center; gap: 8px; text-align: left; font-size: 13px; white-space: nowrap;
}
.sb-item[aria-current="true"] { background: var(--sel-row); font-weight: 600; }
@media (hover: hover) and (pointer: fine) { .sb-item:hover:not([aria-current="true"]) { background: var(--hover); } }
.sb-item svg { width: 18px; height: 15px; flex: none; }
.sb-item .sb-glyph { color: var(--accent); }
.sb-count { margin-left: auto; font-size: 11px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.fmain { display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.ftool {
  height: 52px; flex: none; display: flex; align-items: center; gap: 6px;
  padding: 0 170px 0 10px; border-bottom: 1px solid var(--win-line); user-select: none;
}
.fnav { display: flex; }
.ftitle { margin: 0 6px; font-size: 15px; font-weight: 700; letter-spacing: -0.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.spacer { flex: 1; }
.seg { display: flex; padding: 2px; border-radius: 7px; background: var(--field); }
.seg button { width: 30px; height: 24px; border: 0; border-radius: 5px; background: transparent; color: var(--ink-2); display: grid; place-items: center; }
.seg button[aria-pressed="true"] { background: var(--win-bg); color: var(--ink); box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12); }
.seg svg { width: 15px; height: 15px; }
.search {
  display: flex; align-items: center; gap: 6px; height: 28px; width: 180px; padding: 0 8px;
  border-radius: 7px; background: var(--field); color: var(--ink-3);
}
.search svg { width: 14px; height: 14px; flex: none; }
.search input { flex: 1; min-width: 0; border: 0; background: transparent; font-size: 13px; color: var(--ink); }
.search input::placeholder { color: var(--ink-3); }
.search input::-webkit-search-cancel-button { filter: grayscale(1); }
.search:focus-within { box-shadow: 0 0 0 2px color-mix(in oklch, var(--accent) 55%, transparent); }
.fgrid {
  flex: 1; min-height: 0; overflow: auto; padding: 20px 22px 24px;
  display: grid; grid-template-columns: repeat(auto-fill, minmax(172px, 1fr)); gap: 24px 18px; align-content: start;
}
.tile {
  border: 0; background: none; padding: 0; text-align: left; color: var(--ink);
  display: flex; flex-direction: column; gap: 9px; border-radius: 10px; min-width: 0;
}
.tile-cover {
  position: relative; display: block; padding: 14px 18px 4px; border-radius: 8px; overflow: visible;
  box-shadow: 0 0 0 0.5px rgba(0, 0, 0, 0.12), 0 8px 18px -10px rgba(0, 0, 0, 0.45);
  transition: translate 220ms var(--ease-out), box-shadow 220ms var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .tile:hover .tile-cover { translate: 0 -2px; box-shadow: 0 0 0 0.5px rgba(0, 0, 0, 0.12), 0 14px 24px -12px rgba(0, 0, 0, 0.5); }
}
.tile:active .tile-cover { scale: 0.985; }
.tile.is-selected .c1 { outline: 3px solid var(--accent); outline-offset: 2px; }
.tile:focus-visible { outline: none; }
.tile:focus-visible .c1 { outline: 3px solid var(--accent); outline-offset: 2px; }
.tile-text { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.tile-name { font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tile-kind { font-size: 12px; color: var(--ink-3); }
.fgrid.is-list { grid-template-columns: 1fr; gap: 0; padding: 8px 10px 16px; }
.fgrid.is-list .tile { flex-direction: row; align-items: center; gap: 12px; padding: 6px 10px; border-radius: 7px; }
.fgrid.is-list .tile:nth-child(even) { background: var(--hover); }
.fgrid.is-list .tile-cover { width: 64px; flex: none; padding: 0; }
.fgrid.is-list .c2, .fgrid.is-list .c3 { display: none; }
.fgrid.is-list .stk-card.c1 { transform: none !important; }
.fgrid.is-list .tile-text { flex-direction: row; align-items: baseline; gap: 16px; flex: 1; }
.fgrid.is-list .tile-name { flex: 1; }
.fgrid.is-list .tile.is-selected { background: var(--accent); color: var(--on-accent); }
.fgrid.is-list .tile.is-selected .tile-kind { color: rgba(255, 255, 255, 0.8); }
.fgrid.is-list .tile.is-selected .tile-cover { outline: 0; }
@media (hover: hover) and (pointer: fine) { .fgrid.is-list .tile:hover .tile-cover { translate: none; } }
.fpath {
  height: 30px; flex: none; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 0 14px; border-top: 1px solid var(--win-line); font-size: 12px; color: var(--ink-3); white-space: nowrap;
}
.crumbs { display: flex; align-items: center; gap: 4px; overflow: hidden; }
.crumbs svg { width: 10px; height: 10px; }
.fpath .count { font-variant-numeric: tabular-nums; }
.empty {
  grid-column: 1 / -1; align-self: center; justify-self: center; margin-top: 8vh;
  display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px; max-width: 34ch;
}
.empty svg { width: 76px; height: 64px; margin-bottom: 8px; opacity: 0.9; }
.empty h3 { margin: 0; font-size: 15px; font-weight: 600; }
.empty p { margin: 0; color: var(--ink-2); font-size: 13px; line-height: 1.5; text-wrap: pretty; }
.empty .btn { margin-top: 12px; }

/* Covers: typeset placeholders until real imagery is added */
.cover { position: absolute; inset: 0; background: var(--bg); color: var(--fg); container-type: inline-size; overflow: hidden; }
.cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.cover .mark { position: absolute; }
.cover-serif .mark { inset: 0; display: grid; place-items: center; padding: 0 8cqi; text-align: center; font: 800 15cqi/0.95 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; }
.cover-serif::after { content: ""; position: absolute; left: 7cqi; right: 7cqi; bottom: 7cqi; height: 1px; background: currentColor; opacity: 0.35; }
.cover-bold .mark { left: 7cqi; right: 7cqi; bottom: 6cqi; font: 800 15cqi/0.88 "Inter", var(--font); letter-spacing: -0.045em; text-wrap: balance; }
.cover-bold .meta { position: absolute; top: 6.5cqi; left: 7cqi; right: 7cqi; display: flex; justify-content: space-between; font: 600 3.8cqi/1 "Inter", var(--font); opacity: 0.7; }
.cover-circle::before { content: ""; position: absolute; width: 78cqi; aspect-ratio: 1; right: -16cqi; top: -22cqi; border-radius: 50%; background: currentColor; opacity: 0.16; }
.cover-circle::after { content: ""; position: absolute; width: 30cqi; aspect-ratio: 1; right: 14cqi; top: 10cqi; border-radius: 50%; border: 0.6cqi solid currentColor; opacity: 0.55; }
.cover-circle .mark { left: 7cqi; bottom: 6cqi; right: 7cqi; font: 800 11.4cqi/0.95 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; }

/* Quick Look */
.ql .win-body { overflow: auto; }
.ql-cover { position: relative; aspect-ratio: 16 / 9; }
.ql-info { padding: 22px 28px 26px; display: grid; gap: 10px; }
.ql-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; }
.ql-title { margin: 0; font: 800 32px/1 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; }
.ql-kind { font-size: 12px; color: var(--ink-3); white-space: nowrap; }
.ql-blurb { margin: 0; font-size: 15px; line-height: 1.55; color: var(--ink-2); max-width: 60ch; text-wrap: pretty; }
.ql-actions { display: flex; align-items: center; gap: 8px; margin-top: 8px; }
.ql-pos { margin-left: auto; font-size: 12px; color: var(--ink-3); font-variant-numeric: tabular-nums; }

/* About */
.about .win-body { overflow: auto; }
.about-inner { padding: 38px 46px 40px; max-width: 640px; }
.about-name { margin: 0; font: 800 44px/0.95 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; }
.about-name em { font-style: normal; font-weight: 300; }
.about-lede { margin: 18px 0 0; font-size: 18px; line-height: 1.5; letter-spacing: -0.01em; text-wrap: pretty; }
.about-inner p:not(.about-lede) { margin: 12px 0 0; font-size: 15px; line-height: 1.6; color: var(--ink-2); max-width: 58ch; text-wrap: pretty; }
.about-inner h2 { margin: 30px 0 10px; font-size: 13px; font-weight: 600; color: var(--ink-3); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  height: 32px; padding: 0 12px 0 8px; border: 0; border-radius: 8px; background: var(--field);
  display: inline-flex; align-items: center; gap: 7px; font-size: 13px; font-weight: 500;
  transition: scale 120ms var(--ease-out), background-color 150ms ease;
}
.chip:active { scale: 0.97; }
@media (hover: hover) and (pointer: fine) { .chip:hover { background: color-mix(in oklch, var(--field), var(--ink) 6%); } }
.chip svg { width: 20px; height: 17px; }
.about-actions { display: flex; gap: 8px; margin-top: 30px; }

/* Contact */
.contact .win-body { overflow: auto; }
.contact-inner { padding: 26px 26px 24px; display: grid; gap: 20px; }
.contact-head { display: flex; align-items: center; gap: 14px; }
.avatar {
  width: 56px; height: 56px; border-radius: 50%; flex: none; display: block; object-fit: cover; object-position: 50% 30%;
  background: var(--field); box-shadow: 0 0 0 0.5px var(--hairline), 0 6px 14px -8px rgba(0, 0, 0, 0.4);
}
.contact-head h2 { margin: 0; font-size: 17px; font-weight: 700; letter-spacing: -0.01em; }
.contact-head p { margin: 2px 0 0; color: var(--ink-2); }
.rows { border-radius: 10px; background: var(--field); overflow: hidden; }
.row { display: flex; align-items: center; gap: 12px; min-height: 44px; padding: 6px 8px 6px 14px; }
.row + .row { box-shadow: inset 0 1px 0 var(--win-line); }
.row-label { width: 72px; flex: none; color: var(--ink-3); font-size: 12px; }
.row-value { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; font-weight: 500; color: var(--ink); text-decoration: none; }
a.row-value:hover { color: var(--accent); }
.contact-actions { display: flex; gap: 8px; }
.contact-actions .btn { flex: 1; height: 36px; }

/* About This Computer (easter egg in the h menu), after the Mac's About This Mac */
.abouthis .win-bar { border-bottom: 0; }
.abouthis .win-title, .abouthis .wc-min, .abouthis .wc-zoom { display: none; }
.abouthis .win-body { overflow: auto; }
.at-inner { display: flex; flex-direction: column; align-items: center; padding: 0 24px 22px; text-align: center; }
.at-photo { width: 112px; height: 112px; border-radius: 50%; object-fit: cover; object-position: 50% 30%; box-shadow: 0 0 0 0.5px var(--hairline), 0 14px 28px -14px rgba(0, 0, 0, 0.45); }
.at-name { margin: 18px 0 0; font: 800 21px/1 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; }
.at-model { margin: 6px 0 0; font-size: 12px; color: var(--ink-3); }
.at-specs { width: 100%; margin: 20px 0 22px; display: grid; gap: 7px; font-size: 12px; line-height: 1.35; }
.at-specs div { display: grid; grid-template-columns: 1fr 1.3fr; gap: 10px; text-align: left; }
.at-specs dt { text-align: right; font-weight: 700; color: var(--ink); }
.at-specs dd { margin: 0; color: var(--ink-2); }
.at-link { padding: 0; border: 0; background: none; font: inherit; color: var(--accent); text-align: left; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; text-decoration-color: color-mix(in oklch, var(--accent) 40%, transparent); }
.at-legal { margin: 20px 0 0; font-size: 10.5px; line-height: 1.45; color: var(--ink-3); }

/* ───────────────────────── Dock ───────────────────────── */
.dock-wrap { position: fixed; left: 50%; bottom: 8px; translate: -50% 0; z-index: 900; }
.dock { position: relative; display: flex; align-items: flex-end; gap: 8px; padding: 0 8px 7px; }
.dock::before {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 66px; z-index: -1;
  border-radius: 22px;
  background: var(--chrome);
  -webkit-backdrop-filter: blur(30px) saturate(180%);
  backdrop-filter: blur(30px) saturate(180%);
  box-shadow: inset 0 0 0 0.5px var(--glass-edge), 0 0 0 0.5px var(--hairline), 0 12px 30px -12px rgba(0, 0, 0, 0.35);
}
.dock-item { position: relative; width: 52px; height: 52px; flex: none; }
.dock-btn { width: 100%; height: 100%; padding: 0; border: 0; background: none; display: block; }
.dock-btn:focus-visible { outline: none; }
.dock-btn:focus-visible .dock-icon { outline: 2px solid var(--accent); outline-offset: 3px; }
.dock-icon {
  position: relative; width: 100%; height: 100%; display: grid; place-items: center;
  container-type: size; transition: filter 120ms ease;
}
.dock-btn:active .dock-icon { filter: brightness(0.86); }
/* Objects share the desktop's material language */
.dock-icon .stk { width: 92cqw; }
.dock-icon .sf { width: 94cqw; }
.dock-item:hover .c1 { transform: translateY(-4px) rotate(0deg); }
.dock-item:hover .c2 { transform: translate(18%, -12%) rotate(10deg) scale(0.9); }
.dock-item:hover .c3 { transform: translate(-18%, -8%) rotate(-12deg) scale(0.86); }
.dock-item:hover .sf-front { transform: rotateX(-28deg); }
.dock-item:hover .sf-peek img:first-child { transform: translateY(-36%) rotate(-10deg); }
.dock-item:hover .sf-peek img:nth-child(2) { transform: translateY(-28%) rotate(9deg); }
/* Paper card */
.doc3d {
  position: relative; width: 66cqw; height: 84cqw; border-radius: 3cqw 12cqw 3cqw 3cqw; background: linear-gradient(170deg, #ffffff, #f1ede6);
  box-shadow: 0 0 0 0.5px rgba(0, 0, 0, 0.08), 0 4cqw 8cqw -3cqw rgba(40, 28, 16, 0.45); rotate: -5deg;
  padding: 9cqw 8cqw; display: flex; flex-direction: column; gap: 4.5cqw; transition: rotate 420ms var(--ease-drawer), translate 420ms var(--ease-drawer);
}
.doc3d::after { content: ""; position: absolute; top: 0; right: 0; width: 22cqw; height: 22cqw; border-radius: 0 12cqw 0 4cqw; background: linear-gradient(225deg, transparent 48%, #e2ddd4 50%); }
.doc3d b { font: 800 26.4cqw/0.8 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; color: #ff5a1f; margin-bottom: 2cqw; }
.doc3d i { display: block; height: 3cqw; border-radius: 9px; background: #d9d4cc; }
.doc3d i:nth-of-type(2) { width: 80%; } .doc3d i:nth-of-type(3) { width: 58%; }
.dock-item:hover .doc3d, .icon:hover .doc3d { rotate: 0deg; translate: 0 -4%; }
/* Envelope with a letter */
.env3d { position: relative; width: 88cqw; height: 62cqw; margin-top: 16cqw; }
.env-back, .env-front { position: absolute; inset: 0; border-radius: 6cqw; }
.env-back { background: linear-gradient(180deg, #2442d6, #1d34b3); }
.env-letter {
  position: absolute; left: 10%; right: 10%; top: -30%; height: 88%; border-radius: 3cqw; background: #fffdf8; padding: 8cqw 7cqw; display: flex; flex-direction: column; gap: 4cqw;
  box-shadow: 0 1cqw 3cqw rgba(0, 0, 0, 0.15); transition: translate 420ms var(--ease-drawer);
}
.env-letter i { display: block; height: 3cqw; border-radius: 9px; background: #e2dbf8; }
.env-letter i:last-child { width: 62%; }
.env-front {
  background: linear-gradient(170deg, #8f73ff, #6f4ff0 60%);
  clip-path: polygon(0 18%, 50% 62%, 100% 18%, 100% 100%, 0 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.4);
}
.env3d { filter: drop-shadow(0 3cqw 5cqw rgba(50, 30, 110, 0.35)); }
.env-stamp { position: absolute; right: 7cqw; bottom: 8cqw; width: 16cqw; height: 18cqw; border-radius: 2cqw; background: #ff5a1f; box-shadow: 0 0 0 1.4cqw #fffdf8; }
.dock-item:hover .env-letter { translate: 0 -18%; }
/* Framed wallpaper print */
.frame3d {
  width: 84cqw; aspect-ratio: 1.22; padding: 7cqw; border-radius: 4cqw; rotate: 4deg; background: linear-gradient(170deg, #ffffff, #efebe4);
  box-shadow: 0 0 0 0.5px rgba(0, 0, 0, 0.08), 0 4cqw 8cqw -3cqw rgba(40, 28, 16, 0.45); transition: rotate 420ms var(--ease-drawer);
}
.frame-art { display: block; width: 100%; height: 100%; border-radius: 1.5cqw; background: var(--next-wall); box-shadow: inset 0 0 0 0.5px rgba(0, 0, 0, 0.12), inset 0 2cqw 4cqw rgba(0, 0, 0, 0.12); }
.dock-item:hover .frame3d { rotate: 0deg; }
/* Frosted bin, with the other routes peeking out */
.bin3d { position: relative; width: 66cqw; height: 86cqw; }
.bin-peek { position: absolute; left: 4%; right: 4%; top: 0; height: 40%; }
.bin-peek img { position: absolute; bottom: 0; width: 64%; aspect-ratio: 1.6; object-fit: cover; border-radius: 2cqw; box-shadow: 0 1cqw 3cqw rgba(0, 0, 0, 0.25); transition: transform 460ms var(--ease-drawer); }
.bin-peek img:first-child { left: 0; transform: rotate(-12deg); }
.bin-peek img:last-child { right: 0; transform: rotate(9deg); }
.bin-body {
  position: absolute; left: 0; right: 0; bottom: 0; height: 74%;
  clip-path: polygon(0 0, 100% 0, 88% 100%, 12% 100%);
  background:
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.5) 0 4cqw, rgba(255, 255, 255, 0.12) 4cqw 8cqw),
    linear-gradient(180deg, rgba(215, 212, 206, 0.9), rgba(160, 156, 150, 0.9));
}
.bin-rim { position: absolute; left: -5%; right: -5%; top: 22%; height: 9%; border-radius: 99px; background: linear-gradient(180deg, #f7f5f1, #cfcbc4); box-shadow: 0 1cqw 2cqw rgba(0, 0, 0, 0.2); }
.bin3d { filter: drop-shadow(0 3cqw 4cqw rgba(0, 0, 0, 0.25)); }
.dock-item:hover .bin-peek img:first-child { transform: translateY(-26%) rotate(-16deg); }
.dock-item:hover .bin-peek img:last-child { transform: translateY(-20%) rotate(13deg); }
:root[data-theme="dark"] .bin-body { background: repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.14) 0 4cqw, rgba(255, 255, 255, 0.04) 4cqw 8cqw), linear-gradient(180deg, #4a4a4c, #262628); }
:root[data-theme="dark"] .bin-rim { background: linear-gradient(180deg, #6b6b6e, #3a3a3c); }
:root[data-theme="dark"] .frame3d { background: linear-gradient(170deg, #2b2b2b, #161616); box-shadow: 0 0 0 0.5px rgba(255, 255, 255, 0.1), 0 4cqw 8cqw -3cqw rgba(0, 0, 0, 0.8); }
.dock-dot {
  position: absolute; left: 50%; bottom: -5px; width: 4px; height: 4px; margin-left: -2px; border-radius: 50%;
  background: var(--ink); opacity: 0; transition: opacity 200ms ease;
}
.dock-item.is-running .dock-dot { opacity: 0.75; }
.dock-sep { width: 1px; height: 46px; margin: 0 2px 3px; background: var(--hairline); align-self: flex-end; }
.dock-label {
  position: absolute; left: 50%; bottom: calc(100% + 12px); translate: -50% 0;
  padding: 4px 10px; border-radius: 7px; white-space: nowrap; pointer-events: none;
  background: var(--menu-bg);
  -webkit-backdrop-filter: blur(30px); backdrop-filter: blur(30px);
  box-shadow: 0 0 0 0.5px var(--hairline), 0 6px 16px -6px rgba(0, 0, 0, 0.3);
  font-size: 12px; font-weight: 500; opacity: 0; transition: opacity 120ms ease;
}
@media (hover: hover) and (pointer: fine) { .dock-item:hover .dock-label { opacity: 1; } }
.dock-btn:focus-visible + .dock-label { opacity: 1; }

/* ───────────────────────── Notifications ───────────────────────── */
.toasts {
  position: fixed; top: calc(var(--menubar-h) + 10px); right: 12px; z-index: 1100;
  width: 344px; display: flex; flex-direction: column; gap: 8px; pointer-events: none;
}
.toast {
  pointer-events: auto; display: grid; grid-template-columns: 38px 1fr; gap: 11px; align-items: center;
  padding: 12px 14px 12px 12px; border-radius: 18px;
  background: var(--menu-bg);
  -webkit-backdrop-filter: blur(40px) saturate(180%);
  backdrop-filter: blur(40px) saturate(180%);
  box-shadow: inset 0 0 0 0.5px var(--glass-edge), 0 0 0 0.5px var(--hairline), 0 14px 34px -12px rgba(0, 0, 0, 0.35);
}
.toast .dock-icon { width: 42px; height: 42px; }
.toast-text strong { display: block; font-size: 13px; font-weight: 600; }
.toast-text span { display: block; font-size: 13px; color: var(--ink-2); line-height: 1.35; }

/* ───────────────────────── Compact (phones) ───────────────────────── */
@media (max-width: 719px) {
  body { overflow: hidden; }
  .mb-hide-sm { display: none; }
  .desktop { top: var(--menubar-h); overflow-y: auto; overscroll-behavior: contain; padding: 16px 16px 132px; }
  .widgets { position: static; width: auto; grid-template-columns: 1fr; }
  .w-clock, .w-note { display: none; }
  .icons { margin-top: 26px !important; }
  .w-name { font-size: 53px; }
  .stamp { width: 78px; height: 78px; }
  .icons {
    position: static; pointer-events: auto; margin-top: 22px;
    display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 16px 4px;
  }
  .icons li { position: static; }
  .icon { position: static; width: 100%; translate: none !important; touch-action: manipulation; }
  .win {
    translate: none !important; width: 100% !important; height: calc(100dvh - var(--menubar-h) - 8px) !important;
    top: auto; bottom: 0; border-radius: 16px 16px 0 0;
  }
  .finder .win-body { grid-template-columns: 1fr; grid-template-rows: auto auto auto 1fr auto; grid-template-areas: "tool" "sb" "chips" "grid" "path"; }
  .fchips { grid-area: chips; padding: 10px 12px 0; }
  .fmain { display: contents; }
  .ftool { grid-area: tool; padding-left: 12px; padding-right: 110px; }
  .wc-min, .wc-zoom { display: none !important; }
  .fgrid { grid-area: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); padding: 16px; gap: 18px 12px; }
  /* List view on a phone: the title on top, its description underneath */
  .fgrid.is-list { padding: 8px 8px 16px; }
  .fgrid.is-list .tile { gap: 12px; padding: 8px; min-width: 0; }
  .fgrid.is-list .tile-text { flex-direction: column; align-items: stretch; gap: 2px; min-width: 0; }
  .fgrid.is-list .tile-name { flex: none; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .fgrid.is-list .tile-kind { font-size: 12px; line-height: 1.3; white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  /* Toolbar: the folder chips below do the navigating, so back/forward step aside; search opens from its icon */
  .fnav { display: none; }
  .ftool { gap: 8px; padding-left: 14px; padding-right: 96px; }
  .ftitle { min-width: 0; margin: 0; }
  .search { flex: none; width: 34px; padding: 0 10px; transition: width 220ms var(--ease-out); cursor: text; }
  .search input { width: 0; opacity: 0; }
  .search:focus-within { flex: 1; width: auto; }
  .ftool:has(.search:focus-within) .ftitle, .ftool:has(.search:focus-within) .spacer { display: none; }
  .search:focus-within input { width: auto; opacity: 1; }
  .fpath { grid-area: path; }
  .sb { grid-area: sb; display: flex; gap: 6px; padding: 10px 12px; overflow-x: auto; border-right: 0; border-bottom: 1px solid var(--win-line); }
  .sb h3, .sb .sb-sec2 { display: none; }
  .sb-item { width: auto; flex: none; background: var(--field); padding: 0 12px 0 8px; height: 32px; }
  .sb-count { display: none; }
  .seg { display: none; }
  .about-inner { padding: 26px 22px 40px; }
  .about-name { font-size: 37px; }
  .ql-info { padding: 18px 20px 26px; }
  .ql-title { font-size: 26px; }
  .dock-item { width: 48px; height: 48px; }
  .dock::before { height: 62px; }
  .dock-item[data-app="trash"], .dock-sep { display: none; }
  .toasts { left: 12px; right: 12px; width: auto; }
}


/* ───────────────────────── Featured widget ───────────────────────── */
.w-feat { grid-column: 1 / -1; padding: 16px 18px 16px; }
.w-feat h3 { margin: 0; font: 800 18px/1 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; }
.feat-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; padding-top: 8px; }
.feat {
  display: flex; flex-direction: column; align-items: stretch; gap: 10px; padding: 0; border: 0; background: none;
  font-size: 12.5px; font-weight: 700; letter-spacing: -0.01em; color: var(--ink); text-align: center;
}
.feat:focus-visible { outline: none; }
.feat:focus-visible > span:last-child { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
/* Stacked project files: gently fan out on hover or focus */
.stk { position: relative; display: block; width: 100%; aspect-ratio: 16 / 9; }
.stk-card {
  position: absolute; inset: 0; border-radius: 5px; overflow: hidden; background: var(--field);
  box-shadow: var(--card-shadow); transition: transform 480ms var(--ease-drawer), box-shadow 480ms var(--ease-drawer);
}
.stk-card img { display: block; width: 100%; height: 100%; }
.stk-card.c1 { z-index: 3; transform: rotate(-1.5deg); }
.stk-card.c2 { z-index: 2; transform: translate(5%, -7%) rotate(5deg) scale(0.94); }
.stk-card.c3 { z-index: 1; transform: translate(-5%, -5%) rotate(-7deg) scale(0.9); }
@media (hover: hover) and (pointer: fine) {
  .feat:hover .c1, .tile:hover .c1 { transform: translateY(-4px) rotate(0deg); }
  .feat:hover .c2, .tile:hover .c2 { transform: translate(22%, -12%) rotate(10deg) scale(0.9); }
  .feat:hover .c3, .tile:hover .c3 { transform: translate(-22%, -8%) rotate(-12deg) scale(0.86); }
}
.feat:focus-visible .c2, .tile:focus-visible .c2 { transform: translate(22%, -12%) rotate(10deg) scale(0.9); }
.feat:focus-visible .c3, .tile:focus-visible .c3 { transform: translate(-22%, -8%) rotate(-12deg) scale(0.86); }
.feat:active .stk, .tile:active .stk { scale: 0.97; }
.stk { transition: scale 140ms var(--ease-out); }
@media (max-height: 740px) and (min-width: 720px) { .w-clock, .w-note { display: none; } }
@media (max-height: 700px) and (min-width: 720px) { .w-copy { display: none; } }
.sel-strip { display: none; }

/* Guide viewer: a phone on the desk */
.guide .win-body { overflow: hidden; }
.gv { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; padding: 18px 16px 16px; container-type: size; }
/* An outlined phone: drawn with a fine line, like a technical sketch of the device */
.phone {
  --line: color-mix(in oklch, var(--ink) 82%, transparent);
  position: relative; flex: none; padding: 11px; border-radius: 54px; background: var(--win-bg);
  box-shadow: 0 0 0 1.4px var(--line), 0 34px 60px -44px rgba(20, 16, 40, 0.35);
}
/* Side buttons: action and volume on the left, power on the right */
.phone::before, .phone::after { content: ""; position: absolute; width: 3px; border-radius: 2px; pointer-events: none; }
.phone::before {
  left: -4.4px; top: 17%; height: 25%;
  background: linear-gradient(var(--line) 0 0) 0 0 / 100% 13% no-repeat, linear-gradient(var(--line) 0 0) 0 42% / 100% 24% no-repeat, linear-gradient(var(--line) 0 0) 0 100% / 100% 24% no-repeat;
}
.phone::after { right: -4.4px; top: 27%; height: 11%; background: var(--line); }
.phone-screen { position: relative; height: calc(100cqh - 146px); width: calc((100cqh - 146px) * 9 / 16); max-width: calc(100cqw - 40px); border-radius: 43px; overflow: hidden; background: #111; box-shadow: 0 0 0 1.2px var(--line); }
.gv-pages {
  height: 100%; overflow-y: auto; overscroll-behavior: contain; scroll-snap-type: y mandatory; scrollbar-width: none;
}
.gv-pages::-webkit-scrollbar { display: none; }
.gv-pages:focus-visible { outline: none; box-shadow: inset 0 0 0 3px var(--accent); }
.gv-p { position: relative; height: 100%; scroll-snap-align: start; scroll-snap-stop: always; }
.gv-p img { display: block; width: 100%; height: 100%; object-fit: contain; -webkit-user-drag: none; user-select: none; }
.gv-img { width: 100%; height: 100%; background-repeat: no-repeat; background-size: cover; background-position: center; }
.phone-island { position: absolute; top: 10px; left: 50%; width: 30%; height: 21px; translate: -50% 0; border-radius: 99px; background: #000; pointer-events: none; }
.phone-island::after { content: ""; position: absolute; right: 9%; top: 50%; width: 7px; height: 7px; translate: 0 -50%; border-radius: 50%; background: #1b2233; box-shadow: inset 0 0 0 1.5px #0e0e10; }
.gv-hot { position: absolute; inset: 0; pointer-events: none; }
.gv-hot button { position: absolute; pointer-events: auto; padding: 0; border: 0; border-radius: 14px; background: transparent; cursor: pointer; transition: background-color 160ms ease, box-shadow 160ms ease; }
@media (hover: hover) and (pointer: fine) { .gv-hot button:hover { background: rgba(255, 255, 255, 0.16); box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.75); } }
.gv-hot button:focus-visible { outline: 2px solid #fff; outline-offset: 0; box-shadow: 0 0 0 4px rgba(111, 79, 240, 0.8); }
.gv-hot.reveal button { animation: hotReveal 1100ms ease 250ms 1; }
@keyframes hotReveal { 0%, 100% { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0); } 35% { box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.85); background: rgba(255, 255, 255, 0.14); } }
/* Navigation: a scrubber and one quiet row of controls */
.gv-nav { width: min(100%, 340px); display: flex; flex-direction: column; gap: 10px; }
.gv-scrub { display: block; }
.gv-scrub input {
  --p: 0%;
  width: 100%; height: 18px; margin: 0; background: transparent; -webkit-appearance: none; appearance: none; cursor: pointer;
}
.gv-scrub input::-webkit-slider-runnable-track { height: 4px; border-radius: 99px; background: linear-gradient(90deg, var(--ink) var(--p), var(--field) var(--p)); }
.gv-scrub input::-moz-range-track { height: 4px; border-radius: 99px; background: var(--field); }
.gv-scrub input::-moz-range-progress { height: 4px; border-radius: 99px; background: var(--ink); }
.gv-scrub input::-webkit-slider-thumb {
  -webkit-appearance: none; width: 14px; height: 14px; margin-top: -5px; border-radius: 50%; background: var(--win-bg);
  box-shadow: 0 0 0 1.5px var(--ink), 0 2px 6px rgba(0, 0, 0, 0.2); transition: scale 140ms var(--ease-out);
}
.gv-scrub input::-moz-range-thumb { width: 14px; height: 14px; border: 0; border-radius: 50%; background: var(--win-bg); box-shadow: 0 0 0 1.5px var(--ink); }
.gv-scrub input:active::-webkit-slider-thumb { scale: 1.2; }
.gv-scrub input:focus-visible { outline: none; }
.gv-scrub input:focus-visible::-webkit-slider-thumb { box-shadow: 0 0 0 1.5px var(--ink), 0 0 0 5px color-mix(in oklch, var(--accent) 35%, transparent); }
.gv-bar { display: flex; align-items: center; justify-content: space-between; gap: 4px; }
.gv-pos { flex: 1; text-align: center; font-size: 13px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.gv-pos b { color: var(--ink); font-weight: 700; }
.gv-home { border-radius: 99px; }

/* Wallpaper picker */
.wp {
  position: fixed; z-index: 1150; width: 356px; padding: 14px; border-radius: 20px;
  background: var(--menu-bg); -webkit-backdrop-filter: blur(40px) saturate(180%); backdrop-filter: blur(40px) saturate(180%);
  box-shadow: 0 0 0 0.5px var(--hairline), inset 0 0.5px 0 var(--glass-edge), 0 24px 50px -18px rgba(0, 0, 0, 0.4);
}
.wp-head { display: flex; align-items: baseline; justify-content: space-between; padding: 0 2px 10px; }
.wp-head strong { font: 800 15px/1 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; }
.wp-head span { font-size: 12px; color: var(--ink-3); }
.wp-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.wp-item { padding: 0; border: 0; background: none; display: flex; flex-direction: column; gap: 6px; text-align: left; }
.wp-thumb { display: block; aspect-ratio: 16 / 10; border-radius: 9px; box-shadow: 0 0 0 1px var(--hairline); transition: box-shadow 160ms ease, scale 140ms var(--ease-out); }
.wp-item:active .wp-thumb { scale: 0.96; }
@media (hover: hover) and (pointer: fine) { .wp-item:hover .wp-thumb { box-shadow: 0 0 0 1px var(--hairline), 0 6px 14px -8px rgba(0, 0, 0, 0.4); } }
.wp-item[aria-pressed="true"] .wp-thumb { box-shadow: 0 0 0 2px var(--win-bg), 0 0 0 4px #8f73ff; }
.wp-item:focus-visible { outline: none; }
.wp-item:focus-visible .wp-thumb { box-shadow: 0 0 0 2px var(--win-bg), 0 0 0 4px var(--accent); }
.wp-name { font-size: 11.5px; font-weight: 600; color: var(--ink-2); }
.wp-more { margin: 12px 2px 0; font-size: 11.5px; color: var(--ink-3); }

/* Menu-bar appearance switch */
.mb-seg { display: inline-flex; gap: 2px; padding: 2px; margin: 0 6px; border-radius: 7px; background: var(--menu-hi); }
.mb-seg button { height: 20px; padding: 0 9px; border: 0; border-radius: 5px; background: transparent; font-size: 12px; font-weight: 600; color: var(--ink-2); transition: background-color 160ms ease, color 160ms ease; }
.mb-seg button[aria-pressed="true"] { background: var(--win-bg); color: var(--ink); box-shadow: 0 1px 2px rgba(0, 0, 0, 0.16); }

/* Glister story */
.story-hero { margin: 0 0 8px; }
.facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px 28px; margin: 24px 0 0; padding: 20px 0 0; border-top: 1px solid var(--win-line); }
.facts dt { font-size: 11.5px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); }
.facts dd { margin: 6px 0 0; font-size: 14px; line-height: 1.5; }
.decision { display: grid; grid-template-columns: 1.2fr 1fr; gap: 36px; align-items: center; margin: 48px 0 16px; }
.decision .case-img { margin: 0; }
.decision h3 { margin: 0 0 14px; font: 800 clamp(25px, 2.6vw, 35px)/0.98 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; }
.decision blockquote { margin: 0; font: 500 17px/1.4 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; color: var(--ink-2); }
.decision p { margin: 14px 0 0; font-size: 14px; line-height: 1.55; color: var(--ink-2); }
.chapter { display: flex; align-items: baseline; gap: 14px; margin: 56px 0 16px; }
.chapter h2 { margin: 0; font: 800 clamp(25px, 2.6vw, 35px)/1 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; }
.chapter p { margin: 0; font-size: 13px; color: var(--ink-3); }
.grid2 .case-img { margin: 0; }
.grid2 { margin-bottom: 14px; }

/* Covers are real images now */
.cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

/* ───────────────────────── Case study ───────────────────────── */
.case .win-body { overflow: auto; overscroll-behavior: contain; }
.case { --gut: 48px; }
/* One column: the header, tab bar, work and footer share the same left and right edges */
.case-head { max-width: 1000px; margin: 0 auto; padding: 44px var(--gut) 22px; }
.case-title { margin: 0; font: 800 clamp(35px, 4.4vw, 56px)/0.92 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; text-wrap: balance; }
.case-meta { margin: 12px 0 0; font-size: 13px; font-weight: 600; color: var(--ink-3); }
.case-summary { margin: 14px 0 0; font-size: 17px; line-height: 1.55; color: var(--ink-2); max-width: 60ch; text-wrap: pretty; }
.case-bar {
  position: sticky; top: 0; z-index: 2; display: flex; align-items: center; gap: 6px;
  max-width: 1000px; margin: 0 auto; padding: 10px 48px;
  background: color-mix(in oklch, var(--win-bg) 84%, transparent);
  -webkit-backdrop-filter: blur(20px) saturate(160%); backdrop-filter: blur(20px) saturate(160%);
}
.tabs { position: relative; display: inline-flex; padding: 3px; border-radius: 9px; background: var(--field); }
.tab { position: relative; z-index: 1; height: 28px; padding: 0 14px; border: 0; border-radius: 7px; background: transparent; font-size: 13px; font-weight: 600; color: var(--ink-2); transition: color 200ms ease; }
.tab[aria-selected="true"] { color: var(--ink); }
.tab-pill {
  position: absolute; top: 3px; left: 0; height: 28px; border-radius: 7px; background: var(--win-bg);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.14), 0 0 0 0.5px var(--hairline);
  transition: translate 340ms var(--ease-drawer), width 340ms var(--ease-drawer);
}
.case-panel { max-width: 1000px; margin: 0 auto; padding: 8px var(--gut) 12px; }
.case-sec h2 { margin: 30px 0 14px; font-size: 13px; font-weight: 600; color: var(--ink-3); }
.case-img { display: block; width: 100%; height: auto; margin: 0 0 14px; border-radius: 8px; background: var(--field); }
.case-video { aspect-ratio: 16 / 9; background: #000; }
.browser { position: relative; max-width: 940px; margin: 0 auto 18px; border-radius: 12px; overflow: hidden; box-shadow: 0 0 0 0.5px var(--hairline), 0 24px 48px -24px rgba(0, 0, 0, 0.45); }
.browser-bar { position: relative; height: 32px; display: flex; align-items: center; gap: 6px; padding: 0 12px; background: var(--field); }
.browser-addr { position: absolute; left: 50%; translate: -50% 0; max-width: 50%; padding: 3px 16px; border-radius: 6px; background: var(--field); font-size: 11.5px; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.browser-view { aspect-ratio: 16 / 10; overflow-y: auto; overscroll-behavior-y: auto; scrollbar-width: thin; }
.browser-view:focus-visible { outline: 2px solid var(--accent, #6f4ff0); outline-offset: -2px; }
.browser-hint { position: absolute; right: 14px; bottom: 14px; padding: 5px 11px 5px 10px; border-radius: 99px; background: rgba(20, 19, 18, 0.62); color: #fff; font-size: 12px; pointer-events: none; transition: opacity 240ms ease, translate 240ms cubic-bezier(0.23, 1, 0.32, 1); }
.browser-hint::before { content: '↓ '; }
.browser.scrolled .browser-hint { opacity: 0; translate: 0 6px; }
@media (max-width: 719px) { .browser-view { aspect-ratio: 4 / 5; } }
.browser-bar i { width: 9px; height: 9px; border-radius: 50%; background: var(--light-off); }
.browser .case-img { margin: 0; border-radius: 0; }
.quote { margin: 34px 0 10px; }
.quote blockquote { margin: 0; font: 500 clamp(19px, 2vw, 26px)/1.28 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; max-width: 36ch; text-wrap: pretty; }
.quote blockquote::before { content: "“"; display: block; font-size: 2.4em; line-height: 0.6; font-weight: 800; color: var(--ink-3); margin-bottom: 4px; }
.quote-sm blockquote { font-size: clamp(20px, 2vw, 24px); }
.quote figcaption { margin-top: 12px; font-size: 12px; color: var(--ink-3); }
.sec-note { margin: -6px 0 16px; font-size: 14px; line-height: 1.5; color: var(--ink-2); max-width: 60ch; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.grid2 .case-img { margin: 0; }
.pair { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.pair figure { margin: 0; }
.pair .case-img { margin: 0; aspect-ratio: 16 / 10; object-fit: contain; background: var(--field); }
.pair.ba .case-img { aspect-ratio: 16 / 9; background: #fff; }
.pair figcaption { margin-top: 8px; font-size: 12px; color: var(--ink-3); }
.case-foot { max-width: 1000px; margin: 0 auto; padding: 26px var(--gut) 44px; background: linear-gradient(var(--win-line), var(--win-line)) var(--gut) 0 / calc(100% - 2 * var(--gut)) 1px no-repeat; }
.case-foot p { margin: 0 0 14px; font-size: 15px; color: var(--ink-2); }
.case-foot-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.case-foot .btn { height: 36px; }
.case-next {
  display: flex; align-items: center; gap: 12px; padding: 6px 12px 6px 6px; border: 0; border-radius: 12px; background: var(--field); text-align: left;
  transition: scale 120ms var(--ease-out), background-color 150ms ease;
}
.case-next:active { scale: 0.98; }
.case-next-img { width: 72px; height: 48px; object-fit: cover; border-radius: 7px; }
.case-next span { display: flex; flex-direction: column; font-size: 12px; color: var(--ink-3); }
.case-next strong { font-size: 14px; color: var(--ink); }
.case-next svg { width: 16px; height: 16px; color: var(--ink-3); }

/* ───────────────────────── Tour & Trash ───────────────────────── */
.tour .win-body, .trash .win-body { overflow: auto; }
.tour-inner { max-width: 860px; margin: 0 auto; padding: 36px 40px 44px; }
.tour-head h1 { margin: 0; font: 800 42px/1 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; }
.tour-head p { margin: 12px 0 18px; font-size: 15px; line-height: 1.55; color: var(--ink-2); max-width: 58ch; }
.tour-row {
  width: 100%; display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 4fr); gap: 24px; align-items: center;
  padding: 18px 0; border: 0; border-top: 1px solid var(--win-line); background: none; text-align: left;
}
.tour-img { display: block; border-radius: 8px; overflow: hidden; background: var(--field); box-shadow: 0 0 0 0.5px var(--hairline); }
.tour-img img { display: block; width: 100%; height: auto; transition: scale 500ms var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .tour-row:hover .tour-img img { scale: 1.03; } }
.tour-text { display: flex; flex-direction: column; gap: 6px; }
.tour-text strong { font: 800 26px/1 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; }
.tour-text em { font-style: normal; font-size: 12px; font-weight: 600; color: var(--ink-3); }
.tour-text > span { font-size: 14px; line-height: 1.5; color: var(--ink-2); }
.tour-text b { display: inline-flex; align-items: center; gap: 2px; margin-top: 4px; font-size: 13px; font-weight: 600; color: var(--accent); }
.tour-text b svg { width: 13px; height: 13px; }
.trash-group { padding: 20px 0 8px; border-top: 1px solid var(--win-line); }
.trash-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.trash-head h2 { margin: 0; font: 800 23px/1 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; }
.trash-strip { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; }
.trash-item { padding: 0; border: 0; border-radius: 7px; overflow: hidden; background: var(--field); transition: scale 120ms var(--ease-out); }
.trash-item:active { scale: 0.98; }
.trash-item img { display: block; width: 100%; height: auto; }

/* ───────────────────────── Books: turn the pages ───────────────────────── */
.book .win-body { overflow: hidden; }
.bk { --paper: #fbfaf7; --ease-page: cubic-bezier(0.645, 0.045, 0.355, 1); height: 100%; display: flex; flex-direction: column; }
.bk-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 8px 32px; padding: 20px 28px 0; }
.bk-head h1 { margin: 0; font: 800 23px/1 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; }
.bk-head h1 span { font: 600 17px/1 "Geeza Pro", "Noto Naskh Arabic", system-ui, sans-serif; letter-spacing: 0; color: var(--ink-3); margin-left: 10px; }
.bk-head div p { margin: 7px 0 0; font-size: 12px; font-weight: 600; color: var(--ink-3); }
.bk-sum { flex: 1 1 280px; margin: 0; max-width: 50ch; font-size: 13px; line-height: 1.5; color: var(--ink-2); text-align: right; text-wrap: pretty; }
.bk-stage {
  flex: 1; min-height: 0; display: grid; place-items: center; container-type: size; perspective: 2600px;
  outline: none; cursor: pointer; user-select: none; -webkit-user-select: none; touch-action: pan-y;
}
.bk-stage:focus-visible { box-shadow: inset 0 0 0 2px var(--accent); }
.bk-book {
  position: relative; width: min(100cqw - 56px, (100cqh - 36px) * 2 * var(--ar)); aspect-ratio: calc(2 * var(--ar));
  transform-style: preserve-3d; translate: calc(var(--shift, 0) * 25%) 0; transition: translate 900ms var(--ease-page);
}
.bk-leaf {
  position: absolute; top: 0; left: 50%; width: 50%; height: 100%; transform-origin: 0 50%; transform-style: preserve-3d;
  transition: transform var(--dur, 900ms) var(--ease-page);
}
.bk-leaf.turned { transform: rotateY(-180deg); }
.bk-rtl .bk-leaf { left: 0; transform-origin: 100% 50%; }
.bk-rtl .bk-leaf.turned { transform: rotateY(180deg); }
.bk-leaf.is-next, .bk-leaf.is-prev { --dur: 420ms; }
.bk-leaf.flying { --dur: 900ms; }
.bk-leaf.no-anim { transition: none; }
/* Hovering an edge lifts the page a little, like a thumb at the corner */
.bk-book[data-peek="next"] .bk-leaf.is-next:not(.flying) { transform: rotateY(-14deg); }
.bk-book[data-peek="prev"] .bk-leaf.is-prev:not(.flying) { transform: rotateY(-166deg); }
.bk-rtl .bk-book[data-peek="next"] .bk-leaf.is-next:not(.flying) { transform: rotateY(14deg); }
.bk-rtl .bk-book[data-peek="prev"] .bk-leaf.is-prev:not(.flying) { transform: rotateY(166deg); }
.bk-face {
  position: absolute; inset: 0; overflow: hidden; backface-visibility: hidden; -webkit-backface-visibility: hidden;
  background: var(--paper) center / contain no-repeat;
}
/* Only the pages on top cast a shadow; stacking thirty shadows turns the desk grey */
.bk-leaf.is-next > .front, .bk-leaf.is-prev > .back, .bk-leaf.flying > .bk-face { box-shadow: 0 0 0 0.5px rgba(0, 0, 0, 0.08), 0 20px 32px -22px rgba(20, 16, 40, 0.55); }
.bk-face.back { transform: rotateY(180deg); }
.bk-face.cover { background-color: var(--cover); }
.bk-face::after { content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none; }
/* The gutter: shade where each page meets the spine */
.bk-face.front::after, .bk-rtl .bk-face.back::after { background: linear-gradient(90deg, rgba(0, 0, 0, 0.2), rgba(0, 0, 0, 0.05) 3%, transparent 10%); }
.bk-face.back::after, .bk-rtl .bk-face.front::after { background: linear-gradient(270deg, rgba(0, 0, 0, 0.2), rgba(0, 0, 0, 0.05) 3%, transparent 10%); }
.bk-face.cover::after { opacity: 0.45; }
/* A page in flight passes through its own shadow */
.bk-leaf.flying .bk-face::before { content: ""; position: absolute; inset: 0; z-index: 3; background: #000; opacity: 0; pointer-events: none; animation: bkShade 900ms var(--ease-page); }
@keyframes bkShade { 50% { opacity: 0.14; } }
/* That's IT, page one: the top of the page is really cut away */
.bk-face.cutface { background: none; box-shadow: none !important; filter: drop-shadow(0 1px 1.5px rgba(0, 0, 0, 0.3)); }
.bk-face.cutface::after { display: none; }
.cut-in { position: absolute; inset: 0; background: var(--paper) center / 100% 100% no-repeat; }
.cut-in::after { content: ""; position: absolute; inset: 0; pointer-events: none; }
.front > .cut-in::after { background: linear-gradient(90deg, rgba(0, 0, 0, 0.2), rgba(0, 0, 0, 0.05) 3%, transparent 10%); }
.back > .cut-in::after { background: linear-gradient(270deg, rgba(0, 0, 0, 0.2), rgba(0, 0, 0, 0.05) 3%, transparent 10%); }
.bk-nav { width: min(100% - 32px, 360px); margin: 4px auto 18px; display: flex; flex-direction: column; gap: 10px; }
.bk-rtl .bk-scrub input { scale: -1 1; }
.bk-pos { flex: 1; text-align: center; font-size: 12.5px; font-weight: 600; font-variant-numeric: tabular-nums; }
.bk-pos span { color: var(--ink-3); font-weight: 500; }
@media (max-width: 719px) {
  .bk-head { padding: 14px 18px 0; }
  .bk-sum { display: none; }
  .bk-head h1 span { display: block; margin: 8px 0 0; }
  .bk-book { width: min(100cqw - 24px, (100cqh - 24px) * 2 * var(--ar)); }
  .bk-nav { margin-bottom: 16px; }
  .gv { padding: 12px 12px 14px; gap: 12px; }
  /* On a phone the screen already is the phone: guides and sites fill it, no frame */
  .gv .phone, .sv .phone { padding: 0; border-radius: 16px; background: none; box-shadow: none; }
  .gv .phone::before, .gv .phone::after, .sv .phone::before, .sv .phone::after, .sv .phone-island { display: none; }
  .gv .phone-screen { height: auto; width: min(100cqw, (100cqh - 96px) * 9 / 16); max-width: none; aspect-ratio: 9 / 16; border-radius: 16px; box-shadow: 0 0 0 0.5px var(--hairline); }
}

/* ───────────────────────── A live site, on a phone ───────────────────────── */
.site .win-body { overflow: hidden; }
.sv { height: 100%; display: flex; align-items: center; justify-content: center; gap: 44px; padding: 22px 44px 22px 30px; container-type: size; }
/* The map's own green fills the phone edge to edge, above and below the page */
.sv .phone-screen { box-sizing: border-box; height: calc(100cqh - 64px); width: calc((100cqh - 64px) * 9 / 19.5); max-width: none; padding: 40px 0 22px; background: #002628; }
.sv .phone-island { z-index: 1; }
.sv-full { position: fixed; inset: 0; z-index: 9000; display: flex; flex-direction: column; background: #002628; }
.sv-full iframe { flex: 1; width: 100%; border: 0; }
.sv-full-bar { flex: none; display: flex; align-items: center; gap: 14px; height: 48px; padding: 0 14px; background: #001a1b; color: #e9f1ef; font-size: 13px; }
.sv-full-bar strong { font-weight: 600; opacity: 0.7; }
.sv-back { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 14px 0 10px; border: 0; border-radius: 99px; background: #e9f1ef; color: #0c1d1c; font: 600 13px var(--font); cursor: pointer; }
.sv-back svg { width: 14px; height: 14px; }
.sv-back:focus-visible { outline: 2px solid #62b6ff; outline-offset: 2px; }
.sv-esc { padding: 2px 7px; border-radius: 5px; border: 1px solid rgba(233, 241, 239, 0.3); font: 600 11px var(--font); opacity: 0.6; }
.sv iframe { display: block; width: 100%; height: 100%; border: 0; }
.sv-side { max-width: 300px; }
.sv-kind { margin: 0 0 12px; font-size: 12px; font-weight: 600; color: var(--ink-3); text-wrap: pretty; }
.sv-side h1 { margin: 0; font: 800 33px/0.95 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; text-wrap: balance; }
.sv-sum { margin: 16px 0 0; font-size: 14.5px; line-height: 1.55; color: var(--ink-2); text-wrap: pretty; }
.sv-tips { display: grid; gap: 7px; margin: 18px 0 0; padding: 0; list-style: none; font-size: 13px; color: var(--ink-2); }
.sv-tips li { display: flex; align-items: center; gap: 9px; }
.sv-tips li::before { content: ""; flex: none; width: 6px; height: 6px; border-radius: 50%; background: #62b6ff; }
.sv-btns { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px; }
.sv-btns .btn { height: 34px; }
@media (max-width: 719px) {
  .sv { flex-direction: column; gap: 12px; padding: 12px; }
  .sv-side { order: -1; max-width: none; text-align: center; }
  .sv-side h1 { font-size: 23px; }
  .sv-kind, .sv-sum, .sv-tips { display: none; }
  .sv-btns { justify-content: center; margin-top: 10px; }
  .sv .phone { width: 100%; }
  .sv .phone-screen { height: calc(100cqh - 76px); width: 100%; max-width: none; padding: 0; border-radius: 16px; box-shadow: none; }
}

/* Branding filters */
.fchips { flex: none; display: flex; gap: 6px; padding: 12px 22px 0; overflow-x: auto; scrollbar-width: none; }
.fchips[hidden] { display: none; }
.chip { flex: none; display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 12px; border: 0; border-radius: 99px; background: var(--field); color: var(--ink-2); font: 600 12.5px var(--font); cursor: pointer; transition: background-color 150ms ease, color 150ms ease, scale 120ms var(--ease-out); }
.chip span { font-size: 11px; font-weight: 600; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.chip[aria-pressed="true"] { background: var(--ink); color: var(--win-bg); }
.chip[aria-pressed="true"] span { color: color-mix(in oklch, var(--win-bg) 65%, transparent); }
.chip:active { scale: 0.96; }
@media (hover: hover) and (pointer: fine) { .chip:hover:not([aria-pressed="true"]) { background: var(--hover); color: var(--ink); } }
.case-from { display: inline-flex; align-items: center; gap: 4px; height: 32px; margin-top: 16px; }
.case-from svg { width: 13px; height: 13px; }
/* Arabic: its own face, no Latin letter-spacing, and a comfortable line height */
:lang(ar) { font-family: "IBM Plex Sans Arabic", "Geeza Pro", system-ui, sans-serif; letter-spacing: 0 !important; font-feature-settings: normal; }
.case-title :lang(ar), .tour-text strong :lang(ar), .bk-head h1 :lang(ar) { font-weight: 600; }
.case-ar { display: block; margin-top: 10px; font-size: 0.42em; font-weight: 600; line-height: 1.3; color: var(--ink-3); text-align: left; }
.case-ar:lang(ar) { unicode-bidi: isolate; }

.mv-credit { display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; padding: 3px 10px; border-radius: 99px; background: color-mix(in oklch, #8f73ff 14%, transparent); color: #6c50e6; font: 600 11.5px var(--font); }
:root[data-theme="dark"] .mv-credit { color: #bba9ff; }
.tile-collab { align-self: flex-start; margin-top: 4px; padding: 1px 7px; border-radius: 99px; background: color-mix(in oklch, #8f73ff 14%, transparent); color: #6c50e6; font: 600 10.5px var(--font); }
:root[data-theme="dark"] .tile-collab { color: #bba9ff; }
.fgrid.is-list .tile-collab { margin: 0; }
.souk-film { display: flex; align-items: center; gap: 36px; margin: 0 0 12px; }
.souk-film .phone { flex: none; }
.souk-film .phone-screen { width: min(300px, 62vw); height: auto; aspect-ratio: 9 / 16; max-width: none; background: #000; }
.souk-film video { display: block; width: 100%; height: 100%; object-fit: cover; }
.souk-film-text { max-width: 36ch; font-size: 15px; line-height: 1.55; color: var(--ink-2); }
.souk-film-text p { margin: 0 0 10px; }
@media (max-width: 719px) { .souk-film { flex-direction: column; align-items: center; } }

/* ───────────────────────── Phone: a home screen ───────────────────────── */
.ph, .ph-group { display: none; }
@media (max-width: 719px) {
  :root { --menubar-h: 44px; }
  .menubar, .desktop, .dock-wrap { display: none !important; }
  .ph { display: flex; flex-direction: column; position: fixed; inset: 0; z-index: 100; padding-bottom: env(safe-area-inset-bottom); }
  .ph-group:not([hidden]) { display: block; }
  .note, .fan { display: none; }
  .ghost-files { left: 12%; top: 40%; }
}
.ph-status {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1100; height: 44px; display: flex; align-items: center; gap: 7px; padding: 0 22px 0 30px;
  font: 600 15px/1 var(--font); font-variant-numeric: tabular-nums; letter-spacing: -0.01em; color: var(--label); pointer-events: none;
}
.ph-status svg, .ph-batt { opacity: 0.9; }
.ph-sig { width: 17px; height: 11px; fill: currentColor; }
.ph-batt { position: relative; width: 24px; height: 11.5px; border-radius: 3.5px; box-shadow: inset 0 0 0 1px currentColor; opacity: 0.5; }
.ph-batt::after { content: ""; position: absolute; right: -3px; top: 3.5px; width: 1.5px; height: 4.5px; border-radius: 0 1px 1px 0; background: currentColor; }
.ph-batt i { position: absolute; inset: 2px 5px 2px 2px; border-radius: 1.5px; background: currentColor; }
.ph-theme { pointer-events: auto; display: grid; place-items: center; width: 28px; height: 28px; margin-right: 2px; padding: 0; border: 0; border-radius: 50%; background: none; color: inherit; }
.ph-theme svg { width: 15px; height: 15px; }
.ph-theme:active { scale: 0.9; }
.ph-pages { flex: 1; min-height: 0; margin-top: 44px; display: flex; overflow-x: auto; overflow-y: hidden; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain; }
.ph-pages::-webkit-scrollbar { display: none; }
.ph-page {
  --ico: min(64px, 16.4vw);
  flex: 0 0 100%; scroll-snap-align: start; scroll-snap-stop: always; overflow-y: auto; scrollbar-width: none;
  display: grid; grid-template-columns: repeat(4, 1fr); grid-auto-rows: min-content; gap: 30px 0; align-content: start; padding: 18px 20px 20px;
}
/* Small widgets are two icons wide and two rows tall, like on the phone */
.ph-widget.ph-sq { grid-column: span 2; aspect-ratio: 1; width: calc(100% - 14px); justify-self: center; display: flex; flex-direction: column; align-items: flex-start; padding: 16px; border: 0; border-radius: 24px; text-align: left; font: inherit; }
.ph-widget.ph-wide { grid-column: 1 / -1; width: calc(100% - 14px); justify-self: center; }
.ph-me-img { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 0.5px var(--hairline); }
.ph-me-name { margin-top: auto; font: 800 18px/0.98 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; color: var(--ink); }
.ph-me-role { margin-top: 4px; font-size: 11px; line-height: 1.25; font-weight: 600; color: var(--ink-2); text-wrap: balance; }
.ph-sq .ph-avail { margin-top: 8px; font-size: 11px; }
.ph-w-label { font-size: 12px; font-weight: 700; color: #ff5b2e; text-transform: uppercase; letter-spacing: 0.03em; }
.ph-clock b { margin-top: auto; font: 800 44px/0.9 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; color: var(--ink); }
.ph-w-foot { margin-top: 8px; font-size: 11.5px; font-weight: 600; color: var(--ink-2); }
.ph-widget {
  grid-column: 1 / -1; position: relative; border-radius: 26px; padding: 18px 18px 16px; color: var(--ink);
  background: var(--widget-bg); -webkit-backdrop-filter: blur(26px) saturate(170%); backdrop-filter: blur(26px) saturate(170%);
  box-shadow: inset 0 0 0 0.5px var(--glass-edge), 0 18px 40px -22px rgba(60, 40, 90, 0.35);
}
.ph-avail { display: inline-flex; align-items: center; gap: 7px; font-size: 12px; font-weight: 600; color: var(--ink-2); }
.ph-feat h2 { margin: 0 0 12px; font: 800 18px/1 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; }
.ph-feat .feat-row { padding-top: 0; gap: 12px; }
.ph-app {
  display: flex; flex-direction: column; align-items: center; gap: 7px; min-width: 0; padding: 0; border: 0; background: none;
  color: var(--label); font: 500 12px/1.2 var(--font); letter-spacing: -0.005em; text-align: center; -webkit-tap-highlight-color: transparent; cursor: pointer;
}
.ph-app:focus-visible { outline: none; }
.ph-app:focus-visible .ph-ico { outline: 2px solid var(--accent); outline-offset: 3px; }
.ph-ico {
  position: relative; display: block; width: var(--ico, min(64px, 16.4vw)); aspect-ratio: 1; border-radius: 23%; overflow: hidden; flex: none;
  box-shadow: 0 0 0 0.5px rgba(0, 0, 0, 0.06), 0 8px 16px -10px rgba(0, 0, 0, 0.5);
  transition: scale 160ms var(--ease-out), filter 160ms ease;
}
.ph-app:active .ph-ico { scale: 0.92; filter: brightness(0.9); }
/* Holding an icon puts the home screen in edit mode for a moment (easter egg) */
.ph, .ph-group { -webkit-touch-callout: none; -webkit-user-select: none; user-select: none; }
.ph-app { position: relative; --jig: 1.6deg; }
.ph-widget { --jig: 0.7deg; }
.ph.is-jiggling .ph-app, .ph.is-jiggling .ph-widget { animation: ph-jiggle 0.26s ease-in-out infinite alternate; }
.ph.is-jiggling .ph-app:nth-child(2n), .ph.is-jiggling .ph-widget:nth-child(2n) { animation-duration: 0.3s; animation-direction: alternate-reverse; }
.ph.is-jiggling .ph-app:nth-child(3n) { animation-delay: -0.12s; }
@keyframes ph-jiggle { from { rotate: calc(var(--jig) * -1); } to { rotate: var(--jig); } }
.ph.is-jiggling .ph-app::before, .ph.is-jiggling .ph-widget::before {
  content: ""; position: absolute; z-index: 3; top: -7px; left: calc(50% - var(--ico, 64px) / 2 - 7px); width: 22px; height: 22px; border-radius: 50%;
  background: linear-gradient(#fff, #fff) center / 9px 2px no-repeat, rgba(78, 78, 82, 0.78);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}
.ph.is-jiggling .ph-widget::before { left: -7px; }
.ph-done { pointer-events: auto; height: 28px; padding: 0 14px; border: 0; border-radius: 99px; background: var(--chrome); color: var(--ink); font: 600 14px/1 var(--font); -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px); }
.ph-done[hidden], .ph.is-jiggling .ph-theme, .ph.is-jiggling .ph-sig, .ph.is-jiggling .ph-batt { display: none; }
@media (prefers-reduced-motion: reduce) { .ph.is-jiggling .ph-app, .ph.is-jiggling .ph-widget { animation: none; } }
.ph-ico > img { display: block; width: 100%; height: 100%; object-fit: cover; }
.ph-label { max-width: calc(var(--ico, 64px) + 18px); text-shadow: var(--label-shadow); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* A folder is a group: a frosted tile with a 3 × 3 preview of what's inside */
.ph-folder {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 8%; align-content: start; padding: 14%;
  background: rgba(255, 255, 255, 0.3); -webkit-backdrop-filter: blur(18px) saturate(160%); backdrop-filter: blur(18px) saturate(160%);
  box-shadow: inset 0 0 0 0.5px rgba(255, 255, 255, 0.6), 0 8px 16px -10px rgba(0, 0, 0, 0.45);
}
:root[data-theme="dark"] .ph-folder { background: color-mix(in srgb, var(--c1, #444) 45%, rgba(40, 40, 42, 0.55)); box-shadow: inset 0 0 0 0.5px rgba(255, 255, 255, 0.14), 0 8px 16px -10px rgba(0, 0, 0, 0.6); }
.ph-spr { display: block; width: 100%; height: 100%; background: url(../../work/icons-f2.webp) 0 0 / 800% 600% no-repeat; }
.ph-folder .ph-spr { height: auto; aspect-ratio: 1; border-radius: 24%; box-shadow: 0 1px 2px rgba(0, 0, 0, 0.18); }
.ph-obj { display: grid; place-items: center; background: linear-gradient(165deg, #ffffff, #ebe9e4); }
:root[data-theme="dark"] .ph-obj { background: linear-gradient(165deg, #2f2f31, #1b1b1d); }
.ph-obj .dock-icon { width: 76%; height: 76%; }
.ph-dots { display: flex; justify-content: center; gap: 8px; padding: 6px 0 10px; }
.ph-dots i, .phg-dots i { width: 6px; height: 6px; border-radius: 50%; background: var(--label); opacity: 0.32; transition: opacity 200ms ease; }
.ph-dots i.on, .phg-dots i.on { opacity: 0.9; }
.ph-dock {
  --ico: min(64px, 16.4vw);
  display: grid; grid-template-columns: repeat(4, 1fr); justify-items: center; gap: 8px; margin: 0 10px 10px; padding: 16px 10px;
  border-radius: 32px; background: var(--chrome); -webkit-backdrop-filter: blur(30px) saturate(180%); backdrop-filter: blur(30px) saturate(180%);
  box-shadow: inset 0 0 0 0.5px var(--glass-edge), 0 12px 30px -14px rgba(0, 0, 0, 0.35);
}
.ph-dock .ph-label { display: none; }
/* An open group */
.ph-group { position: fixed; inset: 0; z-index: 150; }
.phg-scrim { position: absolute; inset: 0; background: rgba(28, 24, 36, 0.22); -webkit-backdrop-filter: blur(24px) saturate(150%); backdrop-filter: blur(24px) saturate(150%); }
:root[data-theme="dark"] .phg-scrim { background: rgba(0, 0, 0, 0.4); }
.phg { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px; padding: 44px 0 40px; pointer-events: none; }
.phg-title { margin: 0; padding: 0 28px; font: 800 25px/1.05 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; text-align: center; color: #fff; text-shadow: 0 1px 14px rgba(0, 0, 0, 0.28); }
.phg-panel {
  pointer-events: auto; width: min(86vw, 344px); padding: 22px 12px 12px; border-radius: 38px;
  background: rgba(255, 255, 255, 0.5); -webkit-backdrop-filter: blur(30px) saturate(170%); backdrop-filter: blur(30px) saturate(170%);
  box-shadow: inset 0 0 0 0.5px rgba(255, 255, 255, 0.6), 0 30px 60px -30px rgba(0, 0, 0, 0.55);
}
:root[data-theme="dark"] .phg-panel { background: rgba(48, 48, 50, 0.6); box-shadow: inset 0 0 0 0.5px rgba(255, 255, 255, 0.12), 0 30px 60px -30px rgba(0, 0, 0, 0.8); }
.phg-pages { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain; }
.phg-pages::-webkit-scrollbar { display: none; }
.phg-page { flex: 0 0 100%; scroll-snap-align: start; display: grid; grid-template-columns: repeat(3, 1fr); grid-auto-rows: min-content; gap: 18px 4px; align-content: start; min-height: 312px; }
.phg .ph-app { color: var(--ink); }
.phg .ph-label { text-shadow: none; }
.phg-dots { display: flex; justify-content: center; gap: 8px; padding-top: 10px; }
.phg-dots i { background: var(--ink); }

/* ───────────────────────── Phone: wallpaper and glass ───────────────────────── */
/* The phone has its own full-bleed wallpapers, built from the portfolio's palette, and every surface on it is glass */
.ph, .ph-group { --glass: rgba(255, 255, 255, 0.2); --glass-hi: rgba(255, 255, 255, 0.5); --glass-lo: rgba(255, 255, 255, 0.08); --on-glass: #fff; }
:root[data-theme="dark"] :is(.ph, .ph-group) { --glass: rgba(255, 255, 255, 0.1); --glass-hi: rgba(255, 255, 255, 0.28); --glass-lo: rgba(255, 255, 255, 0.04); }
.ph-bg { position: absolute; inset: 0; z-index: -1; transition: opacity 600ms ease; filter: saturate(0.58) brightness(0.9) contrast(0.94); }  /* softened: easy on the eyes */
.ph-bg::after { content: ""; position: absolute; inset: 0; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .07 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); mix-blend-mode: overlay; }
.ph-bg[data-pw="bloom"] { background:
  radial-gradient(120% 70% at 10% 8%, #ff9a5c 0%, transparent 55%),
  radial-gradient(90% 60% at 95% 30%, #8f73ff 0%, transparent 60%),
  radial-gradient(110% 70% at 20% 75%, #ff5d8f 0%, transparent 60%),
  radial-gradient(90% 60% at 90% 95%, #4b5bff 0%, transparent 60%),
  linear-gradient(170deg, #ff8a5b, #b36cff 55%, #4f5dff); }
.ph-bg[data-pw="dune"] { background:
  radial-gradient(120% 70% at 20% 0%, #ffd9b0 0%, transparent 55%),
  radial-gradient(110% 70% at 100% 45%, #e0703f 0%, transparent 60%),
  radial-gradient(120% 80% at 0% 90%, #b8452b 0%, transparent 60%),
  linear-gradient(175deg, #f4b98a, #d9653a 55%, #7d2f22); }
.ph-bg[data-pw="tide"] { background:
  radial-gradient(120% 70% at 15% 5%, #9fe7d0 0%, transparent 55%),
  radial-gradient(100% 70% at 100% 40%, #3a92e6 0%, transparent 60%),
  radial-gradient(120% 80% at 0% 95%, #1d3f8f 0%, transparent 60%),
  linear-gradient(170deg, #6fd3b8, #2f7fd6 55%, #1a2a6e); }
:root[data-theme="dark"] .ph-bg { filter: brightness(0.42) saturate(0.85); }
@media (max-width: 719px) {
  .walls { display: none; }
  body { background: #111; }
}
/* Labels and chrome: white on the wallpaper, with a soft shadow */
.ph .ph-app, .ph-status, .ph .ph-label { color: var(--on-glass); }
.ph .ph-label { text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35), 0 0 8px rgba(0, 0, 0, 0.12); }
.ph-dots i { background: #fff; }
/* Glass: a translucent pane, a bright rim on the lit edge, a soft shadow */
.ph .ph-widget, .ph .ph-folder, .ph-dock, .phg-panel {
  background: linear-gradient(160deg, var(--glass-hi) -40%, var(--glass) 40%, var(--glass-lo) 130%);
  -webkit-backdrop-filter: blur(28px) saturate(180%); backdrop-filter: blur(28px) saturate(180%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.45), inset 0 0 0 0.5px rgba(255, 255, 255, 0.35), 0 10px 30px -14px rgba(20, 10, 40, 0.45);
}
.ph .ph-widget { color: #fff; }
.ph .ph-me-name, .ph .ph-clock b { color: #fff; }
.ph .ph-me-role, .ph .ph-w-foot, .ph .ph-avail { color: rgba(255, 255, 255, 0.82); }
.ph .ph-w-label { color: #fff; opacity: 0.9; }
.ph .ph-me-img { box-shadow: 0 0 0 1.5px rgba(255, 255, 255, 0.6); }
.ph .ph-feat h2, .ph .feat span { color: #fff; }
.ph-dock { border-radius: 34px; }
.phg-scrim { background: rgba(10, 6, 20, 0.12); -webkit-backdrop-filter: blur(30px) saturate(160%); backdrop-filter: blur(30px) saturate(160%); }
.phg-panel { --glass: rgba(255, 255, 255, 0.22); }
.phg .ph-app, .phg .ph-label { color: #fff; }
.phg .ph-label { text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3); }
.phg-dots i { background: #fff; }
.phg { isolation: isolate; }

/* Messages from Hind: an iMessage-style notification */
.toast.msg { width: 100%; grid-template-columns: 40px 1fr; align-items: start; padding: 11px 14px 12px 11px; border: 0; text-align: left; color: var(--ink); font: inherit; cursor: pointer; }
.toast.msg:active { scale: 0.98; }
.msg-av { position: relative; width: 40px; height: 40px; }
.msg-av img { display: block; width: 40px; height: 40px; border-radius: 50%; object-fit: cover; }
.msg-av i { position: absolute; right: -3px; bottom: -3px; width: 19px; height: 19px; border-radius: 6px; display: grid; place-items: center; background: linear-gradient(#5ff777, #0fc135); box-shadow: 0 0 0 2px var(--menu-bg); }
.msg-av svg { width: 12px; height: 12px; fill: #fff; }
.msg-top { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.msg-top em { font-style: normal; font-size: 12px; color: var(--ink-3); }
.toast.msg .toast-text > span:last-child { margin-top: 1px; font-size: 13.5px; line-height: 1.35; color: var(--ink); }
@media (max-width: 719px) {
  .toasts { top: 8px; left: 8px; right: 8px; z-index: 1200; }
  .toast.msg { border-radius: 22px; padding: 12px 14px 13px 12px; }
}

/* The name widget is the one solid object on the home screen: warm paper, the signature type */
.ph .ph-widget.ph-me { background: #fbf7f0; -webkit-backdrop-filter: none; backdrop-filter: none; color: #141312; box-shadow: 0 1px 0 rgba(255, 255, 255, 0.8) inset, 0 16px 34px -16px rgba(20, 10, 40, 0.5); padding: 15px 15px 14px; }
:root[data-theme="dark"] .ph .ph-widget.ph-me { background: #161514; color: #f3eee6; box-shadow: inset 0 0 0 0.5px rgba(243, 238, 230, 0.14), 0 16px 34px -16px rgba(0, 0, 0, 0.7); }
.ph-me-top { display: flex; align-items: center; width: 100%; }
.ph .ph-me-img { width: 42px; height: 42px; box-shadow: 0 0 0 2px #fbf7f0, 0 0 0 3px rgba(20, 19, 18, 0.12); }
.ph-me-star { display: grid; place-items: center; width: 22px; height: 22px; margin-left: -9px; align-self: flex-end; border-radius: 50%; background: #8f73ff; box-shadow: 0 0 0 2px #fbf7f0; }
.ph-me-star svg { width: 13px; height: 13px; fill: #fff; }
:root[data-theme="dark"] .ph-me-star { box-shadow: 0 0 0 2px #161514; }
.ph-me-open { margin-left: auto; display: inline-flex; align-items: center; gap: 5px; padding: 4px 8px 4px 7px; border-radius: 99px; background: rgba(46, 160, 67, 0.12); color: #1d7a34; font-size: 10.5px; font-weight: 700; }
:root[data-theme="dark"] .ph-me-open { background: rgba(80, 200, 110, 0.14); color: #7fe09a; }
.ph .ph-me-name { margin-top: auto; font: 800 27px/0.9 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; color: inherit; }
.ph .ph-me-name em { display: block; font-style: normal; font-weight: 300; letter-spacing: -0.02em; }
.ph .ph-me-role { margin-top: 7px; font-size: 11px; font-weight: 600; color: inherit; opacity: 0.62; }

/* The strategy: what the brand answers to, before the visuals */
.strat { margin: 22px 0 30px; padding: 26px 0 28px; border-top: 1px solid var(--win-line); border-bottom: 1px solid var(--win-line); }
.strat-eye { margin: 0; font-size: 11.5px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent); }
.strat-head { margin: 10px 0 0; font: 800 clamp(23px, 2.7vw, 33px)/1.08 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; max-width: 24ch; text-wrap: balance; }
.strat-grid { display: grid; grid-template-columns: repeat(var(--n, 3), minmax(0, 1fr)); gap: 18px 28px; margin: 24px 0 0; }
.strat-grid dt { font-size: 11.5px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); }
.strat-grid dd { margin: 7px 0 0; font-size: 14.5px; line-height: 1.55; color: var(--ink-2); text-wrap: pretty; max-width: 62ch; }
.strat-profile { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 22px 40px; margin-top: 26px; padding-top: 22px; border-top: 1px dashed var(--win-line); }
.strat-profile.solo { grid-template-columns: minmax(0, 1fr); }
.strat-profile h3 { margin: 0 0 12px; font-size: 11.5px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); }
.vals { display: flex; flex-wrap: wrap; gap: 7px; margin: 0; padding: 0; list-style: none; }
.vals li { padding: 6px 11px; border-radius: 99px; background: var(--field); font-size: 13px; font-weight: 600; color: var(--ink); }
.scale { display: grid; gap: 13px; margin: 0; padding: 0; list-style: none; }
.scale li { display: grid; grid-template-columns: 92px minmax(0, 1fr) 92px; align-items: center; gap: 12px; font-size: 12px; font-weight: 600; color: var(--ink-2); }
.scale li span:last-child { text-align: right; }
.scale i { position: relative; height: 1px; background: var(--win-line); }
.scale i::after { content: ""; position: absolute; top: 50%; left: calc(var(--v) * 100%); width: 11px; height: 11px; border-radius: 50%; background: var(--ink); translate: -50% -50%; box-shadow: 0 0 0 3px var(--win-bg, transparent); }
.strat-src { margin: 20px 0 0; font-size: 12px; color: var(--ink-3); }
@media (max-width: 719px) {
  .strat-grid, .strat-profile { grid-template-columns: minmax(0, 1fr); }
  .scale li { grid-template-columns: 78px minmax(0, 1fr) 78px; }
}
/* About: how I work */
.how { display: grid; gap: 14px; margin: 4px 0 20px; padding: 0; list-style: none; counter-reset: how; }
.how li { position: relative; display: grid; gap: 3px; padding-left: 36px; counter-increment: how; }
.how li::before { content: counter(how); position: absolute; left: 0; top: 1px; width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-size: 12px; font-weight: 700; color: var(--win-bg); background: var(--accent); }
.how b { font-size: 15px; }
.how span { font-size: 14px; line-height: 1.5; color: var(--ink-2); }
.how-see { justify-self: start; margin-top: 2px; padding: 0; border: 0; background: none; font: inherit; font-size: 12.5px; font-weight: 600; color: var(--accent); cursor: pointer; }
.how-see:hover { text-decoration: underline; }
.about-aside { font-style: italic; color: var(--ink-3); }

/* ───────────────────────── Motion ───────────────────────── */
.motion-win .win-body { overflow: hidden; }
.mv { height: 100%; display: flex; flex-direction: column; }
.mv-stage { flex: 1; min-height: 0; display: grid; place-items: center; padding: 20px 24px 0; }
.mv-stage video { display: block; max-width: 100%; max-height: 100%; border-radius: 10px; background: #fff; box-shadow: 0 0 0 0.5px var(--hairline), 0 24px 44px -24px rgba(20, 16, 40, 0.45); }
.mv-foot { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 24px 20px; }
.mv-foot h1 { margin: 0; font: 800 19px/1.05 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; }
.mv-foot p { margin: 5px 0 0; font-size: 12px; font-weight: 600; color: var(--ink-3); }
.mv-foot .btn { display: inline-flex; align-items: center; gap: 4px; height: 34px; }
.mv-foot .btn svg { width: 13px; height: 13px; }

/* ───────────────────────── Presentations ───────────────────────── */
.deck .win-body { overflow: hidden; }
.dk { height: 100%; display: grid; grid-template-rows: auto minmax(0, 1fr) auto; grid-template-columns: minmax(0, 1fr); }
.dk-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 8px 32px; padding: 20px var(--dk-pad, 28px) 14px; }
.dk-head h1 { margin: 0; font: 800 23px/1 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; }
.dk-head div p { margin: 7px 0 0; font-size: 12px; font-weight: 600; color: var(--ink-3); }
.dk-sum { flex: 1 1 100%; max-width: 72ch; margin: 0; font-size: 13px; line-height: 1.5; color: var(--ink-2); text-wrap: pretty; }
.dk-stage { min-height: 0; display: grid; place-items: center; padding: 0 28px; container-type: size; }
.dk-slide {
  position: relative; width: min(100cqw, 100cqh * 16 / 9); aspect-ratio: 16 / 9; border-radius: 10px; overflow: hidden; cursor: pointer; background: #fff;
  box-shadow: 0 0 0 0.5px var(--hairline), 0 26px 50px -26px rgba(20, 16, 40, 0.5);
}
.dk-slide > img, .dk-slide > video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; display: block; }
.dk-slide.is-live::after {
  content: "Animated"; position: absolute; top: 12px; left: 12px; z-index: 1; display: flex; align-items: center; gap: 6px; height: 22px; padding: 0 9px 0 22px;
  border-radius: 99px; background: rgba(20, 19, 18, 0.72); color: #fff; font: 600 11px var(--font); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.dk-slide.is-live::before { content: ""; position: absolute; top: 20px; left: 21px; z-index: 2; width: 6px; height: 6px; border-radius: 50%; background: #ff6b4a; animation: livePulse 1.6s ease-in-out infinite; }
@keyframes livePulse { 50% { opacity: 0.3; } }
.dk-foot { display: flex; flex-direction: column; gap: 10px; padding: 14px var(--dk-pad, 28px) 16px; }
.dk-strip { display: flex; align-items: center; gap: 8px; overflow-x: auto; padding: 4px 4px 8px; margin: 0 -4px; scrollbar-width: thin; }
.dk-sep { flex: none; width: 52px; padding: 0 2px 0 10px; font-size: 10.5px; font-weight: 700; line-height: 1.2; letter-spacing: 0.04em; text-transform: uppercase; text-align: right; color: var(--ink-3); }
.dk-sep:first-child { padding-left: 0; }
.dk-thumb { position: relative; flex: none; width: 104px; aspect-ratio: 16 / 9; padding: 0; border: 0; border-radius: 6px; overflow: hidden; background: var(--field); opacity: 0.62; box-shadow: 0 0 0 1px var(--hairline); transition: opacity 160ms ease, box-shadow 160ms ease, scale 120ms var(--ease-out); cursor: pointer; }
.dk-thumb img { display: block; width: 100%; height: 100%; object-fit: contain; }
.dk-thumb i { position: absolute; right: 5px; bottom: 5px; width: 14px; height: 14px; border-radius: 50%; background: rgba(20, 19, 18, 0.75); }
.dk-thumb i::after { content: ""; position: absolute; left: 5px; top: 4px; border: 3px solid transparent; border-left: 5px solid #fff; }
.dk-thumb[aria-current="true"] { opacity: 1; box-shadow: 0 0 0 2px var(--win-bg), 0 0 0 4px var(--accent); }
.dk-thumb:active { scale: 0.96; }
@media (hover: hover) and (pointer: fine) { .dk-thumb:hover { opacity: 1; } }
.dk-bar { display: flex; align-items: center; gap: 8px; }
.dk-note { font-size: 12px; font-weight: 600; color: var(--ink-3); }
.dk-pos { min-width: 56px; text-align: center; font-size: 12.5px; font-variant-numeric: tabular-nums; color: var(--ink-2); }
.fb-film { position: relative; aspect-ratio: 16 / 9; margin: 0 0 10px; border-radius: 10px; overflow: hidden; background: #111; }
.fb-film iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.fb-link a { color: var(--accent); font-weight: 600; }
@media (max-width: 719px) {
  .dk-sum, .dk-note { display: none; }
  .dk-foot { padding-bottom: 16px; }
  .mv-foot { padding-bottom: 16px; }
}

/* ───────────────────────── Trash: also found in here ───────────────────────── */
.fun { padding: 2px 0 30px; }
.fun-lede { margin: 0 0 16px; font-size: 12px; font-weight: 600; color: var(--ink-3); }
.fun-row { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 26px 30px; padding: 6px 0 0; }
.scrap {
  position: relative; flex: none; padding: 0; border: 0; background: none; text-align: left; color: #2b2a28; cursor: pointer;
  rotate: var(--r, 0deg); filter: drop-shadow(0 10px 12px rgba(20, 16, 40, 0.18)) drop-shadow(0 1px 1px rgba(0, 0, 0, 0.12));
  transition: rotate 560ms var(--ease-out), scale 160ms var(--ease-out), translate 560ms var(--ease-out);
}
.scrap-in { display: block; filter: url(#crumple); }
.scrap.flat { rotate: calc(var(--r, 0deg) * 0.2); translate: 0 -4px; }
.scrap.flat .scrap-in { filter: none; animation: smoothOut 460ms var(--ease-out); }
@keyframes smoothOut { from { scale: 0.93; } }
.scrap:active { scale: 0.97; }
@media (hover: hover) and (pointer: fine) { .scrap:hover { scale: 1.03; } }
.scrap:focus-visible { outline: 2px solid var(--accent); outline-offset: 6px; border-radius: 4px; }
.s-list .scrap-in {
  width: 196px; padding: 16px 18px 18px 30px; font: 600 19px/26px "Caveat", "Bradley Hand", cursive;
  background: repeating-linear-gradient(#fdf6d9 0 25px, #cfdcf2 25px 26px) 0 12px / 100% 100% #fdf6d9;
  box-shadow: inset 22px 0 0 -21px #eaa2a2;
}
.s-list b { display: block; margin-bottom: 2px; font-size: 23px; font-weight: 700; }
.s-list ul { margin: 0; padding: 0; list-style: none; }
.s-list s { text-decoration-thickness: 2px; opacity: 0.6; }
.s-list i { font-style: normal; opacity: 0.6; }
.s-mail .scrap-in { width: 262px; padding: 14px 16px 16px; background: #fff; font: 12px/1.45 var(--font); }
.s-mail .m-top { display: flex; justify-content: space-between; margin-bottom: 8px; font-size: 10.5px; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; color: #b3413a; }
.s-mail .m-row { display: block; padding: 5px 0; border-bottom: 1px solid #ecebe8; color: #2b2a28; }
.s-mail .m-row em { font-style: normal; color: #9a999e; margin-right: 6px; }
.s-mail .m-body { display: block; padding-top: 10px; color: #3c3b39; }
.s-receipt .scrap-in {
  width: 212px; padding: 16px 14px 22px; background: #fbfbf8; font: 500 10.5px/1.55 ui-monospace, "SF Mono", Menlo, monospace; text-transform: uppercase;
  -webkit-mask: conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) 50% / 10px 100%;
  mask: conic-gradient(from -45deg at bottom, #0000, #000 1deg 89deg, #0000 90deg) 50% / 10px 100%;
}
.s-receipt .r-c { display: block; text-align: center; }
.s-receipt .r-h { font-weight: 700; font-size: 13px; letter-spacing: 0.08em; }
.s-receipt .r-l { display: flex; justify-content: space-between; gap: 6px; }
.s-receipt .r-l span:first-child { overflow: hidden; }
.s-receipt .r-n { display: block; padding-left: 10px; opacity: 0.6; text-transform: none; }
.s-receipt hr { margin: 7px 0; border: 0; border-top: 1px dashed #b8b7bc; }
.s-receipt .r-t { font-weight: 700; }
.s-sticky .scrap-in { width: 158px; height: 150px; padding: 18px 16px; background: linear-gradient(170deg, #ffd0e0, #ffc0d4); font: 700 24px/1.05 "Caveat", "Bradley Hand", cursive; }
.s-sticky svg { display: block; width: 70px; margin: 10px 0 0 auto; }
.s-font { width: 104px; text-align: center; }
.s-font .scrap-in { filter: none; }
.s-font svg { display: block; width: 72px; margin: 0 auto; }
.s-font strong { display: block; margin-top: 6px; font: 600 12px var(--font); color: var(--ink); }
.s-font small { display: inline-block; margin-top: 4px; padding: 2px 7px; border-radius: 99px; background: #e2483d; color: #fff; font: 700 9.5px var(--font); letter-spacing: 0.06em; text-transform: uppercase; }
.s-font.nope { animation: nope 420ms var(--ease-out); }
@keyframes nope { 20% { translate: -6px 0; } 40% { translate: 5px 0; } 60% { translate: -3px 0; } 80% { translate: 2px 0; } }
.trash-sub { margin: 0; padding-top: 22px; border-top: 1px solid var(--win-line); }
.trash-sub h2 { margin: 0; font: 800 26px/1 var(--serif); font-stretch: 110%; letter-spacing: -0.02em; }
.trash-sub p { margin: 10px 0 4px; font-size: 14px; line-height: 1.55; color: var(--ink-2); max-width: 58ch; }
.case-loop { aspect-ratio: 16 / 9; object-fit: contain; background: #fff; }

@media (max-width: 719px) {
  .w-feat { display: none; }
  .sel-strip { display: block; margin-top: 22px; }
  .sel-strip h2 { margin: 0 0 10px; font-size: 13px; font-weight: 600; color: var(--label); text-shadow: var(--label-shadow); }
  .sel-scroll { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: 16px; margin: 0 -16px; padding: 0 16px 6px; scrollbar-width: none; }
  .sel-card { flex: none; width: 76%; scroll-snap-align: start; padding: 0; border: 0; background: none; text-align: left; color: var(--label); text-shadow: var(--label-shadow); display: flex; flex-direction: column; gap: 3px; }
  .sel-card img { width: 100%; height: auto; aspect-ratio: 16 / 10; object-fit: cover; border-radius: 12px; margin-bottom: 6px; box-shadow: 0 12px 26px -14px rgba(0, 0, 0, 0.5); }
  .sel-card strong { font-size: 15px; }
  .sel-card span { font-size: 12px; opacity: 0.85; }
  .case { --gut: 16px; }
  .case-head { padding: 26px var(--gut) 16px; }
  .case-bar { padding-left: var(--gut); padding-right: var(--gut); }
  .grid2, .pair, .decision, .facts { grid-template-columns: 1fr; }
  .mb-seg button { padding: 0 7px; }
  .tour-inner { padding: 26px 18px 40px; }
  .tour-row { grid-template-columns: 1fr; gap: 12px; }
  .ql-pos { display: none; }
}

/* ───────────────────────── Preferences ───────────────────────── */
@media (prefers-reduced-transparency: reduce) {
  .menubar, .menu, .widget, .sb, .dock::before, .toast, .dock-label { -webkit-backdrop-filter: none; backdrop-filter: none; }
  :root { --chrome: #f3f0eb; --menu-bg: #f7f5f1; --widget-bg: #fbf8f3; --win-side: #eeebe6; }
  :root[data-theme="dark"] { --chrome: #232121; --menu-bg: #2b2929; --widget-bg: #242221; --win-side: #2a2828; }
}
@media (prefers-reduced-motion: reduce) {
  .wall { transition-duration: 200ms; }
  .icon.is-settling, .win.is-zooming, .win.is-settling { transition: none; }
  .w-clock .sec { transition: none; }
}
@media (prefers-contrast: more) {
  :root { --ink-2: rgba(29, 29, 31, 0.85); --ink-3: rgba(29, 29, 31, 0.72); --hairline: rgba(0, 0, 0, 0.35); }
}
