/* Ousmane Diouf: rooftop at blue hour. Green and gold. */
:root {
  --deep: #061712;
  --forest: #0d2b22;
  --pine: #123a2e;
  --emerald: #1f7a4d;
  --jade: #2f9a68;
  --gold: #e8b931;
  --gold-soft: #f2d27a;
  --brass: #c9a24a;
  --red: #c8372d;
  --cream: #f6efe0;
  --paper: #fbf6ea;
  --sand: #efe4cc;
  --ink: #10231c;
  --ink-soft: #4b6157;
  --line: rgba(16, 35, 28, .13);
  --glass: rgba(6, 23, 18, .62);
  --glass-line: rgba(242, 210, 122, .18);
  --display: "Fraunces", Georgia, serif;
  --sans: "Manrope", system-ui, -apple-system, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, Menlo, monospace;
  --ease: cubic-bezier(.22, .8, .2, 1);
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { font-family: var(--sans); background: var(--forest); color: var(--cream); -webkit-font-smoothing: antialiased; overflow: hidden; }
button { font: inherit; color: inherit; cursor: pointer; }
a { color: inherit; }
h1, h2, h3 { margin: 0; }
.kicker { font-family: var(--mono); font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--emerald); margin: 0 0 12px; display: flex; align-items: center; gap: 10px; }
.kicker::before { content: ""; width: 18px; height: 1.5px; background: currentColor; opacity: .7; }

/* ---------- Buttons ---------- */
.btn { border: 0; border-radius: 999px; padding: 13px 22px; font-weight: 700; font-size: 14px; transition: transform .2s var(--ease), background .2s, box-shadow .2s; }
.btn:active { transform: scale(.97); }
.btn.primary { background: var(--gold); color: var(--forest); box-shadow: 0 10px 28px rgba(232, 185, 49, .25); }
.btn.primary:hover { background: #f3c84a; }
.btn.ghost { background: transparent; color: var(--cream); box-shadow: inset 0 0 0 1px rgba(246, 239, 224, .28); }
.btn.ghost:hover { box-shadow: inset 0 0 0 1px var(--gold-soft); }

/* ---------- Loader ---------- */
.loader {
  position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 20px;
  background:
    radial-gradient(120% 70% at 50% 115%, rgba(232, 185, 49, .28), transparent 60%),
    radial-gradient(80% 60% at 50% 0%, rgba(31, 122, 77, .45), transparent 70%),
    var(--deep);
  transition: opacity .8s var(--ease), visibility .8s;
}
.loader.gone { opacity: 0; visibility: hidden; }
.build { width: min(560px, 100%); background: rgba(6, 23, 18, .82); border: 1px solid var(--glass-line); border-radius: 18px; padding: 0 22px 22px; font-family: var(--mono); font-size: 12.5px; box-shadow: 0 30px 80px rgba(0, 0, 0, .45); }
.build-head { display: flex; align-items: center; gap: 12px; margin: 0 -22px 16px; padding: 12px 16px; border-bottom: 1px solid var(--glass-line); color: rgba(246, 239, 224, .55); font-size: 11.5px; }
.build-title { color: var(--cream); }
.build-target { margin-left: auto; }
.dots { display: flex; gap: 6px; }
.dots i { width: 10px; height: 10px; border-radius: 50%; background: var(--red); }
.dots i:nth-child(2) { background: var(--gold); }
.dots i:nth-child(3) { background: var(--jade); }
.cmd { margin: 0 0 14px; color: var(--cream); }
.cmd .ps { color: var(--jade); }
.cmd .flag { color: rgba(246, 239, 224, .5); }
.cmd .hl { color: var(--gold); }
.log { list-style: none; margin: 0 0 18px; padding: 0; min-height: 168px; }
.log li { display: flex; gap: 10px; line-height: 1.75; color: rgba(246, 239, 224, .78); animation: rise .35s var(--ease) both; }
.log .tag { color: var(--jade); flex: none; }
.log .tag.warn { color: var(--gold); }
.log .ok { color: var(--gold); font-weight: 600; letter-spacing: .04em; }
.bar { display: flex; justify-content: space-between; color: rgba(246, 239, 224, .55); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; margin-bottom: 8px; }
.bar-label.done { color: var(--gold); }
.progress { height: 6px; border-radius: 6px; background: rgba(246, 239, 224, .1); overflow: hidden; }
.progress i { display: block; height: 100%; width: 0; border-radius: 6px; background: linear-gradient(90deg, var(--emerald), var(--gold)); transition: width .25s linear; }
.enter { display: flex; gap: 10px; margin-top: 20px; opacity: 0; transform: translateY(6px); pointer-events: none; transition: opacity .5s var(--ease), transform .5s var(--ease); }
.enter.ready { opacity: 1; transform: none; pointer-events: auto; }
.enter .btn { flex: 1; font-family: var(--sans); }
@keyframes rise { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ---------- Scene ---------- */
#scene { position: fixed; inset: 0; width: 100%; height: 100%; display: block; z-index: 0; touch-action: none; outline: none; cursor: grab; }
#scene.hovering { cursor: pointer; }
#scene.dragging { cursor: grabbing; }

/* ---------- Intro and signature ---------- */
.intro { position: fixed; inset: 0; z-index: 12; display: grid; place-content: center; text-align: center; pointer-events: none; opacity: 0; }
.intro.show { opacity: 1; }
.intro.leave { opacity: 0; transform: translateY(-14px) scale(.98); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.intro-name { font-family: var(--display); font-weight: 800; font-size: clamp(54px, 11vw, 168px); line-height: .92; letter-spacing: -.02em; color: var(--cream); text-shadow: 0 6px 40px rgba(6, 23, 18, .6); }
.intro-name .w { display: inline-block; overflow: hidden; padding: 0 .04em .06em; vertical-align: bottom; }
.intro-name .c { display: inline-block; transform: translateY(105%); }
.intro.show .intro-name .c { animation: up .9s var(--ease) forwards; }
@keyframes up { to { transform: none; } }
.intro-line { font-family: var(--display); font-style: italic; font-size: clamp(20px, 2.6vw, 32px); margin: 16px 0 0; color: var(--cream); opacity: 0; transition: opacity .8s var(--ease) .9s; text-shadow: 0 2px 20px rgba(6, 23, 18, .7); }
.intro.show .intro-line { opacity: 1; }
.rot { color: var(--gold); font-weight: 600; }

.sig { position: fixed; left: 28px; bottom: 28px; z-index: 10; opacity: 0; transform: translateY(8px); transition: opacity .8s var(--ease), transform .8s var(--ease); pointer-events: none; text-shadow: 0 2px 16px rgba(6, 23, 18, .7); }
.sig.show { opacity: 1; transform: none; }
.sig-name { font-family: var(--display); font-weight: 600; font-size: 26px; color: var(--cream); letter-spacing: -.01em; }
.sig-meta { margin: 6px 0 0; font-family: var(--mono); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: rgba(246, 239, 224, .78); display: flex; align-items: center; gap: 8px; }
.sig-meta span { color: var(--gold); }
.sun-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 10px var(--gold); }

/* ---------- Menu ---------- */
.stops {
  position: fixed; z-index: 20; left: 24px; top: 50%; transform: translateY(-50%);
  display: flex; flex-direction: column; gap: 2px; padding: 6px;
  border-radius: 22px; background: var(--glass); border: 1px solid var(--glass-line);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  opacity: 0; transition: opacity .8s var(--ease);
}
.stops.show { opacity: 1; }
.stops button { display: flex; align-items: center; gap: 10px; background: none; border: 0; padding: 9px 16px 9px 10px; border-radius: 16px; text-align: left; transition: background .25s; }
.stops .i { width: 20px; height: 20px; flex: none; fill: none; stroke: rgba(246, 239, 224, .75); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; transition: stroke .2s; }
.stops .l { font-weight: 600; font-size: 13.5px; color: var(--cream); }
.stops button:hover { background: rgba(246, 239, 224, .08); }
.stops button:hover .i { stroke: var(--gold); }
.stops button[aria-current="true"] { background: var(--gold); }
.stops button[aria-current="true"] .i { stroke: var(--forest); }
.stops button[aria-current="true"] .l { color: var(--forest); }

/* ---------- HUD ---------- */
.hud { position: fixed; top: 22px; right: 22px; z-index: 20; display: flex; gap: 8px; opacity: 0; transition: opacity .8s var(--ease); }
.hud.show { opacity: 1; }
.hud-btn { display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 14px; border-radius: 999px; background: var(--glass); border: 1px solid var(--glass-line); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); font-size: 12.5px; font-weight: 600; color: var(--cream); transition: border-color .2s; }
.hud-btn:hover { border-color: rgba(232, 185, 49, .7); }
.hud-btn svg { width: 17px; height: 17px; fill: none; stroke: var(--gold); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.hud-btn .moon { display: none; }
.hud-btn[aria-pressed="true"] .sun { display: none; }
.hud-btn[aria-pressed="true"] .moon { display: block; fill: rgba(232, 185, 49, .2); }
.waves { display: flex; align-items: center; gap: 3px; height: 16px; }
.waves i { width: 3px; height: 4px; border-radius: 2px; background: var(--cream); opacity: .55; }
.sound[aria-pressed="true"] .waves i { background: var(--gold); opacity: 1; animation: wave 1.2s ease-in-out infinite; }
.sound .waves i:nth-child(2) { animation-delay: .15s; }
.sound .waves i:nth-child(3) { animation-delay: .3s; }
.sound .waves i:nth-child(4) { animation-delay: .45s; }
@keyframes wave { 0%, 100% { height: 4px; } 50% { height: 15px; } }

/* ---------- Markers ---------- */
.markers { position: fixed; inset: 0; z-index: 5; pointer-events: none; }
.marker { position: absolute; left: 0; top: 0; width: 0; height: 0; transition: opacity .4s; }
.marker.off, .markers.hidden .marker { opacity: 0; }
.marker.off .pin, .markers.hidden .pin { pointer-events: none; }
.pin {
  position: absolute; left: -17px; top: -17px; width: 34px; height: 34px; padding: 0; border: 0; border-radius: 50%;
  display: grid; place-items: center; pointer-events: auto;
  background: var(--gold); box-shadow: 0 0 0 4px rgba(232, 185, 49, .22), 0 6px 18px rgba(6, 23, 18, .45);
  transition: transform .3s var(--ease), box-shadow .3s;
}
.pin svg { width: 17px; height: 17px; fill: none; stroke: var(--forest); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.pin::after { content: ""; position: absolute; inset: -4px; border-radius: 50%; border: 1.5px solid rgba(242, 210, 122, .8); animation: ping 2.6s var(--ease) infinite; pointer-events: none; }
.pin:hover { transform: scale(1.12); box-shadow: 0 0 0 6px rgba(232, 185, 49, .3), 0 8px 22px rgba(6, 23, 18, .5); }
.mlbl {
  position: absolute; left: 24px; top: -14px; height: 28px; padding: 0 12px 0 14px; display: flex; align-items: center;
  border-radius: 0 999px 999px 0; background: var(--cream); color: var(--forest); font-size: 12.5px; font-weight: 700; white-space: nowrap;
  opacity: 0; transform: translateX(-6px); transition: opacity .25s, transform .3s var(--ease); pointer-events: none; z-index: -1;
}
.marker:hover .mlbl { opacity: 1; transform: none; }
@keyframes ping { 0% { transform: scale(.85); opacity: 1; } 80%, 100% { transform: scale(1.6); opacity: 0; } }

.tip { position: fixed; left: 0; top: 0; z-index: 30; pointer-events: none; padding: 7px 12px; border-radius: 999px; background: var(--cream); color: var(--forest); font-size: 12.5px; font-weight: 700; box-shadow: 0 8px 24px rgba(6, 23, 18, .35); opacity: 0; transition: opacity .2s; white-space: nowrap; }
.tip.show { opacity: 1; }
.tip span::after { content: " \2192"; color: var(--emerald); }

/* ---------- Speech bubbles ---------- */
.bubble {
  position: fixed; left: 0; top: 0; z-index: 8; max-width: 240px; pointer-events: none;
  padding: 10px 14px; border-radius: 16px; background: var(--cream); color: var(--ink);
  box-shadow: 0 10px 30px rgba(6, 23, 18, .4);
  opacity: 0; visibility: hidden; transition: opacity .25s, visibility .25s;
}
.bubble::after { content: ""; position: absolute; left: 50%; bottom: -6px; width: 12px; height: 12px; margin-left: -6px; background: inherit; transform: rotate(45deg); border-radius: 2px; }
.bubble.show { opacity: 1; visibility: visible; animation: pop .35s var(--ease); }
.bubble.show.off { opacity: 0; }
.bubble p { margin: 0; font-size: 13.5px; font-weight: 600; line-height: 1.4; }
.bubble .who { display: block; font-family: var(--mono); font-size: 9.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--emerald); margin-bottom: 2px; }
.bubble.faro { background: var(--forest); color: var(--cream); border: 1px solid var(--glass-line); }
.bubble.faro::after { border-right: 1px solid var(--glass-line); border-bottom: 1px solid var(--glass-line); }
.bubble.faro .who { color: var(--gold); }
@keyframes pop { from { transform-origin: bottom center; scale: .85; } to { scale: 1; } }
body.panel-open .bubble.faro { opacity: 0; }

/* ---------- Gym playlist ---------- */
.music {
  position: fixed; z-index: 44; left: 24px; bottom: 96px; width: min(340px, calc(100vw - 24px));
  padding: 12px; border-radius: 22px;
  background: rgba(8, 28, 22, .92); border: 1px solid var(--glass-line); color: var(--cream);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 24px 60px rgba(0, 0, 0, .45);
  opacity: 0; transform: translateY(14px); transition: opacity .3s var(--ease), transform .35s var(--ease);
}
.music.in { opacity: 1; transform: none; }
.music[hidden] { display: none; }
.music-head { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.disc { width: 30px; height: 30px; border-radius: 50%; flex: none; background: radial-gradient(circle, var(--gold) 0 18%, #0a0a0a 19% 30%, #1d1d1d 31% 50%, #0a0a0a 51% 100%); box-shadow: 0 0 0 2px rgba(232, 185, 49, .35); }
.music.playing .disc { animation: spin 2.4s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.music-title { display: flex; flex-direction: column; min-width: 0; }
.music-title b { font-family: var(--display); font-size: 16px; font-weight: 600; }
.music-title small { font-size: 11.5px; color: rgba(246, 239, 224, .6); }
.music-x { margin-left: auto; width: 30px; height: 30px; border-radius: 50%; border: 0; background: rgba(246, 239, 224, .08); font-size: 18px; line-height: 1; }
.music-x:hover { background: rgba(246, 239, 224, .16); }
.music-embed { border-radius: 12px; overflow: hidden; min-height: 152px; background: rgba(246, 239, 224, .05); }
.music-embed iframe { display: block; border: 0; }
.music-ctl { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 10px; }
.music-ctl.off { display: none; }
.music-ctl button, .music-ctl a { width: 38px; height: 38px; border-radius: 50%; border: 0; background: transparent; display: grid; place-items: center; color: var(--cream); }
.music-ctl button:hover, .music-ctl a:hover { background: rgba(246, 239, 224, .1); }
.music-ctl svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.music-ctl .big { width: 48px; height: 48px; background: var(--gold); color: var(--forest); }
.music-ctl .big:hover { background: #f3c84a; }
.music-ctl .big svg { fill: currentColor; stroke-width: 2.6; }
.music-ctl .i-pause { display: none; }
.music.playing .i-play { display: none; }
.music.playing .i-pause { display: block; fill: none; }
.music-title { background: none; border: 0; padding: 0; text-align: left; color: inherit; cursor: default; }
/* the mini player: one slim row, the Spotify embed clipped out of sight but still playing */
.music.mini { display: flex; align-items: center; gap: 6px; width: auto; max-width: calc(100vw - 24px); padding: 6px 8px 6px 10px; border-radius: 999px; }
.music.mini .music-head { margin: 0; min-width: 0; }
.music.mini .music-title { cursor: pointer; }
.music.mini .music-title small { display: none; }
.music.mini .music-embed { position: absolute; width: 300px; height: 0; min-height: 0; overflow: hidden; opacity: 0; pointer-events: none; }
.music.mini .music-ctl { margin: 0; gap: 2px; }
.music.mini #m-shuffle, .music.mini #m-prev, .music.mini #m-open, .music.mini #music-min { display: none; }
.music.mini .music-ctl button { width: 34px; height: 34px; }
.music.mini .music-ctl .big { width: 36px; height: 36px; }
.music.mini .disc { width: 26px; height: 26px; }
#m-shuffle { opacity: .5; }
#m-shuffle[aria-pressed="true"] { opacity: 1; color: var(--gold); }
body.panel-open .music:not(.mini) { opacity: 0; pointer-events: none; }

/* ---------- Chat with Faro ---------- */
.hud-btn.ask { background: var(--gold); color: var(--forest); border-color: transparent; }
.hud-btn.ask svg { stroke: var(--forest); }
.hud-btn.ask:hover { background: #f3c84a; }
.chat {
  position: fixed; z-index: 45; right: 22px; bottom: 22px;
  width: min(370px, calc(100vw - 24px)); height: min(540px, calc(100vh - 100px));
  display: flex; flex-direction: column;
  background: rgba(8, 28, 22, .92); color: var(--cream);
  border: 1px solid var(--glass-line); border-radius: 24px;
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 30px 80px rgba(0, 0, 0, .5);
  opacity: 0; transform: translateY(16px) scale(.98); transform-origin: bottom right;
  transition: opacity .3s var(--ease), transform .35s var(--ease);
}
.chat.in { opacity: 1; transform: none; }
.chat[hidden] { display: none; }
.chat-head { display: flex; align-items: center; gap: 12px; padding: 14px 14px 12px 16px; border-bottom: 1px solid var(--glass-line); }
.chat-av { width: 38px; height: 38px; border-radius: 50%; background: var(--pine); display: grid; place-items: center; flex: none; }
.chat-av svg { width: 30px; height: 30px; }
.chat-title { display: flex; flex-direction: column; min-width: 0; }
.chat-title b { font-family: var(--display); font-size: 18px; font-weight: 600; }
.chat-title small { font-size: 12px; color: rgba(246, 239, 224, .62); }
.chat-x { margin-left: auto; width: 32px; height: 32px; border-radius: 50%; border: 0; background: rgba(246, 239, 224, .08); font-size: 20px; line-height: 1; }
.chat-x:hover { background: rgba(246, 239, 224, .16); }
.chat-log { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 8px; scrollbar-width: thin; }
.msg { max-width: 86%; animation: rise .3s var(--ease) both; }
.msg p { margin: 0; padding: 9px 13px; border-radius: 16px; font-size: 14px; line-height: 1.5; }
.msg.faro p { background: rgba(246, 239, 224, .1); border-bottom-left-radius: 5px; }
.msg.me { align-self: flex-end; }
.msg.me p { background: var(--gold); color: var(--forest); font-weight: 600; border-bottom-right-radius: 5px; }
.msg.typing p { display: flex; gap: 4px; padding: 13px 14px; width: fit-content; }
.msg.typing i { width: 6px; height: 6px; border-radius: 50%; background: var(--gold-soft); animation: blink 1s infinite; }
.msg.typing i:nth-child(2) { animation-delay: .15s; }
.msg.typing i:nth-child(3) { animation-delay: .3s; }
@keyframes blink { 0%, 100% { opacity: .25; } 50% { opacity: 1; } }
.msg-act { margin-top: 6px; border: 1px solid rgba(232, 185, 49, .5); background: transparent; color: var(--gold-soft); border-radius: 999px; padding: 5px 12px; font-size: 12.5px; font-weight: 700; }
.msg-act:hover { background: rgba(232, 185, 49, .14); }
.chat-chips { display: flex; gap: 6px; overflow-x: auto; padding: 0 14px 10px; scrollbar-width: none; }
.chat-chips::-webkit-scrollbar { display: none; }
.chip { flex: none; border: 1px solid var(--glass-line); background: rgba(246, 239, 224, .06); color: var(--cream); border-radius: 999px; padding: 6px 12px; font-size: 12.5px; font-weight: 600; white-space: nowrap; }
.chip:hover { border-color: var(--gold); color: var(--gold-soft); }
.chat-form { display: flex; gap: 8px; padding: 10px 12px 12px; border-top: 1px solid var(--glass-line); }
.chat-form input { flex: 1; min-width: 0; height: 42px; border-radius: 999px; border: 1px solid var(--glass-line); background: rgba(246, 239, 224, .07); color: var(--cream); padding: 0 16px; font: inherit; font-size: 14.5px; }
.chat-form input::placeholder { color: rgba(246, 239, 224, .45); }
.chat-form input:focus { outline: none; border-color: var(--gold); }
.chat-form button { width: 42px; height: 42px; border-radius: 50%; border: 0; background: var(--gold); display: grid; place-items: center; flex: none; }
.chat-form button svg { width: 18px; height: 18px; fill: none; stroke: var(--forest); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- Drag hint ---------- */
.drag-hint { position: fixed; left: 50%; bottom: 34px; z-index: 15; transform: translate(-50%, 8px); display: flex; align-items: center; gap: 12px; padding: 10px 18px; border-radius: 999px; background: var(--glass); border: 1px solid var(--glass-line); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); opacity: 0; pointer-events: none; transition: opacity .6s var(--ease), transform .6s var(--ease); }
.drag-hint.show { opacity: 1; transform: translate(-50%, 0); }
.drag-hint svg { width: 40px; height: 20px; fill: none; stroke: var(--gold); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; animation: sway 1.8s ease-in-out infinite; }
.drag-hint p { margin: 0; font-size: 13px; font-weight: 600; white-space: nowrap; }
@keyframes sway { 0%, 100% { transform: translateX(-4px); } 50% { transform: translateX(4px); } }

/* ---------- Panels ---------- */
.flat-hero, .flat-foot { display: none; }
html:not(.flat) .panel { display: none; }
html:not(.flat) .panel.open {
  display: block; position: fixed; z-index: 40; top: 20px; right: 20px;
  max-height: calc(100vh - 40px); width: min(600px, calc(100vw - 40px));
  overflow-y: auto; overscroll-behavior: contain;
  border-radius: 28px; padding: 26px 30px 34px;
  box-shadow: 0 30px 90px rgba(3, 12, 9, .55);
  animation: slidein .7s var(--ease) both; scrollbar-width: thin;
}
html:not(.flat) .panel.closing { animation: slideout .45s var(--ease) both; }
@keyframes slidein { from { opacity: 0; transform: translateX(40px); } to { opacity: 1; transform: none; } }
@keyframes slideout { to { opacity: 0; transform: translateX(40px); } }
.close { display: inline-flex; align-items: center; gap: 8px; border: 0; border-radius: 999px; padding: 8px 14px; margin: 0 0 22px; font-size: 13px; font-weight: 700; background: rgba(16, 35, 28, .07); color: var(--ink); transition: background .2s; }
.close:hover { background: rgba(16, 35, 28, .13); }
.panel h2 { font-family: var(--display); font-weight: 600; font-size: clamp(32px, 4vw, 46px); line-height: 1.02; letter-spacing: -.02em; margin-bottom: 14px; }

/* Projects */
.panel-projects { background: radial-gradient(110% 70% at 100% 100%, rgba(232, 185, 49, .22), transparent 60%), linear-gradient(160deg, #123a2e, #071a14); color: var(--cream); }
html:not(.flat) .panel-projects.open { width: min(900px, calc(100vw - 40px)); }
.panel-projects .close { background: rgba(246, 239, 224, .1); color: var(--cream); }
.panel-projects .close:hover { background: rgba(246, 239, 224, .18); }
.panel-projects .kicker { color: var(--gold); }
.panel-projects h2 { color: var(--cream); }
.proj-wrap { display: grid; grid-template-columns: 1fr 330px; gap: 34px; align-items: start; }
.proj-intro p { color: rgba(246, 239, 224, .8); line-height: 1.65; font-size: 15px; margin: 0 0 22px; }
.proj-index { list-style: none; margin: 0; padding: 0; border-top: 1px solid rgba(246, 239, 224, .12); }
.proj-index li { border-bottom: 1px solid rgba(246, 239, 224, .12); }
.proj-index button { width: 100%; display: grid; grid-template-columns: 30px 1fr auto; align-items: center; gap: 12px; background: none; border: 0; padding: 10px 4px; text-align: left; color: var(--cream); transition: color .2s, padding .25s var(--ease); }
.proj-index button:hover, .proj-index button[aria-current="true"] { color: var(--gold); padding-left: 10px; }
.proj-index .nm { font-weight: 600; font-size: 14.5px; }
.proj-index .org { font-family: var(--mono); font-size: 10.5px; opacity: .55; letter-spacing: .06em; text-transform: uppercase; }
.ico.sm { width: 28px; height: 28px; border-radius: 8px; box-shadow: none; }
.ico.sm svg { width: 16px; height: 16px; }
/* company logo icons, with a small badge for the feature */
.ico.logo { position: relative; overflow: visible; }
.ico.logo img { width: 100%; height: 100%; object-fit: cover; border-radius: inherit; display: block; }
.ico.logo.pad img { width: 70%; height: 70%; object-fit: contain; }
.ico .badge { position: absolute; right: -5px; bottom: -5px; width: 24px; height: 24px; border-radius: 8px; display: grid; place-items: center; box-shadow: 0 2px 6px rgba(0, 0, 0, .35), 0 0 0 2px rgba(13, 43, 34, .9); }
.ico .badge svg { width: 14px; height: 14px; stroke-width: 2.2; }
.ico.sm .badge { width: 14px; height: 14px; border-radius: 4px; right: -4px; bottom: -4px; }
.ico.sm .badge svg { width: 9px; height: 9px; }
.av-hero { margin: 0 -20px 16px; aspect-ratio: 1200 / 630; overflow: hidden; }
.av-hero img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* The phone */
.phone { position: sticky; top: 0; }
.phone-frame { position: relative; width: 330px; height: 680px; max-height: calc(100vh - 120px); min-height: 560px; border-radius: 52px; padding: 12px; background: linear-gradient(145deg, #2a3a33, #07110d); box-shadow: inset 0 0 0 2px rgba(242, 210, 122, .22), 0 0 0 1px #030806, 0 40px 80px rgba(0, 0, 0, .5); }
.island { position: absolute; top: 22px; left: 50%; width: 104px; height: 30px; margin-left: -52px; border-radius: 20px; background: #020605; z-index: 3; }
.status { position: absolute; z-index: 3; top: 26px; left: 40px; right: 34px; display: flex; justify-content: space-between; font-size: 13.5px; font-weight: 700; color: var(--cream); }
.status-r { display: flex; gap: 6px; align-items: center; }
.status svg { height: 11px; fill: var(--cream); stroke: var(--cream); stroke-width: 1.2; }
.screen { position: relative; height: 100%; border-radius: 41px; overflow: hidden; color: var(--cream);
  background:
    radial-gradient(90% 50% at 80% 105%, rgba(232, 185, 49, .9), transparent 70%),
    radial-gradient(70% 45% at 0% 75%, rgba(47, 154, 104, .75), transparent 70%),
    linear-gradient(180deg, #0d2b22 0%, #164f3a 60%, #c99a2a 100%); }
.home { position: absolute; inset: 0; padding: 64px 18px 18px; display: flex; flex-direction: column; transition: transform .45s var(--ease), opacity .45s var(--ease); }
.home.away { transform: scale(.92); opacity: 0; pointer-events: none; }
.widget { background: rgba(246, 239, 224, .14); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-radius: 22px; padding: 14px 16px; margin-bottom: 22px; }
.w-k { margin: 0; font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; opacity: .8; }
.w-t { margin: 2px 0; font-family: var(--display); font-size: 40px; font-weight: 600; line-height: 1; }
.w-s { margin: 0; font-size: 12px; opacity: .85; }
.apps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px 10px; }
.app { background: none; border: 0; padding: 0; display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 10.5px; font-weight: 600; color: var(--cream); text-decoration: none; }
.app:hover .ico { transform: translateY(-3px); }
.ico { width: 58px; height: 58px; border-radius: 15px; display: grid; place-items: center; box-shadow: 0 6px 14px rgba(3, 12, 9, .35), inset 0 1px 0 rgba(255, 255, 255, .22); transition: transform .25s var(--ease); }
.ico svg { width: 30px; height: 30px; fill: none; stroke: #fff; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.app span.lbl { max-width: 70px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-shadow: 0 1px 4px rgba(0, 0, 0, .35); }
.dock { margin-top: auto; display: flex; justify-content: space-around; padding: 12px 10px; border-radius: 28px; background: rgba(246, 239, 224, .18); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); }
.dock .app span.lbl { display: none; }
.dock .app:nth-child(4) .ico svg { stroke: var(--forest); }
.home-bar { position: absolute; bottom: 20px; left: 50%; width: 120px; height: 5px; margin-left: -60px; border-radius: 3px; background: rgba(246, 239, 224, .75); z-index: 3; }
.appview { position: absolute; inset: 0; overflow-y: auto; padding: 62px 20px 40px; background: var(--paper); color: var(--ink); transform: translateX(100%); transition: transform .45s var(--ease); scrollbar-width: none; }
.appview::-webkit-scrollbar { display: none; }
.appview.in { transform: none; }
.av-back { background: none; border: 0; padding: 4px 0; color: var(--emerald); font-weight: 700; font-size: 14px; display: flex; align-items: center; gap: 4px; margin-bottom: 16px; }
.av-top { display: flex; gap: 14px; align-items: center; margin-bottom: 16px; }
.av-top .ico { width: 64px; height: 64px; border-radius: 16px; flex: none; }
.av-top h3 { font-family: var(--display); font-size: 25px; font-weight: 600; line-height: 1.05; }
.av-top p { margin: 3px 0 0; font-size: 11.5px; color: var(--ink-soft); }
.av-tag { font-family: var(--display); font-style: italic; font-size: 18px; line-height: 1.3; margin: 0 0 12px; color: var(--emerald); }
.appview p.body { font-size: 13.5px; line-height: 1.6; margin: 0 0 14px; }
.appview h4 { font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-soft); margin: 18px 0 8px; font-family: var(--mono); font-weight: 600; }
.appview ul.pts { margin: 0; padding: 0; list-style: none; }
.appview ul.pts li { position: relative; padding: 0 0 10px 18px; font-size: 13px; line-height: 1.55; }
.appview ul.pts li::before { content: ""; position: absolute; left: 2px; top: 7px; width: 7px; height: 7px; border-radius: 2px; background: var(--gold); transform: rotate(45deg); }
.av-role { font-size: 12px; color: var(--ink-soft); margin: 0 0 4px; }
.av-link { display: inline-block; margin-top: 16px; padding: 10px 16px; border-radius: 999px; background: var(--forest); color: var(--cream); font-size: 13px; font-weight: 700; text-decoration: none; }
.chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.chips li { padding: 5px 10px; border-radius: 999px; font-size: 12px; font-weight: 600; background: rgba(31, 122, 77, .12); color: var(--emerald); }

/* Experience */
.panel-experience { background: linear-gradient(170deg, var(--paper) 0%, #f1e6cd 100%); color: var(--ink); }
html:not(.flat) .panel-experience.open { width: min(680px, calc(100vw - 40px)); }
.xp-head p { color: var(--ink-soft); margin: 0 0 22px; line-height: 1.6; }
.passes { display: flex; flex-direction: column; gap: 14px; }
.pass { --c: var(--emerald); position: relative; display: grid; grid-template-columns: 1fr 150px; background: #fffdf7; border-radius: 16px; box-shadow: 0 10px 26px rgba(40, 50, 30, .12), 0 1px 0 rgba(40, 50, 30, .08); overflow: hidden; animation: rise .5s var(--ease) both; }
.pass:nth-child(4n+2) { --c: var(--forest); }
.pass:nth-child(4n+3) { --c: #b8861a; }
.pass:nth-child(4n+4) { --c: var(--jade); }
.pass-main { padding: 0 20px 18px; }
.pass-band { display: flex; justify-content: space-between; align-items: center; margin: 0 -20px 14px; padding: 9px 20px; background: var(--c); color: var(--cream); font-family: var(--mono); font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; }
.pass-band b { font-weight: 600; }
.pass h3 { font-family: var(--display); font-weight: 600; font-size: 21px; line-height: 1.15; }
.pass-band.photo { background-size: cover; background-position: center; padding: 16px 20px; }
.pass-co { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.pass-co .role { margin: 2px 0 0; }
.co-logo { width: 44px; height: 44px; border-radius: 12px; flex: none; display: grid; place-items: center; overflow: hidden; box-shadow: 0 2px 8px rgba(16, 35, 28, .15), inset 0 0 0 1px rgba(16, 35, 28, .08); }
.co-logo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.co-logo.pad img { width: 72%; height: 72%; object-fit: contain; }
.co-logo.mono { background: var(--forest); color: var(--gold); font-family: var(--display); font-weight: 800; font-size: 20px; }
.pass .role { font-size: 13.5px; color: var(--ink-soft); font-weight: 600; }
.route { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.route .pt { font-family: var(--mono); }
.route .pt small { display: block; font-size: 9.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-soft); }
.route .pt b { font-size: 15px; font-weight: 600; }
.route .line { flex: 1; height: 1px; background: repeating-linear-gradient(90deg, var(--line) 0 6px, transparent 6px 11px); position: relative; }
.route .line svg { position: absolute; left: 50%; top: 50%; width: 18px; height: 18px; margin: -9px 0 0 -9px; color: var(--c); fill: var(--c); }
.pass ul { margin: 0; padding: 0; list-style: none; }
.pass li { font-size: 13px; line-height: 1.55; padding-left: 14px; position: relative; margin-bottom: 4px; }
.pass li::before { content: ""; position: absolute; left: 0; top: 8px; width: 5px; height: 5px; border-radius: 50%; background: var(--c); }
.pass-stub { position: relative; border-left: 2px dashed rgba(16, 35, 28, .16); padding: 48px 16px 16px; font-family: var(--mono); font-size: 10px; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-soft); display: flex; flex-direction: column; gap: 8px; }
.pass-stub::before, .pass-stub::after { content: ""; position: absolute; left: -9px; width: 16px; height: 16px; border-radius: 50%; background: #f3e9d3; }
.pass-stub::before { top: -8px; }
.pass-stub::after { bottom: -8px; }
.pass-stub .code { font-family: var(--display); font-size: 30px; font-weight: 800; letter-spacing: .02em; color: var(--c); line-height: 1; text-transform: none; }
.pass-stub .row { display: flex; justify-content: space-between; gap: 8px; }
.pass-stub .row b { color: var(--ink); font-weight: 600; }
.barcode { margin-top: auto; height: 34px; background: repeating-linear-gradient(90deg, var(--ink) 0 2px, transparent 2px 4px, var(--ink) 4px 5px, transparent 5px 8px, var(--ink) 8px 11px, transparent 11px 12px); opacity: .8; border-radius: 2px; }

/* About */
.panel-about { background: repeating-linear-gradient(180deg, transparent 0 31px, rgba(31, 122, 77, .1) 31px 32px), var(--paper); color: var(--ink); }
.journal h2 { color: var(--ink); }
.journal .lede { font-family: var(--display); font-style: italic; font-size: 21px; line-height: 1.4; color: var(--emerald); margin: 0 0 16px; }
.journal p { font-size: 15.5px; line-height: 1.75; margin: 0 0 16px; }
.kit { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin: 26px 0 22px; padding: 20px; border-radius: 18px; background: #fffdf7; box-shadow: 0 1px 0 var(--line); }
.kit h3 { font-family: var(--mono); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: #a87a14; margin-bottom: 10px; font-weight: 600; }
.edu { font-size: 14px !important; }
.edu .k, .addr .k { display: block; font-family: var(--mono); font-size: 10px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-soft); margin-bottom: 2px; }
/* a handwritten signature that writes itself in when About opens */
.sign { position: relative; display: inline-block; margin: 18px 0 0 !important; padding: 0 10px 18px 0; line-height: 1 !important; transform: rotate(-5deg); transform-origin: left bottom; }
.sign-name { display: block; font-family: "Mrs Saint Delafield", "Fraunces", cursive; font-size: 76px; font-weight: 400; color: var(--ink); white-space: nowrap; letter-spacing: .01em; clip-path: inset(0 0 0 0); }
.sign-flourish { position: absolute; left: 4%; bottom: 0; width: 92%; height: 34px; overflow: visible; }
.sign-flourish path { fill: none; stroke: var(--gold); stroke-width: 2.4; stroke-linecap: round; stroke-dasharray: 420; stroke-dashoffset: 0; }
#about.open .sign-name, html.flat .sign-name { animation: sign-write 1.6s cubic-bezier(.6, .1, .3, 1) .5s both; }
#about.open .sign-flourish path, html.flat .sign-flourish path { animation: sign-line 1s ease-out 1.9s both; }
@keyframes sign-write { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 -6% 0 0); } }
@keyframes sign-line { from { stroke-dashoffset: 420; } to { stroke-dashoffset: 0; } }
@media (max-width: 760px) { .sign-name { font-size: 60px; } }

/* Contact */
.panel-contact { background: radial-gradient(100% 70% at 0% 0%, rgba(232, 185, 49, .18), transparent 60%), linear-gradient(160deg, #1f7a4d, #0d2b22); color: var(--cream); }
.panel-contact .close { background: rgba(246, 239, 224, .14); color: var(--cream); }
.panel-contact .close:hover { background: rgba(246, 239, 224, .24); }
.panel-contact .kicker { color: var(--gold); }
html:not(.flat) .panel-contact.open { width: min(720px, calc(100vw - 40px)); }
.postcard { display: grid; grid-template-columns: 1.25fr 1fr; background: var(--paper); color: var(--ink); border-radius: 10px; box-shadow: 0 24px 60px rgba(3, 12, 9, .4); transform: rotate(-1deg); padding: 26px; position: relative; border: 10px solid var(--paper); outline: 2px dashed rgba(31, 122, 77, .35); outline-offset: -18px; }
.pc-left { padding-right: 24px; border-right: 1.5px solid var(--line); }
.pc-left h2 { color: var(--ink); }
.pc-left p { font-size: 15px; line-height: 1.65; color: var(--ink-soft); margin: 0 0 18px; }
.note label { display: block; margin-bottom: 12px; }
.note label span { display: block; font-family: var(--mono); font-size: 10px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-soft); margin-bottom: 4px; }
.note input, .note textarea { width: 100%; border: 0; border-bottom: 1.5px solid rgba(16, 35, 28, .25); background: transparent; padding: 6px 0; font: inherit; font-size: 15px; color: var(--ink); resize: vertical; }
.note input:focus, .note textarea:focus { outline: none; border-bottom-color: var(--emerald); }
.note .btn { margin-top: 6px; }
.pc-right { padding-left: 24px; display: flex; flex-direction: column; }
.stamp { align-self: flex-end; width: 64px; margin-bottom: 18px; transform: rotate(4deg); }
.stamp svg { width: 100%; fill: rgba(232, 185, 49, .3); stroke: var(--emerald); stroke-width: 2; stroke-linecap: round; }
.addr { list-style: none; margin: 0; padding: 0; }
.addr li { padding: 10px 0; border-bottom: 1.5px solid var(--line); font-size: 14.5px; font-weight: 600; word-break: break-word; }
.addr a { text-decoration: none; color: var(--ink); background: linear-gradient(var(--gold), var(--gold)) 0 100% / 0 2px no-repeat; transition: background-size .3s var(--ease); }
.addr a:hover { background-size: 100% 2px; }

/* Library */
.panel-library { background: linear-gradient(170deg, #f7efdc, #efe2c4); color: var(--ink); }
html:not(.flat) .panel-library.open { width: min(680px, calc(100vw - 40px)); }
.lib-intro { color: var(--ink-soft); margin: 0 0 22px; line-height: 1.6; }
.shelf { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px 18px; padding-bottom: 6px; }
.book { display: flex; flex-direction: column; gap: 6px; background: none; border: 0; padding: 0; text-align: left; color: var(--ink); animation: rise .5s var(--ease) both; }
.book img { width: 100%; aspect-ratio: 2 / 3; object-fit: cover; border-radius: 4px 8px 8px 4px; background: #e2d6bd; box-shadow: inset 4px 0 0 rgba(0, 0, 0, .12), 0 10px 22px rgba(40, 30, 10, .22); transition: transform .3s var(--ease), box-shadow .3s; }
.book:hover img { transform: translateY(-5px) rotate(-1deg); box-shadow: inset 4px 0 0 rgba(0, 0, 0, .12), 0 16px 30px rgba(40, 30, 10, .3); }
.b-title { font-family: var(--display); font-weight: 600; font-size: 15px; line-height: 1.2; }
.b-author { font-size: 12px; color: var(--ink-soft); }
.lib-back { background: none; border: 0; padding: 4px 0; margin-bottom: 16px; color: var(--emerald); font-weight: 700; font-size: 14px; }
.lib-top { display: flex; gap: 20px; align-items: flex-end; margin-bottom: 20px; }
.lib-top img { width: 130px; aspect-ratio: 2 / 3; object-fit: cover; border-radius: 4px 8px 8px 4px; flex: none; box-shadow: inset 4px 0 0 rgba(0, 0, 0, .12), 0 14px 28px rgba(40, 30, 10, .28); }
.lib-top h3 { font-family: var(--display); font-weight: 600; font-size: 26px; line-height: 1.1; }
.b-meta { margin: 6px 0 0; font-size: 13px; color: var(--ink-soft); }
.lib-book h4 { font-family: var(--mono); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: #a87a14; margin: 18px 0 6px; font-weight: 600; }
.lib-book p { font-size: 15px; line-height: 1.7; margin: 0; }
.lib-book .take { font-family: var(--display); font-style: italic; font-size: 18px; line-height: 1.55; color: var(--emerald); padding-left: 14px; border-left: 3px solid var(--gold); }
@media (max-width: 760px) {
  .shelf { gap: 18px 12px; }
  .lib-top img { width: 104px; }
  .lib-top h3 { font-size: 22px; }
}

/* From home: recipes, football, laamb */
.panel-book { background: linear-gradient(170deg, #fbf3e2, #f3e3c3); color: var(--ink); }
html:not(.flat) .panel-book.open { width: min(680px, calc(100vw - 40px)); }
.book-tabs { display: flex; gap: 6px; margin: 4px 0 20px; padding: 4px; border-radius: 999px; background: rgba(16, 35, 28, .07); width: fit-content; }
.book-tabs button { border: 0; border-radius: 999px; padding: 8px 16px; font-size: 13.5px; font-weight: 700; background: none; color: var(--ink-soft); }
.book-tabs button[aria-selected="true"] { background: var(--forest); color: var(--cream); }
.book-intro { color: var(--ink-soft); margin: 0 0 18px; line-height: 1.6; }
.dishes { display: flex; flex-direction: column; gap: 12px; }
.dish { display: grid; grid-template-columns: 96px 1fr; gap: 16px; align-items: center; text-align: left; padding: 10px; border: 0; border-radius: 18px; background: #fffaf0; box-shadow: 0 1px 0 var(--line), 0 8px 20px rgba(60, 40, 10, .08); color: var(--ink); transition: transform .25s var(--ease), box-shadow .25s; animation: rise .45s var(--ease) both; }
.dish:hover { transform: translateY(-2px); box-shadow: 0 1px 0 var(--line), 0 14px 28px rgba(60, 40, 10, .14); }
.dish img { width: 96px; height: 96px; object-fit: cover; border-radius: 14px; }
.d-text { display: flex; flex-direction: column; gap: 2px; }
.d-text b { font-family: var(--display); font-size: 19px; font-weight: 600; }
.d-text small { font-family: var(--mono); font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: #a87a14; }
.d-text span { font-size: 13.5px; line-height: 1.5; color: var(--ink-soft); margin-top: 4px; }
.recipe-top { display: flex; gap: 18px; align-items: center; margin-bottom: 14px; }
.recipe-top img { width: 120px; height: 120px; object-fit: cover; border-radius: 18px; flex: none; box-shadow: 0 10px 24px rgba(60, 40, 10, .2); }
.recipe-top h3 { font-family: var(--display); font-size: 28px; font-weight: 600; line-height: 1.05; }
.r-meta { margin: 6px 0 0; font-size: 12.5px; font-weight: 700; color: var(--emerald); }
.r-intro { font-size: 15px; line-height: 1.7; margin: 0 0 6px; }
.panel-book h4 { font-family: var(--mono); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase; color: #a87a14; margin: 18px 0 8px; font-weight: 600; }
.r-ing { margin: 0; padding: 0; list-style: none; columns: 2; column-gap: 22px; }
.r-ing li { break-inside: avoid; font-size: 14px; line-height: 1.5; padding: 0 0 8px 16px; position: relative; }
.r-ing li::before { content: ""; position: absolute; left: 0; top: 8px; width: 6px; height: 6px; border-radius: 50%; background: var(--gold); }
.r-steps { margin: 0; padding: 0; list-style: none; counter-reset: step; }
.r-steps li { counter-increment: step; position: relative; padding: 0 0 12px 38px; font-size: 14.5px; line-height: 1.6; }
.r-steps li::before { content: counter(step); position: absolute; left: 0; top: 0; width: 26px; height: 26px; border-radius: 50%; background: var(--forest); color: var(--cream); font-size: 12px; font-weight: 700; display: grid; place-items: center; }
.club { background: #fffaf0; border-radius: 20px; padding: 18px 20px 20px; margin-bottom: 16px; box-shadow: 0 1px 0 var(--line), 0 8px 20px rgba(60, 40, 10, .08); overflow: hidden; }
.club p { font-size: 14.5px; line-height: 1.7; margin: 0 0 10px; }
.club-head { display: flex; align-items: center; gap: 14px; margin-bottom: 12px; }
.club-head h3 { font-family: var(--display); font-size: 24px; font-weight: 600; line-height: 1.1; }
.club-sub { margin: 2px 0 0 !important; font-family: var(--mono); font-size: 10.5px !important; letter-spacing: .12em; text-transform: uppercase; color: #a87a14; }
.crest { width: 64px; height: 64px; object-fit: contain; border-radius: 12px; background: #f6f6f6; flex: none; }
.banner { display: block; width: calc(100% + 40px); margin: -18px -20px 14px; height: 190px; object-fit: cover; }
.banner.tall { height: 300px; object-position: center 30%; }
.club .take { font-family: var(--display); font-style: italic; font-size: 17px; line-height: 1.5; color: var(--emerald); padding-left: 14px; border-left: 3px solid var(--gold); margin: 14px 0 0; }
@media (max-width: 760px) {
  .r-ing { columns: 1; }
  .dish { grid-template-columns: 80px 1fr; }
  .dish img { width: 80px; height: 80px; }
  .recipe-top img { width: 96px; height: 96px; }
  .banner.tall { height: 240px; }
}

/* ---------- Explore sheet ---------- */
.explore {
  position: fixed; z-index: 46; left: 176px; top: 50%; width: 360px;
  padding: 14px; border-radius: 22px;
  background: rgba(8, 28, 22, .94); border: 1px solid var(--glass-line); color: var(--cream);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 24px 60px rgba(0, 0, 0, .45);
  opacity: 0; transform: translate(-8px, -50%); transition: opacity .25s var(--ease), transform .3s var(--ease);
}
.explore.in { opacity: 1; transform: translate(0, -50%); }
.explore[hidden] { display: none; }
.ex-head { display: flex; align-items: center; justify-content: space-between; margin: 0 2px 12px 4px; }
.ex-head b { font-family: var(--display); font-size: 18px; font-weight: 600; }
.ex-x { width: 32px; height: 32px; border-radius: 50%; border: 0; background: rgba(246, 239, 224, .08); font-size: 20px; line-height: 1; }
.ex-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.ex-grid button {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px;
  min-height: 86px; padding: 10px 6px; border-radius: 16px; border: 1px solid var(--glass-line);
  background: rgba(246, 239, 224, .05); font-size: 12.5px; font-weight: 700; line-height: 1.2; text-align: center;
  transition: background .2s, border-color .2s;
}
.ex-grid button:hover, .ex-grid button:active { background: rgba(232, 185, 49, .14); border-color: rgba(232, 185, 49, .5); }
.ex-grid svg { width: 24px; height: 24px; fill: none; stroke: var(--gold); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
html.flat .ex-grid [data-ex="flag"], html.flat .ex-grid [data-ex="ball"], html.flat .ex-grid [data-ex="night"], html.flat .ex-grid [data-ex="sound"] { display: none; }
html.og .explore { display: none !important; }

/* ?og: nothing but the scene, for the link preview image */
html.og .loader, html.og .sig, html.og .stops, html.og .hud, html.og .tip, html.og .bubble, html.og .drag-hint, html.og .intro, html.og .chat, html.og .music { display: none !important; }

/* ---------- Page view ---------- */
html.flat body { overflow: auto; background: var(--forest); }
html.flat #scene, html.flat .markers, html.flat .tip, html.flat .drag-hint, html.flat .intro, html.flat .sig, html.flat .close, html.flat .bubble { display: none !important; }
html.flat .loader { display: none; }
html.flat .hud { opacity: 1; }
html.no-gl #view-btn { display: none; }
html.flat .hud #time-btn, html.flat .hud #sound-btn { display: none; }
html.flat .stops { opacity: 1; left: 50%; top: 18px; transform: translateX(-50%); flex-direction: row; padding: 5px; border-radius: 999px; }
html.flat .stops button { padding: 7px 14px 7px 10px; border-radius: 999px; }
html.flat #content { max-width: 960px; margin: 0 auto; padding: 96px 20px 40px; display: flex; flex-direction: column; gap: 28px; }
html.flat .flat-hero { display: block; padding: 60px 8px 30px; }
html.flat .flat-name { font-family: var(--display); font-weight: 800; font-size: clamp(52px, 9vw, 110px); line-height: .95; letter-spacing: -.02em; color: var(--cream); }
html.flat .flat-line { font-family: var(--display); font-style: italic; font-size: clamp(20px, 2.6vw, 28px); margin: 14px 0 0; color: var(--cream); }
html.flat .flat-note { font-size: 13px; color: rgba(246, 239, 224, .55); margin: 18px 0 0; display: none; }
html.no-gl .flat-note { display: block; }
html.flat .flat-hero .kicker { color: var(--gold); }
html.flat .panel { display: block; border-radius: 28px; padding: 30px; scroll-margin-top: 80px; }
html.flat .phone { position: static; }
html.flat .flat-foot { display: block; text-align: center; color: rgba(246, 239, 224, .55); font-size: 13px; padding: 10px 0 30px; }

/* ---------- Smaller screens ---------- */
@media (min-width: 761px) {
  body.panel-open .stops .l { display: none; }
  body.panel-open .stops button { padding: 9px 10px; }
  body.panel-open .sig { opacity: 0; }
}
@media (max-width: 860px) {
  .proj-wrap { grid-template-columns: 1fr; }
  .phone { position: static; display: flex; justify-content: center; order: -1; }
  .proj-intro { order: 1; }
  .proj-index { display: none; }
}
@media (max-width: 760px) {
  .build-target { display: none; }
  .sig { left: 18px; top: calc(16px + env(safe-area-inset-top)); bottom: auto; }
  .sig-name { font-size: 20px; }
  .sig-meta { font-size: 9.5px; }
  .hud { top: auto; right: 14px; bottom: calc(86px + env(safe-area-inset-bottom)); flex-direction: column; align-items: flex-end; }
  .hud-label { display: none; }
  .hud-btn { width: 42px; padding: 0; justify-content: center; }
  html.flat .hud { bottom: auto; top: 14px; flex-direction: row; }
  html.flat .hud-btn { width: auto; padding: 0 12px; }
  html.flat .hud .hud-label { display: inline; }
  .stops { left: 10px; right: 10px; top: auto; bottom: calc(10px + env(safe-area-inset-bottom)); transform: none; flex-direction: row; justify-content: space-around; gap: 0; padding: 6px; }
  .stops button { flex-direction: column; gap: 3px; padding: 7px 4px; flex: 1; border-radius: 16px; align-items: center; }
  .stops .l { font-size: 10.5px; }
  html.flat .stops { left: 10px; right: 10px; top: auto; bottom: calc(10px + env(safe-area-inset-bottom)); transform: none; padding: 6px; border-radius: 22px; }
  html.flat .stops button { padding: 7px 4px; border-radius: 16px; }
  html.flat #content { padding: 70px 14px 100px; }
  html.flat .panel { padding: 24px 18px; }
  html:not(.flat) .panel.open { inset: 0 !important; width: auto !important; max-height: none; border-radius: 0; padding: calc(18px + env(safe-area-inset-top)) 18px 110px; }
  body.panel-open .hud, body.panel-open .sig { opacity: 0; pointer-events: none; }
  .drag-hint { bottom: calc(96px + env(safe-area-inset-bottom)); }
  /* phones: the Explore tab holds everything the corner buttons did */
  html:not(.flat) .hud { display: none; }
  .explore { left: 10px; right: 10px; top: auto; width: auto; bottom: calc(84px + env(safe-area-inset-bottom)); transform: translateY(12px); padding: 12px; }
  .explore.in { transform: none; }
  .ex-grid button { min-height: 80px; font-size: 12px; }
  .stops .l { font-size: 10px; }
  .music { left: 10px; right: 10px; width: auto; bottom: calc(80px + env(safe-area-inset-bottom)); }
  .music.mini { right: auto; }
  body.panel-open .music.mini { opacity: 0; pointer-events: none; }
  .chat { right: 10px; left: 10px; width: auto; bottom: calc(80px + env(safe-area-inset-bottom)); height: min(60vh, 520px); }
  .chat-form input { font-size: 16px; }
  .bubble { max-width: 200px; }
  .pass { grid-template-columns: 1fr; }
  .pass-stub { border-left: 0; border-top: 2px dashed rgba(16, 35, 28, .16); padding: 14px 20px 16px; display: grid; grid-template-columns: auto 1fr 1fr; align-items: center; gap: 6px 16px; }
  .pass-stub::before, .pass-stub::after { top: -9px; bottom: auto; }
  .pass-stub::before { left: -8px; }
  .pass-stub::after { left: auto; right: -8px; }
  .pass-stub .code { grid-row: span 2; }
  .pass-stub .barcode { display: none; }
  .postcard { grid-template-columns: 1fr; transform: none; padding: 18px; }
  .pc-left { padding: 0 0 20px; border-right: 0; border-bottom: 1.5px solid var(--line); }
  .pc-right { padding: 18px 0 0; }
  .stamp { position: absolute; top: 18px; right: 18px; width: 46px; }
  .kit { grid-template-columns: 1fr; }
  .phone-frame { width: min(330px, calc(100vw - 36px)); height: 640px; max-height: none; }
  .apps { gap: 16px 6px; }
  .ico { width: 54px; height: 54px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
