/* A Walking City, "Night Telescope": the Workbench base (neutral UI, cards, one
   blue accent) under full-bleed cinematic heroes: banner photo + scrim, serif
   (Newsreader) display titles, mono (Plex Mono) eyebrows and meta. Heroes are
   always dark over their photo; everything below follows the theme. */
@font-face { font-family: 'IBM Plex Mono'; src: url('/assets/fonts/plex-mono-400.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'IBM Plex Mono'; src: url('/assets/fonts/plex-mono-500.woff2') format('woff2'); font-weight: 500; font-display: swap; }
@font-face { font-family: 'Newsreader'; src: url('/assets/fonts/newsreader-400.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Newsreader'; src: url('/assets/fonts/newsreader-400-italic.woff2') format('woff2'); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: 'Newsreader'; src: url('/assets/fonts/newsreader-600.woff2') format('woff2'); font-weight: 600; font-display: swap; }

:root {
  --bg: #fbfbfc;
  --surface: #ffffff;
  --surface-2: #f7f8fa;
  --chip: #f1f2f6;
  --border: #e8e9ee;
  --border-strong: #dcdee6;
  --ink: #191b22;
  --text: #31343f;
  --text-soft: #565b68;
  --muted: #8a8ea0;
  --nav: #6d7180;
  --accent: oklch(0.55 0.16 255);
  --accent-strong: oklch(0.5 0.16 255);
  --accent-soft: oklch(0.55 0.16 255 / 0.1);
  --btn: #191b22;
  --btn-ink: #ffffff;
  --shadow: 0 1px 3px rgb(20 25 45 / 0.06);
  --shadow-lift: 0 4px 16px rgb(20 25 45 / 0.09);
  --radius: 14px;
  --radius-sm: 8px;
  --max: 720px;
  --sans: 'Instrument Sans', system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --serif: 'Newsreader', Georgia, serif;
  --mono: 'IBM Plex Mono', ui-monospace, 'SF Mono', Menlo, monospace;
}
:root[data-theme='dark'] {
  --bg: #131419;
  --surface: #1b1d25;
  --surface-2: #20222b;
  --chip: #262933;
  --border: #2b2e39;
  --border-strong: #363a47;
  --ink: #f2f3f7;
  --text: #d4d7e0;
  --text-soft: #b3b7c4;
  --muted: #868b9c;
  --nav: #9297a6;
  --accent: oklch(0.72 0.13 255);
  --accent-strong: oklch(0.78 0.12 255);
  --accent-soft: oklch(0.72 0.13 255 / 0.16);
  --btn: #f2f3f7;
  --btn-ink: #16171d;
  --shadow: 0 1px 3px rgb(0 0 0 / 0.4);
  --shadow-lift: 0 6px 22px rgb(0 0 0 / 0.5);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent-strong); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { color: var(--ink); letter-spacing: -0.02em; line-height: 1.2; }
img { max-width: 100%; }

.wrap { max-width: 1100px; margin: 0 auto; padding: 0 clamp(20px, 4vw, 48px); }

/* ---- header ---- */
.site-header { border-bottom: 1px solid var(--border); background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(10px); position: sticky; top: 0; z-index: 20; }
.site-header-inner { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 20px 0; }
.site-title { color: var(--ink); font-weight: 700; font-size: 16px; letter-spacing: -0.01em; }
.site-title:hover { text-decoration: none; color: var(--accent-strong); }
.site-header nav { display: flex; align-items: center; gap: clamp(16px, 2.5vw, 28px); font-size: 14px; font-weight: 500; }
.site-header nav a { color: var(--nav); padding-bottom: 2px; border-bottom: 2px solid transparent; }
.site-header nav a:hover { color: var(--ink); text-decoration: none; }
.site-header nav a.active { color: var(--ink); border-bottom-color: var(--accent); }
#theme-toggle { font: inherit; font-size: 15px; color: var(--nav); background: none; border: none; cursor: pointer; padding: 0; line-height: 1; }
#theme-toggle:hover { color: var(--ink); }

/* Transparent header over a hero: absolute, light text, no border. */
.site-header-overlay { position: absolute; top: 0; left: 0; right: 0; z-index: 30; background: transparent; border-bottom: none; backdrop-filter: none; }
.site-header-overlay .site-title { color: #f2f3f7; }
.site-header-overlay .site-title:hover { color: #ffffff; }
.site-header-overlay nav a { color: rgb(242 243 247 / 0.75); }
.site-header-overlay nav a:hover { color: #ffffff; }
.site-header-overlay nav a.active { color: #ffffff; border-bottom-color: oklch(0.78 0.12 255); }
.site-header-overlay #theme-toggle { color: rgb(242 243 247 / 0.75); }
.site-header-overlay #theme-toggle:hover { color: #ffffff; }

main { padding: 40px 0 8px; }
/* Pages with full-bleed sections manage their own .wrap; hero sits flush to the top. */
main.bare { padding: 0 0 8px; }
main.bare > :first-child { margin-top: 0; }

/* ---- full-bleed heroes ("Night Telescope") ----
   The hero is always cinematic-dark over its photo, in both themes: the scrim
   ends in solid near-black, blending into the dark bg or cutting cleanly to
   the light one. Text colors inside are fixed, not theme tokens. */
.hero { position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: flex-end; }
.hero-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transform: scale(1.06); filter: blur(2px) brightness(0.85) saturate(1.05); }
.hero-scrim { position: absolute; inset: 0; background: linear-gradient(180deg, rgb(10 11 16 / 0.62) 0%, rgb(10 11 16 / 0.18) 42%, rgb(19 20 25 / 0.9) 84%, #131419 100%); }
.hero-inner { position: relative; width: 100%; max-width: 1100px; margin: 0 auto; padding: 108px clamp(20px, 4vw, 48px) 64px; display: flex; flex-direction: column; gap: 18px; }
.hero-eyebrow-row { display: flex; align-items: center; gap: 14px; }
.hero-avatar { width: 56px; height: 56px; border-radius: 16px; object-fit: cover; border: 1px solid rgb(242 243 247 / 0.25); }
.hero-eyebrow { margin: 0; font-family: var(--mono); font-size: 12px; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; color: oklch(0.78 0.12 255); }
.hero-title { margin: 0; font-family: var(--serif); font-weight: 600; font-size: clamp(32px, 5vw, 64px); line-height: 1.08; letter-spacing: -0.02em; color: #f2f3f7; text-wrap: balance; max-width: 920px; }
.hero-title a { color: inherit; }
.hero-title em { font-weight: 400; }
.hero-note, .hero-lead { margin: 0; font-size: 17px; line-height: 1.6; color: rgb(228 231 240 / 0.78); max-width: 580px; }
.hero-lead { font-size: 15.5px; max-width: 46rem; }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 6px; }
.btn-hero { background: #f2f3f7; color: #16171d; }
.btn-hero:hover { opacity: 0.9; }
.btn-hero-ghost { background: transparent; border-color: rgb(242 243 247 / 0.35); color: #f2f3f7; }
.btn-hero-ghost:hover { border-color: rgb(242 243 247 / 0.6); }
.hero-links { margin: 0; font-family: var(--mono); font-size: 13px; color: rgb(228 231 240 / 0.6); display: flex; flex-wrap: wrap; gap: 8px 14px; }
.hero-links a { color: rgb(228 231 240 / 0.6); }
.hero-links a:hover { color: #f2f3f7; }

.hero-home { min-height: clamp(520px, 78vh, 700px); }
.hero-page { min-height: 320px; }
.hero-page .hero-inner { padding-bottom: 44px; gap: 10px; }
.hero-post { min-height: clamp(380px, 58vh, 560px); }
/* Featured images are often busy screenshots: blur + darken hard so the title always reads. */
.hero-post .hero-bg { filter: blur(5px) brightness(0.55) saturate(1.1); }
.hero-post .hero-scrim { background: linear-gradient(180deg, rgb(10 11 16 / 0.55) 0%, rgb(10 11 16 / 0.3) 42%, rgb(19 20 25 / 0.92) 84%, #131419 100%); }
.hero-post .hero-inner { gap: 14px; }
.hero .post-byline .byline-name { color: #f2f3f7; }
.hero .post-byline .post-meta { color: rgb(228 231 240 / 0.6); font-family: var(--mono); font-size: 13px; }
.hero .post-byline .post-meta a, .hero .post-byline .post-meta .tag { color: oklch(0.78 0.12 255); }

/* ---- full-bleed featured band (home) ---- */
/* isolation + negative z-index on bg/scrim keep the card in-flow and above
   them, so the title link's stretched ::after can cover the whole band. */
.featured-band { position: relative; isolation: isolate; overflow: hidden; min-height: 420px; display: flex; align-items: flex-end; }
.featured-band .featured-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -1; }
.featured-band .featured-scrim { position: absolute; inset: 0; background: linear-gradient(180deg, rgb(19 20 25 / 0.55) 0%, rgb(19 20 25 / 0.08) 30%, rgb(19 20 25 / 0.55) 100%); z-index: -1; }
.featured-band-inner { width: 100%; max-width: 1100px; margin: 0 auto; padding: 48px clamp(20px, 4vw, 48px) 40px; }
.featured-card { display: flex; flex-direction: column; gap: 8px; max-width: 560px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px 28px; box-shadow: var(--shadow-lift); }
.featured-card .card-eyebrow { margin: 0; font-family: var(--mono); font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent-strong); }
.featured-card .card-title { font-family: var(--serif); font-size: 26px; line-height: 1.15; letter-spacing: -0.015em; }
.featured-card .card-summary { font-size: 14px; }
.featured-card .card-link { color: inherit; }
.featured-card .card-link:hover { text-decoration: none; }
/* Stretch the title link over the whole band, like .project-link. */
.featured-band .card-title a::after { content: ''; position: absolute; inset: 0; z-index: 2; }
.featured-band .card-title a:focus-visible::after { outline: 2px solid var(--accent-strong); outline-offset: -3px; }

/* ---- buttons ---- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 10px 16px; border-radius: var(--radius-sm); font-size: 14px; font-weight: 600; border: 1px solid transparent; cursor: pointer; }
.btn:hover { text-decoration: none; }
.btn-primary { background: var(--btn); color: var(--btn-ink); }
.btn-primary:hover { opacity: 0.9; }
.btn-secondary { background: var(--surface); border-color: var(--border-strong); color: var(--ink); }
.btn-secondary:hover { border-color: var(--muted); }

/* ---- bio sidebar (home + cv) ---- */
.layout-sidebar { display: grid; grid-template-columns: 300px 1fr; gap: 48px; align-items: start; }
.bio { display: flex; flex-direction: column; gap: 16px; position: sticky; top: 92px; }
.bio-avatar { width: 96px; height: 96px; border-radius: 20px; object-fit: cover; }
.bio-name { margin: 0; font-size: 26px; font-weight: 700; }
.bio-note { margin: 0; font-size: 15px; line-height: 1.55; color: var(--text-soft); }
.bio-actions { display: flex; flex-direction: column; gap: 8px; margin-top: 4px; }
.bio-actions .btn { width: 100%; }
.bio-links { display: flex; flex-wrap: wrap; gap: 8px 12px; font-size: 13px; color: var(--nav); }
.bio-links a { color: var(--nav); }
.bio-links a:hover { color: var(--ink); }

/* ---- section headings ---- */
.section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; margin: 0 0 20px; }
.eyebrow { margin: 0; font-family: var(--mono); font-size: 12px; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }
.section-link { font-size: 14px; font-weight: 500; }

.page-head { margin: 0 0 28px; }
.page-title { margin: 0 0 8px; font-family: var(--serif); font-size: 32px; font-weight: 600; }
.page-lead { margin: 0; font-size: 15px; color: var(--text-soft); max-width: 46rem; }

/* ---- feed / cards ---- */
.card-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.card {
  display: flex; flex-direction: column; gap: 8px;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow); transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}
.card:hover { border-color: var(--border-strong); box-shadow: var(--shadow-lift); transform: translateY(-2px); text-decoration: none; }
.card-body { display: flex; flex-direction: column; gap: 8px; padding: 22px; }
.card-img { width: 100%; height: 130px; object-fit: cover; display: block; }
.card-meta { margin: 0; font-family: var(--mono); font-size: 12px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.card-title { margin: 0; font-family: var(--serif); font-size: 20px; font-weight: 600; line-height: 1.25; color: var(--ink); letter-spacing: -0.01em; }
.card-summary { margin: 0; font-size: 13.5px; line-height: 1.5; color: var(--text-soft); }

/* featured card spans the row */
.card-featured { grid-column: 1 / -1; }
.card-featured.has-image .card-link { display: grid; grid-template-columns: 1.2fr 1fr; }
.card-featured .card-img { height: 100%; min-height: 220px; }
.card-featured .card-eyebrow { font-family: var(--mono); font-size: 12px; font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent-strong); }
.card-featured .card-title { font-size: 26px; letter-spacing: -0.015em; }
.card-featured .card-summary { font-size: 14px; }
.card-link { color: inherit; }
.card-link:hover { text-decoration: none; }

.tag { color: var(--muted); }
.tag::before { content: '#'; }
.card-meta .tag, .post-meta .tag { color: var(--accent-strong); }

/* ---- post page ---- */
.reading { max-width: var(--max); margin: 0 auto; }
.back-link { display: inline-block; font-size: 13px; font-weight: 500; margin-bottom: 16px; }
.post-title { margin: 0 0 16px; font-family: var(--serif); font-size: clamp(30px, 5vw, 42px); font-weight: 600; letter-spacing: -0.02em; line-height: 1.12; text-wrap: pretty; }
.post-byline { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.post-byline .byline-avatar { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; }
.post-byline .byline-name { font-size: 14px; font-weight: 600; color: var(--ink); }
.post-byline .post-meta { font-size: 14px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.post-hero { width: 100%; max-height: 460px; object-fit: cover; border-radius: 16px; margin: 28px auto 0; display: block; }

.e-content { font-size: 17px; line-height: 1.7; color: var(--text); margin-top: 36px; }
.e-content > * { margin: 24px 0; }
.e-content > :first-child { margin-top: 0; }
.e-content h2 { font-size: 24px; margin: 40px 0 0; }
.e-content h3 { font-size: 19px; margin: 32px 0 0; }
.e-content img, .e-content video { border-radius: 12px; display: block; }
.e-content figure { margin: 8px 0; }
.e-content figcaption { margin-top: 10px; font-size: 13.5px; color: var(--muted); text-align: center; }
.e-content a { text-decoration: underline; text-underline-offset: 2px; }
.e-content blockquote { margin: 24px 0; padding: 4px 20px; border-left: 3px solid var(--border-strong); color: var(--text-soft); font-style: italic; }
.e-content pre { font-family: var(--mono); background: var(--surface-2); border: 1px solid var(--border); border-radius: 12px; padding: 18px 20px; overflow-x: auto; font-size: 13.5px; line-height: 1.6; }
.e-content code, code { font-family: var(--mono); font-size: 0.88em; background: var(--chip); padding: 2px 6px; border-radius: 5px; }
.e-content pre code { background: none; padding: 0; font-size: 1em; }
.e-content ul, .e-content ol { padding-left: 22px; }
.e-content li { margin: 6px 0; }

.gallery { margin-top: 40px; }
.gallery h2 { font-size: 18px; margin: 0 0 14px; }
.gallery-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.gallery-grid img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 12px; border: 1px solid var(--border); }

/* post footer stack */
.post-footer { display: flex; flex-direction: column; gap: 20px; margin-top: 48px; }
.author-card { display: flex; align-items: center; gap: 16px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px 24px; }
.author-card img { width: 52px; height: 52px; border-radius: 14px; object-fit: cover; flex: none; }
.author-card .author-meta { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.author-card .author-name { font-size: 15px; font-weight: 700; color: var(--ink); }
.author-card .author-note { font-size: 13.5px; line-height: 1.5; color: var(--text-soft); }
.author-card .btn { margin-left: auto; flex: none; }

.info-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px 24px; }
.info-card h2 { margin: 0 0 6px; font-size: 13px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.wm-hint { margin: 0; font-size: 14px; line-height: 1.55; color: var(--text-soft); }
.wm-list { margin: 12px 0 0; padding-left: 18px; font-size: 14px; }
.wm-list li { margin: 6px 0; }

.post-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.post-nav a { display: flex; flex-direction: column; gap: 5px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px 22px; }
.post-nav a:hover { text-decoration: none; border-color: var(--border-strong); }
.post-nav .nav-dir { font-size: 12px; color: var(--muted); }
.post-nav .nav-title { font-size: 15px; font-weight: 600; letter-spacing: -0.01em; color: var(--ink); line-height: 1.35; }
.post-nav .nav-next { text-align: right; }

/* ---- CV ---- */
.chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 0; margin: 0; list-style: none; }
.chip { padding: 5px 10px; background: var(--surface); border: 1px solid var(--border); border-radius: 999px; font-size: 12.5px; color: var(--text); }
.side-block { display: flex; flex-direction: column; gap: 10px; margin-top: 6px; }
.side-block .sub-list { display: flex; flex-direction: column; gap: 10px; font-size: 13.5px; line-height: 1.45; color: var(--text); }
.side-block .sub-list .dim { color: var(--muted); }

.exp-list { display: flex; flex-direction: column; gap: 16px; }
.exp { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 26px; display: flex; flex-direction: column; gap: 10px; }
.exp-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; }
.exp-role { font-size: 18px; font-weight: 700; letter-spacing: -0.01em; color: var(--ink); }
.exp-role .p-location { color: var(--ink); }
.exp-date { font-size: 13px; color: var(--muted); flex: none; }
.exp .p-description { margin: 0; font-size: 14px; line-height: 1.6; color: var(--text-soft); }
.exp-bullets { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 7px; font-size: 13.5px; line-height: 1.55; color: var(--text-soft); }
.exp-bullets strong { color: var(--text); font-weight: 600; }

/* ---- link preview cards (CV) ---- */
.linkcard { display: grid; grid-template-columns: 120px 1fr; gap: 14px; align-items: center; margin-top: 4px; background: var(--surface-2); border: 1px solid var(--border); border-radius: 10px; overflow: hidden; }
.linkcard:hover { border-color: var(--border-strong); text-decoration: none; }
.linkcard img { width: 120px; height: 76px; object-fit: cover; }
.linkcard-text { display: flex; flex-direction: column; gap: 2px; padding: 10px 14px 10px 0; min-width: 0; }
.linkcard-title { font-size: 13.5px; font-weight: 600; color: var(--ink); line-height: 1.35; }
.linkcard-desc { font-size: 12.5px; color: var(--text-soft); line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.linkcard-host { font-size: 12px; color: var(--muted); }

/* ---- cv side-project mosaic ---- */
/* One image, made of tiles: the whole grid is a single link to /portfolio/. */
.mosaic { display: grid; grid-template-columns: repeat(var(--mosaic-cols, 4), 1fr); gap: 2px; overflow: hidden; border: 1px solid var(--border); border-radius: var(--radius); background: var(--border); transition: border-color 0.2s ease, box-shadow 0.2s ease; }
.mosaic:hover { border-color: var(--border-strong); box-shadow: var(--shadow-lift); }
.mosaic:focus-visible { outline: 2px solid var(--accent-strong); outline-offset: 2px; }
.mosaic-tile { width: 100%; height: 100%; aspect-ratio: 16 / 10; object-fit: cover; object-position: top center; display: block; background: var(--surface); }

/* ---- portfolio ---- */
.project-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.project { position: relative; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; }
.project:hover { border-color: var(--border-strong); box-shadow: var(--shadow-lift); }
.project-clickable:hover { cursor: pointer; }
.project-link::after { content: ''; position: absolute; inset: 0; z-index: 1; }
.project-link:focus-visible::after { outline: 2px solid var(--accent-strong); outline-offset: -3px; }
.project-img { width: 100%; height: 200px; object-fit: cover; border-bottom: 1px solid var(--border); }
.project-body { padding: 24px; display: flex; flex-direction: column; gap: 10px; }
.project-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.project-name { margin: 0; font-family: var(--serif); font-size: 22px; font-weight: 600; letter-spacing: -0.015em; }
.project-name a { color: var(--ink); }
.project-host { font-size: 12px; font-weight: 600; color: var(--accent-strong); flex: none; }
.project-summary { margin: 0; font-size: 14px; line-height: 1.55; color: var(--text-soft); }
.project .meta { display: flex; gap: 6px; flex-wrap: wrap; }
.project .meta .tag { padding: 4px 9px; background: var(--chip); border-radius: 999px; font-size: 12px; color: var(--text-soft); }
.project .meta .tag::before { content: ''; }
.press { display: flex; flex-direction: column; gap: 8px; margin-top: 2px; }

/* ---- portfolio lightbox ---- */
/* Above .project-link::after, which stretches over the whole card, otherwise
   the card's link swallows the click and the image never opens. */
.project-shot { position: relative; z-index: 2; display: block; width: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; }
.project-shot .project-img { display: block; }
.lightbox { position: fixed; inset: 0; z-index: 100; display: flex; align-items: center; justify-content: center; padding: 28px; background: rgba(10, 12, 16, 0.84); }
.lightbox[hidden] { display: none; }
.lightbox img { max-width: min(1320px, 96vw); max-height: 92vh; width: auto; height: auto; border-radius: 10px; box-shadow: 0 24px 64px rgba(0, 0, 0, 0.45); cursor: zoom-out; }
.lightbox-close { position: absolute; top: 18px; right: 20px; width: 40px; height: 40px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, 0.32); background: rgba(255, 255, 255, 0.1); color: #fff; font-size: 21px; line-height: 1; cursor: pointer; }
.lightbox-close:hover { background: rgba(255, 255, 255, 0.2); }
html.lightbox-open { overflow: hidden; }

/* ---- footer ---- */
.site-footer { border-top: 1px solid var(--border); margin-top: 64px; }
.site-footer-inner { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; padding: 22px 0; font-size: 12.5px; color: var(--muted); }
.site-footer a { color: var(--nav); }
.site-footer a:hover { color: var(--ink); }
.footer-links { display: flex; gap: 16px; }

/* ---- misc ---- */
/* Content sections on bare (hero) pages provide their own top spacing. */
.section-pad { padding-top: 40px; }
.company-intro { margin-bottom: 32px; }
.company-contact { margin-top: 32px; }
.error-page { max-width: var(--max); margin: 0 auto; text-align: center; padding: 40px 0; }
.error-page h1 { font-size: 72px; margin: 0; }
::selection { background: var(--accent-soft); }
time { white-space: nowrap; }

/* ---- responsive ---- */
@media (max-width: 860px) {
  .layout-sidebar { grid-template-columns: 1fr; gap: 32px; }
  .bio { position: static; flex-direction: row; flex-wrap: wrap; align-items: center; gap: 12px 16px; }
  .bio-avatar { width: 72px; height: 72px; }
  .bio-name { font-size: 22px; }
  .bio-note { flex-basis: 100%; }
  .bio-actions { flex-direction: row; flex-basis: 100%; }
  .bio-actions .btn { width: auto; flex: 1; }
}
@media (max-width: 640px) {
  .card-grid, .project-grid, .post-nav { grid-template-columns: 1fr; }
  .hero-home { min-height: min(78vh, 560px); }
  .hero-inner { padding-top: 92px; }
  .hero-avatar { width: 44px; height: 44px; border-radius: 12px; }
  .hero-note { font-size: 15.5px; }
  .featured-band { min-height: 360px; }
  .featured-card { padding: 20px 22px; }
  .featured-card .card-title { font-size: 22px; }
  .card-featured.has-image .card-link { grid-template-columns: 1fr; }
  .card-featured .card-img { min-height: 180px; height: 180px; }
  .exp-head { flex-direction: column; gap: 2px; }
  .author-card { flex-wrap: wrap; }
  .author-card .btn { margin-left: 0; }
}
