#wesel-gauge {display:none;position:absolute;top:calc(var(--header-height) + 10px);left:50%;transform:translateX(-50%);z-index:3;max-width:calc(100% - 150px);min-height:44px;padding:8px 14px;border-radius:9px;text-align:center;color:#edf4f7;font-size:12px;}
#wesel-gauge strong,#wesel-gauge span {display:block;overflow-wrap:anywhere;}
#wesel-gauge span {font-size:10px;color:#bdcfd8;margin-top:3px;}
#wesel-gauge[data-state="stale"] span,#wesel-gauge[data-state="error"] span {color:#f5cf89;}
#wesel-gauge-details {position:fixed;top:118px;right:74px;bottom:36px;left:auto;margin:0;width:342px;max-width:calc(100vw - 24px);height:calc(100dvh - 154px);max-height:calc(100dvh - 154px);overflow:auto;color:#edf4f7;background:rgba(8,25,35,.98);border:1px solid #8aafbf66;border-radius:14px;padding:0 18px 18px;font-size:13px;scrollbar-width:thin;scrollbar-color:#546a78 transparent;}
#wesel-gauge-details::backdrop {background:transparent;}
#wesel-gauge-details h2 {font-size:19px;margin:0 0 12px;}
#wesel-gauge-details dt {color:#a5bac5;margin-top:14px;font-size:12px;}
#wesel-gauge-details dd {margin:4px 0 0;line-height:1.5;overflow-wrap:anywhere;}
#wesel-gauge-details p {line-height:1.5;border-top:1px solid #ffffff20;padding-top:14px;}
#wesel-gauge-details a {color:#70d3f1;display:block;margin:12px 0;}
#wesel-gauge-details button {min-height:44px;padding:8px 14px;border-radius:7px;border:1px solid #8aafbf66;background:#163b4c;color:#edf4f7;}
@media(max-width:600px) {#wesel-gauge {max-width:calc(100% - 140px);width:250px;padding:7px 8px;}#wesel-gauge span{font-size:10px;}}
.gauge-map-marker {width:44px;height:44px;padding:0;border:0;background:transparent;display:grid;place-items:center;cursor:pointer;}
.gauge-map-ruler {display:block;width:38px;height:38px;background:url("../assets/pegelstand-symbol.webp") center / contain no-repeat;}

#gauge-menu {margin:14px 0;border:1px solid #8aafbf55;border-radius:8px;padding:0 10px;}
#gauge-menu summary {min-height:44px;display:list-item;align-content:center;cursor:pointer;font-size:14px;font-weight:600;}
.gauge-menu-station {display:block;width:100%;min-height:64px;margin:6px 0;padding:9px;text-align:left;color:#edf4f7;background:#153543;border:1px solid #8aafbf55;border-radius:6px;cursor:pointer;font:inherit;}
.gauge-menu-station strong,.gauge-menu-station span,.gauge-menu-station small {display:block;overflow-wrap:anywhere;line-height:1.5;}
.gauge-menu-station span {font-size:12px;}
.gauge-menu-station small {font-size:11px;color:#bdcfd8;}
.gauge-menu-station[data-state="stale"] small,.gauge-menu-station[data-state="error"] small {color:#f5cf89;}
.gauge-menu-station:focus-visible {outline:2px solid #70d3f1;outline-offset:2px;}

/* Same desktop dock as object details; retained native dialog, no data/UI rebuild. */
#wesel-gauge-details .gauge-detail-toolbar {position:sticky;top:0;z-index:1;display:flex;align-items:center;justify-content:space-between;gap:8px;min-height:58px;margin:0 -18px;padding:7px 14px;background:#0a202b;border-bottom:1px solid #8aafbf66;}
#wesel-gauge-details .gauge-detail-toolbar h2 {margin:0;font-size:18px;overflow-wrap:anywhere;}
#wesel-gauge-details .gauge-detail-toolbar button {width:44px;height:44px;flex:0 0 44px;padding:0;border:0;background:transparent;font-size:25px;}
body:has(#wesel-gauge-details[open]) #object-details,body:has(#wesel-gauge-details[open]) #wesel-gauge {visibility:hidden;}
@media(max-width:1023px) {
  #wesel-gauge-details {top:106px;right:70px;width:320px;height:calc(100dvh - 142px);max-height:calc(100dvh - 142px);}
}
@media(max-width:600px) {
  #wesel-gauge-details {top:auto;bottom:25px;left:8px;right:8px;width:auto;height:auto;max-width:none;max-height:42dvh;border-radius:16px 16px 10px 10px;padding:0 16px 16px;}
  #wesel-gauge-details .gauge-detail-toolbar {min-height:54px;margin:0 -16px;}
  body:has(#wesel-gauge-details[open]) #layer-menu {visibility:hidden;}
}
@media(max-height:500px) {
  #wesel-gauge-details {top:auto;height:auto;max-height:calc(100dvh - 128px);}
}

/* Non-modal dock remains above the map without intercepting the rest of it. */
#wesel-gauge-details {z-index:4;bottom:var(--footer-clearance,72px);height:calc(100dvh - 118px - var(--footer-clearance,72px));max-height:calc(100dvh - 118px - var(--footer-clearance,72px));}
@media(max-width:1023px) {
  #wesel-gauge-details {height:calc(100dvh - 106px - var(--footer-clearance,72px));max-height:calc(100dvh - 106px - var(--footer-clearance,72px));}
}
@media(max-width:600px) {
  #wesel-gauge-details {height:auto;max-height:min(42dvh,calc(100dvh - var(--header-height) - var(--footer-clearance,72px) - 16px));}
  #object-details {max-height:min(42dvh,calc(100dvh - var(--header-height) - var(--footer-clearance,72px) - 16px));}
}
@media(max-height:500px) {
  #wesel-gauge-details,#object-details {height:auto;max-height:calc(100dvh - 118px - var(--footer-clearance,72px));}
}

.groyne-gauge-brief {margin:12px 0;padding:12px;border:1px solid #447185;border-radius:8px;background:#13313b;}
.groyne-gauge-brief p {margin:8px 0;line-height:1.5;}
.groyne-gauge-brief small {display:block;color:#bdd0d8;line-height:1.5;}
