:root {
  --border: #527183;
}

html {
  font-size: 100%;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 1rem;
  line-height: 1.5;
}

button,
input,
select,
textarea {
  min-width: 0;
  font: inherit;
  line-height: 1.25;
}

::placeholder {
  color: #a9bdc9;
  opacity: 1;
}

a {
  text-underline-offset: .16em;
}

:where(a, button, input, select, textarea, [tabindex]):focus-visible {
  outline: 2px solid #f4f8fb;
  outline-offset: 2px;
  box-shadow: 0 0 0 5px #07111c;
}

.skip-link {
  position: fixed;
  z-index: 1000;
  top: 8px;
  left: 8px;
  min-height: 44px;
  padding: 11px 15px;
  transform: translateY(-160%);
  background: var(--text);
  color: var(--app-bg);
  font-weight: 800;
  text-decoration: none;
}

.skip-link:focus {
  transform: translateY(0);
}

.header-actions button,
.header-link,
.about-back {
  min-height: 44px;
  height: 44px;
  font-size: .8125rem;
  font-family: inherit;
}

.header-actions form,
.header-link {
  margin-top: 11px;
}

.app-header p {
  font-size: .875rem;
}

.app-badge,
.search-form label,
.access-kicker,
.access-form label,
.about-kicker,
.contact-form label {
  font-size: .8125rem;
}

.search-form input,
.search-form select,
.search-form button,
.access-form input,
.access-form button,
.contact-form input,
.contact-form textarea,
.contact-form button {
  font-size: 1rem;
}

.search-shell {
  padding-block: 16px 18px;
}

.search-form button {
  align-self: end;
}

.search-form .submit-arrow {
  display: inline-block;
  font-size: 1.25rem;
  font-weight: 900;
  line-height: 1;
  transform: scaleX(1.12);
  transform-origin: center;
}

.search-form input:focus,
.search-form select:focus,
.access-form input:focus,
.contact-form input:focus,
.contact-form textarea:focus {
  border-color: var(--accent);
}

.section-title {
  align-items: center;
  min-height: 44px;
  height: auto;
}

.section-title h2 {
  font-size: .875rem;
  line-height: 1.25;
}

.chart-panel {
  height: calc(100% - 44px);
}

.details-section {
  grid-template-rows: 44px minmax(0, 1fr);
}

.side-column--combined {
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: minmax(0, 1fr);
}

.details-section--combined {
  height: 100%;
}

.details-panel--combined {
  padding: 0;
}

.forecast-summary {
  min-height: 0;
  padding: 18px;
  border: 0;
  border-bottom: 1px solid var(--border);
}

.forecast-summary p:first-child {
  margin-top: 0;
}

.detail-content {
  padding: 18px 15px;
}

.chart-help-row {
  right: 180px;
  font-size: .8125rem;
  line-height: 1.5;
}

.chart-panel:has(.wind-card.is-selected) .chart-help-row {
  right: 356px;
}

.wind-card {
  width: 155px;
  height: 105px;
  overflow: hidden;
  font-size: .75rem;
}

.wind-card-title {
  font-size: .75rem;
  line-height: 1.25;
}

.wind-direction-row strong {
  font-size: .875rem;
}

.wind-card.is-selected {
  width: 330px;
  height: 105px;
}

.wind-selected-header {
  min-height: 28px;
  font-size: .8125rem;
}

.wind-selected-body,
.wind-selected-body dl {
  font-size: .6875rem;
  line-height: 1.2;
}

.wind-selected-body {
  height: 56px;
}

.wind-selected-divider {
  height: 47px;
}

.chart-band-label,
.chart-axis-label,
.chart-axis-title,
.chart-best-label {
  font-size: .75rem;
}

.chart-time-label {
  font-size: .6875rem;
}

.chart-point:focus-visible {
  outline: none;
  stroke: #fff;
  stroke-width: 4;
}

.best-card p,
.details-panel,
.selected-meta,
.error,
.access-copy,
.access-error,
.contact-status {
  font-size: 1rem;
  line-height: 1.5;
}

.details-panel h3 {
  font-size: .875rem;
  line-height: 1.4;
}

.details-panel li,
.details-panel p {
  line-height: 1.5;
}

.data-attribution,
.contact-privacy {
  font-size: .8125rem;
  line-height: 1.6;
}

.point-tooltip {
  width: min(230px, calc(100% - 16px));
}

.point-tooltip strong {
  font-size: .875rem;
}

.point-tooltip span,
.point-tooltip .tooltip-rating {
  font-size: .8125rem;
}

.chart-zoom-controls button {
  width: 44px;
  height: 44px;
  font-size: 1.25rem;
  font-family: inherit;
}

.about-content h1,
.about-content h2,
.contact-card h2 {
  font-size: 1.125rem;
  line-height: 1.35;
}

.about-content p,
.contact-card > p {
  font-size: 1rem;
  line-height: 1.65;
}

.about-back,
.access-about-link {
  font-size: .8125rem;
}

.about-back {
  height: auto;
  padding-block: 10px;
}

.access-about-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}

.access-form button,
.contact-form button {
  font-family: inherit;
}

@media (max-width: 620px) {
  .app-header {
    height: auto;
    min-height: 90px;
    gap: 12px;
  }

  .header-actions {
    flex-wrap: wrap;
    justify-content: flex-end;
  }

  .search-shell {
    padding-block: 16px;
  }

  .search-form button {
    align-self: stretch;
  }

  .about-header {
    flex-wrap: wrap;
    gap: 12px;
    padding-block: 8px;
  }

  .header-actions form,
  .header-link {
    margin-top: 0;
  }

  .chart-panel {
    height: 450px;
  }

  .chart-help-row,
  .chart-panel:has(.wind-card.is-selected) .chart-help-row {
    left: 12px;
    right: 12px;
  }

  .wind-card,
  .wind-card.is-selected {
    top: 60px;
    right: 12px;
  }

  .wind-card.is-selected {
    width: min(360px, calc(100% - 24px));
  }

  .chart-band-label {
    font-size: .625rem;
  }

  .details-section {
    grid-template-rows: 44px auto;
  }

  .side-column--combined {
    grid-template-columns: minmax(0, 1fr);
    grid-auto-rows: auto;
  }

  .details-section--combined {
    height: auto;
  }
}

@media (max-width: 340px) {
  .chart-panel {
    height: 480px;
  }

  .wind-card,
  .wind-card.is-selected {
    top: 65px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
  }
}

@media (forced-colors: active) {
  :where(a, button, input, select, textarea, [tabindex]):focus-visible {
    outline: 3px solid CanvasText;
    box-shadow: none;
  }
}
