/* ==========================================================================
   Mesothelioma Legal Guide - Production Stylesheet
   Color Palette:
   - Primary Deep Navy: #0f4c81
   - Secondary Ocean Blue: #1b6ca8
   - Teal / Emerald Accent: #2a9d8f
   - Background Slate: #f4f7fb
   - Text Primary: #1f2937
   - Text Secondary: #4b5563
   - Card White: #ffffff
   ========================================================================== */

:root {
  --primary: #0f4c81;
  --primary-dark: #093256;
  --secondary: #1b6ca8;
  --accent: #2a9d8f;
  --accent-light: #eef7f5;
  --accent-dark: #1f786d;
  --bg-main: #f4f7fb;
  --bg-card: #ffffff;
  --text-main: #1f2937;
  --text-muted: #4b5563;
  --text-light: #6b7280;
  --border-color: #e5e7eb;
  --border-light: #eef2f7;
  --warning-bg: #fff7ed;
  --warning-border: #ea9a3e;
  --warning-text: #7c2d12;
  --shadow-sm: 0 2px 8px rgba(15, 76, 129, 0.05);
  --shadow-md: 0 8px 24px rgba(15, 76, 129, 0.08);
  --shadow-lg: 0 16px 36px rgba(15, 76, 129, 0.12);
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --transition-fast: 0.2s ease;
  --transition-normal: 0.3s ease;
  --font-stack: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-stack);
  background-color: var(--bg-main);
  color: var(--text-main);
  line-height: 1.7;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Reading Progress Bar */
#reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--accent), #48cae4);
  width: 0%;
  z-index: 9999;
  transition: width 0.1s linear;
}

a {
  color: var(--secondary);
  text-decoration: none;
  transition: color var(--transition-fast), text-decoration var(--transition-fast);
}

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

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* ==========================================================================
   Header & Navigation
   ========================================================================== */
.topnav-container {
  background: var(--primary);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
}

.topnav {
  max-width: 1120px;
  margin: 0 auto;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
}

.brand-link {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: #ffffff;
}

.brand-link:hover {
  text-decoration: none;
}

.brand-icon {
  width: 32px;
  height: 32px;
  background: var(--accent);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 900;
  font-size: 18px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

.brand-title {
  color: #ffffff;
  font-weight: 800;
  font-size: 19px;
  letter-spacing: -0.2px;
}

.nav-links-desktop {
  display: flex;
  align-items: center;
  gap: 14px;
  list-style: none;
}

.nav-links-desktop a {
  color: #dceef2;
  font-size: 13.5px;
  font-weight: 500;
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
  text-decoration: none;
  white-space: nowrap;
}

.nav-links-desktop a:hover,
.nav-links-desktop a.active {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
  text-decoration: none;
}

/* Mobile Nav Toggle */
.mobile-menu-btn {
  display: none;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #fff;
  padding: 8px 12px;
  border-radius: 6px;
  font-size: 15px;
  cursor: pointer;
  align-items: center;
  gap: 6px;
}

.mobile-menu-btn:focus-visible {
  outline: 2px solid var(--accent);
}

/* Mobile Dropdown Menu */
.mobile-nav-drawer {
  display: none;
  background: var(--primary-dark);
  padding: 16px 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

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

.mobile-nav-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.mobile-nav-list a {
  color: #dceef2;
  font-size: 14.5px;
  font-weight: 500;
  display: block;
  padding: 9px 12px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.05);
  text-decoration: none;
}

.mobile-nav-list a:hover,
.mobile-nav-list a.active {
  background: var(--secondary);
  color: #ffffff;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero {
  background: linear-gradient(135deg, #0f4c81 0%, #1b6ca8 45%, #2a9d8f 100%);
  color: #ffffff;
  padding: 56px 20px 76px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 20px;
  background: var(--bg-main);
  clip-path: ellipse(55% 100% at 50% 100%);
}

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

.hero-badge {
  display: inline-block;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #e6f2ef;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 5px 14px;
  border-radius: 20px;
  margin-bottom: 16px;
}

.hero h1 {
  font-size: 34px;
  font-weight: 800;
  margin: 0 0 16px;
  line-height: 1.25;
  letter-spacing: -0.5px;
}

.hero p.subtitle {
  font-size: 17px;
  color: #e6f2ef;
  max-width: 680px;
  margin: 0 auto;
  line-height: 1.6;
}

/* ==========================================================================
   Layout Containers
   ========================================================================== */
.layout {
  max-width: 1120px;
  margin: -40px auto 60px;
  padding: 0 20px;
  display: grid;
  grid-template-columns: 2.3fr 1fr;
  gap: 28px;
  position: relative;
  z-index: 2;
}

.layout-single {
  grid-template-columns: 1fr;
}

.content-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 38px 36px;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-light);
}

/* ==========================================================================
   Article / Content Formatting
   ========================================================================== */
.breadcrumb-nav {
  margin-bottom: 22px;
  font-size: 13.5px;
  color: var(--text-light);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.breadcrumb-nav a {
  color: var(--secondary);
  font-weight: 500;
}

.breadcrumb-nav a:hover {
  text-decoration: underline;
}

.article-header {
  border-bottom: 1px solid var(--border-light);
  padding-bottom: 24px;
  margin-bottom: 28px;
}

.article-header h1 {
  font-size: 30px;
  font-weight: 800;
  color: var(--primary);
  line-height: 1.25;
  margin-bottom: 14px;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
  font-size: 13.5px;
  color: var(--text-light);
}

.meta-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.article-body h2 {
  font-size: 24px;
  font-weight: 800;
  color: var(--primary);
  margin: 36px 0 16px;
  border-left: 5px solid var(--accent);
  padding-left: 14px;
  line-height: 1.3;
}

.article-body h2:first-of-type {
  margin-top: 10px;
}

.article-body h3 {
  font-size: 19px;
  font-weight: 700;
  color: var(--secondary);
  margin: 26px 0 12px;
  line-height: 1.35;
}

.article-body p {
  font-size: 16px;
  color: #374151;
  margin-bottom: 18px;
  line-height: 1.75;
}

.article-body ul, 
.article-body ol {
  padding-left: 24px;
  margin-bottom: 20px;
}

.article-body li {
  font-size: 16px;
  color: #374151;
  margin-bottom: 9px;
  line-height: 1.65;
}

.article-body strong {
  color: var(--primary);
  font-weight: 700;
}

/* Callouts & Info Boxes */
.highlight-box {
  background: var(--accent-light);
  border-left: 4px solid var(--accent);
  padding: 18px 20px;
  border-radius: var(--radius-md);
  margin: 24px 0;
  font-size: 15.5px;
  color: #14532d;
  line-height: 1.65;
}

.highlight-box strong {
  color: #064e3b;
}

.warning-box {
  background: var(--warning-bg);
  border-left: 4px solid var(--warning-border);
  padding: 18px 20px;
  border-radius: var(--radius-md);
  margin: 24px 0;
  font-size: 15.5px;
  color: var(--warning-text);
  line-height: 1.65;
}

.warning-box strong {
  color: #9a3412;
}

.checklist {
  background: #f0f6ff;
  border: 1px solid #dbeafe;
  border-radius: var(--radius-md);
  padding: 22px 24px;
  margin: 24px 0;
}

.checklist h4 {
  color: var(--primary);
  font-size: 17px;
  margin-bottom: 12px;
  font-weight: 700;
}

.checklist ul {
  list-style-type: none;
  padding-left: 0;
  margin-bottom: 0;
}

.checklist li {
  position: relative;
  padding-left: 26px;
  margin-bottom: 10px;
  font-size: 15px;
}

.checklist li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 0;
  color: var(--accent);
  font-weight: 900;
  font-size: 16px;
}

/* Data Tables */
.table-responsive {
  overflow-x: auto;
  margin: 24px 0;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 15px;
  background: #ffffff;
}

.data-table th {
  background: #f8fafc;
  color: var(--primary);
  font-weight: 700;
  padding: 14px 16px;
  border-bottom: 2px solid var(--border-color);
}

.data-table td {
  padding: 13px 16px;
  border-bottom: 1px solid var(--border-light);
  color: #374151;
}

.data-table tr:last-child td {
  border-bottom: none;
}

.data-table tr:hover td {
  background-color: #fbfdff;
}

/* FAQ Box */
.faq-section {
  margin: 36px 0 20px;
}

.faq-item {
  background: #fafcff;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 18px 22px;
  margin-bottom: 14px;
}

.faq-item h4 {
  color: var(--primary);
  font-size: 16.5px;
  margin-bottom: 8px;
  font-weight: 700;
}

.faq-item p {
  margin-bottom: 0;
  font-size: 15px;
  color: var(--text-muted);
}

/* Author Box / Medical Review Tag */
.author-box {
  background: #f8fafc;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 20px;
  margin-top: 36px;
  display: flex;
  gap: 16px;
  align-items: center;
}

.author-avatar {
  width: 50px;
  height: 50px;
  background: var(--primary);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 20px;
  flex-shrink: 0;
}

.author-info h4 {
  font-size: 15.5px;
  color: var(--primary);
  margin-bottom: 4px;
}

.author-info p {
  font-size: 13px;
  color: var(--text-light);
  margin-bottom: 0;
}

/* ==========================================================================
   Card Grid (Homepage / Guides Index)
   ========================================================================== */
.section-header {
  margin-bottom: 24px;
}

.section-header h2 {
  font-size: 26px;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 8px;
  border-left: 5px solid var(--accent);
  padding-left: 14px;
}

.section-header p {
  font-size: 16px;
  color: var(--text-muted);
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  margin-top: 20px;
}

.article-card {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 26px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
  position: relative;
}

.article-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: #cbd5e1;
}

.card-badge {
  display: inline-block;
  background: #e0f2fe;
  color: var(--secondary);
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 3px 10px;
  border-radius: 12px;
  margin-bottom: 12px;
  align-self: flex-start;
}

.article-card h3 {
  margin-top: 0;
  margin-bottom: 12px;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.35;
}

.article-card h3 a {
  color: var(--primary);
  text-decoration: none;
}

.article-card h3 a:hover {
  color: var(--secondary);
  text-decoration: none;
}

.article-card p {
  font-size: 14.5px;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 20px;
  flex-grow: 1;
}

.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid #f1f5f9;
  padding-top: 14px;
  margin-top: auto;
}

.card-footer a.readmore {
  font-size: 14px;
  font-weight: 700;
  color: var(--secondary);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: gap var(--transition-fast), color var(--transition-fast);
}

.card-footer a.readmore:hover {
  color: var(--primary);
  gap: 10px;
  text-decoration: none;
}

.read-time {
  font-size: 12.5px;
  color: var(--text-light);
}

/* Homepage Value Highlights */
.value-highlights {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 40px;
  padding-top: 30px;
  border-top: 1px solid var(--border-light);
}

.value-item {
  background: #f8fafc;
  border-radius: var(--radius-md);
  padding: 20px;
  border: 1px solid var(--border-light);
}

.value-icon {
  font-size: 24px;
  margin-bottom: 10px;
  color: var(--accent);
}

.value-item h4 {
  font-size: 16px;
  color: var(--primary);
  margin-bottom: 6px;
  font-weight: 700;
}

.value-item p {
  font-size: 13.5px;
  color: var(--text-muted);
  margin-bottom: 0;
  line-height: 1.55;
}

/* ==========================================================================
   Sidebar
   ========================================================================== */
.sidebar {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 26px 22px;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-light);
  height: fit-content;
  position: sticky;
  top: 80px;
}

.sidebar-widget {
  margin-bottom: 28px;
}

.sidebar-widget:last-child {
  margin-bottom: 0;
}

.sidebar h3 {
  color: var(--primary);
  font-size: 16.5px;
  margin-top: 0;
  border-bottom: 2px solid var(--border-light);
  padding-bottom: 10px;
  margin-bottom: 16px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
}

.sidebar ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.sidebar li {
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid #f8fafc;
}

.sidebar li:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.sidebar li a {
  font-size: 14px;
  font-weight: 600;
  color: var(--secondary);
  display: block;
  line-height: 1.4;
  transition: color var(--transition-fast);
}

.sidebar li a:hover,
.sidebar li.active a {
  color: var(--primary);
  text-decoration: none;
}

.sidebar li span {
  display: block;
  font-size: 12px;
  color: var(--text-light);
  font-weight: 400;
  margin-top: 3px;
}

.sidebar-cta {
  background: linear-gradient(135deg, #0f4c81 0%, #1b6ca8 100%);
  color: #fff;
  border-radius: var(--radius-md);
  padding: 20px;
  text-align: center;
}

.sidebar-cta h4 {
  font-size: 16px;
  margin-bottom: 8px;
  color: #fff;
}

.sidebar-cta p {
  font-size: 13px;
  color: #dceef2;
  margin-bottom: 14px;
}

.btn-cta {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  font-size: 13.5px;
  padding: 8px 16px;
  border-radius: 6px;
  text-decoration: none;
  transition: background var(--transition-fast);
}

.btn-cta:hover {
  background: #238b7e;
  color: #fff;
  text-decoration: none;
}

/* ==========================================================================
   Forms (Contact Page)
   ========================================================================== */
.form-group {
  margin-bottom: 20px;
}

.form-label {
  display: block;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 6px;
}

.form-control {
  width: 100%;
  padding: 12px 14px;
  font-size: 15px;
  font-family: inherit;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  background: #ffffff;
  color: var(--text-main);
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.form-control:focus {
  outline: none;
  border-color: var(--secondary);
  box-shadow: 0 0 0 3px rgba(27, 108, 168, 0.15);
}

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

.btn-primary {
  background: var(--primary);
  color: #ffffff;
  border: none;
  padding: 12px 24px;
  font-size: 15px;
  font-weight: 700;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: background var(--transition-fast), transform var(--transition-fast);
}

.btn-primary:hover {
  background: var(--primary-dark);
  color: #fff;
}

.form-alert {
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  margin-top: 16px;
  display: none;
  font-size: 14.5px;
}

.form-alert.success {
  display: block;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  color: #065f46;
}

/* ==========================================================================
   Footer
   ========================================================================== */
footer.sitefooter {
  background: var(--primary);
  color: #dceef2;
  padding: 46px 20px 30px;
  margin-top: 40px;
  border-top: 4px solid var(--accent);
}

footer.sitefooter .foot-wrap {
  max-width: 1120px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.5fr 1.8fr 1fr;
  gap: 36px;
}

footer.sitefooter h4 {
  color: #ffffff;
  font-size: 16px;
  margin: 0 0 16px;
  font-weight: 700;
  letter-spacing: -0.2px;
}

footer.sitefooter p {
  font-size: 13.5px;
  color: #cfe4e9;
  line-height: 1.65;
}

footer.sitefooter ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

footer.sitefooter li {
  margin-bottom: 9px;
}

footer.sitefooter a {
  color: #cfe4e9;
  font-size: 13.5px;
  transition: color var(--transition-fast);
}

footer.sitefooter a:hover {
  color: #ffffff;
  text-decoration: underline;
}

.footer-bottom {
  max-width: 1120px;
  margin: 32px auto 0;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
}

.disclaimer {
  max-width: 1000px;
  margin: 0 auto;
  font-size: 12px;
  color: #9fb8c9;
  line-height: 1.6;
}

.copyright {
  font-size: 12.5px;
  color: #7b9cb2;
  margin-top: 10px;
}

/* ==========================================================================
   Responsive Breakpoints
   ========================================================================== */
@media (max-width: 960px) {
  .layout {
    grid-template-columns: 1fr;
  }
  .sidebar {
    position: static;
    margin-top: 20px;
  }
  footer.sitefooter .foot-wrap {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .nav-links-desktop {
    display: none;
  }
  .mobile-menu-btn {
    display: inline-flex;
  }
  .hero {
    padding: 42px 16px 60px;
  }
  .hero h1 {
    font-size: 26px;
  }
  .hero p.subtitle {
    font-size: 15px;
  }
  .content-card {
    padding: 26px 20px;
  }
  .card-grid {
    grid-template-columns: 1fr;
  }
  .value-highlights {
    grid-template-columns: 1fr;
  }
  footer.sitefooter .foot-wrap {
    grid-template-columns: 1fr;
    gap: 26px;
  }
  .article-header h1 {
    font-size: 24px;
  }
}
