/* ============================================================
   Carlos E. Costa — portfolio · "lab notebook"
   ============================================================ */

:root {
  --backdrop: #eef1ec;
  --grid: #e1e6de;
  --sheet: #fdfdfa;
  --rule: #efeee7;
  --line: #dcdcd3;

  --ink: #232622;
  --ink-2: #555a53;
  --muted: #8d928b;

  --brand: #7d9d86;          /* sage from the logo */
  --brand-deep: #46524a;
  --coral: #e07a5f;

  --sky: #e1ecf7;    --sky-ink: #3c6893;    --sky-mid: #c4d9ee;
  --butter: #f8eec9; --butter-ink: #86690f; --butter-mid: #efdf9f;
  --sage: #dfeadf;   --sage-ink: #3f5546;   --sage-mid: #c3d8c6;
  --blush: #f8e2dc;  --blush-ink: #9c4634;  --blush-mid: #efc6bb;

  --serif: "Instrument Serif", Georgia, serif;
  --sans: "DM Sans", "Inter", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, Menlo, monospace;
  --hand: "Cedarville Cursive", "Snell Roundhand", cursive;

  --pad: clamp(16px, 5vw, 72px);
  --ease: cubic-bezier(.2, .7, .1, 1);
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  color: var(--ink);
  font: 400 16px/1.65 var(--sans);
  -webkit-font-smoothing: antialiased;
  background-color: var(--backdrop);
  background-image:
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 40px 40px;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
::selection { background: var(--sage-mid); }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; border-radius: 2px; }

.mono { font-family: var(--mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; }
.hand { font-family: var(--hand); font-weight: 400; letter-spacing: .01em; }

/* ---------------- Sheet ---------------- */
.sheet {
  max-width: 1180px;
  margin: clamp(0px, 3vw, 40px) auto;
  background-color: var(--sheet);
  background-image: linear-gradient(transparent 31px, var(--rule) 31px);
  background-size: 100% 32px;
  box-shadow: 0 1px 0 rgba(0,0,0,.03), 0 18px 50px -20px rgba(60, 70, 60, .18);
}

/* ---------------- Top bar ---------------- */
.topbar {
  position: sticky; top: 0; z-index: 30;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 16px;
  padding: 12px var(--pad);
  background: color-mix(in srgb, var(--sheet) 88%, transparent);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.brand { display: inline-flex; color: var(--brand); width: max-content; transition: transform .5s var(--ease); }
.brand:hover { transform: rotate(-20deg); }
.brand .mark { width: 36px; height: 36px; object-fit: contain; opacity: .6; transition: opacity .3s; }
.brand:hover .mark { opacity: .9; }
.nav { display: flex; gap: 6px; }
.nav a {
  font-family: var(--mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase;
  padding: 7px 12px; border-radius: 3px; transition: background .25s var(--ease);
}
.nav a:hover { background: var(--sage); }
.nav a.active { background: var(--butter); }
.top-right { display: flex; justify-content: flex-end; align-items: center; gap: 8px; }
.top-right .btn { margin-left: 4px; }
.dot {
  width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center;
  font: 500 10px var(--mono); border: 1px solid var(--line); color: var(--ink-2);
  transition: all .25s var(--ease);
}
.dot:nth-child(1):hover { background: var(--sky); border-color: var(--sky-mid); }
.dot:nth-child(2):hover { background: var(--blush); border-color: var(--blush-mid); }

.btn {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase;
  padding: 10px 16px; border-radius: 3px; transition: transform .25s var(--ease), background .25s, box-shadow .25s;
}
.btn-ink { background: var(--ink); color: var(--sheet); box-shadow: 3px 3px 0 var(--brand); }
.btn-ink:hover { transform: translate(-1px, -1px); box-shadow: 4px 4px 0 var(--brand); }
.btn-line { border: 1px solid var(--ink); }
.btn-line:hover { background: var(--sage); }

/* ---------------- Tape (placed in different spots) ---------------- */
.tape {
  position: absolute; z-index: 2; width: 92px; height: 24px;
  background: color-mix(in srgb, var(--tape, var(--butter-mid)) 78%, transparent);
  box-shadow: 0 1px 1px rgba(0,0,0,.04);
}
.t-top { top: -12px; left: 50%; margin-left: -46px; transform: rotate(-3deg); }
.t-tl  { top: 6px; left: -26px; transform: rotate(-38deg); }
.t-tr  { top: 4px; right: -24px; transform: rotate(36deg); }
.t-br  { bottom: 6px; right: -26px; transform: rotate(-35deg); }
.t-bl  { bottom: 4px; left: -24px; transform: rotate(40deg); }
.t-side{ top: 38%; right: -30px; transform: rotate(84deg); width: 76px; }

/* ---------------- Hero ---------------- */
.hero {
  text-align: center;
  padding: clamp(72px, 13vh, 132px) var(--pad) clamp(80px, 13vh, 136px);
  display: flex; flex-direction: column; align-items: center;
  overflow: hidden;
}
.hello { margin: 0 0 6px; font-size: 22px; color: var(--ink-2); display: inline-flex; flex-direction: column; align-items: center; line-height: 1; }
.hello svg { width: 54px; margin-top: 4px; color: var(--muted); }
.name-wrap { position: relative; display: inline-block; padding: 26px clamp(24px, 4vw, 52px) 24px; margin: 26px 0 64px; }
.name {
  margin: 0; font-family: var(--serif); font-weight: 400;
  font-size: clamp(46px, 9vw, 116px); line-height: .95; letter-spacing: -.02em;
}
.scribble-box { position: absolute; inset: 0; width: 100%; height: 100%; color: var(--coral); pointer-events: none; }
.sticker {
  position: absolute; white-space: nowrap; z-index: 1;
  font-family: var(--hand); font-weight: 400; font-size: 15px; line-height: 1;
  padding: 7px 11px 5px; border-radius: 3px;
  box-shadow: 0 1px 2px rgba(0,0,0,.06);
}
.sticker.tl { left: -54px; top: -16px; rotate: -5deg; }
.sticker.tr { right: -50px; top: -14px; rotate: 4deg; }
.sticker.bl { left: -42px; bottom: -14px; rotate: 3deg; }
.sticker.br { right: -46px; bottom: -16px; rotate: -4deg; }
.s-sage  { background: var(--sage);   color: var(--sage-ink); }
.s-blush { background: var(--blush);  color: var(--blush-ink); }
.s-butter{ background: var(--butter); color: var(--butter-ink); }
.s-sky   { background: var(--sky);    color: var(--sky-ink); }
.tagline {
  margin: 0 auto; max-width: 760px;
  font-family: var(--sans); font-weight: 600; letter-spacing: -.025em;
  font-size: clamp(26px, 3.6vw, 42px); line-height: 1.18;
}
.tagline em { font-family: var(--serif); font-weight: 400; font-size: 1.12em; color: var(--brand-deep); }
.hero-cta { display: flex; justify-content: center; flex-wrap: wrap; gap: 14px; margin-top: 36px; }

/* ---------------- Shared ---------------- */
.margin-note { margin: 0; font-size: 21px; color: var(--muted); rotate: -2deg; }
.section-title {
  margin: 0; font-family: var(--serif); font-weight: 400;
  font-size: clamp(40px, 5vw, 60px); line-height: 1; letter-spacing: -.01em;
}

/* ---------------- About ---------------- */
.about {
  display: grid; grid-template-columns: minmax(0, 320px) minmax(0, 1fr); gap: clamp(36px, 7vw, 104px); align-items: center;
  padding: clamp(80px, 13vh, 128px) var(--pad);
  border-top: 1px dashed var(--line);
}
.polaroid {
  position: relative; margin: 0; background: #fff; padding: 12px 12px 34px;
  box-shadow: 0 2px 4px rgba(0,0,0,.05), 0 14px 30px -12px rgba(0,0,0,.18);
  will-change: translate;
}
.polaroid img { aspect-ratio: 4 / 5; object-fit: cover; object-position: 40% 50%; width: 100%; filter: grayscale(.15); }
.tilt-l { rotate: -3deg; }
.about-text { max-width: 600px; }
.about-text .section-title { margin-bottom: 14px; }
.about-text .subtitle { margin: 0 0 22px; font-family: var(--serif); font-style: italic; font-size: 19px; line-height: 1.3; color: var(--brand-deep); }
.about-text p { margin: 0 0 16px; color: var(--ink-2); font-size: 17px; }
.about-text .quote { font-size: 21px; color: var(--brand-deep); margin: 22px 0 26px; }
.chips { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, max-content); gap: 10px; }
.chips li { display: contents; }
.chips a { font-size: 13px; font-weight: 500; padding: 6px 14px; border-radius: 999px; text-align: center; transition: filter .25s, transform .25s var(--ease); }
.chips a:hover { filter: brightness(.96); transform: translateY(-1px); }
.c-sky { background: var(--sky); color: var(--sky-ink); }
.c-butter { background: var(--butter); color: var(--butter-ink); }
.c-sage { background: var(--sage); color: var(--sage-ink); }
.c-blush { background: var(--blush); color: var(--blush-ink); }

/* ---------------- Work / folders ---------------- */
.work { padding: clamp(72px, 11vh, 112px) var(--pad) clamp(56px, 8vh, 88px); border-top: 1px dashed var(--line); }
.work-head { margin-bottom: 36px; }
.work-head .margin-note { margin-top: 10px; }

.folders { --tab-h: 46px; }
.tabs { display: flex; align-items: flex-end; gap: 14px; padding: 0 12px 0 0; overflow-x: auto; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tab {
  position: relative; flex: none;
  display: flex; align-items: center; gap: 10px;
  height: calc(var(--tab-h) - 8px); padding: 0 18px;
  font-family: var(--mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase;
  border-radius: 10px 10px 0 0;
  background: var(--tab-bg); color: var(--tab-ink);
  opacity: .7;
  transition: height .3s var(--ease), opacity .3s var(--ease);
}
.tab:hover { opacity: 1; }
.tab[aria-selected="true"] { height: var(--tab-h); opacity: 1; }
.tab .n { opacity: .55; }
.tab sup { font-size: 9px; opacity: .7; }
.tab::after {
  content: ""; position: absolute; right: -12px; bottom: 0; width: 13px; height: 100%;
  background: var(--tab-bg); clip-path: polygon(0 0, 0 100%, 100% 100%);
}
.tab[data-color="sky"], .panel[data-color="sky"]       { --tab-bg: var(--sky);    --tab-ink: var(--sky-ink);    --tab-mid: var(--sky-mid); }
.tab[data-color="butter"], .panel[data-color="butter"] { --tab-bg: var(--butter); --tab-ink: var(--butter-ink); --tab-mid: var(--butter-mid); }
.tab[data-color="sage"], .panel[data-color="sage"]     { --tab-bg: var(--sage);   --tab-ink: var(--sage-ink);   --tab-mid: var(--sage-mid); }
.tab[data-color="blush"], .panel[data-color="blush"]   { --tab-bg: var(--blush);  --tab-ink: var(--blush-ink);  --tab-mid: var(--blush-mid); }

.panel {
  background: var(--tab-bg); --tape: var(--tab-mid);
  border-radius: 0 12px 12px 12px;
  padding: clamp(20px, 4vw, 48px);
  transition: background-color .4s var(--ease);
  min-height: 420px;
}
.panel:focus-visible { outline-offset: -2px; }
.panel-in { animation: panelIn .5s var(--ease); }
@keyframes panelIn { from { opacity: 0; transform: translateY(8px); } }
.panel-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 12px 32px; margin-bottom: 32px; }
.panel-head h3 { margin: 0; font-family: var(--serif); font-weight: 400; font-size: clamp(34px, 4vw, 48px); line-height: 1; color: var(--ink); }
.panel-head p { margin: 0; max-width: 460px; font-size: 14px; color: var(--ink-2); }

/* featured card */
.feature {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr); gap: clamp(24px, 4vw, 56px); align-items: center;
  background: var(--sheet); border-radius: 10px; padding: clamp(18px, 3vw, 36px);
  margin-bottom: 28px;
}
.meta-line { color: var(--tab-ink); display: flex; align-items: center; gap: 8px; margin: 0 0 14px; }
.meta-line::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.feature h4 { margin: 0 0 10px; font-family: var(--sans); font-weight: 600; font-size: clamp(26px, 3vw, 38px); line-height: 1.08; letter-spacing: -.02em; }
.feature p { margin: 0 0 6px; color: var(--ink-2); font-size: 14px; }
.feature .note { color: var(--muted); font-size: 13px; }
.feature .go { margin-top: 18px; display: inline-flex; border-bottom: 1px solid currentColor; padding-bottom: 2px; }
.shot { position: relative; display: block; width: 100%; }
.shot img, .shot .embed { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 4px; background: var(--tab-mid); }
.shot.contain img { object-fit: contain; background: #fff; }
.shot .embed { border: 0; display: block; background: #000; }
.shot .play {
  position: absolute; left: 14px; bottom: 14px;
  background: var(--sheet); padding: 7px 12px; border-radius: 3px;
  transition: transform .3s var(--ease);
}
.shot:hover .play { transform: translateY(-3px); }
.shot .play.icon { left: auto; right: 14px; width: 34px; height: 34px; padding: 0; display: grid; place-items: center; font-size: 16px; }

/* rows */
.subhead { margin: 34px 0 6px; color: var(--tab-ink); display: flex; align-items: center; gap: 12px; }
.subhead::after { content: ""; flex: 1; height: 1px; background: color-mix(in srgb, var(--tab-ink) 25%, transparent); }
.rows { list-style: none; margin: 0; padding: 0; }
.rows > li + li { border-top: 1px solid color-mix(in srgb, var(--tab-ink) 14%, transparent); }
.row {
  width: 100%; text-align: left;
  display: grid; grid-template-columns: 96px minmax(0, 1fr) auto; gap: 20px; align-items: center;
  padding: 12px 10px; border-radius: 6px;
  transition: background .25s var(--ease);
}
.row:hover, li.open > .row { background: color-mix(in srgb, var(--sheet) 60%, transparent); }
.row .th { display: block; width: 96px; aspect-ratio: 16 / 9; border-radius: 3px; overflow: hidden; background: var(--tab-mid); }
.row .th img { width: 100%; height: 100%; object-fit: cover; }
.row .th.wave { display: flex; align-items: center; gap: 2px; padding: 0 8px; }
.row .th.wave i { flex: 1; background: var(--tab-ink); opacity: .5; border-radius: 1px; }
.row b { display: block; font-weight: 500; font-size: 16px; line-height: 1.3; }
.row small { display: block; font-size: 13px; color: var(--ink-2); }
.row .end { display: flex; align-items: center; gap: 16px; color: var(--tab-ink); }
.row .arr { display: inline-block; transition: transform .3s var(--ease); }
.row:hover .arr { transform: translateX(4px); }
li.open .row .arr { transform: rotate(90deg); }
.player { padding: 6px 10px 18px; animation: panelIn .4s var(--ease); }
.player iframe { display: block; width: 100%; border: 0; border-radius: 6px; }
.player iframe.yt { aspect-ratio: 16 / 9; background: #000; }
.player iframe.sc { height: 120px; }
.more { margin-top: 16px; color: var(--tab-ink); border-bottom: 1px solid currentColor; padding-bottom: 2px; }

/* image: sub-tabs */
.subtabs { display: flex; flex-wrap: wrap; gap: 8px; margin: -8px 0 28px; }
.subtabs button {
  font-family: var(--mono); font-size: 11px; letter-spacing: .06em; text-transform: uppercase;
  padding: 7px 14px; border-radius: 999px; border: 1px solid color-mix(in srgb, var(--tab-ink) 35%, transparent); color: var(--tab-ink);
  transition: background .25s var(--ease);
}
.subtabs button[aria-pressed="true"] { background: var(--sheet); border-color: var(--sheet); }

/* image: illustration cards */
.cards { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.card {
  display: flex; flex-direction: column; width: 100%; height: 100%; text-align: left;
  background: var(--sheet); border-radius: 10px; padding: 14px 14px 18px;
  transition: transform .35s var(--ease), box-shadow .35s var(--ease);
}
.card:hover { transform: translateY(-4px); box-shadow: 0 16px 30px -18px rgba(0,0,0,.3); }
.card img { width: 100%; aspect-ratio: 4 / 3; object-fit: contain; background: #fff; border-radius: 4px; }
.card .mono { color: var(--tab-ink); margin: 16px 0 6px; }
.card b { font-weight: 500; font-size: 16px; line-height: 1.3; }

/* image: photography (original ratios) */
.photos { columns: 3 220px; column-gap: 18px; }
.photos button { display: block; width: 100%; margin: 0 0 18px; break-inside: avoid; }
.photos img { width: 100%; height: auto; border-radius: 4px; transition: filter .4s var(--ease), transform .4s var(--ease); }
.photos button:hover img { filter: brightness(1.05); transform: scale(.985); }

/* image: logos (frequency map, 3 levels) */
.logo-wrap { container-type: inline-size; }
.logos {
  --gap: 14px;
  list-style: none; margin: 0; padding: 0; display: grid; gap: var(--gap);
  grid-template-columns: repeat(11, minmax(0, 1fr));
  grid-auto-rows: calc((100cqw - 10 * var(--gap)) / 11);
}
.logos li { grid-column: span 2; grid-row: span 2; }
.logos li.l1 { grid-column: span 4; grid-row: span 4; }
.logos li.l2 { grid-column: span 3; grid-row: span 3; }
.logo {
  position: relative; display: block; width: 100%; height: 100%; overflow: hidden;
  border-radius: 10px; background: #fff;
  transition: transform .35s var(--ease), box-shadow .35s var(--ease);
}
.logo img { width: 100%; height: 100%; object-fit: cover; }
.logo:hover { transform: translateY(-3px) scale(1.01); box-shadow: 0 16px 30px -18px rgba(0,0,0,.3); }

/* songs */
.strip {
  position: relative; height: clamp(200px, 30vw, 340px); border-radius: 10px; overflow: hidden;
  margin-bottom: 40px; background: #222;
}
.strip img { position: absolute; left: 0; width: 100%; height: 135%; top: -17%; object-fit: cover; will-change: transform; }
.disc { list-style: none; margin: 0; padding: 0; max-width: 760px; }
.disc > li { display: grid; grid-template-columns: 132px minmax(0, 1fr); gap: 28px; align-items: start; padding: 28px 0; border-top: 1px solid color-mix(in srgb, var(--tab-ink) 20%, transparent); }
.disc > li:first-child { border-top: 0; padding-top: 0; }
.disc .mono { color: var(--tab-ink); }
.disc h4 { margin: 6px 0 4px; font-family: var(--serif); font-weight: 400; font-size: 32px; line-height: 1.05; }
.disc p { margin: 0 0 12px; font-size: 14px; color: var(--ink-2); }
.disc a.mono { border-bottom: 1px solid currentColor; }
.cover { display: block; width: 132px; aspect-ratio: 1; border-radius: 4px; overflow: hidden; box-shadow: 0 8px 18px -10px rgba(0,0,0,.4); }
.cover img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.cover:hover img { transform: scale(1.04); }
.spotify-slot { grid-column: 1 / -1; margin-top: 2px; border-radius: 12px; overflow: hidden; }
.spotify-slot iframe { display: block; width: 100%; height: 152px; border: 0; }
.photo-row { display: grid; grid-template-columns: 1.1fr .62fr 1.15fr 1.3fr; align-items: center; gap: clamp(18px, 3vw, 40px); margin-top: 48px; padding: 0 8px; }
.photo-row figure { position: relative; margin: 0; background: #fff; padding: 8px; box-shadow: 0 10px 24px -14px rgba(0,0,0,.3); }
.photo-row figure img { width: 100%; }
.photo-row figure:nth-child(1) { rotate: -1.8deg; }
.photo-row figure:nth-child(2) { rotate: 1.5deg; }
.photo-row figure:nth-child(3) { rotate: -1deg; }
.photo-row figure:nth-child(4) { rotate: 1.8deg; }

/* ---------------- Contact ---------------- */
.contact { text-align: center; padding: clamp(80px, 13vh, 136px) var(--pad) clamp(56px, 9vh, 96px); border-top: 1px dashed var(--line); }
.contact .margin-note { margin-bottom: 14px; display: inline-block; }
.contact-title { margin: 0 0 36px; font-weight: 600; letter-spacing: -.025em; font-size: clamp(28px, 4vw, 48px); line-height: 1.15; }
.contact-title em { font-family: var(--serif); font-weight: 400; color: var(--brand-deep); }
.contact-row { display: flex; justify-content: center; flex-wrap: wrap; align-items: center; gap: 14px; }
.email {
  font-family: var(--serif); font-size: clamp(26px, 3.4vw, 40px);
  background: linear-gradient(var(--butter-mid), var(--butter-mid)) 0 88% / 100% 10px no-repeat;
  padding: 0 4px; transition: background-size .4s var(--ease);
  word-break: break-all;
}
.email:hover { background-size: 100% 70%; }
.where { margin: 26px 0 0; color: var(--muted); }
.socials { list-style: none; padding: 0; margin: 14px 0 0; display: flex; justify-content: center; flex-wrap: wrap; gap: 10px 28px; color: var(--ink-2); }
.socials a:hover { color: var(--ink); }

/* ---------------- Easter egg: petri dish ---------------- */
.lab {
  display: grid; grid-template-columns: auto minmax(0, 320px); justify-content: center; align-items: center; gap: clamp(24px, 5vw, 64px);
  padding: clamp(40px, 7vh, 72px) var(--pad) clamp(64px, 10vh, 104px);
  border-top: 1px dashed var(--line);
}
.dish-wrap { position: relative; width: min(280px, 72vw); }
.dish {
  display: block; width: 100%; aspect-ratio: 1; border-radius: 50%; cursor: pointer;
  background: radial-gradient(circle at 35% 30%, #ffffff 0%, #f3f6f1 55%, #e7ede5 100%);
  box-shadow: inset 0 0 0 6px rgba(255,255,255,.9), inset 0 0 0 7px var(--line), 0 18px 36px -20px rgba(60,70,60,.35);
  touch-action: manipulation;
}
.dish-hint { position: absolute; right: -44px; top: -14px; margin: 0; font-size: 19px; color: var(--muted); rotate: 8deg; transition: opacity .5s; pointer-events: none; }
.dish-hint.gone { opacity: 0; }
.lab-notes .mono { color: var(--muted); margin: 0 0 8px; }
.lab-line { margin: 0; font-size: 15px; color: var(--ink-2); }
.lab-line .count { font-family: var(--mono); font-size: 12px; color: var(--brand-deep); background: var(--sage); padding: 2px 8px; border-radius: 999px; margin-left: 4px; white-space: nowrap; }
.lab-msg { margin: 14px 0 0; font-family: var(--hand); font-size: 19px; color: var(--brand-deep); line-height: 1.55; }
.lab-msg a { font-weight: 700; text-decoration: underline; text-underline-offset: 3px; border: 0; }
.lab-msg a { border-bottom: 1px solid currentColor; }
.lab-reset { margin-top: 14px; color: var(--ink-2); border-bottom: 1px solid currentColor; }

.footer { display: flex; justify-content: space-between; gap: 16px; padding: 20px var(--pad); border-top: 1px solid var(--line); color: var(--muted); }
.footer a:hover { color: var(--ink); }

/* ---------------- Viewer ---------------- */
.lightbox {
  width: 100vw; height: 100dvh; max-width: none; max-height: none; margin: 0;
  border: 0; padding: 0; background: var(--sheet); color: var(--ink);
}
.lightbox::backdrop { background: transparent; }
.lightbox[open] { display: grid; grid-template-rows: 1fr auto; animation: fade .3s var(--ease); }
@keyframes fade { from { opacity: 0; } }
.lb-inner { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 40px; padding: 72px var(--pad) 24px; min-height: 0; }
.lb-media { display: grid; place-items: center; min-height: 0; min-width: 0; }
.lb-media img { max-width: 100%; max-height: calc(100dvh - 180px); object-fit: contain; box-shadow: 0 14px 40px -20px rgba(0,0,0,.35); }
.lb-info { align-self: end; padding-bottom: 8px; }
.lb-info:has(.lb-title:empty) { display: none; }
.lb-group { margin: 0 0 10px; color: var(--muted); }
.lb-title { margin: 0 0 12px; font-family: var(--serif); font-weight: 400; font-size: 34px; line-height: 1.08; }
.lb-role { margin: 0 0 10px; font-size: 14px; color: var(--ink-2); }
.lb-note { margin: 0 0 14px; font-size: 13px; color: var(--muted); }
.lb-link { border-bottom: 1px solid currentColor; }
.lb-link:empty { display: none; }
.lb-nav { display: flex; justify-content: center; align-items: center; gap: 28px; padding: 16px 0 28px; color: var(--muted); }
.lb-nav button { font-size: 20px; color: var(--ink); padding: 4px 10px; }
.lb-close { position: absolute; top: 22px; right: var(--pad); }
.lightbox.bare .lb-inner { grid-template-columns: minmax(0, 1fr); }

/* ---------------- Reveal ---------------- */
.reveal { opacity: 0; transition: opacity .9s var(--ease); }
.reveal.in { opacity: 1; }

/* ---------------- Responsive ---------------- */
@media (max-width: 900px) {
  .feature { grid-template-columns: minmax(0, 1fr); }
  .feature .shot { order: -1; }
  .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lb-inner { grid-template-columns: 1fr; gap: 20px; padding-top: 64px; }
  .lb-info { align-self: start; }
  .lb-media img { max-height: calc(100dvh - 320px); }
}
@media (max-width: 720px) {
  .sheet { margin: 0; }
  .topbar { grid-template-columns: auto 1fr; }
  .nav, .dot { display: none; }
  .name-wrap { margin: 34px 0 60px; }
  .sticker { font-size: 12px; padding: 5px 8px 4px; }
  .sticker.tl { left: -10px; top: -22px; }
  .sticker.tr { right: -10px; top: -18px; }
  .sticker.bl { left: -8px; bottom: -20px; }
  .sticker.br { right: -10px; bottom: -22px; }
  .about { grid-template-columns: minmax(0, 1fr); }
  .about .polaroid { width: 100%; max-width: 250px; margin: 0 auto; }
  .row { grid-template-columns: 72px minmax(0, 1fr); gap: 14px; }
  .row .th { width: 72px; }
  .row .end { display: none; }
  .cards { grid-template-columns: minmax(0, 1fr); }
  .photos { columns: 2; column-gap: 12px; }
  .photos button { margin-bottom: 12px; }
  .logos { --gap: 10px; grid-template-columns: repeat(6, minmax(0, 1fr)); grid-auto-rows: calc((100cqw - 5 * var(--gap)) / 6); grid-auto-flow: dense; }
  .logos li, .logos li.l2 { grid-column: span 2 !important; grid-row: span 2 !important; }
  .logos li.l1 { grid-column: span 4 !important; grid-row: span 4 !important; }
  .disc > li { grid-template-columns: 88px minmax(0, 1fr); gap: 16px; }
  .cover { width: 88px; }
  .photo-row { grid-template-columns: 1fr 1fr; gap: 14px; padding: 0; }
  .photo-row figure { padding: 4px; }
  .lab { grid-template-columns: minmax(0, 1fr); justify-items: center; text-align: center; }
  .dish-hint { right: -10px; top: -22px; }
  .footer { flex-direction: column; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; }
  html { scroll-behavior: auto; }
}
