/*
 * Design system matched to the IIT Indore website (www.iiti.ac.in):
 * Outfit typeface, navy / copper / cream palette, pill navigation,
 * rounded cream cards with soft warm shadows.
 */

@font-face {
  font-family: "Outfit";
  src: url("../assets/fonts/outfit-latin.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Outfit";
  src: url("../assets/fonts/outfit-latin-ext.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Hind";
  src: url("../assets/fonts/hind-400-devanagari.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
  unicode-range: U+0900-097F, U+1CD0-1CF4, U+1CF7-1CF9, U+200C-200D, U+20A8, U+20B9, U+25CC, U+A830-A839, U+A8E0-A8FF;
}
@font-face {
  font-family: "Hind";
  src: url("../assets/fonts/hind-600-devanagari.woff2") format("woff2");
  font-weight: 600;
  font-display: swap;
  unicode-range: U+0900-097F, U+1CD0-1CF4, U+1CF7-1CF9, U+200C-200D, U+20A8, U+20B9, U+25CC, U+A830-A839, U+A8E0-A8FF;
}

:root {
  /* from iiti.ac.in :root */
  --primary-dark: #000d1b;
  --accent-copper: #bf7771;
  --bg-light: #fffdfa;
  --chip-blue: #d1e5f9;
  /* observed on iiti.ac.in */
  --copper-dark: #995f5a;
  --cream: #fff5e8;
  --cream-card: #fffbf6;
  --rose: #d9adaa;
  --footer: #05192d;
  --topbar: #000305;
  --grey-card: #f6f7f8;
  --pill-light: #e3e6e9;
  --text: #212529;
  --text-dark: #2a2b2c;
  --muted: #5d636b;
  --line: #d1d5db;
  --shadow: 1px 2px 4px rgb(204, 196, 186);
  --shadow-lg: 0 8px 24px rgba(153, 95, 90, 0.18);
  --font: "Outfit", "Hind", system-ui, sans-serif;
  --pad-x: clamp(20px, 6.95vw, 120px);
  --pad-y: clamp(48px, 5.6vw, 96px);
  --maxw: 1320px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  color: var(--text);
  background: var(--bg-light);
  overflow-x: hidden;
}
body.menu-open {
  overflow: hidden;
}
img {
  max-width: 100%;
}
a {
  color: inherit;
}
h1,
h2,
h3,
h4 {
  color: var(--primary-dark);
  margin: 0;
}
[lang="hi"] {
  font-family: "Hind", var(--font);
}
.icon,
.icon-sm {
  display: inline-flex;
  width: 18px;
  height: 18px;
}
.icon-sm {
  width: 14px;
  height: 14px;
  vertical-align: -2px;
}
.icon svg,
.icon-sm svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}
.icon svg[fill="none"],
.icon-sm svg[fill="none"] {
  fill: none;
}
.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  z-index: 200;
  background: var(--accent-copper);
  color: #fff;
  padding: 8px 12px;
}
.skip-link:focus {
  left: 8px;
}

/* ---------- top bar ---------- */
.topbar {
  background: var(--topbar);
  color: #d1d5db;
  font-size: 14px;
  height: 40px;
  padding: 0 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  position: relative;
  z-index: 60;
}
.topbar-left {
  display: flex;
  align-items: center;
  gap: 10px;
  white-space: nowrap;
  overflow: hidden;
}
.topbar a {
  color: #d1d5db;
  text-decoration: none;
}
.topbar a:hover {
  color: #fff;
}
.social {
  display: inline-flex;
  gap: 12px;
}
.social .icon {
  width: 17px;
  height: 17px;
}
.sep {
  color: #6c757d;
}
.lang {
  display: flex;
  align-items: center;
  gap: 10px;
}
.lang-btn {
  background: none;
  border: 0;
  color: #d1d5db;
  font: 600 15px var(--font);
  cursor: pointer;
  padding: 0;
}
.lang-btn.active {
  color: var(--accent-copper);
}
.lang-sep {
  width: 1px;
  height: 22px;
  background: #6c757d;
}

/* ---------- header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 14px 32px;
  background: var(--cream);
  box-shadow: 0 2px 8px rgba(204, 196, 186, 0.45);
  transition: background 0.3s, box-shadow 0.3s;
}
.brand {
  display: flex;
  align-items: center;
  gap: 18px;
  text-decoration: none;
  min-width: 0;
}
.brand-logo {
  flex: none;
  width: 60px;
  height: auto;
}
.brand-divider {
  flex: none;
  width: 1px;
  height: 58px;
  background: var(--accent-copper);
}
.brand-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.brand-name {
  font-size: 21px;
  font-weight: 400;
  line-height: 1.25;
  color: var(--primary-dark);
}
.brand-inst {
  font-size: 15px;
  color: var(--text-dark);
  margin-top: 2px;
}

.pill-nav {
  flex: none;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 32px;
  background: var(--pill-light);
}
.pill-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 2px;
}
.pill-links a {
  display: block;
  padding: 7px 14px;
  border-radius: 20px;
  font-size: 13.5px;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  text-decoration: none;
  color: #3a3f45;
  transition: background 0.2s, color 0.2s;
}
.pill-links a:hover,
.pill-links a.active {
  background: #fff;
  color: var(--primary-dark);
}
.pill-sep {
  width: 1px;
  height: 26px;
  margin: 0 10px 0 14px;
  background: #9aa1a9;
}
.menu-btn {
  width: 40px;
  height: 36px;
  border: 0;
  border-radius: 20px;
  background: none;
  color: #3a3f45;
  cursor: pointer;
  display: grid;
  place-items: center;
}
.menu-btn .icon-menu,
.menu-btn .icon-close {
  width: 22px;
  height: 22px;
  display: inline-flex;
}
.menu-btn svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}
.menu-btn .icon-close,
.menu-btn[aria-expanded="true"] .icon-menu {
  display: none;
}
.menu-btn[aria-expanded="true"] .icon-close {
  display: inline-flex;
}

/* ---------- mega menu ---------- */
.mega {
  position: fixed;
  z-index: 45;
  top: 128px;
  left: 0;
  right: 0;
  max-height: calc(100vh - 128px);
  overflow: auto;
  display: grid;
  grid-template-columns: 1fr 320px;
  border-radius: 0 0 24px 24px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}
.mega[hidden] {
  display: none;
}
.mega-main {
  background: var(--footer);
  padding: 48px 6vw 56px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 32px 48px;
}
.mega-heading {
  font-size: 23px;
  font-weight: 600;
  margin-bottom: 18px;
}
.mega-heading a {
  color: var(--accent-copper);
  text-decoration: none;
}
.mega-col ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.mega-col li a {
  display: block;
  padding: 12px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.35);
  color: #fff;
  text-decoration: none;
  font-size: 15.5px;
}
.mega-col li a:hover {
  color: var(--accent-copper);
}
.mega-side {
  background: var(--cream);
  padding: 48px 24px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 14px;
  border-radius: 0 0 24px 0;
}
.mega-pill {
  display: block;
  text-align: center;
  padding: 11px 16px;
  border-radius: 28px;
  background: #fff;
  color: var(--copper-dark);
  font-size: 18px;
  font-weight: 600;
  text-decoration: none;
  box-shadow: var(--shadow);
}
.mega-pill.primary,
.mega-pill:hover {
  background: var(--primary-dark);
  color: #fff;
}

/* ---------- shared bits ---------- */
.section {
  padding: var(--pad-y) var(--pad-x);
}
.section > .wrap,
.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
}
.bg-light {
  background: var(--bg-light);
}
.bg-cream {
  background: var(--cream);
}
.bg-rose {
  background: var(--rose);
}
.dotted {
  background-color: var(--cream);
  background-image: radial-gradient(rgba(191, 119, 113, 0.28) 1.6px, transparent 1.6px);
  background-size: 28px 28px;
}
.sec-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 40px;
  flex-wrap: wrap;
}
.sec-title {
  font-size: clamp(34px, 3.1vw, 53px);
  font-weight: 300;
  line-height: 1.25;
}
.sec-title-sm {
  font-size: clamp(30px, 2.4vw, 40px);
  font-weight: 300;
  line-height: 1.25;
}
.pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 10px 30px;
  border: 1px solid #6c757d;
  border-radius: 32px;
  font-size: 17px;
  color: var(--primary-dark);
  text-decoration: none;
  background: transparent;
  white-space: nowrap;
  transition: background 0.2s, color 0.2s;
}
.pill-btn:hover {
  background: var(--primary-dark);
  color: #fff;
}
.pill-arrow {
  display: inline-flex;
  width: 44px;
  height: 12px;
}
.pill-arrow svg {
  width: 100%;
  height: 100%;
}
.know-more {
  display: inline-block;
  font-weight: 600;
  font-size: 15px;
  color: var(--primary-dark);
  text-decoration: none;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  font-family: inherit;
}
.know-more::after {
  content: " →";
  color: var(--accent-copper);
  transition: margin 0.2s;
}
.know-more:hover::after {
  margin-left: 4px;
}
.card {
  background: var(--cream-card);
  border-radius: 16px;
  box-shadow: var(--shadow);
  overflow: hidden;
}
.card-body {
  padding: 22px 24px;
}
.card h3 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 8px;
}
.card p {
  margin: 0 0 12px;
  color: var(--muted);
}
.eyebrow {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent-copper);
}
.empty {
  color: var(--muted);
  font-style: italic;
}
.muted-small {
  margin: 6px 0 0;
  font-size: 14px;
  color: var(--muted);
}

/* ---------- home: announcement marquee ---------- */
.announce {
  padding: 80px var(--pad-x);
  background: var(--bg-light);
}
.announce-bar {
  max-width: 1225px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 6px;
  border-radius: 32px;
  background: var(--pill-light);
}
.announce-icon {
  flex: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #fff;
  display: grid;
  place-items: center;
  color: var(--primary-dark);
}
.announce-icon .icon {
  width: 24px;
  height: 24px;
}
.marquee {
  flex: 1;
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent);
}
.marquee-track {
  display: inline-flex;
  gap: 70px;
  white-space: nowrap;
  animation: marquee 45s linear infinite;
  padding-left: 20px;
}
.marquee:hover .marquee-track {
  animation-play-state: paused;
}
.marquee-track a {
  font-size: 16.5px;
  font-weight: 500;
  color: var(--text-dark);
  text-decoration: none;
}
.marquee-track a:hover {
  color: var(--copper-dark);
}
@keyframes marquee {
  to {
    transform: translateX(-50%);
  }
}
.announce-more {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 20px;
  border-radius: 24px;
  background: #fff;
  font-weight: 600;
  font-size: 14.5px;
  text-decoration: none;
  color: var(--primary-dark);
}
.announce-more .icon {
  width: 20px;
}

/* ---------- divisions-style cards (themes) ---------- */
.division-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
}
.division-card {
  background: #fff;
  border-radius: 20px;
  padding: 30px 29px;
  box-shadow: 0 4px 14px rgba(204, 196, 186, 0.6);
  display: flex;
  flex-direction: column;
}
.division-card h3 {
  font-size: 25px;
  font-weight: 500;
  color: var(--accent-copper);
  margin-bottom: 14px;
  line-height: 1.2;
}
.division-card p {
  margin: 0 0 20px;
  font-size: 15px;
}
.division-card .know-more {
  margin-top: auto;
}
.people-list {
  margin: 0 0 18px;
  padding-left: 18px;
  font-size: 15px;
}
.people-list a {
  text-decoration: none;
}
.people-list a:hover {
  color: var(--copper-dark);
}

.r-list {
  display: flex;
  flex-direction: column;
}
.r-item {
  display: grid;
  grid-template-columns: 210px 1fr;
  gap: 20px;
  padding: 16px 0;
  border-bottom: 1px solid var(--accent-copper);
}
.r-item:first-child {
  padding-top: 0;
}
.r-item h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 8px;
}
.r-item p {
  margin: 0 0 10px;
  font-size: 15px;
}
.r-item .thumb img {
  aspect-ratio: 4 / 3;
  object-fit: cover;
  background: #fff;
}

.news-date {
  font-size: 14px;
  font-weight: 300;
  color: var(--topbar);
  margin-bottom: 18px;
}

/* ---------- events (timeline cards) ---------- */

.event {
  display: grid;
  grid-template-columns: 62px 1fr;
  gap: 14px;
}
.timeline {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 2px 0;
}
.tl-date {
  text-align: center;
  line-height: 1.15;
}
.tl-day {
  display: block;
  font-size: 21px;
  color: var(--text-dark);
}
.tl-mon {
  display: block;
  font-size: 14px;
  color: var(--text-dark);
}
.tl-line {
  flex: 1;
  width: 2px;
  min-height: 60px;
  margin: 10px 0;
  background: var(--accent-copper);
  position: relative;
}
.tl-line::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -4px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-copper);
  transform: translateX(-50%);
}
.event-card {
  background: var(--cream);
  border-radius: 16px;
  padding: 22px 18px;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  min-height: 210px;
}
.event-card h3 {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 14px;
  line-height: 1.25;
}
.event-card p {
  margin: 0 0 18px;
  color: var(--text-dark);
}
.event-card .know-more {
  margin-top: auto;
}
.events-list {
  display: grid;
  gap: 28px;
}

/* ---------- openings ---------- */
.openings {
  display: grid;
  gap: 16px;
}
.opening {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 22px 28px;
  background: var(--cream-card);
  border-radius: 16px;
  box-shadow: var(--shadow);
  border-left: 5px solid var(--accent-copper);
}
.opening h3 {
  font-size: 18px;
  font-weight: 500;
}
.deadline {
  margin: 6px 0 0;
  font-size: 14px;
  font-weight: 600;
  color: var(--copper-dark);
}
.opening .know-more {
  flex: none;
}

/* ---------- head message ---------- */
.head-msg {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 56px;
  align-items: center;
}
.head-photo {
  border-radius: 24px;
  overflow: hidden;
  aspect-ratio: 1;
  box-shadow: 0 12px 30px rgba(0, 13, 27, 0.2);
}
.head-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.head-name {
  font-size: 26px;
  font-weight: 400;
  margin-top: 6px;
}
.head-role {
  color: var(--accent-copper);
  font-weight: 500;
}

/* ---------- home (layout after apm.iitm.ac.in, IITI tokens) ---------- */
.pill-btn.filled {
  background: var(--primary-dark);
  border-color: var(--primary-dark);
  color: #fff;
}
.pill-btn.filled:hover {
  background: var(--copper-dark);
  border-color: var(--copper-dark);
}
.pill-btn.filled.copper {
  background: var(--accent-copper);
  border-color: var(--accent-copper);
}
.pill-btn.filled.copper:hover {
  background: var(--copper-dark);
  border-color: var(--copper-dark);
}
.sec-head.ruled {
  padding-bottom: 32px;
  margin-bottom: 40px;
  border-bottom: 1px solid var(--line);
}
.sec-head .eyebrow {
  display: block;
  margin: 0 0 8px;
}
.sec-desc {
  max-width: 460px;
  margin: 0;
  font-size: 17px;
  line-height: 1.6;
  color: var(--muted);
  text-align: right;
}
.center-btn {
  display: flex;
  justify-content: center;
  margin-top: 44px;
}

/* split hero */
.home-hero {
  /* Fill exactly the first screen below the top bar + header (--chrome-h is set by main.js),
     so the next section starts on scroll instead of peeking in at the bottom. */
  min-height: calc(100vh - var(--chrome-h, 134px));
  display: flex;
  align-items: center;
  padding: clamp(28px, 3.5vw, 56px) var(--pad-x);
  background:
    radial-gradient(circle at 85% 20%, rgba(191, 119, 113, 0.14), transparent 45%),
    linear-gradient(180deg, var(--bg-light), var(--cream));
  overflow: hidden;
}
.hh-grid {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: clamp(32px, 5vw, 80px);
  align-items: center;
}
.hh-text .eyebrow {
  font-size: clamp(16px, min(1.5vw, 2.6vh), 24px);
  letter-spacing: 0.14em;
}
.hh-title {
  font-size: clamp(34px, min(3.6vw, 6.4vh), 64px);
  font-weight: 300;
  line-height: 1.08;
  letter-spacing: -0.01em;
  margin: 8px 0 18px;
}
.hh-title span {
  display: block;
}
.hh-title .accent {
  color: var(--accent-copper);
  font-weight: 400;
}
.hh-lead {
  font-size: 17px;
  line-height: 1.65;
  color: #4a4f55;
  max-width: 640px;
  margin: 0 0 24px;
}
.hh-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}
.hh-stats {
  display: grid;
  grid-template-columns: repeat(4, auto);
  justify-content: start;
  gap: 10px 40px;
  margin-top: 28px;
  padding-top: 18px;
  border-top: 1px solid rgba(191, 119, 113, 0.4);
}
.hh-stats strong {
  display: block;
  font-size: 32px;
  font-weight: 300;
  color: var(--copper-dark);
  line-height: 1.1;
}
.hh-stats div > span {
  font-size: 15px;
  color: var(--text-dark);
}
.hero-photos {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  height: clamp(380px, min(38vw, calc(100vh - var(--chrome-h, 134px) - 110px)), 720px);
  overflow: hidden;
  mask-image: linear-gradient(180deg, transparent, #000 12%, #000 88%, transparent);
  -webkit-mask-image: linear-gradient(180deg, transparent, #000 12%, #000 88%, transparent);
}
.hp-col {
  overflow: hidden;
}
.hp-track {
  display: flex;
  flex-direction: column;
  gap: 16px;
  animation: drift-up 48s linear infinite;
}
.hp-col.down .hp-track {
  animation-name: drift-down;
}
.hero-photos:hover .hp-track {
  animation-play-state: paused;
}
.hp-photo {
  display: block;
  padding: 0;
  border: 0;
  border-radius: 16px;
  overflow: hidden;
  cursor: zoom-in;
  box-shadow: 0 6px 18px rgba(0, 13, 27, 0.18);
  background: var(--grey-card);
}
.hp-photo img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
}
@keyframes drift-up {
  from { transform: translateY(0); }
  to { transform: translateY(calc(-50% - 8px)); }
}
@keyframes drift-down {
  from { transform: translateY(calc(-50% - 8px)); }
  to { transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
  .hp-track,
  .marquee-track {
    animation: none;
  }
}

/* featured flyer carousel */
.featured {
  padding: clamp(36px, 4vw, 64px) var(--pad-x);
  background: var(--primary-dark);
  color: #fff;
}
.featured[hidden] {
  display: none;
}
.featured-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr);
  gap: clamp(28px, 4vw, 64px);
  align-items: center;
}
.flyer-stage {
  position: relative;
  height: clamp(380px, 38vw, 560px);
  border-radius: 20px;
  overflow: hidden;
  background:
    radial-gradient(circle at 30% 20%, rgba(191, 119, 113, 0.25), transparent 60%),
    #0b2036;
}
.flyer {
  position: absolute;
  inset: 0;
  padding: 18px;
  border: 0;
  background: none;
  cursor: zoom-in;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.6s ease, visibility 0.6s;
}
.flyer.on {
  opacity: 1;
  visibility: visible;
}
.flyer img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain; /* the whole flyer is always visible */
  filter: drop-shadow(0 10px 24px rgba(0, 0, 0, 0.45));
}
.flyer-info .eyebrow {
  display: block;
  margin: 0 0 10px;
  color: var(--accent-copper);
}
.flyer-title {
  color: #fff;
  font-size: clamp(24px, 2.2vw, 34px);
  font-weight: 400;
  line-height: 1.25;
  margin-bottom: 12px;
}
.flyer-sub {
  margin: 0 0 18px;
  color: #c9d1da;
  font-size: 16px;
  line-height: 1.55;
}
.flyer-meta {
  margin: 0 0 24px;
  display: grid;
  gap: 10px;
}
.flyer-meta div {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 12px;
  padding-top: 10px;
  border-top: 1px solid #2c3d50;
}
.flyer-meta dt {
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-copper);
  padding-top: 2px;
}
.flyer-meta dd {
  margin: 0;
  color: #fff;
}
.flyer-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px 24px;
}
.featured .pill-btn.filled {
  background: var(--accent-copper);
  border-color: var(--accent-copper);
}
.featured .pill-btn.filled:hover {
  background: #fff;
  border-color: #fff;
  color: var(--primary-dark);
}
.featured .know-more {
  color: #fff;
}
.flyer-controls {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 32px;
}
.flyer-controls[hidden] {
  display: none;
}
.flyer-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid #4b5560;
  background: transparent;
  color: #fff;
  display: grid;
  place-items: center;
  cursor: pointer;
}
.flyer-btn:hover {
  background: #fff;
  color: var(--primary-dark);
}
.flyer-btn .icon {
  width: 20px;
  height: 20px;
}
.flyer-count {
  min-width: 44px;
  text-align: center;
  font-size: 14px;
  color: #c9d1da;
}
.flyer-dots {
  display: flex;
  gap: 6px;
  margin-left: auto;
}
.flyer-dot {
  width: 28px;
  height: 28px;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  position: relative;
}
.flyer-dot::after {
  content: "";
  position: absolute;
  inset: 11px 4px;
  border-radius: 3px;
  background: #4b5560;
  transition: background 0.2s;
}
.flyer-dot[aria-selected="true"]::after {
  background: var(--accent-copper);
}
@keyframes flyer-in {
  from { opacity: 0; }
}
@media (max-width: 992px) {
  .featured-grid {
    grid-template-columns: 1fr;
  }
  /* Phones/tablets: the frame takes each flyer's own shape (no empty bands) */
  .flyer-stage {
    height: auto;
    display: grid;
  }
  .flyer {
    position: static;
    grid-area: 1 / 1;
    padding: 8px;
    display: none; /* only the current flyer takes space, so the frame matches its shape */
  }
  .flyer.on {
    display: block;
    animation: flyer-in 0.5s ease;
  }
  .flyer img {
    height: auto;
    max-height: 78vh;
  }
}

/* head of school band */
.head-band {
  background: var(--footer);
  color: #fff;
  padding: 56px var(--pad-x);
}
.hb-grid {
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 48px;
  align-items: center;
}
.hb-person {
  display: flex;
  align-items: center;
  gap: 20px;
  padding-right: 40px;
  border-right: 1px solid #4b5560;
}
.hb-photo {
  flex: none;
  width: 104px;
  height: 104px;
  border-radius: 14px;
  overflow: hidden;
}
.hb-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hb-name {
  margin: 0 0 6px;
  font-size: 19px;
  font-weight: 500;
}
.hb-role {
  margin: 0;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-copper);
}
.hb-quote {
  margin: 0 0 18px;
  font-size: clamp(21px, 1.8vw, 28px);
  font-weight: 300;
  line-height: 1.5;
}
.hb-quote::before {
  content: "\201C";
  color: var(--accent-copper);
  margin-right: 4px;
}
.hb-quote::after {
  content: "\201D";
  color: var(--accent-copper);
  margin-left: 2px;
}
.hb-more {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: #d9dee4;
  text-decoration: none;
  font-size: 15px;
}
.hb-more:hover {
  color: var(--accent-copper);
}

/* news & events */
.ne-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
  gap: 56px;
  align-items: start;
}
.ne-sub {
  font-size: 20px;
  font-weight: 500;
  margin-bottom: 10px;
}
.update {
  display: grid;
  grid-template-columns: 1fr 112px;
  gap: 24px;
  align-items: center;
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
}
.update:last-child {
  border-bottom: 0;
}
.update-meta {
  margin: 0 0 6px;
  font-size: 14px;
  color: var(--muted);
}
.update-meta span {
  margin: 0 6px;
}
.update h3 {
  font-size: 18px;
  font-weight: 500;
  line-height: 1.4;
}
.update h3 a {
  text-decoration: none;
}
.update h3 a:hover {
  color: var(--copper-dark);
}
.update-thumb {
  padding: 0;
  border: 0;
  border-radius: 10px;
  overflow: hidden;
  cursor: zoom-in;
  background: var(--grey-card);
}
.update-thumb img {
  display: block;
  width: 112px;
  height: 84px;
  object-fit: cover;
}
.coming {
  background: #fff;
  border-radius: 20px;
  padding: 28px 28px 20px;
  box-shadow: 0 4px 14px rgba(204, 196, 186, 0.6);
}
.coming-note {
  margin: -4px 0 8px;
  font-size: 14px;
  color: var(--muted);
}
.coming-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.coming-list li {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 14px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.coming-list li:last-child {
  border-bottom: 0;
}
.cu-date {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.3;
}
.cu-date b {
  display: block;
  font-size: 16px;
  color: var(--copper-dark);
}
.cu-title {
  display: block;
  font-size: 17px;
  font-weight: 500;
  color: var(--primary-dark);
  margin-bottom: 4px;
}
.cu-sub {
  display: block;
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 6px;
}
.openings-mini li {
  grid-template-columns: 1fr;
  gap: 4px;
}
.openings-mini a {
  font-weight: 500;
  color: var(--primary-dark);
  text-decoration: none;
}
.openings-mini a:hover {
  color: var(--copper-dark);
}

/* research areas */
.area {
  display: grid;
  grid-template-columns: 90px minmax(0, 1fr) minmax(0, 380px);
  gap: 32px;
  padding: 36px 0;
  border-bottom: 1px solid var(--line);
}
.area:first-child {
  padding-top: 0;
}
.area-num {
  font-size: 46px;
  font-weight: 200;
  line-height: 1;
  color: var(--accent-copper);
}
.area-body h3 {
  font-size: clamp(24px, 2vw, 32px);
  font-weight: 400;
  margin-bottom: 10px;
}
.area-blurb {
  margin: 0 0 12px;
  font-size: 17px;
  color: var(--text-dark);
}
.area-keys {
  margin: 0;
  font-size: 15px;
  line-height: 1.7;
  color: var(--muted);
}
.area-faculty .eyebrow {
  display: block;
  margin: 0 0 12px;
  font-size: 12px;
}
.area-faculty ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 14px 10px;
}
.area-faculty a {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 82px;
  text-align: center;
  font-size: 12.5px;
  line-height: 1.25;
  color: var(--text-dark);
  text-decoration: none;
}
.area-faculty a:hover {
  color: var(--copper-dark);
}
.area-faculty .avatar {
  width: 62px;
  height: 62px;
  font-size: 0.95rem;
  margin-bottom: 6px;
}

/* programs */
.prog-featured {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
  margin-bottom: 22px;
}
.prog-feature {
  display: flex;
  flex-direction: column;
  background: var(--cream-card);
  border-radius: 20px;
  box-shadow: var(--shadow);
  overflow: hidden;
}
.prog-feature > img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}
.pf-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 24px 24px 26px;
}
.pf-body > .know-more {
  align-self: flex-start;
  margin-bottom: 20px;
}
.pf-body .eyebrow {
  display: block;
  margin: 0 0 6px;
}
.pf-body h3 {
  font-size: clamp(21px, 1.6vw, 25px);
  font-weight: 400;
  margin-bottom: 12px;
}
.pf-body > p {
  margin: 0 0 14px;
  color: #4a4f55;
  line-height: 1.6;
}
.pf-links {
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin-top: auto;
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
}
.pf-links a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 14px 16px;
  font-size: 15px;
  font-weight: 500;
  color: var(--primary-dark);
  text-decoration: none;
  background: #fff;
  border-bottom: 1px solid var(--line);
}
.pf-links a:nth-child(odd) {
  border-right: 1px solid var(--line);
}
.pf-links a:nth-last-child(-n + 2) {
  border-bottom: 0;
}
.pf-links a:hover {
  background: var(--cream);
  color: var(--copper-dark);
}
.pf-links .icon {
  width: 16px;
  height: 16px;
  color: var(--accent-copper);
}
.prog-pg {
  grid-column: 1 / -1;
}
.pg-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px;
  margin-top: 8px;
}
.pg-course {
  display: flex;
  flex-direction: column;
}
.pg-course > img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 14px;
  margin-bottom: 16px;
}
.pg-course h4 {
  font-size: 20px;
  font-weight: 500;
  margin: 0 0 8px;
}
.pg-course > p {
  margin: 0 0 14px;
  color: #4a4f55;
  line-height: 1.6;
}
.pg-course > .know-more {
  align-self: flex-start;
  margin-bottom: 20px;
}
.prog-more {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px;
}
.prog-tile {
  position: relative;
  display: block;
  border-radius: 16px;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  box-shadow: var(--shadow);
  text-decoration: none;
}
.prog-tile img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s;
}
.prog-tile:hover img {
  transform: scale(1.05);
}
.prog-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 13, 27, 0) 35%, rgba(0, 13, 27, 0.85));
}
.pt-text {
  position: absolute;
  z-index: 1;
  left: 18px;
  right: 18px;
  bottom: 16px;
}
.pt-text .eyebrow {
  display: block;
  font-size: 11.5px;
  color: #f0c4bf;
  margin-bottom: 4px;
}
.pt-title {
  display: block;
  font-size: 20px;
  line-height: 1.25;
  color: #fff;
}

/* facilities (APM "platforms" list) */
.fac-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: start;
}
.fac-intro {
  position: sticky;
  top: 130px;
}
.fac-intro .eyebrow {
  display: block;
  margin: 0 0 8px;
}
.fac-intro p:not(.eyebrow) {
  font-size: 17px;
  line-height: 1.7;
  color: #4a4f55;
  margin: 18px 0 28px;
}
.fac-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--line);
}
.fac-list a {
  display: grid;
  grid-template-columns: 96px 1fr 22px;
  gap: 22px;
  align-items: center;
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
}
.fac-list a:hover .fac-title {
  color: var(--copper-dark);
}
.fac-thumb {
  width: 96px;
  height: 72px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #fff;
  overflow: hidden;
}
.fac-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.fac-title {
  display: block;
  font-size: 20px;
  font-weight: 400;
  color: var(--primary-dark);
  margin-bottom: 4px;
}
.fac-desc {
  display: block;
  font-size: 15px;
  line-height: 1.55;
  color: var(--muted);
}
.fac-arrow {
  width: 18px;
  height: 18px;
  color: var(--accent-copper);
}

@media (max-width: 1100px) {
  .area {
    grid-template-columns: 70px minmax(0, 1fr);
  }
  .area-faculty {
    grid-column: 2;
  }
  .prog-more {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .pg-course .pf-links {
    grid-template-columns: 1fr;
  }
  .pg-course .pf-links a:nth-child(odd) {
    border-right: 0;
  }
  .pg-course .pf-links a:nth-last-child(2) {
    border-bottom: 1px solid var(--line);
  }
}
@media (max-width: 992px) {
  .hh-grid,
  .ne-grid,
  .fac-grid,
  .hb-grid {
    grid-template-columns: 1fr;
  }
  .hero-photos {
    height: 360px;
  }
  .hp-photo img {
    aspect-ratio: 4 / 3;
  }
  .hb-person {
    border-right: 0;
    padding-right: 0;
  }
  .fac-intro {
    position: static;
  }
  .sec-desc {
    text-align: left;
  }
}
@media (max-width: 640px) {
  .hh-stats {
    grid-template-columns: repeat(2, auto);
  }
  .hero-photos {
    height: 280px;
  }
  .area {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .area-faculty {
    grid-column: auto;
  }
  .update {
    grid-template-columns: 1fr 84px;
  }
  .update-thumb img {
    width: 84px;
    height: 64px;
  }
  .pf-links,
  .prog-more,
  .prog-featured,
  .pg-grid {
    grid-template-columns: 1fr;
  }
  .pf-links a:nth-child(odd) {
    border-right: 0;
  }
  .pf-links a:nth-last-child(2) {
    border-bottom: 1px solid var(--line);
  }
  .fac-list a {
    grid-template-columns: 72px 1fr;
  }
  .fac-thumb {
    width: 72px;
    height: 56px;
  }
  .fac-arrow {
    display: none;
  }
}

/* Keep the header to one line on mid-size screens, and the hero inside short windows */
@media (max-width: 1200px) and (min-width: 641px) {
  .brand-inst {
    display: none;
  }
  .brand-name {
    font-size: 17px;
  }
}
@media (max-height: 760px) and (min-width: 993px) {
  .home-hero {
    padding-top: 22px;
    padding-bottom: 26px;
  }
  .hh-title {
    margin: 4px 0 12px;
  }
  .hh-lead {
    font-size: 15.5px;
    line-height: 1.55;
    margin-bottom: 16px;
  }
  .hh-ctas .pill-btn {
    padding: 8px 24px;
    font-size: 16px;
  }
  .hh-stats {
    margin-top: 18px;
    padding-top: 12px;
  }
  .hh-stats strong {
    font-size: 26px;
  }
  .hh-stats div > span {
    font-size: 14px;
  }
}

.image-credits {
  margin: 0 auto;
  padding: 18px var(--pad-x) 26px;
  font-size: 12.5px;
  color: var(--muted);
  background: var(--bg-light);
  max-width: none;
}
.image-credits a {
  color: var(--copper-dark);
}

/* ---------- inner pages ---------- */
.page-intro {
  padding: 48px var(--pad-x) 40px;
  max-width: calc(var(--maxw) + 2 * var(--pad-x));
  margin: 0 auto;
}
.crumbs {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  font-size: 17px;
  margin-bottom: 18px;
}
.crumbs a {
  text-decoration: none;
  color: var(--text-dark);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.crumbs a:hover {
  color: var(--copper-dark);
}
.crumbs [aria-current] {
  color: var(--accent-copper);
}
.crumb-sep {
  color: var(--text-dark);
}
.page-intro h1 {
  font-size: clamp(34px, 2.7vw, 47px);
  font-weight: 300;
  line-height: 1.2;
}
.page-intro .lead {
  margin: 12px 0 0;
  font-size: 18px;
  color: var(--muted);
  max-width: 70ch;
}
.inner-grid {
  display: grid;
  grid-template-columns: 306px minmax(0, 1fr);
  gap: clamp(32px, 7vw, 118px);
  padding: 0 var(--pad-x) var(--pad-y) clamp(16px, 4.1vw, 71px);
  max-width: calc(var(--maxw) + 2 * var(--pad-x));
  margin: 0 auto;
}
.inner-grid.no-side {
  grid-template-columns: minmax(0, 1fr);
  padding-left: var(--pad-x);
}
.side-nav {
  align-self: start;
  position: sticky;
  top: 120px;
  background: var(--cream);
  border-radius: 24px;
  padding: 38px 32px 48px 43px;
  min-height: 420px;
}
.side-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.side-nav a {
  display: block;
  padding: 11px 0;
  border-bottom: 1px solid var(--accent-copper);
  font-size: 15px;
  color: var(--text-dark);
  text-decoration: none;
}
.side-nav a:hover {
  color: var(--copper-dark);
}
.side-nav a.active {
  color: var(--accent-copper);
  font-weight: 600;
}
.inner-content {
  min-width: 0;
  padding-top: 26px;
}
.block {
  margin-bottom: 72px;
  scroll-margin-top: 130px;
}
.block:last-child {
  margin-bottom: 0;
}
.block-title {
  font-size: clamp(30px, 2.3vw, 40px);
  font-weight: 400;
  line-height: 1.2;
  margin-bottom: 26px;
}
.prose {
  font-size: 17px;
  line-height: 1.6;
  color: #4a4f55;
}
.prose p {
  margin: 0 0 18px;
}
.prose .signoff {
  color: var(--primary-dark);
  font-weight: 600;
}
.prose .signoff span {
  font-weight: 400;
  color: var(--accent-copper);
}
.rounded-img {
  width: 100%;
  border-radius: 24px;
  margin-bottom: 36px;
  aspect-ratio: 16 / 7;
  object-fit: cover;
}
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  align-items: start;
}
.split .head-photo {
  max-width: 360px;
}

/* ---------- people ---------- */
.toolbar {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 30px;
}
.toolbar-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.search,
.select {
  padding: 12px 18px;
  border: 1px solid var(--line);
  border-radius: 28px;
  font: inherit;
  background: #fff;
  max-width: 100%;
}
.search {
  width: 100%;
  max-width: 460px;
}
.search:focus,
.select:focus {
  outline: 2px solid var(--accent-copper);
  outline-offset: 1px;
}
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.chip {
  border: 0;
  background: var(--chip-blue);
  border-radius: 999px;
  padding: 7px 16px;
  font: inherit;
  font-size: 14px;
  cursor: pointer;
  color: var(--primary-dark);
}
.chip:hover {
  background: #bcd8f5;
}
.chip.active {
  background: var(--primary-dark);
  color: #fff;
}
.chip-n {
  display: inline-block;
  margin-left: 4px;
  padding: 0 7px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.7);
  font-size: 12px;
}
.chip.active .chip-n {
  background: rgba(255, 255, 255, 0.2);
}
.count {
  color: var(--muted);
  font-size: 14px;
}
.faculty-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 420px), 1fr));
  gap: 22px;
}
.faculty-card {
  display: flex;
  gap: 20px;
  background: var(--cream-card);
  border-radius: 16px;
  padding: 24px;
  box-shadow: var(--shadow);
}
.avatar {
  flex: none;
  width: 104px;
  height: 104px;
  border-radius: 50%;
  background: var(--copper-dark);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 500;
  font-size: 1.4rem;
  overflow: hidden;
}
.avatar::before {
  content: attr(data-initials);
  grid-area: 1 / 1;
}
.avatar img {
  grid-area: 1 / 1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
  background: var(--grey-card);
}
.faculty-body {
  min-width: 0;
}
.faculty-body h3 {
  font-size: 20px;
  font-weight: 500;
}
.designation {
  margin: 2px 0 12px;
  color: var(--accent-copper);
  font-weight: 600;
  font-size: 15px;
}
.tags {
  list-style: none;
  padding: 0;
  margin: 0 0 14px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.tags li {
  background: var(--chip-blue);
  border-radius: 14px;
  padding: 2px 10px;
  font-size: 13px;
  color: var(--primary-dark);
}
.faculty-links {
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 18px;
  font-size: 14.5px;
  word-break: break-word;
}
.faculty-links a:not(.know-more) {
  color: var(--copper-dark);
}
.year-group {
  margin-bottom: 44px;
}
.year-head {
  font-size: 26px;
  font-weight: 300;
  margin: 0 0 18px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--accent-copper);
}
.year-head span {
  font-size: 15px;
  color: var(--accent-copper);
  font-weight: 500;
}
.person-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 16px;
}
.person-card {
  background: var(--cream-card);
  border-radius: 16px;
  box-shadow: var(--shadow);
  padding: 20px 12px;
  text-align: center;
}
.person-card .avatar {
  width: 92px;
  height: 92px;
  margin: 0 auto 12px;
  font-size: 1.15rem;
}
.person-card h3 {
  font-size: 16px;
  font-weight: 500;
  margin-bottom: 4px;
}
.person-card p {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
}

/* ---------- research / programs / news inner ---------- */
.areas {
  columns: 2;
  column-gap: 40px;
  padding-left: 18px;
  font-size: 16px;
  color: #4a4f55;
}
.areas li {
  margin-bottom: 10px;
  break-inside: avoid;
}
.program-detail {
  background: var(--cream-card);
  border-radius: 16px;
  box-shadow: var(--shadow);
  padding: 30px 32px;
  margin-bottom: 24px;
  scroll-margin-top: 130px;
}
.program-detail h2 {
  font-size: 26px;
  font-weight: 400;
  margin: 6px 0 12px;
}
.program-detail p {
  margin: 0 0 12px;
  color: #4a4f55;
}
.btn-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 24px;
  margin-top: 18px;
}
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 22px;
}
.news-photo-card .thumb {
  border-radius: 0;
}
.news-photo-card h3 {
  font-size: 16px;
  font-weight: 500;
  line-height: 1.4;
}
.news-photo-card h3 a {
  text-decoration: none;
}
.news-photo-card .news-date {
  margin-bottom: 8px;
  color: var(--accent-copper);
  font-weight: 500;
}

/* ---------- committees ---------- */
.committee-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr));
  gap: 18px;
}
.committee {
  background: var(--cream-card);
  border-radius: 16px;
  box-shadow: var(--shadow);
  padding: 22px 24px;
  border-top: 4px solid var(--accent-copper);
}
.committee h3 {
  font-size: 17px;
  font-weight: 600;
  line-height: 1.35;
  margin-bottom: 12px;
}
.committee ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.committee li {
  padding: 6px 0;
  border-bottom: 1px solid var(--line);
  font-size: 15px;
  color: var(--text-dark);
}
.committee li:last-child {
  border-bottom: 0;
}
.committee li.lead {
  font-weight: 600;
  color: var(--primary-dark);
}
.role-tag {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 8px;
  border-radius: 10px;
  background: var(--chip-blue);
  font-size: 11.5px;
  font-weight: 600;
  vertical-align: 1px;
}
.ethics {
  margin: 0;
  background: var(--cream-card);
  border-radius: 16px;
  box-shadow: var(--shadow);
  overflow: hidden;
}
.ethics-row {
  display: grid;
  grid-template-columns: minmax(160px, 260px) 1fr;
  gap: 20px;
  padding: 14px 24px;
  border-bottom: 1px solid var(--line);
}
.ethics-row:last-child {
  border-bottom: 0;
}
.ethics dt {
  font-weight: 600;
  color: var(--copper-dark);
}
.ethics dd {
  margin: 0;
  color: var(--text-dark);
}
.advisory-grid {
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
}
.advisory-card p {
  line-height: 1.45;
}
@media (max-width: 640px) {
  .ethics-row {
    grid-template-columns: 1fr;
    gap: 4px;
  }
}

/* ---------- images ---------- */
.thumb {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: var(--grey-card);
  cursor: zoom-in;
  overflow: hidden;
  border-radius: 12px;
}
.thumb img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transition: transform 0.3s;
}
.thumb:hover img {
  transform: scale(1.04);
}
.photo-tile {
  margin: 0;
  background: var(--cream-card);
  border-radius: 16px;
  box-shadow: var(--shadow);
  overflow: hidden;
}
.photo-tile .thumb {
  border-radius: 0;
}
.photo-tile figcaption {
  padding: 14px 18px;
  font-size: 15px;
  color: var(--text-dark);
}
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 14px;
}
.facility-photos {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 4px;
  background: #fff;
}
.facility-photos .thumb {
  border-radius: 0;
}
.facility-photos .thumb img,
.r-item .thumb img {
  object-fit: contain;
  background: #fff;
}
.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 22px;
}
.contact-grid .card-body p {
  color: var(--text-dark);
}
.contact-grid a:not(.know-more) {
  color: var(--copper-dark);
}
.staff-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 14px;
}
.staff-list a {
  color: var(--copper-dark);
}

.lightbox {
  border: 0;
  padding: 0;
  background: transparent;
  max-width: 95vw;
  max-height: 95vh;
}
.lightbox::backdrop {
  background: rgba(0, 13, 27, 0.9);
}
.lightbox img {
  display: block;
  max-width: 95vw;
  max-height: 85vh;
  margin: 0 auto;
  border-radius: 12px;
}
.lb-caption {
  color: #fff;
  text-align: center;
  margin: 10px 0 0;
}
.lb-close {
  position: fixed;
  top: 16px;
  right: 20px;
  width: 40px;
  height: 40px;
  background: none;
  border: 0;
  color: #fff;
  cursor: pointer;
}
.lb-close svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

/* ---------- footer ---------- */
.site-footer {
  background: var(--footer);
  color: #fff;
  padding: 72px clamp(20px, 8.2vw, 118px) 14px;
}
.site-footer a {
  color: #fff;
  text-decoration: none;
}
.site-footer a:hover {
  color: var(--accent-copper);
}
.footer-links {
  display: grid;
  grid-template-columns: 1fr 1fr 2fr;
  gap: 32px;
  padding-bottom: 56px;
  border-bottom: 1px solid #a0473f;
}
.footer-links ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.footer-links li {
  margin-bottom: 18px;
  font-size: 16.5px;
}
.footer-res h4 {
  color: var(--accent-copper);
  font-size: 16.5px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding-bottom: 12px;
  margin-bottom: 22px;
  border-bottom: 1px solid #4b5560;
}
.footer-res ul {
  columns: 2;
  column-gap: 32px;
}
.footer-res li {
  break-inside: avoid;
}
.footer-info {
  display: grid;
  grid-template-columns: 140px 1.2fr 1.3fr 1fr auto;
  gap: 40px;
  padding: 40px 0;
  border-bottom: 1px solid #4b5560;
}
.footer-logo {
  padding-right: 32px;
  border-right: 1px solid #4b5560;
}
.footer-logo img {
  background: #fff;
  padding: 8px;
  border-radius: 4px;
  width: 106px;
}
.footer-info h5 {
  margin: 0 0 12px;
  font-size: 17px;
  font-weight: 400;
}
.footer-info p {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.5;
  color: #b8c0c9;
}
.footer-info p a {
  color: #b8c0c9;
}
.footer-social {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.footer-social .icon {
  width: 20px;
  height: 20px;
}
.footer-copy {
  text-align: center;
  font-size: 14.5px;
  color: #b8c0c9;
  margin: 18px 0 0;
}
.footer-copy a {
  color: inherit;
  text-decoration: none;
}
.footer-copy a:hover {
  text-decoration: underline;
}
#credits {
  padding: 28px 0 0;
  background: none;
}
.to-top {
  position: fixed;
  right: 30px;
  bottom: 30px;
  z-index: 40;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: var(--accent-copper);
  color: #fff;
  display: grid;
  place-items: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}
.to-top.show {
  opacity: 1;
  pointer-events: auto;
}
.to-top .icon {
  width: 24px;
  height: 24px;
}

/* ---------- responsive ---------- */
@media (max-width: 1200px) {
  .pill-links a {
    padding: 7px 10px;
    font-size: 12.5px;
  }
  .brand-name {
    font-size: 18px;
  }
  .footer-info {
    grid-template-columns: 1fr 1fr;
  }
  .footer-logo {
    border-right: 0;
  }
  .footer-social {
    flex-direction: row;
  }
}

@media (max-width: 992px) {
  .topbar {
    padding: 0 16px;
  }
  .site-header {
    padding: 12px 16px;
  }
  .pill-links,
  .pill-sep {
    display: none;
  }
  .pill-nav {
    padding: 0;
    border: 0;
    background: #374151;
    border-radius: 50%;
  }
  .menu-btn {
    width: 52px;
    height: 52px;
    color: #fff;
  }
  .mega {
    top: 0;
    max-height: 100vh;
    height: 100vh;
    grid-template-columns: 1fr;
    border-radius: 0;
    background: var(--footer);
  }
  .mega-main {
    padding: 24px 20px;
  }
  .mega-side {
    border-radius: 0;
    padding: 24px 20px 40px;
  }
  body.menu-open .site-header {
    z-index: 60;
  }
  .head-msg,
  .split {
    grid-template-columns: 1fr;
  }
  .head-photo {
    max-width: 280px;
  }
  .inner-grid {
    grid-template-columns: 1fr;
    padding-left: var(--pad-x);
  }
  .side-nav {
    position: static;
    min-height: 0;
    padding: 20px 24px;
  }
  .footer-links {
    grid-template-columns: 1fr 1fr;
  }
  .footer-res {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  .topbar .sep,
  .topbar-left > a {
    display: none;
  }
  .brand {
    gap: 10px;
  }
  .brand-logo {
    width: 46px;
  }
  .brand-divider {
    height: 44px;
  }
  .brand-name {
    font-size: 15px;
  }
  .brand-inst {
    display: none;
  }
  .announce {
    padding: 40px 16px;
  }
  .announce-more span:first-child {
    display: none;
  }
  .r-item {
    grid-template-columns: 1fr;
  }
  .areas,
  .footer-res ul {
    columns: 1;
  }
  .footer-links {
    grid-template-columns: 1fr;
  }
  .footer-info {
    grid-template-columns: 1fr;
  }
  .faculty-card {
    flex-direction: column;
    align-items: flex-start;
  }
  .opening {
    flex-direction: column;
    align-items: flex-start;
  }
  .sec-head .pill-btn {
    padding: 8px 20px;
    font-size: 15px;
  }
  .to-top {
    right: 16px;
    bottom: 16px;
  }
}

/* ---------- touch devices / phones ---------- */
@media (pointer: coarse), (max-width: 640px) {
  /* ≥40px tap areas without changing the look */
  .social a,
  .footer-social a {
    display: inline-grid;
    place-items: center;
    min-width: 40px;
    min-height: 40px;
  }
  .social {
    gap: 0;
  }
  .lang-btn {
    min-width: 40px;
    min-height: 40px;
  }
  .know-more {
    padding: 10px 0;
  }
  .crumbs a,
  .hb-more,
  .footer-info h5 a {
    display: inline-flex;
    padding: 10px 0;
  }
}
@media (max-width: 992px) {
  /* Inner-page section menu becomes one swipeable row of pills instead of a long list above the content */
  .inner-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .side-nav {
    min-width: 0;
    position: sticky;
    top: 76px;
    z-index: 20;
    margin: 0 calc(-1 * var(--pad-x));
    padding: 10px var(--pad-x);
    border-radius: 0;
    background: rgba(255, 245, 232, 0.96);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    box-shadow: 0 2px 6px rgba(204, 196, 186, 0.5);
  }
  .side-nav ul {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  .side-nav ul::-webkit-scrollbar {
    display: none;
  }
  .side-nav li {
    flex: none;
  }
  .side-nav a {
    padding: 9px 16px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #fff;
    white-space: nowrap;
    font-size: 14px;
  }
  .side-nav a.active {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    color: #fff;
  }
  .inner-content {
    padding-top: 8px;
  }
  .block {
    scroll-margin-top: 150px;
  }
}

@media (max-width: 640px) {
  /* Two people per row on phones (students, alumni, advisory committee) */
  .person-grid,
  .advisory-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }
  .person-card {
    padding: 14px 8px;
  }
  .person-card .avatar {
    width: 72px;
    height: 72px;
  }
  .person-card h3 {
    font-size: 14.5px;
  }
}

@media (max-width: 992px) {
  /* Stacked layout on tablets/phones: let the hero be as tall as its content */
  .home-hero {
    min-height: 0;
  }
}

/* Large desktop screens: the hero content scales up with the screen so it fills the first view
   instead of floating in the middle of wide empty bands. Short windows keep the compact rules above. */
@media (min-width: 993px) and (min-height: 761px) {
  .home-hero {
    padding-top: 40px;
    padding-bottom: 40px;
  }
  .home-hero .wrap {
    max-width: 1560px;
  }
  .hh-grid {
    grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr);
    gap: clamp(40px, 4.5vw, 110px);
  }
  .hh-title {
    font-size: clamp(40px, min(3.7vw, 6.7vh), 80px);
    margin: 8px 0 clamp(16px, 2.2vh, 28px);
  }
  .hh-lead {
    font-size: clamp(16px, min(1vw, 1.9vh), 20px);
    max-width: 46em;
    margin-bottom: clamp(22px, 2.9vh, 36px);
  }
  .hh-ctas .pill-btn {
    font-size: clamp(15px, min(0.95vw, 1.75vh), 18px);
    padding: clamp(10px, 1.15vh, 14px) clamp(24px, 1.7vw, 32px);
  }
  .hh-stats {
    gap: 12px clamp(40px, 3.2vw, 72px);
    margin-top: clamp(26px, 3.4vh, 44px);
    padding-top: clamp(16px, 2.2vh, 24px);
  }
  .hh-stats strong {
    font-size: clamp(30px, min(2.3vw, 4.3vh), 48px);
  }
  .hh-stats div > span {
    font-size: clamp(14px, min(0.9vw, 1.65vh), 17px);
  }
  .hero-photos {
    /* full height of the hero, minus its padding */
    height: calc(100vh - var(--chrome-h, 134px) - 150px);
    gap: 14px;
    mask-image: linear-gradient(180deg, transparent, #000 7%, #000 93%, transparent);
    -webkit-mask-image: linear-gradient(180deg, transparent, #000 7%, #000 93%, transparent);
  }
  .hp-track {
    gap: 14px;
  }
}

/* Header at the top of the page: fully transparent, blending into the page (as on iiti.ac.in) */
.site-header {
  background: transparent;
  box-shadow: none;
}

/* Header after scrolling: translucent navy with blur, as on iiti.ac.in (rgba(0, 13, 27, .7)) */
.site-header.scrolled {
  background: rgba(38, 72, 112, 0.62); /* lighter blue than IITI's navy so the blue logo stays visible */
  -webkit-backdrop-filter: blur(12px) saturate(140%);
  backdrop-filter: blur(12px) saturate(140%);
  box-shadow: 0 2px 14px rgba(0, 0, 0, 0.25);
}
.site-header.scrolled .brand-name,
.site-header.scrolled .brand-inst {
  color: #fff;
}
.site-header.scrolled .brand-logo {
  /* the logo is dark blue: a soft white disc behind it keeps it readable on the blue bar */
  background: rgba(255, 255, 255, 0.92);
  border-radius: 50%;
  padding: 3px;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.4);
}
.brand-logo {
  transition: background 0.3s, padding 0.3s;
}
.site-header.scrolled .brand-divider {
  background: rgba(255, 255, 255, 0.55);
}
.site-header.scrolled .pill-nav {
  background: rgba(0, 13, 27, 0.45);
  border: 1px solid rgba(255, 255, 255, 0.18);
}
.site-header.scrolled .pill-links a {
  color: #fff;
}
.site-header.scrolled .pill-links a:hover,
.site-header.scrolled .pill-links a.active {
  background: #fff;
  color: var(--primary-dark);
}
.site-header.scrolled .pill-sep {
  background: #4b5560;
}
.site-header.scrolled .menu-btn {
  color: #fff;
}
.brand-name,
.brand-inst,
.pill-nav,
.pill-links a {
  transition: color 0.3s, background 0.3s, border-color 0.3s;
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .site-header.scrolled {
    background: rgba(38, 72, 112, 0.95);
  }
}

/* Homepage: hero background runs up behind the transparent header, so there is no seam */
body[data-page="home"] .home-hero {
  margin-top: calc(-1 * var(--header-h, 93px));
  min-height: calc(100vh - var(--chrome-h, 134px) + var(--header-h, 93px));
}
body[data-page="home"] .home-hero > .wrap {
  margin-top: var(--header-h, 93px);
}
@media (max-width: 992px) {
  body[data-page="home"] .home-hero {
    min-height: 0;
  }
}

/* former faculty: space between "At the school" line and tags */
.faculty-body .muted-small + .tags {
  margin-top: 10px;
}

/* facilities: expandable full description */
.facility-more {
  margin-top: 12px;
  border-top: 1px solid var(--line);
  padding-top: 10px;
}
.facility-more summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--copper-dark);
  min-height: 40px;
  display: flex;
  align-items: center;
}
.facility-more h4 {
  font-size: 16px;
  font-weight: 600;
  margin: 16px 0 6px;
}
.facility-more p,
.facility-more li {
  font-size: 15px;
  line-height: 1.6;
  color: #4a4f55;
}
.facility-more ul {
  padding-left: 20px;
  margin: 6px 0 0;
}

/* sponsored projects */
.projects-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
}
.projects-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
}
.projects-table th,
.projects-table td {
  text-align: left;
  vertical-align: top;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
}
.projects-table th {
  background: var(--cream);
  font-weight: 600;
  white-space: nowrap;
}
.projects-table tr:last-child td {
  border-bottom: 0;
}
.projects-table .status {
  white-space: nowrap;
  font-size: 13px;
  font-weight: 600;
  color: var(--copper-dark);
}
@media (max-width: 640px) {
  .projects-table thead {
    display: none;
  }
  .projects-table tr {
    display: block;
    padding: 12px 14px;
    border-bottom: 1px solid var(--line);
  }
  .projects-table td {
    display: block;
    padding: 2px 0;
    border: 0;
  }
  .projects-table td[data-label]::before {
    content: attr(data-label) ": ";
    font-weight: 600;
  }
  .projects-table td.p-title {
    font-weight: 600;
    margin-bottom: 4px;
  }
}
.projects-table .p-dur {
  white-space: nowrap;
}
