/* ========================================================
   SHARED LAYOUT STYLES (HEADER, NAVBAR, FOOTER)
   ======================================================== */

:root {
  /* Mahidol Brand Colors Token -> Customized for SN_TH Standard Royal Blue & Sky Blue Theme */
  --mu-blue: #1d4ed8;
  /* Standard Royal Blue */
  --mu-blue-dark: #1e40af;
  /* Solid Dark Blue */
  --mu-blue-mid: #2563eb;
  /* Vibrant Blue */
  --mu-blue-light: #3b82f6;
  /* Medium Royal Blue */
  --mu-blue-pale: #e0f2fe;
  /* Soft Ice Blue / Sky Blue Pale */
  --mu-gold: #0284c7;
  /* Vibrant Sky Blue Accent */
  --mu-gold-light: #38bdf8;
  /* Light Sky Blue Accent */
  --mu-gold-dark: #0369a1;
  /* Dark Sky Blue Accent */



  /* Neutrals */
  --white: #ffffff;
  --off-white: #f8f9fc;
  --gray-50: #f4f5f7;
  --gray-100: #e8eaed;
  --gray-200: #d1d5db;
  --gray-400: #9ca3af;
  --gray-500: #6b7280;
  --gray-600: #4b5563;
  --gray-700: #374151;
  --gray-800: #1f2937;
  --gray-900: #111827;

  /* Typography */
  --font-thai: 'Sarabun', sans-serif;
  --font-en: 'Inter', sans-serif;
  --font-base: var(--font-thai);

  /* Utilities */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-full: 9999px;
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 4px 16px rgba(25, 68, 136, 0.1);
  --shadow-lg: 0 10px 40px rgba(25, 68, 136, 0.15);
  --shadow-xl: 0 20px 60px rgba(25, 68, 136, 0.2);
  --transition-fast: 0.15s ease;
  --transition-base: 0.25s ease;
  --transition-slow: 0.4s ease;
  /* ---Layout--- */
  --container-max: 1200px;
  --navbar-height: 68px;
  --topbar-height: 40px;
}

/* Reset เบื้องต้นสำหรับ Layout */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-base);
  background-color: var(--off-white);
  color: var(--gray-700);
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-thai);
}

a {
  text-decoration: none;
  transition: color var(--transition-fast);
}

ul {
  list-style: none;
}

.mn-wrapper {
  max-width: var(--container-max);
  margin: 0 auto;
  background: var(--white);
  box-shadow: var(--shadow-xl);
  min-height: 100vh;
  position: relative;
}

/* =========================================
   1. TOP BAR
   ========================================= */
.topbar {
  background: var(--mu-blue-dark);
  height: var(--topbar-height);
  display: flex;
  align-items: center;
  padding: 0 24px;
  gap: 16px;
}

.topbar-links {
  display: flex;
  align-items: center;
  gap: 4px;
  flex: 1;
}

.topbar-links a {
  color: rgba(255, 255, 255, 0.75);
  font-size: 13px;
  padding: 4px 8px;
  border-radius: var(--radius-sm);
}

.topbar-links a:hover {
  color: var(--mu-gold-light);
}

.topbar-links .sep {
  color: rgba(255, 255, 255, 0.25);
  font-size: 12px;
  margin: 0 4px;
}

/* ลบหรือคอมเม้นต์บรรทัด display: none; ด้านล่างออกเมื่อต้องการเปิดใช้งาน Facebook Link */
.topbar-social {
  display: none;
  align-items: center;
  gap: 8px;
}

/* <<<< ตรงนี้ */

.topbar-social a {
  display: flex;
  align-items: center;
  justify-content: center;
}

.topbar-social a:hover {
  transform: translateY(-1px);
  cursor: pointer;
}

.topbar-social img {
  width: 30px;
  height: 30px;
}

.topbar-lang a {
  display: flex;
  align-items: center;
  gap: 4px;
  color: rgba(255, 255, 255, 0.75);
  font-size: 12px;
  padding: 3px 10px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-full);
}

.topbar-lang a:hover {
  background: var(--mu-gold);
  border-color: var(--mu-gold);
  color: white;
}

.topbar-lang img {
  width: 20px;
  height: 14px;
  border-radius: 2px;
}

/* =========================================
   2. SITE HEADER
   ========================================= */
.site-header {
  background: linear-gradient(135deg, var(--mu-blue-dark) 0%, var(--mu-blue) 60%, var(--mu-blue-light) 100%);
  padding: 24px;
  display: flex;
  align-items: center;
  gap: 20px;
  position: relative;
  overflow: hidden;
}

.site-header::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--mu-gold) 0%, var(--mu-gold-light) 50%, var(--mu-gold) 100%);
}

.header-logo {
  flex-shrink: 0;
  height: 75px;
  display: flex;
  align-items: center;
}

.header-logo img {
  width: auto;
  height: 100%;
  max-width: 250px;
  object-fit: contain;
}

.logo-placeholder {
  display: none;
}

.header-text {
  flex: 1;
}

.header-dept-name {
  font-size: clamp(18px, 2.5vw, 26px);
  font-weight: 700;
  color: var(--white);
  line-height: 1.3;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  text-align: end;
}

.header-faculty-name {
  font-size: clamp(13px, 1.8vw, 16px);
  color: rgba(255, 255, 255, 0.75);
  margin-top: 4px;
  text-align: end;
}

.header-univ-name {
  font-size: clamp(12px, 1.5vw, 14px);
  color: var(--mu-gold-light);
  margin-top: 4px;
  font-weight: 500;
  letter-spacing: 0.5px;
}

/* =========================================
   3. NAVIGATION BAR
   ========================================= */
.navbar {
  background: var(--mu-blue);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 4px 20px rgba(25, 68, 136, 0.3);
}

.navbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--navbar-height);
  padding: 0 16px;
}

.navbar-brand {
  color: var(--white) !important;
  /* บังคับให้เป็นสีขาวตลอดเวลา */
  font-size: 15px;
  font-family: var(--font-base);
  font-weight: 400;
  letter-spacing: 0.3px;
}

.nav-menu {
  display: flex;
  align-items: center;
  height: 100%;
}

.nav-item {
  position: relative;
  height: 100%;
  display: flex;
  align-items: center;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 0 16px;
  height: 100%;
  color: rgba(255, 255, 255, 0.88);
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
  cursor: pointer;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 3px;
  background: var(--mu-gold);
  transition: width var(--transition-base);
}

.nav-link:hover,
.nav-link.active {
  color: var(--white);
  background: rgba(255, 255, 255, 0.08);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 60%;
}

.nav-arrow {
  font-size: 10px;
  opacity: 0.7;
  transition: transform var(--transition-fast);
}

.nav-item:hover .nav-arrow {
  transform: rotate(180deg);
}

/* Dropdown เมนู */
.dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  min-width: 240px;
  background: var(--white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: all var(--transition-base);
  border: 1px solid var(--gray-100);
  z-index: 1100;
}

.nav-item:hover .dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-item {
  display: block;
  padding: 12px 20px;
  color: var(--gray-700);
  font-size: 14.5px;
  border-bottom: 1px solid var(--gray-50);
  transition: all var(--transition-fast);
  position: relative;
}

.dropdown-item::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 0;
  background: var(--mu-blue);
  transition: width var(--transition-fast);
}

.dropdown-item:hover {
  background: var(--mu-blue-pale);
  color: var(--mu-blue);
  padding-left: 28px;
}

.dropdown-item:hover::before {
  width: 4px;
}

.dropdown-item:last-child {
  border-bottom: none;
}

/* Hamburger Menu (Transparent, White Lines like MN_TH) */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 6px;
  border-radius: 6px;
  transition: background 0.2s ease;
  border: none;
  background: none;
  box-shadow: none;
  width: auto;
  height: auto;
}

.hamburger:hover {
  background: rgba(255, 255, 255, 0.15);
  transform: none;
  box-shadow: none;
}

.hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: #ffffff;
  border-radius: 2px;
  transition: all 0.25s ease;
  transform-origin: center;
}

.hamburger span:nth-child(n+4) {
  display: none !important;
}

.hamburger.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.hamburger.open span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.hamburger.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.mobile-menu {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(0, 0, 0, 0);
  backdrop-filter: blur(0px);
  transition: all var(--transition-slow);
  pointer-events: none;
}

.mobile-menu.open {
  display: block;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  pointer-events: all;
}

.mobile-nav-panel {
  position: fixed;
  top: 0;
  right: -100%;
  width: min(320px, 85vw);
  height: 100%;
  background: var(--mu-blue-dark);
  overflow-y: auto;
  transition: right var(--transition-slow);
  display: flex;
  flex-direction: column;
}

.mobile-menu.open .mobile-nav-panel {
  right: 0;
}

.mobile-nav-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  background: var(--mu-blue);
}

.mobile-nav-title {
  color: white;
  font-size: 15px;
  font-weight: 600;
}

.mobile-close {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  border: none;
  background: rgba(255, 255, 255, 0.1);
  color: white;
  font-size: 20px;
}

.mobile-nav-list {
  padding: 16px 0;
  flex: 1;
}

.mobile-nav-item {
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.mobile-nav-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  color: rgba(255, 255, 255, 0.85);
  font-size: 15px;
  cursor: pointer;
}

.mobile-dropdown {
  display: none;
  background: rgba(0, 0, 0, 0.2);
}

.mobile-dropdown.open {
  display: block;
}

.mobile-dropdown a {
  display: block;
  padding: 12px 20px 12px 36px;
  color: rgba(255, 255, 255, 0.65);
  font-size: 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.mobile-dropdown a:hover {
  color: var(--mu-gold-light);
  background: rgba(255, 255, 255, 0.05);
}

/* =========================================
   4. MAIN CONTENT CONTAINER
   ========================================= */
.main-content {
  padding: 32px 24px;
  min-height: 400px;
}

/* =========================================
   5. SITE FOOTER
   ========================================= */
.site-footer {
  background: linear-gradient(135deg, var(--mu-blue-dark) 0%, var(--mu-blue) 100%);
  padding: 40px 24px;
  position: relative;
  overflow: hidden;
}

.site-footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--mu-gold), var(--mu-gold-light), var(--mu-gold));
}

.footer-inner {
  max-width: var(--container-max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 32px;
  align-items: start;
}

.footer-info h3 {
  font-size: 16px;
  font-weight: 700;
  color: white;
  margin-bottom: 8px;
}

.footer-info p {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.6;
  margin-bottom: 4px;
}

.footer-info a {
  color: var(--mu-gold-light);
}

.footer-info a:hover {
  color: var(--mu-gold);
}

.footer-copy {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.4);
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
}

/* ลบหรือคอมเม้นต์บรรทัด display: none; ด้านล่างออกเมื่อต้องการเปิดใช้งาน Facebook Link */
.footer-social {
  display: none;
  gap: 10px;
}

/* <<<< ตรงนี้ */

.footer-social a {
  display: flex;
  align-items: center;
  justify-content: center;
}

.footer-social a:hover {
  transform: translateY(-2px);
}

.footer-social img {
  width: 30px;
  height: 30px;
  object-fit: cover;
}

.footer-lang-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  color: rgba(255, 255, 255, 0.6);
  font-size: 13px;
  padding: 6px 14px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  transition: all 0.2s;
}

.footer-lang-btn:hover {
  background: var(--mu-gold);
  border-color: var(--mu-gold);
  color: white;
}

.footer-lang-btn img {
  width: 22px;
  height: 15px;
  border-radius: 2px;
}

/* BACK TO TOP BUTTON */
#back-to-top {
  position: fixed;
  right: 24px;
  bottom: 32px;
  width: 44px;
  height: 44px;
  background: linear-gradient(135deg, var(--mu-blue), var(--mu-blue-light));
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transition: all var(--transition-base);
  box-shadow: var(--shadow-md);
  z-index: 999;
  border: none;
}

#back-to-top.visible {
  opacity: 1;
  pointer-events: all;
}

#back-to-top svg {
  width: 20px;
  height: 20px;
  fill: white;
}

/* =========================================
   RESPONSIVE DESIGN BREAKPOINTS
   ========================================= */
@media (max-width: 960px) {
  .nav-menu {
    display: none;
  }

  .hamburger {
    display: flex;
  }

  .navbar-brand {
    color: white;
    font-size: 16px;
    font-weight: 600;
    display: block;
  }

  .footer-inner {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .footer-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 12px;
  }

  /* ลบหรือคอมเม้นต์บรรทัด display: none; ด้านล่างออกเมื่อต้องการเปิดใช้งาน Facebook Link */
  .footer-social {
    display: none;
    gap: 10px;
  }

  /* <<<< ตรงนี้ */

  .footer-social a {
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .footer-social a:hover {
    transform: translateY(-2px);
  }

  .footer-social img {
    width: 30px;
    height: 30px;
    object-fit: cover;
  }

  .footer-lang-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    color: rgba(255, 255, 255, 0.6);
    font-size: 13px;
    padding: 6px 14px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 999px;
    transition: all 0.2s;
  }

  .footer-lang-btn:hover {
    background: var(--mu-gold);
    border-color: var(--mu-gold);
    color: white;
  }

  .footer-lang-btn img {
    width: 22px;
    height: 15px;
    border-radius: 2px;
  }
}

@media (max-width: 768px) {
  .topbar {
    display: none;
  }

  .site-header {
    padding: 16px;
    flex-direction: column;
    text-align: center;
    gap: 12px;
  }

  .header-logo {
    width: 100%;
    height: 60px;
    justify-content: center;
  }

  .header-dept-name {
    font-size: 16px;
  }

  .header-faculty-name {
    font-size: 12px;
  }

  .main-content {
    padding: 20px 16px;
  }

  .head-page .breadcrumb {
    justify-content: flex-start;
  }
}

/* Modern Enhancements for Content */
.txt_head {
  font-family: 'Sarabun', sans-serif;
  font-size: 22px;
  color: var(--mu-blue);
  margin-bottom: 20px;
  font-weight: 600;
  border-bottom: 2px solid var(--mu-gold);
  padding-bottom: 10px;
  display: inline-block;
}

.txt_blue {
  font-family: 'Sarabun', sans-serif;
  font-size: 18px;
  color: var(--mu-blue-light);
  font-weight: 600;
  margin-top: 15px;
  margin-bottom: 10px;
}

.txt_font {
  font-family: 'Sarabun', sans-serif;
  margin-left: 2.5em;
  text-align: left;
  line-height: 1.6;
  margin-bottom: 15px;
}

.txt_name_bold {
  font-family: 'Sarabun', sans-serif;
  font-weight: 700;
  color: var(--gray-800);
}

.txt_blue_reg {
  font-family: 'Sarabun', sans-serif;
  color: var(--mu-blue);
}

.line_body {
  padding: 12px;
  border-bottom: 1px solid var(--gray-100);
}

.line_body:hover {
  background-color: var(--mu-blue-pale);
  transition: background-color 0.3s ease;
}

.hyperlink {
  color: var(--mu-blue-light);
  font-weight: 500;
  text-decoration: none;
}

.hyperlink:hover {
  color: var(--mu-gold);
  text-decoration: underline;
}

.hyperlink_menu {
  color: var(--mu-gold-dark);
  text-decoration: none;
}

.hyperlink_menu:hover {
  color: var(--mu-gold);
}

table {
  width: 100% !important;
  border-collapse: collapse;
  background: white;
}

td {
  vertical-align: top;
}

img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
}

.bg_blue {
  background: var(--mu-blue);
  color: white;
}

tr.bg_blue td,
tr.bg_blue th {
  padding: 14px 16px;
  font-weight: 600;
}

/* =========================================
   HEAD PAGE
   ========================================= */
.head-page {
  background:
    radial-gradient(circle at top right, rgba(56, 189, 248, 0.12), transparent 30%),
    linear-gradient(180deg, #ffffff 0%, #f7fbff 100%);
}

.head-page .page-title-banner {
  margin-bottom: 18px;
}

.head-page .breadcrumb {
  justify-content: center;
  margin-bottom: 18px;
}

.head-page .txt_font {
  text-indent: 0;
  text-align: center;
  color: var(--gray-600);
  margin-bottom: 18px;
}

.head-page .staff-container {
  padding-top: 4px;
}

.head-page .staff-grid {
  max-width: 1040px;
  margin: 0 auto;
  gap: 20px;
}

.head-page .staff-card {
  min-height: 100%;
}

.head-page .staff-img {
  width: 160px;
  height: 200px;
  object-fit: cover;
  object-position: center top;
  background: var(--white);
}

.head-page .staff-name {
  min-height: 3.2em;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  line-height: 1.5;
}

/* New CSS Grid and Card Styles for Head of Department list */
.head-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 24px;
  margin-top: 24px;
  max-width: 1040px;
  margin-left: auto;
  margin-right: auto;
  padding: 10px 0;
}

.head-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: 24px 20px;
  text-align: center;
  transition: transform var(--transition-base), box-shadow var(--transition-base);
  border: 1px solid var(--gray-100);
  position: relative;
  overflow: hidden;
}

.head-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
  border-color: var(--mu-blue-light);
}

.head-img-wrapper {
  width: 150px;
  height: 185px;
  border-radius: var(--radius-md);
  margin-bottom: 16px;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--gray-200);
  transition: transform var(--transition-base);
  background-color: var(--gray-50);
  display: flex;
  align-items: center;
  justify-content: center;
}

.head-card:hover .head-img-wrapper {
  transform: scale(1.03);
}

.head-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

.head-name {
  font-size: 16px;
  font-weight: 700;
  color: var(--gray-800);
  margin-bottom: 6px;
  line-height: 1.4;
  min-height: 2.8em;
  display: flex;
  align-items: center;
  justify-content: center;
}

.head-position {
  font-size: 13px;
  color: var(--gray-500);
  font-weight: 500;
}

/* =========================================
   STAFF GRID LAYOUT
   ========================================= */
.staff-container {
  padding: 10px 0;
}

.staff-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 24px;
  margin-top: 20px;
}

.staff-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: 24px;
  text-align: left;
  transition: transform var(--transition-base), box-shadow var(--transition-base);
  border: 1px solid var(--gray-100);
}

.staff-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.staff-img {
  width: 160px;
  height: 200px;
  object-fit: cover;
  border-radius: var(--radius-md);
  margin-bottom: 20px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--gray-100);
  transition: transform var(--transition-base);
}

.staff-name {
  font-size: 16px;
  font-weight: 700;
  color: var(--mu-blue-dark);
  margin-bottom: 6px;
  line-height: 1.4;
}

.staff-name a {
  color: inherit;
}

.staff-name a:hover {
  color: var(--mu-blue-light);
}

.staff-position {
  display: inline-block;
  align-self: flex-start;
  font-size: 13px;
  color: var(--mu-gold-dark);
  background: var(--mu-blue-pale);
  border: 1px solid var(--mu-gold-light);
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  margin-bottom: 16px;
  line-height: 1.4;
}

.staff-contact {
  font-size: 13px;
  color: var(--gray-600);
  width: 100%;
  line-height: 1.6;
}

.staff-contact p {
  margin-bottom: 4px;
}

.staff-contact a {
  color: var(--mu-blue-light);
  font-weight: 500;
}

.staff-contact a:hover {
  text-decoration: underline;
}

/* Make images larger on larger screens like in MN_TH (not applied to head-page) */
@media (min-width: 641px) {
  body:not(.head-page) .staff-card {
    padding: 0 0 24px 0;
    align-items: stretch;
    overflow: hidden;
    display: flex;
    flex-direction: column;
  }

  body:not(.head-page) .staff-card:hover .staff-img {
    transform: scale(1.03);
  }

  body:not(.head-page) .staff-img {
    width: 100%;
    height: auto;
    aspect-ratio: 4 / 5;
    border-radius: 0;
    margin-bottom: 18px;
    box-shadow: none;
    border: none;
    border-bottom: 1px solid var(--gray-100);
  }

  body:not(.head-page) .staff-name {
    padding: 0 20px;
  }

  body:not(.head-page) .staff-position {
    align-self: flex-start;
    margin-left: 20px;
  }

  body:not(.head-page) .staff-contact {
    padding: 0 20px;
  }

  .profile-link-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    width: 100%;
    box-sizing: border-box;
    margin: 12px 0 0 0;
    padding: 8px 6px;
    border-radius: 10px;
    background: linear-gradient(135deg, #194488 0%, #1d4ed8 100%);
    border: 1px solid #194488;
    color: #ffffff;
    font-family: 'Sarabun', sans-serif;
    font-size: 12px;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    transition: all 0.25s ease;
    box-shadow: 0 2px 8px rgba(25, 68, 136, 0.2);
  }

  .profile-link-btn:hover {
    background: #e8f0fb;
    color: #194488;
    border-color: #1d4ed8;
    box-shadow: 0 4px 14px rgba(25, 68, 136, 0.25);
  }
}

/* Mobile Staff Card Layout: Horizontal 1-column layout */
@media (max-width: 640px) {
  body:not(.head-page) .staff-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  body:not(.head-page) .staff-card {
    display: flex;
    flex-direction: row;
    padding: 12px;
    gap: 14px;
    align-items: stretch;
    border-radius: 14px;
    background: #ffffff;
    border: 1px solid var(--gray-200);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
  }

  body:not(.head-page) .staff-img {
    width: 110px;
    min-width: 110px;
    height: auto;
    aspect-ratio: 4 / 5;
    border-radius: 10px;
    margin-bottom: 0;
    object-fit: cover;
    flex-shrink: 0;
    border: 1px solid var(--gray-100);
  }

  body:not(.head-page) .staff-name {
    padding: 0;
    font-size: 14.5px;
    font-weight: 700;
    margin-bottom: 4px;
    line-height: 1.35;
  }

  body:not(.head-page) .staff-position {
    margin: 0 0 6px 0;
    font-size: 11px;
    padding: 3px 8px;
    border-radius: 6px;
    line-height: 1.3;
    align-self: flex-start;
  }

  body:not(.head-page) .staff-contact {
    padding: 0;
    font-size: 11.5px;
    line-height: 1.4;
    word-break: break-all;
  }

  body:not(.head-page) .staff-contact p {
    margin-bottom: 2px;
  }

  .profile-link-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 100%;
    margin: 8px 0 0 0;
    padding: 7px 0;
    border-radius: 8px;
    background: linear-gradient(135deg, #194488 0%, #1d4ed8 100%);
    border: 1px solid #194488;
    color: #ffffff;
    font-family: 'Sarabun', sans-serif;
    font-size: 12px;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    transition: all 0.25s ease;
  }

  .profile-link-btn:hover {
    background: #e8f0fb;
    color: #194488;
    border-color: #1d4ed8;
  }
}

/* =========================================
   PAGE TITLE BANNER
   ========================================= */
.page-title-banner {
  background: linear-gradient(135deg, var(--mu-blue-dark) 0%, var(--mu-blue) 100%);
  padding: 24px;
  display: flex;
  align-items: center;
  gap: 16px;
  border-bottom: 3px solid var(--mu-gold);
  margin-bottom: 24px;
  border-radius: var(--radius-md);
}

.page-title-text {
  font-size: clamp(18px, 2vw, 24px);
  font-weight: 700;
  color: white;
  font-family: var(--font-base);
}

.page-title-icon {
  width: 42px;
  height: 42px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border: 1px solid rgba(250, 204, 21, 0.4);
  color: #ffffff;
}

.page-title-icon svg {
  width: 22px;
  height: 22px;
  stroke: #ffffff;
  fill: none;
}

.page-title-icon i {
  font-size: 20px;
  color: #ffffff;
}

/* =========================================
   BREADCRUMB
   ========================================= */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.breadcrumb a,
.breadcrumb span {
  font-size: 13px;
  color: var(--gray-400);
  font-family: var(--font-base);
  transition: color var(--transition-fast);
}

.breadcrumb a:hover {
  color: var(--mu-blue);
}

.breadcrumb .sep {
  color: var(--gray-200);
  font-size: 12px;
}

.breadcrumb .current {
  color: var(--mu-blue);
  font-weight: 500;
}

/* =========================================
   ANIMATIONS
   ========================================= */
.animate-in {
  animation: slideUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes slideUp {
  0% {
    opacity: 0;
    transform: translateY(16px);
  }

  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* =========================================
   VISION / MISSION / PHILOSOPHY PAGE STYLES
   ========================================= */
.content-body {
  font-family: var(--font-base);
  font-size: 16px;
  color: var(--gray-700);
  line-height: 1.85;
}

.content-body p {
  margin-bottom: 20px;
  text-indent: 2.5em;
}

.content-heading {
  font-size: 20px;
  font-weight: 700;
  color: var(--mu-blue-dark);
  font-family: var(--font-base);
  padding: 12px 20px;
  background: var(--mu-blue-pale);
  border-left: 4px solid var(--mu-blue-light);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin: 32px 0 16px;
}

/* Mission list custom styles */
.mission-list {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 20px 0;
}

.mission-item {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  padding: 16px 20px;
  background: var(--gray-50);
  border-radius: var(--radius-md);
  border-left: 4px solid var(--mu-blue-light);
  transition: transform var(--transition-base), background var(--transition-base);
}

.mission-item:hover {
  background: var(--mu-blue-pale);
  transform: translateX(4px);
}

.mission-icon {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  background: var(--mu-blue-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 2px;
}

.mission-icon svg {
  width: 12px;
  height: 12px;
  fill: white;
}

.mission-text {
  font-size: 15.5px;
  color: var(--gray-700);
  font-family: var(--font-base);
  line-height: 1.7;
}

/* Philosophy & Vision Cards */
.vision-cards-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  margin-bottom: 32px;
}

@media (min-width: 570px) {
  .vision-cards-grid {
    grid-template-columns: 3fr 2fr;
  }
}

.philosophy-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--gray-100);
  border-top: 4px solid var(--mu-blue);
  position: relative;
  overflow: hidden;
  transition: transform var(--transition-base), box-shadow var(--transition-base);
}

.philosophy-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.philosophy-card::before {
  content: '"';
  position: absolute;
  top: 10px;
  right: 20px;
  font-size: 120px;
  font-family: serif;
  color: var(--mu-blue-pale);
  line-height: 1;
  pointer-events: none;
  opacity: 0.7;
}

.philosophy-card h3.txt_blue {
  color: var(--mu-blue-dark);
  margin-top: 0;
  margin-bottom: 16px;
}

.vision-card {
  background: linear-gradient(135deg, var(--mu-blue-dark) 0%, var(--mu-blue) 100%);
  color: var(--white);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow-sm);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  transition: transform var(--transition-base), box-shadow var(--transition-base);
}

.vision-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.vision-card::before {
  content: '';
  position: absolute;
  width: 150px;
  height: 150px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 50%;
  top: -50px;
  right: -50px;
}

.vision-card h3 {
  color: var(--mu-gold-light) !important;
  margin-top: 0;
  margin-bottom: 12px;
}

.vision-card p {
  color: rgba(255, 255, 255, 0.95);
  line-height: 1.7;
  margin-bottom: 0;
  text-indent: 0 !important;
}