/* ==========================================================================
   Dr. Dilip S. Kiyawat - News & Blog Page Styles
   File: css/pages/news.css
   Color Palette:
     Primary Purple: #5E125E
     Secondary Blue: #235293
     Accent Teal:    #48C0C0
     Dark Slate:     #0f172a / #1e293b
     Light Slate:    #f8fafc / #f1f5f9
   ========================================================================== */

:root {
  --blog-primary: var(--primary-purple, #5E125E);
  --blog-secondary: var(--secondary-blue, #235293);
  --blog-accent: var(--accent-teal, #48C0C0);
  --blog-dark: #0f172a;
  --blog-gray: #64748b;
  --blog-light-bg: #f8fafc;
  --blog-border: #e2e8f0;
}

/* --------------------------------------------------------------------------
   Hero Section
   -------------------------------------------------------------------------- */
.news-hero-section {
  position: relative;
  background: linear-gradient(135deg, rgba(94, 18, 94, 0.94) 0%, rgba(35, 82, 147, 0.92) 100%),
              url('../../images/aboutus/about.jpg') center/cover no-repeat;
  padding: 4.5rem 1.5rem 4rem;
  color: #ffffff;
  text-align: center;
  overflow: hidden;
}

.news-hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(circle at 20% 30%, rgba(72, 192, 192, 0.15) 0%, transparent 60%);
  pointer-events: none;
}

.news-hero-content {
  position: relative;
  max-width: 860px;
  margin: 0 auto;
  z-index: 2;
}

.news-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #ffffff;
  padding: 6px 18px;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  margin-bottom: 1.25rem;
  border: 1px solid rgba(255, 255, 255, 0.25);
}

.news-badge i {
  color: var(--blog-accent);
}

.news-hero-title {
  font-size: 2.75rem;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 1rem;
  color: #ffffff;
  letter-spacing: -0.5px;
}

.news-hero-subtitle {
  font-size: 1.15rem;
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.9);
  max-width: 720px;
  margin: 0 auto 1.5rem;
}

.news-breadcrumbs {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.8);
}

.news-breadcrumbs a {
  color: #ffffff;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s ease;
}

.news-breadcrumbs a:hover {
  color: var(--blog-accent);
}

.news-breadcrumbs i {
  font-size: 0.75rem;
  opacity: 0.7;
}

.news-breadcrumbs span {
  color: var(--blog-accent);
  font-weight: 600;
}

/* --------------------------------------------------------------------------
   Filter & Search Bar
   -------------------------------------------------------------------------- */
.news-toolbar-section {
  background: #ffffff;
  border-bottom: 1px solid var(--blog-border);
  padding: 1.25rem 0;
}

.news-toolbar-wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.news-category-filters {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.filter-pill {
  padding: 8px 18px;
  border-radius: 30px;
  font-size: 0.88rem;
  font-weight: 600;
  color: #475569;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  text-decoration: none;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.filter-pill:hover,
.filter-pill.active {
  background: var(--blog-primary);
  color: #ffffff;
  border-color: var(--blog-primary);
  box-shadow: 0 4px 12px rgba(94, 18, 94, 0.2);
}

.news-search-box {
  position: relative;
  min-width: 260px;
}

.news-search-box input {
  width: 100%;
  padding: 8px 14px 8px 36px;
  border-radius: 30px;
  border: 1px solid var(--blog-border);
  background: #f8fafc;
  font-size: 0.9rem;
  color: var(--blog-dark);
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.news-search-box input:focus {
  border-color: var(--blog-primary);
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(94, 18, 94, 0.1);
}

.news-search-box i {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
  font-size: 0.85rem;
}

/* --------------------------------------------------------------------------
   Main Content Layout: Articles + Sidebar
   -------------------------------------------------------------------------- */
.news-main-section {
  background: #f8fafc;
  padding: 3.5rem 0 5rem;
}

.news-layout-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 2.5rem;
  align-items: start;
}

/* --------------------------------------------------------------------------
   Article Card
   -------------------------------------------------------------------------- */
.news-articles-column {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.news-article-card {
  background: #ffffff;
  border-radius: 14px;
  border: 1px solid rgba(226, 232, 240, 0.8);
  box-shadow: 0 4px 20px rgba(15, 23, 42, 0.04);
  overflow: hidden;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  display: flex;
  flex-direction: column;
}

.news-article-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.09);
  border-color: rgba(94, 18, 94, 0.2);
}

.card-thumb-wrap {
  position: relative;
  width: 100%;
  height: 280px;
  overflow: hidden;
  background: #e2e8f0;
}

.card-thumb-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.news-article-card:hover .card-thumb-wrap img {
  transform: scale(1.04);
}

.card-cat-badge {
  position: absolute;
  top: 16px;
  left: 16px;
  background: var(--blog-primary);
  color: #ffffff;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  padding: 5px 14px;
  border-radius: 20px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  z-index: 2;
}

.card-cat-badge.badge-spine {
  background: var(--blog-secondary);
}

.card-body-wrap {
  padding: 1.75rem 2rem 2rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.card-meta-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.25rem;
  font-size: 0.85rem;
  color: var(--blog-gray);
  margin-bottom: 0.85rem;
}

.meta-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.meta-item i {
  color: var(--blog-accent);
}

.news-card-title {
  font-size: 1.45rem;
  font-weight: 750;
  line-height: 1.35;
  margin-bottom: 0.85rem;
  color: #1e293b;
}

.news-card-title a {
  color: #1e293b;
  text-decoration: none;
  transition: color 0.2s ease;
}

.news-card-title a:hover {
  color: var(--blog-primary);
}

.news-card-excerpt {
  font-size: 0.96rem;
  line-height: 1.68;
  color: #475569;
  margin-bottom: 1.5rem;
  flex-grow: 1;
}

.card-footer-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--blog-border);
}

.btn-read-more {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--blog-primary);
  color: #ffffff;
  padding: 8px 18px;
  border-radius: 8px;
  font-size: 0.88rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
}

.btn-read-more:hover {
  background: var(--blog-secondary);
  color: #ffffff;
  transform: translateX(2px);
  box-shadow: 0 4px 12px rgba(35, 82, 147, 0.25);
}

.card-treatment-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--blog-secondary);
  background: rgba(35, 82, 147, 0.08);
  padding: 5px 12px;
  border-radius: 6px;
  text-decoration: none;
  transition: all 0.2s ease;
}

.card-treatment-link:hover {
  background: var(--blog-secondary);
  color: #ffffff;
}

/* --------------------------------------------------------------------------
   Pagination Controls
   -------------------------------------------------------------------------- */
.news-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 3rem;
}

.pag-item {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 8px;
  background: #ffffff;
  border: 1px solid var(--blog-border);
  color: #334155;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  transition: all 0.2s ease;
}

.pag-item:hover,
.pag-item.active {
  background: var(--blog-primary);
  color: #ffffff;
  border-color: var(--blog-primary);
  box-shadow: 0 4px 12px rgba(94, 18, 94, 0.2);
}

.pag-item.disabled {
  opacity: 0.5;
  pointer-events: none;
}

/* --------------------------------------------------------------------------
   Sidebar Widgets
   -------------------------------------------------------------------------- */
.news-sidebar {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  position: sticky;
  top: 100px;
}

.sidebar-widget {
  background: #ffffff;
  border-radius: 14px;
  border: 1px solid var(--blog-border);
  box-shadow: 0 4px 18px rgba(15, 23, 42, 0.03);
  padding: 1.75rem;
}

.widget-title {
  font-size: 1.15rem;
  font-weight: 750;
  color: #0f172a;
  margin-bottom: 1.25rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--blog-primary);
  display: flex;
  align-items: center;
  gap: 10px;
}

.widget-title i {
  color: var(--blog-primary);
  font-size: 1rem;
}

/* Author Widget */
.author-widget-body {
  text-align: center;
}

.author-avatar-img {
  width: 110px;
  height: 110px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--blog-accent);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.1);
  margin: 0 auto 1rem;
}

.author-doctor-name {
  font-size: 1.25rem;
  font-weight: 750;
  color: #1e293b;
  margin-bottom: 0.25rem;
}

.author-doctor-role {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--blog-primary);
  margin-bottom: 0.75rem;
}

.author-doctor-bio {
  font-size: 0.88rem;
  line-height: 1.6;
  color: #64748b;
  margin-bottom: 1.25rem;
}

.btn-author-profile {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--blog-secondary);
  color: #ffffff;
  padding: 8px 18px;
  border-radius: 6px;
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.2s ease;
}

.btn-author-profile:hover {
  background: var(--blog-primary);
  color: #ffffff;
}

/* Services / Treatments Directory Widget */
.sidebar-treatments-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.sidebar-treatment-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 12px;
  border-radius: 8px;
  color: #334155;
  font-size: 0.88rem;
  font-weight: 500;
  text-decoration: none;
  background: #f8fafc;
  transition: all 0.2s ease;
}

.sidebar-treatment-link:hover {
  background: rgba(94, 18, 94, 0.08);
  color: var(--blog-primary);
  padding-left: 16px;
}

.sidebar-treatment-link i {
  font-size: 0.75rem;
  color: #94a3b8;
  transition: transform 0.2s ease, color 0.2s ease;
}

.sidebar-treatment-link:hover i {
  color: var(--blog-primary);
  transform: translateX(3px);
}

/* Recent Posts Widget */
.sidebar-recent-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.sidebar-post-item {
  display: flex;
  align-items: center;
  gap: 14px;
}

.sidebar-post-thumb {
  width: 72px;
  height: 72px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
  background: #e2e8f0;
}

.sidebar-post-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.sidebar-post-date {
  font-size: 0.75rem;
  color: var(--blog-gray);
  display: flex;
  align-items: center;
  gap: 5px;
}

.sidebar-post-title {
  font-size: 0.88rem;
  font-weight: 650;
  line-height: 1.35;
  color: #1e293b;
  text-decoration: none;
  transition: color 0.2s ease;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.sidebar-post-title:hover {
  color: var(--blog-primary);
}

/* Emergency & Consultation Widget */
.emergency-consultation-widget {
  background: linear-gradient(135deg, var(--blog-primary) 0%, var(--blog-secondary) 100%);
  color: #ffffff;
  border: none;
  text-align: center;
  padding: 2rem 1.5rem;
}

.emergency-consultation-widget .widget-title {
  color: #ffffff;
  border-bottom: none;
  justify-content: center;
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
  padding-bottom: 0;
}

.emergency-consultation-widget p {
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.6;
  margin-bottom: 1.25rem;
}

.emergency-phone-box {
  background: rgba(255, 255, 255, 0.15);
  border-radius: 10px;
  padding: 12px 14px;
  margin-bottom: 1.25rem;
  border: 1px solid rgba(255, 255, 255, 0.25);
}

.emergency-phone-box a {
  color: #ffffff;
  font-size: 1.15rem;
  font-weight: 750;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.emergency-phone-box a:hover {
  color: var(--blog-accent);
}

.btn-sidebar-book {
  display: block;
  width: 100%;
  background: var(--blog-accent);
  color: var(--blog-dark);
  font-weight: 750;
  padding: 10px 16px;
  border-radius: 8px;
  text-decoration: none;
  transition: all 0.2s ease;
  text-transform: uppercase;
  font-size: 0.85rem;
  letter-spacing: 0.5px;
}

.btn-sidebar-book:hover {
  background: #ffffff;
  color: var(--blog-primary);
  transform: translateY(-2px);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.2);
}

/* --------------------------------------------------------------------------
   Responsive Design
   -------------------------------------------------------------------------- */
@media (max-width: 991px) {
  .news-layout-grid {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
  
  .news-sidebar {
    position: static;
  }
  
  .news-hero-title {
    font-size: 2.25rem;
  }
  
  .card-thumb-wrap {
    height: 240px;
  }
}

@media (max-width: 768px) {
  .news-hero-section {
    padding: 3.5rem 1rem 3rem;
  }
  
  .news-hero-title {
    font-size: 1.95rem;
  }
  
  .news-hero-subtitle {
    font-size: 1rem;
  }
  
  .news-toolbar-wrapper {
    flex-direction: column;
    align-items: stretch;
  }
  
  .news-search-box {
    width: 100%;
  }
  
  .card-body-wrap {
    padding: 1.25rem 1.25rem 1.5rem;
  }
  
  .news-card-title {
    font-size: 1.25rem;
  }
  
  .card-thumb-wrap {
    height: 210px;
  }
}

@media (max-width: 480px) {
  .card-meta-row {
    gap: 0.75rem;
    font-size: 0.8rem;
  }
  
  .card-footer-row {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .btn-read-more {
    width: 100%;
    justify-content: center;
  }
}
