/* ============================================================
   DIRTY BACON · DB-OS 3.1
   a production house shipped as a Mac-grade operating system
   Apple system palette · SF stack · Instrument Serif · Plex Mono
   ============================================================ */

:root {
  --ink: #0b0b0d;
  --glass: rgba(19, 19, 21, 0.68);
  --glass-hi: rgba(27, 27, 30, 0.8);
  --text: #f5f5f7;
  --text-dim: #a1a1a6;
  --mute: #7d7d82;
  --blue: #e8342a;
  --blue-soft: rgba(232, 52, 42, 0.16);
  --link: #ff453a;
  --green: #30d158;
  --orange: #9a9aa0;
  --red: #ff453a;
  --teal: #ff6b61;
  --line: rgba(255, 255, 255, 0.10);
  --line-strong: rgba(255, 255, 255, 0.17);
  --paper: #ffffff;
  --paper-2: #f5f5f7;
  --paper-ink: #1d1d1f;
  --paper-dim: #6e6e73;
  --paper-cap: #86868b;
  --paper-line: rgba(0, 0, 0, 0.12);
  --tl-red: #ff5f57;
  --tl-yellow: #febc2e;
  --tl-green: #28c840;
  --r-win: 12px;
  --shadow-win: 0 0 0 0.5px rgba(0,0,0,0.55), 0 18px 55px rgba(0, 0, 0, 0.5), 0 3px 14px rgba(0, 0, 0, 0.35);
  --shadow-active: 0 0 0 0.5px rgba(0,0,0,0.6), 0 30px 85px rgba(0, 0, 0, 0.62), 0 5px 20px rgba(0, 0, 0, 0.45);
  --ui: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Helvetica Neue", "Segoe UI", Roboto, sans-serif;
  --serif: "Instrument Serif", Georgia, serif;
  --mono: "IBM Plex Mono", "SF Mono", monospace;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html, body { height: 100%; }

body {
  font-family: var(--ui);
  font-size: 13px;
  background: var(--ink);
  color: var(--text);
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}

button { font: inherit; color: inherit; background: none; border: none; cursor: default; }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
a[href], button[data-open], button[data-act], .doclink, #reel-toggle, #empty-trash { cursor: pointer; }

.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

::selection { background: var(--blue); color: #fff; }

/* ============ BOOT ============ */
#boot {
  position: fixed; inset: 0; z-index: 500;
  background: #000;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 34px;
  transition: opacity 0.5s ease;
}
#boot.gone { opacity: 0; pointer-events: none; }
.boot-mark { position: relative; width: 70px; height: 70px; }
.boot-mark span {
  position: absolute; inset: 0; border-radius: 50%;
  border: 8px solid var(--red);
  animation: bootpulse 1.1s ease-in-out infinite;
}
@keyframes bootpulse { 50% { transform: scale(0.88); opacity: 0.55; } }
#boot-log {
  font-family: var(--mono); font-size: 11px; line-height: 1.9;
  color: var(--mute); letter-spacing: 0.05em;
  min-height: 168px; width: min(430px, 82vw);
}
#boot-log .ok { color: var(--green); }
#boot-log .acc { color: var(--teal); }
.boot-bar { width: min(300px, 70vw); height: 4px; background: rgba(255,255,255,0.18); border-radius: 4px; overflow: hidden; }
.boot-bar i { display: block; height: 100%; width: 0; background: #f5f5f7; border-radius: 4px; transition: width 0.25s ease; }

/* ============ WALLPAPER ============ */
#wallpaper { position: fixed; inset: 0; z-index: 0; overflow: hidden; background: #000; }
.wp {
  position: absolute; inset: -4%;
  width: 108%; height: 108%; object-fit: cover;
  transition: opacity 1s ease;
  animation: wpdrift 45s ease-in-out infinite alternate;
}
.wp.b { opacity: 0; }
@keyframes wpdrift { from { transform: scale(1) translateY(0); } to { transform: scale(1.045) translateY(-1%); } }
.wp-shade {
  position: absolute; inset: 0;
  background:
    radial-gradient(130% 100% at 50% 40%, transparent 45%, rgba(0, 0, 0, 0.5) 100%),
    linear-gradient(to bottom, rgba(0, 0, 0, 0.45), transparent 16%),
    linear-gradient(to top, rgba(0, 0, 0, 0.4), transparent 20%);
}
.wp-credit {
  position: absolute; right: 16px; bottom: 12px;
  font-family: var(--mono); font-size: 9px; letter-spacing: 0.22em;
  color: rgba(245, 245, 247, 0.55);
  text-shadow: 0 1px 4px rgba(0,0,0,0.6);
}
#grain { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 300; pointer-events: none; opacity: 0.34; mix-blend-mode: overlay; }
body.no-grain #grain { display: none; }

/* ============ MENU BAR ============ */
#menubar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 200;
  height: 30px;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 12px 0 8px;
  background: rgba(22, 22, 24, 0.45);
  backdrop-filter: blur(26px) saturate(1.6);
  -webkit-backdrop-filter: blur(26px) saturate(1.6);
  border-bottom: 0.5px solid rgba(0, 0, 0, 0.4);
  font-size: 13px;
}
.mb-left, .mb-right { display: flex; align-items: center; gap: 2px; height: 100%; }
.mb-logo { display: inline-flex; align-items: center; padding: 0 10px; height: 100%; }
.mb-logo i { width: 14px; height: 14px; border-radius: 50%; border: 3.5px solid var(--red); display: inline-block; }
.mb-name { font-weight: 700; padding: 0 10px; height: 100%; letter-spacing: 0.01em; }
.mb-item { padding: 0 10px; height: 100%; color: var(--text); font-weight: 400; }
.mb-logo:hover, .mb-item:hover, .mb-name:hover, .mb-item.on, .mb-name.on, .mb-logo.on { background: rgba(255, 255, 255, 0.14); }
.mb-right { gap: 14px; font-size: 12px; color: var(--text); }
.mb-rec { display: inline-flex; align-items: center; gap: 5px; color: var(--red); font-family: var(--mono); font-size: 10px; letter-spacing: 0.12em; }
.mb-rec i { width: 7px; height: 7px; border-radius: 50%; background: var(--red); animation: blink 1.2s steps(2) infinite; }
@keyframes blink { 50% { opacity: 0.15; } }
.mb-soul { font-family: var(--mono); font-size: 10px; letter-spacing: 0.12em; color: var(--text-dim); }
.mb-clock { font-variant-numeric: tabular-nums; font-weight: 500; }

/* dropdown menus */
.menu {
  position: absolute; top: 34px; left: 8px;
  min-width: 240px;
  background: var(--glass-hi);
  backdrop-filter: blur(30px) saturate(1.7);
  -webkit-backdrop-filter: blur(30px) saturate(1.7);
  border: 0.5px solid var(--line-strong);
  border-radius: 10px;
  padding: 5px;
  box-shadow: 0 0 0 0.5px rgba(0,0,0,.5), 0 16px 46px rgba(0, 0, 0, 0.5);
  display: none;
  flex-direction: column;
}
.menu.open { display: flex; animation: menuin 0.14s ease; }
@keyframes menuin { from { opacity: 0; transform: translateY(-4px); } }
.menu button, .menu a {
  text-align: left; padding: 5px 10px; border-radius: 6px;
  font-size: 13px; color: var(--text);
  display: flex; align-items: center; justify-content: space-between; gap: 20px;
  cursor: default;
}
.menu button:hover, .menu a:hover { background: var(--blue); color: #fff; }
.menu .kbd { font-size: 12px; color: var(--mute); }
.menu button:hover .kbd { color: rgba(255,255,255,0.75); }
.msep { height: 1px; background: var(--line); margin: 4px 10px; }
#menu-special { left: 172px; }
#menu-help { left: 232px; }

/* ============ DESKTOP ============ */
#desktop { position: fixed; inset: 30px 0 0 0; z-index: 10; }

/* icons */
#icons {
  position: absolute; top: 18px; right: 14px;
  display: flex; flex-direction: column; gap: 4px;
  z-index: 5;
}
.dicon {
  display: flex; flex-direction: column; align-items: center; gap: 5px;
  width: 106px; padding: 9px 4px 7px;
  border-radius: 8px;
  font-family: var(--ui); font-size: 10.5px; font-weight: 500; letter-spacing: 0.01em;
  line-height: 1.25;
  color: #fff;
  text-shadow: 0 1px 5px rgba(0, 0, 0, 0.85), 0 0 2px rgba(0,0,0,0.6);
  max-width: 106px; overflow-wrap: anywhere; text-align: center;
}
.dicon:hover { background: rgba(255, 255, 255, 0.13); }
.dicon:active { background: rgba(255, 255, 255, 0.22); }

/* ============ ICONS ============ */
.ic { width: 44px; height: 44px; display: inline-block; background-position: center; background-repeat: no-repeat; background-size: contain; filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.45)); }

/* apps (squircles) */
.ic-app-readme { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 44 44'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='0' y1='0' x2='0' y2='1'%3E%3Cstop offset='0' stop-color='%23ffffff'/%3E%3Cstop offset='1' stop-color='%23e8e8ed'/%3E%3C/linearGradient%3E%3C/defs%3E%3Crect x='2' y='2' width='40' height='40' rx='10' fill='url(%23g)'/%3E%3Crect x='10' y='12' width='24' height='3' rx='1.5' fill='%231d1d1f' opacity='.85'/%3E%3Crect x='10' y='19' width='24' height='2.6' rx='1.3' fill='%231d1d1f' opacity='.55'/%3E%3Crect x='10' y='25' width='24' height='2.6' rx='1.3' fill='%231d1d1f' opacity='.38'/%3E%3Crect x='10' y='31' width='15' height='2.6' rx='1.3' fill='%231d1d1f' opacity='.25'/%3E%3C/svg%3E"); }
.ic-app-reel { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 44 44'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='0' y1='0' x2='0' y2='1'%3E%3Cstop offset='0' stop-color='%233a3a3f'/%3E%3Cstop offset='1' stop-color='%2318181b'/%3E%3C/linearGradient%3E%3C/defs%3E%3Crect x='2' y='2' width='40' height='40' rx='10' fill='url(%23g)'/%3E%3Ccircle cx='22' cy='22' r='13.5' fill='%23f5f5f7'/%3E%3Ccircle cx='22' cy='22' r='3.2' fill='%2318181b'/%3E%3Ccircle cx='22' cy='13.4' r='2.7' fill='%2318181b'/%3E%3Ccircle cx='22' cy='30.6' r='2.7' fill='%2318181b'/%3E%3Ccircle cx='13.4' cy='22' r='2.7' fill='%2318181b'/%3E%3Ccircle cx='30.6' cy='22' r='2.7' fill='%2318181b'/%3E%3C/svg%3E"); }
.ic-app-slate { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 44 44'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='0' y1='0' x2='0' y2='1'%3E%3Cstop offset='0' stop-color='%234a4a50'/%3E%3Cstop offset='1' stop-color='%23202024'/%3E%3C/linearGradient%3E%3C/defs%3E%3Crect x='2' y='2' width='40' height='40' rx='10' fill='url(%23g)'/%3E%3Cpath d='M10 17 L34 17 L34 33 Q34 34.5 32.5 34.5 L11.5 34.5 Q10 34.5 10 33 Z' fill='%23f5f5f7'/%3E%3Cpath d='M10 16.5 L34 16.5 L32.8 10 L8.8 10 Z' fill='%231d1d1f'/%3E%3Cpath d='M11.5 11.4h4.4l-1.6 3.6h-4.4z M19 11.4h4.4l-1.6 3.6h-4.4z M26.5 11.4h4.4l-1.6 3.6h-4.4z' fill='%23f5f5f7'/%3E%3Crect x='13.5' y='21.5' width='17' height='2.6' rx='1.3' fill='%231d1d1f' opacity='.75'/%3E%3Crect x='13.5' y='27' width='10' height='2.6' rx='1.3' fill='%231d1d1f' opacity='.45'/%3E%3C/svg%3E"); }
.ic-app-play { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 44 44'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='0' y1='0' x2='0' y2='1'%3E%3Cstop offset='0' stop-color='%23ff6961'/%3E%3Cstop offset='1' stop-color='%23e0322b'/%3E%3C/linearGradient%3E%3C/defs%3E%3Crect x='2' y='2' width='40' height='40' rx='10' fill='url(%23g)'/%3E%3Cpath d='M17.5 13.5 L32.5 22 L17.5 30.5 Z' fill='%23ffffff'/%3E%3C/svg%3E"); }
.ic-app-term { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 44 44'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='0' y1='0' x2='0' y2='1'%3E%3Cstop offset='0' stop-color='%23303035'/%3E%3Cstop offset='1' stop-color='%230c0c0e'/%3E%3C/linearGradient%3E%3C/defs%3E%3Crect x='2' y='2' width='40' height='40' rx='10' fill='url(%23g)' stroke='%23f5f5f7' stroke-opacity='.22' stroke-width='1'/%3E%3Cpath d='M11 15 L18 21.5 L11 28' fill='none' stroke='%23ff453a' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3Crect x='21' y='26.5' width='11' height='3' rx='1.5' fill='%23f5f5f7'/%3E%3C/svg%3E"); }
.ic-app-bio { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 44 44'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='0' y1='0' x2='0' y2='1'%3E%3Cstop offset='0' stop-color='%23ffffff'/%3E%3Cstop offset='1' stop-color='%23e8e8ed'/%3E%3C/linearGradient%3E%3C/defs%3E%3Crect x='2' y='2' width='40' height='40' rx='10' fill='url(%23g)'/%3E%3Ccircle cx='22' cy='17.5' r='6.5' fill='%2398989d'/%3E%3Cpath d='M9.5 36 Q9.5 26.5 22 26.5 Q34.5 26.5 34.5 36 Z' fill='%2398989d'/%3E%3C/svg%3E"); }
.ic-app-tel { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 44 44'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='0' y1='0' x2='0' y2='1'%3E%3Cstop offset='0' stop-color='%23303035'/%3E%3Cstop offset='1' stop-color='%23101013'/%3E%3C/linearGradient%3E%3C/defs%3E%3Crect x='2' y='2' width='40' height='40' rx='10' fill='url(%23g)'/%3E%3Cpath d='M14.5 11 Q17 10 18 12.5 L19.8 16.5 Q20.6 18.5 18.8 19.8 L17.2 21 Q18.6 24.6 21.7 27 Q24.8 29.4 28 30 L28.8 28.2 Q29.7 26.2 31.8 26.8 L36 28 Q38.5 28.8 37.8 31.4 Q36.8 35.2 33 35.2 Q25.5 35.2 18.7 29.6 Q11.9 24 10.3 16.8 Q9.5 13 12.8 11.6 Z' fill='%23ff453a' transform='translate(-2.2 -1.5) scale(1.02)'/%3E%3C/svg%3E"); }

/* folders (graphite) */
.ic-folder { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 44 44'%3E%3Cdefs%3E%3ClinearGradient id='b' x1='0' y1='0' x2='0' y2='1'%3E%3Cstop offset='0' stop-color='%236e6e76'/%3E%3Cstop offset='1' stop-color='%234a4a52'/%3E%3C/linearGradient%3E%3ClinearGradient id='f' x1='0' y1='0' x2='0' y2='1'%3E%3Cstop offset='0' stop-color='%235c5c64'/%3E%3Cstop offset='1' stop-color='%2334343b'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cpath d='M4 12 Q4 9 7 9 L16 9 L19.5 13 L37 13 Q40 13 40 16 L40 20 L4 20 Z' fill='url(%23b)'/%3E%3Crect x='4' y='16' width='36' height='20' rx='3' fill='url(%23f)'/%3E%3C/svg%3E"); }
.ic-folder-tag { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 44 44'%3E%3Cdefs%3E%3ClinearGradient id='b' x1='0' y1='0' x2='0' y2='1'%3E%3Cstop offset='0' stop-color='%236e6e76'/%3E%3Cstop offset='1' stop-color='%234a4a52'/%3E%3C/linearGradient%3E%3ClinearGradient id='f' x1='0' y1='0' x2='0' y2='1'%3E%3Cstop offset='0' stop-color='%235c5c64'/%3E%3Cstop offset='1' stop-color='%2334343b'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cpath d='M4 12 Q4 9 7 9 L16 9 L19.5 13 L37 13 Q40 13 40 16 L40 20 L4 20 Z' fill='url(%23b)'/%3E%3Crect x='4' y='16' width='36' height='20' rx='3' fill='url(%23f)'/%3E%3Ccircle cx='34' cy='30' r='6.5' fill='%23ff453a'/%3E%3Ctext x='34' y='33.4' font-family='-apple-system,Helvetica' font-size='9' font-weight='700' fill='%23ffffff' text-anchor='middle'%3E$%3C/text%3E%3C/svg%3E"); }

/* documents (sheets) */
.ic-doc-reel { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 44 44'%3E%3Cpath d='M9 4 L28 4 L35 11 L35 40 L9 40 Z' fill='%23ffffff'/%3E%3Cpath d='M28 4 L28 11 L35 11 Z' fill='%23c7c7cc'/%3E%3Ccircle cx='22' cy='25' r='8.5' fill='%231d1d1f'/%3E%3Ccircle cx='22' cy='25' r='2' fill='%23ffffff'/%3E%3Ccircle cx='22' cy='19.6' r='1.7' fill='%23ffffff'/%3E%3Ccircle cx='22' cy='30.4' r='1.7' fill='%23ffffff'/%3E%3Ccircle cx='16.6' cy='25' r='1.7' fill='%23ffffff'/%3E%3Ccircle cx='27.4' cy='25' r='1.7' fill='%23ffffff'/%3E%3C/svg%3E"); }
.ic-doc-play { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 44 44'%3E%3Cpath d='M9 4 L28 4 L35 11 L35 40 L9 40 Z' fill='%23ffffff'/%3E%3Cpath d='M28 4 L28 11 L35 11 Z' fill='%23c7c7cc'/%3E%3Ccircle cx='22' cy='25' r='9' fill='%23ff453a'/%3E%3Cpath d='M19.5 20.5 L27 25 L19.5 29.5 Z' fill='%23fff'/%3E%3C/svg%3E"); }
.ic-doc-bio { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 44 44'%3E%3Cpath d='M9 4 L28 4 L35 11 L35 40 L9 40 Z' fill='%23ffffff'/%3E%3Cpath d='M28 4 L28 11 L35 11 Z' fill='%23c7c7cc'/%3E%3Ccircle cx='22' cy='22' r='4.5' fill='%2398989d'/%3E%3Cpath d='M14 34 Q14 27.5 22 27.5 Q30 27.5 30 34 Z' fill='%2398989d'/%3E%3C/svg%3E"); }
.ic-doc-tel { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 44 44'%3E%3Cpath d='M9 4 L28 4 L35 11 L35 40 L9 40 Z' fill='%23ffffff'/%3E%3Cpath d='M28 4 L28 11 L35 11 Z' fill='%23c7c7cc'/%3E%3Ctext x='22' y='31' font-family='Georgia' font-size='17' font-style='italic' fill='%230a84ff' text-anchor='middle'%3E@%3C/text%3E%3C/svg%3E"); }

/* trash + files */
.ic-trash { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 44 44'%3E%3Cpath d='M11 13 L33 13 L31 37 Q30.8 39 28.8 39 L15.2 39 Q13.2 39 13 37 Z' fill='rgba(245,245,247,0.32)' stroke='%23f5f5f7' stroke-width='1.6'/%3E%3Cpath d='M15.8 17.5 L17 34.5 M22 17.5 L22 34.5 M28.2 17.5 L27 34.5' stroke='%23f5f5f7' stroke-width='1.5' stroke-linecap='round' opacity='.85'/%3E%3Crect x='8.5' y='8.6' width='27' height='3.6' rx='1.8' fill='%23f5f5f7'/%3E%3Crect x='17.5' y='5' width='9' height='3.6' rx='1.8' fill='%23f5f5f7'/%3E%3C/svg%3E"); }
.ic-zip { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 44 44'%3E%3Cpath d='M10 4 L29 4 L36 11 L36 40 L10 40 Z' fill='%23e8e8ed'/%3E%3Cpath d='M20 4h4v4h-4z M20 12h4v4h-4z M20 20h4v4h-4z' fill='%231d1d1f' opacity='.6'/%3E%3C/svg%3E"); }
.ic-fig { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 44 44'%3E%3Ccircle cx='22' cy='14' r='8' fill='%23e8e8ed'/%3E%3Ccircle cx='22' cy='30' r='8' fill='%2398989d'/%3E%3C/svg%3E"); }
.ic-psd { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 44 44'%3E%3Crect x='5' y='7' width='34' height='30' rx='5' fill='%23e8e8ed'/%3E%3Ctext x='22' y='28.5' font-family='monospace' font-size='14' font-weight='bold' fill='%231d1d1f' text-anchor='middle'%3EPs%3C/text%3E%3C/svg%3E"); }

/* ============ WINDOWS ============ */
.window {
  position: absolute;
  background: var(--glass);
  backdrop-filter: blur(34px) saturate(1.6);
  -webkit-backdrop-filter: blur(34px) saturate(1.6);
  border: 0.5px solid var(--line-strong);
  border-radius: var(--r-win);
  box-shadow: var(--shadow-win);
  overflow: hidden;
  display: none;
  flex-direction: column;
  min-width: 300px;
  max-height: min(80vh, 780px);
  opacity: 0;
  transform: scale(0.97) translateY(8px);
  transition: opacity 0.2s ease, transform 0.24s cubic-bezier(0.32, 1.35, 0.5, 1), box-shadow 0.2s;
  will-change: transform;
}
.window.open { display: flex; }
.window.shown { opacity: 1; transform: scale(1) translateY(0); }
.window.active { box-shadow: var(--shadow-active); }
.window.dragging { transition: none; }

.tbar {
  display: flex; align-items: center; gap: 10px;
  height: 38px; padding: 0 14px 0 12px; flex: none;
  border-bottom: 0.5px solid rgba(0, 0, 0, 0.35);
  background: linear-gradient(rgba(255,255,255,0.055), rgba(255,255,255,0.02));
  cursor: grab; user-select: none;
}
.window.dragging .tbar { cursor: grabbing; }
.tbar h2 {
  font-size: 13px; font-weight: 600; letter-spacing: 0.01em;
  color: var(--text-dim); flex: 1; text-align: center;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  font-family: var(--ui);
}
.window.active .tbar h2 { color: var(--text); }
.tmeta { font-family: var(--mono); font-size: 10px; letter-spacing: 0.12em; color: var(--mute); min-width: 64px; text-align: right; }
.tmeta.hot { color: var(--text-dim); }
.tmeta.live { color: var(--text-dim); display: inline-flex; align-items: center; gap: 6px; justify-content: flex-end; }
.tmeta.live i { width: 6px; height: 6px; border-radius: 50%; background: var(--red); animation: blink 1.1s steps(2) infinite; }

/* traffic lights */
.dots { display: flex; gap: 8px; min-width: 64px; align-items: center; }
.dots > * { width: 12px; height: 12px; border-radius: 50%; border: none; padding: 0; position: relative; }
.d-close { background: var(--tl-red); box-shadow: inset 0 0 0 0.5px rgba(0,0,0,0.15); }
.d-min { background: var(--tl-yellow); box-shadow: inset 0 0 0 0.5px rgba(0,0,0,0.15); }
.d-zoom { background: var(--tl-green); box-shadow: inset 0 0 0 0.5px rgba(0,0,0,0.15); display: inline-block; opacity: 0.45; }
.window:not(.active) .dots > * { background: #4a4a50; }
.dots:hover .d-close { background: var(--tl-red); }
.dots:hover .d-min { background: var(--tl-yellow); }
.dots:hover .d-close::after, .dots:hover .d-min::after {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; color: rgba(0, 0, 0, 0.55); line-height: 1;
}
.dots:hover .d-close::after { content: "✕"; font-size: 7.5px; }
.dots:hover .d-min::after { content: "—"; font-size: 7px; }

.wbody { flex: 1; overflow: auto; overscroll-behavior: contain; }
.wbody::-webkit-scrollbar { width: 8px; }
.wbody::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.18); border-radius: 4px; }
.paper.wbody::-webkit-scrollbar-thumb, .doc.wbody::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.22); }

/* ---- README ---- */
.w-readme { width: 400px; }
.w-readme .wbody { padding: 28px 30px 22px; }
.paper { background: linear-gradient(180deg, var(--paper), var(--paper-2)); color: var(--paper-ink); }
.readme-line { font-family: var(--serif); font-size: 27px; line-height: 1.32; }
.readme-line em { font-style: italic; }
.readme-line.accent em { color: var(--red); }
.readme-foot { margin-top: 20px; padding-top: 15px; border-top: 1px solid var(--paper-line); font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.13em; line-height: 1.9; color: var(--paper-dim); }

/* ---- SHOWREEL ---- */
.w-showreel { width: 520px; }
.reel-stage { position: relative; aspect-ratio: 1; background: #000; }
.rs { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: opacity 0.7s ease; }
.rs.b { opacity: 0; }
.reel-stage figcaption {
  position: absolute; left: 14px; bottom: 12px; right: 56px;
  font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.16em;
  color: rgba(245, 245, 247, 0.9); text-shadow: 0 1px 6px rgba(0,0,0,0.9);
}
#reel-toggle {
  position: absolute; right: 12px; bottom: 10px;
  width: 30px; height: 30px; border-radius: 50%;
  background: rgba(20, 20, 22, 0.6); backdrop-filter: blur(8px);
  color: var(--text); font-size: 9px;
  border: 0.5px solid var(--line-strong);
}
#reel-toggle:hover { background: rgba(255, 255, 255, 0.25); }

/* ---- docs (paper) ---- */
.w-films { width: 640px; }
.doc { padding: 24px 30px 28px; }
.letterhead {
  display: flex; justify-content: space-between; align-items: baseline;
  font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.24em; color: var(--paper-cap);
  padding-bottom: 13px; margin-bottom: 22px; border-bottom: 2px solid var(--paper-ink);
}
.film-feature { margin-bottom: 34px; }
.film-feature + .film-feature { border-top: 1px solid var(--paper-line); padding-top: 30px; }
.film-feature .laurel {
  display: inline-block;
  font-family: var(--mono); font-size: 8.5px; letter-spacing: 0.18em;
  color: var(--paper-dim); border: 1px solid rgba(0, 0, 0, 0.28); border-radius: 99px;
  padding: 5px 12px; margin: 10px 0 16px;
}
.ff-title { font-family: var(--serif); font-size: 56px; line-height: 0.98; font-weight: 400; font-style: italic; }
.ff-media { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 6px 0 16px; }
.ff-media.two { grid-template-columns: 1.1fr 1.55fr; }
.ff-media img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 10px; }
.ff-media.two img { aspect-ratio: auto; height: 190px; }
.ff-desc { font-family: var(--serif); font-size: 18px; line-height: 1.45; color: #48484d; max-width: 50ch; }
.ff-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 0 22px; margin-top: 16px; border-top: 1px solid var(--paper-line); }
.ff-meta div { padding: 9px 0; border-bottom: 1px solid var(--paper-line); }
.ff-meta .wide { grid-column: 1 / -1; }
.ff-meta dt { font-family: var(--mono); font-size: 8.5px; letter-spacing: 0.22em; text-transform: uppercase; color: var(--paper-cap); margin-bottom: 3px; }
.ff-meta dd { font-size: 12.5px; color: var(--paper-ink); }
.doc-foot { margin-top: 20px; padding-top: 13px; border-top: 1px solid var(--paper-line); font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.11em; line-height: 1.9; color: var(--paper-cap); }
.doclink { font: inherit; letter-spacing: inherit; color: var(--blue); text-decoration: underline; padding: 0; }

/* ---- SLATE board ---- */
.w-slate { width: 620px; }
.slate.wbody { padding: 18px 20px 22px; display: flex; flex-direction: column; gap: 12px; }
.slate-kick { font-family: var(--mono); font-size: 9px; letter-spacing: 0.22em; color: var(--mute); margin-bottom: 2px; }
.proj {
  border: 0.5px solid var(--line);
  border-radius: 12px;
  padding: 16px 16px 18px;
  background: rgba(255, 255, 255, 0.045);
  transition: border-color 0.2s, background 0.2s;
}
.proj:hover { border-color: rgba(255, 255, 255, 0.3); background: rgba(255, 255, 255, 0.07); }
.proj-head { display: flex; align-items: center; justify-content: space-between; gap: 14px; }
.proj-head h3 { font-family: var(--ui); font-weight: 700; font-size: 21px; letter-spacing: 0.01em; }

/* macOS-tag style badges: neutral pill + colored dot */
.badge, .pill {
  font-family: var(--mono); font-size: 8.5px; letter-spacing: 0.16em; font-style: normal;
  color: var(--text-dim);
  border: 0.5px solid var(--line-strong); border-radius: 99px;
  background: rgba(255, 255, 255, 0.07);
  padding: 5px 11px 5px 9px; white-space: nowrap;
  display: inline-flex; align-items: center; gap: 6px;
}
.badge::before, .pill::before {
  content: ""; width: 6px; height: 6px; border-radius: 50%;
  background: var(--dot, var(--mute));
}
.badge.hot, .pill.hot { --dot: var(--red); color: var(--text); border-color: rgba(255, 69, 58, 0.4); }
.badge { --dot: #d8d8dc; }
.badge.dim { --dot: var(--mute); color: var(--mute); }

.proj-media { display: grid; grid-template-columns: 1fr 1.5fr; gap: 8px; margin-top: 12px; }
.proj-media img { width: 100%; height: 132px; object-fit: cover; border-radius: 8px; }
.proj-log { font-family: var(--serif); font-size: 16.5px; color: var(--text-dim); margin: 10px 0 12px; line-height: 1.35; }
.proj-meta { display: flex; gap: 7px; flex-wrap: wrap; margin-bottom: 14px; align-items: center; }
.proj-meta span { font-family: var(--mono); font-size: 8px; letter-spacing: 0.16em; color: var(--text-dim); background: rgba(255, 255, 255, 0.08); border-radius: 5px; padding: 4px 8px; }
.proj-link {
  font-family: var(--mono); font-size: 8px; letter-spacing: 0.16em;
  color: #fff; background: var(--blue); border-radius: 5px; padding: 4px 8px;
}
.proj-link:hover { filter: brightness(1.15); }
.phase { position: relative; height: 4px; background: rgba(255, 255, 255, 0.12); border-radius: 3px; margin-top: 20px; }
.phase i { position: absolute; left: 0; top: 0; bottom: 0; background: linear-gradient(90deg, rgba(232, 52, 42, 0.4), var(--red)); border-radius: 3px; }
.phase .ph { position: absolute; top: -15px; font-family: var(--mono); font-size: 7.5px; letter-spacing: 0.15em; color: var(--mute); }
.ph1 { left: 0; } .ph2 { left: 33%; } .ph3 { left: 66%; } .ph4 { right: 0; }

/* ---- CLIENTS ---- */
.w-clients { width: 480px; }
.clients.wbody { padding: 20px 22px 22px; }
.clients .c-kick { font-family: var(--serif); font-size: 18px; color: var(--text-dim); margin-bottom: 16px; }
.client-rows { list-style: none; border-top: 0.5px solid var(--line); }
.client-rows li {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 13px 2px; border-bottom: 0.5px solid var(--line);
}
.cr-main b { font-size: 15px; font-weight: 700; letter-spacing: 0.01em; display: block; }
.cr-main span { font-size: 12px; color: var(--text-dim); }
.clients-foot { margin-top: 16px; font-size: 12.5px; color: var(--text-dim); }
.clients-foot a { color: var(--link); }
.clients-foot a:hover { text-decoration: underline; }

/* ---- FLESH ---- */
.w-flesh { width: 560px; }
.flesh.wbody { padding: 0; display: flex; flex-direction: column; }
.yt-frame { aspect-ratio: 16 / 9; background: #000; }
.yt-frame iframe { width: 100%; height: 100%; border: 0; display: block; }
.flesh-cap { padding: 12px 16px 14px; font-size: 12.5px; color: var(--text-dim); }
.flesh-cap i { font-family: var(--serif); font-size: 15px; color: var(--text); }
.flesh-cap a { color: var(--link); }
.flesh-cap a:hover { text-decoration: underline; }

/* ---- LAB terminal ---- */
.w-lab { width: 560px; }
.term.wbody {
  background: rgba(10, 10, 12, 0.9);
  font-family: var(--mono); font-size: 12px; line-height: 1.75;
  padding: 14px 16px; color: #d6d6db;
  cursor: text;
}
#term-out .t-dim { color: var(--mute); }
#term-out .t-acc { color: var(--teal); }
#term-out .t-ok { color: var(--green); }
#term-out .t-b { color: #fff; font-weight: 500; }
#term-out div { white-space: pre-wrap; word-break: break-word; }
.term-line { display: flex; gap: 8px; align-items: center; }
.ps1 { color: var(--red); white-space: pre; }
#term-in {
  flex: 1; background: none; border: none; outline: none;
  font: inherit; color: #fff; caret-color: var(--red);
}

/* ---- SALAR ---- */
.w-salar { width: 560px; }
.bio-head { display: flex; align-items: center; gap: 18px; margin-bottom: 16px; }
.bio-pic { width: 80px; height: 80px; border-radius: 50%; object-fit: cover; border: 1px solid var(--paper-line); }
.bio-name { font-family: var(--serif); font-style: italic; font-size: 38px; line-height: 1; }
.bio-role { font-family: var(--mono); font-size: 9px; letter-spacing: 0.2em; color: var(--paper-cap); margin-top: 8px; text-transform: uppercase; }
.bio-lead { font-size: 14px; line-height: 1.65; color: #48484d; margin-bottom: 18px; }
.bio-lead b { color: var(--paper-ink); }
.cv { width: 100%; border-collapse: collapse; }
.cv th {
  font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.12em; color: var(--paper-cap);
  text-align: left; vertical-align: top; padding: 9px 14px 9px 0; white-space: nowrap; font-weight: 500;
}
.cv td { font-size: 12.5px; line-height: 1.55; color: #48484d; padding: 9px 0; }
.cv td b { color: var(--paper-ink); }
.cv tr { border-top: 1px solid var(--paper-line); }

/* ---- CONTACT ---- */
.w-contact { width: 430px; }
.contact.wbody { padding: 24px 26px 26px; }
.contact .c-kick { font-family: var(--serif); font-size: 18px; line-height: 1.4; color: var(--text-dim); margin-bottom: 20px; max-width: 30ch; }
.c-mail {
  display: block;
  font-family: var(--serif); font-style: italic;
  font-size: 46px; line-height: 1.02;
  color: var(--text);
  transition: color 0.2s;
}
.c-mail:hover { color: var(--link); }
.c-loc { margin-top: 18px; font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.24em; color: var(--mute); }
.c-partners { margin-top: 20px; padding-top: 15px; border-top: 0.5px solid var(--line); font-family: var(--mono); font-size: 8.5px; letter-spacing: 0.18em; color: var(--mute); line-height: 2.1; }
.c-partners span { color: var(--text-dim); }

/* ---- TRASH ---- */
.w-trash { width: 400px; }
.trash.wbody { padding: 12px 14px 16px; }
#trash-list { list-style: none; }
#trash-list li {
  display: flex; align-items: center; gap: 12px;
  padding: 7px 10px; border-radius: 8px;
  font-family: var(--ui); font-size: 13px;
}
#trash-list li:hover { background: rgba(255, 255, 255, 0.07); }
#trash-list .ic { width: 28px; height: 28px; }
#trash-list em { margin-left: auto; font-style: normal; font-size: 11px; color: var(--mute); font-variant-numeric: tabular-nums; }
#empty-trash {
  margin-top: 12px; width: 100%;
  font-size: 12.5px; font-weight: 600;
  padding: 8px; border-radius: 8px;
  background: var(--blue); color: #fff;
  transition: filter 0.2s;
}
#empty-trash:hover { filter: brightness(1.12); }
.trash-empty { padding: 24px 10px; text-align: center; font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.13em; color: var(--mute); line-height: 2; }

/* ============ DOCK ============ */
#dock {
  position: fixed; bottom: 10px; left: 50%; transform: translateX(-50%);
  z-index: 210;
  display: flex; align-items: flex-end; gap: 3px;
  padding: 7px 10px;
  background: rgba(30, 30, 34, 0.4);
  backdrop-filter: blur(30px) saturate(1.7);
  -webkit-backdrop-filter: blur(30px) saturate(1.7);
  border: 0.5px solid var(--line-strong);
  border-radius: 22px;
  box-shadow: 0 0 0 0.5px rgba(0,0,0,.4), 0 14px 44px rgba(0, 0, 0, 0.45);
}
#dock button {
  position: relative;
  padding: 4px 5px 9px;
  border-radius: 12px;
  transition: transform 0.16s cubic-bezier(0.34, 1.56, 0.64, 1);
}
#dock button:hover { transform: translateY(-10px) scale(1.28); }
#dock button:active { transform: translateY(-5px) scale(1.12); }
#dock .ic { width: 44px; height: 44px; }
#dock .lit {
  position: absolute; left: 50%; bottom: 2px; transform: translateX(-50%);
  width: 4px; height: 4px; border-radius: 50%;
  background: rgba(255, 255, 255, 0.85); opacity: 0; transition: opacity 0.2s;
}
#dock button.running .lit { opacity: 1; }
.dock-sep { width: 1px; align-self: stretch; margin: 6px 5px; background: var(--line-strong); }
.dock-tip { display: none; }
#dock button::before {
  content: attr(data-tip);
  position: absolute; bottom: calc(100% + 12px); left: 50%; transform: translateX(-50%);
  background: var(--glass-hi);
  backdrop-filter: blur(16px);
  border: 0.5px solid var(--line-strong);
  border-radius: 7px;
  padding: 4px 10px;
  font-size: 12px; white-space: nowrap; color: var(--text);
  box-shadow: 0 6px 20px rgba(0,0,0,0.4);
  opacity: 0; pointer-events: none;
  transition: opacity 0.15s ease 0.1s;
}
#dock button:hover::before { opacity: 1; }

/* ============ TOAST ============ */
#toast {
  position: fixed; bottom: 90px; left: 50%; transform: translateX(-50%) translateY(12px);
  z-index: 400;
  background: var(--glass-hi);
  backdrop-filter: blur(22px);
  border: 0.5px solid var(--line-strong);
  border-radius: 99px;
  padding: 10px 20px;
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.12em;
  color: var(--text);
  opacity: 0; pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
  max-width: 86vw; text-align: center;
}
#toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
#toast b { color: var(--teal); font-weight: 500; }

/* ---- PROJECT PAGES ---- */
.w-project { width: 600px; }
.pj.wbody { padding: 0; }
.pj-media { background: #000; }
.pj-media video, .pj-media img { width: 100%; display: block; }
.pj-media:not(.vert):not(.grid) video { aspect-ratio: 16 / 9; object-fit: cover; }
.pj-media.vert { display: flex; justify-content: center; max-height: 46vh; overflow: hidden; }
.pj-media.vert video { width: min(52%, 300px); }
.pj-media.grid { display: grid; gap: 2px; }
.pj-media.grid.g2 { grid-template-columns: 1fr 1.4fr; }
.pj-media.grid.g3 { grid-template-columns: repeat(3, 1fr); }
.pj-media.grid img { height: 200px; object-fit: cover; }
.pj-body { padding: 16px 20px 20px; }
.pj-body .proj-log { margin: 10px 0 8px; }
.pj-desc { font-size: 12.5px; line-height: 1.65; color: var(--text-dim); max-width: 60ch; }
.pj-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 0 20px; margin-top: 14px; border-top: 0.5px solid var(--line); }
.pj-meta div { padding: 8px 0; border-bottom: 0.5px solid var(--line); }
.pj-meta dt { font-family: var(--mono); font-size: 8px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--mute); margin-bottom: 2px; }
.pj-meta dd { font-size: 12px; color: var(--text); }
.pj-links { margin-top: 14px; display: flex; gap: 8px; flex-wrap: wrap; }

/* clickable slate cards */
.proj[data-open] { cursor: pointer; }
.proj[data-open]:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; }

/* films full index */
.index-title { font-family: var(--mono); font-size: 9px; letter-spacing: 0.24em; color: var(--paper-cap); margin: 6px 0 8px; }
.film-index { list-style: none; border-top: 1px solid var(--paper-line); }
.fi-row {
  width: 100%; display: grid; grid-template-columns: 1.2fr 1fr auto;
  align-items: baseline; gap: 14px; text-align: left;
  padding: 9px 2px; border-bottom: 1px solid var(--paper-line);
  color: var(--paper-ink); cursor: pointer;
}
.fi-row:hover { background: rgba(0, 0, 0, 0.045); }
.fi-row b { font-family: var(--serif); font-style: italic; font-size: 17px; font-weight: 400; }
.fi-row span { font-family: var(--mono); font-size: 9px; letter-spacing: 0.14em; color: var(--paper-cap); text-transform: uppercase; }
.fi-row em { font-family: var(--mono); font-style: normal; font-size: 8.5px; letter-spacing: 0.16em; color: var(--red); }

/* ============ MOBILE = iOS ============ */
.m-only { display: none !important; }

@media (max-width: 760px) {
  .m-only { display: flex !important; }
  .m-hide { display: none !important; }
  #menubar, .wp-credit { display: none; }

  /* --- status bar + dynamic island --- */
  #ios-status {
    position: fixed; top: 0; left: 0; right: 0; z-index: 220;
    height: calc(54px + env(safe-area-inset-top, 0px));
    padding: calc(8px + env(safe-area-inset-top, 0px)) 20px 0;
    display: flex; align-items: center; justify-content: space-between;
    color: #fff; text-shadow: 0 1px 4px rgba(0, 0, 0, 0.6);
    pointer-events: none;
  }
  .ios-time { font-size: 15px; font-weight: 600; width: 64px; font-variant-numeric: tabular-nums; }
  .island {
    position: absolute; left: 50%; transform: translateX(-50%);
    top: calc(9px + env(safe-area-inset-top, 0px));
    background: #000; border: 0.5px solid rgba(255, 255, 255, 0.14);
    border-radius: 99px; height: 33px; padding: 0 15px;
    display: inline-flex; align-items: center; gap: 8px;
    max-width: 58vw;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
    pointer-events: auto;
    transition: max-width 0.3s ease;
  }
  .island-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--red); animation: blink 1.2s steps(2) infinite; flex: none; }
  .island b { font-size: 11px; font-weight: 600; letter-spacing: 0.08em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .ios-right { display: flex; align-items: center; gap: 7px; width: 64px; justify-content: flex-end; }
  .sig { display: flex; gap: 1.5px; align-items: flex-end; height: 11px; }
  .sig i { width: 3px; background: #fff; border-radius: 1px; }
  .sig i:nth-child(1) { height: 4px; } .sig i:nth-child(2) { height: 6px; }
  .sig i:nth-child(3) { height: 8.5px; } .sig i:nth-child(4) { height: 11px; }
  .batt { width: 25px; height: 12.5px; border: 1px solid rgba(255,255,255,0.55); border-radius: 4px; padding: 1.5px; position: relative; display: inline-block; }
  .batt::after { content: ""; position: absolute; right: -4px; top: 3.5px; width: 2px; height: 5px; background: rgba(255,255,255,0.55); border-radius: 0 2px 2px 0; }
  .batt i { display: block; height: 100%; width: 100%; background: var(--red); border-radius: 2px; }

  /* --- home screen --- */
  #icons {
    position: absolute; inset: auto; top: calc(64px + env(safe-area-inset-top, 0px)); left: 0; right: 0; bottom: auto;
    height: auto;
    display: grid; grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: min-content;
    align-content: start; align-items: start;
    gap: 18px 4px; padding: 10px 14px;
  }
  .dicon { display: flex; width: auto; max-width: none; padding: 0; font-size: 10px; gap: 7px; background: none !important; }
  .dicon .ic { width: 58px; height: 58px; }
  .dicon:active .ic { transform: scale(0.9); opacity: 0.8; }
  .dicon .ic { transition: transform 0.15s ease, opacity 0.15s; }

  /* --- dock --- */
  #dock {
    left: 14px; right: 14px; transform: none;
    bottom: calc(10px + env(safe-area-inset-bottom, 0px));
    justify-content: space-around; align-items: center;
    gap: 0; padding: 11px 8px; border-radius: 30px;
    background: rgba(60, 60, 66, 0.32);
  }
  #dock .ic { width: 56px; height: 56px; }
  #dock button { padding: 0; }
  #dock button:hover, #dock button:active { transform: none; }
  #dock button:active .ic { transform: scale(0.9); }
  #dock button::before { display: none; }
  #dock .lit { display: none; }

  /* --- windows become iOS sheets --- */
  .window {
    position: fixed;
    left: 0 !important; right: 0 !important; top: auto !important; bottom: 0 !important;
    width: 100% !important; min-width: 0;
    height: 87vh !important; height: 87dvh !important; max-height: none;
    border-radius: 22px 22px 0 0;
    border: none; border-top: 0.5px solid var(--line-strong);
    opacity: 1;
    transform: translateY(103%);
    transition: transform 0.42s cubic-bezier(0.32, 0.72, 0.35, 1);
    box-shadow: 0 -18px 60px rgba(0, 0, 0, 0.5);
  }
  .window.shown { transform: translateY(0); }
  .window.dragging { transition: none; }

  .tbar { height: 54px; padding-top: 12px; }
  .tbar::before {
    content: ""; position: absolute; top: 7px; left: 50%; transform: translateX(-50%);
    width: 40px; height: 5px; border-radius: 3px;
    background: rgba(160, 160, 168, 0.4);
  }
  .window { position: fixed; }
  .tbar { position: relative; }
  .tbar h2 { font-size: 15px; }
  .d-min, .d-zoom { display: none; }
  .dots { min-width: 32px; }
  .d-close {
    width: 28px; height: 28px; border-radius: 50%;
    background: rgba(120, 120, 128, 0.28) !important;
    box-shadow: none;
  }
  .d-close::after {
    content: "✕"; position: absolute; inset: 0;
    display: flex; align-items: center; justify-content: center;
    font-size: 13px; font-weight: 600; color: #d8d8dc;
  }
  .tmeta { min-width: 32px; }

  /* --- content tweaks --- */
  .ff-title { font-size: 40px; }
  .ff-media.two { grid-template-columns: 1fr; }
  .ff-media.two img { height: 150px; }
  .c-mail { font-size: 38px; }
  .proj-media img { height: 100px; }
  .pj-media.grid img { height: 120px; }
  .pj-media.vert { max-height: 42vh; }
  .pj-media.vert video { width: min(64%, 260px); }
  .fi-row { grid-template-columns: 1fr auto; }
  .fi-row span { display: none; }
  #toast { bottom: calc(110px + env(safe-area-inset-bottom, 0px)); }
}

/* ============ MOTION SAFETY ============ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  #boot { display: none; }
  .window { opacity: 1; transform: none; }
}
