/* ==========================================================================
   Riyan Al Fajri — profile landing page
   Palette taken from his portrait: studio maroon (#670D0D) and tassel gold.
   ========================================================================== */

/* ---------- Tokens ---------- */
:root {
  --paper: #FBF7F1;
  --band: #F4ECE1;
  --surface: #FFFFFF;
  --ink: #1F1916;
  --ink-2: #4A413B;
  --muted: #6F655D;
  --line: #E6DBCD;
  --line-strong: #D6C8B7;
  --accent: #7A1418;
  --maroon: #7A1418;
  --maroon-hover: #5E0E12;
  --on-maroon: #FFF7EE;
  --gold: #C9973F;
  --gold-ink: #8A6420;
  --tint-maroon: rgba(122, 20, 24, .08);
  --tint-gold: rgba(201, 151, 63, .16);

  /* Maroon bands look the same in both themes */
  --photo-bg: #670D0D;
  --band-from: #560A0E;
  --band-to: #7A1418;
  --on-band: #FBF3EA;
  --on-band-muted: #E9D5C7;
  --band-gold: #E0B866;
  /* Songket-style diamond lattice, a nod to Malay woven textiles */
  --songket: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='56' height='56' viewBox='0 0 56 56'%3E%3Cg fill='none' stroke='%23E0B866' stroke-width='1'%3E%3Cpath d='M28 0 56 28 28 56 0 28Z' stroke-opacity='.22'/%3E%3Cpath d='M28 14 42 28 28 42 14 28Z' stroke-opacity='.15'/%3E%3C/g%3E%3Cg fill='%23E0B866' fill-opacity='.34'%3E%3Cpath d='M28 24 32 28 28 32 24 28Z'/%3E%3Cpath d='M0 -4 4 0 0 4 -4 0Z'/%3E%3Cpath d='M56 -4 60 0 56 4 52 0Z'/%3E%3Cpath d='M0 52 4 56 0 60 -4 56Z'/%3E%3Cpath d='M56 52 60 56 56 60 52 56Z'/%3E%3C/g%3E%3C/svg%3E");

  --shadow-sm: 0 1px 2px rgba(31, 25, 22, .06);
  --shadow: 0 1px 2px rgba(31, 25, 22, .05), 0 18px 40px -18px rgba(31, 25, 22, .28);
  --radius: 18px;
  --serif: "Fraunces", Georgia, "Times New Roman", serif;
  --sans: "Plus Jakarta Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --container: 1160px;
  --header-h: 68px;
  --ease: cubic-bezier(.2, .7, .2, 1);
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #14100E;
    --band: #1A1512;
    --surface: #221C18;
    --ink: #F4EDE5;
    --ink-2: #D9CEC3;
    --muted: #A99D92;
    --line: #382E28;
    --line-strong: #4B3F37;
    --accent: #F0A6A2;
    --maroon: #8E1B21;
    --maroon-hover: #A3242B;
    --gold: #D8AD5A;
    --gold-ink: #E2BD72;
    --tint-maroon: rgba(240, 166, 162, .1);
    --tint-gold: rgba(216, 173, 90, .14);
    --band-from: #3D080B;
    --band-to: #5E0E12;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, .4);
    --shadow: 0 1px 2px rgba(0, 0, 0, .35), 0 22px 44px -20px rgba(0, 0, 0, .75);
    color-scheme: dark;
  }
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

main { overflow-x: clip; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: .2em; }
h1, h2, h3 {
  margin: 0;
  font-family: var(--serif);
  font-weight: 600;
  line-height: 1.12;
  letter-spacing: -.012em;
  text-wrap: balance;
}
p { margin: 0 0 1em; }
ul, ol { margin: 0; padding: 0; list-style: none; }
figure, blockquote { margin: 0; }
abbr[title] { text-decoration: none; }
::selection { background: var(--maroon); color: var(--on-maroon); }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: 6px; }

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.icon { width: 1.15em; height: 1.15em; flex: none; }

.container { width: min(100% - 2rem, var(--container)); margin-inline: auto; }
@media (min-width: 768px) {
  .container { width: min(100% - 4rem, var(--container)); }
}

.skip-link {
  position: fixed;
  top: -4rem;
  left: 1rem;
  z-index: 100;
  padding: .6rem 1rem;
  border-radius: 10px;
  background: var(--maroon);
  color: var(--on-maroon);
  font-weight: 600;
  text-decoration: none;
  transition: top .2s;
}
.skip-link:focus { top: 1rem; }

/* ---------- Shared pieces ---------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: .7rem;
  margin: 0 0 1rem;
  color: var(--gold-ink);
  font-size: .76rem;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
}
.eyebrow::before {
  content: "";
  width: 28px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .6rem;
  min-height: 48px;
  padding: .8rem 1.35rem;
  border: 1.5px solid transparent;
  border-radius: 999px;
  font: 600 .98rem/1.2 var(--sans);
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color .2s, border-color .2s, color .2s, box-shadow .2s, transform .2s var(--ease);
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn-primary {
  background: var(--maroon);
  color: var(--on-maroon);
  box-shadow: 0 10px 24px -12px rgba(122, 20, 24, .75);
}
.btn-primary:hover { background: var(--maroon-hover); }
.btn-ghost { border-color: var(--line-strong); color: var(--ink); }
.btn-ghost:hover { border-color: var(--ink); }
.btn-sm { min-height: 40px; padding: .5rem .95rem; font-size: .88rem; }

.text-link {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  border-bottom: 1.5px solid transparent;
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
  transition: border-color .2s, gap .25s var(--ease);
}
.text-link:hover { border-color: currentColor; gap: .6rem; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--paper);
  background: color-mix(in srgb, var(--paper) 86%, transparent);
  -webkit-backdrop-filter: saturate(1.5) blur(14px);
  backdrop-filter: saturate(1.5) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s, box-shadow .3s;
}
.site-header.is-scrolled { border-bottom-color: var(--line); box-shadow: var(--shadow-sm); }

.nav { display: flex; align-items: center; gap: 1rem; height: var(--header-h); }

.brand { display: inline-flex; align-items: center; gap: .7rem; margin-right: auto; text-decoration: none; }
.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 11px;
  background: var(--photo-bg);
  box-shadow: inset 0 0 0 1px rgba(224, 184, 102, .35);
  color: var(--band-gold);
  font: 600 .95rem/1 var(--serif);
  letter-spacing: .04em;
}
.brand-name { font-size: 1rem; font-weight: 700; letter-spacing: -.005em; }

.nav-actions { display: flex; align-items: center; gap: .5rem; }
.nav-toggle {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1.5px solid var(--line-strong);
  border-radius: 12px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
}
.nav-toggle .icon { width: 22px; height: 22px; }
.nav-toggle .icon-close { display: none; }
.nav-toggle[aria-expanded="true"] .icon-open { display: none; }
.nav-toggle[aria-expanded="true"] .icon-close { display: block; }

/* Mobile: the menu drops down below the header */
.nav-menu {
  display: none;
  position: absolute;
  top: var(--header-h);
  left: 0;
  right: 0;
  border-bottom: 1px solid var(--line);
  background: var(--paper);
  box-shadow: var(--shadow);
}
.menu-open .nav-menu { display: block; }
.nav-links { width: min(100% - 2rem, var(--container)); margin-inline: auto; padding: .5rem 0 1rem; }
.nav-links a {
  display: block;
  padding: .85rem 0;
  border-bottom: 1px solid var(--line);
  font-family: var(--serif);
  font-size: 1.35rem;
  font-weight: 500;
  text-decoration: none;
}
.nav-links li:last-child a { border-bottom: 0; }

@media (min-width: 900px) {
  .nav-toggle { display: none; }
  .nav-menu {
    display: block;
    position: static;
    margin-right: 1rem;
    border: 0;
    background: none;
    box-shadow: none;
  }
  .nav-links { display: flex; gap: 2rem; width: auto; padding: 0; }
  .nav-links a {
    position: relative;
    padding: .4rem 0;
    border: 0;
    color: var(--ink-2);
    font-family: var(--sans);
    font-size: .94rem;
    font-weight: 500;
    transition: color .2s;
  }
  .nav-links a::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 2px;
    border-radius: 2px;
    background: var(--gold);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform .3s var(--ease);
  }
  .nav-links a:hover,
  .nav-links a.is-active { color: var(--ink); }
  .nav-links a:hover::after,
  .nav-links a.is-active::after { transform: scaleX(1); }
}

@media (max-width: 379px) {
  .brand-name { font-size: .95rem; }
  .nav-cta-label {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
  }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  isolation: isolate;
  padding: clamp(1.75rem, 5vw, 4.5rem) 0 clamp(3.5rem, 7vw, 6rem);
}
.hero::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: -10%;
  right: -15%;
  width: min(900px, 90vw);
  aspect-ratio: 1;
  background: radial-gradient(closest-side, var(--tint-gold), transparent);
}

.hero-grid { display: grid; gap: 3rem; align-items: center; }

.hero-copy { text-align: center; }
.hero-copy > * { animation: rise .9s var(--ease) backwards; }
.hero-copy > :nth-child(2) { animation-delay: .08s; }
.hero-copy > :nth-child(3) { animation-delay: .16s; }
.hero-copy > :nth-child(4) { animation-delay: .24s; }
.hero-copy > :nth-child(5) { animation-delay: .32s; }
.hero-copy > :nth-child(6) { animation-delay: .4s; }

.hero-title {
  margin-bottom: .2em;
  font-size: clamp(3.4rem, 9vw, 6.6rem);
  font-weight: 600;
  line-height: .95;
  letter-spacing: -.03em;
}
.hero-title .line { display: block; }
.hero-title em { color: var(--accent); font-style: italic; font-weight: 500; }

.hero-role {
  margin-bottom: 1.1rem;
  color: var(--ink-2);
  font-family: var(--serif);
  font-size: clamp(1.3rem, 2.4vw, 1.65rem);
  font-style: italic;
}
.hero-lead {
  max-width: 34rem;
  margin: 0 auto 2rem;
  color: var(--ink-2);
  font-size: clamp(1.05rem, 1.4vw, 1.15rem);
}
.hero-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: .75rem; margin-bottom: 1.6rem; }
.hero-note { margin: 0; color: var(--muted); font-size: .92rem; }
.hero-note a { color: var(--accent); font-weight: 600; }

.hero-portrait {
  position: relative;
  order: -1;
  justify-self: center;
  width: min(74vw, 340px);
  margin-bottom: 1.5rem;
  animation: rise 1s var(--ease) backwards;
}
/* Offset gold outline echoing the arch */
.hero-portrait::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: -12px 12px 12px -12px;
  border: 1.5px solid var(--gold);
  border-radius: 50% 50% 26px 26px / 40% 40% 26px 26px;
  opacity: .75;
}
.arch {
  overflow: hidden;
  aspect-ratio: 4 / 5;
  border-radius: 50% 50% 22px 22px / 40% 40% 22px 22px;
  background: var(--photo-bg);
  box-shadow: var(--shadow);
}
.arch img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 0; }

.hero-badge {
  position: absolute;
  left: 50%;
  bottom: -1.4rem;
  display: flex;
  align-items: center;
  gap: .75rem;
  padding: .65rem 1rem .65rem .7rem;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
  box-shadow: var(--shadow);
  white-space: nowrap;
  transform: translateX(-50%);
}
.badge-icon {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 11px;
  background: var(--tint-gold);
  color: var(--gold-ink);
}
.badge-icon .icon { width: 20px; height: 20px; }
.badge-text strong { display: block; font-size: .88rem; line-height: 1.3; }
.badge-text span { display: block; color: var(--muted); font-size: .78rem; line-height: 1.3; }

@media (min-width: 900px) {
  .hero-grid { grid-template-columns: minmax(0, 1.12fr) minmax(0, .88fr); gap: 4rem; }
  .hero-copy { text-align: left; }
  .hero-lead { margin-inline: 0; }
  .hero-actions { justify-content: flex-start; }
  .hero-portrait { order: 0; justify-self: end; width: 100%; max-width: 440px; margin: 0; }
  .hero-portrait::before { inset: -16px 16px 16px -16px; }
  .hero-badge { left: -2.25rem; bottom: 2.5rem; transform: none; }
}

@keyframes rise {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: none; }
}

/* ---------- Numbers ---------- */
.stats { border-block: 1px solid var(--line); }
.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  background: var(--line);
}
.stat { display: flex; flex-direction: column; gap: .45rem; padding: 1.5rem 1.1rem; background: var(--paper); }
.stat-num {
  color: var(--accent);
  font: 600 clamp(2.2rem, 4.2vw, 3.1rem)/1 var(--serif);
  letter-spacing: -.02em;
}
.stat-label { color: var(--muted); font-size: .9rem; line-height: 1.35; }

@media (min-width: 900px) {
  .stats-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .stat { padding: 2rem 1.75rem; }
}

/* ---------- Sections ---------- */
.section { padding: clamp(4.5rem, 9vw, 7.5rem) 0; scroll-margin-top: var(--header-h); }
.section-band { background: var(--band); }
.section-head { max-width: 46rem; margin-bottom: clamp(2.25rem, 5vw, 3.5rem); }
.section-head--split {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.5rem;
  max-width: none;
}
.section-head--split > div { max-width: 46rem; }
.section-title { font-size: clamp(2.1rem, 4.6vw, 3.25rem); }
.section-title em { color: var(--accent); font-style: italic; font-weight: 500; }
.section-intro { margin: 1.1rem 0 0; color: var(--ink-2); font-size: 1.1rem; }
.section-head .text-link { margin-top: 1.1rem; }

/* ---------- About ---------- */
.about-grid { display: grid; gap: 3rem; }
.about-title { margin-bottom: 1.5rem; font-size: clamp(1.9rem, 3.6vw, 2.75rem); }
.about-copy > p:not(.eyebrow) { color: var(--ink-2); }
.about-copy a { color: var(--accent); }

.dream {
  margin-top: 2.25rem;
  padding: 1.5rem 1.6rem;
  border: 1px solid var(--line);
  border-left: 3px solid var(--gold);
  border-radius: 4px 16px 16px 4px;
  background: var(--surface);
}
.dream figcaption {
  color: var(--muted);
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
}
.dream blockquote p {
  margin: .7rem 0 1rem;
  color: var(--ink);
  font: italic 500 clamp(1.15rem, 2vw, 1.35rem)/1.4 var(--serif);
}
.dream-note { display: flex; align-items: center; gap: .6rem; margin: 0; font-size: .95rem; font-weight: 600; }
.dream-check {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--maroon);
  color: var(--on-maroon);
}
.dream-check .icon { width: 15px; height: 15px; }

.glance {
  padding: 1.75rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}
.glance-title {
  margin-bottom: 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--line);
  font-size: 1.35rem;
}
.glance dl { display: grid; gap: 1.15rem; margin: 0; }
.glance dt {
  color: var(--gold-ink);
  font-size: .74rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.glance dd { margin: .3rem 0 0; font-weight: 500; line-height: 1.5; }
.chips { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .45rem; }
.chips li {
  padding: .3rem .7rem;
  border-radius: 999px;
  background: var(--tint-maroon);
  color: var(--accent);
  font-size: .82rem;
  font-weight: 600;
}

@media (min-width: 980px) {
  .about-grid { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 4.5rem; align-items: start; }
  .glance { position: sticky; top: calc(var(--header-h) + 1.5rem); }
}

/* ---------- Motto ---------- */
.motto {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: clamp(4.5rem, 10vw, 7rem) 0;
  background: linear-gradient(135deg, var(--band-from), var(--band-to));
  color: var(--on-band);
  text-align: center;
}
.motto::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0;
  background-image: var(--songket);
  background-position: center;
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(ellipse 70% 80% at 50% 50%, transparent 25%, #000 85%);
  mask-image: radial-gradient(ellipse 70% 80% at 50% 50%, transparent 25%, #000 85%);
}
.motto-figure { max-width: 54rem; margin-inline: auto; }
.motto-mark {
  display: block;
  height: 3.4rem;
  color: var(--band-gold);
  font: 600 6rem/1 var(--serif);
}
.motto blockquote p {
  margin: 0;
  font: italic 400 clamp(1.8rem, 4.4vw, 3.2rem)/1.2 var(--serif);
  letter-spacing: -.01em;
  text-wrap: balance;
}
.motto-translation { margin: 1.4rem 0 1.6rem; color: var(--on-band-muted); font-size: 1.05rem; text-wrap: balance; }
.motto figcaption {
  color: var(--band-gold);
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
}
.motto cite { font-style: normal; }

/* ---------- Focus ---------- */
.focus-grid { display: grid; gap: 1rem; }
.focus-card {
  padding: 1.75rem 1.6rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  transition: transform .35s var(--ease), box-shadow .35s, border-color .35s;
}
.focus-card:hover {
  border-color: color-mix(in srgb, var(--gold) 45%, var(--line));
  box-shadow: var(--shadow);
  transform: translateY(-4px);
}
.focus-icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  margin-bottom: 1.25rem;
  border-radius: 14px;
  background: var(--tint-maroon);
  color: var(--accent);
}
.focus-icon .icon { width: 24px; height: 24px; }
.focus-card h3 { margin-bottom: .55rem; font-size: 1.35rem; }
.focus-card p { margin: 0; color: var(--muted); font-size: .97rem; }

@media (min-width: 640px) {
  .focus-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 1080px) {
  .focus-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* ---------- Journey ---------- */
.legend { display: flex; gap: 1.25rem; margin-top: 1.4rem; color: var(--ink-2); font-size: .85rem; font-weight: 600; }
.legend li { display: inline-flex; align-items: center; gap: .5rem; }
.legend li::before {
  content: "";
  width: 13px;
  height: 13px;
  border: 3px solid var(--maroon);
  border-radius: 50%;
  background: var(--band);
}
.legend .legend-edu::before { border-color: var(--gold); }

.timeline { position: relative; max-width: 920px; }
.timeline::before {
  content: "";
  position: absolute;
  top: .6rem;
  bottom: .6rem;
  left: 8px;
  width: 2px;
  background: linear-gradient(to bottom, var(--gold), var(--line) 85%);
}
.tl-item { position: relative; padding: 0 0 1.75rem 2.4rem; }
.tl-item:last-child { padding-bottom: 0; }
.tl-item::before {
  content: "";
  position: absolute;
  top: .3rem;
  left: 0;
  width: 18px;
  height: 18px;
  border: 3.5px solid var(--maroon);
  border-radius: 50%;
  background: var(--band);
}
.tl-item[data-kind="edu"]::before { border-color: var(--gold); }
.tl-when { margin: 0 0 .6rem; color: var(--accent); font: 600 1.05rem/1.4 var(--serif); }
.tl-card {
  padding: 1.35rem 1.5rem;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
  transition: box-shadow .3s;
}
.tl-card:hover { box-shadow: var(--shadow); }
.tl-card h3 { font-size: 1.3rem; }
.tl-org { margin: .3rem 0 .65rem; color: var(--ink-2); font-size: .95rem; font-weight: 600; }
.tl-card p:last-child { margin: 0; color: var(--muted); font-size: .97rem; }

.tag {
  display: inline-block;
  margin-bottom: .75rem;
  padding: .22rem .6rem;
  border-radius: 999px;
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
}
.tag-career { background: var(--tint-maroon); color: var(--accent); }
.tag-edu { background: var(--tint-gold); color: var(--gold-ink); }

@media (min-width: 860px) {
  .timeline::before { left: 181px; }
  .tl-item { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 4rem; padding-left: 0; }
  .tl-item::before { top: 1.45rem; left: 173px; }
  .tl-when { margin: 1.25rem 0 0; text-align: right; }
}

/* ---------- Featured talk ---------- */
.talk { display: grid; gap: 2.25rem; align-items: center; }
.video {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  border-radius: 20px;
  background: #0D0A09;
  box-shadow: var(--shadow);
}
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-facade { position: absolute; inset: 0; display: block; }
.video-facade img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.video-facade::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, .45), transparent 45%);
}
.video-facade:hover img { transform: scale(1.03); }
.play-pill {
  position: absolute;
  z-index: 1;
  left: 1rem;
  bottom: 1rem;
  display: inline-flex;
  align-items: center;
  gap: .7rem;
  padding: .45rem 1.1rem .45rem .45rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, .95);
  box-shadow: 0 10px 30px -10px rgba(0, 0, 0, .5);
  color: #1F1916;
  font-size: .92rem;
  font-weight: 700;
  transition: transform .25s var(--ease);
}
.video-facade:hover .play-pill { transform: translateY(-2px); }
.play-dot {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--photo-bg);
  color: #FFF;
}
.play-dot .icon { width: 18px; height: 18px; margin-left: 2px; }
.talk-copy .section-title { margin-bottom: 1.1rem; }
.talk-copy > p:not(.eyebrow) { color: var(--ink-2); font-size: 1.06rem; }

@media (min-width: 960px) {
  .talk { grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 4rem; }
}

/* ---------- Writing ---------- */
.post-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .5rem .75rem;
  color: var(--muted);
  font-size: .8rem;
}
.post-tag {
  padding: .22rem .6rem;
  border-radius: 999px;
  background: var(--tint-maroon);
  color: var(--accent);
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.post-lang {
  margin-left: auto;
  padding: .1rem .4rem;
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  color: var(--ink-2);
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .08em;
}
.read-more {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  margin-top: auto;
  color: var(--accent);
  font-size: .9rem;
  font-weight: 700;
  transition: gap .25s var(--ease);
}
a:hover .read-more { gap: .65rem; }

.post-feature { margin-bottom: 1rem; }
.post-feature a {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: block;
  padding: clamp(1.75rem, 4.5vw, 3rem);
  border-radius: 22px;
  background: linear-gradient(135deg, var(--band-from), var(--band-to));
  box-shadow: var(--shadow);
  color: var(--on-band);
  text-decoration: none;
  transition: transform .35s var(--ease), box-shadow .35s;
}
.post-feature a::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0;
  background-image: var(--songket);
  background-size: 56px 56px;
  -webkit-mask-image: linear-gradient(to left, #000, transparent 75%);
  mask-image: linear-gradient(to left, #000, transparent 75%);
}
.post-feature a:hover { transform: translateY(-3px); }
.post-feature .post-meta { color: var(--on-band-muted); }
.post-feature .post-tag { background: rgba(224, 184, 102, .16); color: var(--band-gold); }
.post-feature h3 {
  max-width: 40rem;
  margin: 1rem 0 .9rem;
  font-size: clamp(1.7rem, 3.6vw, 2.6rem);
  line-height: 1.12;
}
.post-feature p { max-width: 38rem; margin-bottom: 1.6rem; color: var(--on-band-muted); font-size: 1.05rem; }
.post-feature .read-more { color: var(--band-gold); }

.posts { display: grid; gap: 1rem; }
.post a {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 1.6rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  text-decoration: none;
  transition: transform .35s var(--ease), box-shadow .35s, border-color .35s;
}
.post a:hover {
  border-color: color-mix(in srgb, var(--gold) 45%, var(--line));
  box-shadow: var(--shadow);
  transform: translateY(-4px);
}
.post h3 { margin: 1rem 0 .65rem; font-size: 1.28rem; line-height: 1.22; }
.post p { margin-bottom: 1.4rem; color: var(--muted); font-size: .95rem; }

@media (min-width: 700px) {
  .posts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 1040px) {
  .posts { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* ---------- Research ---------- */
.pubs { max-width: 960px; border-top: 1px solid var(--line); }
.pubs li { border-bottom: 1px solid var(--line); }
/* Phones: year sits above the title so long titles get the full width */
.pub {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas: "year arrow" "body body";
  gap: .3rem 1rem;
  align-items: start;
  padding: 1.4rem .25rem;
  border-radius: 12px;
  color: inherit;
  text-decoration: none;
  transition: background-color .25s;
}
a.pub:hover { background: var(--surface); }
.pub-year { grid-area: year; color: var(--accent); font: 600 1.1rem/1.5 var(--serif); }
.pub-body { grid-area: body; display: flex; flex-direction: column; gap: .35rem; }
.pub-title { color: var(--ink); font-size: 1.04rem; font-weight: 600; line-height: 1.45; transition: color .25s; }
.pub-venue { color: var(--muted); font-size: .9rem; overflow-wrap: anywhere; }
.pub-arrow {
  grid-area: arrow;
  width: 20px;
  height: 20px;
  margin-top: .2rem;
  color: var(--muted);
  transition: transform .25s var(--ease), color .25s;
}
a.pub:hover .pub-title { color: var(--accent); }
a.pub:hover .pub-arrow { color: var(--accent); transform: translate(2px, -2px); }

@media (min-width: 720px) {
  .pub {
    grid-template-columns: 5.5rem minmax(0, 1fr) auto;
    grid-template-areas: "year body arrow";
    gap: .25rem 1.25rem;
    padding: 1.6rem 1rem;
  }
}

/* ---------- Contact ---------- */
.contact { padding-top: 0; }
.contact-card {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: grid;
  gap: 2.25rem;
  padding: clamp(1.5rem, 6vw, 4.5rem);
  border-radius: 28px;
  background: linear-gradient(135deg, var(--band-from), var(--band-to));
  box-shadow: var(--shadow);
  color: var(--on-band);
}
.contact-card::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0;
  background-image: var(--songket);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(circle at 100% 0%, #000, transparent 65%);
  mask-image: radial-gradient(circle at 100% 0%, #000, transparent 65%);
}
.contact-card .eyebrow { color: var(--band-gold); }
.contact-copy > p:not(.eyebrow) { max-width: 30rem; margin: 1.1rem 0 0; color: var(--on-band-muted); font-size: 1.08rem; }

.contact-links { display: grid; gap: .7rem; }
.contact-link {
  display: flex;
  align-items: center;
  gap: .9rem;
  padding: .95rem 1.1rem;
  border: 1px solid rgba(255, 255, 255, .16);
  border-radius: 16px;
  background: rgba(255, 255, 255, .07);
  color: var(--on-band);
  text-decoration: none;
  transition: background-color .25s, transform .25s var(--ease);
}
.contact-link:hover { background: rgba(255, 255, 255, .13); transform: translateX(3px); }
.contact-link > .icon { width: 22px; height: 22px; }
.contact-text { display: flex; flex-direction: column; min-width: 0; }
.contact-text strong { font-size: 1rem; }
.contact-text span { color: var(--on-band-muted); font-size: .85rem; overflow-wrap: anywhere; }
.contact-arrow { width: 18px; height: 18px; margin-left: auto; opacity: .7; }
.contact-link.is-primary { border-color: transparent; background: var(--band-gold); color: #2A1A06; }
.contact-link.is-primary:hover { background: #EBC679; }
.contact-link.is-primary .contact-text span { color: rgba(42, 26, 6, .72); }

@media (min-width: 900px) {
  .contact-card { grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 4rem; align-items: center; }
}

/* ---------- Footer ---------- */
.site-footer { padding: 0 0 2.5rem; color: var(--muted); font-size: .9rem; }
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: .75rem 2rem;
  padding-top: 2rem;
  border-top: 1px solid var(--line);
}
.footer-inner p { margin: 0; }
.footer-inner a { color: var(--ink-2); }
.to-top { display: inline-flex; align-items: center; gap: .4rem; font-weight: 600; text-decoration: none; }

/* ---------- Reveal on scroll (classes set by js/main.js) ---------- */
.js [data-reveal] { opacity: 0; }
.js [data-reveal].is-visible { opacity: 1; animation: rise .85s var(--ease) var(--d, 0ms) backwards; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js [data-reveal] { opacity: 1; }
}
