/* ============================================================
   MILAN DAY MATKA CHART - PREMIUM RESPONSIVE CSS
   FixResult.in Design System
   Optimized from Desktop down to 320px Ultra-Compact Mobile
   ============================================================ */

:root {
  --md-brand: #0b66a0;
  --md-brand-dark: #074f80;
  --md-brand-deep: #053353;
  --md-brand-light: #e0f0ff;
  --md-brand-subtle: #f0f7ff;
  --md-gold: #f59e0b;
  --md-gold-light: #fef3c7;
  --md-crimson: #dc2626;
  --md-crimson-bg: #fee2e2;
  --md-green: #059669;
  --md-green-light: #d1fae5;
  --md-text-head: #0f172a;
  --md-text-body: #334155;
  --md-text-muted: #64748b;
  --md-text-light: #94a3b8;
  --md-bg: #f0f4f8;
  --md-card: #ffffff;
  --md-border: #e2e8f0;
  --md-border-focus: #93c5fd;
  --md-radius-sm: 8px;
  --md-radius-md: 12px;
  --md-radius-lg: 16px;
  --md-shadow-sm: 0 2px 8px rgba(15, 23, 42, 0.05);
  --md-shadow-md: 0 6px 20px rgba(11, 102, 160, 0.08);
  --md-shadow-hover: 0 12px 30px rgba(11, 102, 160, 0.14);
  --ff-head: 'Poppins', sans-serif;
  --ff-body: 'Gabarito', sans-serif;
  --ff-mono: Consolas, 'Liberation Mono', Menlo, Monaco, monospace;
}

/* Base & Global Reset */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  padding: 0;
  background-color: var(--md-bg);
  color: var(--md-text-body);
  font-family: var(--ff-body), -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 15px;
  line-height: 1.6;
  overflow-x: hidden;
  width: 100%;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Accessibility: Skip link */
.skip-link {
  position: absolute;
  top: -60px;
  left: 16px;
  padding: 10px 18px;
  background: var(--md-brand-dark);
  color: #fff;
  border-radius: var(--md-radius-sm);
  z-index: 9999;
  font-weight: 700;
  text-decoration: none;
  transition: top 0.2s ease;
}
.skip-link:focus {
  top: 16px;
}

/* Responsive Wrap Container */
.wrap {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 16px;
}
@media (min-width: 768px) {
  .wrap {
    padding: 0 24px;
  }
}
@media (max-width: 480px) {
  .wrap {
    padding: 0 10px;
  }
}
@media (max-width: 360px) {
  .wrap {
    padding: 0 8px;
  }
}

/* Site Header */
.site-header {
  background: #ffffff;
  border-bottom: 1px solid var(--md-border);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.04);
}

.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--md-brand);
  font-family: var(--ff-head);
  font-size: 21px;
  font-weight: 800;
  letter-spacing: -0.2px;
}
.brand img {
  border-radius: 8px;
  display: block;
}
.brand-dot {
  color: var(--md-gold);
}

.top-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}
.top-nav a {
  text-decoration: none;
  color: var(--md-text-body);
  font-size: 13.5px;
  font-weight: 600;
  padding: 7px 12px;
  border-radius: var(--md-radius-sm);
  transition: all 0.2s ease;
  white-space: nowrap;
}
.top-nav a:hover {
  color: var(--md-brand);
  background: var(--md-brand-light);
}

/* Breadcrumbs */
.breadcrumbs {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 13px;
  color: var(--md-text-muted);
  margin: 18px 0;
  padding: 9px 16px;
  background: #ffffff;
  border: 1px solid var(--md-border);
  border-radius: var(--md-radius-sm);
  box-shadow: var(--md-shadow-sm);
  word-break: break-word;
}
.breadcrumbs a {
  color: var(--md-brand);
  text-decoration: none;
  font-weight: 600;
  transition: color 0.15s;
}
.breadcrumbs a:hover {
  color: var(--md-brand-dark);
  text-decoration: underline;
}
.breadcrumbs span[aria-current="page"] {
  color: var(--md-text-head);
  font-weight: 700;
}

/* Card Container */
.card {
  background: var(--md-card);
  border: 1px solid var(--md-border);
  border-radius: var(--md-radius-md);
  padding: 24px;
  margin-bottom: 20px;
  box-shadow: var(--md-shadow-sm);
}
@media (min-width: 768px) {
  .card {
    padding: 28px 24px;
    margin-bottom: 24px;
  }
}

/* Hero Section */
.hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #ffffff 0%, #f8fbfe 100%);
  border-top: 4px solid var(--md-brand);
}
.hero::after {
  content: "";
  position: absolute;
  top: -80px;
  right: -80px;
  width: 240px;
  height: 240px;
  background: radial-gradient(circle, rgba(11, 102, 160, 0.08) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 12px;
  color: var(--md-brand-dark);
  background: var(--md-brand-light);
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  margin-bottom: 12px;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--md-green);
  box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.25);
  display: inline-block;
  animation: mdPulse 2s infinite ease-in-out;
}
@keyframes mdPulse {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(5, 150, 105, 0.4); }
  70% { transform: scale(1.05); box-shadow: 0 0 0 6px rgba(5, 150, 105, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(5, 150, 105, 0); }
}

.hero h1 {
  margin: 0 0 12px;
  color: var(--md-text-head);
  font-family: var(--ff-head);
  font-size: 26px;
  font-weight: 800;
  line-height: 1.25;
}
@media (min-width: 768px) {
  .hero h1 {
    font-size: 32px;
  }
}

.lede {
  color: var(--md-text-body);
  font-size: 15px;
  line-height: 1.65;
  margin: 0 0 14px;
}
.lede strong {
  color: var(--md-brand-dark);
}

.hero-note {
  margin: 0 0 20px;
  padding: 10px 14px;
  background: var(--md-brand-subtle);
  border-left: 3px solid var(--md-brand);
  border-radius: 4px;
  color: var(--md-text-muted);
  font-size: 13.5px;
}

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

/* Button System */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 20px;
  border-radius: var(--md-radius-sm);
  font-family: var(--ff-head);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.2s ease;
  line-height: 1.2;
  min-height: 42px;
}

.button-primary {
  background: linear-gradient(135deg, var(--md-brand) 0%, var(--md-brand-dark) 100%);
  color: #ffffff !important;
  box-shadow: 0 4px 14px rgba(11, 102, 160, 0.28);
}
.button-primary:hover {
  background: linear-gradient(135deg, var(--md-brand-dark) 0%, var(--md-brand-deep) 100%);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(11, 102, 160, 0.36);
}

.button-subtle {
  background: #ffffff;
  color: var(--md-text-head) !important;
  border-color: var(--md-border);
  box-shadow: var(--md-shadow-sm);
}
.button-subtle:hover {
  background: #f8fafc;
  border-color: var(--md-brand);
  color: var(--md-brand) !important;
  transform: translateY(-1px);
}

.button-small {
  padding: 8px 18px;
  font-size: 13px;
  background: var(--md-brand);
  color: #ffffff;
  min-height: 38px;
}
.button-small:hover {
  background: var(--md-brand-dark);
}

.button-clear {
  height: 42px;
  padding: 0 16px;
  background: #ffffff;
  color: var(--md-text-muted);
  border-color: var(--md-border);
}
.button-clear:hover {
  background: #f8fafc;
  color: var(--md-text-head);
  border-color: var(--md-text-light);
}

/* Section Headings */
.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 14px;
}
.overline {
  margin: 0 0 4px;
  color: var(--md-brand);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
}
.section-heading h2 {
  margin: 0;
  color: var(--md-text-head);
  font-family: var(--ff-head);
  font-size: 21px;
  font-weight: 800;
}
.section-tag {
  display: inline-block;
  padding: 4px 10px;
  background: #f1f5f9;
  color: var(--md-text-muted);
  border: 1px solid var(--md-border);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
}

.subcopy {
  color: var(--md-text-muted);
  font-size: 14px;
  line-height: 1.6;
  margin: 0 0 16px;
}
.subcopy strong {
  color: var(--md-text-head);
}
.subcopy-tight {
  margin-bottom: 12px;
}

/* Stats Grid */
.stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin: 18px 0;
}
@media (min-width: 768px) {
  .stats {
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
  }
}

.stat {
  padding: 14px 16px;
  background: #f8fbfe;
  border: 1px solid var(--md-border);
  border-radius: var(--md-radius-sm);
  transition: all 0.2s ease;
}
.stat:hover {
  border-color: var(--md-brand-light);
  box-shadow: 0 4px 12px rgba(11, 102, 160, 0.08);
}
.stat dt {
  color: var(--md-text-muted);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 6px;
}
.stat dd {
  margin: 0;
  color: var(--md-brand);
  font-family: var(--ff-head);
  font-size: 20px;
  font-weight: 800;
  line-height: 1.2;
}
@media (min-width: 768px) {
  .stat dd {
    font-size: 24px;
  }
}

.coverage-note {
  margin: 14px 0 0;
  color: var(--md-text-muted);
  font-size: 13px;
  font-style: italic;
  padding: 8px 12px;
  background: #fafafa;
  border-radius: 6px;
}

/* Archive Tabs & Controls */
.archive {
  box-shadow: var(--md-shadow-md);
}

.tabs {
  display: inline-flex;
  gap: 4px;
  padding: 4px;
  background: #f1f5f9;
  border: 1px solid var(--md-border);
  border-radius: 10px;
  margin: 10px 0 18px;
}

.tab {
  padding: 10px 20px;
  color: var(--md-text-muted);
  background: transparent;
  border: 0;
  border-radius: 7px;
  font-family: var(--ff-head);
  font-size: 13.5px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
  min-height: 40px;
}
.tab:hover {
  color: var(--md-text-head);
}
.tab.active {
  color: var(--md-brand);
  background: #ffffff;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.08);
}

.toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 14px;
  padding: 12px 16px;
  background: #f8fafc;
  border: 1px solid var(--md-border);
  border-radius: var(--md-radius-sm);
}
.toolbar label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 700;
  color: var(--md-text-head);
}
.toolbar select,
.filter-grid select,
.filter-grid input {
  height: 42px;
  padding: 0 12px;
  color: var(--md-text-body);
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: var(--md-radius-sm);
  font-family: inherit;
  font-size: 14px;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.toolbar select:focus,
.filter-grid select:focus,
.filter-grid input:focus {
  outline: none;
  border-color: var(--md-brand);
  box-shadow: 0 0 0 3px rgba(11, 102, 160, 0.15);
}

.results-count {
  margin: 0;
  color: var(--md-brand-dark);
  font-size: 12.5px;
  font-weight: 700;
  background: var(--md-brand-light);
  padding: 5px 12px;
  border-radius: 999px;
  white-space: nowrap;
}

.table-hint {
  margin: 0 0 10px;
  color: var(--md-brand);
  font-size: 12px;
  font-weight: 600;
  text-align: center;
  padding: 7px 12px;
  background: #f0f7ff;
  border: 1px dashed #bfdbfe;
  border-radius: 6px;
}
@media (min-width: 992px) {
  .table-hint {
    display: none;
  }
}

.filter-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin-bottom: 14px;
  padding: 16px;
  background: #f8fafc;
  border: 1px solid var(--md-border);
  border-radius: var(--md-radius-sm);
  align-items: end;
}
.filter-grid label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12px;
  font-weight: 700;
  color: var(--md-text-head);
}

.toolbar-simple {
  margin-bottom: 12px;
}

/* Tables Design */
.table-scroll {
  position: relative;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--md-border);
  border-radius: var(--md-radius-sm);
  background: #ffffff;
  width: 100%;
}

.chart-table {
  width: 100%;
  border-collapse: collapse;
  text-align: center;
  font-size: 13.5px;
}

.chart-table caption {
  padding: 10px 16px;
  color: var(--md-text-muted);
  background: #f8fafc;
  border-bottom: 1px solid var(--md-border);
  font-size: 12px;
  font-weight: 600;
  text-align: left;
}

.chart-table th {
  padding: 11px 8px;
  color: #ffffff;
  background: var(--md-brand);
  font-family: var(--ff-head);
  font-size: 12.5px;
  font-weight: 700;
  white-space: nowrap;
  border-right: 1px solid rgba(255, 255, 255, 0.15);
}

.chart-table td {
  padding: 8px 6px;
  border-bottom: 1px solid var(--md-border);
  color: var(--md-text-body);
  transition: background-color 0.15s;
}

.chart-table tbody tr:nth-child(even) {
  background: #fcfdfe;
}
.chart-table tbody tr:hover {
  background: #f1f5f9;
}

/* Weekly Matrix */
.weekly-table th:first-child,
.weekly-table td:first-child {
  position: sticky;
  left: 0;
  z-index: 2;
  min-width: 115px;
  background: #f8fafc;
  color: var(--md-text-head);
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
  border-right: 2px solid var(--md-border);
  text-align: center;
}
.weekly-table th:first-child {
  background: var(--md-brand);
  color: #ffffff;
  z-index: 3;
}

.weekly-cell-content {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  min-width: 82px;
  font-family: var(--ff-mono);
}

.panel-digits {
  display: flex;
  flex-direction: column;
  font-size: 10px;
  font-weight: 700;
  line-height: 1.05;
  color: #475569;
}

.jodi-digit-center {
  min-width: 24px;
  font-size: 15px;
  font-weight: 800;
  color: var(--md-brand);
}
.jodi-digit-center.red-jodi {
  color: var(--md-crimson);
}

.empty-cell {
  background: #fafafa !important;
  color: var(--md-text-light);
  font-style: italic;
  padding: 24px 16px !important;
}

/* Date-wise Table */
.date-table td {
  padding: 10px 14px;
}
.date-table td:first-child {
  font-weight: 700;
  color: var(--md-text-head);
  white-space: nowrap;
  text-align: left;
}
.date-table .col-panel {
  font-family: var(--ff-mono);
  font-size: 14px;
  font-weight: 700;
  color: #1e293b;
}

.date-table .jodi-pill {
  display: inline-block;
  min-width: 34px;
  padding: 3px 9px;
  background: var(--md-brand-light);
  color: var(--md-brand-dark);
  border: 1px solid rgba(11, 102, 160, 0.2);
  border-radius: 6px;
  font-family: var(--ff-mono);
  font-size: 14px;
  font-weight: 800;
}
.date-table .jodi-pill.red-jodi {
  background: var(--md-crimson-bg);
  color: var(--md-crimson);
  border-color: rgba(220, 38, 38, 0.25);
}

/* Table Footer & Legend */
.table-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 14px;
  padding: 10px 14px;
  background: #f8fafc;
  border: 1px solid var(--md-border);
  border-radius: var(--md-radius-sm);
}

.legend {
  margin: 0;
  font-size: 12.5px;
  color: var(--md-text-muted);
}
.legend strong {
  color: var(--md-text-head);
}
.legend span {
  color: var(--md-brand);
  font-weight: 700;
}

/* Explain Grid */
.explain-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 16px;
  margin-top: 16px;
}
.explain-grid > div {
  padding: 18px 16px;
  background: #f8fbfe;
  border: 1px solid var(--md-border);
  border-radius: var(--md-radius-sm);
}
.explain-number {
  display: inline-block;
  padding: 2px 8px;
  background: var(--md-brand);
  color: #ffffff;
  border-radius: 4px;
  font-family: var(--ff-head);
  font-size: 11px;
  font-weight: 800;
  margin-bottom: 8px;
}
.explain-grid h3 {
  margin: 0 0 6px;
  font-size: 15px;
  font-weight: 700;
  color: var(--md-text-head);
}
.explain-grid p {
  margin: 0;
  font-size: 13px;
  color: var(--md-text-muted);
  line-height: 1.5;
}

/* Policy List */
.policy-list {
  margin: 12px 0 0;
  padding-left: 20px;
  color: var(--md-text-body);
  font-size: 14px;
  line-height: 1.7;
}
.policy-list li {
  margin-bottom: 10px;
}
.policy-list strong {
  color: var(--md-text-head);
}

/* Related Resources Grid */
.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
  margin-top: 16px;
}
.related-card {
  display: flex;
  flex-direction: column;
  padding: 20px;
  background: var(--md-card);
  border: 1px solid var(--md-border);
  border-radius: var(--md-radius-md);
  text-decoration: none;
  box-shadow: var(--md-shadow-sm);
  transition: all 0.25s ease;
}
.related-card:hover {
  transform: translateY(-3px);
  border-color: var(--md-brand);
  box-shadow: var(--md-shadow-hover);
}
.related-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  background: var(--md-brand-light);
  color: var(--md-brand);
  border-radius: var(--md-radius-sm);
  font-family: var(--ff-head);
  font-size: 13px;
  font-weight: 800;
  margin-bottom: 12px;
}
.related-card h3 {
  margin: 0 0 8px;
  color: var(--md-text-head);
  font-family: var(--ff-head);
  font-size: 16px;
  font-weight: 700;
}
.related-card p {
  margin: 0 0 16px;
  color: var(--md-text-muted);
  font-size: 13.5px;
  line-height: 1.5;
  flex-grow: 1;
}
.related-action {
  color: var(--md-brand);
  font-size: 13px;
  font-weight: 700;
}

/* FAQ Details Accordion */
.faq details {
  background: #f8fafc;
  border: 1px solid var(--md-border);
  border-radius: var(--md-radius-sm);
  padding: 14px 16px;
  margin-bottom: 12px;
  transition: all 0.2s ease;
}
.faq details[open] {
  background: #ffffff;
  border-color: var(--md-brand);
  box-shadow: 0 4px 14px rgba(11, 102, 160, 0.08);
}
.faq summary {
  font-family: var(--ff-head);
  font-size: 14.5px;
  font-weight: 700;
  color: var(--md-text-head);
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 36px;
}
.faq summary::-webkit-details-marker {
  display: none;
}
.faq summary::after {
  content: "+";
  font-size: 18px;
  font-weight: 700;
  color: var(--md-brand);
  margin-left: 10px;
}
.faq details[open] summary::after {
  content: "−";
}
.faq details p {
  margin: 10px 0 0;
  color: var(--md-text-body);
  font-size: 13.5px;
  line-height: 1.6;
}

/* Notice & Privacy Note */
.notice {
  margin: 24px 0;
  padding: 14px 18px;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-left: 4px solid var(--md-brand);
  border-radius: var(--md-radius-sm);
  color: #1e3a8a;
  font-size: 13px;
  line-height: 1.6;
}
.notice a {
  color: var(--md-brand-dark);
  font-weight: 700;
  text-decoration: underline;
}

/* Site Footer */
.site-footer {
  background: #0f172a;
  color: var(--md-text-light);
  padding: 28px 0;
  margin-top: 48px;
  font-size: 13px;
  border-top: 3px solid var(--md-brand);
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
}
.footer-inner p {
  margin: 0;
}
.footer-inner nav {
  display: flex;
  gap: 16px;
}
.footer-inner nav a {
  color: #cbd5e1;
  text-decoration: none;
  transition: color 0.2s;
}
.footer-inner nav a:hover {
  color: #ffffff;
}

/* ============================================================
   RESPONSIVE DESIGN BREAKPOINTS
   Optimized from Large Screens down to 320px
   ============================================================ */

/* ── Tablets & Laptops (< 992px) ── */
@media (max-width: 991px) {
  .hero h1 {
    font-size: 26px;
  }
  .weekly-table th:first-child,
  .weekly-table td:first-child {
    min-width: 105px;
  }
}

/* ── Phablets & Mobile (< 768px) ── */
@media (max-width: 767px) {
  .site-header {
    padding: 2px 0;
  }
  .header-inner {
    flex-direction: column;
    gap: 8px;
    padding: 8px 0;
    align-items: stretch;
  }
  .brand {
    justify-content: center;
    font-size: 19px;
  }
  .top-nav {
    justify-content: center;
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    gap: 6px;
    padding-bottom: 2px;
  }
  .top-nav a {
    padding: 6px 10px;
    font-size: 12.5px;
  }

  .breadcrumbs {
    margin: 12px 0 16px;
    padding: 8px 12px;
    font-size: 12.5px;
  }

  .hero {
    padding: 20px 16px;
  }
  .hero h1 {
    font-size: 23px;
  }
  .hero-actions {
    flex-direction: column;
    width: 100%;
  }
  .hero-actions .button {
    width: 100%;
    text-align: center;
  }

  .section-heading {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
  }
  .section-heading h2 {
    font-size: 19px;
  }
  .section-tag {
    align-self: flex-start;
  }

  .stats {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin: 14px 0;
  }
  .stat {
    padding: 12px;
  }
  .stat dd {
    font-size: 19px;
  }

  .tabs {
    display: flex;
    width: 100%;
  }
  .tab {
    flex: 1;
    text-align: center;
    padding: 10px 8px;
    font-size: 13px;
  }

  .filter-grid {
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 12px;
  }
  .filter-grid .button-clear {
    width: 100%;
  }

  .toolbar {
    padding: 10px 12px;
    gap: 8px;
  }

  .table-footer {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
    gap: 10px;
  }
  .table-footer .button-small {
    width: 100%;
  }

  .explain-grid,
  .related-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .footer-inner {
    flex-direction: column;
    text-align: center;
    gap: 12px;
  }
  .footer-inner nav {
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
  }
}

/* ── Small Smartphones (< 480px) ── */
@media (max-width: 480px) {
  body {
    font-size: 14px;
  }
  .card {
    padding: 16px 12px;
    border-radius: 10px;
    margin-bottom: 16px;
  }

  .brand {
    font-size: 18px;
  }
  .brand img {
    width: 28px;
    height: 28px;
  }
  .top-nav a {
    padding: 5px 8px;
    font-size: 11.5px;
  }

  .hero {
    padding: 18px 12px;
  }
  .eyebrow {
    font-size: 10px;
    padding: 3px 8px;
    margin-bottom: 8px;
  }
  .hero h1 {
    font-size: 21px;
    line-height: 1.25;
    margin-bottom: 8px;
  }
  .lede {
    font-size: 13.5px;
    line-height: 1.5;
    margin-bottom: 10px;
  }
  .hero-note {
    font-size: 12px;
    padding: 8px 10px;
    margin-bottom: 14px;
  }
  .button {
    font-size: 13.5px;
    padding: 10px 14px;
  }

  .section-heading h2 {
    font-size: 18px;
  }
  .subcopy {
    font-size: 13px;
    margin-bottom: 12px;
  }

  /* Weekly table compact horizontal scroll view */
  .weekly-table th:first-child,
  .weekly-table td:first-child {
    min-width: 86px;
    max-width: 90px;
    font-size: 10px;
    padding: 6px 3px;
  }
  .weekly-table th {
    padding: 8px 4px;
    font-size: 11.5px;
  }
  .weekly-day-cell {
    min-width: 68px;
    padding: 5px 2px !important;
  }
  .weekly-cell-content {
    gap: 2.5px;
    min-width: 64px;
  }
  .panel-digits {
    font-size: 9px;
  }
  .jodi-digit-center {
    font-size: 13.5px;
    min-width: 19px;
  }

  /* Date table compact view */
  .date-table th {
    padding: 8px 6px;
    font-size: 11.5px;
  }
  .date-table td {
    padding: 8px 6px;
    font-size: 12.5px;
  }
  .date-table td:first-child {
    font-size: 12px;
    padding-left: 8px;
  }
  .date-table .col-panel {
    font-size: 13px;
  }
  .date-table .jodi-pill {
    padding: 2px 7px;
    font-size: 13px;
    min-width: 28px;
  }

  .faq details {
    padding: 12px 14px;
    margin-bottom: 8px;
  }
  .faq summary {
    font-size: 13.5px;
  }
  .faq details p {
    font-size: 12.5px;
  }

  .policy-list {
    padding-left: 16px;
    font-size: 13px;
  }

  .notice {
    padding: 10px 12px;
    font-size: 12px;
    margin: 16px 0;
  }
}

/* ── Ultra-Compact / Fold Phones (< 360px) ── */
@media (max-width: 360px) {
  .wrap {
    padding: 0 6px;
  }
  .card {
    padding: 14px 8px;
    border-radius: 8px;
  }

  .brand {
    font-size: 16.5px;
    gap: 6px;
  }
  .brand img {
    width: 24px;
    height: 24px;
  }
  .top-nav {
    gap: 4px;
  }
  .top-nav a {
    padding: 4px 6px;
    font-size: 11px;
  }

  .hero h1 {
    font-size: 19px;
  }
  .lede {
    font-size: 13px;
  }

  .stats {
    gap: 8px;
  }
  .stat {
    padding: 10px 8px;
  }
  .stat dt {
    font-size: 9.5px;
    margin-bottom: 2px;
  }
  .stat dd {
    font-size: 16.5px;
  }

  .tab {
    padding: 8px 4px;
    font-size: 12px;
  }

  .toolbar {
    padding: 8px 6px;
  }
  .toolbar select {
    font-size: 12.5px;
    height: 36px;
  }
  .results-count {
    font-size: 10.5px;
    padding: 3px 8px;
  }

  /* Weekly table ultra-compact */
  .weekly-table th:first-child,
  .weekly-table td:first-child {
    min-width: 76px;
    max-width: 80px;
    font-size: 9px;
    padding: 5px 2px;
  }
  .weekly-day-cell {
    min-width: 58px;
    padding: 4px 1px !important;
  }
  .weekly-cell-content {
    gap: 1.5px;
    min-width: 54px;
  }
  .panel-digits {
    font-size: 8px;
  }
  .jodi-digit-center {
    font-size: 12px;
    min-width: 16px;
  }

  /* Date table ultra-compact */
  .date-table th {
    padding: 6px 3px;
    font-size: 10.5px;
  }
  .date-table td {
    padding: 6px 3px;
    font-size: 11.5px;
  }
  .date-table td:first-child {
    font-size: 11px;
  }
  .date-table .col-panel {
    font-size: 11.5px;
  }
  .date-table .jodi-pill {
    padding: 2px 4px;
    font-size: 11.5px;
    min-width: 24px;
  }

  .related-card {
    padding: 12px;
  }
  .explain-grid > div {
    padding: 12px;
  }
}

/* ================= YEAR NAVIGATION PILLS ================= */
.year-nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin: 12px 0 16px;
  padding: 10px 14px;
  background: #f8fafc;
  border: 1px solid var(--md-border);
  border-radius: var(--md-radius-sm);
}

.year-nav-label {
  font-size: 11.5px;
  font-weight: 700;
  color: var(--md-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.6px;
  margin-right: 4px;
}

.year-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 5px 12px;
  font-size: 13px;
  font-weight: 700;
  font-family: var(--ff-head);
  color: var(--md-brand);
  background: #ffffff;
  border: 1px solid var(--md-border);
  border-radius: 999px;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.2s ease;
  line-height: 1;
}

.year-pill:hover,
.year-pill.active {
  background: var(--md-brand);
  color: #ffffff;
  border-color: var(--md-brand);
  box-shadow: 0 2px 6px rgba(11, 102, 160, 0.25);
}

/* ================= COVERAGE DETAILS GRID ================= */
.coverage-details-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.coverage-details-grid > div {
  padding: 16px;
  background: #f8fbfe;
  border: 1px solid var(--md-border);
  border-radius: var(--md-radius-sm);
  border-left: 3px solid var(--md-brand);
}

.coverage-details-grid h3 {
  margin: 0 0 8px;
  font-size: 14.5px;
  color: var(--md-text-head);
  font-family: var(--ff-head);
}

.coverage-details-grid p {
  margin: 0;
  font-size: 13px;
  color: var(--md-text-muted);
  line-height: 1.55;
}

/* ================= BENEFIT LIST ================= */
.benefit-list {
  list-style: none;
  padding: 0;
  margin: 16px 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.benefit-list li {
  padding: 12px 16px;
  background: #f8fafc;
  border: 1px solid var(--md-border);
  border-radius: var(--md-radius-sm);
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--md-text-body);
}

.benefit-list li strong {
  color: var(--md-brand-dark);
}

