:root {
  color-scheme: light;
  --ink: #13202b;
  --muted: #5e7182;
  --line: rgba(126, 148, 165, 0.28);
  --panel: rgba(255, 255, 255, 0.92);
  --panel-strong: #ffffff;
  --surface: #eff6f7;
  --accent: #007f8f;
  --accent-strong: #045b69;
  --shadow: 0 18px 55px rgba(12, 35, 48, 0.2);
}

[hidden] {
  display: none !important;
}

/* Critical Leaflet layout rules. Keep these locally so the map still renders
   correctly if the CDN stylesheet is blocked or its integrity check fails. */
.leaflet-pane,
.leaflet-tile,
.leaflet-marker-icon,
.leaflet-marker-shadow,
.leaflet-tile-container,
.leaflet-pane > svg,
.leaflet-pane > canvas,
.leaflet-zoom-box,
.leaflet-image-layer,
.leaflet-layer {
  position: absolute;
  left: 0;
  top: 0;
}

.leaflet-container {
  overflow: hidden;
  font-family: inherit;
  background: #dce8ec;
}

.leaflet-container .leaflet-overlay-pane svg {
  max-width: none !important;
  max-height: none !important;
}

.leaflet-pane {
  z-index: 400;
}

.leaflet-map-pane {
  z-index: auto;
}

.leaflet-tile-pane {
  z-index: 200;
}

.leaflet-overlay-pane {
  z-index: 400;
}

.leaflet-shadow-pane {
  z-index: 500;
}

.leaflet-marker-pane {
  z-index: 600;
}

.leaflet-tooltip-pane {
  z-index: 650;
}

.leaflet-popup-pane {
  z-index: 700;
}

.leaflet-tooltip {
  position: absolute;
  opacity: 0;
  pointer-events: none;
  white-space: nowrap;
  user-select: none;
}

.leaflet-tooltip.leaflet-interactive {
  cursor: pointer;
  pointer-events: auto;
}

.leaflet-tooltip-top::before,
.leaflet-tooltip-bottom::before,
.leaflet-tooltip-left::before,
.leaflet-tooltip-right::before {
  position: absolute;
  pointer-events: none;
  border: 6px solid transparent;
  background: transparent;
  content: "";
}

.leaflet-tooltip-top {
  margin-top: -6px;
}

.leaflet-tooltip-top::before {
  bottom: 0;
  left: 50%;
  margin-bottom: -12px;
  margin-left: -6px;
  border-top-color: rgba(20, 28, 35, 0.9);
}

.leaflet-tile,
.leaflet-marker-icon,
.leaflet-marker-shadow {
  user-select: none;
  -webkit-user-drag: none;
}

.leaflet-tile {
  filter: inherit;
  visibility: hidden;
}

.leaflet-tile-loaded {
  visibility: inherit;
}

.leaflet-zoom-animated {
  transform-origin: 0 0;
}

.leaflet-interactive {
  cursor: pointer;
}

.leaflet-marker-shadow,
.leaflet-image-layer,
.leaflet-pane > svg path,
.leaflet-tile-container {
  pointer-events: none;
}

.leaflet-marker-icon.leaflet-interactive,
.leaflet-image-layer.leaflet-interactive,
.leaflet-pane > svg path.leaflet-interactive,
svg.leaflet-image-layer.leaflet-interactive path {
  pointer-events: visiblePainted;
  pointer-events: auto;
}

.leaflet-control {
  position: relative;
  z-index: 800;
  pointer-events: auto;
}

.leaflet-top,
.leaflet-bottom {
  position: absolute;
  z-index: 1000;
  pointer-events: none;
}

.leaflet-top {
  top: 0;
}

.leaflet-right {
  right: 0;
}

.leaflet-bottom {
  bottom: 0;
}

.leaflet-left {
  left: 0;
}

.leaflet-top.leaflet-left {
  left: 464px;
}

.leaflet-control-zoom {
  margin: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(13, 38, 54, 0.18);
}

.leaflet-control-zoom a {
  display: block;
  width: 34px;
  height: 34px;
  line-height: 34px;
  text-align: center;
  background: #fff;
  color: var(--ink);
  text-decoration: none;
  font-weight: 800;
}

.leaflet-control-attribution {
  margin: 0 10px 8px 0;
  padding: 4px 7px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.86);
  font-size: 11px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  overflow: hidden;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--surface);
}

.shell {
  position: relative;
  min-height: 100vh;
  isolation: isolate;
}

#map {
  position: fixed;
  inset: 0;
  z-index: 0;
}

.control-rail,
.detail-card {
  position: fixed;
  z-index: 2;
  border: 1px solid var(--line);
  background: var(--panel);
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.control-rail {
  left: 24px;
  top: 24px;
  width: min(440px, calc(100vw - 48px));
  max-height: calc(100vh - 48px);
  display: grid;
  gap: 18px;
  padding: 20px;
  border-radius: 12px;
  overflow: auto;
}

.brand-row {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.brand-logo {
  width: 100%;
  height: auto;
  object-fit: contain;
}

.brand-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.eyebrow {
  display: block;
  margin-bottom: 3px;
  color: var(--accent-strong);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font-size: 28px;
  line-height: 1.05;
}

p {
  margin: 0;
}

.icon-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.icon-sprite symbol,
.button-icon {
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.button-icon {
  flex: 0 0 auto;
  width: 15px;
  height: 15px;
}

.brand-row p,
.muted {
  color: var(--muted);
}

.brand-row p {
  margin-top: 3px;
  font-size: 13px;
  font-weight: 650;
  line-height: 1.3;
}

.control-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.manual-tools {
  display: grid;
  gap: 13px;
  padding: 14px 15px;
  border: 1px solid rgba(126, 148, 165, 0.22);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.78);
}

.forecast-tools-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  cursor: pointer;
}

.forecast-tools-body {
  display: grid;
  gap: 12px;
}

.forecast-tools-body[hidden] {
  display: none;
}

.forecast-tools-toggle {
  width: 34px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  padding: 0;
  border: 1px solid rgba(0, 127, 143, 0.24);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--accent-strong);
  cursor: pointer;
  font: inherit;
}

.forecast-tools-toggle:hover {
  border-color: var(--accent);
  background: #ffffff;
}

.forecast-tools-toggle:focus-visible {
  outline: 2px solid rgba(0, 127, 143, 0.38);
  outline-offset: 2px;
}

.forecast-tools-chevron {
  width: 11px;
  height: 11px;
  border-right: 2px solid var(--accent-strong);
  border-bottom: 2px solid var(--accent-strong);
  transform: rotate(45deg);
  transition: transform 160ms ease;
}

.forecast-tools-toggle[aria-expanded="true"] .forecast-tools-chevron {
  transform: rotate(225deg) translate(-2px, -2px);
}

.manual-heading {
  display: grid;
  gap: 4px;
  padding: 1px 0 0;
}

.manual-kicker {
  color: var(--accent-strong);
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 0.08em;
  line-height: 1.1;
  text-transform: uppercase;
}

.manual-heading h2 {
  margin: 0;
  font-size: 15px;
  font-weight: 850;
  line-height: 1.15;
}

.manual-heading p {
  color: var(--muted);
  font-size: 12px;
  font-weight: 650;
  line-height: 1.35;
}

.mode-panel {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(248, 252, 253, 0.78);
}

.mode-bar {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.mode-button {
  min-width: 0;
  min-height: 36px;
  padding: 7px 10px;
  border: 1px solid rgba(91, 115, 132, 0.32);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  cursor: pointer;
  font: inherit;
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0;
  line-height: 1.1;
}

.mode-button:hover {
  border-color: var(--accent);
}

.mode-button:disabled,
select:disabled,
input[type="range"]:disabled {
  cursor: wait;
  opacity: 0.62;
}

.mode-button.is-active {
  border-color: var(--accent);
  background: var(--accent);
  color: #ffffff;
}

.mode-description {
  color: var(--muted);
  font-size: 12px;
  font-weight: 650;
  line-height: 1.35;
}

.field {
  display: grid;
  gap: 7px;
  min-width: 0;
  font-size: 13px;
  font-weight: 750;
}

.time-field {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(248, 252, 253, 0.78);
}

.time-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
}

.time-header > span {
  min-width: 0;
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.time-buttons {
  display: inline-grid;
  grid-template-columns: 32px minmax(58px, auto) 32px;
  gap: 6px;
  align-items: center;
}

.time-button {
  min-width: 0;
  height: 32px;
  display: inline-grid;
  place-items: center;
  padding: 0 9px;
  border: 1px solid rgba(91, 115, 132, 0.32);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  cursor: pointer;
  font: inherit;
  font-size: 12px;
  font-weight: 850;
  line-height: 1;
}

.time-button:hover:not(:disabled) {
  border-color: var(--accent);
}

.time-button:disabled {
  cursor: not-allowed;
  opacity: 0.46;
}

.time-button-play {
  color: #ffffff;
  background: var(--accent);
  border-color: var(--accent);
}

select,
input[type="range"] {
  width: 100%;
}

select {
  appearance: none;
  min-height: 42px;
  padding: 8px 38px 8px 12px;
  border: 1px solid rgba(91, 115, 132, 0.32);
  border-radius: 8px;
  background-color: #ffffff;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--accent-strong) 50%),
    linear-gradient(135deg, var(--accent-strong) 50%, transparent 50%);
  background-position:
    calc(100% - 18px) 50%,
    calc(100% - 12px) 50%;
  background-repeat: no-repeat;
  background-size: 6px 6px, 6px 6px;
  color: var(--ink);
  cursor: pointer;
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.25;
  transition: border-color 160ms ease, box-shadow 160ms ease, background-color 160ms ease;
}

select:hover:not(:disabled) {
  border-color: rgba(0, 127, 143, 0.45);
  background-color: #f9fdfe;
}

select:focus-visible {
  border-color: var(--accent);
  outline: 2px solid rgba(0, 127, 143, 0.24);
  outline-offset: 2px;
  box-shadow: 0 0 0 3px rgba(0, 127, 143, 0.08);
}

select option {
  background: #ffffff;
  color: var(--ink);
  font-weight: 650;
}

select option:checked {
  background: #e8f6f8;
  color: var(--ink);
}

input[type="range"] {
  accent-color: var(--accent);
}

.summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.summary-row {
  min-height: 74px;
  display: grid;
  align-content: center;
  gap: 4px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--panel-strong);
}

.summary-row span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.summary-row strong {
  display: block;
  font-size: 18px;
  line-height: 1.15;
  overflow-wrap: anywhere;
}

.is-loading-placeholder strong,
.legend-row.is-loading-placeholder .legend-label,
.legend-row.is-loading-placeholder .legend-detail,
.legend-row.is-loading-placeholder .swatch {
  border-radius: 6px;
  color: transparent;
  background: linear-gradient(90deg, rgba(203, 221, 226, 0.75), rgba(238, 247, 249, 0.95), rgba(203, 221, 226, 0.75));
  background-size: 220% 100%;
  animation: loadingPulse 1.4s ease-in-out infinite;
}

.is-loading-placeholder strong {
  width: min(100%, 92px);
  min-height: 21px;
}

.legend-row.is-loading-placeholder .legend-label {
  min-height: 14px;
}

.legend-row.is-loading-placeholder .legend-detail {
  width: 52px;
  min-height: 12px;
}

.legend-row.is-loading-placeholder .swatch {
  border-color: transparent;
}

@keyframes loadingPulse {
  0% {
    background-position: 100% 0;
  }
  100% {
    background-position: -100% 0;
  }
}

.destination-recommendations {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid rgba(0, 127, 143, 0.22);
  border-radius: 8px;
  background: rgba(232, 248, 250, 0.78);
}

.destination-recommendations-title {
  color: var(--accent-strong);
  font-size: 11px;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.destination-pick-list {
  display: grid;
  gap: 6px;
}

.destination-pick,
.destination-empty {
  color: var(--ink);
  font-size: 12px;
  font-weight: 650;
  line-height: 1.35;
}

.destination-pick {
  display: grid;
  gap: 2px;
}

.destination-pick strong {
  color: var(--ink);
  font-size: 12px;
  font-weight: 850;
}

.destination-pick-detail {
  display: flex;
  flex-wrap: wrap;
  gap: 3px 6px;
  align-items: baseline;
  color: var(--ink);
}

.destination-separator {
  color: var(--muted);
  font-weight: 800;
}

.advisor-panel {
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid rgba(4, 91, 105, 0.38);
  border-radius: 10px;
  background: #043d48;
  box-shadow: 0 14px 34px rgba(4, 61, 72, 0.22);
  color: #ffffff;
}

.advisor-panel-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  cursor: pointer;
}

.advisor-panel-body {
  display: grid;
  gap: 12px;
}

.advisor-panel-body[hidden] {
  display: none;
}

.advisor-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
}

.advisor-kicker {
  display: block;
  margin-bottom: 3px;
  color: #a9eef3;
  font-size: 11px;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.advisor-heading h2 {
  margin: 0;
  font-size: 22px;
  line-height: 1.15;
}

.advisor-status-badge {
  min-width: 68px;
  display: inline-grid;
  place-items: center;
  padding: 6px 9px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.12);
  color: #e8fbfd;
  font-size: 11px;
  font-weight: 850;
  line-height: 1;
}

.advisor-status-badge[hidden] {
  display: none !important;
}

.advisor-panel.is-loading .advisor-status-badge {
  border-color: rgba(255, 255, 255, 0.46);
  background: rgba(255, 255, 255, 0.18);
  color: #ffffff;
}

.advisor-panel.is-validation .advisor-status-badge,
.advisor-panel.is-error .advisor-status-badge,
.advisor-panel.is-unsupported .advisor-status-badge {
  border-color: rgba(255, 210, 210, 0.56);
  background: rgba(255, 80, 80, 0.2);
  color: #ffe5e5;
}

.advisor-form {
  display: grid;
  gap: 9px;
}

.advisor-question-field input {
  min-height: 48px;
  width: 100%;
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.34);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 14px;
  font-weight: 700;
}

.advisor-question-field input:focus {
  border-color: #a9eef3;
  outline: 2px solid rgba(169, 238, 243, 0.34);
  outline-offset: 1px;
}

.advisor-actions {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(112px, 0.75fr);
  gap: 8px;
}

.advisor-submit,
.advisor-location-button {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 9px 12px;
  border: 1px solid rgba(255, 255, 255, 0.34);
  border-radius: 8px;
  cursor: pointer;
  font: inherit;
  font-size: 13px;
  font-weight: 850;
  line-height: 1.1;
}

.advisor-submit {
  border-color: #ffffff;
  background: #ffffff;
  color: var(--accent-strong);
}

.advisor-location-button {
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
}

.advisor-submit:hover:not(:disabled),
.advisor-location-button:hover:not(:disabled) {
  border-color: #a9eef3;
}

.advisor-submit:disabled,
.advisor-location-button:disabled {
  cursor: wait;
  opacity: 0.58;
}

.advisor-location-status {
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
  color: #a9eef3;
  min-height: 1.4em;
  margin: 0;
}

.advisor-helper,
.advisor-empty,
.advisor-validation,
.advisor-error,
.advisor-question-trail,
.advisor-result-message,
.advisor-clarification,
.advisor-forecast-freshness,
.advisor-recommendation-context,
.advisor-assumptions,
.advisor-measurements,
.advisor-reasons,
.advisor-warnings {
  font-size: 12px;
  line-height: 1.4;
}

.advisor-helper,
.advisor-empty,
.advisor-forecast-freshness,
.advisor-assumptions {
  color: rgba(244, 251, 252, 0.78);
}

.advisor-support-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

.advisor-support-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: end;
}

.advisor-info-button {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 6px 9px;
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: 8px;
  background: transparent;
  color: #e8fbfd;
  cursor: pointer;
  font: inherit;
  font-size: 11px;
  font-weight: 850;
  line-height: 1;
}

.advisor-info-button:hover {
  border-color: #a9eef3;
  background: rgba(255, 255, 255, 0.08);
}

.advisor-info-button:disabled {
  cursor: wait;
  opacity: 0.58;
}

.advisor-result {
  display: grid;
  gap: 9px;
}

.advisor-question-trail {
  display: grid;
  gap: 3px;
  padding: 8px 10px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.12);
  color: rgba(244, 251, 252, 0.84);
  overflow-wrap: anywhere;
}

.advisor-question-trail p {
  margin: 0;
}

.advisor-question-trail span {
  display: inline-block;
  margin-right: 5px;
  color: #a9eef3;
  font-weight: 850;
}

.advisor-result-message {
  color: #ffffff;
  font-weight: 700;
}

.advisor-validation,
.advisor-error,
.advisor-clarification {
  padding: 9px 10px;
  border: 1px solid rgba(169, 238, 243, 0.26);
  border-radius: 8px;
  background: rgba(232, 248, 250, 0.12);
  color: #e8fbfd;
  font-weight: 800;
}

.advisor-validation,
.advisor-error {
  border-color: rgba(255, 210, 210, 0.42);
  background: rgba(255, 80, 80, 0.16);
  color: #ffe5e5;
}

.advisor-error {
  font-weight: 750;
}

.advisor-recommendation-list {
  display: grid;
  gap: 8px;
}

.advisor-alternates {
  display: grid;
  gap: 8px;
}

.advisor-alternates-body {
  display: grid;
  gap: 8px;
}

.advisor-alternates-body[hidden] {
  display: none;
}

.advisor-recommendation {
  display: grid;
  gap: 8px;
  padding: 11px;
  border: 1px solid rgba(169, 238, 243, 0.22);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
}

.advisor-recommendation-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
}

.advisor-recommendation h3 {
  margin: 0 0 2px;
  color: var(--ink);
  font-size: 14px;
  line-height: 1.2;
}

.advisor-time {
  color: var(--muted);
  font-size: 11px;
  font-weight: 750;
  line-height: 1.2;
}

.advisor-score {
  min-width: 58px;
  padding: 5px 7px;
  border-radius: 8px;
  background: #dff5f7;
  color: var(--accent-strong);
  font-size: 12px;
  font-weight: 850;
  line-height: 1;
  text-align: center;
}

.advisor-response-section {
  display: grid;
  gap: 5px;
}

.advisor-section-title {
  color: var(--muted);
  font-size: 10px;
  font-weight: 850;
  letter-spacing: 0.06em;
  line-height: 1;
  text-transform: uppercase;
}

.advisor-recommendation-context {
  color: var(--muted);
  font-weight: 750;
}

.advisor-measurements-disclosure summary {
  cursor: pointer;
}

.advisor-measurements,
.advisor-reasons,
.advisor-warnings,
.advisor-assumptions {
  margin: 0;
  padding-left: 18px;
}

.advisor-measurements {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px 10px;
  padding-left: 0;
  list-style: none;
}

.advisor-measurements li,
.advisor-reasons li,
.advisor-warnings li,
.advisor-assumptions li {
  overflow-wrap: anywhere;
}

.advisor-measurements strong {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
  text-transform: uppercase;
}

.advisor-warnings {
  color: #8d2432;
  font-weight: 700;
}

.advisor-map-button {
  min-height: 32px;
  justify-self: start;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 7px 10px;
  border: 1px solid rgba(0, 127, 143, 0.28);
  border-radius: 8px;
  background: #ffffff;
  color: var(--accent-strong);
  cursor: pointer;
  font: inherit;
  font-size: 12px;
  font-weight: 850;
  line-height: 1;
}

.advisor-map-button:hover {
  border-color: var(--accent);
  background: #f7fbfc;
}

.advisor-secondary-button {
  min-height: 34px;
  justify-self: start;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 10px;
  border: 1px solid rgba(169, 238, 243, 0.28);
  border-radius: 8px;
  background: rgba(232, 248, 250, 0.12);
  color: #e8fbfd;
  cursor: pointer;
  font: inherit;
  font-size: 12px;
  font-weight: 850;
  line-height: 1.1;
  text-align: left;
}

.advisor-secondary-button:hover {
  border-color: #a9eef3;
  background: rgba(255, 255, 255, 0.1);
}

.advisor-secondary-button .button-icon {
  transition: transform 160ms ease;
}

.advisor-secondary-button[aria-expanded="true"] .button-icon {
  transform: rotate(180deg);
}

.advisor-alternate-times {
  display: grid;
  gap: 6px;
}

.advisor-alternate-time {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  padding: 8px 9px;
  border: 1px solid rgba(169, 238, 243, 0.22);
  border-radius: 8px;
  background: #ffffff;
  color: var(--ink);
  font-size: 12px;
}

.advisor-alternate-time strong,
.advisor-alternate-time span {
  display: block;
  line-height: 1.25;
}

.advisor-alternate-time span {
  color: var(--muted);
  font-weight: 750;
}

.advisor-map-button-compact {
  min-height: 28px;
  padding: 6px 8px;
  font-size: 11px;
}

.legend {
  display: grid;
  gap: 9px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.82);
}

.legend-title {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.legend-scale {
  display: grid;
  gap: 6px;
}

.legend-row {
  display: grid;
  grid-template-columns: 14px minmax(0, 1fr) auto;
  align-items: center;
  gap: 9px;
  min-height: 24px;
  font-size: 12px;
}

.legend-label {
  min-width: 0;
  font-weight: 750;
}

.legend-detail {
  color: var(--muted);
  font-size: 11px;
  font-weight: 750;
  text-align: right;
}

.swatch {
  flex: 0 0 auto;
  width: 14px;
  height: 14px;
  border-radius: 4px;
  border: 1px solid rgba(0, 0, 0, 0.22);
}

.forecast-status {
  display: grid;
  gap: 5px;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.forecast-status strong {
  display: block;
  color: var(--ink);
  font-size: 13px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.forecast-status span {
  overflow-wrap: anywhere;
}

.info-button {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 38px;
  justify-self: start;
  padding: 8px 16px;
  border: 1px solid var(--accent);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--accent-strong);
  cursor: pointer;
  font: inherit;
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.info-button:hover {
  background: #ffffff;
}

.data-attribution {
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.data-attribution strong {
  color: var(--ink);
}

.data-attribution a {
  color: var(--accent-strong);
  font-weight: 800;
}

.detail-card {
  right: 24px;
  top: 24px;
  bottom: 24px;
  width: min(430px, calc(100vw - 48px));
  max-height: calc(100vh - 48px);
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
  padding: 16px;
  border-radius: 12px;
  overflow: hidden;
}

.detail-card.is-empty {
  top: 24px;
  bottom: auto;
  width: min(360px, calc(100vw - 48px));
  max-height: none;
  display: block;
  padding: 14px 16px;
  overflow: visible;
}

.map-hint {
  display: grid;
  gap: 4px;
}

.map-hint-title {
  color: var(--ink);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.25;
}

.map-hint-title::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 8px;
  border-radius: 999px;
  background: var(--accent);
  box-shadow: 0 0 0 4px rgba(0, 127, 143, 0.12);
  vertical-align: 1px;
}

.detail-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 34px;
  gap: 12px;
  align-items: start;
}

.detail-close {
  width: 32px;
  height: 32px;
  display: inline-grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--ink);
  cursor: pointer;
  font: inherit;
  font-size: 20px;
  line-height: 1;
}

.detail-close:hover {
  background: #ffffff;
}

.detail-profile-link {
  display: inline-block;
  margin-top: 7px;
  color: var(--accent-strong);
  font-size: 12px;
  font-weight: 850;
  line-height: 1.2;
  text-decoration: none;
}

.detail-profile-link:hover {
  text-decoration: underline;
}

.detail-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}

.detail-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 10px;
  background: rgba(18, 52, 59, 0.08);
  color: var(--ink);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.4;
  text-transform: capitalize;
}

.detail-badge-blue-flag {
  background: rgba(0, 102, 204, 0.12);
  color: #0052a3;
}

.detail-meta {
  display: grid;
  gap: 8px;
  margin: 10px 0 12px;
}

.sunlight-panel {
  margin: 0;
}

.sunlight-pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.sunlight-pill {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 4px 9px;
  border-radius: 999px;
  border: 1px solid rgba(0, 127, 143, 0.12);
  background: #dff5f7;
  color: var(--accent-strong);
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
}

.sunlight-pill span {
  white-space: nowrap;
}

.sunlight-pill-wide {
  max-width: 100%;
}

.sunlight-pill-wide span {
  white-space: normal;
  overflow-wrap: anywhere;
}

.beach-report-scroll {
  min-height: 0;
  max-height: none;
  padding-top: 12px;
  padding-right: 4px;
  border-top: 1px solid var(--line);
  overflow: auto;
  scrollbar-gutter: stable;
}

.forecast-context {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 0 0 10px;
  border-bottom: 1px solid rgba(0, 127, 143, 0.12);
}

.forecast-context-label {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
  letter-spacing: 0;
  line-height: 1.1;
}

.forecast-context-time {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  width: fit-content;
  padding: 4px 9px;
  border-radius: 999px;
  background: #dff5f7;
  color: var(--accent-strong);
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
}

.beach-metric-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}

.beach-metric {
  min-height: 86px;
  display: grid;
  align-content: start;
  gap: 5px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(248, 252, 253, 0.9);
}

.beach-metric span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 850;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.beach-metric strong {
  overflow-wrap: anywhere;
  color: var(--ink);
  font-size: 16px;
  line-height: 1.15;
}

.beach-metric small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 650;
  line-height: 1.25;
}

.beach-metric-accent {
  background: #e8f8fa;
  border-color: rgba(0, 127, 143, 0.22);
}

.beach-metric-excellent {
  border-color: rgba(80, 240, 230, 0.8);
}

.beach-metric-good {
  border-color: rgba(80, 204, 170, 0.8);
}

.beach-metric-fair {
  border-color: rgba(240, 230, 65, 0.9);
}

.beach-metric-poor {
  border-color: rgba(255, 80, 80, 0.7);
}

.beach-metric-very-poor {
  border-color: rgba(150, 0, 50, 0.55);
}

.detail-accordion {
  display: grid;
  gap: 8px;
}

.detail-section {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
  overflow: hidden;
}

.detail-section summary {
  min-height: 38px;
  display: flex;
  align-items: center;
  padding: 9px 11px;
  background: rgba(248, 252, 253, 0.92);
  color: var(--ink);
  cursor: pointer;
  font-size: 13px;
  font-weight: 850;
}

.detail-section[open] summary {
  border-bottom: 1px solid var(--line);
  background: #eef8fa;
}

.detail-section-body {
  padding: 11px;
}

.beach-section-split {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.beach-section-block {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(248, 252, 253, 0.86);
}

.beach-section-title {
  margin-bottom: 8px;
  color: var(--ink);
  font-size: 12px;
  font-weight: 850;
}

.fact-list {
  margin: 0;
  padding-left: 18px;
  color: var(--ink);
  font-size: 12px;
  line-height: 1.4;
}

.fact-list li {
  margin-bottom: 6px;
}

.fact-list li:last-child {
  margin-bottom: 0;
}

.section-copy {
  margin-bottom: 10px;
  color: var(--ink);
  font-size: 12px;
  line-height: 1.45;
}

.info-modal {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: none;
  padding: 28px;
}

.info-modal.is-open {
  display: grid;
  place-items: center;
}

.info-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(12, 28, 37, 0.42);
  backdrop-filter: blur(3px);
}

.info-dialog {
  position: relative;
  z-index: 1;
  width: min(760px, calc(100vw - 48px));
  max-height: min(82vh, 760px);
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.97);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.info-dialog-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 34px;
  gap: 12px;
  align-items: start;
  padding: 18px;
  border-bottom: 1px solid var(--line);
}

.info-dialog-header h2 {
  margin: 0;
  font-size: 22px;
  line-height: 1.15;
}

.info-dialog-body {
  padding: 18px;
  overflow: auto;
}

.info-dialog-body h3 {
  margin: 18px 0 8px;
  color: var(--accent-strong);
  font-size: 13px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.info-dialog-body h3:first-child {
  margin-top: 0;
}

.info-dialog-body p,
.info-dialog-body li {
  color: var(--ink);
  font-size: 14px;
  line-height: 1.55;
}

.info-dialog-body p {
  margin: 0 0 10px;
}

.info-dialog-body ul {
  margin: 0 0 12px;
  padding-left: 20px;
}

.detail-card h2 {
  margin: 0 0 6px;
  font-size: 22px;
  line-height: 1.15;
}

.detail-card h3 {
  margin: 18px 0 9px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent-strong);
}

a {
  color: var(--accent-strong);
  font-weight: 800;
}

.leaflet-tooltip {
  padding: 8px 10px;
  border: 1px solid rgba(255, 255, 255, 0.54);
  border-radius: 8px;
  background: rgba(20, 28, 35, 0.88);
  box-shadow: 0 10px 24px rgba(15, 34, 45, 0.18);
  color: #ffffff;
  font-weight: 600;
}

.leaflet-tooltip.aithra-map-tooltip {
  max-width: min(340px, calc(100vw - 32px));
  white-space: normal;
}

.tooltip-card {
  display: grid;
  gap: 4px;
  min-width: 230px;
  max-width: 340px;
  line-height: 1.25;
}

.tooltip-title {
  display: block;
  margin-bottom: 1px;
  font-size: 13px;
  font-weight: 850;
  line-height: 1.2;
}

.tooltip-location {
  display: block;
  margin-bottom: 3px;
  color: rgba(244, 251, 252, 0.82);
  font-size: 11px;
  font-weight: 650;
  line-height: 1.2;
}

.tooltip-row {
  display: grid;
  grid-template-columns: minmax(84px, max-content) minmax(0, 1fr);
  gap: 10px;
  align-items: baseline;
  font-size: 12px;
  font-weight: 550;
}

.tooltip-text {
  display: block;
  font-size: 12px;
  font-weight: 550;
  overflow-wrap: anywhere;
  text-align: right;
}

.tooltip-icon {
  display: block;
  min-width: 84px;
  color: rgba(244, 251, 252, 0.82);
  font-size: 11px;
  font-style: normal;
  font-weight: 850;
  line-height: 1;
  text-align: left;
  transform: translateY(1px);
}

.tooltip-note {
  display: block;
  color: rgba(244, 251, 252, 0.9);
  font-size: 11px;
  font-weight: 650;
  line-height: 1.28;
  overflow-wrap: anywhere;
}

.tooltip-note strong {
  color: #f4fbfc;
  font-weight: 850;
}

.tooltip-divider {
  display: block;
  height: 1px;
  margin: 4px 0;
  background: rgba(244, 251, 252, 0.18);
}

@media (max-width: 980px) {
  body {
    overflow: auto;
  }

  #map {
    position: relative;
    height: 56vh;
    min-height: 420px;
  }

  .control-rail,
  .detail-card {
    position: relative;
    left: auto;
    right: auto;
    top: auto;
    bottom: auto;
    width: auto;
    max-height: none;
    display: grid;
    gap: 14px;
    margin: 14px;
    overflow: visible;
  }

  .beach-report-scroll {
    max-height: none;
    overflow: visible;
  }

  .info-modal {
    padding: 14px;
  }

  .shell {
    display: flex;
    flex-direction: column;
  }

  .control-rail {
    order: -1;
  }

  .leaflet-top.leaflet-left {
    left: 0;
  }

  .detail-card.is-empty {
    display: none;
  }
}

@media (max-width: 620px) {
  body {
    background: #e8f1f3;
  }

  #map {
    height: 46vh;
    min-height: 340px;
  }

  .control-rail,
  .detail-card {
    margin: 8px;
    border-radius: 10px;
  }

  .control-rail {
    gap: 12px;
    padding: 14px;
  }

  .control-grid,
  .beach-section-split {
    grid-template-columns: 1fr;
  }

  .brand-row {
    gap: 8px;
  }

  .brand-logo {
    width: 100%;
  }

  .eyebrow {
    margin-bottom: 2px;
    font-size: 9px;
    line-height: 1.25;
  }

  h1 {
    font-size: 24px;
  }

  .brand-row p {
    font-size: 12px;
    line-height: 1.28;
  }

  .field {
    gap: 6px;
    font-size: 12px;
  }

  select {
    min-height: 38px;
    padding: 7px 9px;
  }

  .mode-panel,
  .time-field,
  .advisor-panel,
  .manual-tools,
  .legend,
  .forecast-status,
  .data-attribution {
    border-radius: 8px;
  }

  .manual-tools {
    gap: 10px;
    padding: 11px;
  }

  .forecast-tools-header {
    gap: 10px;
  }

  .forecast-tools-toggle {
    width: 32px;
    height: 32px;
  }

  .mode-panel {
    gap: 7px;
    padding: 9px;
  }

  .mode-bar {
    gap: 6px;
  }

  .mode-button {
    min-height: 34px;
    padding: 6px 5px;
    font-size: 11px;
  }

  .mode-description {
    font-size: 11px;
  }

  .time-field {
    gap: 9px;
    padding: 11px;
  }

  .time-header {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .time-header > span {
    font-size: 12px;
  }

  .time-buttons {
    width: 100%;
    grid-template-columns: 40px minmax(0, 1fr) 40px;
    gap: 7px;
  }

  .time-button {
    height: 34px;
  }

  .summary {
    grid-template-columns: repeat(3, minmax(96px, 1fr));
    gap: 7px;
    overflow-x: auto;
    padding-bottom: 2px;
    scrollbar-width: thin;
  }

  .summary-row {
    min-height: 58px;
    padding: 9px;
    border-radius: 8px;
  }

  .summary-row span {
    font-size: 9px;
    line-height: 1.15;
  }

  .summary-row strong {
    font-size: 18px;
  }

  .legend {
    gap: 7px;
    padding: 10px;
  }

  .advisor-panel {
    gap: 11px;
    padding: 13px;
  }

  .advisor-heading h2 {
    font-size: 20px;
  }

  .manual-heading h2 {
    font-size: 14px;
  }

  .manual-heading p {
    font-size: 11px;
  }

  .advisor-actions,
  .advisor-measurements {
    grid-template-columns: 1fr;
  }

  .legend-title {
    font-size: 10px;
  }

  .legend-scale {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 10px;
    row-gap: 4px;
  }

  .legend-row {
    grid-template-columns: 13px minmax(0, 1fr) auto;
    gap: 8px;
    min-height: 21px;
    font-size: 11px;
  }

  .legend-detail {
    font-size: 10px;
  }

  .swatch {
    width: 13px;
    height: 13px;
  }

  .info-button {
    width: 100%;
    justify-self: stretch;
    min-height: 36px;
  }

  .data-attribution {
    display: none;
  }

  .detail-card {
    gap: 12px;
    padding: 12px;
  }

  .detail-card h2 {
    font-size: 19px;
  }

  .beach-metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .beach-metric {
    min-height: 78px;
    padding: 9px;
  }

  .beach-metric span {
    font-size: 10px;
  }

  .beach-metric strong {
    font-size: 16px;
  }

  .info-modal {
    padding: 8px;
  }

  .info-dialog {
    width: calc(100vw - 16px);
    max-height: calc(100vh - 16px);
    border-radius: 10px;
  }

  .info-dialog-header,
  .info-dialog-body {
    padding: 14px;
  }

  .info-dialog-header h2 {
    font-size: 19px;
  }

  .leaflet-control-zoom {
    margin: 10px;
  }

  .leaflet-top.leaflet-left {
    left: 0;
  }

  .leaflet-control-attribution {
    max-width: calc(100vw - 20px);
    margin: 0 6px 6px 0;
    font-size: 9px;
  }
}

@media (hover: none), (pointer: coarse) {
  .leaflet-tooltip.aithra-map-tooltip {
    display: none;
  }
}

@media (max-width: 380px) {
  .control-rail {
    padding: 12px;
  }

  .advisor-support-row {
    grid-template-columns: 1fr;
  }

  .mode-bar {
    grid-template-columns: 1fr;
  }

  .beach-metric-grid {
    grid-template-columns: 1fr;
  }

  h1 {
    font-size: 22px;
  }
}
