/* ==========================================================================
   Instituto San Marcos — sistema de diseño
   Paleta tomada de la identidad real (isotipo de mosaico vino + dorado).
   Tipografía: Fraunces (display editorial) + IBM Plex Sans (texto/UI).
   ========================================================================== */

:root {
  /* color */
  --cream: #f7f2e7;
  --cream-deep: #efe4cd;
  --paper: #fffdf8;
  --ink: #2a2420;
  --ink-soft: #6b6055;
  --line: #e2d5b8;

  --burgundy: #7c332f;
  --burgundy-strong: #601f1f;
  --burgundy-deep: #341210;
  --burgundy-deeper: #240d0b;
  --gold: #ab9a5e;
  --gold-light: #d3c393;

  --on-dark: #f3e9d6;
  --on-dark-soft: #cdb999;

  /* type */
  --font-display: "Fraunces", "Iowan Old Style", "Palatino Linotype", serif;
  --font-body: "IBM Plex Sans", "Segoe UI", system-ui, sans-serif;

  /* layout */
  --container: 1240px;
  --gutter: clamp(1.25rem, 4vw, 3rem);
  --radius-s: 3px;
  --radius-m: 6px;
  --shadow-soft: 0 20px 45px -25px rgba(36, 13, 11, 0.35);
  --shadow-card: 0 1px 0 rgba(36, 13, 11, 0.06), 0 12px 24px -18px rgba(36, 13, 11, 0.25);

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---- reset --------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
}
body {
  margin: 0;
  overflow-x: clip;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4, p { margin: 0; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
input, textarea { font: inherit; }

:focus-visible {
  outline: 2px solid var(--burgundy);
  outline-offset: 3px;
}

.skip-link {
  position: fixed;
  top: .75rem;
  left: .75rem;
  z-index: 100;
  padding: .7rem 1rem;
  background: var(--paper);
  color: var(--burgundy);
  border: 1px solid var(--burgundy);
  border-radius: var(--radius-s);
  transform: translateY(-150%);
  transition: transform .2s;
}
.skip-link:focus { transform: translateY(0); }

.container {
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

section { position: relative; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--burgundy);
}
.eyebrow--onDark { color: var(--gold-light); }

/* mosaic mark — recurring signature motif, derived from the real isotype */
.mosaic {
  display: inline-grid;
  grid-template-columns: repeat(2, 1fr);
  grid-template-rows: repeat(2, 1fr);
  flex: none;
}
.mosaic span:nth-child(1) { background: var(--burgundy); }
.mosaic span:nth-child(2) { background: var(--gold); }
.mosaic span:nth-child(3) { background: var(--gold); }
.mosaic span:nth-child(4) { background: var(--burgundy); }
.mosaic--sm { width: 14px; height: 14px; gap: 2px; }
.mosaic--md { width: 22px; height: 22px; gap: 2px; }
.mosaic--lg { width: 40px; height: 40px; gap: 4px; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--ink);
}
h2 { font-size: clamp(1.9rem, 3.2vw, 2.7rem); line-height: 1.12; }
h3 { font-size: 1.3rem; line-height: 1.3; }
.section-head { max-width: 640px; margin-bottom: 2.75rem; }
.section-head p { margin-top: 1rem; color: var(--ink-soft); font-size: 1.05rem; }
.section-head--center { margin-inline: auto; text-align: center; }
.section-head--center .eyebrow { justify-content: center; }

.lede { font-size: 1.1rem; color: var(--ink-soft); max-width: 54ch; }

/* buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.85rem 1.5rem;
  border-radius: var(--radius-s);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
  transition: transform 0.25s var(--ease), background 0.25s var(--ease), color 0.25s var(--ease), border-color .25s var(--ease);
  white-space: nowrap;
}
.btn svg { width: 18px; height: 18px; }
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--burgundy); color: var(--on-dark); }
.btn-primary:hover { background: var(--burgundy-strong); }
.btn-ghost { background: transparent; color: var(--ink); border: 1.5px solid var(--line); }
.btn-ghost:hover { border-color: var(--burgundy); color: var(--burgundy); }
.btn-onDark { background: var(--gold); color: var(--burgundy-deeper); }
.btn-onDark:hover { background: var(--gold-light); }
.btn-line-onDark { background: transparent; color: var(--on-dark); border: 1.5px solid rgba(243, 233, 214, 0.35); }
.btn-line-onDark:hover { border-color: var(--gold-light); color: var(--gold-light); }

/* ---- topbar ---------------------------------------------------------- */
.topbar {
  background: var(--burgundy-deeper);
  color: var(--on-dark-soft);
  font-size: 0.82rem;
}
.topbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 0.5rem;
}
.topbar-contact { display: flex; gap: 1.5rem; flex-wrap: wrap; }
.topbar-contact a { display: inline-flex; align-items: center; gap: 0.4rem; transition: color .2s; }
.topbar-contact a:hover { color: var(--gold-light); }
.topbar-social { display: flex; gap: 0.9rem; }
.topbar-social a { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; border: 1px solid rgba(243,233,214,.25); transition: border-color .2s, color .2s; }
.topbar-social a:hover { border-color: var(--gold-light); color: var(--gold-light); }
.topbar svg { width: 14px; height: 14px; }

/* ---- header ------------------------------------------------------------ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--cream);
  border-bottom: 1px solid transparent;
  transition: border-color .3s, box-shadow .3s;
}
.site-header.is-scrolled { border-color: var(--line); box-shadow: 0 8px 24px -20px rgba(36,13,11,.4); }
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 0.9rem;
}

.brand { display: flex; align-items: center; gap: 0.65rem; }
.brand-word { display: flex; flex-direction: column; line-height: 1; }
.brand-word .top {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 400;
  font-size: 0.8rem;
  color: var(--ink-soft);
}
.brand-word .bottom {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.3rem;
  letter-spacing: 0.02em;
  color: var(--burgundy);
}
.brand--onDark .brand-word .top { color: var(--on-dark-soft); }
.brand--onDark .brand-word .bottom { color: var(--on-dark); }

.nav { display: flex; align-items: center; gap: 2.2rem; }
.nav-panel { display: flex; align-items: center; gap: 1.15rem; }
.nav-links { display: flex; gap: clamp(.65rem, 1vw, 1.15rem); }
.nav-links a {
  font-size: clamp(.76rem, .78vw, .88rem);
  font-weight: 500;
  color: var(--ink-soft);
  position: relative;
  padding-block: 0.25rem;
  white-space: nowrap;
  transition: color .2s;
}
.nav-links a:hover { color: var(--burgundy); }
.nav-links a[aria-current="page"] { color: var(--burgundy); font-weight: 600; }
.nav-links a::after {
  content: "";
  position: absolute; left: 0; right: 100%; bottom: -2px;
  height: 2px; background: var(--burgundy);
  transition: right .25s var(--ease);
}
.nav-links a:hover::after { right: 0; }
.nav-links a[aria-current="page"]::after { right: 0; }

.nav-actions { display: flex; align-items: center; gap: .8rem; }
.nav-actions .btn { padding: .72rem 1rem; font-size: .84rem; }
.nav-ateneo {
  color: var(--burgundy);
  font-size: .82rem;
  font-weight: 600;
  white-space: nowrap;
  transition: color .2s;
}
.nav-ateneo:hover { color: var(--burgundy-strong); }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
}
.nav-toggle span { width: 22px; height: 2px; background: var(--ink); transition: transform .25s, opacity .25s; }

/* ---- hero --------------------------------------------------------------- */
.hero {
  overflow: hidden;
  padding-block: clamp(3rem, 8vw, 6rem) clamp(3.5rem, 8vw, 6.5rem);
  background:
    radial-gradient(880px 480px at 88% -10%, rgba(171, 154, 94, 0.16), transparent 60%);
}
.hero .container {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
}
.hero-eyebrow { margin-bottom: 1.4rem; }
.hero h1 {
  font-size: clamp(2.5rem, 5vw, 3.85rem);
  line-height: 1.05;
}
.hero h1 em {
  font-style: italic;
  color: var(--burgundy);
}
.hero-lede {
  margin-top: 1.5rem;
  font-size: 1.15rem;
  color: var(--ink-soft);
  max-width: 46ch;
}
.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; margin-top: 2.2rem; }
.hero-trust {
  display: flex;
  gap: 1.8rem;
  flex-wrap: wrap;
  margin-top: 2.6rem;
  padding-top: 1.8rem;
  border-top: 1px solid var(--line);
}
.hero-trust li {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 0.88rem;
  color: var(--ink-soft);
  font-weight: 500;
}
.hero-trust svg { width: 17px; height: 17px; color: var(--burgundy); flex: none; }

.hero-visual { position: relative; }
.hero-frame {
  position: relative;
  aspect-ratio: 4 / 5;
  border-radius: var(--radius-m);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
}
.hero-frame img { width: 100%; height: 100%; object-fit: cover; }
.hero-frame::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(36,13,11,0) 55%, rgba(36,13,11,.55) 100%);
}
.hero-frame-caption {
  position: absolute;
  /*left: 1.4rem;*/
  right: 1.4rem; bottom: 1.3rem; z-index: 2;
  color: var(--on-dark);
  font-size: 0.85rem;
  display: flex; align-items: baseline; gap: 0.5rem;
}
.hero-frame-caption strong { font-family: var(--font-display); font-size: 1.05rem; }
.hero-swatch {
  position: absolute;
  width: 128px; height: 128px;
  bottom: -30px; left: -30px;
  background: var(--paper);
  border-radius: var(--radius-m);
  box-shadow: var(--shadow-card);
  display: grid; place-items: center;
  z-index: 3;
}

/* ---- stats strip ---------------------------------------------------- */
.stats {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--cream-deep);
}
.stats .container {
  display: flex;
  justify-content: space-around;
  align-items: center;
  gap: 1.5rem;
  padding-block: 2.1rem;
}
.stat { flex: 1; text-align: center; }
.stat strong {
  display: block;
  font-family: var(--font-display);
  font-size: 2rem;
  color: var(--burgundy);
  line-height: 1;
}
.stat span { display: block; margin-top: 0.5rem; font-size: 0.85rem; color: var(--ink-soft); }

/* ---- generic section spacing ---------------------------------------- */
.section { padding-block: clamp(4rem, 9vw, 6.5rem); }
.section--tight { padding-block: clamp(3rem, 6vw, 4.5rem); }
.section-alt { background: var(--cream-deep); }

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2.5rem, 6vw, 5rem);
  align-items: center;
}
.split.reverse .split-media { order: 2; }

.split-media img {
  width: 100%;
  border-radius: var(--radius-m);
  box-shadow: var(--shadow-card);
}

.body-copy > * + * { margin-top: 1.15rem; }
.body-copy p { color: var(--ink-soft); font-size: 1.03rem; }

.tag-row { display: flex; gap: .6rem; flex-wrap: wrap; margin-top: 1.6rem; }
.tag {
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .03em;
  color: var(--burgundy);
  background: rgba(124, 51, 47, .08);
  border: 1px solid rgba(124, 51, 47, .18);
  padding: .4rem .8rem;
  border-radius: 999px;
}

/* ---- services grid ---------------------------------------------------- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.4rem;
}
.service-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-m);
  padding: 2rem 1.6rem;
  transition: transform .3s var(--ease), box-shadow .3s var(--ease), border-color .3s;
}
.service-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-card); border-color: transparent; }
.service-icon {
  display: grid; place-items: center;
  width: 52px; height: 52px;
  border-radius: var(--radius-s);
  background: var(--burgundy);
  color: var(--on-dark);
  margin-bottom: 1.3rem;
}
.service-icon svg { width: 26px; height: 26px; }
.service-card h3 { margin-bottom: .6rem; }
.service-card p { color: var(--ink-soft); font-size: .95rem; }
.service-card a.card-link {
  display: inline-flex; align-items: center; gap: .4rem;
  margin-top: 1rem; font-size: .85rem; font-weight: 600; color: var(--burgundy);
}
.service-card a.card-link svg { width: 14px; height: 14px; transition: transform .2s; }
.service-card a.card-link:hover svg { transform: translateX(3px); }

/* ---- paxman feature ---------------------------------------------------- */
.paxman-benefits { margin-top: 1.6rem; display: flex; flex-direction: column; gap: .85rem; }
.paxman-benefits li { display: flex; gap: .75rem; align-items: flex-start; font-size: .98rem; color: var(--ink-soft); }
.paxman-benefits svg { width: 19px; height: 19px; color: var(--burgundy); flex: none; margin-top: 2px; }

/* ---- statement band ---------------------------------------------------- */
.statement {
  background: var(--burgundy-deep);
  background-image: radial-gradient(700px 400px at 12% 20%, rgba(171,154,94,.14), transparent 60%);
  color: var(--on-dark);
  text-align: center;
  padding-block: clamp(4.5rem, 9vw, 7rem);
}
.statement .mosaic { margin-inline: auto; margin-bottom: 1.8rem; }
.statement blockquote {
  margin: 0 auto;
  max-width: 780px;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(1.5rem, 3.4vw, 2.35rem);
  line-height: 1.35;
}
.statement cite {
  display: block;
  margin-top: 1.6rem;
  font-style: normal;
  font-size: .82rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--gold-light);
}

/* ---- research / careers duo -------------------------------------------- */
.duo {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.4rem;
}
.duo-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-m);
  padding: 2.6rem;
}
.duo-card .mosaic { margin-bottom: 1.3rem; }
.duo-card h3 { font-size: 1.55rem; margin-bottom: .9rem; }
.duo-card p { color: var(--ink-soft); margin-bottom: 1.6rem; }

/* ---- staff directory --------------------------------------------------- */
.staff-hero {
  padding-block: clamp(4.5rem, 10vw, 8rem);
  overflow: hidden;
  background: var(--cream);
  border-bottom: 1px solid var(--line);
}
.staff-hero .container { max-width: 980px; margin-left: max(0px, calc((100vw - var(--container)) / 2)); }
.staff-hero h1 { margin-top: 1.4rem; font-size: clamp(2.8rem, 6vw, 5rem); line-height: 1.02; }
.staff-hero h1 em { color: var(--burgundy); font-weight: 400; }
.staff-hero p { max-width: 62ch; margin-top: 1.5rem; color: var(--ink-soft); font-size: 1.15rem; }

.staff-directory { border-bottom: 1px solid var(--line); }
.specialty-head {
  display: grid;
  grid-template-columns: minmax(280px, .9fr) 1.1fr;
  gap: 3rem;
  align-items: end;
  padding-bottom: 1.8rem;
  margin-bottom: 2rem;
  border-bottom: 1px solid var(--line);
}
.specialty-head > div { display: flex; align-items: baseline; gap: 1rem; }
.specialty-number { font-size: .72rem; font-weight: 700; letter-spacing: .12em; color: var(--gold); }
.specialty-head p { max-width: 48ch; color: var(--ink-soft); }
.staff-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 1.25rem; }
.staff-card {
  overflow: hidden;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-m);
  box-shadow: var(--shadow-card);
  transition: transform .3s var(--ease), box-shadow .3s var(--ease);
}
.staff-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-soft); }
.staff-card img { width: 100%; height: 230px; object-fit: cover; object-position: center top; filter: saturate(.92); }
.staff-card > div { padding: 1.2rem 1.1rem 1.3rem; }
.staff-card h3, .staff-card h4 { font-size: 1.12rem; line-height: 1.2; }
.staff-card p { margin-top: .4rem; color: var(--burgundy); font-size: .75rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; }
.staff-subgroup { display: flex; align-items: center; gap: 1rem; margin: 2.4rem 0 1rem; }
.staff-subgroup::after { content: ""; height: 1px; flex: 1; background: var(--line); }
.staff-subgroup h3 { color: var(--burgundy); font-size: 1rem; font-family: var(--font-body); letter-spacing: .08em; text-transform: uppercase; }
.staff-grid--subgroup { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: calc(40% - .5rem); }
.staff-pair-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 5rem); }
.specialty-head--stacked { display: block; min-height: 150px; }
.specialty-head--stacked p { margin-top: 1rem; }
.staff-pair .staff-card { max-width: 240px; }

.staff-cta { background: var(--burgundy-deep); color: var(--on-dark); padding-block: clamp(3rem, 6vw, 4.5rem); }
.staff-cta .container { display: grid; grid-template-columns: auto 1fr auto; gap: 1.5rem; align-items: center; }
.staff-cta p { color: var(--gold-light); font-size: .75rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; }
.staff-cta h2 { margin-top: .35rem; color: var(--on-dark); font-size: clamp(1.6rem, 3vw, 2.3rem); }

/* ---- contact ------------------------------------------------------------ */
.contact {
  background: var(--burgundy-deep);
  color: var(--on-dark);
}
.contact .split { align-items: start; }
.contact-info-list { margin-top: 2rem; display: flex; flex-direction: column; gap: 1.5rem; }
.contact-info-list li { display: flex; gap: 1rem; }
.contact-info-list .ic {
  width: 42px; height: 42px; flex: none;
  display: grid; place-items: center;
  border-radius: var(--radius-s);
  background: rgba(171, 154, 94, .16);
  color: var(--gold-light);
}
.contact-info-list .ic svg { width: 20px; height: 20px; }
.contact-info-list strong { display: block; font-size: .95rem; margin-bottom: .2rem; }
.contact-info-list span, .contact-info-list a { color: var(--on-dark-soft); font-size: .92rem; }
.contact-info-list a:hover { color: var(--gold-light); }

.map-frame {
  margin-top: 2rem;
  border-radius: var(--radius-m);
  overflow: hidden;
  border: 1px solid rgba(243,233,214,.15);
  filter: sepia(12%) saturate(85%);
}
.map-frame iframe { width: 100%; height: 240px; border: 0; display: block; }

.contact-form {
  background: var(--paper);
  border-radius: var(--radius-m);
  padding: clamp(1.8rem, 3vw, 2.6rem);
  box-shadow: var(--shadow-soft);
  color: var(--ink);
}
.contact-form h3 { margin-bottom: .4rem; }
.contact-form .lede { color: var(--ink-soft); font-size: .95rem; margin-bottom: 1.6rem; }
.field { margin-bottom: 1.2rem; display: flex; flex-direction: column; gap: .45rem; }
.field label { font-size: .82rem; font-weight: 600; color: var(--ink-soft); }
.field input, .field textarea {
  border: 1.5px solid var(--line);
  border-radius: var(--radius-s);
  padding: .75rem .9rem;
  background: var(--cream);
  color: var(--ink);
  transition: border-color .2s;
}
.field input:focus, .field textarea:focus { border-color: var(--burgundy); outline: none; }
.field textarea { resize: vertical; min-height: 110px; }
.contact-form .btn { width: 100%; justify-content: center; margin-top: .4rem; }

/* ---- footer -------------------------------------------------------------- */
.site-footer { background: var(--burgundy-deeper); color: var(--on-dark-soft); }
.footer-top {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  gap: 3rem;
  padding-block: 3.5rem;
  border-bottom: 1px solid rgba(243,233,214,.1);
}
.footer-about p { margin-top: 1.1rem; font-size: .92rem; max-width: 34ch; color: var(--on-dark-soft); }
.footer-social { display: flex; gap: .8rem; margin-top: 1.4rem; }
.footer-social a { width: 34px; height: 34px; display: grid; place-items: center; border: 1px solid rgba(243,233,214,.2); border-radius: 50%; transition: border-color .2s, color .2s; }
.footer-social a:hover { border-color: var(--gold-light); color: var(--gold-light); }
.footer-social svg { width: 15px; height: 15px; }
.footer-heading { font-size: .78rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--on-dark); margin-bottom: 1.2rem; }
.footer-links { display: flex; flex-direction: column; gap: .75rem; }
.footer-links a { font-size: .92rem; transition: color .2s; }
.footer-links a:hover { color: var(--gold-light); }
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 1rem;
  padding-block: 1.4rem;
  font-size: .82rem;
}

/* ---- reveal on scroll ---------------------------------------------------- */
[data-reveal] { opacity: 0; transform: translateY(18px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
[data-reveal].is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  [data-reveal] { opacity: 1; transform: none; }
}

/* ---- responsive ----------------------------------------------------------- */
@media (max-width: 1180px) {
  .nav-toggle { display: flex; }
  .nav-panel {
    position: fixed;
    inset: 0 0 0 28%;
    top: var(--header-h, 0);
    z-index: 50;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 1.4rem;
    overflow-y: auto;
    background: var(--paper);
    padding: 1.5rem var(--gutter) 2.5rem;
    border-left: 1px solid var(--line);
    box-shadow: -20px 0 40px -30px rgba(36,13,11,.5);
    transform: translateX(100%);
    transition: transform .35s var(--ease);
  }
  .nav-panel.is-open { transform: translateX(0); }
  .nav-links { flex-direction: column; gap: 0; }
  .nav-links a { display: block; width: max-content; max-width: 100%; padding-block: .8rem; border-bottom: 1px solid var(--line); font-size: .95rem; }
  .nav-links a::after { display: none; }
  .nav-actions { flex-direction: column-reverse; align-items: stretch; }
  .nav-actions .btn { justify-content: center; }
  .nav-ateneo { padding: .72rem 1rem; text-align: center; border: 1px solid var(--line); border-radius: var(--radius-s); }
  .nav-toggle.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-toggle.is-open span:nth-child(2) { opacity: 0; }
  .nav-toggle.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
}

@media (max-width: 1080px) {
  .card-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-top { grid-template-columns: 1fr 1fr; }
  .footer-about { grid-column: 1 / -1; }
  .staff-grid { grid-template-columns: repeat(3, 1fr); }
  .staff-grid--subgroup { max-width: 66%; grid-template-columns: repeat(2, 1fr); }
  .staff-card img { height: 300px; }
}

@media (max-width: 900px) {
  .topbar-contact span.sep { display: none; }
  .hero .container, .split, .duo, .contact .split { grid-template-columns: 1fr; }
  .split-media, .split.reverse .split-media { order: -1; }
  .hero-visual { max-width: 420px; margin-inline: auto; }
  .hero-swatch { display: none; }
  .specialty-head { grid-template-columns: 1fr; gap: 1rem; align-items: start; }
  .staff-pair-grid { grid-template-columns: 1fr; }
  .specialty-head--stacked { min-height: 0; }
  .staff-cta .container { grid-template-columns: auto 1fr; }
  .staff-cta .btn { grid-column: 2; justify-self: start; }
}

@media (max-width: 640px) {
  .card-grid { grid-template-columns: 1fr; }
  .stats .container { flex-direction: column; gap: 2rem; }
  .stat { width: 100%; }
  .topbar .container { flex-direction: column; align-items: flex-start; gap: .4rem; }
  .hero-actions { flex-direction: column; align-items: stretch; }
  .hero-actions .btn { justify-content: center; }
  .footer-top { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
  .nav-panel { left: 12%; }
  .staff-grid, .staff-grid--subgroup { grid-template-columns: repeat(2, 1fr); max-width: none; }
  .staff-card > div { padding: 1rem .85rem 1.1rem; }
  .staff-card h3, .staff-card h4 { font-size: 1rem; }
  .staff-card img { height: 190px; }
  .staff-pair .staff-card { max-width: none; }
  .staff-cta .container { grid-template-columns: 1fr; }
  .staff-cta .btn { grid-column: auto; justify-self: stretch; justify-content: center; }
}

@media (max-width: 420px) {
  .staff-grid, .staff-grid--subgroup { grid-template-columns: 1fr; }
  .staff-card img { height: 360px; }
}
