/* =====================================================================
 * babakghahremani.com — styles
 * Editorial / gallery aesthetic with a warm-to-sky colour story pulled
 * from the portrait. Light + dark themes. Mobile-first responsive.
 * ===================================================================== */

/* ---------------- fonts ---------------- */
@font-face {
  font-family: "Fraunces";
  src: url("fonts/fraunces-var.woff2") format("woff2-variations");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("fonts/inter-400.woff2") format("woff2");
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("fonts/inter-500.woff2") format("woff2");
  font-weight: 500; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("fonts/inter-600.woff2") format("woff2");
  font-weight: 600; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("fonts/inter-700.woff2") format("woff2");
  font-weight: 700; font-style: normal; font-display: swap;
}

/* ---------------- tokens ---------------- */
:root {
  /* surfaces */
  --paper:      #f8f6f1;
  --paper-warm: #efece3;
  --card:       #fffefb;
  --ink:        #1b1a16;
  --ink-soft:   #4c4940;
  --ink-faint:  #7e786b;
  --line:       #e4e0d4;

  /* colour story: sage · taupe · petrol (from the Jee mark) */
  --c1: #4d8a87;
  --c2: #6c685c;
  --c3: #2f5e63;
  --c1-wash: #e3efee;
  --c2-wash: #edeae2;
  --c3-wash: #dde9eb;
  --c1-ink: #33726f;
  --c2-ink: #565246;
  --c3-ink: #27565b;

  --accent: var(--c1);
  --grad: linear-gradient(115deg, var(--c1) 0%, #5a7d74 50%, var(--c2) 100%);
  --grad-text: linear-gradient(112deg, #2f6b68 0%, #456f66 48%, #55524a 100%);
  --grad-soft: linear-gradient(115deg, var(--c1-wash), var(--c2-wash));

  --shade: 0 1px 2px rgba(40, 44, 40, 0.05), 0 12px 32px -14px rgba(40, 44, 40, 0.16);
  --shade-lift: 0 2px 6px rgba(40, 44, 40, 0.07), 0 26px 56px -18px rgba(40, 44, 40, 0.28);

  --radius: 18px;
  --maxw: 980px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);

  --font-body: "Inter", "Segoe UI", system-ui, -apple-system, Arial, sans-serif;
  --font-display: "Fraunces", Georgia, "Times New Roman", serif;

  color-scheme: light;
}

:root[data-theme="dark"] {
  --paper:      #101210;
  --paper-warm: #181a17;
  --card:       #1a1c19;
  --ink:        #eef0e9;
  --ink-soft:   #aeb0a4;
  --ink-faint:  #7e8177;
  --line:       #2a2d28;

  --c1: #93b3b2;
  --c2: #b8b0a0;
  --c3: #6fa3a6;
  --c1-wash: #18231f;
  --c2-wash: #211f1a;
  --c3-wash: #142124;
  --c1-ink: #a8c6c4;
  --c2-ink: #cdc4b2;
  --c3-ink: #8fbcbe;

  --grad: linear-gradient(115deg, var(--c1) 0%, #a3b2a9 50%, var(--c2) 100%);
  --grad-text: linear-gradient(112deg, #a6c8c6 0%, #b3c2b6 48%, #cfc5b3 100%);
  --grad-soft: linear-gradient(115deg, var(--c1-wash), var(--c2-wash));

  --shade: 0 1px 2px rgba(0, 0, 0, 0.5), 0 12px 32px -14px rgba(0, 0, 0, 0.7);
  --shade-lift: 0 2px 6px rgba(0, 0, 0, 0.5), 0 26px 56px -18px rgba(0, 0, 0, 0.8);

  color-scheme: dark;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16.5px;
  line-height: 1.72;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

/* colour blobs + film grain, fixed behind everything */
.bg-fx {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}
.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.3;
  will-change: transform;
}
:root[data-theme="dark"] .blob { opacity: 0.26; filter: blur(110px); }
.blob-1 { width: 52vw; height: 52vw; top: -16vw; right: -12vw; background: var(--c1); animation: drift1 26s ease-in-out infinite; }
.blob-2 { width: 44vw; height: 44vw; top: 28vh; left: -16vw; background: var(--c3); animation: drift2 32s ease-in-out infinite; }
.blob-3 { width: 38vw; height: 38vw; bottom: -14vw; right: 6vw; background: var(--c3); animation: drift3 38s ease-in-out infinite; }

@keyframes drift1 { 50% { transform: translate3d(-4vw, 4vh, 0) scale(1.1); } }
@keyframes drift2 { 50% { transform: translate3d(5vw, -3vh, 0) scale(0.92); } }
@keyframes drift3 { 50% { transform: translate3d(-3vw, -5vh, 0) scale(1.08); } }

.grain {
  position: absolute;
  inset: -50%;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
:root[data-theme="dark"] .grain { opacity: 0.06; }

a { color: inherit; text-decoration: none; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--c1);
  color: #fff;
  padding: 10px 18px;
  z-index: 100;
  border-radius: 0 0 10px 10px;
}
.skip-link:focus { left: 0; }

:focus-visible { outline: 2px solid var(--c2); outline-offset: 3px; border-radius: 6px; }

::selection { background: var(--c1); color: #fff; }

/* ---------------- header ---------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--paper) 78%, transparent);
  backdrop-filter: saturate(170%) blur(16px);
  -webkit-backdrop-filter: saturate(170%) blur(16px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s var(--ease), background 0.3s var(--ease);
}
.site-header.is-stuck { border-bottom-color: var(--line); }

.site-header .wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 66px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-size: 1.12rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  white-space: nowrap;
  min-width: 0;
}
.brand-mark {
  width: 28px; height: 28px;
  flex: none;
  border-radius: 9px;
  background: var(--grad);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 0.82rem;
  font-weight: 700;
  font-family: var(--font-body);
}
.brand-mark.has-logo { background: none; padding: 0; overflow: hidden; }
.brand-mark img { width: 100%; height: 100%; object-fit: cover; border-radius: inherit; display: block; }
.brand-text { overflow: hidden; text-overflow: ellipsis; }

.site-nav {
  display: flex;
  gap: 2px;
  margin-left: auto;
}
.site-nav a {
  position: relative;
  color: var(--ink-soft);
  padding: 8px 12px;
  font-size: 0.87rem;
  font-weight: 500;
  white-space: nowrap;
  transition: color 0.2s var(--ease);
}
.site-nav a::after {
  content: "";
  position: absolute;
  left: 12px; right: 12px;
  bottom: 3px;
  height: 2px;
  border-radius: 2px;
  background: var(--grad);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s var(--ease);
}
.site-nav a:hover { color: var(--ink); }
.site-nav a:hover::after, .site-nav a.is-active::after { transform: scaleX(1); }
.site-nav a.is-active { color: var(--ink); }

.header-actions { display: flex; gap: 8px; flex: none; margin-left: 4px; }

.btn-ghost {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--ink-soft);
  border-radius: 999px;
  padding: 7px 15px;
  font: inherit;
  font-size: 0.79rem;
  font-weight: 500;
  line-height: 1.6;
  cursor: pointer;
  transition: color 0.2s var(--ease), border-color 0.2s var(--ease), background 0.2s var(--ease);
}
.btn-ghost:hover { color: var(--c1); border-color: var(--c1); background: var(--c1-wash); }

.nav-toggle { display: none; }

/* ---------------- hero ---------------- */
.hero { padding: 72px 0 8px; }

.hero-inner {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 42px;
  align-items: center;
}

.portrait {
  position: relative;
  width: 172px;
  height: 172px;
  flex: none;
  border-radius: 50%;
  padding: 4px;
  background: var(--grad);
  box-shadow: var(--shade-lift);
  animation: float 7s ease-in-out infinite;
}
.portrait::after {
  content: "";
  position: absolute;
  inset: -14px;
  border-radius: 50%;
  border: 1px dashed color-mix(in srgb, var(--c2) 40%, transparent);
  animation: spin 46s linear infinite;
}
.portrait img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  display: block;
  background: var(--paper-warm);
}
.portrait .avatar-fallback {
  width: 100%; height: 100%;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--paper-warm);
  color: var(--c1);
  font-family: var(--font-display);
  font-size: 4rem;
  font-weight: 600;
}

@keyframes float { 50% { transform: translateY(-9px); } }
@keyframes spin { to { transform: rotate(360deg); } }

.hero-text { min-width: 0; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin: 0 0 16px;
  padding: 5px 14px 5px 10px;
  border-radius: 999px;
  background: var(--card);
  border: 1px solid var(--line);
  box-shadow: var(--shade);
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.eyebrow .dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--c2);
  box-shadow: 0 0 0 0 color-mix(in srgb, var(--c2) 60%, transparent);
  animation: pulse 2.6s ease-out infinite;
}
@keyframes pulse {
  70% { box-shadow: 0 0 0 9px transparent; }
  100% { box-shadow: 0 0 0 0 transparent; }
}

.hero h1 {
  margin: 0 0 14px;
  font-family: var(--font-display);
  font-weight: 600;
  font-variation-settings: "SOFT" 20, "WONK" 1;
  font-size: clamp(2.5rem, 7.5vw, 4.3rem);
  line-height: 1.02;
  letter-spacing: -0.025em;
  background: var(--grad-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  padding-bottom: 0.06em;
}

.hero .headline {
  margin: 0 0 6px;
  font-size: 1.04rem;
  font-weight: 500;
  color: var(--ink);
}
.hero .role { margin: 0 0 20px; color: var(--ink-soft); font-size: 0.97rem; }
.hero .summary { margin: 0 0 28px; color: var(--ink-soft); font-size: 1.04rem; max-width: 52ch; }

.cta-row { display: flex; gap: 12px; flex-wrap: wrap; }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 26px;
  min-height: 46px;
  border-radius: 999px;
  font-size: 0.93rem;
  font-weight: 600;
  transition: transform 0.22s var(--ease), box-shadow 0.22s var(--ease),
              color 0.22s var(--ease), border-color 0.22s var(--ease);
}
.btn-primary { background: var(--grad); color: #fff; box-shadow: var(--shade); }
:root[data-theme="dark"] .btn-primary { color: #141611; }
.btn-primary:hover { transform: translateY(-2px); box-shadow: var(--shade-lift); }
.btn-outline { border: 1px solid var(--line); color: var(--ink); background: var(--card); }
.btn-outline:hover { border-color: var(--c2); color: var(--c2); transform: translateY(-2px); }

/* ---------------- stats strip ---------------- */
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin: 54px 0 6px;
  padding: 22px;
  border-radius: var(--radius);
  background: var(--card);
  border: 1px solid var(--line);
  box-shadow: var(--shade);
}
.stat { text-align: center; }
.stat .value {
  display: block;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.6rem, 4vw, 2.1rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
}
.stat:nth-child(1) .value { color: var(--c1); }
.stat:nth-child(2) .value { color: var(--c2); }
.stat:nth-child(3) .value { color: var(--c3); }
.stat:nth-child(4) .value { color: var(--c1); }
.stat .label {
  display: block;
  margin-top: 4px;
  font-size: 0.76rem;
  color: var(--ink-faint);
  letter-spacing: 0.03em;
}

/* ---------------- sections ---------------- */
main { counter-reset: sec; }

section { padding: 62px 0; scroll-margin-top: 80px; }
section + section { border-top: 1px solid var(--line); }

.sec-head { margin: 0 0 32px; }
.sec-head h2 {
  margin: 0;
  display: flex;
  align-items: baseline;
  gap: 16px;
  font-family: var(--font-display);
  font-weight: 600;
  font-variation-settings: "SOFT" 20, "WONK" 1;
  font-size: clamp(1.8rem, 4.4vw, 2.5rem);
  line-height: 1.12;
  letter-spacing: -0.02em;
}
.sec-head h2::before {
  counter-increment: sec;
  content: counter(sec, decimal-leading-zero);
  flex: none;
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--c1);
}
.sec-head h2::after {
  content: "";
  flex: 1;
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--line), transparent);
  transform: translateY(-0.35em);
}
section:nth-of-type(3n + 2) .sec-head h2::before { color: var(--c2); }
section:nth-of-type(3n + 3) .sec-head h2::before { color: var(--c3); }

/* ---------------- cards ---------------- */
.timeline { display: flex; flex-direction: column; gap: 16px; }

.card {
  position: relative;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px 28px;
  box-shadow: var(--shade);
  overflow: hidden;
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), border-color 0.3s var(--ease);
}
.card::before {
  content: "";
  position: absolute;
  top: 0; left: 0;
  width: 3px;
  height: 100%;
  background: var(--grad);
  transform: scaleY(0);
  transform-origin: top;
  transition: transform 0.35s var(--ease);
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shade-lift);
  border-color: color-mix(in srgb, var(--c1) 30%, var(--line));
}
.card:hover::before { transform: scaleY(1); }
.card:nth-child(3n + 2):hover { border-color: color-mix(in srgb, var(--c2) 30%, var(--line)); }
.card:nth-child(3n + 3):hover { border-color: color-mix(in srgb, var(--c3) 30%, var(--line)); }

.card-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  align-items: baseline;
}
.card h3 { margin: 0 0 3px; font-size: 1.1rem; font-weight: 600; letter-spacing: -0.01em; }
.card .org {
  font-size: 0.95rem;
  font-weight: 600;
  background: var(--grad-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.card .period {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--ink-faint);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
  padding: 3px 11px;
  border-radius: 999px;
  background: var(--paper-warm);
}
.card .meta { color: var(--ink-faint); font-size: 0.82rem; margin-top: 6px; }

.card ul { margin: 16px 0 0; padding: 0; list-style: none; }
.card li {
  position: relative;
  padding-left: 20px;
  margin-bottom: 8px;
  color: var(--ink-soft);
  font-size: 0.96rem;
}
.card li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.68em;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--grad-soft);
  border: 1.5px solid var(--c1);
}
.card:nth-child(3n + 2) li::before { border-color: var(--c2); }
.card:nth-child(3n + 3) li::before { border-color: var(--c3); }

.card-links { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.card-links a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.79rem;
  font-weight: 500;
  color: var(--ink-soft);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 13px;
  transition: color 0.2s var(--ease), border-color 0.2s var(--ease), background 0.2s var(--ease);
}
.card-links a::before { content: "◎"; color: var(--c3); font-size: 0.85em; }
.card-links a:hover { color: var(--c3); border-color: var(--c3); background: var(--c3-wash); }

/* ---------------- about ---------------- */
.about-body p { margin: 0 0 18px; color: var(--ink-soft); font-size: 1.02rem; max-width: 66ch; }
.about-body p:first-child {
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.16rem, 2.6vw, 1.42rem);
  line-height: 1.5;
  letter-spacing: -0.01em;
}
.about-body p:last-child { margin-bottom: 0; }

/* ---------------- skills ---------------- */
.skill-group { margin-bottom: 26px; }
.skill-group:last-child { margin-bottom: 0; }
.skill-group h3 {
  margin: 0 0 12px;
  font-size: 0.73rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-faint);
}
.chips { display: flex; flex-wrap: wrap; gap: 9px; }
.chip {
  border-radius: 999px;
  padding: 7px 16px;
  font-size: 0.87rem;
  font-weight: 500;
  border: 1px solid transparent;
  transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
.chip:hover { transform: translateY(-2px); box-shadow: var(--shade); }
.skill-group.hue-1 .chip { background: var(--c1-wash); color: var(--c1-ink); border-color: color-mix(in srgb, var(--c1) 22%, transparent); }
.skill-group.hue-2 .chip { background: var(--c2-wash); color: var(--c2-ink); border-color: color-mix(in srgb, var(--c2) 22%, transparent); }
.skill-group.hue-3 .chip { background: var(--c3-wash); color: var(--c3-ink); border-color: color-mix(in srgb, var(--c3) 22%, transparent); }
:root[data-theme="dark"] .chip { filter: brightness(1.05); }

/* ---------------- languages ---------------- */
.lang-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px; }
.lang-item {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 15px 19px;
  box-shadow: var(--shade);
}
.lang-item strong { display: block; font-weight: 600; }
.lang-item span { color: var(--ink-faint); font-size: 0.85rem; }

/* ---------------- contact ---------------- */
.contact-lead { margin: 0 0 24px; color: var(--ink-soft); font-size: 1.04rem; max-width: 54ch; }
.contact-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(232px, 1fr)); gap: 13px; }
.contact-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 17px 21px;
  min-height: 74px;
  box-shadow: var(--shade);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), border-color 0.25s var(--ease);
}
.contact-item .label {
  color: var(--ink-faint);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.17em;
  text-transform: uppercase;
}
.contact-item .value { font-weight: 600; word-break: break-word; transition: color 0.25s var(--ease); }
.contact-item:hover { transform: translateY(-3px); box-shadow: var(--shade-lift); }
.contact-item:nth-child(3n + 1):hover { border-color: var(--c1); }
.contact-item:nth-child(3n + 1):hover .value { color: var(--c1); }
.contact-item:nth-child(3n + 2):hover { border-color: var(--c2); }
.contact-item:nth-child(3n + 2):hover .value { color: var(--c2); }
.contact-item:nth-child(3n + 3):hover { border-color: var(--c3); }
.contact-item:nth-child(3n + 3):hover .value { color: var(--c3); }

/* ---------------- footer ---------------- */
.site-footer {
  position: relative;
  border-top: 1px solid var(--line);
  padding: 32px 0 48px;
  color: var(--ink-faint);
  font-size: 0.82rem;
  text-align: center;
}
.site-footer::before {
  content: "";
  position: absolute;
  top: -1.5px;
  left: 50%;
  transform: translateX(-50%);
  width: min(220px, 50%);
  height: 3px;
  border-radius: 3px;
  background: var(--grad);
}

/* ---------------- reveal on scroll ---------------- */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.65s var(--ease), transform 0.65s var(--ease);
}
.reveal.is-in { opacity: 1; transform: none; }

/* =====================================================================
 * responsive
 * ===================================================================== */

@media (max-width: 900px) {
  .hero { padding: 56px 0 4px; }
  .hero-inner { gap: 32px; }
  .portrait { width: 148px; height: 148px; }
  section { padding: 52px 0; }
}

/* tablet / mobile: portrait on top, nav becomes a menu panel */
@media (max-width: 760px) {
  body { font-size: 16px; }
  .wrap { padding: 0 18px; }

  .site-header .wrap { height: 60px; }
  .brand { font-size: 1.02rem; }

  .nav-toggle { display: inline-flex; }

  .site-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin: 0;
    flex-direction: column;
    gap: 0;
    padding: 8px 18px 16px;
    background: color-mix(in srgb, var(--paper) 96%, transparent);
    backdrop-filter: saturate(170%) blur(16px);
    -webkit-backdrop-filter: saturate(170%) blur(16px);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shade);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity 0.25s var(--ease), transform 0.25s var(--ease), visibility 0.25s;
  }
  .site-header.is-open .site-nav { opacity: 1; visibility: visible; transform: none; }
  .site-nav a {
    padding: 13px 4px;
    font-size: 1rem;
    border-bottom: 1px solid var(--line);
  }
  .site-nav a:last-child { border-bottom: 0; }
  .site-nav a::after { display: none; }
  .site-nav a.is-active { color: var(--c1); }

  .hero { padding: 44px 0 0; }
  .hero-inner { grid-template-columns: 1fr; justify-items: center; text-align: center; gap: 26px; }
  .hero-text { display: flex; flex-direction: column; align-items: center; }
  .hero .summary, .hero .headline { max-width: 40ch; }
  .cta-row { justify-content: center; width: 100%; }
  .btn { flex: 1 1 auto; min-width: 150px; }

  .portrait { width: 136px; height: 136px; animation: none; }
  .portrait::after { inset: -10px; }

  .stats { grid-template-columns: repeat(2, 1fr); gap: 18px 12px; margin-top: 40px; padding: 20px 16px; }

  section { padding: 46px 0; }
  .sec-head { margin-bottom: 26px; }
  .sec-head h2 { gap: 12px; }

  .card { padding: 20px 20px; border-radius: 16px; }
  .card-head { gap: 8px; }
  .card .period { font-size: 0.74rem; padding: 2px 9px; }
  .card li { font-size: 0.93rem; }

  .about-body p { font-size: 0.99rem; }
  .contact-grid { grid-template-columns: 1fr; }

  .blob { filter: blur(70px); opacity: 0.26; }
}

@media (max-width: 420px) {
  .wrap { padding: 0 15px; }
  .brand-text { font-size: 0.95rem; }
  .btn-ghost { padding: 7px 12px; font-size: 0.75rem; }
  .hero h1 { font-size: clamp(2.1rem, 11vw, 2.7rem); }
  .stats { grid-template-columns: 1fr 1fr; }
  .stat .label { font-size: 0.72rem; }
  .card { padding: 18px 16px; }
  .cta-row { flex-direction: column; }
  .btn { width: 100%; }
}

/* devices that can't hover: no lift, no dashed spin */
@media (hover: none) {
  .card:hover, .contact-item:hover, .chip:hover, .btn:hover { transform: none; }
  .card::before { transform: scaleY(1); opacity: 0.6; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition-duration: 0.01ms !important; }
  .reveal { opacity: 1; transform: none; }
}

/* ---------------- print ---------------- */
@media print {
  .site-header, .site-footer, .cta-row, .skip-link, .card-links, .bg-fx { display: none !important; }
  body { background: #fff; color: #000; font-size: 10.5pt; }
  .hero { padding: 0 0 12px; }
  .hero h1 { color: #000; -webkit-text-fill-color: #000; }
  .card .org { color: #000; -webkit-text-fill-color: #000; }
  section { padding: 12px 0; break-inside: avoid; }
  .card { box-shadow: none; break-inside: avoid; border-color: #ccc; }
  .stats { box-shadow: none; border-color: #ccc; }
  a { color: #000; }
}
