@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

/* === OKMS - Відділ освіти, молоді та спорту === */

/* ════════════════════════════════════════════
   ACCESSIBILITY MODES
════════════════════════════════════════════ */

/* Font sizes — zoom масштабує весь контент включно з px-значеннями */
body.a11y-font-1 { zoom: 1.1; }
body.a11y-font-2 { zoom: 1.2; }
body.a11y-font-3 { zoom: 1.35; }

/* Grayscale */
body.a11y-grayscale { filter: grayscale(100%); }

/* High contrast */
body.a11y-contrast,
body.a11y-contrast * {
  background: #000 !important;
  color: #fff !important;
  border-color: #fff !important;
}
body.a11y-contrast a { color: #7DF0FF !important; }
body.a11y-contrast img { filter: contrast(1.4) brightness(0.9); }
body.a11y-contrast .btn,
body.a11y-contrast button { background: #000 !important; border: 2px solid #fff !important; color: #fff !important; }

/* Yellow on black */
body.a11y-yellow-black,
body.a11y-yellow-black * {
  background: #000 !important;
  color: #FFD700 !important;
  border-color: #FFD700 !important;
}
body.a11y-yellow-black a { color: #FFD700 !important; text-decoration: underline !important; }
body.a11y-yellow-black img { filter: sepia(100%) saturate(300%) hue-rotate(30deg); }

/* Underline links */
body.a11y-underline a { text-decoration: underline !important; }

/* Line height */
body.a11y-lineheight *:not(#a11y-widget):not(#a11y-widget *) {
  line-height: 1.9 !important;
}

/* ════════════════════════════════════════════
   ACCESSIBILITY WIDGET
════════════════════════════════════════════ */
#a11y-widget {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  font-family: var(--font, 'Inter', sans-serif);
}

#a11y-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: var(--primary, #1A3A6B);
  color: #fff;
  border: none;
  border-radius: 32px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  box-shadow: 0 4px 16px rgba(0,0,0,0.2);
  transition: all 0.2s;
}
#a11y-toggle:hover { background: var(--primary-dark, #0F2347); transform: translateY(-1px); }
#a11y-toggle span { display: none; }
@media (min-width: 768px) { #a11y-toggle span { display: inline; } }

#a11y-panel {
  position: absolute;
  bottom: calc(100% + 12px);
  right: 0;
  width: 300px;
  background: #fff;
  border: 1px solid #E5E7EB;
  border-radius: 16px;
  box-shadow: 0 10px 40px rgba(0,0,0,0.15);
  overflow: hidden;
}

.a11y-panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 18px;
  background: var(--primary, #1A3A6B);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
}
.a11y-close {
  background: none; border: none; color: #fff;
  cursor: pointer; font-size: 16px; padding: 0 4px; line-height: 1;
}

.a11y-section { padding: 14px 18px; border-bottom: 1px solid #F3F4F6; }
.a11y-section:last-child { border-bottom: none; }
.a11y-label { font-size: 11px; font-weight: 600; color: #6B7280; text-transform: uppercase; letter-spacing: .06em; margin-bottom: 10px; }

.a11y-row { display: flex; gap: 8px; flex-wrap: wrap; }

.a11y-btn {
  padding: 7px 12px;
  border: 1.5px solid #E5E7EB;
  border-radius: 8px;
  background: #fff;
  color: #374151;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.15s;
  font-family: inherit;
}
.a11y-btn:hover { border-color: var(--primary, #1A3A6B); color: var(--primary, #1A3A6B); }
.a11y-btn.active { background: var(--primary, #1A3A6B); color: #fff; border-color: var(--primary, #1A3A6B); }

/* Font size button sizes */
.a11y-btn-font0 { font-size: 12px; }
.a11y-btn-font1 { font-size: 15px; }
.a11y-btn-font2 { font-size: 18px; }
.a11y-btn-font3 { font-size: 22px; }

/* Color scheme previews */
.a11y-color-gray    { background: #f5f5f5; color: #333; }
.a11y-color-contrast { background: #000; color: #fff; border-color: #000; }
.a11y-color-contrast:hover { background: #222; }
.a11y-color-yb      { background: #000; color: #FFD700; border-color: #000; }

.a11y-btn-reset {
  width: 100%;
  background: #FEF2F2;
  color: #DC2626;
  border-color: #FECACA;
  font-size: 13px;
}
.a11y-btn-reset:hover { background: #DC2626; color: #fff; border-color: #DC2626; }

/* Exclude a11y widget from zoom */
body.a11y-font-1 #a11y-widget,
body.a11y-font-2 #a11y-widget,
body.a11y-font-3 #a11y-widget { zoom: revert; }

/* Keep panel visible in contrast modes */
body.a11y-contrast #a11y-panel,
body.a11y-yellow-black #a11y-panel { filter: none !important; }
body.a11y-contrast #a11y-panel *,
body.a11y-yellow-black #a11y-panel * { background: revert !important; color: revert !important; border-color: revert !important; }

:root {
  --primary: #1A3A6B;
  --primary-light: #2557A7;
  --primary-dark: #0F2347;
  --accent: #FFD700;
  --accent-dark: #E6C200;
  --success: #2E7D32;
  --warning: #F57C00;
  --bg: #F7F8FA;
  --card-bg: #FFFFFF;
  --text: #1B1B1B;
  --text-muted: #6B7280;
  --text-light: #9CA3AF;
  --border: #E5E7EB;
  --border-hover: #D1D5DB;
  --shadow: 0 1px 3px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.05);
  --shadow-md: 0 4px 6px rgba(0,0,0,0.07), 0 2px 4px rgba(0,0,0,0.05);
  --shadow-lg: 0 10px 25px rgba(0,0,0,0.1), 0 4px 8px rgba(0,0,0,0.06);
  --radius: 12px;
  --radius-sm: 8px;
  --radius-lg: 16px;
  --transition: all 0.2s ease;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; font-size: 16px; overflow-x: hidden; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: var(--primary-light); text-decoration: none; transition: var(--transition); }
a:hover { color: var(--primary); }
img { max-width: 100%; display: block; }
ul { list-style: none; }

/* ─── TOP FLAG BAR ─── */
.flag-bar {
  height: 4px;
  background: linear-gradient(to bottom, #005BBB 50%, #FFD700 50%);
}

/* ─── HEADER ─── */
.site-header {
  background: #fff;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: var(--shadow);
}

.header-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
  height: 72px;
  display: flex;
  align-items: center;
  gap: 32px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-shrink: 0;
  color: var(--text);
  text-decoration: none;
}

.logo-emblem {
  width: 44px;
  height: 44px;
  flex-shrink: 0;
}

.logo-text {
  display: flex;
  flex-direction: column;
}

.logo-title {
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
  color: var(--primary);
  letter-spacing: -0.01em;
}

.logo-subtitle {
  font-size: 11px;
  color: var(--text-muted);
  line-height: 1.2;
}

/* ─── MAIN NAV ─── */
.main-nav {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
}

.nav-item {
  position: relative;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 8px 14px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  border-radius: var(--radius-sm);
  transition: var(--transition);
  white-space: nowrap;
}

.nav-link:hover, .nav-link.active {
  color: var(--primary);
  background: rgba(26, 58, 107, 0.06);
}

.nav-link svg { width: 14px; height: 14px; transition: transform 0.2s; }
.nav-item:hover .nav-link svg { transform: rotate(180deg); }

/* Dropdown */
.dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 220px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: all 0.2s ease;
  z-index: 100;
  padding: 8px;
}

.nav-item:hover .dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown a {
  display: block;
  padding: 8px 12px;
  font-size: 14px;
  color: var(--text);
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.dropdown a:hover {
  background: var(--bg);
  color: var(--primary);
}

/* ─── HAMBURGER ─── */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 8px;
  border-radius: var(--radius-sm);
  transition: var(--transition);
}
.hamburger:hover { background: var(--bg); }
.hamburger span {
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: var(--transition);
}

/* Mobile nav */
.mobile-nav {
  display: none;
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0,0,0,0.5);
  z-index: 2000;
}

.mobile-nav.open { display: block; }

.mobile-nav-panel {
  position: absolute;
  top: 0; right: 0; bottom: 0;
  width: 300px;
  background: #fff;
  padding: 24px;
  overflow-y: auto;
  box-shadow: -4px 0 20px rgba(0,0,0,0.15);
}

.mobile-nav-close {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 24px;
}

.mobile-nav-close button {
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  border-radius: 50%;
  color: var(--text);
  font-size: 20px;
}

.mobile-nav-items a {
  display: block;
  padding: 12px 0;
  font-size: 16px;
  font-weight: 500;
  color: var(--text);
  border-bottom: 1px solid var(--border);
}

.mobile-nav-items a:hover { color: var(--primary); }

.mobile-nav-sub {
  display: none;
  padding-left: 16px;
}
.mobile-has-sub.open .mobile-nav-sub {
  display: block;
}
.mobile-sub-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border);
}
.mobile-sub-header a {
  border-bottom: none !important;
  flex: 1;
}
.mobile-sub-toggle {
  background: none;
  border: none;
  cursor: pointer;
  padding: 12px 8px;
  font-size: 14px;
  color: var(--text-muted);
  transition: transform 0.25s ease;
}
.mobile-has-sub.open .mobile-sub-toggle {
  transform: rotate(180deg);
}
.mobile-nav-sub a {
  font-size: 14px;
  font-weight: 400;
  color: var(--text-muted);
}

/* ─── HERO ─── */
.hero {
  background: linear-gradient(135deg, var(--primary) 0%, #1a4d8f 60%, #1a6b9f 100%);
  color: #fff;
  padding: 80px 0 64px;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -100px; right: -100px;
  width: 500px; height: 500px;
  background: rgba(255,255,255,0.04);
  border-radius: 50%;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -80px; left: -60px;
  width: 300px; height: 300px;
  background: rgba(255,215,0,0.06);
  border-radius: 50%;
}

.hero-centered .hero-inner,
.hero-centered h1,
.hero-centered .hero-lead,
.hero-centered .hero-badge,
.hero-centered .hero-actions { text-align: center; justify-content: center; }
.hero-centered .hero-actions { display: flex; }
.hero-centered h1 { max-width: none; margin-left: auto; margin-right: auto; }
.hero-centered .hero-lead { max-width: 560px; margin-left: auto; margin-right: auto; }

.hero-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
  position: relative;
  z-index: 1;
}

.hero-emblem {
  display: flex;
  justify-content: center;
  margin-bottom: 24px;
}
.hero-emblem img {
  width: 72px;
  height: auto;
  filter: drop-shadow(0 2px 16px rgba(255, 215, 0, 0.35));
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255,215,0,0.15);
  border: 1px solid rgba(255,215,0,0.3);
  color: var(--accent);
  padding: 6px 14px;
  border-radius: 100px;
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 20px;
}

.hero h1 {
  font-size: clamp(22px, 2.4vw, 34px);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.hero-lead {
  font-size: 18px;
  color: rgba(255,255,255,0.8);
  max-width: 600px;
  margin-bottom: 36px;
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* ─── BUTTONS ─── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: var(--transition);
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary {
  background: var(--accent);
  color: var(--primary-dark);
}
.contact-form .btn-primary,
form:not(.doc-search-form) .btn-primary[type="submit"] {
  width: 100%;
  justify-content: center;
  text-align: center;
}
.btn-primary:hover {
  background: var(--accent-dark);
  color: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(255,215,0,0.4);
}

.btn-outline {
  background: transparent;
  color: #fff;
  border: 2px solid rgba(255,255,255,0.4);
}
.btn-outline:hover {
  background: rgba(255,255,255,0.1);
  border-color: rgba(255,255,255,0.7);
  color: #fff;
}

.btn-secondary {
  background: var(--primary);
  color: #fff;
}
.btn-secondary:hover {
  background: var(--primary-dark);
  color: #fff;
  transform: translateY(-1px);
}

.btn-ghost {
  background: transparent;
  color: var(--primary-light);
  padding: 10px 16px;
}
.btn-ghost:hover {
  background: rgba(26, 58, 107, 0.06);
  color: var(--primary);
}

.btn-sm { padding: 8px 16px; font-size: 13px; }

/* ─── CONTAINER ─── */
.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ─── SECTIONS ─── */
.section { padding: 64px 0; }
.section-sm { padding: 40px 0; }
.section-white { background: #fff; }
.section-gray { background: var(--bg); }
.section-dark { background: var(--primary-dark); color: #fff; }

.section-header {
  margin-bottom: 40px;
}

.section-eyebrow {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--primary-light);
  margin-bottom: 8px;
}

.section-title {
  font-size: clamp(22px, 3vw, 32px);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--text);
}

.section-title.white { color: #fff; }

.section-subtitle {
  font-size: 16px;
  color: var(--text-muted);
  margin-top: 8px;
  max-width: 560px;
}

.section-header-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

/* ─── CARDS ─── */
.card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
  transition: var(--transition);
}

.card:hover {
  border-color: var(--border-hover);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.card-link { display: block; color: inherit; text-decoration: none; }
.card-link:hover { color: inherit; }

/* ─── GRID ─── */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.grid-auto { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; }

/* ─── NEWS CARDS ─── */
.news-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

.news-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-3px);
}

.news-card-img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  background: linear-gradient(135deg, #e8edf5, #c8d5e8);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 48px;
  color: var(--primary-light);
  flex-shrink: 0;
}

.news-card-body {
  padding: 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.news-card-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}

.tag {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 100px;
  font-size: 12px;
  font-weight: 600;
  background: rgba(26,58,107,0.08);
  color: var(--primary-light);
}

.tag-news { background: rgba(26,58,107,0.08); color: var(--primary-light); }
.tag-event { background: rgba(255,215,0,0.15); color: #8B6E00; }
.tag-announcement { background: rgba(46,125,50,0.1); color: var(--success); }
.tag-gallery { background: rgba(245,124,0,0.1); color: var(--warning); }

.date {
  font-size: 12px;
  color: var(--text-muted);
}

.news-card-title {
  font-size: 16px;
  font-weight: 700;
  line-height: 1.4;
  color: var(--text);
  margin-bottom: 10px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.news-card-excerpt {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.6;
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 16px;
}

.news-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.read-more {
  font-size: 14px;
  font-weight: 600;
  color: var(--primary-light);
  display: flex;
  align-items: center;
  gap: 4px;
}
.read-more:hover { color: var(--primary); }

/* ─── DOCUMENT LIST ─── */
.doc-list { display: flex; flex-direction: column; gap: 8px; }

.doc-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  transition: var(--transition);
  cursor: pointer;
}

.doc-item:hover {
  border-color: var(--primary-light);
  box-shadow: var(--shadow-md);
  transform: translateX(3px);
}

.doc-icon {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  background: rgba(26,58,107,0.08);
  color: var(--primary-light);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 18px;
}

.doc-icon.pdf { background: rgba(239,68,68,0.08); color: #EF4444; }
.doc-icon.docx { background: rgba(59,130,246,0.08); color: #3B82F6; }

.doc-info { flex: 1; min-width: 0; }

.doc-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 2px;
}

.doc-meta {
  font-size: 12px;
  color: var(--text-muted);
}

.doc-download {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--bg);
  color: var(--primary-light);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: var(--transition);
  font-size: 16px;
}

.doc-item:hover .doc-download {
  background: var(--primary);
  color: #fff;
}

/* ─── QUICK LINKS ─── */
.quick-links { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 16px; }

.quick-link-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 20px;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: var(--transition);
  text-decoration: none;
  color: var(--text);
}

.quick-link-card:hover {
  border-color: var(--primary-light);
  color: var(--text);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.quick-link-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
}

.quick-link-text strong {
  display: block;
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 2px;
}

.quick-link-text span {
  font-size: 12px;
  color: var(--text-muted);
}

/* ─── STATS ─── */
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }

.stat-card {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: var(--radius);
  padding: 24px;
  text-align: center;
}

.stat-number {
  font-size: 40px;
  font-weight: 800;
  color: var(--accent);
  line-height: 1;
  margin-bottom: 6px;
  letter-spacing: -0.03em;
}

.stat-label {
  font-size: 14px;
  color: rgba(255,255,255,0.7);
}

/* ─── TABS ─── */
.tabs-nav {
  display: flex;
  gap: 4px;
  border-bottom: 2px solid var(--border);
  margin-bottom: 32px;
  overflow-x: auto;
  scrollbar-width: none;
}
.tabs-nav::-webkit-scrollbar { display: none; }

.tab-btn {
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
  border: none;
  background: none;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: var(--transition);
  white-space: nowrap;
}

.tab-btn:hover { color: var(--primary); }
.tab-btn.active { color: var(--primary); border-bottom-color: var(--primary); }

.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* ─── BREADCRUMB ─── */
.breadcrumb {
  padding: 12px 0;
  margin-bottom: 0;
}

.page-hero .breadcrumb {
  padding: 0 0 10px 0;
  border-bottom: none;
}
.page-hero .breadcrumb-item { color: rgba(255,255,255,0.7); }
.page-hero .breadcrumb-item a { color: rgba(255,255,255,0.85); }
.page-hero .breadcrumb-item a:hover { color: #fff; }
.page-hero .breadcrumb-item.current { color: #fff; }
.page-hero .breadcrumb-sep { color: rgba(255,255,255,0.45); }

.breadcrumb-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.breadcrumb-item {
  font-size: 13px;
  color: var(--text-muted);
}

.breadcrumb-item a {
  color: var(--primary-light);
}

.breadcrumb-item a:hover { color: var(--primary); }
.breadcrumb-item.current { color: var(--text); font-weight: 500; }
.breadcrumb-sep { color: var(--text-light); font-size: 12px; }

/* ─── PAGE HERO ─── */
.page-hero {
  background: var(--primary);
  color: #fff;
  padding: 48px 0 40px;
}

.page-hero h1 {
  font-size: clamp(24px, 3vw, 36px);
  font-weight: 800;
  margin-bottom: 8px;
  letter-spacing: -0.02em;
}

.page-hero p {
  font-size: 16px;
  color: rgba(255,255,255,0.75);
}

/* ─── INSTITUTION TABLE ─── */
.inst-table-wrapper {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

.inst-table {
  width: 100%;
  border-collapse: collapse;
}

.inst-table th {
  background: var(--primary);
  color: #fff;
  padding: 14px 20px;
  font-size: 13px;
  font-weight: 600;
  text-align: left;
  border-right: 1px solid rgba(255,255,255,0.15);
}

.inst-table th:last-child { border-right: none; }

.inst-table td {
  padding: 12px 20px;
  font-size: 14px;
  border-bottom: 1px solid var(--border);
  border-right: 1px solid var(--border);
  vertical-align: top;
}

.inst-table td:last-child { border-right: none; }
.inst-table tr:last-child td { border-bottom: none; }
.inst-table tr:nth-child(even) td { background: var(--bg); }

.inst-table a {
  color: var(--primary-light);
  font-weight: 500;
}

.inst-table a:hover {
  color: var(--primary);
  text-decoration: underline;
}

/* ─── STAFF CARDS ─── */
.staff-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
  display: flex;
  gap: 20px;
  align-items: flex-start;
  transition: var(--transition);
}

.staff-card:hover { box-shadow: var(--shadow-md); }

.staff-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 28px;
  font-weight: 700;
}

.staff-info .name {
  font-size: 17px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 4px;
}

.staff-info .position {
  font-size: 14px;
  color: var(--primary-light);
  font-weight: 500;
  margin-bottom: 8px;
}

.staff-info .contact {
  font-size: 13px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 6px;
}

/* ─── CONTACT FORM ─── */
.contact-form {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 40px;
  box-shadow: var(--shadow-md);
}

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }

.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group.full { grid-column: 1 / -1; }

.form-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}

.form-control {
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-family: inherit;
  color: var(--text);
  background: var(--bg);
  transition: var(--transition);
  outline: none;
}

.form-control:focus {
  border-color: var(--primary-light);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(26,58,107,0.1);
}

textarea.form-control { resize: vertical; min-height: 120px; }

/* ─── SEARCH ─── */
.search-bar {
  display: flex;
  align-items: center;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: var(--radius-sm);
  overflow: hidden;
  max-width: 340px;
}

.search-input {
  background: none;
  border: none;
  padding: 10px 16px;
  font-size: 14px;
  color: #fff;
  outline: none;
  width: 100%;
}

.search-input::placeholder { color: rgba(255,255,255,0.5); }

.search-btn {
  background: none;
  border: none;
  color: rgba(255,255,255,0.7);
  padding: 10px 14px;
  cursor: pointer;
  font-size: 16px;
}

/* ─── ANNOUNCEMENT BANNER ─── */
.announcement-banner {
  background: linear-gradient(135deg, #FFF9E6, #FFFDE7);
  border: 1px solid #FFD700;
  border-radius: var(--radius);
  padding: 16px 20px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.announcement-icon { font-size: 20px; flex-shrink: 0; margin-top: 1px; }

.announcement-body strong {
  display: block;
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 2px;
}

.announcement-body p {
  font-size: 13px;
  color: var(--text-muted);
}

/* ─── ABOUT SNIPPET ─── */
.about-snippet {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

.about-text h2 {
  font-size: 26px;
  font-weight: 800;
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.about-text p {
  font-size: 15px;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 16px;
}

.about-image {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  background: linear-gradient(135deg, #e8edf5, #c8d5e8);
  height: 320px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 64px;
}

/* ─── FOOTER ─── */
.site-footer {
  background: var(--primary-dark);
  color: rgba(255,255,255,0.8);
  padding: 56px 0 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 48px;
}

.footer-brand .logo-title { color: var(--accent); font-size: 15px; }
.footer-brand .logo-subtitle { color: rgba(255,255,255,0.5); }

.footer-desc {
  font-size: 14px;
  color: rgba(255,255,255,0.55);
  line-height: 1.7;
  margin: 16px 0 20px;
}

.footer-contacts { display: flex; flex-direction: column; gap: 6px; }

.footer-contact-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: rgba(255,255,255,0.7);
}

.footer-col h4 {
  font-size: 13px;
  font-weight: 700;
  color: rgba(255,255,255,0.5);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 16px;
}

.footer-links { display: flex; flex-direction: column; gap: 8px; }

.footer-links a {
  font-size: 14px;
  color: rgba(255,255,255,0.7);
}

.footer-links a:hover { color: var(--accent); }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding: 20px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.footer-bottom-text {
  font-size: 13px;
  color: rgba(255,255,255,0.4);
}

/* ─── UTILITY ─── */
.text-center { text-align: center; }
.text-right { text-align: right; }
.mt-0 { margin-top: 0; }
.mt-8 { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-32 { margin-top: 32px; }
.mb-0 { margin-bottom: 0; }
.mb-8 { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.mb-32 { margin-bottom: 32px; }
.flex { display: flex; }
.flex-wrap { flex-wrap: wrap; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-8 { gap: 8px; }
.gap-16 { gap: 16px; }
.gap-24 { gap: 24px; }
.font-bold { font-weight: 700; }
.text-muted { color: var(--text-muted); }
.text-primary { color: var(--primary-light); }

/* ─── DIVIDER ─── */
.divider {
  height: 1px;
  background: var(--border);
  margin: 0;
}

/* ─── ALERT / NOTICE ─── */
.notice {
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  border-left: 4px solid;
  margin-bottom: 16px;
}
.notice-info { background: rgba(26,58,107,0.05); border-color: var(--primary-light); color: var(--primary); }
.notice-warning { background: rgba(245,124,0,0.06); border-color: var(--warning); color: #9A4E00; }
.notice-success { background: rgba(46,125,50,0.06); border-color: var(--success); color: var(--success); }

/* ─── PAGINATION ─── */
.pagination {
  display: flex;
  align-items: center;
  gap: 4px;
  justify-content: center;
  margin-top: 40px;
}

.page-btn {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--card-bg);
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.page-btn:hover { border-color: var(--primary-light); color: var(--primary-light); }
.page-btn.active { background: var(--primary); border-color: var(--primary); color: #fff; }

/* ─── GALLERY GRID ─── */
.gallery-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }

.gallery-item {
  border-radius: var(--radius-sm);
  overflow: hidden;
  aspect-ratio: 4/3;
  background: linear-gradient(135deg, #e8edf5, #c8d5e8);
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 40px;
  color: var(--primary-light);
  position: relative;
}

.gallery-item:hover { transform: scale(1.02); box-shadow: var(--shadow-md); }

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ─── SCROLL TO TOP ─── */
.scroll-top {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 44px;
  height: 44px;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-md);
  transition: var(--transition);
  opacity: 0;
  pointer-events: none;
  font-size: 18px;
  z-index: 500;
}

.scroll-top.visible { opacity: 1; pointer-events: all; }
.scroll-top:hover { background: var(--primary-dark); transform: translateY(-2px); }

/* ─── ACCESSIBILITY ─── */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--primary);
  color: #fff;
  padding: 8px 16px;
  border-radius: 0 0 var(--radius-sm) 0;
  z-index: 9999;
  font-size: 14px;
  font-weight: 600;
  transition: top 0.2s;
}
.skip-link:focus { top: 0; }

/* ─── RESPONSIVE: tight header for ~13" screens ─── */
@media (max-width: 1380px) {
  .header-inner { gap: 16px; padding: 0 16px; }
  .logo { gap: 10px; }
  .logo-title { font-size: 12px; }
  .nav-link { padding: 8px 10px; font-size: 13px; }
  .main-nav { gap: 2px; }
}

/* ─── RESPONSIVE ─── */
@media (max-width: 1024px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .about-snippet { grid-template-columns: 1fr; }
  .about-image { height: 240px; }
}

@media (max-width: 768px) {
  .main-nav { display: none; }
  .hamburger { display: flex; margin-left: auto; }
  
  .header-inner { height: 60px; gap: 16px; }
  
  .hero { padding: 48px 0 40px; }
  .hero h1 { font-size: 24px; }
  .hero-centered h1 { white-space: normal; }
  .hero-lead { font-size: 16px; }
  
  .section { padding: 48px 0; }
  .container { padding: 0 16px; }
  
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .form-grid { grid-template-columns: 1fr; }
  
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  
  .contact-form { padding: 24px 20px; }
  
  .section-header-row { flex-direction: column; align-items: flex-start; }
  
  .quick-links { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .hero-actions { flex-direction: column; }
  .hero-actions .btn { width: 100%; justify-content: center; }
}

/* ─── DOCUMENT LIST ─── */
.doc-list { display: flex; flex-direction: column; gap: 2px; margin-top: 32px; }

.doc-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 20px;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  transition: var(--transition);
}
.doc-item:hover { border-color: var(--primary-light); box-shadow: var(--shadow-md); }

.doc-icon {
  flex-shrink: 0;
  width: 40px; height: 40px;
  background: var(--bg);
  border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  color: var(--primary);
}
.doc-info { flex: 1; min-width: 0; }
.doc-title { font-size: 15px; font-weight: 500; color: var(--text); }
.doc-title a { color: inherit; text-decoration: none; }
.doc-title a:hover { color: var(--primary); }
.doc-meta { font-size: 12px; color: var(--text-muted); margin-top: 4px; }

.doc-download {
  flex-shrink: 0;
  width: 36px; height: 36px;
  border-radius: 50%;
  border: 1.5px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  color: var(--text-muted);
  text-decoration: none;
  transition: var(--transition);
}
.doc-download-active { border-color: var(--primary); color: var(--primary); }
.doc-download-active:hover { background: var(--primary); color: #fff; }

/* ─── DOC LINKS LIST (front page) ─── */
.doc-links-list { list-style: none; padding: 0; margin: 16px 0 0; }
.doc-link-item {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 0; border-bottom: 1px solid var(--border);
  font-size: 14px; flex-wrap: wrap;
}
.doc-link-item:last-child { border-bottom: none; }
.doc-link-icon { flex-shrink: 0; color: var(--primary); opacity: 0.7; }
.doc-link-item a {
  color: var(--text); text-decoration: none; font-weight: 500; flex: 1;
  transition: color 0.2s;
}
.doc-link-item a:hover { color: var(--primary); text-decoration: underline; }
.doc-link-tag {
  flex-shrink: 0; font-size: 11px; font-weight: 600; text-transform: uppercase;
  letter-spacing: 0.4px; color: var(--primary); background: rgba(26,58,107,0.07);
  padding: 2px 8px; border-radius: 100px;
}
.doc-link-date { flex-shrink: 0; font-size: 12px; color: var(--text-muted); margin-left: auto; }

/* ─── ABOUT SPLIT ─── */
.about-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}
.about-text .section-title { margin-bottom: 20px; }
.about-text p { color: var(--text-muted); line-height: 1.7; margin-bottom: 16px; font-size: 15px; }
.about-text .btn { margin-top: 8px; }

.about-image {
  display: flex;
  align-items: center;
  justify-content: center;
}
.about-image-placeholder {
  width: 100%;
  aspect-ratio: 4/3;
  background: #EEF2F8;
  border-radius: var(--radius-lg);
  display: flex; align-items: center; justify-content: center;
  color: #9CA3AF;
}

@media (max-width: 768px) {
  .about-split { grid-template-columns: 1fr; gap: 32px; }
  .about-image { display: none; }
  .doc-item { padding: 12px 16px; }
}

/* ─── PAGE LAYOUT (sidebar + main) ─── */
.page-layout { display: grid; grid-template-columns: 220px 1fr; gap: 40px; align-items: start; }
.page-sidebar { position: sticky; top: 80px; }
.page-main { min-width: 0; }
.sub-nav ul { list-style: none; padding: 0; margin: 0; border-left: 2px solid var(--border); }
.sub-nav ul li a {
  display: block; padding: 9px 16px; font-size: 14px; font-weight: 500;
  color: var(--text-muted); text-decoration: none; border-left: 2px solid transparent; margin-left: -2px;
  transition: color 0.2s, border-color 0.2s;
}
.sub-nav ul li a:hover,
.sub-nav ul li.active a { color: var(--primary); border-left-color: var(--primary); }

/* ─── SECTION CARDS (overview template) ─── */
.section-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.section-card {
  display: flex; align-items: center; gap: 16px;
  padding: 20px; border: 1px solid var(--border);
  border-radius: var(--radius); text-decoration: none; color: inherit;
  background: #fff; transition: box-shadow 0.2s, border-color 0.2s;
}
.section-card:hover { box-shadow: 0 4px 16px rgba(26,58,107,0.1); border-color: var(--primary); }
.section-card-icon { flex-shrink: 0; width: 48px; height: 48px; border-radius: 12px; background: var(--bg-light); display: flex; align-items: center; justify-content: center; color: var(--primary); }
.section-card-body { flex: 1; }
.section-card-body h3 { font-size: 15px; font-weight: 600; margin: 0 0 4px; }
.section-card-body p { font-size: 13px; color: var(--text-muted); margin: 0; }
.section-card-arrow { flex-shrink: 0; color: var(--text-muted); }

/* ─── PAGE BODY ─── */
.page-body { padding: 48px 0 64px; }

/* ─── DOC SEARCH ─── */
.doc-search-form { display: flex; gap: 8px; align-items: stretch; }
.doc-search-input {
  flex: 1;
  padding: 10px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 14px;
  font-family: inherit;
  transition: border-color 0.2s;
}
.doc-search-input:focus { outline: none; border-color: var(--primary); }
.doc-search-btn { flex-shrink: 0; white-space: nowrap; }

/* ─── INSTITUTIONS GRID ─── */
.institutions-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 20px; }
.institution-card { border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; background: #fff; transition: box-shadow 0.2s; }
.institution-card:hover { box-shadow: 0 4px 20px rgba(26,58,107,0.1); }
.institution-img, .institution-card img { width: 100%; height: 160px; object-fit: cover; }
.institution-body { padding: 20px; }
.institution-title { font-size: 16px; font-weight: 600; margin: 8px 0; }
.institution-title a { color: inherit; text-decoration: none; }
.institution-title a:hover { color: var(--primary); }
.institution-head, .institution-addr { font-size: 13px; color: var(--text-muted); margin: 4px 0; }
.institution-contacts { display: flex; flex-direction: column; gap: 4px; margin-top: 8px; }
.institution-contacts a { font-size: 13px; color: var(--text-muted); text-decoration: none; }
.institution-contacts a:hover { color: var(--primary); }

/* ─── INSTITUTION SINGLE ─── */
.institution-single-layout { display: grid; grid-template-columns: 1fr 320px; gap: 40px; align-items: start; }
.institution-single-img img.institution-cover { width: 100%; border-radius: var(--radius-lg); }
.info-card { border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 24px; background: #fff; }
.info-card h3 { font-size: 16px; font-weight: 700; margin: 0 0 16px; color: var(--primary); }
.info-row { display: flex; flex-direction: column; gap: 2px; padding: 10px 0; border-bottom: 1px solid var(--border); font-size: 14px; }
.info-row:last-child { border-bottom: none; }
.info-label { font-size: 12px; text-transform: uppercase; letter-spacing: 0.5px; color: var(--text-muted); font-weight: 500; }
.info-row a { color: var(--primary); text-decoration: none; }

/* ─── NEWS LIST ─── */
.news-list { display: flex; flex-direction: column; gap: 24px; }
.news-list-item { display: flex; gap: 20px; padding-bottom: 24px; border-bottom: 1px solid var(--border); }
.news-list-thumb { flex-shrink: 0; width: 120px; height: 90px; border-radius: var(--radius); overflow: hidden; }
.news-list-thumb img.news-thumb-img { width: 100%; height: 100%; object-fit: cover; }
.news-list-body { flex: 1; }
.news-list-title { font-size: 17px; font-weight: 600; margin: 6px 0 8px; }
.news-list-title a { color: inherit; text-decoration: none; }
.news-list-title a:hover { color: var(--primary); }

/* ─── GALLERY ─── */
.gallery-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }
.gallery-item { text-decoration: none; border-radius: var(--radius); overflow: hidden; position: relative; }
.gallery-img { width: 100%; height: 160px; object-fit: cover; display: block; transition: transform 0.25s; }
.gallery-placeholder { background: var(--bg-light); display: flex; align-items: center; justify-content: center; font-size: 32px; }
.gallery-item:hover .gallery-img { transform: scale(1.04); }
.gallery-caption { position: absolute; bottom: 0; left: 0; right: 0; background: rgba(0,0,0,0.55); color: #fff; font-size: 12px; padding: 6px 10px; }

/* ─── CONTACTS LAYOUT ─── */
.contacts-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
.contact-cards { display: flex; flex-direction: column; gap: 16px; }
.contact-card { display: flex; gap: 16px; align-items: flex-start; padding: 16px; border: 1px solid var(--border); border-radius: var(--radius); background: #fff; }
.contact-icon { font-size: 20px; flex-shrink: 0; }
.contact-card strong { display: block; font-size: 14px; font-weight: 600; margin-bottom: 4px; }
.contact-card p { font-size: 14px; color: var(--text-muted); margin: 0; }
.contact-form { display: flex; flex-direction: column; gap: 16px; }
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group label { font-size: 13px; font-weight: 600; color: var(--text); }
.form-group input, .form-group textarea, .form-group select {
  padding: 10px 14px; border: 1px solid var(--border); border-radius: var(--radius);
  font-size: 14px; font-family: inherit; transition: border-color 0.2s;
}
.form-group input:focus, .form-group textarea:focus { outline: none; border-color: var(--primary); }
.form-group textarea { resize: vertical; min-height: 120px; }

/* ─── FILTER TABS ─── */
.filter-tabs { display: flex; flex-wrap: wrap; gap: 8px; }
.filter-tab {
  padding: 6px 16px; border: 1px solid var(--border); border-radius: 100px;
  font-size: 13px; font-weight: 500; text-decoration: none; color: var(--text-muted);
  transition: all 0.2s; background: #fff;
}
.filter-tab:hover, .filter-tab.active { background: var(--primary); color: #fff; border-color: var(--primary); }
.filter-count { font-size: 11px; background: rgba(0,0,0,0.12); border-radius: 100px; padding: 1px 6px; margin-left: 4px; }

/* ─── PAGINATION ─── */
.pagination { display: flex; gap: 4px; justify-content: center; margin-top: 40px; flex-wrap: wrap; }
.pagination .page-numbers {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 36px; height: 36px; padding: 0 12px;
  border: 1px solid var(--border); border-radius: var(--radius);
  font-size: 14px; text-decoration: none; color: var(--text); background: #fff;
  transition: all 0.2s;
}
.pagination .page-numbers.current, .pagination .page-numbers:hover { background: var(--primary); color: #fff; border-color: var(--primary); }

/* ─── EMPTY STATE ─── */
.empty-state { text-align: center; padding: 64px 24px; color: var(--text-muted); }
.empty-state svg { display: block; margin: 0 auto 16px; opacity: 0.3; }
.empty-state p { font-size: 15px; }

/* ─── NEWS META + READ MORE ─── */
.news-card-meta { display: flex; align-items: center; gap: 10px; }
.news-card-excerpt { font-size: 14px; color: var(--text-muted); line-height: 1.6; }
.read-more { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; font-weight: 600; color: var(--primary); }
.read-more:hover { color: var(--primary); opacity: 0.8; }

/* ─── TAG VARIANTS ─── */
.tag-news { background: rgba(30,70,150,0.08); color: var(--primary); }
.tag { display: inline-block; padding: 2px 10px; font-size: 11px; font-weight: 600; border-radius: 20px; letter-spacing: 0.02em; }

.tag-institution { background: rgba(16,120,60,0.1); color: #10783C; }

/* ─── UTILITY ─── */
.mb-24 { margin-bottom: 24px; }
.mb-32 { margin-bottom: 32px; }
.mb-40 { margin-bottom: 40px; }
.mt-12 { margin-top: 12px; }
.mt-16 { margin-top: 16px; }
.btn-sm { padding: 6px 14px; font-size: 13px; }
.text-muted { color: var(--text-muted); }

/* ─── RESPONSIVE NEW TEMPLATES ─── */
@media (max-width: 900px) {
  .page-layout { grid-template-columns: 1fr; }
  .page-sidebar { position: static; }
  .institution-single-layout { grid-template-columns: 1fr; }
  .contacts-layout { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .institutions-grid { grid-template-columns: 1fr; }
  .news-list-thumb { width: 80px; height: 64px; }
  .section-cards { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ─── DOC ACTION BAR ─── */
.doc-action-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 20px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 20px;
  flex-wrap: wrap;
}
.doc-action-info {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: var(--text-muted);
}

/* ─── PDF VIEWER ─── */
.pdf-viewer-wrap {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: #f5f5f5;
}
.pdf-viewer-iframe {
  display: block;
  width: 100%;
  height: 80vh;
  min-height: 500px;
  border: none;
}
.pdf-viewer-fallback { display: none; }

@media (max-width: 900px) {
  .pdf-viewer-iframe { height: 70vh; min-height: 400px; }
}
@media (max-width: 640px) {
  .pdf-viewer-iframe { display: none; }
  .pdf-viewer-fallback {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    padding: 48px 24px;
    text-align: center;
    color: var(--text-muted);
  }
}
