.tide-panel { display: block; padding: 34px 36px 26px; background: radial-gradient(ellipse at 82% 12%,rgba(74,147,143,.16),transparent 55%),var(--deep); }
.tide-panel .tide-heading { display: flex; justify-content: space-between; gap: 30px; align-items: end; padding-bottom: 26px; border-bottom: 1px solid rgba(145,217,207,.16); }
.tide-panel .tide-heading > div { max-width: 650px; }
.tide-panel .tide-heading b { font-size: 23px; line-height: 1.55; text-wrap: balance; }
.tide-panel .tide-heading p { flex: 0 1 310px; margin: 0; }
.tide-panel .tide-timeline { display: block; min-width: 0; min-height: 100px; }
.tide-panel .tide-timeline::before { content: none; }
.tide-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-top: 24px; }
.tide-legend { display: flex; flex-wrap: wrap; gap: 12px 22px; color: #afc9c9; font-size: 11px; }
.tide-legend > span { display: inline-flex; align-items: center; gap: 7px; }
.tide-legend i { width: 7px; height: 7px; border-radius: 50%; background: #91d9cf; box-shadow: 0 0 12px #91d9cf44; }
.tide-legend i.low { background: #e9a95f; box-shadow: 0 0 12px #e9a95f44; }
.tide-ranges { display: flex; flex-shrink: 0; border: 1px solid #91d9cf33; padding: 4px; border-radius: 11px; gap: 3px; }
.tide-ranges button { min-height: 36px; padding: 6px 14px; border: 0; border-radius: 7px; background: transparent; color: #b3cbcd; font: inherit; font-size: 12px; font-weight: 600; line-height: 1.4; }
.tide-ranges button[aria-pressed="true"] { background: #b3e6de; color: #123a3f; }
.tide-ranges button:disabled { opacity: .45; cursor: default; }
.tide-reading { display: grid; grid-template-columns: 1.1fr 1fr 1fr 1.2fr; align-items: center; gap: 20px; min-height: 120px; padding: 24px 0 10px; }
.tide-reading > div > span { display: block; color: #9ebfc1; font-size: 11px; margin-bottom: 8px; }
.tide-reading > div { min-width: 0; }
.tide-selected-time { display: block; color: #eff8f4; font-size: 20px; font-variant-numeric: tabular-nums; text-align: start; }
.tide-height output { display: inline-block; font: 500 43px/1.15 "Aptos","Segoe UI",sans-serif; color: #f6fbf7; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tide-selected-trend { justify-self: start; max-width: 100%; overflow-wrap: anywhere; font-size: 16px; font-weight: 500; color: #b3e6de; padding: 9px 12px; background: #91d9cf12; border: 1px solid #91d9cf33; border-radius: 9px; }
.tide-selected-trend:is([data-trend="falling"],[data-trend="low"]) { color: #f0c08b; border-color: #e9a95f44; background: #e9a95f0b; }
.tide-next { border-inline-start: 1px solid #91d9cf33; padding-inline-start: 22px; min-width: 0; }
.tide-next b { display: block; font-size: 12px; font-weight: 500; color: #dcece7; }
.tide-next time { display: block; margin-top: 6px; color: #a4bec0; font-size: 11px; font-variant-numeric: tabular-nums; }
.tide-chart-frame { width: 100%; height: 270px; margin-top: 8px; direction: ltr; touch-action: pan-y; cursor: crosshair; }
.tide-plot { display: block; width: 100%; height: 270px; overflow: visible; }
.tide-plot text { direction: ltr; unicode-bidi: isolate; fill: #91b0b3; font: 11px "Segoe UI",Tahoma,Arial,sans-serif; }
.tide-axis-title { fill: #c2d9d6 !important; font-size: 10px !important; }
.tide-grid line { stroke: #91d9cf1b; stroke-width: 1; }
.tide-grid.zero line { stroke: #91d9cf66; stroke-dasharray: 3 5; }
.tide-axis-time text { fill: #cee0dc; font-size: 11px; font-weight: 600; }
.tide-axis-time text.date { fill: #85a4a8; font-size: 9px; font-weight: 400; }
.tide-area { fill: url(#tide-area-fill); }
.tide-curve-line { fill: none; stroke: #9fe5d9; stroke-width: 3; stroke-linejoin: round; stroke-linecap: round; filter: drop-shadow(0 0 5px #91d9cf33); }
.tide-peak circle,.tide-single { fill: #9fe5d9; stroke: #0b252c; stroke-width: 2; }
.tide-peak text { fill: #bce9df; font-size: 11px; }
.tide-peak.low circle { fill: #e9a95f; }
.tide-peak.low text { fill: #e9bc8c; }
.tide-selection-line { stroke: #f2eee0; stroke-width: 1; stroke-dasharray: 3 4; opacity: .65; }
.tide-selection-halo { fill: #f0d09e22; stroke: #f0d09e44; stroke-width: 1; }
.tide-selection-dot { fill: #fff7e7; stroke: #092a31; stroke-width: 2; }
.tide-slider-heading { display: flex; justify-content: space-between; align-items: center; gap: 15px; margin-top: 10px; }
.tide-slider-heading label { font-size: 12px; color: #d3e6df; }
.tide-now { flex-shrink: 0; border: 1px solid #91d9cf44; border-radius: 8px; background: #91d9cf0c; color: #c5e9e2; min-height: 36px; padding: 6px 10px; font: inherit; font-size: 11px; }
.tide-now i { font-style: normal; padding-inline-start: 8px; }
.tide-scrubber { margin-top: 9px; direction: ltr; }
.tide-scrubber input { appearance: none; -webkit-appearance: none; display: block; width: 100%; height: 38px; margin: 0; background: transparent; border: 0; border-radius: 8px; cursor: ew-resize; direction: ltr; touch-action: pan-y; }
.tide-scrubber input::-webkit-slider-runnable-track { height: 4px; border-radius: 3px; background: linear-gradient(90deg,#b3e6de var(--scrub-progress,0%),#426366 var(--scrub-progress,0%)); }
.tide-scrubber input::-webkit-slider-thumb { appearance: none; -webkit-appearance: none; width: 24px; height: 24px; margin-top: -10px; border: 4px solid #143c42; border-radius: 50%; background: #e7f6ef; box-shadow: 0 0 0 1px #a1d7cd,0 0 18px #91d9cf33; }
.tide-scrubber input::-moz-range-track { height: 4px; background: #426366; border-radius: 3px; }
.tide-scrubber input::-moz-range-progress { height: 4px; background: #b3e6de; }
.tide-scrubber input::-moz-range-thumb { width: 18px; height: 18px; border: 3px solid #143c42; border-radius: 50%; background: #e7f6ef; }
.tide-endpoints { display: flex; justify-content: space-between; gap: 16px; color: #91b0b3; font-size: 10px; font-variant-numeric: tabular-nums; }
.tide-events { margin-top: 25px; container-type: inline-size; }
.tide-event-heading { display: flex; justify-content: space-between; align-items: start; gap: 12px; margin-bottom: 12px; color: #adc9c7; font-size: 11px; line-height: 1.5; }
.tide-event-heading > span { min-width: 0; }
.tide-event-heading small { max-width: 45%; flex-shrink: 0; font: inherit; text-align: end; color: #85a7a9; }
.tide-event-days,.tide-turning-points { display: grid; grid-template-columns: repeat(var(--tide-event-count),minmax(0,1fr)); direction: ltr; min-width: 0; gap: 8px; }
.tide-event-days { margin-bottom: 8px; }
.tide-event-days > span { min-width: 0; padding-bottom: 7px; border-bottom: 1px solid #91d9cf33; color: #afcecb; font-size: 11px; text-align: center; font-variant-numeric: tabular-nums; }
.tide-turning { display: grid; grid-template-rows: minmax(30px,auto) auto auto; justify-items: center; align-content: center; gap: 7px; min-width: 0; width: 100%; padding: 10px 7px; min-height: 108px; text-align: center; border: 1px solid #91d9cf26; border-top: 3px solid #91d9cf88; border-radius: 8px; background: #91d9cf07; color: #abc7c9; }
.tide-turning.low { border-top-color: #e9a95f88; }
.tide-event-kind { display: flex; justify-content: center; align-items: center; align-self: stretch; gap: 5px; min-width: 0; max-width: 100%; color: #a7e0d6; font-size: 10px; line-height: 1.5; }
.tide-event-kind i { flex-shrink: 0; font-size: 13px; font-style: normal; }
.tide-turning.low .tide-event-kind { color: #e9bc8c; }
.tide-event-long { min-width: 0; overflow-wrap: anywhere; }
.tide-event-short { display: none; }
.tide-event-time { display: block; max-width: 100%; color: #e4f1ed; font: 600 17px/1.3 "Segoe UI",Arial,sans-serif; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tide-turning strong { max-width: 100%; color: #c3dcd5; font: 500 15px/1.3 "Segoe UI",Arial,sans-serif; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tide-event-level { display: inline-flex; align-items: baseline; justify-content: center; gap: 2px; }
.tide-event-unit { color: #9cbab8; font: 500 .8em/1.2 "Segoe UI",Arial,sans-serif; letter-spacing: normal; }
.tide-turning[aria-pressed="true"] { border-color: #d6f0e9; background: #91d9cf1c; box-shadow: inset 0 0 0 1px #d6f0e966; }
.tide-reference { margin: 10px 0 0; color: #8aa9ac; font-size: 10px; line-height: 1.7; }
.tide-reference span { display: block; color: #dec19a; }
.tide-empty { display: grid; place-items: center; min-height: 220px; color: #abc7c9; font-size: 15px; }
.tide-panel :is(button,input):focus-visible { outline: 2px solid #e4f5ed; outline-offset: 4px; }
.locale-ar .tide-heading b,.locale-dv .tide-heading b { font-family: inherit; letter-spacing: normal; }
.locale-ar .tide-turning,.locale-dv .tide-turning { direction: rtl; }
.locale-dv .tide-plot text { font-family: "Noto Sans Thaana","Segoe UI",sans-serif; }
.locale-ar .tide-panel span,.locale-dv .tide-panel span { letter-spacing: normal; }
:is(.locale-ar,.locale-dv) .tide-selected-time,:is(.locale-ar,.locale-dv) .tide-next time { text-align: right; }
@media(max-width:1100px) {
  .tide-turning { padding-inline: 3px; }
  .tide-event-time { font-size: clamp(11px,calc(100cqw / var(--tide-event-count) / 4),17px); }
  .tide-turning strong { font-size: clamp(10px,calc(100cqw / var(--tide-event-count) / 4),15px); }
}
@media(max-width:900px) {
  .tide-panel .tide-heading { align-items: start; flex-direction: column; gap: 12px; }
  .tide-panel .tide-heading p { flex: auto; max-width: 650px; }
  .tide-reading { grid-template-columns: 1fr 1fr; gap: 17px; }
  .tide-selected-trend { font-size: 13px; }
  .tide-next { padding-inline-start: 0; border: 0; }
  .tide-turning { grid-template-rows: minmax(17px,auto) auto auto; min-height: 90px; }
  .tide-event-kind i,.tide-event-long { display: none; }
  .tide-event-short { display: block; }
}
@media(max-width:600px) {
  .tide-panel { padding: 25px 18px 20px; }
  .tide-panel .tide-heading { padding-bottom: 20px; }
  .tide-panel .tide-heading b { font-size: 21px; }
  .tide-panel .tide-heading p { font-size: 10px; }
  .tide-toolbar { align-items: stretch; flex-direction: column-reverse; gap: 17px; margin-top: 20px; }
  .tide-ranges { width: fit-content; }
  .tide-ranges button { padding: 7px 17px; min-height: 38px; }
  .tide-legend { font-size: 10px; gap: 12px; }
  .tide-reading { padding-top: 20px; gap: 18px 12px; }
  .tide-selected-time { font-size: 16px; }
  .tide-height output { font-size: 35px; }
  .tide-reading > div > span { font-size: 10px; }
  .tide-next time { font-size: 10px; }
  .tide-chart-frame { margin-inline: -10px; width: calc(100% + 20px); }
  .tide-events { margin-inline: -8px; }
  .tide-event-days,.tide-turning-points { gap: 2px; }
  .tide-event-heading { padding-inline: 4px; font-size: 10px; }
  .tide-event-days > span { font-size: 10px; }
  .tide-turning { grid-template-rows: minmax(17px,auto) auto auto; gap: 8px; min-height: 84px; padding: 8px 1px; border-radius: 4px; border-top-width: 2px; }
  .tide-event-kind { font-size: 9px; }
  .tide-event-kind i,.tide-event-long { display: none; }
  .tide-event-short { display: block; }
  .tide-event-time,.tide-turning strong { font-size: 11px; font-size: clamp(9px,calc(100cqw / var(--tide-event-count) / 3.7),15px); letter-spacing: -.2px; }
  .tide-event-level { gap: 0; }
  .tide-turning span.tide-event-number { letter-spacing: -.3px; }
  .tide-event-unit { font-size: clamp(7px,.75em,11px); }
  .tide-slider-heading label { font-size: 11px; }
}
@media(forced-colors:active) {
  .tide-curve-line,.tide-grid line,.tide-selection-line { stroke: CanvasText; }
  .tide-plot text { fill: CanvasText; }
  .tide-area { fill: none; }
  .tide-peak circle,.tide-selection-dot { fill: Highlight; }
  .tide-ranges button[aria-pressed="true"],.tide-turning[aria-pressed="true"] { outline: 2px solid Highlight; }
}
