/* ============================================================================
   PBMT Design Tokens
   Palette (overridable from admin/settings): Primary #C2185B (pink) /
   Secondary #FCE4EC (light pink) / Accent #2E7D32 (green) / Background #FAFAFA
   Direction: Modern Government UI + Apple-style — glassmorphism, rounded
   corners, soft shadow, minimal/compact type scale, card design, gradients,
   micro-interactions. Font sizes are intentionally on the small/dense side.
   ============================================================================ */

:root {
  --pbmt-primary: #C2185B;
  --pbmt-primary-dark: #8E1345;
  --pbmt-secondary: #FCE4EC;
  --pbmt-accent: #2E7D32;
  --pbmt-accent-dark: #1B5E20;
  --pbmt-bg: #FAFAFA;
  --pbmt-ink: #24262B;
  --pbmt-ink-soft: #6B6F76;
  --pbmt-radius-lg: 24px;
  --pbmt-radius-md: 16px;
  --pbmt-radius-sm: 10px;
  --pbmt-shadow-soft: 0 10px 30px rgba(194, 24, 91, 0.08), 0 2px 8px rgba(0,0,0,0.04);
  --pbmt-shadow-lift: 0 20px 45px rgba(194, 24, 91, 0.14), 0 4px 12px rgba(0,0,0,0.06);
  --pbmt-gradient-hero: linear-gradient(135deg, var(--pbmt-primary) 0%, #E9457F 45%, var(--pbmt-accent) 100%);
  --pbmt-gradient-soft: linear-gradient(135deg, rgba(194,24,91,0.10), rgba(46,125,50,0.08));
  --pbmt-gradient-footer: linear-gradient(115deg, var(--pbmt-primary-dark) 0%, var(--pbmt-primary) 38%, var(--pbmt-accent) 100%);
  --font-display: 'Prompt', sans-serif;
  --font-body: 'Sarabun', 'Noto Sans Thai', sans-serif;
  --fs-base: 0.92rem;
  --pbmt-gold: #C9A227;
  --pbmt-gold-light: #E8C766;
}

@import url('fonts.css');

* { box-sizing: border-box; }
html {
  scroll-behavior: smooth;
  /* Fluid root size: 14px at narrow phone widths (~320px) scaling smoothly up to
     16px at desktop widths (~1440px+). Since nearly every font-size in this
     stylesheet is defined in rem, this single rule makes ALL text on the site
     scale automatically with screen size — no per-element breakpoints needed. */
  font-size: clamp(14px, 13.4px + 0.18vw, 16px);
}

body {
  font-family: var(--font-body);
  background: var(--pbmt-bg);
  color: var(--pbmt-ink);
  line-height: 1.65;
  font-size: var(--fs-base);
  overflow-wrap: break-word;
}

h1, h2, h3, h4, h5, h6, .display-font {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.01em;
}
h5 { font-size: 1rem; }
h6 { font-size: 0.9rem; }
p { font-size: 0.92rem; }
.small, small { font-size: 0.8rem !important; }

a { color: var(--pbmt-primary); text-decoration: none; }
a:hover { color: var(--pbmt-primary-dark); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

a:focus-visible, button:focus-visible, input:focus-visible,
textarea:focus-visible, select:focus-visible {
  outline: 3px solid var(--pbmt-accent);
  outline-offset: 2px;
}

/* --- Glassmorphism card base ------------------------------------------------ */
.glass-card {
  background: rgba(255, 255, 255, 0.74);
  backdrop-filter: blur(16px) saturate(160%);
  -webkit-backdrop-filter: blur(16px) saturate(160%);
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: var(--pbmt-radius-lg);
  box-shadow: var(--pbmt-shadow-soft);
  transition: transform .35s ease, box-shadow .35s ease;
}
.glass-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--pbmt-shadow-lift);
}

/* --- Buttons ----------------------------------------------------------------- */
.btn-pbmt {
  background: var(--pbmt-gradient-hero);
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 0.65rem 1.5rem;
  font-weight: 600;
  font-size: 0.86rem;
  box-shadow: 0 8px 20px rgba(194,24,91,0.25);
  transition: transform .25s ease, box-shadow .25s ease;
}
.btn-pbmt:hover {
  color: #fff;
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 12px 26px rgba(194,24,91,0.32);
}
.btn-outline-pbmt {
  border: 2px solid var(--pbmt-primary);
  color: var(--pbmt-primary);
  border-radius: 999px;
  padding: 0.55rem 1.4rem;
  font-weight: 600;
  font-size: 0.86rem;
  background: transparent;
  transition: all .25s ease;
}
.btn-outline-pbmt:hover {
  background: var(--pbmt-primary);
  color: #fff;
}

/* --- Navbar ------------------------------------------------------------------ */
.pbmt-navbar {
  background: rgba(255,255,255,0.82);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(194,24,91,0.08);
  position: sticky;
  top: 0;
  z-index: 1030;
  transition: box-shadow .3s ease;
}
.pbmt-navbar.scrolled { box-shadow: 0 4px 20px rgba(0,0,0,0.06); }
.navbar-logo-img { width: 42px; height: 42px; }
.navbar-brand-text-wrap { display: flex; flex-direction: column; line-height: 1.2; }
.navbar-brand-short { font-family: var(--font-display); font-weight: 700; color: var(--pbmt-primary); font-size: 1.05rem; }
.navbar-brand-long { font-size: 0.62rem; color: var(--pbmt-ink-soft); font-weight: 500; }
.pbmt-navbar .nav-link {
  font-weight: 500;
  font-size: 0.86rem;
  color: var(--pbmt-ink);
  position: relative;
  margin: 0 0.3rem;
}
.pbmt-navbar .nav-link::after {
  content: '';
  position: absolute;
  left: 0; bottom: 2px;
  width: 0; height: 2px;
  background: var(--pbmt-gradient-hero);
  transition: width .25s ease;
}
.pbmt-navbar .nav-link:hover::after,
.pbmt-navbar .nav-link.active::after { width: 100%; }
.pbmt-navbar .nav-link.active { color: var(--pbmt-primary); }
.nav-icon-btn {
  width: 36px; height: 36px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--pbmt-secondary); color: var(--pbmt-primary);
  transition: background .2s ease;
}
.nav-icon-btn:hover { background: var(--pbmt-primary); color: #fff; }

.pbmt-dropdown-menu {
  border: none; border-radius: var(--pbmt-radius-md);
  box-shadow: var(--pbmt-shadow-lift);
  padding: .5rem; margin-top: .5rem !important;
}
.pbmt-dropdown-menu .dropdown-item {
  border-radius: var(--pbmt-radius-sm); font-size: .86rem; padding: .5rem .75rem;
}
.pbmt-dropdown-menu .dropdown-item:hover,
.pbmt-dropdown-menu .dropdown-item.active { background: var(--pbmt-secondary); color: var(--pbmt-primary-dark); }

/* Show submenu on mouse hover (desktop only — touch devices keep the tap-to-open
   behavior from Bootstrap's JS, since hover doesn't make sense there). The margin-top
   above is removed here so there's no gap for the mouse to "fall out" of between the
   nav-link and the menu while moving the cursor down into it. */
@media (min-width: 992px) {
  .pbmt-navbar .nav-item.dropdown:hover > .pbmt-dropdown-menu {
    display: block;
    margin-top: 0 !important;
  }
}

/* --- Hero banner --------------------------------------------------------------- */
.hero-banner {
  position: relative;
  overflow: hidden;
  background-color: var(--pbmt-secondary);
  background-size: cover;
  background-position: center right;
  background-repeat: no-repeat;
  padding: 3rem 0 2.5rem;
}
/* Legibility wash so hero text stays readable over any uploaded background image —
   fades from opaque near the text (left) to transparent toward the illustration (right). */
.hero-banner::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg,
    var(--pbmt-bg) 0%, rgba(255,255,255,0.94) 30%,
    rgba(255,255,255,0.55) 55%, rgba(255,255,255,0.12) 75%, transparent 100%);
  z-index: 1;
}
.hero-banner .container { position: relative; z-index: 2; }
.hero-eyebrow-badge {
  display: inline-flex; align-items: center; gap: .4rem;
  background: var(--pbmt-secondary); color: var(--pbmt-primary-dark);
  border-radius: 999px; padding: .35rem .9rem; font-size: .72rem; font-weight: 600;
}
.hero-banner h1 {
  font-size: clamp(1.5rem, 3.2vw, 2.5rem);
  line-height: 1.25;
}
.hero-banner h1 .hl-pink { color: var(--pbmt-primary); }
.hero-banner h1 .hl-green { color: var(--pbmt-accent); }
.hero-banner .lead { font-size: 0.92rem; color: var(--pbmt-ink-soft); max-width: 560px; }

/* --- Homepage banner carousel (Admin → Banners) ------------------------------------ */
.banner-slide-img {
  width: 100%;
  max-height: 340px;
  min-height: 200px;
  object-fit: contain;
  background: var(--pbmt-gradient-soft);
}
.banner-caption {
  background: rgba(30,18,32,0.55);
  backdrop-filter: blur(4px);
  border-radius: var(--pbmt-radius-md);
  padding: 0.75rem 1.25rem;
  bottom: 1.25rem;
}
.banner-caption h5 { font-size: 1rem; margin-bottom: .15rem; }
.banner-caption p { font-size: 0.8rem; opacity: .9; }
#pbmtBannerCarousel .carousel-indicators [data-bs-target] { background-color: var(--pbmt-primary); }

/* --- Value / quick icon strip ----------------------------------------------- */
.value-icon-card {
  text-align: center;
  padding: 1.4rem 0.9rem;
}
.value-icon-card .icon-wrap {
  width: 52px; height: 52px; margin: 0 auto 0.75rem;
  border-radius: 16px;
  background: var(--pbmt-gradient-soft);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.25rem; color: var(--pbmt-primary);
  transition: transform .3s ease;
}
.value-icon-card:hover .icon-wrap { transform: rotate(-8deg) scale(1.08); }
.value-icon-card .label { font-size: 0.78rem; font-weight: 600; line-height: 1.35; }

/* --- Quick menu cards (used on some inner pages) ---------------------------- */
.quick-menu-card { text-align: center; padding: 1.5rem 1rem; color: var(--pbmt-ink); }
.quick-menu-card .icon-wrap {
  width: 54px; height: 54px; margin: 0 auto 0.8rem;
  border-radius: 16px; background: var(--pbmt-gradient-soft);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.3rem; color: var(--pbmt-primary);
  transition: transform .3s ease;
}
.quick-menu-card:hover .icon-wrap { transform: rotate(-8deg) scale(1.08); }

/* --- Section headings ------------------------------------------------------------ */
.section-eyebrow {
  display: inline-block;
  color: var(--pbmt-accent);
  font-weight: 600;
  letter-spacing: 0.07em;
  font-size: 0.7rem;
  text-transform: uppercase;
  margin-bottom: 0.3rem;
}
.section-title { font-size: clamp(1.2rem, 2.4vw, 1.6rem); margin-bottom: 0.4rem; }
section { padding: 3.25rem 0; }

/* --- News cards ------------------------------------------------------------------ */
.news-card { overflow: hidden; }
.news-card img { height: 150px; width: 100%; object-fit: cover; }
.news-card .card-body { padding: 1.1rem; }
.news-card h5 { font-size: 0.92rem; }
.news-card .badge-cat {
  background: var(--pbmt-secondary);
  color: var(--pbmt-primary-dark);
  border-radius: 999px;
  font-weight: 500;
  font-size: 0.7rem;
  padding: 0.25rem 0.7rem;
}

/* --- Pinned news item: elegant slow-moving gradient border + pin badge -------------- */
.news-item-wrap { display: block; border-radius: var(--pbmt-radius-lg); }
.news-item-pinned {
  padding: 2px;
  border-radius: var(--pbmt-radius-lg);
  background: linear-gradient(120deg, var(--pbmt-primary) 0%, var(--pbmt-accent) 50%, var(--pbmt-primary) 100%);
  background-size: 260% 260%;
  animation: pinnedBorderRun 6s ease infinite;
  box-shadow: 0 6px 18px rgba(194,24,91,0.12);
}
.news-item-pinned .glass-card { background: rgba(255,255,255,0.95); }
@keyframes pinnedBorderRun {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}
.news-pin-badge {
  position: absolute;
  top: -8px; left: -8px;
  width: 26px; height: 26px;
  border-radius: 50%;
  background: var(--pbmt-gradient-hero);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.7rem;
  box-shadow: 0 3px 8px rgba(194,24,91,0.35);
  transform: rotate(-25deg);
  z-index: 2;
}

/* --- Event cards ------------------------------------------------------------------ */
.event-card { display: flex; gap: .85rem; padding: 1rem; align-items: flex-start; }
.event-date-badge {
  min-width: 54px; text-align: center;
  background: linear-gradient(135deg, var(--pbmt-primary) 0%, #E9457F 45%, var(--pbmt-accent) 100%);
  color: #fff; border-radius: var(--pbmt-radius-sm);
  padding: 0.5rem 0.3rem;
}
.event-date-badge-alt {
  background: linear-gradient(135deg, var(--pbmt-accent) 0%, #57B85F 45%, var(--pbmt-primary) 100%);
}
.event-date-badge .day { font-size: 1.2rem; font-weight: 700; line-height: 1; }
.event-date-badge .month { font-size: 0.65rem; }
.event-card h6 { font-size: 0.98rem; }
.event-online-badge {
  display: inline-flex; align-items: center; justify-content: center;
  width: 20px; height: 20px; border-radius: 50%; flex-shrink: 0;
  background: var(--pbmt-gradient-hero); color: #fff; font-size: 0.6rem;
}

/* --- Flexbox truncation fix -------------------------------------------------------- */
/* Long unbroken Thai text (university names, titles) inside a flex row won't actually
   shrink for text-truncate/ellipsis unless the flex item's min-width is reset to 0 —
   the browser default (min-width:auto) instead expands to fit the full text, which was
   pushing the whole page wider than the viewport and causing horizontal scrolling. */
.overflow-hidden { min-width: 0; }
.member-sidebar-item > span:last-child { flex: 1 1 auto; min-width: 0; }

html, body { max-width: 100%; overflow-x: hidden; }

/* --- Committee org-chart layout (committee.php) --------------------------------------- */
.org-chart-title {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(1.5rem, 3vw, 2.1rem);
  color: var(--pbmt-ink); letter-spacing: -0.01em;
}
.org-chart-subtitle { color: var(--pbmt-ink-soft); font-size: .92rem; }
.org-term-badge {
  display: inline-block; background: var(--pbmt-gradient-soft); color: var(--pbmt-primary-dark);
  font-family: var(--font-display); font-size: .68rem; font-weight: 700; letter-spacing: .03em;
  border: 1px solid rgba(194,24,91,0.18);
  border-radius: 999px; padding: .3rem .9rem;
  vertical-align: middle; margin-left: .6rem;
}

.org-tier { display: flex; justify-content: center; flex-wrap: wrap; gap: 2.5rem; margin-bottom: 3rem; position: relative; }
.org-tier-vp { gap: 4rem; }

.org-member { display: flex; flex-direction: column; align-items: center; text-align: center; width: 240px; }

.org-photo {
  width: 140px; height: 175px; border-radius: var(--pbmt-radius-lg); overflow: hidden;
  border: 4px solid #fff; box-shadow: var(--pbmt-shadow-lift);
  margin-bottom: -1.75rem; position: relative; z-index: 2;
}
.org-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }

.org-name-pill {
  background: var(--pbmt-secondary); color: var(--pbmt-primary-dark);
  border-radius: var(--pbmt-radius-md); padding: 2.25rem .9rem .7rem;
  font-family: var(--font-display); font-weight: 700; font-size: .88rem; line-height: 1.4; width: 100%;
}
.org-name-pill span { display: block; font-family: var(--font-body); font-weight: 500; font-size: .74rem; color: var(--pbmt-ink-soft); margin-top: .15rem; }

.org-section { margin-bottom: 3rem; }
.org-section-divider {
  display: flex; align-items: center; text-align: center;
  margin-bottom: 2.5rem;
}
.org-section-divider::before, .org-section-divider::after {
  content: ''; flex: 1; height: 2px; background: var(--pbmt-secondary);
}
.org-section-pill {
  background: var(--pbmt-gradient-hero); color: #fff;
  font-family: var(--font-display); font-weight: 700; font-size: .88rem;
  border-radius: 999px; padding: .5rem 1.5rem; margin: 0 1rem; white-space: nowrap;
}

@media (max-width: 767.98px) {
  .org-tier { gap: 1.5rem; }
  .org-tier-vp { gap: .75rem; }
  .org-member { width: 175px; }
  .org-tier-vp .org-member { width: 145px; }
  .org-photo { width: 100px; height: 125px; }
}

/* --- Homepage: premium "AI-era representative" theme --------------------------------- */
body.homepage-premium-page {
  background: linear-gradient(180deg, #F8F1E3 0%, #F3EAD8 45%, #F6EFE6 100%);
}
.homepage-premium-page .bg-pbmt-soft { background: rgba(255,255,255,0.55); }
.homepage-premium-page .glass-card {
  background: rgba(255,255,255,0.86);
}
.homepage-premium-page .section-title { position: relative; }
.homepage-premium-page .value-icon-card .icon-wrap {
  position: relative;
  box-shadow: 0 0 0 2px rgba(201,162,39,0.35), var(--pbmt-shadow-soft);
}
.homepage-premium-page .value-icon-card .icon-wrap::after {
  content: '';
  position: absolute; inset: -2px; border-radius: inherit;
  border: 1px solid rgba(201,162,39,0.25);
}
.homepage-premium-page .org-term-badge,
.homepage-premium-page .section-eyebrow {
  letter-spacing: .06em;
}
.homepage-premium-page .stats-section {
  position: relative; overflow: hidden;
}
.homepage-premium-page .stats-section::before {
  content: '';
  position: absolute; inset: 0;
  background-image: radial-gradient(rgba(255,255,255,0.14) 1px, transparent 1.5px);
  background-size: 20px 20px;
  pointer-events: none;
}
.homepage-premium-page .stat-number {
  text-shadow: 0 0 18px rgba(232,199,102,0.35);
}
.homepage-premium-page .hero-eyebrow-badge {
  border: 1px solid rgba(201,162,39,0.5);
  box-shadow: 0 0 0 1px rgba(201,162,39,0.15) inset;
}
.homepage-premium-page .hero-banner .btn-pbmt {
  box-shadow: 0 0 0 1px rgba(201,162,39,0.4), 0 10px 24px rgba(0,0,0,0.15);
}

/* --- Committee page: premium "AI-era representative" theme -------------------------- */
.committee-premium-page .org-chart-header {
  position: relative;
  background: linear-gradient(135deg, #1A0E17 0%, var(--pbmt-primary-dark) 55%, #2A0F1E 100%);
  overflow: hidden;
  padding: 4rem 0 5rem;
}
.committee-premium-page .org-chart-header::before {
  content: '';
  position: absolute; inset: 0;
  background-image: radial-gradient(rgba(232,199,102,0.16) 1px, transparent 1.5px);
  background-size: 22px 22px;
  opacity: .6;
}
.committee-premium-page .org-chart-header::after {
  content: '';
  position: absolute; inset: -20% -10% auto -10%; height: 140%;
  background: radial-gradient(circle at 20% 20%, rgba(194,24,91,0.35), transparent 55%),
              radial-gradient(circle at 80% 60%, rgba(46,125,50,0.22), transparent 50%);
  pointer-events: none;
}
.committee-premium-page .org-chart-header .container { position: relative; z-index: 2; }
.committee-premium-page .org-chart-title {
  color: #fff;
  text-shadow: 0 2px 20px rgba(0,0,0,0.25);
}
.committee-premium-page .org-chart-subtitle { color: rgba(255,255,255,0.72); }
.committee-premium-page .org-term-badge {
  background: transparent; color: var(--pbmt-gold-light);
  border: 1px solid rgba(232,199,102,0.55);
  box-shadow: 0 0 16px rgba(201,162,39,0.25) inset;
}

.committee-premium-page .org-photo {
  border: 3px solid var(--pbmt-gold-light);
  box-shadow: 0 0 0 5px rgba(201,162,39,0.14), 0 14px 30px rgba(0,0,0,0.22);
}
.committee-premium-page .org-name-pill {
  background: linear-gradient(160deg, #241019 0%, var(--pbmt-primary-dark) 100%);
  color: #fff;
  position: relative;
}
.committee-premium-page .org-name-pill::before {
  content: '';
  position: absolute; top: 0; left: 18%; right: 18%; height: 2px;
  background: linear-gradient(90deg, transparent, var(--pbmt-gold-light), transparent);
}
.committee-premium-page .org-name-pill span { color: rgba(255,255,255,0.68); }

.committee-premium-page .org-section-divider::before,
.committee-premium-page .org-section-divider::after {
  background: linear-gradient(90deg, transparent, var(--pbmt-gold-light));
}
.committee-premium-page .org-section-divider::after { background: linear-gradient(90deg, var(--pbmt-gold-light), transparent); }
.committee-premium-page .org-section-pill {
  background: #fff; color: var(--pbmt-primary-dark);
  border: 1.5px solid var(--pbmt-gold-light);
  box-shadow: 0 4px 16px rgba(201,162,39,0.18);
}
.committee-premium-page .committee-card-vertical,
.committee-premium-page .glass-card {
  box-shadow: 0 10px 30px rgba(26,14,23,0.1), 0 2px 8px rgba(0,0,0,0.04);
}

/* --- Committee cards: vertical/portrait style ---------------------------------------- */
.committee-card-vertical { overflow: hidden; padding: 0; }
.committee-card-photo { width: 100%; aspect-ratio: 3 / 4; overflow: hidden; background: var(--pbmt-secondary); }
.committee-card-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.committee-card-body { padding: 1rem; text-align: center; }
.committee-card-vertical-sm .committee-card-photo { aspect-ratio: 1 / 1.1; }
.committee-card-vertical-sm .committee-card-body { padding: .75rem; }

/* --- Link cards (ลิงก์แบนเนอร์อื่นๆ) ------------------------------------------------ */
.link-card-img { width: 68px; height: 56px; object-fit: cover; border-radius: var(--pbmt-radius-sm); background: var(--pbmt-secondary); }
.link-card-icon {
  width: 68px; height: 56px;
  border-radius: var(--pbmt-radius-sm); background: var(--pbmt-gradient-soft); color: var(--pbmt-primary);
  display: flex; align-items: center; justify-content: center; font-size: 1.3rem;
}
.link-card-title { font-family: var(--font-display); font-weight: 700; font-size: 1rem; color: var(--pbmt-ink); line-height: 1.3; }
.link-card-desc { font-size: .76rem; color: var(--pbmt-ink-soft); margin-top: .15rem; }

/* --- Project report card (homepage block) -------------------------------------------- */
.project-report-card { overflow: hidden; }
.project-report-thumb {
  position: relative; width: 100%; height: 110px; border-radius: 0;
  background: var(--pbmt-gradient-soft); overflow: hidden;
}
.project-report-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.project-report-play {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
  width: 42px; height: 42px; border-radius: 50%;
  background: rgba(30,18,32,0.55); color: #fff;
  display: flex; align-items: center; justify-content: center; font-size: 1rem;
  transition: background .2s ease, transform .2s ease;
}
.project-report-card:hover .project-report-play { background: var(--pbmt-primary); transform: translate(-50%, -50%) scale(1.08); }
.project-report-info-icon {
  width: 100%; height: 100%; display: flex; align-items: center; justify-content: center;
  color: var(--pbmt-primary); font-size: 2rem;
}

/* --- Full-page iframe viewer (iframe_view.php) --------------------------------------- */
.iframe-view-frame { width: 100%; height: 75vh; min-height: 500px; border: 0; border-radius: var(--pbmt-radius-md); }

/* --- Meeting schedule table (homepage block) ---------------------------------------- */
.meeting-table th {
  font-size: 0.7rem; text-transform: uppercase; letter-spacing: .04em;
  color: var(--pbmt-ink-soft); font-weight: 600; border-bottom-width: 1px;
}
.meeting-table td { font-size: 0.85rem; vertical-align: middle; }

/* --- Sidebar: member universities list (homepage) ---------------------------------- */
.member-sidebar-card { padding: 1.25rem; position: sticky; top: 84px; }
.member-sidebar-list { padding-right: 4px; }
.member-sidebar-item {
  display: flex; align-items: center; gap: .6rem;
  padding: .6rem .25rem; font-size: 0.94rem;
  border-bottom: 1px dashed rgba(194,24,91,0.12);
}
.member-sidebar-item:last-child { border-bottom: none; }
.member-sidebar-num {
  min-width: 26px; height: 26px; border-radius: 50%;
  background: var(--pbmt-gradient-soft); color: var(--pbmt-primary);
  font-size: 0.78rem; font-weight: 700;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.member-sidebar-icon { color: var(--pbmt-accent); flex-shrink: 0; font-size: 1rem; }
.member-sidebar-logo { width: 22px; height: 22px; object-fit: contain; flex-shrink: 0; border-radius: 4px; }

/* --- Member university logos grid (members.php / homepage grid variant) ------------- */
.member-logo-card { padding: 1rem; text-align: center; height: 100%; }
.member-logo-card .logo-circle {
  width: 64px; height: 64px; margin: 0 auto 0.65rem;
  border-radius: 50%; background: var(--pbmt-gradient-soft);
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; color: var(--pbmt-primary); overflow: hidden;
}
.member-logo-card .logo-circle img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.member-logo-card .name { font-size: 0.74rem; color: var(--pbmt-ink-soft); }

/* --- Journal mini card (sidebar) ----------------------------------------------------- */
.journal-mini-card { padding: 1.25rem; text-align: center; }
.journal-mini-card img { max-height: 150px; object-fit: contain; }

/* --- Committee quote card -------------------------------------------------------------- */
/* --- Event countdown card (events_detail.php) -------------------------------------- */
.event-countdown-card { padding: 1.75rem; text-align: center; }
.countdown-label { font-weight: 600; color: var(--pbmt-ink-soft); font-size: .85rem; margin-bottom: 1rem; }
.countdown-units { display: flex; align-items: center; justify-content: center; gap: .6rem; flex-wrap: wrap; }
.countdown-unit {
  background: var(--pbmt-gradient-hero); color: #fff;
  border-radius: var(--pbmt-radius-md);
  padding: .85rem 1rem; min-width: 78px;
  box-shadow: 0 8px 20px rgba(194,24,91,0.2);
}
.countdown-num { font-family: var(--font-display); font-size: 1.8rem; font-weight: 700; line-height: 1; font-variant-numeric: tabular-nums; }
.countdown-unit-label { font-size: .68rem; opacity: .9; margin-top: .3rem; }
.countdown-sep { font-size: 1.6rem; font-weight: 700; color: var(--pbmt-primary); opacity: .5; }
.countdown-status-msg {
  font-weight: 600; font-size: 1.05rem; color: var(--pbmt-primary);
  padding: .5rem 0;
}
.countdown-status-ended { color: var(--pbmt-ink-soft); }
@media (max-width: 575.98px) {
  .countdown-unit { min-width: 64px; padding: .65rem .7rem; }
  .countdown-num { font-size: 1.4rem; }
}

/* --- Pulsing highlight for the external "view details" button ---------------------- */
.btn-pulse { animation: btnPulseGlow 1.8s ease-in-out infinite; }
@keyframes btnPulseGlow {
  0%, 100% { box-shadow: 0 8px 20px rgba(194,24,91,0.25); transform: scale(1); }
  50% { box-shadow: 0 8px 28px rgba(194,24,91,0.55); transform: scale(1.035); }
}

/* --- Event cover image: show the full image (no cropping) whether landscape or
   portrait — a soft-tinted frame lets the image breathe on any device without
   ever cutting off part of the picture. --------------------------------------------- */
.event-cover-frame {
  background: var(--pbmt-gradient-soft);
  border-radius: var(--pbmt-radius-lg);
  display: flex; align-items: center; justify-content: center;
  max-height: 70vh;
  overflow: hidden;
}
.event-cover-frame img {
  width: 100%;
  max-height: 70vh;
  object-fit: contain;
  display: block;
}

.committee-quote-card {
  background: var(--pbmt-gradient-hero);
  color: #fff; border-radius: var(--pbmt-radius-lg);
  padding: 2rem 1.5rem; text-align: center;
  position: relative; overflow: hidden;
}
.committee-quote-card .quote-mark { font-size: 2.5rem; opacity: .5; line-height: 1; }
.committee-quote-card p { font-size: 0.98rem; font-weight: 600; margin: .5rem 0 0; }

/* --- Stats counters ------------------------------------------------------------------ */
.stats-section { background: var(--pbmt-gradient-hero); color: #fff; padding: 2.4rem 0; }
.stats-section .stat-icon { font-size: 1.4rem; margin-bottom: .4rem; opacity: .9; }
.stat-number { font-family: var(--font-display); font-size: clamp(1.5rem, 3vw, 2.1rem); font-weight: 700; }
.stat-label { opacity: 0.85; font-size: 0.78rem; }

/* --- Footer ---------------------------------------------------------------------------- */
.pbmt-footer { background: var(--pbmt-gradient-footer); color: #FDEBF1; padding: 3rem 0 1.25rem; font-size: 0.82rem; }
.pbmt-footer a { color: #FDEBF1; opacity: .85; }
.pbmt-footer a:hover { color: #fff; opacity: 1; }
.pbmt-footer h5 { color: #fff; font-size: 0.88rem; margin-bottom: .85rem; }
.footer-logo-img { width: 40px; height: 40px; }
.footer-brand-short { font-family: var(--font-display); font-weight: 700; color: #fff; font-size: 1rem; }
.footer-brand-long { font-size: 0.65rem; opacity: .85; }
.footer-hr { border-color: rgba(255,255,255,0.25); opacity: 1; }
.footer-bottom-links a { margin-left: 0.5rem; }
.footer-social a {
  display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: 50%;
  background: rgba(255,255,255,0.12); margin-right: 0.5rem;
  transition: background .25s ease;
}
.footer-social a:hover { background: rgba(255,255,255,0.28); }

/* --- Admin login ------------------------------------------------------------------------ */
.admin-login-body {
  min-height: 100vh;
  display: flex; align-items: center; justify-content: center;
  background: var(--pbmt-gradient-hero);
  padding: 1.5rem;
}
.admin-login-wrap { width: 100%; max-width: 400px; }
.admin-login-card { padding: 2.25rem; background: rgba(255,255,255,0.92); }
.admin-login-logo {
  width: 60px; height: 60px; margin: 0 auto;
  border-radius: 16px; background: var(--pbmt-gradient-hero); color: #fff;
  display: flex; align-items: center; justify-content: center; font-weight: 700;
}

/* --- Admin dashboard shell --------------------------------------------------------------- */
.admin-sidebar {
  width: 250px; height: 100vh;
  background: #1E1220; color: #E9DCE2;
  position: fixed; top: 0; left: 0; z-index: 1040;
  padding: 1.4rem 1rem; font-size: 0.86rem;
  overflow-y: auto;
}
.admin-sidebar::-webkit-scrollbar { width: 5px; }
.admin-sidebar::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.15); border-radius: 4px; }
.admin-sidebar .brand { color: #fff; font-family: var(--font-display); font-weight: 700; padding: 0 0.75rem 1.4rem; font-size: 0.95rem; }
.cms-brand-preview {
  display: flex; align-items: center; gap: .5rem;
  background: #1E1220; color: #fff;
  font-family: var(--font-display); font-weight: 700; font-size: 0.95rem;
  padding: .65rem 1rem; border-radius: var(--pbmt-radius-sm);
  min-width: 160px;
}
.cms-brand-preview i { color: var(--pbmt-primary); font-size: 1.1rem; }
.admin-sidebar .nav-link {
  color: #C9BFC7; border-radius: var(--pbmt-radius-sm);
  padding: 0.6rem 0.85rem; margin-bottom: 0.2rem; font-size: 0.86rem;
}
.admin-sidebar .nav-link:hover, .admin-sidebar .nav-link.active {
  background: rgba(194,24,91,0.25); color: #fff;
}
.admin-main { margin-left: 250px; padding: 1.6rem 1.9rem; min-height: 100vh; font-size: 0.9rem; }
.admin-topbar { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1.4rem; }
.admin-topbar-icon-btn {
  width: 38px; height: 38px; border-radius: 10px;
  background: var(--pbmt-secondary); color: var(--pbmt-primary);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.95rem; transition: background .2s ease, color .2s ease;
}
.admin-topbar-icon-btn:hover { background: var(--pbmt-primary); color: #fff; }
.admin-topbar-icon-btn-danger:hover { background: #C0392B; }
.admin-topbar h1 { font-size: 1.1rem; }
.stat-widget { padding: 1.3rem; }
.stat-widget .value { font-size: 1.5rem; font-weight: 700; font-family: var(--font-display); }

@media (max-width: 991.98px) {
  .admin-sidebar { transform: translateX(-100%); transition: transform .3s ease; }
  .admin-sidebar.open { transform: translateX(0); }
  .admin-main { margin-left: 0; }
  .member-sidebar-card { position: static; }
}

/* --- Utility ---------------------------------------------------------------------------------- */
.rounded-pbmt { border-radius: var(--pbmt-radius-md) !important; }
.text-pbmt-primary { color: var(--pbmt-primary) !important; }
.text-pbmt-accent { color: var(--pbmt-accent) !important; }
.bg-pbmt-soft { background: var(--pbmt-gradient-soft) !important; }
