/* Escala compartida por las cuatro páginas. Cargar después de los estilos de sección.
   Las cabeceras fotográficas y los datos destacados mantienen su tamaño de exposición. */
:root {
  --font-site: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --text-body: .8125rem; /* 13 px */
  --text-table: .6875rem; /* 11 px: tablas compactas */
  --text-table-head: .65625rem; /* 10,5 px */
  --text-control: .75rem; /* 12 px */
  --text-meta: .6875rem; /* 11 px */
  --text-fine: .625rem; /* 10 px */
  --text-subtitle: .875rem; /* 14 px */
  --text-card-small: 1rem; /* 16 px */
  --text-card: 1.25rem; /* 20 px */
  --text-section: clamp(1.625rem, 3vw, 2.1875rem);
  --weight-body: 400;
  --weight-label: 650;
  --weight-title: 750;
  --weight-section: 800;
  --leading-body: 1.75;
  --leading-table: 1.6;
  --muted: #63767c;
  font-family: var(--font-site);
}

body { font-family: var(--font-site); font-size: var(--text-body); font-weight: var(--weight-body); line-height: var(--leading-body); }
button, input, select, textarea, table { font-family: inherit; }
h1 { font-weight: var(--weight-section); }

/* Títulos de sección: la misma jerarquía en la Home y en las páginas interiores. */
h2, .webcams-heading h2, .weather-top h2, .info-card h2, .contact-panel h2,
.forfaits-content .section-heading h2 {
  font-size: var(--text-section);
  font-weight: var(--weight-section);
  line-height: 1.15;
  letter-spacing: -.045em;
}

/* Títulos de tarjetas y subtítulos del contenido importado. */
.list-heading h3, .station-extra-card h3, .directions-card h3, .address-card h3, .destination-card h3,
.official-content h3, .forfaits-content .official-content h3, .feed-title h3,
.forecast-view-heading h3 {
  font-size: var(--text-card);
  font-weight: var(--weight-title);
  line-height: 1.35;
  letter-spacing: -.03em;
}
.overview-card h3, .transit-card h3, .month-card h3, .official-content .school-title {
  font-size: var(--text-card-small);
  font-weight: var(--weight-title);
  line-height: 1.5;
  letter-spacing: -.015em;
}
.official-content h4, .road-card h4 {
  font-size: var(--text-subtitle);
  font-weight: var(--weight-label);
  line-height: 1.5;
}
.official-content h3, .official-content h4 { color: var(--ink); }

/* Texto de lectura, incluidas condiciones, normas, servicios y escuelas. */
.official-content, .section-intro, .info-copy, .intro-copy, .webcams-heading > p,
.forecast-intro, .transit-card ul, .address-card p, .school-contacts {
  font-size: var(--text-body);
  font-weight: var(--weight-body);
  line-height: var(--leading-body);
}
.source-disclosure > summary {
  font-size: var(--text-body);
  font-weight: var(--weight-title);
  line-height: 1.6;
}
.source-disclosure .source-body { font-size: var(--text-body); }
.hero-copy, .section-hero .hero-copy { font-size: var(--text-subtitle); line-height: 1.85; }

/* Tablas: mismo componente visual en pistas, categorías, tarifas y datos técnicos. */
.inventory-table, .overview-table, .official-content table, .distance-table {
  font-size: var(--text-table);
  line-height: 1.55;
  color: #405761;
  font-variant-numeric: tabular-nums;
  border-collapse: separate;
  border-spacing: 0;
}
.inventory-table th, .inventory-table td, .overview-table th, .overview-table td,
.official-content th, .official-content td, .distance-table th, .distance-table td {
  padding: 10px 14px;
  border: 0;
  border-bottom: 1px solid #edf1f4;
  background: transparent;
  color: inherit;
  font-size: inherit;
  font-weight: 400;
  line-height: 1.55;
  vertical-align: middle;
}
.inventory-table thead { background: transparent; }
.inventory-table thead th, .overview-table thead th, .official-content th[scope="col"] {
  height: auto;
  padding-top: 12px;
  padding-bottom: 12px;
  border-bottom-color: #e1e8ee;
  background: #f7f9fb;
  color: #536b78;
  font-size: var(--text-table-head);
  font-weight: 600;
  letter-spacing: .015em;
  line-height: 1.5;
}
.track-name, .overview-table tbody th, .official-content th[scope="row"], .distance-table th {
  background: transparent;
  color: #29434e;
  font-size: var(--text-table);
  font-weight: 500;
}
.inventory-table th:first-child { padding-left: 20px; }
.inventory-table td:last-child { padding-right: 20px; }
.inventory-table .track-dimension,
.inventory-table thead th:nth-child(n+3), .overview-table td, .overview-table thead th:not(:first-child),
.official-content .data-table .is-numeric, .distance-table td {
  text-align: right;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.official-content .data-table td.is-numeric { color: #29434e; font-weight: 500; }
.official-content .data-table .is-numeric-column { text-align: right; }
.official-content .data-table th[scope="col"].is-numeric { white-space: normal; }
.inventory-table .track-dimension, .overview-table td, .distance-table td { font-weight: 500; }
.official-content td[colspan] { background: transparent; color: inherit; font-weight: inherit; }
.official-content table.data-table :is(p,div,span,strong,b,em,small,h3,h4) {
  color: inherit;
  font-size: inherit;
  font-weight: inherit;
  line-height: inherit;
}
.official-content table.data-table :is(p,h3,h4) { margin: 0; }
.official-content table.data-table p+p { margin-top: 4px; }
.official-content table.data-table :is(ul,ol) { margin: 4px 0; padding-left: 16px; font-size: inherit; }
.official-content table.data-table li { margin: 2px 0; }
.official-content .data-table td img { max-width:32px; max-height:32px; margin-right:8px; }
.official-content .data-table .table-group-row > :is(th,td) {
  background: #f7f9fb;
  color: #536b78;
  font-weight: 600;
  letter-spacing: .015em;
}
.overview-table .total-row > :is(th,td), .official-content .data-table .total-row > :is(th,td) {
  border-top: 1px solid #e1e8ee;
  border-bottom: 0;
  background: #f7f9fb;
  color: #29434e;
  font-weight: 600;
}
.overview-table .total-row { background: transparent; }
.inventory-table tbody tr:hover > :is(th,td), .overview-table tbody tr:not(.total-row):hover > :is(th,td),
.official-content .data-table tr:not(.table-group-row):not(.total-row):hover > :is(th[scope="row"],td),
.distance-table tr:hover > :is(th,td) { background: #fafcfd; }
.official-table-scroll { margin: 18px 0; border-color: #e3eaf0; border-radius: 12px; box-shadow: none; }
.inventory-card { border-color: #e3eaf0; border-radius: 18px; }
.overview-table { overflow: hidden; border: 1px solid #e8edf1; border-radius: 10px; }
.inventory-table tr:last-child > :is(th,td), .overview-table tr:last-child > :is(th,td),
.official-content .data-table tr:last-child > :is(th,td), .distance-table tr:last-child > :is(th,td) { border-bottom: 0; }
.inventory-table .state-badge { min-height: 22px; padding: 0 7px; font-size: var(--text-table-head); font-weight: 600; }
@media(max-width:650px) {
  .official-content th, .official-content td { padding: 9px 12px; }
  .overview-table th, .overview-table td { padding: 9px 10px; }
  .overview-table thead th:not(:first-child), .overview-table td:last-child { white-space: normal; }
}

/* Etiquetas, botones y fechas. Los créditos conservan un nivel más discreto. */
.kicker, .section-kicker, .eyebrow { font-size: var(--text-fine); font-weight: var(--weight-section); letter-spacing: .16em; line-height: 1.6; }
.source-stamp, .section-note, .timeline-note, .social-wall-note, .stat-note,
.forecast-credit, .weather-notice, .webcam-detail {
  font-size: var(--text-meta);
  line-height: 1.65;
}
.button, .channel-nav a, .social-load-button, .info-button, .search-label input,
.filter-group button { font-size: var(--text-control); }
.button, .channel-nav a, .social-load-button, .info-button, .filter-group button { font-weight: var(--weight-title); }
.webcam-info h3 { min-height:2.8em; font-size: var(--text-subtitle); font-weight: var(--weight-title); line-height: 1.4; }
.webcam-viewer-credit, .weather-credit, .weather-attribution { font-size: var(--text-fine); line-height: 1.6; }

@media (max-width:650px) {
  :root { --text-section: 1.75rem; --text-card: 1.125rem; }
  .hero-copy, .section-hero .hero-copy { font-size: var(--text-body); }
  .list-heading h3, .station-extra-card h3, .directions-card h3, .address-card h3, .destination-card h3,
  .official-content h3, .forfaits-content .official-content h3, .feed-title h3,
  .forecast-view-heading h3 { font-size: var(--text-card); }
}

/* Ajustes de lectura comunes tras la revisión completa. */
.source-disclosure>summary{font-weight:600}
.official-content table{min-width:0}
.official-content th[scope="col"]{white-space:normal}
.footer-links a{display:inline-flex;align-items:center;min-height:32px}
button:focus-visible,a:focus-visible,summary:focus-visible,input:focus-visible{outline:2px solid #23617d;outline-offset:3px}
@media(prefers-reduced-motion:reduce){html{scroll-behavior:auto}}

/* Estados compartidos: texto explícito y colores iguales en resumen, carrusel e inventario. */
:root{--status-open:#176548;--status-closed:#9b373e;--status-caution:#865500;--status-unknown:#5b6e7a}
.state-value.state-value--open{color:var(--status-open)}
.state-value.state-value--closed{color:var(--status-closed)}
.state-value.state-value--caution{color:var(--status-caution)}
.state-value.state-value--unknown{color:var(--status-unknown)}
.state-badge{display:inline-flex;align-items:center;gap:5px;min-height:22px;padding:0 7px;border-radius:999px;font-size:var(--text-table-head);font-weight:600;line-height:1.4;white-space:nowrap}
.state-badge::before{content:"";display:block;flex:0 0 4px;width:4px;height:4px;border-radius:50%;background:currentColor}
.state-badge.open{color:var(--status-open);background:#edf6f1}
.state-badge.closed{color:var(--status-closed);background:#f9edef}
.state-badge.partial{color:var(--status-caution);background:#faf3e7}
.state-badge.unknown{color:var(--status-unknown);background:#eef2f5}

/* Solo la estación usa una etiqueta completa en el carrusel; accesos y snowpark conservan el texto coloreado. */
.snow-report .snow-metric.snow-cycle-marker{gap:6px;padding:4px 9px;border:0;line-height:1.4}
.snow-report .snow-cycle-marker::before{display:block;align-self:center;margin:0}
.snow-report .snow-metric.snow-cycle-marker small,.snow-report .snow-metric.snow-cycle-marker strong{color:inherit;font-size:var(--text-table-head);line-height:1.4}

/* Archivo histórico: enlaces permanentes en las páginas de producción. */
.archive-links{display:flex;flex-wrap:wrap;align-items:center;gap:10px 20px;padding-top:0;padding-bottom:24px;color:var(--muted,#536b76);font-size:11px;line-height:1.6}.archive-links>span{margin-right:auto}.archive-links a{text-decoration:none;text-underline-offset:3px}.archive-links a:hover{text-decoration:underline}.archive-links a:focus-visible{outline:2px solid #246887;outline-offset:4px}

/* Contacto de Leitariegos.net, compartido en todos los pies públicos. */
.site-footer .footer-contact{display:block;margin-top:4px;color:var(--muted,#63767c);font-size:var(--text-meta,11px);line-height:1.6}
.site-footer .footer-contact a{display:inline-flex;align-items:center;min-height:28px;color:inherit;font-size:inherit;font-weight:500;text-decoration:none;text-underline-offset:3px}
.site-footer .footer-contact a:hover{text-decoration:underline}
.site-footer .footer-contact a:focus-visible{outline:2px solid var(--blue,#23617d);outline-offset:3px;border-radius:2px}
