/* ============================================================
   ME Community v2.0 — Premium Education Portal Design System
   ============================================================ */

/* ── 1. Design Tokens ─────────────────────────────────────── */
:root {
  /* Brand */
  --mc-primary:          #006ad0;
  --mc-primary-dark:     #003b73;
  --mc-primary-midnight: #071f3d;
  --mc-accent:           #006ad0;
  --mc-accent-dark-text: #ffffff;

  /* Page surfaces */
  --mc-bg:      #eef6ff;
  --mc-surface: #ffffff;
  --mc-text:    #132238;
  --mc-muted:   #667085;
  --mc-line:    rgba(0, 64, 128, 0.12);

  /* Elevation */
  --mc-shadow-sm: 0 1px 4px rgba(0, 40, 96, 0.08);
  --mc-shadow-md: 0 4px 20px rgba(0, 40, 96, 0.10);

  /* ── Legacy aliases kept for Customizer inline injection ── */
  --mc-blue:      var(--mc-primary);
  --mc-blue-dark: var(--mc-primary-dark);
  --mc-blue-soft: #dceeff;
  --mc-ink:       var(--mc-text);
  --mc-gold:      var(--mc-accent);
  --mc-green:     #006ad0;
  --mc-orange:    #004f9d;
  --mc-shadow:    var(--mc-shadow-md);

  /* ── Academic alias bridge ── */
  --theme-yellow:      var(--mc-accent);
  --theme-yellow-deep: #c49a00;
  --theme-black:       var(--mc-primary);
  --theme-white:       #ffffff;
  --theme-soft:        var(--mc-bg);
  --theme-muted:       var(--mc-muted);
  --theme-line:        var(--mc-line);
  --theme-shadow:      var(--mc-shadow-sm);
}

/* ── 2. Reset ─────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  font-family: "Sarabun", "Noto Sans Thai", Arial, sans-serif;
  color: var(--mc-text);
  background: var(--mc-bg);
  line-height: 1.65;
  font-weight: 400;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }

/* ── 3. Typography ────────────────────────────────────────── */
h1, h2, h3, h4, h5, h6 {
  margin-top: 0;
  font-weight: 800;
  line-height: 1.2;
  color: var(--mc-text);
}
p, li, address { margin-top: 0; }
h1 { margin-bottom: 14px; color: var(--mc-primary-dark); }
h2 { margin-bottom: 16px; color: var(--mc-primary-dark); }
h3 { margin-bottom: 8px; }

.section-kicker,
.eyebrow {
  display: inline-block;
  margin: 0 0 14px;
  border-radius: 999px;
  padding: 5px 14px;
  color: var(--mc-accent-dark-text);
  background: var(--mc-accent);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

/* ── 4. Layout Utilities ──────────────────────────────────── */
.container { width: min(1180px, calc(100% - 32px)); margin: 0 auto; }
.section { padding-block: clamp(56px, 8vw, 96px); }
.section-heading { margin-bottom: clamp(28px, 4vw, 48px); }
.text-link {
  color: var(--mc-primary);
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* ── 5. Site Header ───────────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.97);
  border-bottom: 1px solid var(--mc-line);
  box-shadow: var(--mc-shadow-sm);
  backdrop-filter: blur(16px);
}

/* Topbar */
.top-strip {
  color: #fff;
  background: var(--mc-primary);
  font-size: 13px;
  font-weight: 600;
}
.top-strip-inner {
  min-height: 34px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.top-strip a { color: rgba(255, 255, 255, 0.90); font-weight: 700; }
.top-strip a:hover { color: var(--mc-accent); }

/* Navbar */
.nav-bar {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.brand { display: flex; align-items: center; gap: 14px; min-width: 0; }
.brand img, .custom-logo { width: 88px; height: 58px; object-fit: contain; }
.brand span { display: grid; line-height: 1.3; }
.brand strong { color: var(--mc-primary-dark); font-size: 17px; font-weight: 800; }
.brand small { color: var(--mc-muted); font-size: 12px; font-weight: 500; }

.main-nav, .menu-list {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--mc-text);
  font-size: 15px;
  font-weight: 700;
}
.main-nav a, .menu-list > li > a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  border-radius: 8px;
  padding: 8px 14px;
  transition: background 0.15s, color 0.15s;
}
.main-nav a:hover,
.main-nav a:focus-visible,
.menu-list > li > a:hover,
.menu-list > li > a:focus-visible {
  color: var(--mc-accent-dark-text);
  background: var(--mc-accent);
  outline: none;
}
.main-nav a.current-menu-item,
.menu-list .current-menu-item > a {
  color: var(--mc-accent-dark-text);
  background: var(--mc-accent);
}

/* ── 6. Buttons ───────────────────────────────────────────── */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  border-radius: 8px;
  padding: 12px 24px;
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
  border: none;
  text-decoration: none;
  transition: opacity 0.15s, transform 0.12s;
  font-family: inherit;
}
.button:hover { opacity: 0.92; }
.button:active { transform: scale(0.98); }

/* All CTA variants → yellow with dark navy text */
.button.primary,
.button.secondary,
.button.light {
  background: var(--mc-accent);
  color: var(--mc-accent-dark-text);
}

/* Explicit blue variant */
.button.blue {
  background: var(--mc-primary);
  color: #fff;
}

/* ── 7. Hero Section ──────────────────────────────────────── */
.academic-hero {
  position: relative;
  min-height: 520px;
  overflow: hidden;
  background:
    linear-gradient(
      90deg,
      rgba(0, 59, 115, 0.94) 0%,
      rgba(0, 106, 208, 0.70) 55%,
      rgba(0, 106, 208, 0.28) 100%
    ),
    var(--hero-image, linear-gradient(135deg, #003b73, #006ad0));
  background-size: cover;
  background-position: center;
  border-bottom: 1px solid var(--mc-line);
}

/* Subtle dot-grid texture */
.academic-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle at 1px 1px, rgba(255, 255, 255, 0.07) 1px, transparent 0);
  background-size: 20px 20px;
  pointer-events: none;
}

.hero-link { position: absolute; inset: 0; z-index: 1; }

.academic-hero-inner {
  position: relative;
  z-index: 2;
  min-height: 520px;
  display: grid;
  align-content: center;
  justify-items: center;
  text-align: center;
  padding-block: clamp(48px, 7vw, 80px);
  pointer-events: none;
}

.academic-hero-inner .section-kicker,
.academic-hero-inner .eyebrow {
  background: rgba(255, 255, 255, 0.92);
  color: var(--mc-primary-dark);
}

.academic-hero h1 {
  max-width: 860px;
  margin: 0 0 14px;
  color: #fff;
  font-size: clamp(30px, 4.5vw, 54px);
  line-height: 1.14;
  font-weight: 800;
}

.academic-hero p {
  max-width: 640px;
  margin: 0;
  color: rgba(255, 255, 255, 0.90);
  font-size: clamp(15px, 1.8vw, 19px);
  font-weight: 400;
}

.academic-hero .hero-actions {
  margin-top: 32px;
  pointer-events: auto;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}

/* ── 8. Intro Grid: Announcements + Statistics ────────────── */
.academic-intro-grid {
  padding: clamp(36px, 5vw, 56px) 0;
  background: var(--mc-surface);
  border-bottom: 1px solid var(--mc-line);
}

.intro-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(20px, 3vw, 32px);
}

.portal-panel {
  padding: 22px;
  background: var(--mc-surface);
  border-radius: 8px;
  border: 1px solid var(--mc-line);
}

/* Panel title row */
.panel-title-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}
.panel-title-row h2,
.academic-widget-card h2 {
  position: relative;
  margin: 0;
  color: var(--mc-text);
  font-size: 17px;
  line-height: 1.3;
  font-weight: 700;
}
.panel-title-row h2::after,
.academic-widget-card h2::after,
.site-footer h2::after {
  content: "";
  display: block;
  width: 34px;
  height: 3px;
  margin-top: 8px;
  background: var(--mc-accent);
  border-radius: 2px;
}
.panel-title-row a,
.news-title-row a {
  color: var(--mc-primary);
  font-size: 13px;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 3px;
  white-space: nowrap;
}
.panel-title-row a:hover,
.news-title-row a:hover { color: var(--mc-primary-dark); }

/* Announcement list – refined, borderless rows */
.announcement-list { display: grid; gap: 0; }
.announcement-list a {
  display: grid;
  grid-template-columns: 1fr;
  min-height: 44px;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--mc-line);
  color: var(--mc-text);
  font-size: 14.5px;
  font-weight: 500;
  line-height: 1.5;
  transition: color 0.15s;
}
.announcement-list a:last-child { border-bottom: none; }
.announcement-list a.has-thumb { grid-template-columns: 52px 1fr; gap: 12px; }
.announcement-list img {
  width: 52px;
  height: 38px;
  border-radius: 5px;
  object-fit: cover;
  background: var(--mc-bg);
  display: block;
}
.announcement-list a:hover { color: var(--mc-primary); }

/* Statistics */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}
.stat-card {
  min-height: 78px;
  display: grid;
  place-items: center;
  padding: 12px 8px;
  text-align: center;
  border-radius: 8px;
  background: var(--mc-bg);
}
.stat-card strong {
  display: block;
  color: var(--mc-primary);
  font-size: 22px;
  line-height: 1;
  font-weight: 800;
}
.stat-card span {
  display: block;
  margin-top: 4px;
  color: var(--mc-muted);
  font-size: 11.5px;
  font-weight: 500;
}

/* ── 9. Activity News Section ─────────────────────────────── */
.academic-news-section {
  padding: clamp(48px, 7vw, 80px) 0;
  background: var(--mc-surface);
  border-bottom: 1px solid var(--mc-line);
}

.news-title-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: clamp(22px, 3vw, 36px);
}
.news-title-row h2 {
  margin: 0;
  color: var(--mc-text);
  font-size: clamp(18px, 2.2vw, 24px);
  font-weight: 800;
}

.academic-news-grid {
  display: grid;
  gap: clamp(18px, 3vw, 28px);
  grid-template-columns: 1fr;
}

.academic-news-card {
  overflow: hidden;
  border-radius: 8px;
  background: var(--mc-surface);
  border: 1px solid var(--mc-line);
  transition: box-shadow 0.2s, transform 0.2s;
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.academic-news-card:hover {
  box-shadow: var(--mc-shadow-md);
  transform: translateY(-2px);
}
.academic-news-card a {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  overflow: hidden;
  color: inherit;
}

.news-thumb {
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--mc-bg);
  flex-shrink: 0;
}
.news-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }

.academic-news-card h3 {
  display: -webkit-box;
  margin: 14px 16px 6px;
  overflow: hidden;
  color: var(--mc-text);
  font-size: 15.5px;
  line-height: 1.5;
  font-weight: 700;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.academic-news-card p {
  display: -webkit-box;
  margin: 0 16px 16px;
  overflow: hidden;
  color: var(--mc-muted);
  font-size: 13.5px;
  font-weight: 400;
  line-height: 1.55;
  max-height: calc(13.5px * 1.55 * 2);
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

/* ── 10. Widget Section ───────────────────────────────────── */
.academic-widget-section {
  padding: clamp(48px, 7vw, 80px) 0;
  background: var(--mc-bg);
}

.academic-widget-grid {
  display: grid;
  gap: clamp(18px, 3vw, 28px);
  grid-template-columns: 1fr;
}

.academic-widget-card {
  border-radius: 8px;
  background: var(--mc-surface);
  border: 1px solid var(--mc-line);
  padding: 20px;
  display: flex;
  flex-direction: column;
}

.widget-content {
  margin-top: 14px;
  border-radius: 6px;
  overflow: hidden;
  background: var(--mc-bg);
  border: 1px solid var(--mc-line);
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: stretch;
}

/* Responsive iframe */
.widget-content iframe {
  width: 100%;
  height: auto;
  display: block;
  border: 0;
  flex-shrink: 0;
}
/* YouTube – 16:9 ratio */
.widget-content iframe[src*="youtube"] {
  aspect-ratio: 16 / 9;
}
/* Facebook Page Plugin – fill remaining height */
.widget-content iframe[src*="facebook"] {
  aspect-ratio: unset;
  flex: 1;
  min-height: 300px;
}
.widget-content:has(iframe) {
  background: transparent;
  border: none;
}
.widget-content:has(iframe[src*="facebook"]) {
  background: var(--mc-surface);
}

/* Calendar mock */
.calendar-mock { width: 100%; padding: 16px; display: grid; gap: 12px; align-self: flex-start; }
.calendar-mock strong { color: var(--mc-primary); font-size: 15px; font-weight: 800; }
.calendar-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
.calendar-grid span {
  min-height: 28px;
  display: grid;
  place-items: center;
  border-radius: 5px;
  color: var(--mc-muted);
  background: var(--mc-surface);
  font-size: 12px;
  font-weight: 500;
}
.calendar-grid .cal-blank { background: transparent; }
.calendar-grid .is-today { outline: 2px solid var(--mc-primary); outline-offset: -2px; font-weight: 700; }
.calendar-grid .is-event { color: #fff; background: var(--mc-primary); cursor: default; }
.calendar-grid .is-event.is-today { outline-color: #fff; }
.calendar-event-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--mc-line);
  padding-top: 10px;
  display: grid;
  gap: 6px;
}
.calendar-event-list li {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--mc-text);
}
.calendar-event-list .event-day {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--mc-primary);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 11px;
  font-weight: 700;
}

/* YouTube / Facebook mocks */
.youtube-mock, .facebook-mock {
  min-height: 150px;
  display: grid;
  place-items: center;
  gap: 8px;
  padding: 20px;
  text-align: center;
}
.youtube-mock span {
  width: 58px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #fff;
  background: #ff0000;
  font-size: 20px;
}
.youtube-mock strong, .facebook-mock strong { color: var(--mc-primary); font-size: 15px; font-weight: 800; }
.youtube-mock small, .facebook-mock span { color: var(--mc-muted); font-size: 13px; font-weight: 400; }
.facebook-mock a {
  display: inline-block;
  border-radius: 6px;
  padding: 8px 16px;
  color: #fff;
  background: #1877f2;
  font-weight: 700;
  font-size: 14px;
}

/* ── 11. Footer ───────────────────────────────────────────── */
.site-footer {
  background: var(--mc-primary-midnight);
  color: rgba(255, 255, 255, 0.82);
  padding-block: clamp(48px, 7vw, 80px);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(32px, 5vw, 56px);
}

.footer-logo {
  width: 96px;
  height: 60px;
  object-fit: contain;
  object-position: left center;
  margin-bottom: 16px;
}

.site-footer h2 {
  margin-bottom: 12px;
  color: #ffffff;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.site-footer h2::after { margin-top: 8px; }

.site-footer p,
.site-footer address {
  margin: 0;
  color: rgba(255, 255, 255, 0.70);
  font-style: normal;
  font-size: 14px;
  line-height: 1.7;
  font-weight: 400;
}

.footer-stats p { margin-bottom: 3px; }

.footer-links { display: grid; align-content: start; gap: 6px; }

.site-footer a {
  color: rgba(255, 255, 255, 0.80);
  font-size: 14px;
  font-weight: 500;
  transition: color 0.15s;
}
.site-footer a:hover { color: #ffffff; }

/* ── 12. Floating Chat ────────────────────────────────────── */
.floating-chat {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 70;
  display: grid;
  gap: 8px;
}
.floating-chat a {
  min-width: 96px;
  border-radius: 999px;
  padding: 10px 14px;
  color: #fff;
  font-weight: 700;
  font-size: 14px;
  text-align: center;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.18);
}
.chat-line { background: #06c755; }
.chat-facebook { background: #1877f2; }

/* ── 13. Popup ────────────────────────────────────────────── */
.mc-popup {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(7, 31, 61, 0.72);
}
.mc-popup.is-hidden { display: none !important; }
.mc-popup-card {
  position: relative;
  width: min(600px, 100%);
  border-radius: 10px;
  padding: 32px;
  background: #fff;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.18);
}
.mc-popup-card h2 { font-size: 24px; color: var(--mc-text); }
.mc-popup-body { margin-bottom: 20px; color: var(--mc-muted); font-size: 16px; font-weight: 400; }
.mc-popup-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 50%;
  color: var(--mc-text);
  background: var(--mc-bg);
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  display: grid;
  place-items: center;
}

.mc-popup--cpt { padding: 16px; }
.mc-popup-card--image {
  padding: 0;
  overflow: hidden;
  width: min(var(--popup-w, 600px), calc(100vw - 32px));
}
.mc-popup-card--image .mc-popup-close {
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  backdrop-filter: blur(4px);
}
.mc-popup-img-wrap { display: block; line-height: 0; }
.mc-popup-img {
  width: 100%;
  height: auto;
  display: block;
  max-height: 80vh;
  object-fit: contain;
}

/* ── 14. Contact Page ─────────────────────────────────────── */
.contact-page { background: var(--mc-bg); }

.contact-hero {
  padding: clamp(56px, 8vw, 90px) 0;
  background:
    linear-gradient(90deg, rgba(0, 59, 115, 0.95), rgba(0, 106, 208, 0.72)),
    url("../images/mockups/pr-news-1.jpg");
  background-size: cover;
  background-position: center;
}
.contact-hero .section-kicker,
.contact-hero .eyebrow {
  background: rgba(255, 255, 255, 0.15);
  color: rgba(255, 255, 255, 0.95);
}
.contact-hero h1 {
  margin: 10px 0 12px;
  color: #fff;
  font-size: clamp(28px, 4vw, 46px);
  line-height: 1.1;
}
.contact-hero p {
  max-width: 600px;
  margin: 0;
  color: rgba(255, 255, 255, 0.88);
  font-size: 16px;
  font-weight: 400;
}

.contact-shell { padding: clamp(48px, 7vw, 80px) 0; }

.contact-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(28px, 5vw, 48px);
}

/* Base form-wrap (outside .contact-page context) */
.mc-contact-form-wrap {
  border-radius: 8px;
  padding: 24px;
  background: var(--mc-surface);
  border: 1px solid var(--mc-line);
}

/* Contact page form card */
.contact-page .mc-contact-form-wrap {
  position: relative;
  overflow: hidden;
  border-radius: 10px;
  padding: clamp(24px, 4vw, 40px);
  background: var(--mc-surface);
  border: 1px solid var(--mc-line);
  box-shadow: var(--mc-shadow-md);
  max-width: none;
}
.contact-page .mc-contact-form-wrap::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 4px;
  background: var(--mc-accent);
}

.contact-page .section-kicker,
.contact-page .eyebrow {
  background: var(--mc-bg);
  color: var(--mc-primary);
}
.contact-page .section-heading { margin-bottom: 22px; }
.contact-page .section-heading h2 {
  color: var(--mc-text);
  font-size: clamp(20px, 2.5vw, 26px);
}
.contact-page .section-heading p {
  color: var(--mc-muted);
  font-size: 15px;
  font-weight: 400;
}

.form-grid { display: grid; gap: 16px; }

.mc-contact-form { display: grid; gap: 16px; }
.mc-contact-form label {
  display: grid;
  gap: 6px;
  color: var(--mc-text);
  font-size: 14px;
  font-weight: 700;
}
.contact-page .mc-contact-form span { color: #d92d20; }

.contact-page .mc-contact-form input,
.contact-page .mc-contact-form textarea,
.contact-page .mc-contact-form select {
  width: 100%;
  min-height: 48px;
  border: 1px solid rgba(0, 64, 128, 0.20);
  border-radius: 8px;
  padding: 12px 14px;
  font: inherit;
  font-size: 15px;
  font-weight: 400;
  color: var(--mc-text);
  background: var(--mc-surface);
  transition: border-color 0.15s, box-shadow 0.15s;
  appearance: auto;
}
.contact-page .mc-contact-form input:focus,
.contact-page .mc-contact-form textarea:focus,
.contact-page .mc-contact-form select:focus {
  border-color: var(--mc-primary);
  outline: none;
  box-shadow: 0 0 0 3px rgba(0, 106, 208, 0.12);
}
.contact-page .mc-contact-form textarea { min-height: 140px; resize: vertical; }

.form-success {
  margin-bottom: 18px;
  border-radius: 8px;
  padding: 14px 16px;
  color: #067647;
  background: #d1fadf;
  font-weight: 700;
  font-size: 15px;
}

/* Contact info card */
.contact-info-card {
  position: relative;
  overflow: hidden;
  border-radius: 10px;
  padding: clamp(24px, 4vw, 36px);
  background: var(--mc-surface);
  border: 1px solid var(--mc-line);
  box-shadow: var(--mc-shadow-md);
}
.contact-info-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 4px;
  background: var(--mc-accent);
}
.contact-info-card h2 { color: var(--mc-text); font-size: clamp(17px, 2vw, 22px); }

.contact-info-list { display: grid; gap: 20px; margin-top: 20px; }
.contact-info-item {
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 14px;
  align-items: start;
}

/* SVG outline icon container */
.contact-icon {
  width: 48px;
  height: 48px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  border: 1px solid rgba(0, 106, 208, 0.18);
  border-radius: 999px;
  color: var(--mc-primary);
  background: rgba(0, 106, 208, 0.06);
}
.contact-icon svg {
  width: 22px;
  height: 22px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.contact-info-item small {
  display: block;
  margin-bottom: 3px;
  color: var(--mc-muted);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.contact-info-item strong {
  display: block;
  color: var(--mc-text);
  font-size: 14.5px;
  font-weight: 600;
  line-height: 1.6;
}
.contact-info-item a {
  display: inline-flex;
  margin-top: 6px;
  color: var(--mc-primary);
  font-size: 13px;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.contact-info-item a:hover { color: var(--mc-primary-dark); }

.office-hours {
  margin-top: 24px;
  border-radius: 8px;
  padding: 20px 22px;
  background: var(--mc-primary-midnight);
}
.office-hours h3 { margin-bottom: 12px; color: #fff; font-size: 17px; font-weight: 800; }
.office-hours div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.office-hours span,
.office-hours strong { color: rgba(255, 255, 255, 0.88); font-size: 15px; font-weight: 600; }

/* ── 15. Content Area (single posts / pages) ──────────────── */
.content-area { background: var(--mc-bg); }
.entry-card {
  border-radius: 8px;
  padding: 32px;
  background: var(--mc-surface);
  border: 1px solid var(--mc-line);
  box-shadow: var(--mc-shadow-sm);
}
.custom-html-section { background: var(--mc-surface); }
.custom-html-content {
  border: 1px solid var(--mc-line);
  border-radius: 8px;
  padding: 24px;
  background: var(--mc-surface);
}

/* ── 16. Accessibility & Focus ────────────────────────────── */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid rgba(243, 213, 91, 0.9);
  outline-offset: 3px;
  border-radius: 3px;
}

/* ── 17. Responsive ───────────────────────────────────────── */

/* Tablet (640px+) */
@media (min-width: 640px) {
  .intro-grid { grid-template-columns: minmax(0, 1fr) minmax(300px, .85fr); }
  .academic-news-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .academic-widget-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Desktop (1024px+) */
@media (min-width: 1024px) {
  .academic-news-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .academic-widget-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .footer-grid { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) minmax(0, .85fr); }
  .contact-grid { grid-template-columns: minmax(0, 1.15fr) minmax(360px, 0.85fr); }
}

/* ── 20. Archive / Category Page ─────────────────────────── */
.archive-page { background: var(--mc-bg); }

.archive-hero {
  padding: clamp(40px, 6vw, 70px) 0;
  background: linear-gradient(90deg, rgba(0, 59, 115, 0.95), rgba(0, 106, 208, 0.72));
}
.archive-hero .section-kicker {
  background: rgba(255, 255, 255, 0.15);
  color: rgba(255, 255, 255, 0.9);
}
.archive-hero h1 {
  color: #fff;
  font-size: clamp(24px, 3.5vw, 40px);
  margin: 10px 0 0;
}
.archive-hero p { color: rgba(255,255,255,0.85); margin: 8px 0 0; }

.archive-pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 40px;
}
.archive-pagination .nav-links { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.archive-pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  border-radius: 8px;
  padding: 0 12px;
  background: var(--mc-surface);
  color: var(--mc-primary);
  font-weight: 600;
  font-size: 14px;
  border: 1px solid var(--mc-line);
  text-decoration: none;
  transition: background 0.15s, color 0.15s;
}
.archive-pagination .page-numbers:hover,
.archive-pagination .page-numbers.current {
  background: var(--mc-primary);
  color: #fff;
  border-color: var(--mc-primary);
}
.archive-empty { color: var(--mc-muted); padding: 40px 0; text-align: center; }

/* ── 21. Single Post Page ─────────────────────────────────── */
.single-post-page { background: var(--mc-bg); }

.single-entry {
  max-width: 800px;
  margin: 0 auto;
  background: var(--mc-surface);
  border-radius: 16px;
  padding: clamp(24px, 4vw, 48px);
  box-shadow: var(--mc-shadow-sm);
}

.single-breadcrumb {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--mc-muted);
  margin-bottom: 20px;
}
.single-breadcrumb a { color: var(--mc-primary); text-decoration: none; }
.single-breadcrumb a:hover { text-decoration: underline; }

.single-entry h1 {
  font-size: clamp(20px, 3vw, 34px);
  color: var(--mc-text);
  line-height: 1.3;
  margin: 0 0 16px;
}

.single-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}
.single-meta time { font-size: 13px; color: var(--mc-muted); }
.single-meta .section-kicker { margin: 0; }

.single-thumb {
  margin-bottom: 32px;
  border-radius: 10px;
  overflow: hidden;
  line-height: 0;
}
.single-thumb img { width: 100%; height: auto; display: block; }

.entry-content {
  font-size: 16px;
  line-height: 1.85;
  color: var(--mc-text);
}
.entry-content p { margin: 0 0 18px; }
.entry-content p:last-child { margin-bottom: 0; }
.entry-content img { max-width: 100%; height: auto; border-radius: 8px; margin: 8px 0; }
.entry-content h2,.entry-content h3 { color: var(--mc-primary); margin: 28px 0 12px; }
.entry-content ul,.entry-content ol { padding-left: 24px; margin: 0 0 18px; }
.entry-content li { margin-bottom: 6px; }
.entry-content a { color: var(--mc-primary); }
.entry-content blockquote {
  border-left: 4px solid var(--mc-primary);
  margin: 20px 0;
  padding: 12px 20px;
  background: var(--mc-bg);
  border-radius: 0 8px 8px 0;
  color: var(--mc-muted);
  font-style: italic;
}

.single-footer {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid var(--mc-line);
}

/* ── 22. About Page ───────────────────────────────────────── */
.about-page { background: var(--mc-bg); }

.about-hero {
  padding: clamp(56px, 8vw, 90px) 0;
  background:
    linear-gradient(90deg, rgba(0, 59, 115, 0.95), rgba(0, 106, 208, 0.72)),
    url("../images/mockups/pr-news-1.jpg");
  background-size: cover;
  background-position: center;
}
.about-hero .section-kicker {
  background: rgba(255, 255, 255, 0.15);
  color: rgba(255, 255, 255, 0.95);
}
.about-hero h1 {
  margin: 10px 0 12px;
  color: #fff;
  font-size: clamp(26px, 4vw, 44px);
  line-height: 1.15;
}
.about-hero p {
  max-width: 640px;
  margin: 0;
  color: rgba(255, 255, 255, 0.88);
  font-size: 16px;
}

.about-content-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
  align-items: start;
}
.about-body { font-size: 16px; line-height: 1.8; color: var(--mc-text); }
.about-body p { margin: 0 0 18px; }
.about-body p:last-child { margin-bottom: 0; }
.about-image-wrap img {
  width: 100%;
  border-radius: 12px;
  box-shadow: var(--mc-shadow-md);
  display: block;
}

.about-cards-section { background: var(--mc-surface); }
.about-cards-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}
.about-card { padding: 28px 24px; }
.about-card h2 {
  font-size: clamp(16px, 2vw, 20px);
  color: var(--mc-primary);
  margin: 0 0 12px;
}
.about-card p { font-size: 15px; line-height: 1.7; color: var(--mc-muted); margin: 0; }

@media (min-width: 640px) {
  .about-content-grid { grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); }
  .about-cards-grid   { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* Mobile (<640px) */
@media (max-width: 639px) {
  .nav-bar { align-items: flex-start; flex-direction: column; padding: 14px 0; gap: 12px; }
  .main-nav, .menu-list { width: 100%; justify-content: flex-start; }
  .brand img, .custom-logo { width: 72px; height: 46px; }
  .brand strong { font-size: 16px; }
  .academic-hero, .academic-hero-inner { min-height: 400px; }
  .container { width: min(100%, calc(100% - 24px)); }
  .news-title-row,
  .panel-title-row { flex-direction: column; align-items: flex-start; gap: 8px; }
  .contact-hero h1 { font-size: 30px; }
  .office-hours div { flex-direction: column; align-items: flex-start; }
  .stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .top-strip-inner { flex-direction: column; align-items: flex-start; gap: 4px; padding: 8px 0; }
  .hero-actions { flex-direction: column; align-items: stretch; }
  .hero-actions .button { justify-content: center; }
}
