/* RugaTech Global — v3
   Palette: navy, royal blue, green, white, black only */
:root {
  --navy: #0d2b5e;
  --blue: #1e63c4;
  --green: #43a535;
  --white: #ffffff;
  --black: #000000;
  --line: rgba(13, 43, 94, 0.15);
  --head: 'Montserrat', 'Segoe UI', Arial, sans-serif;
  --body: 'Inter', 'Segoe UI', Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; font-family: var(--body); color: var(--black); background: var(--white); line-height: 1.6; }
img { max-width: 100%; display: block; }
h1, h2, h3, h4 { font-family: var(--head); margin: 0; line-height: 1.2; color: var(--navy); font-weight: 700; }
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
a { color: inherit; }

.container { width: min(1200px, calc(100% - 2rem)); margin: 0 auto; }

/* Shared */
.label { display: flex; align-items: center; gap: 0.6rem; margin-bottom: 0.75rem; font-size: 0.8rem; font-weight: 700; color: var(--blue); }
.label::before { content: ''; width: 26px; height: 2px; background: var(--blue); }
.label.upper { text-transform: uppercase; letter-spacing: 0.08em; }
.on-dark .label { color: var(--white); }
.on-dark .label::before { background: var(--green); }

.btn { display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.6rem 1.2rem; border-radius: 999px; border: 2px solid transparent; font-weight: 600; font-size: 0.85rem; text-decoration: none; cursor: pointer; transition: background .15s, color .15s, border-color .15s; }
.btn::after { content: '→'; }
.btn.no-arrow::after { content: none; }
.btn-blue { background: var(--blue); color: var(--white); }
.btn-blue:hover { background: var(--navy); }
.btn-green { background: var(--green); color: var(--white); }
.btn-green:hover { background: var(--blue); }
.btn-ghost { border-color: var(--white); color: var(--white); }
.btn-ghost:hover { background: var(--white); color: var(--navy); }
.btn-outline { border-color: var(--blue); color: var(--blue); }
.btn-outline:hover { background: var(--blue); color: var(--white); }

.bullets li { position: relative; padding: 0.18rem 0 0.18rem 1rem; font-size: 0.88rem; }
.bullets li::before { content: ''; position: absolute; left: 0; top: 0.72rem; width: 5px; height: 5px; border-radius: 50%; background: var(--navy); }

/* Header */
.site-header { position: sticky; top: 0; z-index: 50; background: var(--white); border-bottom: 1px solid var(--line); }
.header-inner { display: flex; align-items: center; gap: 2rem; padding: 0.85rem 0; }
.brand { display: flex; align-items: center; gap: 0.7rem; text-decoration: none; }
.brand img { width: 48px; height: 48px; object-fit: contain; }
.brand b { display: block; font-family: var(--head); font-size: 1.5rem; color: var(--navy); line-height: 1; }
.brand small { display: block; margin-top: 0.3rem; font-size: 0.6rem; font-weight: 600; letter-spacing: 0.3em; color: var(--navy); }
.main-nav { display: flex; gap: 0.2rem; margin: 0 auto; }
.main-nav a { padding: 0.5rem 0.7rem; font-size: 0.86rem; font-weight: 500; text-decoration: none; border-bottom: 2px solid transparent; }
.main-nav a:hover, .main-nav a.active { color: var(--blue); border-bottom-color: var(--blue); }
.nav-toggle { display: none; margin-left: auto; background: none; border: 1px solid var(--line); border-radius: 6px; padding: 0.5rem; cursor: pointer; }
.nav-toggle span { display: block; width: 22px; height: 2px; margin: 4px 0; background: var(--navy); }

/* Hero */
.hero { position: relative; background: var(--navy); color: var(--white); overflow: hidden; }
.hero-img { position: absolute; top: 0; right: 0; height: 100%; width: 62%; object-fit: cover; object-position: right center; }
.hero-arrow, .hero-arrow-edge { position: absolute; top: 0; left: 0; height: 100%; width: 100%; }
/* Straight diagonal edge, as in the mockup */
.hero-arrow { background: var(--navy); clip-path: polygon(0 0, 55% 0, 40% 100%, 0 100%); }
.hero-arrow-edge { background: var(--blue); clip-path: polygon(0 0, calc(55% + 6px) 0, calc(40% + 6px) 100%, 0 100%); }
.hero-inner { position: relative; padding: 5.5rem 0; max-width: 470px; }
.hero .kicker { font-size: 0.78rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; margin-bottom: 0.9rem; }
.hero h1 { color: var(--white); font-size: clamp(1.9rem, 3.2vw, 2.5rem); margin-bottom: 1rem; }
.hero h1 span { color: var(--green); }
.hero .lead { margin-bottom: 1.5rem; font-size: 0.95rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.9rem; }

/* About snapshot */
.snapshot { padding: 3.5rem 0; }
.snapshot-grid { display: grid; grid-template-columns: 1fr 1.9fr; gap: 1.5rem; align-items: start; }
.snapshot h2 { font-size: clamp(1.5rem, 2.2vw, 1.9rem); margin-bottom: 1rem; }
.snapshot-intro p { margin-bottom: 1.75rem; font-size: 0.95rem; }
.cards3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.card { border: 1px solid var(--line); border-top: 4px solid var(--blue); border-radius: 8px; padding: 1.4rem; background: var(--white); }
.card h3 { font-size: 1.02rem; margin-bottom: 0.8rem; }

/* Robotics panel */
.robotics { padding: 0 0 3.5rem; }
.robotics-panel { background: var(--navy); color: var(--white); border-radius: 12px; padding: 2rem; display: grid; grid-template-columns: 1fr 1.25fr 0.75fr; gap: 1.75rem; align-items: center; }
.robotics h2 { color: var(--white); font-size: clamp(1.5rem, 2.2vw, 1.85rem); margin-bottom: 1rem; }
.robotics-text > p { font-size: 0.93rem; margin-bottom: 1.5rem; }
.robotics-text > p b { color: var(--green); font-weight: 600; }
.points { display: grid; grid-template-columns: repeat(3, auto); justify-content: start; margin-bottom: 1.75rem; }
.points span { font-size: 0.8rem; padding: 0 1rem; border-left: 1px solid rgba(255,255,255,0.3); line-height: 1.35; }
.points span:first-child { padding-left: 0; border-left: 0; }
.video { position: relative; display: block; aspect-ratio: 16 / 10; border-radius: 8px; overflow: hidden; background: var(--blue) center / cover no-repeat; border: 1px solid rgba(255,255,255,0.25); text-decoration: none; }
.video::before { content: ''; position: absolute; inset: 0; background: rgba(13,43,94,0.35); }
.video .play { position: absolute; left: 50%; top: 50%; width: 64px; height: 64px; margin: -32px 0 0 -32px; border-radius: 50%; border: 3px solid var(--white); }
.video .play::after { content: ''; position: absolute; left: 24px; top: 17px; border-style: solid; border-width: 12px 0 12px 19px; border-color: transparent transparent transparent var(--white); }
.video .title { position: absolute; right: 1.25rem; top: 50%; transform: translateY(-50%); text-align: left; color: var(--white); }
.video .title b { display: block; font-family: var(--head); font-size: 1.6rem; line-height: 1.1; }
.video .title small { font-size: 0.75rem; }
.video .dur { position: absolute; right: 0.75rem; bottom: 0.75rem; background: var(--black); color: var(--white); font-size: 0.72rem; padding: 0.15rem 0.5rem; border-radius: 4px; }
.watch h3 { color: var(--white); font-family: var(--body); font-size: 0.85rem; margin-bottom: 0.85rem; }
.watch a { display: flex; gap: 0.75rem; align-items: center; padding: 0.5rem; margin-bottom: 0.5rem; border: 1px solid transparent; border-radius: 6px; text-decoration: none; }
.watch a.current, .watch a:hover { border-color: var(--blue); }
.watch .thumb { width: 84px; height: 54px; border-radius: 4px; background: var(--blue) center / cover no-repeat; flex-shrink: 0; }
.watch b { display: block; font-size: 0.8rem; font-weight: 600; }
.watch small { font-size: 0.74rem; }

/* Programs */
.programs { padding: 3.5rem 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.programs-grid { display: grid; grid-template-columns: 1.3fr repeat(5, 1fr); gap: 0.9rem; align-items: stretch; }
.programs-intro h2 { font-size: clamp(1.4rem, 2vw, 1.7rem); margin-bottom: 0.75rem; }
.programs-intro p { font-size: 0.85rem; margin-bottom: 1.5rem; }
.prog { border: 1px solid var(--line); border-radius: 8px; padding: 1.1rem; }
.prog h3 { font-family: var(--body); font-size: 0.86rem; margin-bottom: 0.5rem; }
.prog .bullets li { font-size: 0.76rem; color: var(--blue); }
.prog .bullets li::before { background: var(--blue); top: 0.62rem; }

/* Innovation */
.innovation { display: grid; grid-template-columns: 0.55fr 1fr; }
.innovation-img { min-height: 340px; background: var(--blue) 42% center / 70% auto no-repeat; clip-path: polygon(0 0, 100% 0, 78% 100%, 0 100%); }
.innovation-body { padding: 3rem 2rem 3rem 0.5rem; }
.innovation-body h2 { font-size: clamp(1.4rem, 2.2vw, 1.8rem); margin-bottom: 1.75rem; }
.cols3 { display: grid; grid-template-columns: repeat(3, 1fr); }
.cols3 > div { padding: 0 1.5rem; border-left: 1px solid var(--line); }
.cols3 > div:first-child { padding-left: 0; border-left: 0; }
.cols3 h3 { font-family: var(--body); font-size: 0.95rem; color: var(--blue); margin-bottom: 0.6rem; }
.cols3 .bullets li { font-size: 0.82rem; }

/* Stats */
.stats { background: var(--navy); color: var(--white); }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.stat { padding: 1.6rem 1.5rem; border-left: 1px solid rgba(255,255,255,0.2); }
.stat:first-child { border-left: 0; }
.stat b { display: block; font-family: var(--head); font-size: 1.7rem; line-height: 1.1; }
.stat span { font-size: 0.85rem; color: var(--green); font-weight: 600; }

/* Footer */
.site-footer { background: var(--navy); color: var(--white); padding: 3rem 0 0; font-size: 0.86rem; border-top: 1px solid rgba(255,255,255,0.15); }
.footer-grid { display: grid; grid-template-columns: 1.3fr 0.8fr 1fr 1.2fr 1.4fr; gap: 2rem; }
.footer-brand .brand b, .footer-brand .brand small { color: var(--white); }
.footer-brand .brand img { background: var(--white); border-radius: 6px; padding: 3px; }
.footer-brand p { margin-top: 1rem; }
.site-footer h4 { color: var(--white); font-size: 0.9rem; margin-bottom: 0.9rem; }
.site-footer li { margin-bottom: 0.35rem; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { color: var(--green); }
.newsletter p { margin-bottom: 0.9rem; }
.newsletter form { display: flex; }
.newsletter input { flex: 1; min-width: 0; padding: 0.75rem; border: 0; border-radius: 6px 0 0 6px; font: inherit; }
.newsletter button { border: 0; padding: 0 1.1rem; border-radius: 0 6px 6px 0; background: var(--blue); color: var(--white); font: inherit; font-weight: 600; cursor: pointer; }
.newsletter button:hover { background: var(--green); }
.footer-bottom { margin-top: 2.5rem; padding: 1.2rem 0; border-top: 1px solid rgba(255,255,255,0.15); }
.footer-bottom .container { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 1rem; font-size: 0.8rem; }
.footer-bottom nav { display: flex; gap: 1.25rem; }

/* WhatsApp floating button */
.whatsapp { position: fixed; right: 1.5rem; bottom: 1.5rem; z-index: 60; display: flex; align-items: center; gap: 0.75rem; text-decoration: none; }
.wa-btn { position: relative; width: 58px; height: 58px; border-radius: 50%; background: var(--green); color: var(--white); display: grid; place-items: center; box-shadow: 0 6px 18px rgba(0,0,0,0.25); transition: transform .2s, background .2s; }
.wa-btn svg { width: 30px; height: 30px; }
.wa-btn::before { content: ''; position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--green); animation: wa-pulse 2.4s ease-out infinite; }
.wa-dot { position: absolute; top: 3px; right: 3px; width: 12px; height: 12px; border-radius: 50%; background: var(--white); border: 3px solid var(--green); }
.wa-label { background: var(--white); color: var(--navy); font-size: 0.85rem; font-weight: 600; padding: 0.55rem 0.95rem; border-radius: 8px; box-shadow: 0 4px 14px rgba(0,0,0,0.15); opacity: 0; transform: translateX(8px); transition: opacity .2s, transform .2s; pointer-events: none; }
.whatsapp:hover .wa-label, .whatsapp:focus-visible .wa-label { opacity: 1; transform: none; }
.whatsapp:hover .wa-btn { transform: scale(1.06); background: var(--navy); }
.whatsapp:hover .wa-btn::before { border-color: var(--navy); }
@keyframes wa-pulse { 0% { transform: scale(1); opacity: .7; } 100% { transform: scale(1.5); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .wa-btn::before { animation: none; } }
@media (max-width: 640px) { .whatsapp { right: 1rem; bottom: 1rem; } .wa-btn { width: 52px; height: 52px; } }

/* Responsive */
@media (max-width: 1100px) {
  .robotics-panel { grid-template-columns: 1fr 1fr; }
  .watch { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.5rem; }
  .watch h3 { grid-column: 1 / -1; }
  .programs-grid { grid-template-columns: repeat(3, 1fr); }
  .programs-intro { grid-column: 1 / -1; }
  .footer-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 900px) {
  .nav-toggle { display: block; }
  .header-cta { display: none; }
  .header-inner { flex-wrap: wrap; }
  .main-nav { display: none; width: 100%; flex-direction: column; }
  .main-nav.show { display: flex; }
  .hero { display: flex; flex-direction: column; }
  .hero-img { position: static; width: 100%; height: 260px; order: 2; object-position: right center; }
  .hero-arrow, .hero-arrow-edge { display: none; }
  .hero-inner { padding: 3rem 0; }
  .snapshot-grid, .robotics-panel, .innovation { grid-template-columns: 1fr; }
  .innovation-img { clip-path: none; min-height: 260px; background-size: auto 85%; background-position: center; }
  .innovation-body { padding: 2.5rem 1rem; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .stat:nth-child(3) { border-left: 0; }
}
@media (max-width: 640px) {
  .cards3, .cols3, .watch, .stats-grid, .footer-grid { grid-template-columns: 1fr; }
  .cols3 > div { padding: 1rem 0; border-left: 0; border-top: 1px solid var(--line); }
  .cols3 > div:first-child { border-top: 0; }
  .programs-grid { grid-template-columns: 1fr 1fr; }
  .stat { border-left: 0; border-top: 1px solid rgba(255,255,255,0.2); }
  .points { grid-template-columns: 1fr; gap: 0.5rem; }
  .points span { padding: 0; border: 0; }
}

.header-cta { padding: 0.45rem 1rem; font-size: 0.8rem; }

/* ---------- Section heading (shared) ---------- */
.sec-head { display: grid; grid-template-columns: 1fr 1fr; gap: 2.5rem; align-items: end; margin-bottom: 2.25rem; }
.sec-head h2 { font-size: clamp(1.6rem, 2.6vw, 2.1rem); }
.sec-head > p { padding-left: 1.25rem; border-left: 3px solid var(--green); font-size: 0.95rem; }

/* ---------- Departments ---------- */
.departments { background: var(--navy); color: var(--white); padding: 4.5rem 0; }
.departments h2, .departments h3 { color: var(--white); }
.departments .sec-head > p { color: var(--white); }
.dep-grid { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid rgba(255,255,255,0.2); border-left: 1px solid rgba(255,255,255,0.2); }
.dep { display: flex; flex-direction: column; padding: 1.75rem 1.5rem; border-right: 1px solid rgba(255,255,255,0.2); border-bottom: 1px solid rgba(255,255,255,0.2); transition: background .2s; }
.dep:hover { background: var(--blue); }
.dep-no { font-family: var(--head); font-weight: 700; color: var(--green); margin-bottom: 0.75rem; }
.dep h3 { font-size: 1.1rem; margin-bottom: 0.6rem; }
.dep > p { font-size: 0.88rem; margin-bottom: 1.5rem; }
.dep-head { margin-top: auto; padding-top: 1rem; border-top: 1px solid rgba(255,255,255,0.2); }
.dep-head small { display: block; font-size: 0.7rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--green); font-weight: 700; }
.dep-head b { font-family: var(--head); font-size: 1rem; }

/* ---------- Team ---------- */
.team { padding: 4.5rem 0; border-top: 1px solid var(--line); }
.team-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.member { border: 1px solid var(--line); border-radius: 8px; padding: 2rem 1.5rem; text-align: center; transition: border-color .2s; }
.member:hover { border-color: var(--blue); }
.avatar { position: relative; width: 120px; height: 120px; margin: 0 auto 1.25rem; border-radius: 50%; background: var(--navy); border: 4px solid var(--white); box-shadow: 0 0 0 3px var(--green); overflow: hidden; display: grid; place-items: center; }
.avatar span { font-family: var(--head); font-weight: 700; font-size: 2.1rem; color: var(--white); letter-spacing: 0.04em; }
.avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.member h3 { font-size: 1.1rem; margin-bottom: 0.25rem; }
.member .role { color: var(--blue); font-weight: 600; font-size: 0.85rem; margin-bottom: 0.75rem; }
.member p:last-child { font-size: 0.88rem; }

@media (max-width: 1100px) { .dep-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 900px) { .sec-head { grid-template-columns: 1fr; gap: 1rem; } .team-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .team-grid, .dep-grid { grid-template-columns: 1fr; } }

/* ---------- Faculty rows (homepage preview + overview page) ---------- */
.fac-rows { display: grid; border-top: 1px solid var(--line); }
.fac-row { display: grid; grid-template-columns: 56px 1fr auto; gap: 1.25rem; align-items: center; padding: 1.15rem 0.75rem; border-bottom: 1px solid var(--line); text-decoration: none; transition: background .15s; }
.fac-row:hover, .fac-row[aria-current] { background: var(--navy); }
.fac-row-no { font-family: var(--head); font-weight: 700; font-size: 1.35rem; color: var(--blue); }
.fac-row-text b { display: block; font-family: var(--head); font-size: 1rem; color: var(--navy); }
.fac-row-text small { font-size: 0.86rem; }
.fac-row-go { font-size: 0.8rem; font-weight: 600; color: var(--blue); white-space: nowrap; }
.fac-row-go::after { content: ' →'; }
.fac-row:hover *, .fac-row[aria-current] * { color: var(--white); }
.fac-row:hover .fac-row-no { color: var(--green); }

.fac-preview { padding: 4.5rem 0; }
.fac-preview-grid { display: grid; grid-template-columns: 0.8fr 1.6fr; gap: 3rem; align-items: start; }
.fac-preview-intro { position: sticky; top: 100px; background: var(--navy); color: var(--white); border-radius: 10px; padding: 2rem; }
.fac-preview-intro h2 { color: var(--white); font-size: clamp(1.6rem, 2.6vw, 2.1rem); margin-bottom: 0.9rem; }
.fac-preview-intro p:not(.label) { font-size: 0.92rem; margin-bottom: 1.5rem; }
.fac-preview-intro .label { color: var(--white); }
.fac-preview-intro .label::before { background: var(--green); }
.fac-index { padding: 3.5rem 0 4.5rem; }

/* ---------- Faculty page ---------- */
.page-hero { background: var(--navy); color: var(--white); border-bottom: 4px solid var(--green); }
.ph-grid { display: grid; grid-template-columns: 1fr; gap: 3rem; align-items: center; }
.page-hero.has-media .ph-grid { grid-template-columns: 1.15fr 0.85fr; }
.ph-text { padding: 3.25rem 0; }
.crumbs { display: flex; flex-wrap: wrap; gap: 0.5rem; font-size: 0.8rem; margin-bottom: 1.5rem; }
.crumbs a { text-decoration: none; }
.crumbs a:hover { color: var(--green); }
.crumbs span { opacity: .5; }
.ph-kicker { font-size: 0.78rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--green); margin-bottom: 0.75rem; }
.page-hero h1 { color: var(--white); font-size: clamp(1.8rem, 3.4vw, 2.6rem); max-width: 22ch; margin-bottom: 1rem; }
.page-hero .lead { max-width: 40rem; margin-bottom: 1.75rem; }
.ph-media { align-self: stretch; display: flex; align-items: center; padding: 2rem 0; }
.ph-media img { width: 100%; max-height: 320px; object-fit: cover; border-radius: 8px; border: 3px solid var(--white); background: var(--blue); }

.subnav { position: sticky; top: 73px; z-index: 40; background: var(--white); border-bottom: 1px solid var(--line); }
.subnav .container { display: flex; gap: 0.25rem; overflow-x: auto; scrollbar-width: none; }
.subnav a { padding: 0.95rem 0.9rem; font-size: 0.85rem; font-weight: 600; color: var(--navy); text-decoration: none; white-space: nowrap; border-bottom: 3px solid transparent; }
.subnav a:hover { color: var(--blue); border-bottom-color: var(--blue); }

.fac-layout { display: grid; grid-template-columns: 1fr 320px; gap: 3rem; padding: 3rem 0 4.5rem; align-items: start; }
.fp-sec { padding: 2.25rem 0; border-bottom: 1px solid var(--line); scroll-margin-top: 140px; }
.fp-sec:first-child { padding-top: 0; }
.fp-sec:last-child { border-bottom: 0; }
.fp-sec h2 { font-size: clamp(1.35rem, 2vw, 1.65rem); margin-bottom: 1.1rem; }
.fp-sec > p:not(.label):not(.note) { margin-bottom: 1rem; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 8px; }
.prog-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.prog-table th { background: var(--navy); color: var(--white); text-align: left; font-weight: 600; padding: 0.8rem 1rem; }
.prog-table td { padding: 0.8rem 1rem; border-top: 1px solid var(--line); vertical-align: top; }
.prog-table td:first-child { font-weight: 600; color: var(--navy); }
.prog-table tbody tr:hover { background: rgba(30,99,196,0.06); }
.tag { display: inline-block; padding: 0.15rem 0.6rem; border-radius: 999px; border: 1px solid var(--blue); color: var(--blue); font-size: 0.75rem; font-weight: 600; white-space: nowrap; }
.note { margin-top: 0.9rem; font-size: 0.85rem; padding-left: 0.9rem; border-left: 3px solid var(--green); }
.check-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; }
.check-grid li { position: relative; padding: 0.8rem 0.9rem 0.8rem 2.4rem; border: 1px solid var(--line); border-radius: 6px; font-size: 0.9rem; }
.check-grid li::before { content: ''; position: absolute; left: 0.95rem; top: 1.05rem; width: 10px; height: 5px; border-left: 2px solid var(--green); border-bottom: 2px solid var(--green); transform: rotate(-45deg); }
.chips { display: flex; flex-wrap: wrap; gap: 0.6rem; }
.chips li { padding: 0.5rem 1rem; border-radius: 999px; background: var(--navy); color: var(--white); font-size: 0.85rem; font-weight: 500; }
.two-col { columns: 2; column-gap: 2rem; }
.steps { list-style: none; margin: 0; padding: 0; counter-reset: st; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; }
.steps li { counter-increment: st; position: relative; padding: 1.25rem; border-top: 4px solid var(--blue); background: rgba(30,99,196,0.06); font-size: 0.86rem; }
.steps li::before { content: counter(st, decimal-leading-zero); display: block; font-family: var(--head); font-weight: 700; font-size: 1.3rem; color: var(--blue); margin-bottom: 0.5rem; }
.steps b { display: block; font-family: var(--head); color: var(--navy); margin-bottom: 0.3rem; }

.fac-side { position: sticky; top: 140px; display: grid; gap: 1.25rem; }
.side-card { border: 1px solid var(--line); border-radius: 8px; padding: 1.4rem; }
.side-card h3 { font-size: 1rem; margin-bottom: 1rem; }
.side-card dl { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: 0.55rem 1rem; font-size: 0.85rem; }
.side-card dt { font-weight: 600; color: var(--navy); }
.side-card dd { margin: 0; text-align: right; }
.side-cta { background: var(--navy); color: var(--white); border-color: var(--navy); }
.side-cta h3 { color: var(--white); }
.side-cta p { font-size: 0.88rem; margin-bottom: 1rem; }
.side-cta .btn { width: 100%; justify-content: center; margin-bottom: 0.75rem; }
.side-link { display: block; font-size: 0.84rem; text-decoration: none; padding: 0.3rem 0; word-break: break-all; }
.side-link:hover { color: var(--green); }
.side-others a { display: flex; gap: 0.75rem; padding: 0.6rem 0; border-top: 1px solid var(--line); font-size: 0.85rem; text-decoration: none; color: var(--navy); }
.side-others a:hover { color: var(--blue); }
.side-others a span { font-family: var(--head); font-weight: 700; color: var(--blue); }

@media (max-width: 1000px) {
  .fac-layout { grid-template-columns: 1fr; }
  .fac-side { position: static; grid-template-columns: repeat(2, 1fr); }
  .side-others { grid-column: 1 / -1; }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .fac-preview-grid { grid-template-columns: 1fr; gap: 2rem; }
  .fac-preview-intro { position: static; }
}
@media (max-width: 900px) {
  .page-hero.has-media .ph-grid { grid-template-columns: 1fr; gap: 0; }
  .ph-media { padding: 0 0 2rem; }
  .subnav { top: 0; position: relative; }
}
@media (max-width: 640px) {
  .fac-row { grid-template-columns: 40px 1fr; padding: 1rem 0.25rem; }
  .fac-row-go { display: none; }
  .check-grid, .steps, .fac-side { grid-template-columns: 1fr; }
  .two-col { columns: 1; }
}
.fac-layout > * { min-width: 0; }

/* ---------- Menu dropdowns (hover on desktop, click everywhere) ---------- */
.header-inner { position: relative; }
.main-nav { align-items: center; }
.nav-item { position: static; }
.drop-toggle { display: inline-flex; align-items: center; gap: 0.35rem; background: none; border: 0; border-bottom: 2px solid transparent; padding: 0.5rem 0.7rem; font: inherit; font-size: 0.86rem; font-weight: 500; color: var(--black); cursor: pointer; }
.drop-toggle::after { content: ''; width: 6px; height: 6px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: translateY(-2px) rotate(45deg); transition: transform .2s; }
.nav-item.is-active > .drop-toggle, .drop-toggle:hover, .nav-item.open > .drop-toggle { color: var(--blue); border-bottom-color: var(--blue); }
.nav-item.open > .drop-toggle::after { transform: translateY(1px) rotate(-135deg); }
.drop { position: absolute; left: 0; right: 0; top: 100%; z-index: 70; background: var(--white); border: 1px solid var(--line); border-top: 3px solid var(--blue); border-radius: 0 0 10px 10px; box-shadow: 0 18px 40px rgba(13,43,94,0.18); padding: 1.5rem; opacity: 0; visibility: hidden; transform: translateY(8px); transition: opacity .18s, transform .18s, visibility .18s; }
.nav-item.open > .drop { opacity: 1; visibility: visible; transform: none; }
@media (hover: hover) and (min-width: 901px) {
  .nav-item:hover > .drop { opacity: 1; visibility: visible; transform: none; }
  .nav-item:hover > .drop-toggle { color: var(--blue); border-bottom-color: var(--blue); }
}
.drop-head { display: flex; justify-content: space-between; align-items: baseline; padding-bottom: 0.9rem; margin-bottom: 0.9rem; border-bottom: 1px solid var(--line); }
.drop-head b { font-family: var(--head); color: var(--navy); font-size: 1rem; }
.drop-head a { font-size: 0.82rem; font-weight: 600; color: var(--blue); text-decoration: none; }
.drop-head a::after { content: ' →'; }
.drop-grid { display: grid; gap: 0.5rem; }
.drop-grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.drop-grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
.main-nav .drop-link { display: flex; gap: 0.8rem; align-items: flex-start; padding: 0.85rem; border: 1px solid transparent; border-bottom: 1px solid transparent; border-radius: 8px; text-decoration: none; }
.main-nav .drop-link:hover { background: var(--navy); border-color: var(--navy); }
.drop-no { font-family: var(--head); font-weight: 700; color: var(--blue); font-size: 1rem; line-height: 1.3; }
.drop-link b { display: block; font-family: var(--head); font-size: 0.88rem; color: var(--navy); line-height: 1.3; margin-bottom: 0.2rem; }
.drop-link small { display: block; font-size: 0.78rem; color: var(--black); line-height: 1.4; }
.drop-link:hover b, .drop-link:hover small { color: var(--white); }
.drop-link:hover .drop-no { color: var(--green); }

@media (max-width: 900px) {
  .main-nav { align-items: stretch; }
  .main-nav > a, .drop-toggle { width: 100%; justify-content: space-between; padding: 0.8rem 0.25rem; border-bottom: 1px solid var(--line); }
  .drop { position: static; display: none; opacity: 1; visibility: visible; transform: none; box-shadow: none; border: 0; border-radius: 0; padding: 0.5rem 0 0.75rem; }
  .nav-item.open > .drop { display: block; }
  .drop-grid.cols-3, .drop-grid.cols-4 { grid-template-columns: 1fr; }
  .drop-link small { display: none; }
}

/* ---------- Department cards as links ---------- */
.dep { text-decoration: none; color: var(--white); }
.dep-go { margin-top: 1rem; font-size: 0.82rem; font-weight: 600; color: var(--green); }
.dep-go::after { content: ' →'; }
.dep:hover .dep-go { color: var(--white); }

/* ---------- Department page ---------- */
.svc-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; }
.svc { border: 1px solid var(--line); border-left: 4px solid var(--blue); border-radius: 6px; padding: 1.2rem 1.3rem; }
.svc:hover { border-left-color: var(--green); }
.svc h3 { font-size: 1rem; margin-bottom: 0.4rem; }
.svc p { font-size: 0.88rem; }
.head-card { text-align: center; }
.head-card h3 { text-align: left; }
.avatar.sm { width: 96px; height: 96px; margin-bottom: 0.9rem; }
.avatar.sm span { font-size: 1.6rem; }
.head-card > b { display: block; font-family: var(--head); color: var(--navy); }
.head-card > small { display: block; color: var(--blue); font-weight: 600; font-size: 0.82rem; margin-bottom: 0.75rem; }
@media (max-width: 640px) { .svc-grid { grid-template-columns: 1fr; } }

/* ---------- Academics mega menu ---------- */
.drop.mega { display: grid; grid-template-columns: repeat(3, 1fr) 1.1fr; padding: 0; background: var(--white); border-top: 3px solid var(--navy); }
.mega-col { padding: 1.5rem 1.5rem 1.75rem; border-left: 1px solid var(--line); }
.mega-col:first-child { border-left: 0; }
.mega-col h4 { font-family: var(--head); font-size: 0.8rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--navy); padding-bottom: 0.55rem; margin: 0 0 0.9rem; border-bottom: 3px solid var(--green); }
.main-nav .mega-col > a:not(.btn) { display: block; padding: 0.42rem 0; border: 0; font-size: 0.88rem; font-weight: 600; color: var(--blue); line-height: 1.4; text-decoration: none; }
.main-nav .mega-col > a:not(.btn):hover { color: var(--navy); text-decoration: underline; text-underline-offset: 3px; }
.mega-cta { background: var(--navy); color: var(--white); border-left: 0; border-radius: 0 0 10px 0; }
.mega-cta h4 { color: var(--white); }
.mega-cta p { font-size: 0.86rem; margin-bottom: 1.1rem; }
.main-nav .mega-cta .btn { padding: 0.6rem 1.1rem; border-bottom: 0; color: var(--white); }
.main-nav .mega-cta .mega-tel { display: block; margin-top: 0.85rem; font-size: 0.85rem; color: var(--white); border: 0; text-decoration: none; }
@media (max-width: 900px) {
  .nav-item.open > .drop.mega { display: block; }
  .mega-col { border-left: 0; padding: 0.75rem 0.25rem; }
  .mega-cta { border-radius: 8px; padding: 1.25rem; margin-top: 0.5rem; }
}
.main-nav .mega-col.mega-cta > a.mega-tel { color: var(--white); font-weight: 500; } .main-nav .mega-col.mega-cta > a.mega-tel:hover { color: var(--green); }
.drop.mega { grid-template-columns: repeat(var(--cols, 3), 1fr) 1.1fr; }

/* ---------- Course search ---------- */
.search-bar { display: flex; flex-wrap: wrap; gap: 0.6rem; align-items: center; margin-bottom: 1rem; }
.search-bar input, .search-bar select { font: inherit; font-size: 0.9rem; padding: 0.7rem 0.9rem; border: 1px solid rgba(13,43,94,0.3); border-radius: 6px; background: var(--white); color: var(--black); }
.search-bar input { flex: 1 1 260px; }
.search-bar input:focus, .search-bar select:focus { outline: 2px solid var(--blue); outline-offset: -1px; }
.search-count { font-size: 0.82rem; font-weight: 600; color: var(--blue); margin-left: auto; }
.search-empty { margin-top: 1rem; padding: 1rem; border: 1px dashed var(--blue); border-radius: 6px; font-size: 0.9rem; }
.prog-table td a { color: var(--blue); font-weight: 500; }
.search-page { padding: 3rem 0 4.5rem; }
.search-page .fp-sec:first-child { padding-top: 0; }

/* ---------- News ---------- */
.news-list { display: grid; gap: 1rem; }
.news-item { border-left: 4px solid var(--blue); padding: 0.75rem 1rem; }
.news-item time { font-size: 0.78rem; font-weight: 700; color: var(--green); }
.news-item h3 { font-size: 1rem; margin: 0.2rem 0 0.35rem; }
.news-item p { font-size: 0.88rem; }
.news-item small { font-size: 0.75rem; color: var(--blue); font-weight: 600; }
.news-empty { padding: 1.4rem; border: 1px dashed rgba(13,43,94,0.35); border-radius: 8px; }
.news-empty b { display: block; font-family: var(--head); color: var(--navy); margin-bottom: 0.3rem; }
.news-empty p { font-size: 0.88rem; }

/* ---------- Head of department ---------- */
.hod { display: grid; grid-template-columns: 140px 1fr; gap: 1.75rem; align-items: start; padding: 1.5rem; border: 1px solid var(--line); border-radius: 8px; margin-bottom: 1rem; }
.hod .avatar { margin: 0; width: 130px; height: 130px; }
.hod-text small { font-size: 0.72rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--green); }
.hod-text h3 { font-size: 1.25rem; margin: 0.2rem 0 0.15rem; }
.hod-role { color: var(--blue); font-weight: 600; font-size: 0.88rem; margin-bottom: 0.75rem; }
.hod-text p:not(.hod-role) { font-size: 0.92rem; margin-bottom: 0.8rem; }
.hod-link { font-size: 0.85rem; font-weight: 600; color: var(--blue); text-decoration: none; }
.hod-link::after { content: ' →'; }

/* ---------- Students & applicants ---------- */
.res-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.res { border: 1px solid var(--line); border-top: 4px solid var(--navy); border-radius: 8px; padding: 1.3rem; scroll-margin-top: 120px; }
.res-top { display: flex; justify-content: space-between; align-items: center; gap: 0.5rem; margin-bottom: 0.5rem; }
.res h3 { font-size: 1rem; }
.res p { font-size: 0.88rem; }
.tag.soon { border-color: var(--green); color: var(--green); }
.apply-form { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; padding: 1.75rem; border: 1px solid var(--line); border-top: 4px solid var(--blue); border-radius: 8px; }
.apply-form label { display: grid; gap: 0.35rem; font-size: 0.85rem; font-weight: 600; color: var(--navy); }
.apply-form .full, .apply-form button, .apply-form small { grid-column: 1 / -1; }
.apply-form input, .apply-form select, .apply-form textarea { font: inherit; font-weight: 400; padding: 0.75rem; border: 1px solid rgba(13,43,94,0.3); border-radius: 6px; color: var(--black); background: var(--white); }
.apply-form input:focus, .apply-form select:focus, .apply-form textarea:focus { outline: 2px solid var(--blue); outline-offset: -1px; }
.apply-form button { justify-self: start; }
@media (max-width: 900px) { .res-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 640px) {
  .res-grid, .apply-form { grid-template-columns: 1fr; }
  .hod { grid-template-columns: 1fr; text-align: center; }
  .hod .avatar { margin: 0 auto; }
  .search-count { margin-left: 0; }
}

/* ---------- Mega menu: refined, full-width ---------- */
@media (min-width: 901px) {
  .header-inner { position: static; }
  .site-header .drop.mega {
    left: 0; right: 0; top: 100%;
    padding: 0 max(1rem, calc((100% - 1200px) / 2));
    border: 0; border-top: 1px solid var(--line); border-bottom: 3px solid var(--navy);
    border-radius: 0; box-shadow: 0 16px 32px rgba(13, 43, 94, 0.10);
    transform: translateY(-4px);
  }
  .nav-item.open > .drop.mega, .nav-item:hover > .drop.mega { transform: none; }
  .mega-col { padding: 2rem 2rem 2.25rem; }
  .mega-col:first-child { padding-left: 0; }
}
.mega-col h4 {
  font-family: var(--body); font-size: 0.72rem; font-weight: 700; letter-spacing: 0.14em;
  color: var(--blue); border-bottom: 1px solid var(--line); padding-bottom: 0.75rem; margin-bottom: 0.75rem;
}
.main-nav .mega-col > a:not(.btn) {
  position: relative; padding: 0.5rem 0 0.5rem 0; font-size: 0.9rem; font-weight: 500;
  color: var(--navy); transition: color .15s, padding-left .15s;
}
.main-nav .mega-col > a:not(.btn)::before {
  content: ''; position: absolute; left: 0; top: 50%; width: 0; height: 2px; background: var(--green); transition: width .15s;
}
.main-nav .mega-col > a:not(.btn):hover { color: var(--blue); text-decoration: none; padding-left: 0.9rem; }
.main-nav .mega-col > a:not(.btn):hover::before { width: 0.55rem; }
.mega-cta { border-radius: 0; margin: 1.25rem 0; padding: 1.75rem !important; }
.mega-cta h4 { color: var(--white); border-bottom-color: rgba(255,255,255,0.2); }
.mega-cta p { line-height: 1.55; }
.drop-toggle { font-weight: 500; }
@media (max-width: 900px) {
  .mega-col h4 { margin-top: 0.5rem; }
  .mega-cta { margin: 0.75rem 0 0; }
}
.drop-toggle::after { content: none; display: none; }

/* ---------- Faculty banner ---------- */
.page-hero.banner { position: relative; overflow: hidden; }
.page-hero.banner .ph-grid { grid-template-columns: 1fr; }
.page-hero.banner .ph-text { position: relative; z-index: 1; max-width: 560px; padding: 4.5rem 0 5rem; }
.ph-banner {
  position: absolute; top: 0; right: 0; bottom: 0; width: 58%;
  background: url('faculty-banner.jpg') center 22% / cover no-repeat;
  -webkit-mask-image: linear-gradient(to right, transparent 0, #000 38%);
          mask-image: linear-gradient(to right, transparent 0, #000 38%);
}
.page-hero.banner::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 4px; background: var(--green); z-index: 2; }
@media (max-width: 900px) {
  .page-hero.banner .ph-text { max-width: none; padding: 3rem 0 2rem; }
  .ph-banner { position: relative; display: block; width: 100%; height: 260px; -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 30%); mask-image: linear-gradient(to bottom, transparent 0, #000 30%); }
}
@media (min-width: 901px) {
  .ph-banner { width: 55%; background-position: left 22%;
    -webkit-mask-image: linear-gradient(to right, transparent 0, #000 9%); mask-image: linear-gradient(to right, transparent 0, #000 9%); }
  .page-hero.banner .ph-text { max-width: 500px; }
  .page-hero.banner h1 { font-size: clamp(1.8rem, 3vw, 2.4rem); }
}

/* ---------- Faculty banner: circular photo with rings ---------- */
.page-hero.banner { min-height: 520px; display: flex; align-items: center; }
.page-hero.banner > .container { width: min(1200px, calc(100% - 2rem)); }
.ph-banner {
  -webkit-mask-image: none !important; mask-image: none !important;
  position: absolute; top: 50%; right: max(2rem, calc((100% - 1200px) / 2 + 2rem)); left: auto; bottom: auto;
  width: 400px; height: 400px; transform: translateY(-50%);
  border-radius: 50%;
  background: #ffffff url('faculty-banner.jpg') center 30% / 112% auto no-repeat;
  box-shadow: 0 0 0 8px var(--navy), 0 0 0 13px var(--green), 0 20px 50px rgba(0,0,0,0.35);
}
.page-hero.banner::before {
  content: ''; position: absolute; top: 50%; right: max(2rem, calc((100% - 1200px) / 2 + 2rem));
  width: 400px; height: 400px; transform: translate(42px, -50%) scale(1.22); transform-origin: center;
  border-radius: 50%; border: 2px dashed rgba(30, 99, 196, 0.7);
  margin-right: 42px; pointer-events: none;
}
@media (max-width: 1100px) and (min-width: 901px) {
  .ph-banner, .page-hero.banner::before { width: 320px; height: 320px; }
  .page-hero.banner .ph-text { max-width: 440px; }
}
@media (max-width: 900px) {
  .page-hero.banner { display: block; min-height: 0; padding-bottom: 2.5rem; }
  .page-hero.banner::before { display: none; }
  .ph-banner { position: relative; top: auto; right: auto; transform: none; width: 240px; height: 240px; margin: 0.5rem auto 0; display: block; }
}

.res-link { display: inline-block; margin-top: 0.85rem; font-size: 0.85rem; font-weight: 600; color: var(--blue); text-decoration: none; }
.res-link::after { content: ' →'; }
.res-link:hover { color: var(--navy); }
/* Fit 8 menu items */
@media (min-width: 901px) and (max-width: 1280px) {
  .main-nav > a, .drop-toggle { padding: 0.5rem 0.5rem; font-size: 0.82rem; }
  .header-inner { gap: 1rem; }
  .brand b { font-size: 1.25rem; }
}
@media (min-width: 901px) and (max-width: 1080px) { .header-cta { display: none; } }

/* Banner photo: oval frame that matches the photo, so it fills with no white bands */
@media (min-width: 901px) {
  .ph-banner, .page-hero.banner::before { width: 470px; height: 395px; }
  .ph-banner { background: url('faculty-banner.jpg') center / cover no-repeat; }
}
@media (max-width: 1100px) and (min-width: 901px) {
  .ph-banner, .page-hero.banner::before { width: 380px; height: 320px; }
}
@media (max-width: 900px) {
  .ph-banner { width: 290px; height: 244px; background: url('faculty-banner.jpg') center / cover no-repeat; }
}

/* Banner photo: true circle, whole group visible, edges filled with a soft blur of the photo (no white bands) */
@media (min-width: 901px) {
  .ph-banner, .page-hero.banner::before { width: 420px; height: 420px; }
}
@media (max-width: 1100px) and (min-width: 901px) {
  .ph-banner, .page-hero.banner::before { width: 340px; height: 340px; }
}
.ph-banner { overflow: hidden; background: var(--navy) !important; isolation: isolate; }
.ph-banner::before, .ph-banner::after { content: ''; position: absolute; inset: 0; border-radius: 50%; }
.ph-banner::before { background: url('faculty-banner.jpg') center / cover no-repeat; filter: blur(18px) brightness(0.95); transform: scale(1.25); z-index: -1; }
.ph-banner::after { background: url('faculty-banner.jpg') center 58% / 96% auto no-repeat; }
@media (max-width: 900px) { .ph-banner { width: 260px !important; height: 260px !important; } }
/* Square version of the photo (wall extended above the group) fills the circle with nobody cut off */
.ph-banner::before { content: none; }
.ph-banner::after { background: url('faculty-banner-circle.jpg') center / cover no-repeat; }

/* ---------- Resource centre ---------- */
.res-centre .fac-layout { padding-top: 2.5rem; }
.res-tools { display: grid; gap: 1rem; padding-bottom: 1.25rem; border-bottom: 1px solid var(--line); margin-bottom: 0.5rem; }
#res-q { font: inherit; font-size: 0.95rem; padding: 0.85rem 1rem; border: 1px solid rgba(13,43,94,0.3); border-radius: 6px; }
#res-q:focus { outline: 2px solid var(--blue); outline-offset: -1px; }
.chip-row { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.chip-btn { font: inherit; font-size: 0.84rem; font-weight: 600; padding: 0.5rem 1rem; border-radius: 999px; border: 1px solid var(--navy); background: var(--white); color: var(--navy); cursor: pointer; scroll-margin-top: 140px; }
.chip-btn:hover { border-color: var(--blue); color: var(--blue); }
.chip-btn.is-on { background: var(--navy); color: var(--white); }
.res-count { font-size: 0.82rem; font-weight: 600; color: var(--blue); }
.rr-list { list-style: none; margin: 0; padding: 0; }
.rr { display: grid; grid-template-columns: 96px 1fr 170px 130px; gap: 1.25rem; align-items: center; padding: 1.15rem 0; border-bottom: 1px solid var(--line); }
.rr-kind { justify-self: start; font-size: 0.7rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--blue); border: 1px solid var(--blue); border-radius: 4px; padding: 0.2rem 0.5rem; }
.rr-main h3 { font-size: 1rem; margin-bottom: 0.2rem; }
.rr-main p { font-size: 0.86rem; }
.rr-meta { font-size: 0.8rem; line-height: 1.4; }
.rr-meta b { display: block; color: var(--navy); font-weight: 600; }
.rr-btn { justify-self: end; padding: 0.5rem 1.1rem; font-size: 0.82rem; }
.rr-soon { justify-self: end; font-size: 0.78rem; font-weight: 600; color: var(--green); border: 1px solid var(--green); border-radius: 999px; padding: 0.35rem 0.85rem; white-space: nowrap; }
.rr:has(.rr-soon) .rr-main h3 { color: rgba(13,43,94,0.75); }
@media (max-width: 700px) {
  .rr { grid-template-columns: 1fr auto; gap: 0.5rem 1rem; }
  .rr-kind { grid-column: 1 / -1; }
  .rr-meta { grid-column: 1; grid-row: 3; }
  .rr-btn, .rr-soon { grid-column: 2; grid-row: 2 / 4; align-self: center; }
}

/* =========================================================
   Hero banner variants: one distinct look per section
   ========================================================= */
.page-hero { position: relative; overflow: hidden; }
.page-hero.has-side .ph-grid { grid-template-columns: 1.1fr 0.9fr; gap: 3rem; align-items: center; }
.page-hero.has-side .ph-text { padding: 3.75rem 0 4rem; }
.page-hero > .container { position: relative; z-index: 1; }
.hv-side { justify-self: end; width: 100%; max-width: 440px; }

/* background patterns (white at low opacity, brand only) */
.page-hero.hv-grid { background-image:
  linear-gradient(rgba(255,255,255,0.06) 1px, transparent 1px),
  linear-gradient(90deg, rgba(255,255,255,0.06) 1px, transparent 1px);
  background-size: 36px 36px; }
.page-hero.hv-dots { background-image: radial-gradient(rgba(255,255,255,0.12) 1.5px, transparent 1.5px); background-size: 22px 22px; }
.page-hero.hv-stripes { background-image: repeating-linear-gradient(135deg, rgba(255,255,255,0.05) 0 14px, transparent 14px 34px); }
.page-hero.hv-circuit::before, .page-hero.hv-person::before {
  content: ''; position: absolute; inset: 0; opacity: 0.12; pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120' fill='none' stroke='white' stroke-width='1.5'%3E%3Cpath d='M0 30h40l10 10h30M120 90H80l-10-10H40M60 0v20l10 10M60 120v-20l-10-10'/%3E%3Ccircle cx='80' cy='40' r='3'/%3E%3Ccircle cx='40' cy='80' r='3'/%3E%3Ccircle cx='70' cy='30' r='3'/%3E%3Ccircle cx='50' cy='90' r='3'/%3E%3C/svg%3E");
}
.page-hero.hv-shelf::after { content: ''; position: absolute; right: -120px; top: -120px; width: 420px; height: 420px; border-radius: 50%; border: 2px solid rgba(255,255,255,0.08); }

/* stats panel (Course Search, Resources) */
.hv-stats { display: grid; grid-template-columns: 1fr 1fr; border: 1px solid rgba(255,255,255,0.2); border-radius: 10px; overflow: hidden; background: rgba(13,43,94,0.6); }
.hv-stats div { padding: 1.4rem 1.5rem; border-right: 1px solid rgba(255,255,255,0.15); border-bottom: 1px solid rgba(255,255,255,0.15); }
.hv-stats div:nth-child(2n) { border-right: 0; }
.hv-stats div:nth-last-child(-n+2) { border-bottom: 0; }
.hv-stats b { display: block; font-family: var(--head); font-size: 2.4rem; line-height: 1; color: var(--white); }
.hv-stats div:first-child b { color: var(--green); }
.hv-stats span { display: block; margin-top: 0.4rem; font-size: 0.82rem; }

/* steps panel (Applicants) */
.hv-steps { list-style: none; margin: 0; padding: 0.5rem 0; background: var(--white); border-radius: 10px; border-top: 4px solid var(--green); box-shadow: 0 20px 45px rgba(0,0,0,0.25); }
.hv-steps li { display: flex; align-items: center; gap: 1rem; padding: 0.95rem 1.4rem; color: var(--navy); font-family: var(--head); font-weight: 600; border-bottom: 1px solid var(--line); position: relative; }
.hv-steps li:last-child { border-bottom: 0; }
.hv-steps span { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: var(--navy); color: var(--white); font-size: 0.8rem; flex-shrink: 0; }
.hv-steps li:first-child span { background: var(--green); }

/* angled photo (Students) */
.hv-photo { position: relative; padding: 0 0 18px 18px; }
.hv-photo::before { content: ''; position: absolute; left: 0; bottom: 0; width: 72%; height: 72%; border: 3px solid var(--green); border-radius: 10px; }
.hv-photo img { position: relative; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 10px; clip-path: polygon(10% 0, 100% 0, 100% 100%, 0 100%, 0 14%); }

/* news card (News) */
.hv-news-card { position: relative; background: var(--white); color: var(--black); border-radius: 10px; padding: 2rem 1.75rem 1.75rem; border-left: 5px solid var(--blue); box-shadow: 0 20px 45px rgba(0,0,0,0.25); }
.hv-news-card .hv-tag { position: absolute; top: -12px; left: 1.5rem; background: var(--green); color: var(--white); font-size: 0.72rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; padding: 0.3rem 0.75rem; border-radius: 999px; }
.hv-news-card small { display: block; font-size: 0.75rem; font-weight: 700; color: var(--blue); letter-spacing: 0.06em; text-transform: uppercase; }
.hv-news-card b { display: block; font-family: var(--head); font-size: 1.25rem; color: var(--navy); margin: 0.35rem 0 0.5rem; }
.hv-news-card p { font-size: 0.9rem; }

/* bookshelf (Library) */
.hv-shelf { display: grid; gap: 1.25rem; }
.shelf-row { display: flex; align-items: flex-end; gap: 6px; height: 120px; padding: 0 0.5rem; border-bottom: 6px solid var(--green); }
.shelf-row i { flex: 1; height: var(--h); background: var(--c); border-radius: 3px 3px 0 0; opacity: 0.9; }
.shelf-row:nth-child(2) i:nth-child(odd) { height: calc(var(--h) * 0.85); }
.shelf-row i:nth-child(3n) { box-shadow: inset 0 10px 0 rgba(13,43,94,0.25), inset 0 -10px 0 rgba(13,43,94,0.25); }

/* head of department (Department pages) */
.hv-person-card { display: flex; flex-direction: column; align-items: center; gap: 1.1rem; }
.avatar.xl { width: 230px; height: 230px; margin: 0; border: 6px solid var(--navy); box-shadow: 0 0 0 4px var(--green), 0 0 0 14px rgba(255,255,255,0.08), 0 20px 45px rgba(0,0,0,0.3); }
.avatar.xl span { font-size: 3.2rem; }
.hv-caption { text-align: center; background: var(--white); border-radius: 8px; padding: 0.8rem 1.4rem; border-bottom: 3px solid var(--green); }
.hv-caption small { display: block; font-size: 0.68rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--blue); }
.hv-caption b { display: block; font-family: var(--head); color: var(--navy); font-size: 1.05rem; }
.hv-caption span { font-size: 0.8rem; color: var(--black); }

/* all heads (Departments overview) */
.hv-people-card { background: rgba(13,43,94,0.6); border: 1px solid rgba(255,255,255,0.2); border-radius: 10px; padding: 1.75rem; }
.hv-faces { display: flex; justify-content: center; margin-bottom: 1.25rem; }
.avatar.md { width: 92px; height: 92px; margin: 0 -10px; border: 4px solid var(--navy); box-shadow: 0 0 0 3px var(--green); }
.avatar.md span { font-size: 1.4rem; }
.hv-people-card ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem 1rem; font-size: 0.8rem; }
.hv-people-card li b { display: block; font-family: var(--head); font-size: 0.9rem; color: var(--white); }

@media (max-width: 900px) {
  .page-hero.has-side .ph-grid { grid-template-columns: 1fr; gap: 0; }
  .page-hero.has-side .ph-text { padding: 3rem 0 2rem; }
  .hv-side { justify-self: stretch; max-width: none; margin-bottom: 2.5rem; }
  .avatar.xl { width: 180px; height: 180px; }
  .hv-photo img { aspect-ratio: 16 / 10; }
}
@media (max-width: 480px) { .hv-stats b { font-size: 1.9rem; } .avatar.md { width: 72px; height: 72px; } }

/* ---------- Fine-tuning ---------- */
:focus-visible { outline: 3px solid var(--green); outline-offset: 2px; }
.page-hero .lead { line-height: 1.65; }
.site-footer ul a { display: inline-block; padding: 0.1rem 0; }
.fp-sec h2 { letter-spacing: -0.01em; }
.btn { line-height: 1.2; }
img { height: auto; }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; } }
.search-bar select { flex: 1 1 160px; min-width: 0; max-width: 100%; } .search-page .container > * { min-width: 0; }
.page-hero.hv-person .ph-grid { padding: 2.75rem 0; }
.page-hero.hv-person .ph-text { padding: 1rem 0; }
.page-hero.hv-pic { background-image: radial-gradient(rgba(255,255,255,0.1) 1.5px, transparent 1.5px); background-size: 26px 26px; }
@media (max-width: 900px) { .page-hero.hv-person .ph-grid { padding: 0; } }
@media (max-width: 900px) { .page-hero.hv-person .ph-text { padding: 2.5rem 0 2rem; } }
.team-page { padding: 3rem 0 4.5rem; }
.team-page .fp-sec:first-child { padding-top: 0; }
.member .hod-link { display: inline-block; margin-top: 0.75rem; }
.hod-text .hod-link + .hod-link { margin-left: 1.25rem; }
@media (min-width: 1001px) { #leaders .team-grid { grid-template-columns: repeat(4, 1fr); gap: 1.25rem; } #leaders .member { padding: 1.75rem 1.1rem; } }
@media (min-width: 641px) and (max-width: 1000px) { #leaders .team-grid { grid-template-columns: repeat(2, 1fr); } }

/* full-width photo banners (the banner artwork carries the page title) */
.img-hero { background: var(--navy); line-height: 0; }
.img-hero img { display: block; width: 100%; height: auto; max-height: 560px; object-fit: cover; object-position: center; }
.img-hero-link { display: block; }
.page-hero.hero-strip { padding: 1.75rem 0 2rem; }
.page-hero.hero-strip h1 { font-size: clamp(1.4rem, 2.4vw, 1.9rem); max-width: none; margin-bottom: .5rem; }
.page-hero.hero-strip .lead { margin-bottom: 1.1rem; }
.hero.hero-plain .hero-inner { max-width: 760px; }
.hero.hero-plain { padding: 3rem 0; }
.main-nav .nav-portal { font-weight: 700; }
.apply-online p { max-width: 44rem; }
@media (max-width: 720px) { .img-hero img { max-height: none; } }
.hero.hero-plain, .page-hero.hero-strip { min-height: 0; }
.hero.hero-plain .hero-inner, .page-hero.hero-strip .ph-text { padding: 0; max-width: 820px; }
@media (max-width: 720px) { .hero.hero-plain { padding: 2rem 0; } .page-hero.hero-strip { padding: 1.25rem 0 1.5rem; } }
/* phones: show the photo side of each banner (the page title is in the strip below) */
@media (max-width: 720px) {
  .img-hero img { height: 190px; max-height: none; object-fit: cover; object-position: right center; }
}
/* phones: the banner artwork's built-in text is too small to read, so phones get the clean text header only */
@media (max-width: 720px) { .img-hero { display: none; } .page-hero.hero-strip { padding-top: 1.75rem; } }
/* computers and tablets: the banner already shows the title and text, so the strip below is kept only for screen readers and search engines */
@media (min-width: 721px) {
  .page-hero.hero-strip { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0; padding: 0; }
  .img-hero { border-bottom: 4px solid var(--green); }
}
/* phones: the banner photo becomes the background of the text header, with a dark layer so the text reads clearly */
@media (max-width: 720px) {
  .page-hero.hero-strip, .hero.hero-plain { position: relative; background-color: var(--navy); background-image: var(--hero-bg); background-size: cover; background-position: right center; isolation: isolate; }
  .page-hero.hero-strip::before, .hero.hero-plain::before { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(10, 25, 70, .9), rgba(10, 25, 70, .84)); z-index: -1; }
  .page-hero.hero-strip { padding: 2.25rem 0 2.5rem; }
}
/* cards: a quiet outline and soft shadow instead of coloured bars across the top */
.card, .res, .apply-form { border: 1px solid var(--line); border-top: 1px solid var(--line); box-shadow: 0 6px 18px rgba(13, 43, 94, 0.06); }
.steps li { border-top: 0; border-radius: 8px; }
.hv-steps { border-top: 0; }
/* computers and tablets: the homepage banner stands alone; the text introduction is the phone header */
@media (min-width: 721px) { .hero.hero-plain { display: none; } }

/* social media icons in the footer */
.socials { display: flex; gap: .5rem; flex-wrap: wrap; }
.socials a { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 50%; background: rgba(255,255,255,.1); color: #fff; transition: background .2s, transform .2s; }
.socials a:hover { background: var(--green); transform: translateY(-2px); }
.socials svg { width: 18px; height: 18px; fill: currentColor; }
