/* Santiago Santos — portfolio, midnight theme.
   Order: tokens · base · texture · components · header · sections · motion · responsive · preferences */

/* ---------- tokens ---------- */
:root {
  --night-0: #040817;          /* deepest, page edges */
  --night-1: #070e24;          /* page */
  --night-2: #0d1838;          /* raised */
  --night-3: #16244f;          /* horizon body */
  --glow: #a8bdf5;             /* horizon glow */
  --glow-hot: #e6edff;         /* horizon line */
  --ink: #f3f6ff;              /* primary text  (17:1 on page) */
  --ink-2: #c3cdea;            /* secondary     (11:1) */
  --ink-3: #95a3c9;            /* tertiary, ≥ 4.5:1 on glass */
  --gold: #d9b56c;             /* small details only */
  --line: rgba(196, 210, 255, .14);
  --glass: rgba(150, 175, 255, .06);
  --glass-hi: rgba(170, 195, 255, .1);
  --glass-line: rgba(200, 215, 255, .16);
  --radius: 30px;
  --radius-s: 18px;
  --shell: 1240px;
  --gutter: clamp(16px, 4vw, 40px);
  --font: "Helvetica Neue", Helvetica, Inter, Arial, sans-serif;
  --ease: cubic-bezier(.2, .7, .1, 1);
  --title-grad: linear-gradient(180deg, #ffffff 0%, #eef2ff 38%, #b9c8f2 72%, #7f95d0 100%);
  --title-line-grad: linear-gradient(180deg, #ffffff 0%, #eef2ff 30%, #c4d1f5 62%, #9fb2e6 76%, rgba(127, 149, 208, .35) 86%, rgba(127, 149, 208, 0) 97%);
  --title-word-grad: linear-gradient(180deg, #ffffff 0%, #eef2ff 30%, #c4d1f5 62%, #9fb2e6 80%, #8ea3db 100%);
  --page-top: #0e1a40;
  --nav-bg: rgba(10, 18, 44, .55);
  --menu-bg: #0a1330;
  color-scheme: dark;
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--night-1);
  background-image:
    radial-gradient(120% 70% at 50% -10%, var(--page-top) 0%, transparent 60%),
    linear-gradient(180deg, var(--night-1), var(--night-0));
  color: var(--ink-2);
  font: 300 1.0625rem/1.6 var(--font);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
b, strong { font-weight: 700; color: var(--ink); }
h1, h2, h3, h4 { margin: 0; font-weight: 300; color: var(--ink); }
p { margin: 0; }
ol, ul { margin: 0; padding: 0; list-style: none; }
::selection { background: var(--glow); color: var(--night-0); }
:focus-visible { outline: 2px solid var(--glow-hot); outline-offset: 3px; border-radius: 8px; }
.shell { width: min(100% - 2 * var(--gutter), var(--shell)); margin-inline: auto; }
.skip-link { position: fixed; left: 16px; top: -60px; z-index: 100; padding: 10px 16px; border-radius: 99px; background: var(--ink); color: var(--night-0); font-weight: 700; transition: top .2s; }
.skip-link:focus { top: 16px; }
html[lang="en"] .pt-only { display: none; }

/* ---------- texture: grain over everything ----------
   Static, normal blending, its own compositor layer: drawn once, then never repainted.
   (An animated grain with a blend mode forced the whole screen and every glass blur to redraw 5×/s.) */
.grain {
  position: fixed; inset: 0; z-index: 60; pointer-events: none; opacity: .05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 1.4 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  transform: translateZ(0);
}

/* horizon glow (covers + contact) */
.horizon { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; }
.horizon-glow {
  position: absolute; left: 50%; bottom: -46vh; width: 160vw; height: 75vh; transform: translateX(-50%);
  background: radial-gradient(50% 50% at 50% 50%, rgba(214, 226, 255, .55) 0%, rgba(150, 175, 240, .32) 28%, rgba(60, 86, 170, .18) 55%, transparent 72%);
  animation: breathe 9s ease-in-out infinite alternate;
  will-change: transform, opacity;
}
.horizon-line {
  position: absolute; left: 50%; bottom: 0; width: 140vw; height: 24vh; transform: translateX(-50%);
  border-radius: 50% 50% 0 0 / 100% 100% 0 0;
  border-top: 1px solid rgba(230, 237, 255, .55);
  background: linear-gradient(180deg, rgba(4, 8, 23, .2), var(--night-0) 70%);
  box-shadow: 0 -14px 60px -10px rgba(200, 215, 255, .5);
}
@keyframes breathe { from { opacity: .78; transform: translateX(-50%) scale(1); } to { opacity: 1; transform: translateX(-50%) scale(1.06); } }

/* ---------- components ---------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: .78rem; font-weight: 400; letter-spacing: .22em; text-transform: uppercase; color: var(--ink-2);
}
.dot { width: 6px; height: 6px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 12px var(--gold); }
.kicker { font-size: .75rem; letter-spacing: .2em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 14px; }

/* gradient title: Helvetica Neue Light, tight leading, one italic accent */
.title {
  font-weight: 300; line-height: .78; letter-spacing: -.035em; color: var(--ink);
  padding-block: .08em .14em;
}
/* The gradient is painted per line (box-decoration-break: clone), so every line fades the same way.
   Below the baseline it fades out: descenders (g, y, p) dissolve instead of sitting on the next line's capitals. */
.title .w {
  background: var(--title-line-grad); -webkit-background-clip: text; background-clip: text; color: transparent;
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
}
.title em { font-style: italic; font-weight: 300; letter-spacing: -.045em; padding-right: .06em; }
.title-xl { font-size: clamp(3rem, 8.4vw, 7.6rem); }
.title-l  { font-size: clamp(2.5rem, 5.6vw, 4.9rem); }
.title-m  { font-size: clamp(2rem, 3.4vw, 3rem); line-height: .9; }
.sub { max-width: 42ch; color: var(--ink-2); font-size: 1.1rem; }
.lead { max-width: 46ch; font-size: clamp(1.1rem, 1.5vw, 1.3rem); color: var(--ink-2); line-height: 1.55; }
.fine { font-size: .92rem; color: var(--ink-3); max-width: 70ch; }
.center { text-align: center; margin-inline: auto; }
.note { font-size: .9rem; color: var(--ink-3); }

.wordmark, .hero-wordmark, .wordmark-lg { color: var(--ink); letter-spacing: -.02em; white-space: nowrap; }
.wm-light { font-weight: 300; }

.glass {
  position: relative; isolation: isolate;
  background: linear-gradient(180deg, var(--glass-hi), var(--glass));
  border: 1px solid var(--glass-line);
  border-radius: var(--radius);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08), 0 30px 80px -40px rgba(0, 0, 0, .8);
}
/* pointer spotlight on glass */
.glass::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; z-index: -1; pointer-events: none; opacity: 0; transition: opacity .4s;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 50%), rgba(190, 208, 255, .12), transparent 60%);
}
.glass:hover::before { opacity: 1; }

.pill {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 24px;
  border-radius: 99px; border: 1px solid var(--glass-line); background: rgba(150, 175, 255, .06);
  color: var(--ink); font-size: .95rem; font-weight: 400; white-space: nowrap;
  transition: background .3s var(--ease), border-color .3s, transform .3s var(--ease);
}
.pill:hover { background: rgba(170, 195, 255, .14); border-color: rgba(220, 230, 255, .35); }
.pill-solid { background: var(--ink); color: var(--night-1); border-color: var(--ink); font-weight: 700; }
.pill-solid:hover { background: #fff; border-color: #fff; box-shadow: 0 0 40px -6px rgba(200, 215, 255, .6); }
.arr { display: inline-block; transition: transform .3s var(--ease); }
a:hover .arr, button:hover .arr { transform: translate(2px, -2px); }
.pill[href^="#"]:hover .arr { transform: translateY(3px); }
.text-link { display: inline-flex; gap: 6px; align-items: center; color: var(--ink); font-weight: 400; background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; transition: background-size .4s var(--ease); padding-bottom: 2px; }
.text-link:hover { background-size: 100% 1px; }
.round { width: 48px; height: 48px; border-radius: 50%; border: 1px solid var(--glass-line); background: var(--glass); color: var(--ink); font-size: 1.1rem; transition: background .3s, opacity .3s; }
.round:hover { background: var(--glass-hi); }
.round:disabled { opacity: .3; cursor: default; }

/* photography: real photo, dark layer, vignette, fused with the midnight */
.photo-frame { position: relative; overflow: hidden; border-radius: var(--radius); background: var(--night-2); }
.photo-frame img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease); }
.photo-frame::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(120% 90% at 50% 40%, transparent 55%, rgba(4, 8, 23, .55) 100%),
    linear-gradient(180deg, rgba(13, 24, 56, .08), rgba(7, 14, 36, .28));
}


/* ---------- header ---------- */
.progress { position: fixed; inset: 0 0 auto; height: 2px; z-index: 70; pointer-events: none; }
.progress i { display: block; height: 100%; width: 100%; transform-origin: 0 50%; transform: scaleX(var(--p, 0)); background: linear-gradient(90deg, transparent, var(--gold)); }
.site-header { position: fixed; inset: 14px 0 auto; z-index: 50; pointer-events: none; }
.nav {
  pointer-events: auto; margin-inline: auto; width: min(100% - 2 * var(--gutter), var(--shell));
  display: flex; align-items: center; justify-content: space-between; gap: 20px;
  padding: 8px 8px 8px 22px; border-radius: 99px; border: 1px solid transparent;
  transition: background .5s, border-color .5s, width .6s var(--ease), box-shadow .5s;
}
.scrolled .nav {
  width: min(100% - 2 * var(--gutter), 65rem);
  background: var(--nav-bg); border-color: var(--glass-line);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  box-shadow: 0 20px 50px -30px rgba(0, 0, 0, .9);
}
.wordmark { font-size: 1.1rem; }
.nav-links { display: flex; gap: 4px; }
.nav-links a { position: relative; padding: 10px 14px; font-size: .92rem; color: var(--ink-2); border-radius: 99px; transition: color .3s, background .3s; }
.nav-links a:hover { color: var(--ink); }
.nav-links a.active { color: var(--ink); background: rgba(170, 195, 255, .1); }
.nav-actions { display: flex; align-items: center; gap: 8px; }
.nav-cta { min-height: 44px; padding: 0 18px; font-size: .88rem; }
.lbl-short { display: none; }
.lang-toggle { display: inline-flex; padding: 4px; border-radius: 99px; border: 1px solid var(--glass-line); min-height: 44px; align-items: center; }
.lang-toggle span { padding: 6px 10px; border-radius: 99px; font-size: .78rem; font-weight: 700; letter-spacing: .06em; color: var(--ink-3); transition: background .3s, color .3s; }
.lang-toggle[data-lang="en"] [data-l="en"], .lang-toggle[data-lang="pt"] [data-l="pt"] { background: var(--ink); color: var(--night-1); }
.menu-toggle { display: none; width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--glass-line); position: relative; }
.menu-toggle span { position: absolute; left: 13px; right: 13px; height: 1.5px; background: var(--ink); transition: transform .35s var(--ease); }
.menu-toggle span:first-child { top: 18px; } .menu-toggle span:last-child { top: 25px; }
.menu-toggle[aria-expanded="true"] span:first-child { transform: translateY(3.5px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:last-child { transform: translateY(-3.5px) rotate(-45deg); }

/* ---------- 01 cover ---------- */
.hero { position: relative; min-height: 100svh; display: grid; align-items: center; padding: 130px 0 120px; overflow: hidden; }
.hero-grid { position: relative; z-index: 1; display: grid; grid-template-columns: 1.25fr .75fr; gap: clamp(32px, 6vw, 90px); align-items: center; }
.hero-copy { display: grid; gap: 26px; justify-items: start; }
.hero-wordmark { font-size: clamp(1.2rem, 1.8vw, 1.5rem); }
.hero h1 { max-width: 11ch; margin-block: 4px 6px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 6px; }
.hero-portrait { margin: 0; justify-self: end; width: min(100%, 25rem); }
.hero-portrait .photo-frame { aspect-ratio: 4 / 5; border-radius: 200px 200px var(--radius) var(--radius); }
.hero-portrait img { filter: saturate(.7) contrast(1.05) brightness(.82); }
.hero-portrait .photo-frame::after {
  background:
    linear-gradient(180deg, rgba(20, 36, 90, .38) 0%, rgba(7, 14, 36, 0) 40%, rgba(7, 14, 36, .78) 100%),
    radial-gradient(110% 80% at 50% 35%, transparent 50%, rgba(4, 8, 23, .65) 100%);
  mix-blend-mode: normal;
}
.hero-portrait .photo-frame::before { content: ""; position: absolute; inset: 0; z-index: 1; background: #1b2c66; mix-blend-mode: color; opacity: .35; pointer-events: none; }
.hero-portrait figcaption { display: grid; gap: 2px; margin-top: 16px; text-align: right; font-size: .9rem; }
.hero-portrait figcaption span { color: var(--ink-3); }
.scroll-cue { position: absolute; left: 50%; bottom: 26px; z-index: 2; width: 26px; height: 42px; margin-left: -13px; border-radius: 99px; border: 1px solid rgba(230, 237, 255, .4); }
.scroll-cue span { position: absolute; left: 50%; top: 8px; width: 3px; height: 8px; margin-left: -1.5px; border-radius: 3px; background: var(--ink); animation: cue 2.2s var(--ease) infinite; }
@keyframes cue { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(14px); } }

/* numbers */
.numbers { position: relative; z-index: 2; padding-top: clamp(70px, 8vw, 110px); }
.numbers .numbers-head { margin-bottom: clamp(28px, 4vw, 44px); }
.intern { padding: 10px; }
.stat-row { display: grid; grid-template-columns: repeat(2, 1fr); }
.stat-row li { display: grid; gap: 6px; padding: 26px 22px; text-align: center; justify-items: center; }
.stat-row li + li { border-left: 1px solid var(--line); }
.stat-row b { font-size: clamp(2.4rem, 4.4vw, 3.6rem); font-weight: 300; line-height: .9; letter-spacing: -.04em; background: var(--title-grad); -webkit-background-clip: text; background-clip: text; color: transparent; font-variant-numeric: tabular-nums; }
.stat-row li > span { font-size: .78rem; letter-spacing: .18em; text-transform: uppercase; color: var(--ink-2); max-width: 18ch; }

/* sections */
.section { position: relative; padding: clamp(90px, 10vw, 140px) 0 clamp(70px, 7vw, 100px); }
.section-head { display: grid; gap: 18px; margin-bottom: clamp(40px, 6vw, 70px); max-width: 54rem; }

/* 02 work */
.project { display: grid; grid-template-columns: .85fr 1.15fr; gap: clamp(24px, 4vw, 56px); padding: clamp(14px, 1.6vw, 22px); }
.project-media .photo-frame.tall { height: 100%; min-height: 520px; border-radius: calc(var(--radius) - 10px); }
.project-media img { object-position: center 40%; }
.project-body { padding: clamp(10px, 2.4vw, 34px) clamp(6px, 2vw, 28px) clamp(10px, 2vw, 26px) 0; display: flex; flex-direction: column; }
.project-desc { margin: 18px 0 30px; font-size: 1.1rem; max-width: 40ch; }
.steps-label { font-size: .72rem; letter-spacing: .22em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 8px; }
.steps { position: relative; display: grid; }
.steps::before { content: ""; position: absolute; left: 17px; top: 22px; bottom: 22px; width: 1px; background: var(--line); }
.steps::after { content: ""; position: absolute; left: 17px; top: 22px; bottom: 22px; width: 1px; background: linear-gradient(180deg, var(--glow-hot), var(--glow)); transform-origin: top; transform: scaleY(var(--line-p, 0)); box-shadow: 0 0 10px var(--glow); }
.steps li { position: relative; display: grid; grid-template-columns: 36px 1fr; gap: 18px; padding: 14px 0; }
.step-no { position: relative; z-index: 1; width: 35px; height: 35px; display: grid; place-items: center; border-radius: 50%; font-size: .72rem; font-weight: 700; color: var(--ink-2); background: var(--night-2); border: 1px solid var(--glass-line); transition: background .5s, color .5s, box-shadow .5s; }
.steps li.lit .step-no { background: var(--ink); color: var(--night-1); box-shadow: 0 0 22px -2px rgba(200, 215, 255, .7); }
.steps h4 { font-size: 1.05rem; font-weight: 700; margin: 6px 0 4px; }
.steps p { font-size: .95rem; color: var(--ink-2); max-width: 54ch; }

.gallery-head { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin: clamp(80px, 10vw, 120px) 0 30px; }
.gallery-ctrl { display: flex; gap: 10px; }
.gallery { position: relative; }
.track {
  display: flex; gap: 20px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain;
  padding: 0 max(var(--gutter), calc((100vw - var(--shell)) / 2)) 10px; scroll-padding-inline: max(var(--gutter), calc((100vw - var(--shell)) / 2));
  cursor: grab;
}
.track::-webkit-scrollbar { display: none; }
.track.dragging { cursor: grabbing; scroll-snap-type: none; }
.track.dragging img { pointer-events: none; }
.slide { flex: none; margin: 0; scroll-snap-align: start; }
.slide .photo-frame { height: clamp(340px, 46vw, 540px); }
.portrait-slide .photo-frame { aspect-ratio: 3 / 4; height: clamp(340px, 46vw, 540px); width: auto; }
.wide-slide .photo-frame { aspect-ratio: 16 / 10; width: auto; }
.slide:hover img { transform: scale(1.04); }
.slide figcaption { display: flex; gap: 14px; align-items: baseline; margin-top: 14px; font-size: .92rem; color: var(--ink-2); }
.slide figcaption span { font-size: .72rem; font-weight: 700; color: var(--ink-3); letter-spacing: .1em; }
.work-foot { display: flex; justify-content: space-between; align-items: center; gap: 30px; margin-top: 50px; flex-wrap: wrap; }
.work-links { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }

/* 03 experience */
.exp-grid { display: grid; }
.exp-lists { display: grid; grid-template-columns: 1fr; gap: 34px clamp(28px, 4vw, 56px); padding: clamp(28px, 3.4vw, 44px); }
.list-title { font-size: .75rem; letter-spacing: .22em; text-transform: uppercase; color: var(--ink-3); font-weight: 400; margin-bottom: 8px; }
.timeline li { display: grid; grid-template-columns: 140px 1fr; gap: 20px; padding: 18px 0; border-top: 1px solid var(--line); }
.when { display: grid; gap: 2px; font-size: .9rem; }
.when span { color: var(--ink-3); font-size: .85rem; }
.timeline h4 { font-size: 1.15rem; font-weight: 700; margin-bottom: 4px; }
.timeline p:not(.when) { font-size: .95rem; }
.facts { display: grid; grid-template-columns: 1fr; gap: 20px; margin: 20px 0 0; }
.facts > div { padding: 28px clamp(24px, 3vw, 40px); display: grid; gap: 10px; align-content: start; }
.facts dt { font-size: .75rem; letter-spacing: .22em; text-transform: uppercase; color: var(--ink-3); }
.facts dd { margin: 0; font-size: 1.02rem; display: flex; flex-wrap: wrap; gap: 10px 26px; }
.lang-row { display: inline-flex; align-items: baseline; gap: 8px; }
.lang-row i { font-style: normal; font-size: .78rem; font-weight: 700; padding: 3px 9px; border-radius: 99px; border: 1px solid var(--glass-line); color: var(--ink); }

/* 04 words */
.quotes { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-items: stretch; }
.quote { padding: clamp(28px, 3.4vw, 46px); display: flex; flex-direction: column; gap: 22px; }
.qmark { font-size: 5.5rem; line-height: .5; height: 34px; font-weight: 300; color: var(--ink); opacity: .9; }
.excerpt { font-size: clamp(1.2rem, 1.7vw, 1.45rem); line-height: 1.4; color: var(--ink); font-weight: 300; letter-spacing: -.01em; }
.quote-more { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .6s var(--ease), opacity .5s; opacity: 0; }
.quote-more > div { overflow: hidden; display: grid; gap: 14px; font-size: .97rem; }
.quote.open .quote-more { grid-template-rows: 1fr; opacity: 1; }
.quote-more > div > :first-child { padding-top: 6px; border-top: 1px solid var(--line); margin-top: 2px; padding-top: 18px; }
.quote-foot { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-top: 6px; }
.person { display: flex; align-items: center; gap: 14px; }
.person img { width: 52px; height: 52px; border-radius: 50%; object-fit: cover; filter: saturate(.8); border: 1px solid var(--glass-line); }
.person h4 { font-size: 1rem; font-weight: 700; }
.person p { font-size: .85rem; color: var(--ink-3); max-width: 30ch; }
.more-toggle { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; padding: 0 16px 0 10px; border-radius: 99px; border: 1px solid var(--glass-line); font-size: .9rem; color: var(--ink); transition: background .3s; }
.more-toggle:hover { background: var(--glass-hi); }
.plus { position: relative; width: 22px; height: 22px; }
.plus::before, .plus::after { content: ""; position: absolute; left: 5px; right: 5px; top: 50%; height: 1.5px; margin-top: -.75px; background: currentColor; transition: transform .4s var(--ease); }
.plus::after { transform: rotate(90deg); }
[aria-expanded="true"] .plus::after { transform: rotate(0); }
.lbl-open, [aria-expanded="true"] .lbl-closed { display: none; }
[aria-expanded="true"] .lbl-open { display: inline; }

/* 05 toolkit */
.tools { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; margin-bottom: 30px; }
.tools li { display: flex; }
.tool { flex: 1; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 10px; padding: 34px 18px 28px; transition: transform .5s var(--ease), border-color .4s; }
.tool:hover { transform: translateY(-6px); border-color: rgba(220, 230, 255, .3); }
.tool-logo { width: 68px; height: 68px; border-radius: 16px; margin-bottom: 10px; transition: transform .6s var(--ease); box-shadow: 0 16px 30px -14px rgba(0, 0, 0, .8); }
.tool-logo.tile { background: #fff; padding: 9px; }
.tool:hover .tool-logo { transform: scale(1.08) rotate(-3deg); }
.tool-name { font-weight: 700; color: var(--ink); font-size: 1rem; }
.tool-name .arr { font-weight: 300; opacity: .7; }
.tool-desc { font-size: .88rem; color: var(--ink-2); }

/* 06 about */
.about-grid { display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(32px, 6vw, 90px); align-items: center; }
.about-photo { margin: 0; }
.about-photo .photo-frame { aspect-ratio: 4 / 5; }
.about-photo img { filter: saturate(.7) brightness(.85); }
.about-photo .photo-frame::before { content: ""; position: absolute; inset: 0; z-index: 1; background: #1b2c66; mix-blend-mode: color; opacity: .35; pointer-events: none; }
.about-copy { display: grid; gap: 20px; justify-items: start; }
.about-copy h2 { margin-bottom: 8px; }
.about-copy p { max-width: 56ch; }
.pull { margin: clamp(90px, 12vw, 160px) auto; text-align: center; max-width: 61rem; display: grid; gap: 26px; justify-items: center; }
.pull .title { line-height: .86; }
.pull footer { font-size: .85rem; letter-spacing: .18em; text-transform: uppercase; color: var(--ink-3); }
.pull footer span { color: var(--ink); }
.moments { display: grid; gap: 22px; }
.videos { display: grid; grid-template-columns: 2.2fr .8fr; gap: 20px; align-items: stretch; }
.video { position: relative; margin: 0; border-radius: var(--radius); overflow: hidden; background: var(--night-2); border: 1px solid var(--glass-line); }
.video video { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 1024 / 465; }
.video.tall video { aspect-ratio: auto; }
.video::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: radial-gradient(120% 90% at 50% 50%, transparent 55%, rgba(4, 8, 23, .55)); transition: opacity .4s; }
.video.playing::after { opacity: 0; }
.play { position: absolute; inset: 0; margin: auto; z-index: 2; width: 78px; height: 78px; border-radius: 50%; display: grid; place-items: center; color: var(--ink); background: rgba(10, 18, 44, .4); border: 1px solid rgba(230, 237, 255, .4); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); transition: transform .4s var(--ease), background .3s, opacity .3s; }
.play svg { width: 26px; fill: currentColor; margin-left: 3px; }
.play::before { content: ""; position: absolute; inset: -1px; border-radius: 50%; border: 1px solid rgba(230, 237, 255, .45); animation: ripple 2.6s var(--ease) infinite; }
.video:hover .play { transform: scale(1.08); background: rgba(20, 34, 80, .55); }
.video.playing .play { opacity: 0; pointer-events: none; }
@keyframes ripple { from { transform: scale(1); opacity: .9; } to { transform: scale(1.6); opacity: 0; } }

/* 07 contact */
.contact { position: relative; min-height: 92svh; display: grid; place-items: center; padding: 140px 0 200px; overflow: hidden; text-align: center; }
.contact-bg { position: absolute; inset: 0; z-index: 0; background: url("assets/banner-bg.jpg") center / cover; filter: grayscale(1); opacity: .16; -webkit-mask-image: linear-gradient(180deg, transparent, #000 30%, #000 70%, transparent); mask-image: linear-gradient(180deg, transparent, #000 30%, #000 70%, transparent); }
.contact-inner { position: relative; z-index: 1; display: grid; justify-items: center; gap: 26px; }
.contact .lead { text-align: center; }
.contact-actions { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; }
.handle { font-size: .9rem; color: var(--ink-3); }

/* footer */
.site-footer { position: relative; z-index: 1; padding: 50px 0 40px; border-top: 1px solid var(--line); background: var(--night-0); }
.footer-inner { display: flex; justify-content: space-between; align-items: end; gap: 30px; flex-wrap: wrap; }
.footer-mark { display: grid; gap: 8px; }
.wordmark-lg { font-size: clamp(1.8rem, 3vw, 2.4rem); line-height: 1; }
.slogan { font-size: .95rem; color: var(--ink-2); }
.slogan em { font-style: italic; }
.footer-meta { display: grid; gap: 10px; justify-items: end; font-size: .78rem; letter-spacing: .14em; color: var(--ink-3); }

.toast { position: fixed; left: 50%; bottom: 28px; z-index: 80; transform: translate(-50%, 30px); opacity: 0; padding: 12px 22px; border-radius: 99px; background: var(--ink); color: var(--night-1); font-weight: 700; font-size: .92rem; transition: opacity .35s, transform .45s var(--ease); pointer-events: none; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- motion ---------- */
.js .reveal { opacity: 0; transform: translateY(36px); transition: opacity 1s var(--ease), transform 1.1s var(--ease); transition-delay: var(--d, 0s); }
.js .reveal.in { opacity: 1; transform: none; }
.js [data-in] { opacity: 0; transform: translateY(24px); filter: blur(6px); }
.title .w { display: inline-block; padding-block: .2em; margin-block: -.2em; }
.title .w.ll { background-image: var(--title-word-grad); }
.js .split .w { display: inline-block; opacity: 0; transform: translateY(.45em); filter: blur(10px); }
.loaded [data-in], .loaded .split .w { opacity: 1; transform: none; filter: none; transition: opacity 1.1s var(--ease), transform 1.2s var(--ease), filter 1.1s var(--ease); transition-delay: var(--d, 0s); }
.js .horizon-line { transform: translateX(-50%) translateY(40%); opacity: 0; transition: transform 2.2s var(--ease), opacity 1.6s; }
.loaded .horizon-line, .contact.in-view .horizon-line { transform: translateX(-50%); opacity: 1; }
.js .contact .horizon-line { transform: translateX(-50%) translateY(40%); opacity: 0; }
.js .contact.in-view .horizon-line { transform: translateX(-50%); opacity: 1; }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .nav-links a { padding: 10px 10px; }
  .lbl-long { display: none; } .lbl-short { display: inline; }
  .tools { grid-template-columns: repeat(3, 1fr); }
  .tools li:nth-child(n+4) { grid-column: span 1; }
}
@media (max-width: 900px) {
  .menu-toggle { display: inline-block; }
  .nav { background: var(--nav-bg); border-color: var(--glass-line); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); }
  .nav-links {
    position: absolute; left: var(--gutter); right: var(--gutter); top: calc(100% + 10px);
    flex-direction: column; padding: 10px; border-radius: 24px; background: var(--menu-bg); box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .9); border: 1px solid var(--glass-line);
    -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
    opacity: 0; transform: translateY(-8px); pointer-events: none; transition: opacity .3s, transform .4s var(--ease);
  }
  .nav-links.open { opacity: 1; transform: none; pointer-events: auto; }
  .nav-links a { padding: 14px 16px; font-size: 1.05rem; }
  .site-header { position: fixed; }
  .nav { position: relative; }
  .hero-grid, .project, .exp-lists, .quotes, .about-grid, .facts { grid-template-columns: 1fr; }
  .hero { padding-top: 120px; }
  .hero-portrait { justify-self: start; width: min(64%, 300px); }
  .scroll-cue { display: none; }
  .hero-portrait figcaption { text-align: left; }
  .stat-row { grid-template-columns: 1fr 1fr; }
  .stat-row li:nth-child(3) { border-left: 0; }
  .stat-row li:nth-child(n+3) { border-top: 1px solid var(--line); }
  .project-media .photo-frame.tall { min-height: 0; aspect-ratio: 4 / 5; }
  .project-body { padding: 6px 10px 18px; }
  .videos { grid-template-columns: 1fr; }
  .video.tall { max-width: 360px; }
  .video.tall video { aspect-ratio: 9 / 16; }
  .about-photo { max-width: 380px; }
}
@media (max-width: 560px) {
  .nav { padding-left: 16px; gap: 8px; }
  .wordmark { font-size: 1rem; }
  .nav-cta { display: none; }
  .tools { grid-template-columns: 1fr 1fr; }
  .tools li:last-child { grid-column: 1 / -1; }
  .timeline li { grid-template-columns: 1fr; gap: 6px; }
  .gallery-head { align-items: start; flex-direction: column; }
  .portrait-slide .photo-frame, .slide .photo-frame { height: 380px; }
  .wide-slide .photo-frame { aspect-ratio: 4 / 5; }
  .stat-row li { padding: 20px 10px; }
  .footer-meta { justify-items: start; }
}

/* ---------- user preferences ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition-duration: .01ms !important; transition-delay: 0s !important; }
  .js .reveal, .js [data-in], .js .split .w { opacity: 1; transform: none; filter: none; }
  .js .horizon-line { opacity: 1; transform: translateX(-50%); }
}
@media (prefers-reduced-transparency: reduce) {
  .glass, .scrolled .nav, .nav-links, .play { -webkit-backdrop-filter: none; backdrop-filter: none; background: var(--night-2); }
  .grain { display: none; }
}
@media (prefers-contrast: more) {
  :root:not([data-theme="light"]) { --ink-2: #e2e8fa; --ink-3: #c3cdea; --glass-line: rgba(220, 230, 255, .5); --line: rgba(220, 230, 255, .4); }
  .title .w, .title .w.ll { background: none; color: var(--ink); }
}

/* ---------- theme toggle ---------- */
.theme-toggle { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--glass-line); display: grid; place-items: center; color: var(--ink); transition: background .3s, transform .5s var(--ease); }
.theme-toggle:hover { background: var(--glass-hi); }
.theme-toggle svg { grid-area: 1 / 1; width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; transition: opacity .4s, transform .6s var(--ease); }
.theme-toggle .i-sun { opacity: 0; transform: rotate(-90deg) scale(.6); }
[data-theme="light"] .theme-toggle .i-sun { opacity: 1; transform: none; }
[data-theme="light"] .theme-toggle .i-moon { opacity: 0; transform: rotate(90deg) scale(.6); }
html.theme-anim body, html.theme-anim .glass, html.theme-anim .nav, html.theme-anim .pill { transition: background-color .5s, color .5s, border-color .5s; }

/* ---------- light theme: paper with midnight ink ---------- */
[data-theme="light"] {
  --night-0: #e9edf6;
  --night-1: #f5f6fa;
  --night-2: #e3e8f3;
  --night-3: #d6ddee;
  --glow: #5b74c4;
  --glow-hot: #2c3f86;
  --ink: #0b1430;              /* 17:1 on page */
  --ink-2: #33406a;            /* 9.5:1 */
  --ink-3: #56628a;            /* 5.6:1 */
  --gold: #a67a22;
  --line: rgba(11, 20, 48, .12);
  --glass: rgba(255, 255, 255, .55);
  --glass-hi: rgba(255, 255, 255, .85);
  --glass-line: rgba(11, 20, 48, .1);
  --title-grad: linear-gradient(180deg, #0b1430 0%, #17255a 42%, #33478c 75%, #5b74c4 100%);
  --title-line-grad: linear-gradient(180deg, #0b1430 0%, #17255a 34%, #2b3e80 62%, #4a62b0 76%, rgba(91, 116, 196, .35) 86%, rgba(91, 116, 196, 0) 97%);
  --title-word-grad: linear-gradient(180deg, #0b1430 0%, #17255a 34%, #2b3e80 62%, #4a62b0 80%, #5b74c4 100%);
  --page-top: #dfe6f6;
  --nav-bg: rgba(250, 251, 255, .7);
  --menu-bg: #fbfcff;
  color-scheme: light;
}
[data-theme="light"] .grain { opacity: .06; filter: invert(1); }
[data-theme="light"] .horizon-glow { background: radial-gradient(50% 50% at 50% 50%, rgba(120, 145, 220, .42) 0%, rgba(150, 172, 235, .25) 30%, rgba(190, 205, 245, .14) 55%, transparent 72%); }
[data-theme="light"] .horizon-line { border-top-color: rgba(44, 63, 134, .45); background: linear-gradient(180deg, rgba(255, 255, 255, .45), transparent 80%); box-shadow: 0 -14px 60px -10px rgba(91, 116, 196, .35); }
[data-theme="light"] .glass { box-shadow: inset 0 1px 0 rgba(255, 255, 255, .9), 0 30px 70px -40px rgba(20, 36, 90, .35); }
[data-theme="light"] .glass::before { background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 50%), rgba(91, 116, 196, .1), transparent 60%); }
[data-theme="light"] .pill { background: rgba(255, 255, 255, .6); }
[data-theme="light"] .pill:hover { background: #fff; border-color: rgba(11, 20, 48, .25); }
[data-theme="light"] .pill-solid { background: var(--ink); color: #f5f6fa; }
[data-theme="light"] .pill-solid:hover { background: #1b2a5c; border-color: #1b2a5c; box-shadow: 0 10px 30px -10px rgba(20, 36, 90, .5); }
[data-theme="light"] .nav-links a.active { background: rgba(11, 20, 48, .07); }
[data-theme="light"] .scrolled .nav { box-shadow: 0 20px 50px -30px rgba(20, 36, 90, .35); }
[data-theme="light"] .nav-links { box-shadow: 0 30px 60px -20px rgba(20, 36, 90, .3); }
[data-theme="light"] .scroll-cue { border-color: rgba(11, 20, 48, .3); }
[data-theme="light"] .steps li.lit .step-no { box-shadow: 0 0 22px -4px rgba(44, 63, 134, .5); }
[data-theme="light"] .tool:hover { border-color: rgba(11, 20, 48, .2); }
[data-theme="light"] .hero-portrait .photo-frame::after { background: linear-gradient(180deg, rgba(20, 36, 90, .2) 0%, transparent 45%, rgba(11, 20, 48, .4) 100%), radial-gradient(110% 80% at 50% 35%, transparent 55%, rgba(11, 20, 48, .35) 100%); }
[data-theme="light"] .photo-frame::after { background: radial-gradient(120% 90% at 50% 40%, transparent 60%, rgba(11, 20, 48, .3) 100%); }
[data-theme="light"] .contact-bg { opacity: .1; }
[data-theme="light"] .play { color: #f3f6ff; }
[data-theme="light"] .site-footer { background: var(--night-0); }
[data-theme="light"] ::selection { background: var(--ink); color: #fff; }

/* latest internship: numbers on top, story below, one glass panel */
.intern-body { display: grid; justify-items: center; text-align: center; gap: 16px; margin: 6px 12px 0; padding: clamp(26px, 3.4vw, 40px) clamp(10px, 3vw, 40px) clamp(22px, 3vw, 34px); border-top: 1px solid var(--line); }
.intern-name { font-size: 1.15rem; font-weight: 700; letter-spacing: .02em; }
.intern-body > p:not(.note) { max-width: 52ch; font-size: 1.08rem; }

/* interests: the panel that pitches what I want to do next */
.facts .interests { padding: clamp(30px, 4vw, 52px); gap: 14px; }
.facts .interests dd { display: grid; gap: 22px; font-size: 1.05rem; }
.interests .title { margin-top: 4px; }
.int-lead { max-width: 60ch; color: var(--ink-2); font-size: 1.1rem; }
.int-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-top: 6px; }
.int-grid li { display: grid; align-content: start; gap: 8px; padding: 22px 22px 24px; border-radius: var(--radius-s); border: 1px solid var(--glass-line); background: var(--glass); transition: transform .5s var(--ease), border-color .4s, background .4s; }
.int-grid li:hover { transform: translateY(-4px); background: var(--glass-hi); }
.int-no { font-size: .72rem; font-weight: 700; letter-spacing: .14em; color: var(--ink-3); }
.int-grid h4 { font-size: 1.12rem; font-weight: 700; }
.int-grid p { font-size: .95rem; color: var(--ink-2); }
.seeking { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; padding-top: 20px; border-top: 1px solid var(--line); color: var(--ink); }
.seeking .dot { animation: pulse 2.4s ease-in-out infinite; }
.seeking .text-link { margin-left: auto; }
@keyframes pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(217, 181, 108, .55); } 50% { box-shadow: 0 0 0 7px rgba(217, 181, 108, 0); } }
@media (max-width: 900px) { .int-grid { grid-template-columns: 1fr; } .seeking .text-link { margin-left: 0; } }
@media (prefers-reduced-motion: reduce) { .seeking .dot { animation: none; } }

/* recommendations: the excerpt sits in real quotation marks; the opening mark hangs into the margin */
.excerpt { position: relative; }
.excerpt::before { content: "“"; position: absolute; right: 100%; padding-right: .06em; }
.excerpt::after { content: "”"; }

/* ---------- large screens (big monitors, TVs) ----------
   Everything is in rem, so raising the root size scales type, spacing and panels together;
   the content column widens a little so it doesn't float in the middle of a big screen. */
@media (min-width: 1700px) { html { font-size: 112.5%; } :root { --shell: 1400px; } }
@media (min-width: 2300px) { html { font-size: 137.5%; } :root { --shell: 1700px; } }
@media (min-width: 3200px) { html { font-size: 200%; } :root { --shell: 2400px; } }

/* podcast slide: the full 16:9 frame (no crop, no zoom), linking to YouTube */
.video-slide .podcast { display: block; aspect-ratio: 16 / 9; height: clamp(340px, 46vw, 540px); width: auto; }
.podcast > img { width: 100%; height: 100%; object-fit: cover; }
.video-slide:hover img { transform: none; }
/* the burned-in subtitle sits in the bottom strip: a soft blur that fades into the midnight hides it quietly */
.sub-fade {
  position: absolute; left: 0; right: 0; bottom: 0; height: 26%; z-index: 1; pointer-events: none;
  background: linear-gradient(to top, rgba(7, 14, 36, .82) 0%, rgba(7, 14, 36, .55) 38%, rgba(7, 14, 36, 0) 100%);
  -webkit-backdrop-filter: blur(7px); backdrop-filter: blur(7px);
  -webkit-mask-image: linear-gradient(to top, #000 45%, transparent); mask-image: linear-gradient(to top, #000 45%, transparent);
}
/* play button: quiet glass at rest; on hover it fills white, grows and sends out a ring */
.yt-play { position: absolute; inset: 0; margin: auto; z-index: 2; width: 74px; height: 74px; border-radius: 50%; display: grid; place-items: center; color: #f3f6ff; background: rgba(10, 18, 44, .45); border: 1px solid rgba(230, 237, 255, .5); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); transition: transform .5s var(--ease), background .35s, color .35s, box-shadow .5s; }
.yt-play svg { width: 26px; fill: currentColor; margin-left: 4px; }
.yt-play::before { content: ""; position: absolute; inset: -1px; border-radius: 50%; border: 1px solid rgba(230, 237, 255, .6); opacity: 0; }
.podcast:hover .yt-play, .podcast:focus-visible .yt-play { transform: scale(1.18); background: #f3f6ff; color: #0b1430; box-shadow: 0 18px 50px -12px rgba(0, 0, 0, .7); }
.podcast:hover .yt-play::before, .podcast:focus-visible .yt-play::before { animation: ripple 1.8s var(--ease) infinite; }
.slide-note { margin-top: 4px; font-size: .88rem; color: var(--ink-3); max-width: 48ch; }
@media (max-width: 560px) { .video-slide .podcast { height: auto; width: calc(100vw - 48px); } }


/* languages: a light, open strip between hairlines (no glass panel), so it doesn't read as a third heavy box.
   Each level line fills to its share of the CEFR scale (Native = full, C1 ≈ 5/6, B2 ≈ 4/6) when the block scrolls in. */
.facts .langs { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 18px clamp(28px, 5vw, 72px); padding: 26px 4px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.facts .langs dd { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px clamp(20px, 4vw, 56px); }
.lang { display: grid; grid-template-columns: 1fr auto; align-items: baseline; gap: 10px 12px; }
.lang b { font-weight: 700; color: var(--ink); }
.lang i { font-style: normal; font-size: .78rem; font-weight: 700; letter-spacing: .08em; color: var(--ink-2); }
.meter { grid-column: 1 / -1; position: relative; height: 2px; border-radius: 2px; background: var(--line); overflow: hidden; }
.meter::after { content: ""; position: absolute; inset: 0; border-radius: inherit; background: linear-gradient(90deg, var(--glow), var(--glow-hot)); transform-origin: 0 50%; transform: scaleX(0); transition: transform 1.4s var(--ease); }
.facts.in .meter::after { transform: scaleX(var(--v)); }
.facts.in .lang:nth-child(2) .meter::after { transition-delay: .15s; }
.facts.in .lang:nth-child(3) .meter::after { transition-delay: .3s; }
@media (max-width: 700px) { .facts .langs { grid-template-columns: 1fr; } .facts .langs dd { grid-template-columns: 1fr; gap: 16px; } }
@media (prefers-reduced-motion: reduce) { .meter::after { transform: scaleX(var(--v)); } }


/* =====================================================================
   PHONE ONLY (≤ 600px). Everything below is scoped to phones; desktop and tablet are untouched.
   Goals: shorter page, less scrolling, no decorative arrows, tighter rhythm, easy thumb targets.
   ===================================================================== */
@media (max-width: 600px) {
  /* no arrow symbols on phones; carousel arrows go too (swipe instead) */
  .arr, .gallery-ctrl { display: none; }
  .pill { gap: 0; }

  /* rhythm: smaller section gaps */
  .section { padding: 64px 0 48px; }
  .section-head { gap: 12px; margin-bottom: 28px; }
  .sub { font-size: 1rem; }
  .title-l { font-size: 2.5rem; }
  .title-m { font-size: 1.85rem; }

  /* cover: fits one screen — compact portrait sits under the buttons */
  .hero { min-height: auto; padding: 104px 0 56px; }
  .hero-grid { gap: 28px; }
  .hero-copy { gap: 18px; }
  .lead { font-size: 1.05rem; }
  .hero-actions { width: 100%; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
  .hero-actions .pill { padding: 0 12px; }
  .hero-portrait { width: 100%; max-width: none; display: grid; grid-template-columns: 46% 1fr; align-items: end; gap: 16px; }
  .hero-portrait figcaption { margin: 0 0 6px; font-size: .85rem; text-align: left; }
  .scroll-cue { display: none; }

  /* latest internship */
  .numbers { padding-top: 40px; }
  .numbers .numbers-head { margin-bottom: 20px; }
  .stat-row li { padding: 18px 8px 16px; gap: 4px; }
  .stat-row b { font-size: 2.4rem; }
  .stat-row li > span { font-size: .66rem; letter-spacing: .1em; max-width: 14ch; }
  .intern-body { margin: 4px 6px 0; padding: 20px 8px 18px; gap: 12px; }
  .intern-body > p:not(.note) { font-size: 1rem; }

  /* work: postcard project + process */
  .project { padding: 10px; gap: 18px; }
  .project-body { padding: 4px 8px 14px; }
  .project-desc { margin: 12px 0 20px; font-size: 1rem; }
  .steps li { grid-template-columns: 30px 1fr; gap: 14px; padding: 10px 0; }
  .step-no { width: 30px; height: 30px; font-size: .66rem; }
  .steps::before, .steps::after { left: 14.5px; }
  .steps h4 { font-size: 1rem; margin-top: 4px; }
  .steps p { font-size: .9rem; }
  .gallery-head { margin: 56px 0 18px; }
  .track { gap: 12px; padding-inline: 16px; scroll-padding-inline: 16px; }
  .slide .photo-frame, .portrait-slide .photo-frame { height: 250px; }
  .wide-slide .photo-frame { aspect-ratio: 4 / 5; }
  .video-slide .podcast { width: calc(100vw - 56px); height: auto; aspect-ratio: 16 / 9; }
  .slide figcaption { font-size: .85rem; margin-top: 10px; }
  .work-foot { margin-top: 32px; gap: 18px; }
  .work-links { width: 100%; justify-content: space-between; gap: 14px; }

  /* experience */
  .exp-lists { padding: 22px 18px; gap: 26px; }
  .timeline li { gap: 4px; padding: 14px 0; }
  .when { display: flex; gap: 10px; align-items: baseline; }
  .timeline h4 { font-size: 1.05rem; }
  .timeline p:not(.when) { font-size: .92rem; }
  .facts { gap: 14px; margin-top: 14px; }
  .facts .langs { padding: 20px 2px; gap: 14px; }
  .facts .interests { padding: 24px 18px; }
  .facts .interests dd { gap: 16px; }
  .int-lead { font-size: 1rem; }
  .int-grid { gap: 8px; }
  .int-grid li { grid-template-columns: auto 1fr; column-gap: 12px; row-gap: 2px; padding: 14px 16px; }
  .int-grid li .int-no { grid-row: span 2; padding-top: 3px; }
  .int-grid h4 { font-size: 1rem; }
  .int-grid p { font-size: .88rem; }
  .seeking { padding-top: 16px; font-size: .98rem; }

  /* recommendations */
  .quotes { gap: 14px; }
  .quote { padding: 22px 20px 20px 26px; gap: 16px; }
  .excerpt { font-size: 1.08rem; }
  .person img { width: 44px; height: 44px; }
  .person p { font-size: .8rem; }
  .quote-foot { gap: 12px; }
  .more-toggle { min-height: 40px; }

  /* toolkit: one compact row per tool instead of tall tiles */
  .tools { grid-template-columns: 1fr; gap: 8px; margin-bottom: 18px; }
  .tools li:last-child { grid-column: auto; }
  .tool { flex-direction: row; text-align: left; align-items: center; gap: 14px; padding: 12px 16px; border-radius: var(--radius-s); }
  .tool > .tool-name, .tool > .tool-desc { display: block; }
  .tool-logo { width: 44px; height: 44px; border-radius: 11px; margin: 0; flex: none; box-shadow: none; }
  .tool-logo.tile { padding: 6px; }
  .tool-name { font-size: .95rem; }
  .tool-desc { font-size: .82rem; }
  .tool { display: grid; grid-template-columns: 44px 1fr; grid-template-rows: auto auto; column-gap: 14px; row-gap: 0; }
  .tool .tool-logo { grid-row: span 2; }
  .tool:hover { transform: none; }

  /* about: the hero already shows the portrait, so the second copy is skipped on phones */
  .about-photo { display: none; }
  .about-copy { gap: 14px; }
  .about-copy p { font-size: 1rem; }
  .pull { margin: 64px auto; gap: 16px; }
  .pull .title { font-size: 2rem; }

  /* moments: landscape full width, vertical video kept to a sensible size beside nothing */
  .videos { gap: 12px; }
  .video.tall { max-width: 62%; margin-inline: auto; }

  /* contact */
  .contact { min-height: auto; padding: 88px 0 190px; }
  .contact-inner { gap: 18px; }
  .contact-actions { width: 100%; display: grid; gap: 10px; }
  .handle { font-size: .76rem; max-width: 26rem; padding-inline: 12px; }

  /* footer */
  .site-footer { padding: 36px 0 30px; }
  .footer-inner { gap: 18px; }
}

/* ---------- lightness ----------
   The contact background only downloads once the contact section is near, then fades in. */
.js .contact-bg { opacity: 0; transition: opacity 1.2s var(--ease); }
.js .contact:not(.near) .contact-bg { background-image: none; }
.js .contact.near .contact-bg { opacity: .16; }
/* Touch devices: the glass panels sit on a flat background, so their blur is invisible but costly while scrolling.
   The nav keeps its blur (content really scrolls under it) and so does the podcast subtitle fade. */
@media (hover: none) {
  .glass, .play, .yt-play { -webkit-backdrop-filter: none; backdrop-filter: none; }
}
