/**
 * Bongovo! https://www.bongovo.cz
 * GNU General Public License version 3 or later
 */
.bhy {
    --bhy-bg: #fff;
    --bhy-panel: #f0f5fa;
    --bhy-text: #152c43;
    --bhy-muted: #526579;
    --bhy-border: #cbd6e2;
    --bhy-blue: #1468ac;
    --bhy-prediction: #8051b0;
    background: var(--bhy-bg);
    color: var(--bhy-text);
    border: 1px solid var(--bhy-border);
    border-radius: .75rem;
    padding: clamp(1rem, 3vw, 1.75rem);
    line-height: 1.5;
    container-type: inline-size;
}
.bhy-dark {
    --bhy-bg: #17283b;
    --bhy-panel: #21374e;
    --bhy-text: #f1f5fa;
    --bhy-muted: #bdccdc;
    --bhy-border: #48617c;
    --bhy-blue: #76c4ff;
    --bhy-prediction: #d3b2ff;
}
.bhy a { color: var(--bhy-blue); text-decoration: underline; }
.bhy-header { display: flex; justify-content: space-between; align-items: flex-start; flex-wrap: wrap; gap: .75rem; }
.bhy .bhy-title { color: var(--bhy-text); margin: 0; font-size: 1.5rem; }
.bhy-subtitle { color: var(--bhy-muted); margin: .25rem 0 .75rem; }
.bhy-status { display: inline-block; padding: .3rem .75rem; border-radius: 1rem; font-weight: 700; font-size: .85rem; background: var(--bhy-panel); border: 1px solid var(--bhy-border); }
.bhy-status-1 { background: #fff2bd; color: #594000; border-color: #b38300; }
.bhy-status-2 { background: #ffe0bb; color: #713900; border-color: #b05b00; }
.bhy-status-3, .bhy-status-4 { background: #ffe0e4; color: #8c0b21; border-color: #b82037; }
.bhy-status-4 { border-width: 3px; }
@container (max-width: 25rem) {
    .bhy-status { flex-basis: 100%; box-sizing: border-box; text-align: center; }
}
.bhy-metrics { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 12rem), 1fr)); gap: .75rem; margin: 1rem 0; }
.bhy-metric { padding: 1rem; border-radius: .5rem; background: var(--bhy-panel); min-width: 0; }
.bhy-metric dt { color: var(--bhy-muted); font-weight: 500; }
.bhy-metric dd { margin: .25rem 0 0; }
.bhy .bhy-value { font-size: 2rem; font-weight: 700; line-height: 1.3; }
.bhy-value small { font-size: .95rem; font-weight: 400; }
.bhy-timestamp, .bhy-muted, .bhy-footer, .bhy-cell-time { color: var(--bhy-muted); font-size: .85rem; }
.bhy-notice { margin: .75rem 0; }
.bhy-outlook { border-inline-start: 4px solid var(--bhy-prediction); padding: .6rem 1rem; background: var(--bhy-panel); }
.bhy-limits { display: flex; flex-wrap: wrap; gap: .5rem 1.25rem; padding: 0; list-style: none; font-size: .85rem; }
.bhy-limits li { padding-inline-start: .6rem; border-inline-start: 4px solid; }
.bhy-limit-label-1 { border-color: #ad8400 !important; }
.bhy-limit-label-2 { border-color: #c26300 !important; }
.bhy-limit-label-3, .bhy-limit-label-4 { border-color: #bf3048 !important; }
.bhy-figure { margin: 1.25rem 0; }
.bhy-figure figcaption { font-weight: 700; margin-bottom: .5rem; }
.bhy-scroll { overflow-x: auto; overscroll-behavior-x: contain; }
.bhy-scroll:focus-visible, .bhy summary:focus-visible, .bhy a:focus-visible { outline: 3px solid var(--bhy-blue); outline-offset: 3px; }
.bhy-chart { width: 100%; min-width: 620px; display: block; }
.bhy-chart-navigation { position: relative; min-width: 0; }
.bhy-chart-navigation.bhy-scroll-ready .bhy-chart-viewport { scrollbar-width: none; }
.bhy-scroll-ready .bhy-chart-viewport::-webkit-scrollbar { display: none; }
.bhy-chart-navigation.bhy-scrollable .bhy-chart-viewport { cursor: grab; }
.bhy-chart-navigation .bhy-chart-viewport.bhy-dragging { cursor: grabbing; user-select: none; }
.bhy-chart-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 1;
    width: 44px;
    height: 44px;
    padding: 0;
    border-radius: 50%;
    font-size: 2rem;
    line-height: 1;
    box-shadow: 0 2px 6px #0003;
}
.bhy-chart-arrow[hidden] { display: none; }
.bhy-chart-prev { left: 0; }
.bhy-chart-next { right: 0; }
.bhy-chart-arrow:disabled { opacity: .4; cursor: default; }
.bhy-chart-arrow:focus-visible { outline: 3px solid var(--bhy-blue); outline-offset: 3px; }
.bhy-grid { stroke: var(--bhy-border); stroke-width: 1; }
.bhy-axis { fill: var(--bhy-muted); font-size: 12px; font-family: inherit; }
.bhy-line { fill: none; stroke-width: 2.5; stroke-linejoin: round; }
.bhy-observed { stroke: var(--bhy-blue); }
.bhy-forecast { stroke: var(--bhy-prediction); stroke-dasharray: 6 4; }
.bhy-point.bhy-observed { fill: var(--bhy-blue); }
.bhy-point.bhy-forecast { fill: var(--bhy-prediction); stroke-dasharray: none; }
.bhy-limit { stroke-width: 1.5; stroke-dasharray: 3 4; }
.bhy-limit-1 { stroke: #ad8400; }
.bhy-limit-2 { stroke: #c26300; }
.bhy-limit-3 { stroke: #bf3048; }
.bhy-now { stroke: var(--bhy-muted); stroke-dasharray: 2 4; }
.bhy-legend { display: flex; flex-wrap: wrap; gap: 1rem; font-size: .85rem; }
.bhy-legend span::before { content: ""; display: inline-block; width: 1.75rem; margin-inline-end: .4rem; vertical-align: middle; border-top: 3px solid var(--bhy-blue); }
.bhy-legend .bhy-legend-forecast::before { border-color: var(--bhy-prediction); border-top-style: dashed; }
.bhy-details { border: 1px solid var(--bhy-border); border-radius: .35rem; padding: .75rem; margin: .75rem 0; }
.bhy-details summary { font-weight: 600; cursor: pointer; }
.bhy-map { height: 360px; max-width: 100%; margin-top: .75rem; background: #e6edf2; color: #152c43; isolation: isolate; z-index: 0; }
.bhy-map-tools { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin-top: .75rem; }
.bhy-map-tools[hidden], .bhy-map[hidden] { display: none; }
.bhy-map-tools .form-select { width: auto; max-width: 100%; }
.bhy .bhy-map .leaflet-control a { color: #152c43; text-decoration: none; }
.bhy .bhy-map .leaflet-control-attribution a { color: #1468ac; text-decoration: underline; }
.bhy-flash { margin: 1rem 0; }
.bhy-table { width: 100%; border-collapse: collapse; font-size: .85rem; margin-top: .75rem; }
.bhy .bhy-table > :not(caption) > * > * { background: var(--bhy-bg); color: var(--bhy-text); border-bottom: 1px solid var(--bhy-border); padding: .5rem; white-space: nowrap; }
.bhy-cell-time { display: block; }
.bhy-warnings { margin-top: 1rem; }
.bhy-official-notice { border: 1px solid; border-inline-start-width: 4px; border-radius: .35rem; padding: .75rem; margin-bottom: 1rem; overflow-wrap: anywhere; }
.bhy-official-notice p { margin: .4rem 0; }
.bhy .bhy-official-notice a { color: inherit; }
.bhy-warning-1 { border-inline-start: 4px solid #ad8400; }
.bhy-warning-2 { border-inline-start: 4px solid #c26300; }
.bhy-warning-3 { border-inline-start: 4px solid #bf3048; }
.bhy-official-text { white-space: pre-line; }
.bhy-footer { border-top: 1px solid var(--bhy-border); padding-top: 1rem; margin-top: 1rem; }
.bhy-footer p { margin: 0 0 .5rem; }
.bhy-minimal { --bhy-water-level: #b34e10; }
.bhy-minimal.bhy-dark { --bhy-water-level: #ffb268; }
.bhy-minimal .bhy-footer { font-size: .72rem; padding-top: .6rem; }
.bhy-minimal .bhy-footer p { margin-bottom: .25rem; }
.bhy-tip { position: relative; cursor: help; }
.bhy-tip:focus-visible { outline: 3px solid var(--bhy-blue); outline-offset: 3px; }
.bhy .bhy-tip > .bhy-tip-content {
    display: none; position: absolute; z-index: 4; inset-inline-start: auto; inset-inline-end: 0; top: 100%; margin: 0;
    width: 18rem; max-width: 100%; padding: .6rem .75rem; border: 1px solid var(--bhy-border);
    border-radius: .4rem; background: var(--bhy-bg); color: var(--bhy-text);
    font-size: .8rem; font-weight: 400; text-align: start; white-space: normal; box-shadow: 0 3px 12px #0003;
}
.bhy .bhy-tip:hover > .bhy-tip-content, .bhy .bhy-tip:focus > .bhy-tip-content { display: block; }
.bhy-minimal .bhy-legend { position: relative; }
.bhy-minimal .bhy-legend .bhy-tip { position: static; }
.bhy-minimal .bhy-legend .bhy-tip-content { inset-inline-start: 0; inset-inline-end: auto; max-width: 100%; width: 18rem; }
.bhy-minimal .bhy-legend .bhy-tip-content::before { display: none; }
.bhy-series-Q { stroke: var(--bhy-blue); }
.bhy-series-H { stroke: var(--bhy-water-level); }
.bhy-axis-Q { fill: var(--bhy-blue); }
.bhy-axis-H { fill: var(--bhy-water-level); }
.bhy-combined-forecast { stroke-dasharray: 6 4; }
.bhy-combined-chart .bhy-line { pointer-events: stroke; }
.bhy-combined-chart .bhy-line:hover, .bhy-combined-chart .bhy-line:focus { stroke-width: 4; outline: none; }
.bhy-combined-point.bhy-series-Q { fill: var(--bhy-blue); }
.bhy-combined-point.bhy-series-H { fill: var(--bhy-water-level); }
.bhy-minimal .bhy-legend-H::before { border-color: var(--bhy-water-level); }
.bhy-minimal .bhy-legend-observed::before, .bhy-minimal .bhy-legend-forecast::before { border-color: var(--bhy-muted); }
.bhy-warning-band { fill: #ffdf63; stroke: #8c6900; stroke-width: 1; }
.bhy-warning-band-2 { fill: #ffb55e; stroke: #9c4a00; }
.bhy-warning-band-3 { fill: #ff8899; stroke: #a4162c; }
.bhy-warning-band:focus { outline: 2px solid var(--bhy-text); }
.bhy-minimal .bhy-legend-warning::before { border-color: #b38300; border-top-width: 8px; }
@media print {
    .bhy { break-inside: avoid; }
    .bhy-scroll { overflow: visible; }
    .bhy-chart { min-width: 0; }
    .bhy-chart-arrow { display: none; }
}
