@font-face {
  font-family: "Bricolage Grotesque";
  src: url("assets/fonts/bricolage.woff2") format("woff2");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: Geist;
  src: url("assets/fonts/geist.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Dancing Script";
  src: url("assets/fonts/dancing-script.woff2") format("woff2");
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}
:root {
  color-scheme: light dark;
  --ink: light-dark(#111e30, #edf5ff);
  --muted: light-dark(#4f6071, #b7c9dd);
  --line: light-dark(#d9e2e9, #3b516b);
  --page: light-dark(#f7fafd, #101d2e);
  --surface: light-dark(#fff, #18283c);
  --paper: light-dark(#eef4f9, #132237);
  --accent: #ff8668;
  --link: light-dark(#164f75, #a8d9ff);
  --meta: light-dark(#315a74, #a9cee8);
  --focus: light-dark(#a72e13, #ffbc96);
  --hero-glow: light-dark(#d7e7f5, #263e61);
  --glass: light-dark(#ffffffa8, #32495e82);
  --glass-edge: light-dark(#9cb6caad, #91b8d381);
  --glass-shadow: light-dark(#25405c14, #08152550);
  font-family: Geist, "Segoe UI", system-ui, sans-serif;
  --display: "Bricolage Grotesque", Geist, "Segoe UI", system-ui, sans-serif;
  color: var(--ink);
  background: var(--page);
  font-synthesis: none;
  scroll-padding-top: 1.5rem;
}
:root[data-theme="light"] { color-scheme: light; }
:root[data-theme="dark"] { color-scheme: dark; }
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; line-height: 1.6; }
.home-page {
  isolation: isolate;
  --page: light-dark(#fcfaf6, #101d2e);
  --paper: light-dark(#f6f0e7, #132237);
  --line: light-dark(#ded4c6, #3b516b);
  --glass: light-dark(#fcfaf6d9, #32495e82);
  --glass-edge: light-dark(#baaa95a8, #91b8d381);
  --glass-shadow: light-dark(#60442e1a, #08152550);
  --hero-glow: light-dark(transparent, #263e61);
  --cream: #f6f0e7;
  --sand: #ede2d3;
}
.home-page::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: linear-gradient(125deg, var(--page) 12%, light-dark(#fcfaf6, #192b42) 43%, light-dark(#fcfaf6, #182a36) 65%, var(--page) 90%);
  background-size: 170% 170%;
}
img, canvas { display: block; max-width: 100%; }
figure, h1, h2, h3, p { margin: 0; }
ul, ol { margin-block: .6rem 0; }
a { color: var(--link); text-underline-offset: .22em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 4px; }
.skip-link { position: absolute; z-index: 5; top: .5rem; left: .5rem; padding: .5rem 1rem; background: var(--surface); transform: translateY(-180%); }
.skip-link:focus { transform: none; }
.shell { width: min(1160px, calc(100% - 80px)); margin-inline: auto; }
.site-header { display: flex; justify-content: space-between; align-items: center; min-height: 76px; gap: 1rem 2rem; }
:root:has(.sticky-header) { scroll-padding-top: calc(var(--header-height, 76px) + 1rem); }
.sticky-header { position: sticky; top: 0; z-index: 4; background: var(--page); }
.sticky-header.is-scrolled { background: light-dark(#fcfaf6ed, #101d2ef2); box-shadow: inset 0 -1px var(--line); backdrop-filter: blur(14px); }
@media (hover: hover) and (pointer: fine) {
  .sticky-header:hover {
    background: light-dark(#fffdf9f2, #1a2c41f2);
    box-shadow: inset 0 -1px var(--glass-edge);
    backdrop-filter: blur(14px);
  }
}
.brand { display: inline-flex; align-items: center; gap: .7rem; color: var(--ink); font-weight: 760; letter-spacing: -.025em; text-decoration: none; }
.brand-mark { display: grid; place-items: center; width: 37px; height: 37px; border-radius: 8px; background: #111e30; color: var(--accent); font-size: .79rem; letter-spacing: .025em; }
nav { display: flex; flex-wrap: wrap; align-items: center; gap: .3rem .45rem; }
nav a { display: inline-flex; align-items: center; padding: .28rem .5rem; border: 1px solid transparent; border-radius: 6px; color: var(--ink); text-decoration: none; font-size: .93rem; font-weight: 650; }
.icon-nav a {
  --icon-accent: light-dark(#a64423, #ff9c75);
  --icon-glass: light-dark(#efe3d4b8, #42627eba);
  --icon-edge: light-dark(#bca78e90, #9ab9d18c);
  position: relative;
  display: grid;
  place-items: center;
  width: 2.25rem;
  height: 2.25rem;
  padding: 0;
  background: transparent;
}
.icon-nav a svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.icon-nav a span {
  position: absolute;
  inset: calc(100% + 2px) auto auto 50%;
  z-index: 1;
  transform: translateX(-50%);
  padding: .18rem .4rem;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: var(--surface);
  color: var(--ink);
  font-size: .75rem;
  white-space: nowrap;
  visibility: hidden;
  pointer-events: none;
}
.icon-nav a:focus-visible, .icon-nav a[aria-current="location"] {
  color: var(--icon-accent);
  background: var(--icon-glass);
  border-color: var(--icon-edge);
  backdrop-filter: blur(8px);
}
.icon-nav a:focus-visible span { visibility: visible; }
@media (hover: hover) and (pointer: fine) {
  .icon-nav a:hover {
    color: var(--icon-accent);
    background: var(--icon-glass);
    border-color: var(--icon-edge);
    backdrop-filter: blur(8px);
  }
  .icon-nav a:hover span { visibility: visible; }
}
@media (prefers-reduced-motion: no-preference) {
  .icon-nav a svg { transition: transform .16s ease; }
  .icon-nav a:focus-visible svg, .icon-nav a[aria-current="location"] svg { transform: translateY(-2px); }
}
@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  .icon-nav a:hover svg { transform: translateY(-2px); }
}
.hero {
  position: relative;
  overflow: hidden;
  color: var(--ink);
  background:
    radial-gradient(ellipse at 80% 15%, var(--hero-glow) 0%, transparent 68%),
    radial-gradient(var(--warm-hero-shape, ellipse 52% 82% at 82% 38%), light-dark(#eaddca, transparent), transparent 88%),
    linear-gradient(105deg, light-dark(#fff, transparent) 12%, light-dark(#fcfaf6, transparent)),
    var(--paper);
}
@media (max-width: 650px) {
  .home-page .hero { --warm-hero-shape: ellipse 76% 46% at 55% 82%; }
}
.hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  align-items: center;
  column-gap: clamp(1rem, 4vw, 3rem);
  padding-block: clamp(1.35rem, 3vw, 2.4rem) clamp(2.5rem, 5.3vw, 4.25rem);
}
.hero-greeting-slot {
  display: grid;
  grid-column: 1 / -1;
  place-items: center;
  block-size: 1.9em;
  font-size: clamp(1.125rem, calc(.96rem + .675vw), 1.5rem);
  margin-bottom: .5rem;
}
.hero-greeting {
  max-inline-size: 100%;
  padding: .27em .65em;
  border-radius: .42em;
  background: #fff;
  color: #973a17;
  font-family: "Dancing Script", cursive;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  pointer-events: none;
}
.greeting-ending { white-space: nowrap; }
@media (max-width: 650px) {
  .hero-greeting-slot { block-size: 3em; }
}
@media (prefers-reduced-motion: no-preference) {
  .hero-greeting { transition: opacity .3s ease-out; }
  .hero-greeting.is-leaving { opacity: 0; }
  .hero-greeting:not(.is-complete)::after, .greeting-ending::after {
    content: "";
    display: inline-block;
    width: 3px;
    height: .8em;
    margin-inline-start: 1px;
    background: #9a5a05;
  }
  .greeting-ending::after { animation: greeting-blink .9s step-end infinite; }
  @keyframes greeting-blink { 50% { opacity: 0; } }
  .hero-greeting.is-complete { animation: greeting-glow .45s ease-out; }
  @keyframes greeting-glow {
    from { text-shadow: 0 0 10px light-dark(#f4a43f9c, #ffc34d99); }
    to { text-shadow: 0 0 0 transparent; }
  }
}
.hero h1 {
  position: relative;
  isolation: isolate;
  width: fit-content;
  max-width: 100%;
  font-family: var(--display);
  font-size: clamp(2.35rem, 6.5vw, 5.5rem);
  line-height: 1;
  letter-spacing: -.055em;
  font-weight: 760;
}
.hero h1::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: -.45em -12%;
  background: radial-gradient(ellipse, light-dark(#e9906029, #ff966229), transparent 72%);
  pointer-events: none;
}
.hero-role { margin-top: .75rem; color: var(--meta); font-family: var(--display); font-weight: 700; font-size: clamp(1.15rem, 2.4vw, 1.85rem); line-height: 1.2; }
.hero-local { display: flex; flex-wrap: wrap; gap: .3rem .8rem; align-items: baseline; margin-top: 1rem; color: var(--muted); font-size: .88rem; }
.hero-location { color: var(--ink); font-weight: 650; }
.hero-flag { display: inline-block; width: 1.1rem; height: .69rem; border-radius: 2px; font-size: 0; background: radial-gradient(circle at 45% 50%, #f42a41 0 25%, transparent 28%), #006a4e; }
.hero-local time { font-variant-numeric: tabular-nums; }
.hero-clock, .hero-live { display: inline-flex; align-items: center; gap: .4rem; }
.hero-live { color: var(--ink); font-weight: 650; }
.live-dot { position: relative; width: .42rem; height: .42rem; border-radius: 50%; background: light-dark(#167249, #86dfb1); }
.live-dot::after { content: ""; position: absolute; inset: 0; border-radius: inherit; border: 1px solid light-dark(#167249, #86dfb1); opacity: 0; }
@keyframes live-pulse {
  0%, 50% { opacity: 0; transform: scale(1); }
  58% { opacity: .6; }
  90%, 100% { opacity: 0; transform: scale(2.3); }
}
.hero-intro { color: var(--muted); font-size: clamp(1.025rem, 1.55vw, 1.23rem); line-height: 1.65; max-width: 52ch; margin-block: 1.15rem 1.45rem; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: .8rem; }
.actions a { font-size: .93rem; white-space: nowrap; }
.button { padding: .68rem .98rem; border-radius: 5px; font-weight: 760; text-decoration: none; }
.primary { background: var(--accent); color: #241711; border: 1px solid var(--accent); }
.primary:hover { background: #ffa28b; }
.outline { color: var(--link); border: 1px solid var(--meta); }
.outline:hover { background: var(--surface); }
.text-link { color: var(--link); font-weight: 650; padding: .5rem .22rem; }
.theme-toggle { margin-inline-start: auto; min-height: 2.25rem; padding: .3rem .7rem; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); color: var(--link); font: 650 .8rem / 1.2 Geist, sans-serif; white-space: nowrap; cursor: pointer; }
.theme-icon-toggle { display: grid; place-items: center; margin: 0; width: 2.25rem; padding: 0; }
.theme-icon-toggle svg { display: none; width: 1.15rem; height: 1.15rem; }
.theme-icon-toggle[data-icon="light"] .theme-sun,
.theme-icon-toggle[data-icon="dark"] .theme-moon { display: block; }

.hero-engineer {
  --engineer-line: light-dark(#24445f, #a7c3da);
  --engineer-orange: light-dark(#b94e2b, #ff9a69);
  --engineer-shadow: light-dark(#28445f45, #040d1bb0);
  --coat-highlight: light-dark(#d7e7f2, #9abacf);
  --coat-midtone: light-dark(#aac6db, #4c728f);
  --coat-shadow: light-dark(#688da9, #29465f);
  display: block;
  justify-self: end;
  width: min(100%, 390px);
  height: auto;
}
.engineer-halo { fill: light-dark(#c6daea66, #314e6880); }
.engineer-ring { fill: none; stroke: var(--engineer-line); stroke-opacity: .22; stroke-width: 1.2; }
.engineer-outline { stroke: var(--engineer-line); stroke-opacity: .7; stroke-width: 1.5; stroke-linejoin: round; }
.engineer-jacket { fill: url(#engineer-coat-light); }
.engineer-shirt { fill: light-dark(#eaf3f9, #263e55); }
.engineer-skin { fill: url(#engineer-skin-light); }
.engineer-hair { fill: url(#engineer-hair-light); }
.engineer-eye { fill: #263044; }
.engineer-cast-shadow { fill: #142338; opacity: .16; }
.engineer-neck-shadow { fill: #8e4838; opacity: .18; }
.engineer-skin-shine, .engineer-hair-shine { fill: none; stroke-linecap: round; }
.engineer-skin-shine { stroke: #ffe8cd; stroke-width: 2.4; stroke-opacity: .63; }
.engineer-hair-shine { stroke: #b9d6e9; stroke-width: 1.8; stroke-opacity: .38; }
.engineer-face, .engineer-seam, .engineer-headset, .engineer-accent-line { fill: none; stroke-linecap: round; stroke-linejoin: round; }
.engineer-face { stroke: #6b4539; stroke-width: 1.65; }
.engineer-seam { stroke: var(--engineer-line); stroke-width: 1.45; }
.engineer-headset { stroke: var(--engineer-line); stroke-width: 5; }
.engineer-headset-pad { fill: url(#engineer-pad-light); stroke: var(--engineer-line); stroke-width: 1.3; }
.engineer-accent { fill: var(--engineer-orange); }
.engineer-accent-line { stroke: var(--engineer-orange); stroke-width: 2.3; }
@media (max-width: 700px) {
  .hero-inner { grid-template-columns: 1fr; row-gap: .65rem; }
  .hero-engineer { width: min(100%, 275px); justify-self: center; }
}

.section { padding-block: 4.2rem; }
#about, #projects { border-block-start: 1px solid var(--line); }
.home-page :is(#about, #projects, .credentials-stack > section, .contact) {
  border-image: linear-gradient(90deg, transparent, light-dark(#d1825d, #f3a37f), transparent) 1;
}
.section-head { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: .4rem 1rem; margin-bottom: 1.6rem; }
.section-head h2, .contact h2 { font-size: clamp(1.95rem, 4vw, 3.15rem); line-height: 1.08; letter-spacing: -.057em; }
.section-head > p { color: var(--muted); }
.meta { color: var(--meta); font-size: .86rem; line-height: 1.4; font-weight: 720; }
.project-link { display: inline-block; margin-top: .84rem; font-size: .94rem; font-weight: 700; }
.feature-flow { display: grid; align-content: center; padding: 2.2rem clamp(1.25rem, 4vw, 3.8rem); background: linear-gradient(light-dark(#b3c8d850, #9eb8d322) 1px, transparent 1px) 0 0 / 24px 24px, linear-gradient(90deg, light-dark(#b3c8d850, #9eb8d322) 1px, transparent 1px) 0 0 / 24px 24px, var(--paper); border-left: 1px solid var(--line); }
.feature-flow figcaption { font-size: .88rem; font-weight: 720; margin-bottom: .65rem; color: var(--meta); }
.feature-flow ol { padding: 0; margin: 0; list-style: none; display: grid; gap: .35rem; }
.feature-flow li { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .15rem .5rem; background: var(--surface); padding: .56rem .75rem; border: 1px solid var(--line); border-left: 3px solid var(--meta); border-radius: 4px; }
.feature-flow span { color: var(--muted); font-size: .83rem; }
.project-grid, .focus-grid, .record-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.project-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.project-grid > .reveal-slot, .more .reveal-slot, .about-metrics .reveal-slot { display: grid; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 1040px) {
  .project-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .project-grid > .reveal-slot { grid-column: span 2; }
  .project-grid > .reveal-slot:nth-child(-n+2) { grid-column: span 3; }
}
.project { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.home-page .project { background-color: light-dark(#fff, transparent); }
.project-visual { flex-shrink: 0; aspect-ratio: 2.12; overflow: hidden; background: #16364a; }
.project-visual img { width: 100%; height: 100%; object-fit: cover; object-position: center; }
.project-carousel { position: relative; }
.project-carousel .carousel-slide { position: absolute; inset: 0; object-fit: contain; opacity: 0; visibility: hidden; }
.project-carousel .is-active { opacity: 1; visibility: visible; }
.carousel-controls { position: absolute; z-index: 2; right: 2px; bottom: 0; display: flex; color: #fff; }
.carousel-dots { display: flex; }
.carousel-controls button { appearance: none; display: grid; place-items: center; width: 16px; height: 20px; padding: 0; border: 0; background: transparent; color: inherit; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.carousel-controls button:focus-visible { outline: 2px solid #172337; outline-offset: -2px; box-shadow: inset 0 0 0 3px #fff; }
.carousel-dot::before { content: ""; width: 4px; height: 4px; border-radius: 99px; background: #b7bdbb; box-shadow: 0 0 0 1px #222f2bbf; }
.carousel-dot[aria-current="true"]::before { width: 9px; background: #a5bda3; }
.carousel-playback::before { content: ""; width: 8px; height: 8px; border-inline: 2px solid currentColor; filter: drop-shadow(0 0 1px #101722); }
.carousel-playback[data-paused]::before { width: 0; height: 0; border: 0; border-block: 4px solid transparent; border-inline-start: 8px solid currentColor; }
@media (any-pointer: coarse) {
  .carousel-controls { right: 0; }
  .carousel-controls button { width: 24px; height: 28px; padding: 8px 0 0 4px; }
}
@media (prefers-reduced-motion: no-preference) {
  .project-carousel .carousel-slide { transition: opacity .25s ease, visibility 0s .25s; }
  .project-carousel .is-active { transition-delay: 0s; }
}
.attendance-visual { border: 0; padding: .55rem clamp(.65rem, 1.6vw, 1.25rem); background: var(--paper); overflow: visible; }
.attendance-visual figcaption { margin-bottom: .25rem; }
.attendance-visual ol { gap: .2rem; }
.attendance-visual li { padding: .22rem .5rem; font-size: .85rem; line-height: 1.3; }
.attendance-visual span { font-size: .78rem; }
.project-copy { display: flex; flex: 1; flex-direction: column; align-items: flex-start; padding: 1.15rem; }
.project-copy h3 { margin-block: .3rem .42rem; }
.project-copy > p:not(.meta) { color: var(--muted); margin-bottom: .6rem; }
.project-copy .project-link { margin-top: auto; padding-top: .35rem; }
.cctv-visual, .thesis-visual { position: relative; display: grid; place-items: center; }
.cctv-visual { background: repeating-linear-gradient(0deg, transparent 0 17px, #67879a30 17px 18px), repeating-linear-gradient(90deg, transparent 0 17px, #67879a30 17px 18px), #19314a; }
.radar { position: relative; width: 40%; aspect-ratio: 1; border-radius: 50%; background: conic-gradient(from 25deg, #90c4f04f, transparent 72deg); }
.radar i { position: absolute; inset: 0; border: 1px solid #9abfda; border-radius: 50%; }
.radar i:nth-child(2) { inset: 16%; }
.radar i:nth-child(3) { inset: 34%; }
.radar b { position: absolute; width: 7px; height: 7px; background: #ff987d; top: 29%; right: 24%; border-radius: 50%; }
.thesis-visual { background: radial-gradient(ellipse at 55% 25%, #d5efeb, #a8d4cc); }
.signal { height: 64%; width: 68%; display: flex; gap: 6%; align-items: end; padding: .4rem 7%; border-left: 1px solid #275c59; border-bottom: 1px solid #275c59; }
.signal i { flex: 1; background: #266d67; height: 38%; border-radius: 2px 2px 0 0; }
.signal i:nth-child(2n) { height: 53%; }
.signal i:nth-child(3n) { height: 76%; }
.signal i:nth-child(4n) { height: 47%; }
.signal i:nth-child(7) { height: 68%; background: #985134; }
h1, h2, h3 { font-family: var(--display); }
h3 { font-size: clamp(1.13rem, 2vw, 1.42rem); line-height: 1.24; letter-spacing: -.025em; }
.more { margin-top: 1rem; text-align: center; }
.more summary { display: inline-flex; align-items: center; gap: .65rem; padding: .65rem .9rem; border: 1px solid var(--glass-edge); border-radius: 8px; background: var(--glass); font-weight: 760; color: var(--link); cursor: pointer; list-style: none; }
.more summary::-webkit-details-marker { display: none; }
.more summary::after { content: ""; width: .45rem; height: .45rem; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: translateY(-.1rem) rotate(45deg); }
.more[open] summary::after { transform: translateY(.1rem) rotate(225deg); }
.more ul {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.2rem 2rem;
  list-style: none;
  padding: clamp(1rem, 3vw, 2rem);
  border: 1px solid var(--glass-edge);
  border-radius: 8px;
  background: var(--glass);
  backdrop-filter: blur(10px);
  text-align: start;
  overflow: clip;
  scroll-margin-block-start: 4rem;
}
.more [data-enter] { border: 1px solid transparent; border-top-color: var(--line); border-radius: 5px; padding: .7rem .65rem; }
.more li h3 { margin-block: .2rem .3rem; font-size: 1.08rem; }
.more li p:not(.meta) { color: var(--muted); }
.more li .project-link { margin-top: .45rem; }
.project-grid .project, .more [data-enter] { position: relative; }
.project-grid .project-link::after, .more .project-link::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
}
:is(.project-grid, .more) .project-link:focus-visible { outline: none; }
:is(.project-grid, .more) .project-link:focus-visible::after {
  outline: 3px solid var(--focus);
  outline-offset: -3px;
  border-radius: 5px;
}
:is(.project-grid .project, .more [data-enter]):has(.project-link:focus-visible) {
  background: var(--glass);
  border-color: var(--glass-edge);
}
:is(.project-grid .project, .more [data-enter]):has(.project-link:focus-visible) h3 {
  color: light-dark(#9e3b1c, #ffab82);
}
@media (hover: hover) and (pointer: fine) {
  .more [data-enter]:hover { background: var(--glass); border-color: var(--glass-edge); }
  :is(.project-grid .project, .more [data-enter]):hover h3 { color: light-dark(#9e3b1c, #ffab82); }
}
.experience-band {
  background: light-dark(#fcfaf6ad, #132237b8);
  backdrop-filter: blur(10px);
  border-block: 1px solid var(--glass-edge);
}
.experience-grid { display: grid; grid-template-columns: 1.06fr .94fr; gap: 1rem; --entry-duration: 1s; --travel-x: 36px; }
.experience-grid > .reveal-slot { display: grid; grid-template-columns: minmax(0, 1fr); }
.experience-grid article, .focus-grid article, .profile-card { background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: clamp(1.1rem, 2.2vw, 1.8rem); }
.experience-grid h3, .profile-card .meta + h3 { margin-block: .3rem .55rem; }
.experience-grid p:not(.meta), .experience-grid li, .focus-grid p, .profile-card p:not(.meta) { color: var(--muted); }
.timeline { display: grid; gap: .6rem; list-style: none; padding: 0 0 0 .9rem; border-left: 2px solid #87a9be; margin-bottom: 1rem; }
.timeline li { display: grid; gap: .05rem; line-height: 1.42; }
.timeline strong { color: var(--ink); }
.timeline span { font-size: .875rem; }
.affiliation { font-weight: 650; }
.focus-grid p, .profile-card p:not(.meta) { margin-top: .5rem; }
.profile-section { padding-block: clamp(2rem, 4.6vw, 3.4rem); }
.about-copy { max-width: 68ch; color: var(--muted); }
.about-copy .reveal-slot + .reveal-slot { margin-top: .85rem; }
.about-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: .65rem;
  margin: 1.2rem 0 0;
  padding: 0;
  list-style: none;
}
.metric-card {
  display: grid;
  align-content: start;
  gap: .3rem;
  padding: .75rem clamp(.65rem, 1.5vw, 1rem);
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}
.about-metrics strong {
  position: relative;
  color: var(--link);
  font: 750 clamp(1.45rem, 2.5vw, 2rem) / 1.05 var(--display);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.metric-card > span { color: var(--muted); font-size: .86rem; line-height: 1.35; }
.metric-final { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
@media (hover: hover) and (pointer: fine) {
  .metric-card:hover { border-color: light-dark(#b88d75, #ba9078); }
}
@media (prefers-reduced-motion: no-preference) {
  .entrance-pending:not(:focus-within) { opacity: 0; }
  .about-copy p.reveal-in {
    --rise-distance: 12px;
    animation: rise-in .75s ease-out var(--entrance-delay, 0ms) both;
  }
  .project-grid { --travel-x: 48px; --travel-y: 40px; --entry-duration: 1.1s; }
  .more ul { --travel-x: 28px; --travel-y: 22px; --entry-duration: .85s; }
  [data-enter="left"], [data-enter="lower-left"] { --entry-x: calc(-1 * var(--travel-x)); }
  [data-enter="right"], [data-enter="lower-right"] { --entry-x: var(--travel-x); }
  [data-enter="below"], [data-enter^="lower-"] { --entry-y: var(--travel-y); }
  [data-enter="above"] { --entry-y: calc(-.6 * var(--travel-y)); }
  [data-enter].reveal-in { animation: project-entry var(--entry-duration) ease-out var(--entrance-delay, 0ms) both; }
  @keyframes project-entry {
    from { opacity: 0; translate: var(--entry-x, 0px) var(--entry-y, 0px); }
    to { opacity: 1; translate: 0 0; }
  }
  .project-featured { --work-travel: 28px; --work-offset: calc(-1 * var(--work-travel)); }
  .project-grid > :nth-child(2) > .project-featured { --work-offset: var(--work-travel); }
  .project-featured.reveal-in { animation: featured-project-enter .9s ease-out both; }
  @keyframes rise-in {
    from { opacity: 0; translate: 0 var(--rise-distance); }
    to { opacity: 1; translate: 0 0; }
  }
  @keyframes featured-project-enter {
    from { opacity: 0; translate: var(--work-offset) 0; }
    to { opacity: 1; translate: 0 0; }
  }
  .metric-card { transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease; }
  .metric-card.reveal-in { animation: metric-enter .38s ease-out var(--metric-delay, 0ms) both; }
  .about-metrics li:nth-child(2) { --metric-delay: 55ms; }
  .about-metrics li:nth-child(3) { --metric-delay: 110ms; }
  .about-metrics li:nth-child(4) { --metric-delay: 165ms; }
  .about-metrics li:nth-child(5) { --metric-delay: 220ms; }
  .about-metrics li:nth-child(6) { --metric-delay: 275ms; }
  @keyframes metric-enter {
    from { opacity: 0; translate: 0 6px; }
    to { opacity: 1; translate: 0 0; }
  }
}
@media (min-width: 881px) and (max-width: 1270px) {
  .project-grid { --travel-x: 39px; }
}
@media (max-width: 880px) {
  .experience-grid { --travel-x: 20px; }
  .project-grid { --travel-x: 20px; --travel-y: 26px; }
  .project-featured { --work-travel: 20px; }
}
@media (max-width: 650px) {
  .experience-grid { --travel-x: 12px; }
  .project-grid, .more ul { --travel-x: 12px; --travel-y: 16px; }
  .project-featured { --work-travel: 8px; }
}
@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  .metric-card:hover { transform: translateY(-3px); box-shadow: 0 6px 18px var(--glass-shadow); }
}
@media (min-width: 650px) {
  .about-metrics { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (min-width: 1040px) {
  .about-metrics { grid-template-columns: repeat(6, minmax(0, 1fr)); }
}
.skill-categories { border-block-end: 1px solid var(--line); }
.skill-category { display: grid; grid-template-columns: 14rem minmax(0, 1fr); align-items: start; gap: .5rem 1rem; padding: .75rem .65rem; border-top: 1px solid var(--line); }
.skill-category h3 { padding-block: .24rem; font-size: 1rem; }
.skill-chips { display: flex; flex-wrap: wrap; gap: .38rem; margin: 0; padding: 0; list-style: none; }
.skill-chips li { max-width: 100%; padding: .18rem .58rem; border-radius: 5px; background: var(--paper); color: var(--ink); font-size: .88rem; overflow-wrap: anywhere; }
@media (hover: hover) and (pointer: fine) {
  .skill-categories > .reveal-slot:hover > .skill-category {
    background: var(--glass);
    box-shadow: inset 0 0 0 1px var(--glass-edge);
    backdrop-filter: blur(8px);
  }
}
@media (prefers-reduced-motion: no-preference) {
  .skill-category { transition: background-color .2s ease, box-shadow .2s ease; }
  .skill-category.reveal-in {
    --rise-distance: 8px;
    animation: rise-in .6s ease-out var(--entrance-delay, 0ms) both;
  }
}
.credentials-stack > section {
  border-top: 1px solid var(--line);
  --travel-x: 28px;
  --entry-duration: .9s;
}
.credentials-stack .reveal-slot:has(> .profile-card) { display: grid; grid-template-columns: minmax(0, 1fr); }
.credentials-stack :is(#certifications, #awards, #leadership) .profile-card:has(:focus-visible) {
  border-color: var(--glass-edge);
  box-shadow: 0 4px 16px var(--glass-shadow);
}
@media (hover: hover) and (pointer: fine) {
  .credentials-stack :is(#certifications, #awards, #leadership) .reveal-slot:hover > .profile-card {
    border-color: var(--glass-edge);
    box-shadow: 0 4px 16px var(--glass-shadow);
  }
}
@media (prefers-reduced-motion: no-preference) {
  .credentials-stack :is(#certifications, #awards, #leadership) .profile-card {
    transition: scale .2s ease, border-color .2s ease, box-shadow .2s ease;
  }
  .credentials-stack :is(#certifications, #awards, #leadership) .profile-card:has(:focus-visible) { scale: 1.02; }
}
@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  .credentials-stack :is(#certifications, #awards, #leadership) .reveal-slot:hover > .profile-card { scale: 1.02; }
}
@media (max-width: 880px) {
  .credentials-stack > section { --travel-x: 18px; }
}
@media (max-width: 650px) {
  .credentials-stack > section { --travel-x: 10px; }
}
.education-grid, .leadership-grid { display: grid; gap: 1rem; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.education-grid { grid-template-columns: 1.3fr 1fr; }
.education-secondary, .credential-list { display: grid; align-content: start; gap: .65rem; list-style: none; }
.education-secondary { margin: 0; }
.education-secondary li + li { border-top: 1px solid var(--line); }
.education-secondary span, .credential-list span { display: block; color: var(--muted); font-size: .87rem; }
.education-entry {
  padding: .5rem;
  border: 1px solid transparent;
  border-radius: 5px;
}
.education-entry span strong { color: var(--ink); white-space: nowrap; }
#security .focus-grid, .education-secondary .reveal-slot { --travel-x: 32px; --entry-duration: .9s; }
#security .focus-grid { --travel-y: 26px; }
#security .reveal-slot { display: grid; grid-template-columns: minmax(0, 1fr); }
#security article {
  position: relative;
  --security-edge: light-dark(#bd775694, #ffab828f);
}
@property --security-sweep {
  syntax: "<angle>";
  inherits: false;
  initial-value: 0deg;
}
@media (hover: hover) and (pointer: fine) {
  #security article:hover { border-color: var(--security-edge); }
  .education-entry:hover {
    background: light-dark(#f6f0e7c4, #32495e82);
    border-color: var(--glass-edge);
  }
}
@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  #security article, .education-entry { transition: border-color .2s ease, background-color .2s ease; }
  #security article:hover::after {
    content: "";
    position: absolute;
    inset: -1px;
    padding: 2px;
    border-radius: inherit;
    background: conic-gradient(from var(--security-sweep), transparent, light-dark(#cf7448, #ffc29d) 42deg, transparent 85deg);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
    pointer-events: none;
    animation: security-border-sweep .85s ease-out both;
  }
  @keyframes security-border-sweep {
    from { --security-sweep: -42deg; opacity: 0; }
    20% { opacity: 1; }
    to { --security-sweep: 318deg; opacity: 0; }
  }
}
@media (max-width: 880px) {
  #security .focus-grid, .education-secondary .reveal-slot { --travel-x: 18px; }
}
@media (max-width: 650px) {
  #security .focus-grid, .education-secondary .reveal-slot { --travel-x: 10px; }
  #security .focus-grid { --travel-y: 14px; }
}
.credential-list { padding: 0; }
.credential-list li + li { padding-top: .65rem; border-top: 1px solid var(--line); }
#awards > .reveal-slot { max-width: 46rem; }
#awards .award-card { background: light-dark(#fffdf9, #18283c); }
.contact { background: var(--paper); color: var(--ink); border-top: 1px solid var(--line); }
.contact-inner { max-width: 60rem; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; gap: 1rem 2rem; padding-block: 2.2rem; }
.contact-social, .contact-intro { display: grid; gap: .65rem; }
.contact-intro > p { color: var(--muted); }
.contact-email { display: flex; flex-wrap: wrap; align-items: center; gap: .55rem .7rem; }
.contact-email a { overflow-wrap: anywhere; }
.copy-email { min-inline-size: 7rem; padding: .45rem .7rem; background: transparent; font: inherit; font-weight: 700; cursor: pointer; }
.copy-email-status { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.contact-inner > .copyright { grid-column: 1 / -1; text-align: center; }
.contact-links { display: flex; flex-wrap: wrap; gap: .3rem 1rem; }
.contact-links a { color: var(--link); display: inline-flex; align-items: center; gap: .35rem; padding-block: .3rem; }
.contact-icon { display: grid; place-items: center; width: 1.65rem; height: 1.65rem; border: 1px solid transparent; border-radius: 5px; }
.contact-icon svg { width: .95rem; height: .95rem; }
.copyright { color: var(--muted); font-size: .84rem; }
.contact-links a:focus-visible .contact-icon { background: var(--glass); border-color: var(--glass-edge); backdrop-filter: blur(8px); }
.case-hero { background: var(--paper); color: var(--ink); padding-block: clamp(2rem, 7vw, 5rem); }
.case-hero .meta { color: var(--meta); }
.case-hero h1 { font-size: clamp(2.25rem, 6vw, 5rem); line-height: 1.02; letter-spacing: -.06em; margin-block: .55rem 1rem; max-width: 17ch; }
.case-hero h1 + p { max-width: 59ch; color: var(--muted); font-size: 1.13rem; }
.case-main { display: grid; grid-template-columns: 1.55fr .75fr; align-items: start; gap: 2rem; }
.case-story section + section { margin-top: 1.6rem; }
.case-story h2 { font-size: clamp(1.35rem, 3vw, 1.8rem); letter-spacing: -.04em; }
.case-story p, .case-story li { color: var(--muted); }
.case-story h2 + p { margin-top: .45rem; }
.case-facts { background: var(--paper); border: 1px solid var(--line); border-radius: 8px; padding: 1rem 1.2rem; margin: 0; }
.case-facts div + div { border-top: 1px solid var(--line); margin-top: .7rem; padding-top: .7rem; }
.case-facts dt { font-weight: 700; }
.case-facts dd { margin: .15rem 0 0; color: var(--muted); }
.case-visuals { grid-column: 1/-1; }
.case-visuals figure { border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.case-visuals img { width: 100%; }
.case-visuals figcaption { padding: .7rem .9rem; color: var(--muted); }
.case-main > .feature-flow { border: 1px solid var(--line); border-radius: 8px; }
.case-bottom { grid-column: 1/-1; }
@media (max-width: 880px) {
  .shell { width: calc(100% - 44px); }
  .project-grid, .record-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 650px) {
  :root:has(.sticky-header) { scroll-padding-top: calc(var(--header-height, 9rem) + 1rem); }
  .shell { width: calc(100% - 34px); }
  .site-header { flex-wrap: wrap; padding-block: .65rem; gap: .45rem 1rem; }
  .site-header nav { flex-basis: 100%; gap: .15rem .2rem; }
  nav a { padding-inline: .34rem; }
  .hero-intro { margin-block: .85rem 1.1rem; }
  .hero-local { margin-top: .7rem; }
  .section { padding-block: 2.7rem; }
  .project-grid, .experience-grid, .focus-grid, .record-grid, .more ul, .case-main, .education-grid, .leadership-grid, .skill-category { grid-template-columns: 1fr; }
  .feature-flow { border-left: 0; border-top: 1px solid var(--line); }
  .attendance-visual { border: 0; min-height: min-content; }
  .contact-inner { grid-template-columns: minmax(0, 1fr); padding-block: 1.7rem; }
}
.case-visuals h2 { font-size: clamp(1.35rem, 3vw, 1.8rem); letter-spacing: -.04em; margin-bottom: .65rem; }
.gallery { display: grid; gap: .65rem; }
.gallery figure img { width: 100%; aspect-ratio: 2.14; object-fit: contain; background: var(--paper); }
.gallery-controls { display: flex; flex-wrap: wrap; gap: .45rem; }
.gallery-controls button { color: var(--link); border: 1px solid var(--meta); background: var(--surface); border-radius: 5px; padding: .46rem .75rem; font: inherit; font-weight: 650; cursor: pointer; }
.gallery-controls button:hover { background: var(--paper); }

@keyframes enter {
  from { opacity: .54; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes profile-enter {
  from { opacity: .8; transform: translateY(5px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes homepage-gradient {
  from { background-position: 0% 40%; }
  to { background-position: 100% 60%; }
}
@keyframes screen-change {
  from { opacity: .38; transform: scale(.992); }
  to { opacity: 1; transform: scale(1); }
}
@media (prefers-reduced-motion: no-preference) {
  .home-page::before { animation: homepage-gradient 52s ease-in-out infinite alternate; }
  .profile-section.reveal-in { animation: profile-enter .42s ease-out both; }
  .live-dot::after { animation: live-pulse 4s ease-out infinite; }
  .contact-icon { transition: transform .16s ease, background-color .16s ease, border-color .16s ease; }
  .contact-links a:focus-visible .contact-icon { transform: translateY(-2px); }
  .hero-copy h1 { animation: enter .54s cubic-bezier(.2,.7,.2,1) both; }
  .hero-intro { animation: enter .55s .09s cubic-bezier(.2,.7,.2,1) both; }
  .actions { animation: enter .54s .16s cubic-bezier(.2,.7,.2,1) both; }
  .reveal-in { animation: enter .45s cubic-bezier(.2,.7,.2,1) both; }
  .gallery[data-enhanced] figure:not([hidden]) img { animation: screen-change .3s ease-out both; }
  nav a, .theme-icon-toggle, .more summary, .project, .experience-grid article, .button { transition: box-shadow .2s ease, border-color .2s ease, background-color .2s ease; }
  .project-visual:not(.project-carousel) img { transition: transform .35s ease; }
}
@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  .contact-links a:hover .contact-icon { transform: translateY(-2px); }
  .project:hover .project-visual:not(.project-carousel) img { transform: scale(1.035); }
  .button:hover { transform: translateY(-2px); }
}

nav:not(.icon-nav) a:focus-visible, .theme-icon-toggle:focus-visible, .more summary:focus-visible,
.project:has(:focus-visible) {
  background: var(--glass);
  border-color: var(--glass-edge);
  box-shadow: 0 6px 20px var(--glass-shadow);
  backdrop-filter: blur(8px);
}
@media (hover: hover) and (pointer: fine) {
  .contact-links a:hover .contact-icon { background: var(--glass); border-color: var(--glass-edge); backdrop-filter: blur(8px); }
  nav:not(.icon-nav) a:hover, .theme-icon-toggle:hover, .more summary:hover,
  .project:hover {
    background: var(--glass);
    border-color: var(--glass-edge);
    box-shadow: 0 6px 20px var(--glass-shadow);
    backdrop-filter: blur(8px);
  }
}
.experience-grid article:has(:focus-visible) {
  border-color: var(--glass-edge);
  box-shadow: 0 6px 20px var(--glass-shadow);
}
@media (hover: hover) and (pointer: fine) {
  .experience-grid article:hover {
    border-color: var(--glass-edge);
    box-shadow: 0 6px 20px var(--glass-shadow);
  }
}

/* Full-width backdrops follow the section boxes without changing the content grid. */
.home-page > main { container-type: inline-size; }
.home-page :is(#about, #projects, #experience, #skills, #security, #credentials > section, #contact) {
  position: relative;
  isolation: isolate;
  --section-edge-fade: linear-gradient(var(--page), transparent 3.5rem calc(100% - 3.5rem), var(--page));
}
.home-page :is(#about, #projects, #experience, #skills, #security, #credentials > section, #contact)::before {
  content: "";
  display: block;
  position: absolute;
  inset-block: 0;
  inset-inline: 0;
  z-index: -1;
  pointer-events: none;
}
.home-page :is(#about, #projects, #skills, #security, #credentials > section)::before { inset-inline: calc(50% - 50cqw); }
.home-page #about::before {
  background:
    linear-gradient(to bottom, transparent calc(100% - 3.5rem), var(--page)),
    linear-gradient(100deg, light-dark(#fcfaf6, #18283c), light-dark(#fcfaf6, #172a36) 47%, light-dark(var(--cream), #101d2e));
}
.home-page #projects::before {
  background:
    var(--section-edge-fade),
    radial-gradient(ellipse 82% clamp(32rem, 65vw, 40rem) at 50% 15rem, light-dark(var(--sand), #293d61), light-dark(var(--cream), #1b2d48) 52%, transparent 100%),
    var(--page);
}
.home-page #experience::before {
  background: linear-gradient(180deg, light-dark(#f6f0e754, #14243867), light-dark(#ede2d3a3, #2743658c) 43%, light-dark(#f6f0e7a3, #1c34516b) 78%, light-dark(#f6f0e754, #14243867));
}
.home-page #skills::before {
  background: linear-gradient(var(--page), light-dark(#fffdf9, #14243a) 31%, light-dark(#fffdf9, #14243a) 76%, var(--page));
}
.home-page #security::before {
  background:
    var(--section-edge-fade),
    radial-gradient(ellipse at 11% 44%, transparent 4%, var(--page) 76%),
    linear-gradient(light-dark(#8f7d6812, #8eabc50a) 1px, transparent 1px) 0 0 / 32px 32px,
    linear-gradient(90deg, light-dark(#8f7d6812, #8eabc50a) 1px, transparent 1px) 0 0 / 32px 32px,
    radial-gradient(ellipse at 10% 50%, light-dark(#e5dbcd, #1c363d), light-dark(#f4ede3, #101d2e) 65%);
}
.home-page #education::before {
  background: var(--section-edge-fade), linear-gradient(120deg, light-dark(#fcfaf6, #223952), light-dark(var(--cream), #17293f) 64%, var(--page));
}
.home-page #certifications::before {
  background: var(--section-edge-fade), radial-gradient(ellipse at 55% 37%, light-dark(#e8ded2, #222f50), var(--page) 81%);
}
.home-page #awards::before {
  background: var(--section-edge-fade), radial-gradient(ellipse at 88% 49%, light-dark(#eee0cb, #302a37), light-dark(#f8f0e3, #18273a) 48%, var(--page) 86%);
}
.home-page #leadership::before {
  background: var(--section-edge-fade), linear-gradient(132deg, light-dark(var(--cream), #1b3440), light-dark(#f9f5ee, #172938) 46%, var(--page) 92%);
}
.home-page #contact::before {
  background:
    linear-gradient(light-dark(#fcfaf6, transparent), transparent 2.2rem),
    radial-gradient(ellipse at 52% 10%, light-dark(#e8d8c4, #1a2f49), light-dark(var(--sand), #101d2e) 76%);
}
