/* ==========================================================================
   UMRI HOSPITAL - DEPARTMENT PAGES ULTIMATE UI/UX STYLESHEET
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&family=Outfit:wght@500;600;700;800&display=swap');

:root {
  --dept-primary: #0284c7;
  --dept-primary-dark: #0369a1;
  --dept-accent: #dc2626;
  --dept-bg-dark: #0f172a;
  --dept-card-bg: #ffffff;
  --dept-text-main: #1e293b;
  --dept-text-muted: #64748b;
  --dept-border-color: #e2e8f0;
  --dept-shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
  --dept-shadow-lg: 0 20px 25px -5px rgba(15, 23, 42, 0.08), 0 10px 10px -5px rgba(15, 23, 42, 0.04);
  --dept-radius: 16px;
  --dept-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
  font-family: 'Plus Jakarta Sans', sans-serif;
  color: var(--dept-text-main);
  background-color: #f8fafc;
}

/* ==========================================================================
   1. HERO BANNER
   ========================================================================== */
.dept-hero-section {
  position: relative;
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 50%, #0369a1 100%);
  color: #ffffff;
  padding: 3.5rem 0 3rem;
  overflow: hidden;
}

.dept-hero-section::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.15) 0%, rgba(2, 132, 199, 0) 70%);
  border-radius: 50%;
  pointer-events: none;
}

.dept-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1.25rem;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 50px;
  font-size: 0.875rem;
  font-weight: 600;
  color: #38bdf8;
  margin-bottom: 1rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.dept-hero-title {
  font-family: 'Outfit', sans-serif;
  font-size: 2.75rem;
  font-weight: 800;
  line-height: 1.15;
  color: #ffffff;
  margin-bottom: 0.75rem;
  letter-spacing: -0.02em;
}

.dept-hero-desc {
  font-size: 1.05rem;
  color: #94a3b8;
  max-width: 720px;
  line-height: 1.6;
  margin-bottom: 1.75rem;
}

.dept-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
}

.btn-dept-cta {
  padding: 0.875rem 1.75rem;
  font-weight: 700;
  border-radius: 12px;
  transition: var(--dept-transition);
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  text-decoration: none;
}

.btn-dept-primary {
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
  color: #ffffff !important;
  border: none;
  box-shadow: 0 8px 20px rgba(2, 132, 199, 0.35);
}

.btn-dept-primary:hover {
  background: linear-gradient(135deg, #0369a1 0%, #075985 100%);
  color: #ffffff !important;
  transform: translateY(-2px);
  box-shadow: 0 12px 24px rgba(2, 132, 199, 0.45);
}

.btn-dept-outline {
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.25);
  backdrop-filter: blur(8px);
}

.btn-dept-outline:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.4);
  transform: translateY(-2px);
}

/* Breadcrumb */
.dept-breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  color: #64748b;
  margin-top: 1.5rem;
}

.dept-breadcrumb a {
  color: #94a3b8;
  text-decoration: none;
  transition: var(--dept-transition);
}

.dept-breadcrumb a:hover {
  color: #38bdf8;
}

/* ==========================================================================
   2. MAIN CONTENT STYLING
   ========================================================================== */
.department-details {
  padding: 3rem 0 4rem;
}

.dept-main-card {
  background: var(--dept-card-bg);
  border-radius: var(--dept-radius);
  padding: 2.25rem;
  border: 1px solid var(--dept-border-color);
  box-shadow: var(--dept-shadow-lg);
  margin-bottom: 2rem;
}

.department-details h2.section-title {
  font-family: 'Outfit', sans-serif;
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--dept-text-main);
  margin-bottom: 1.25rem;
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.department-details h2.section-title::before {
  content: '';
  display: inline-block;
  width: 6px;
  height: 28px;
  background: linear-gradient(180deg, #0284c7 0%, #0369a1 100%);
  border-radius: 4px;
}

.department-details h3 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.3rem;
  font-weight: 700;
  color: #0f172a;
  margin-top: 2rem;
  margin-bottom: 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.625rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid #f1f5f9;
}

.department-details p {
  font-size: 1.05rem;
  line-height: 1.7;
  color: #334155;
}

/* Conditions & Services Grid Transformation */
.department-details ul.list-style {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.department-details ul.list-style li {
  background: #f8fafc;
  padding: 1rem 1.25rem;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  font-weight: 600;
  color: #334155;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  transition: var(--dept-transition);
  box-shadow: var(--dept-shadow-sm);
}

.department-details ul.list-style li::before {
  content: '\f00c';
  font-family: 'Font Awesome 5 Free';
  font-weight: 900;
  color: #0284c7;
  background: #e0f2fe;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  flex-shrink: 0;
}

.department-details ul.list-style li:hover {
  background: #ffffff;
  border-color: #38bdf8;
  transform: translateY(-2px);
  box-shadow: 0 10px 15px -3px rgba(2, 132, 199, 0.1);
}

/* ==========================================================================
   3. DOCTORS SHOWCASE SECTION
   ========================================================================== */
.dept-doctors-section {
  margin-top: 2.5rem;
}

.dept-doctor-card {
  background: #ffffff;
  border-radius: 16px;
  border: 1px solid #e2e8f0;
  padding: 1.5rem;
  transition: var(--dept-transition);
  box-shadow: var(--dept-shadow-sm);
  height: 100%;
  display: flex;
  flex-direction: column;
}

.dept-doctor-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--dept-shadow-lg);
  border-color: #38bdf8;
}

.dept-doctor-avatar {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  background: linear-gradient(135deg, #e0f2fe 0%, #bae6fd 100%);
  color: #0284c7;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  font-weight: 700;
  margin-bottom: 1rem;
  border: 3px solid #ffffff;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
}

.dept-doctor-name {
  font-family: 'Outfit', sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 0.25rem;
}

.dept-doctor-degree {
  font-size: 0.85rem;
  color: #0284c7;
  font-weight: 600;
  margin-bottom: 0.35rem;
}

.dept-doctor-spec {
  font-size: 0.8rem;
  color: #64748b;
  margin-bottom: 1.25rem;
}

.dept-doctor-btn {
  margin-top: auto;
  width: 100%;
  border-radius: 10px;
  font-weight: 600;
  padding: 0.625rem 1rem;
}

/* ==========================================================================
   4. STICKY SIDEBAR STYLING (ALIGNED RIGHT NEXT TO OVERVIEW)
   ========================================================================== */
.dept-sidebar-col {
  align-self: flex-start;
}

.dept-sidebar-wrapper {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  position: -webkit-sticky;
  position: sticky;
  top: 90px;
  align-self: flex-start;
  z-index: 10;
  width: 100%;
}

/* OPD Booking Widget */
.dept-booking-widget {
  background: #ffffff;
  border-radius: var(--dept-radius);
  padding: 1.75rem;
  border: 1px solid var(--dept-border-color);
  box-shadow: var(--dept-shadow-lg);
  transition: var(--dept-transition);
}

.dept-booking-widget:hover {
  border-color: #38bdf8;
  box-shadow: 0 20px 25px -5px rgba(2, 132, 199, 0.12);
}

.dept-booking-widget h4 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.25rem;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Emergency Box */
.dept-emergency-box {
  background: linear-gradient(135deg, #dc2626 0%, #991b1b 100%);
  color: #ffffff;
  border-radius: var(--dept-radius);
  padding: 1.75rem;
  box-shadow: 0 12px 25px rgba(220, 38, 38, 0.25);
  position: relative;
  overflow: hidden;
}

.dept-emergency-box::after {
  content: '\f0f9';
  font-family: 'Font Awesome 5 Free';
  font-weight: 900;
  position: absolute;
  right: -15px;
  bottom: -20px;
  font-size: 6.5rem;
  color: rgba(255, 255, 255, 0.08);
  pointer-events: none;
}

.dept-emergency-box h3 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.25rem;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 0.35rem;
  border: none;
  padding: 0;
}

.dept-emergency-box p {
  color: #fca5a5;
  font-size: 0.875rem;
  margin-bottom: 1.15rem;
}

.btn-emergency-call {
  background: #ffffff;
  color: #dc2626 !important;
  font-weight: 800;
  padding: 0.75rem 1.15rem;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  text-decoration: none;
  transition: var(--dept-transition);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.btn-emergency-call:hover {
  background: #fef2f2;
  color: #991b1b !important;
  transform: translateY(-2px);
}

.btn-whatsapp-call {
  background: #22c55e;
  color: #ffffff !important;
  font-weight: 700;
  padding: 0.75rem 1.15rem;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  text-decoration: none;
  margin-top: 0.75rem;
  transition: var(--dept-transition);
}

.btn-whatsapp-call:hover {
  background: #16a34a;
  color: #ffffff !important;
  transform: translateY(-2px);
}

/* Directory Nav Box */
.dept-directory-box {
  background: #ffffff;
  border-radius: var(--dept-radius);
  padding: 1.5rem;
  border: 1px solid var(--dept-border-color);
  box-shadow: var(--dept-shadow-sm);
}

.dept-directory-box h4 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid #f1f5f9;
}

.dept-directory-list {
  list-style: none;
  padding: 0;
  margin: 0;
  max-height: 320px;
  overflow-y: auto;
}

.dept-directory-list::-webkit-scrollbar {
  width: 5px;
}

.dept-directory-list::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 10px;
}

.dept-directory-item a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.625rem 0.875rem;
  border-radius: 10px;
  color: #475569;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.875rem;
  transition: var(--dept-transition);
  margin-bottom: 0.25rem;
}

.dept-directory-item a:hover {
  background: #f0f9ff;
  color: #0284c7;
  transform: translateX(3px);
}

.dept-directory-item.active a {
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
  color: #ffffff !important;
  box-shadow: 0 4px 12px rgba(2, 132, 199, 0.25);
}

/* Media Queries & Responsive Layout Controls */
@media (max-width: 991.98px) {
  .dept-hero-title {
    font-size: 2.15rem;
  }
  .dept-sidebar-col {
    align-self: auto;
  }
  .dept-sidebar-wrapper {
    position: static;
    margin-top: 1.5rem;
  }
}
