.eps-page { max-width: 1250px; }
.eps-switch { display: flex; gap: 6px; flex-wrap: wrap; margin: 12px 0; }
.eps-switch a { padding: 8px 14px; border: 1px solid #cad9e6; border-radius: 9px; background: #fff; color: #11486e; text-decoration: none; font-size: 13px; font-weight: bold; }
.eps-switch a[aria-current="page"] { background: #115885; border-color: #115885; color: #fff; }
.eps-switch a:not([aria-current="page"]):hover { background: #e6eef5; }
.eps-switch a:focus-visible { outline: 2px solid #117f7a; outline-offset: 2px; }
.eps-page .eps-header { grid-template-columns: 1fr auto; }
.eps-board { margin-top: 14px; padding: clamp(10px, 2vw, 20px); background: #fff; border: 1px solid #cad9e6; border-radius: 16px; }
.eps-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }
.eps-tabs { display: flex; flex-wrap: wrap; gap: 4px; }
.eps-tabs[hidden] { display: none; }
.eps-threshold-picker { display: flex; gap: 4px; margin: 0 0 8px; padding: 3px; border-radius: 12px; background: #edf3f8; }
.eps-threshold-picker[hidden] { display: none; }
.eps-threshold-picker button { flex: 1; }
.eps-board button { padding: 7px 12px; min-height: 36px; border: 0; border-radius: 9px; background: #e6eef5; color: #11486e; font: inherit; font-size: 13px; font-weight: bold; cursor: pointer; }
.eps-board button[aria-pressed="true"], .eps-controls button { background: #115885; color: #fff; }
.eps-board button:focus-visible { outline: 2px solid #117f7a; outline-offset: 2px; }
.eps-run, .eps-note, #epsStatus { font-size: 12px; color: #3e5c73; }
.eps-run { margin: 0; }
.eps-frame { margin-top: 12px; }
.eps-frame h2 { font-size: clamp(14px, 2vw, 19px); margin: 0; }
#epsStatus { min-height: 1.3em; margin: 2px 0 4px; }
.eps-maps { display: grid; grid-template-columns: repeat(var(--panels, 2), minmax(0, 1fr)); gap: 8px; }
.eps-card { position: relative; min-width: 0; border: 1px solid #cad9e6; border-radius: 10px; overflow: hidden; background: #acd5df; }
.eps-card h3 { position: absolute; z-index: 500; top: 8px; left: 8px; max-width: calc(100% - 54px); margin: 0; padding: 5px 7px; border-radius: 6px; background: #fff; font-size: clamp(10px, 1.5vw, 14px); pointer-events: none; }
.eps-map { height: clamp(245px, 49vh, 560px); }
.eps-gallery .eps-map { width: 100%; height: auto; aspect-ratio: 1; }
.eps-controls { display: flex; align-items: center; gap: 10px; margin: 13px 0; }
.eps-controls input { flex: 1; min-width: 0; accent-color: #115885; }
.eps-controls .eps-reset { background: #e6eef5; color: #11486e; white-space: nowrap; }
.eps-legend { width: min(340px, 100%); font-size: 12px; }
.eps-swatches { display: flex; gap: 2px; margin-top: 4px; }
.eps-swatches span { flex: 1; min-width: 0; text-align: center; font-size: 10px; }
.eps-swatches i { display: block; height: 9px; margin-bottom: 2px; border-radius: 2px; }
.eps-note { margin: 10px 0 0; line-height: 1.45; }
@media (max-width: 620px) {
    .eps-page .eps-header { grid-template-columns: 1fr; gap: 6px; }
    .eps-page .top-links { justify-content: flex-start; }
    .eps-maps { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; }
    .eps-maps[data-count="1"] { grid-template-columns: 1fr; }
    .eps-map { width: 100%; height: auto; aspect-ratio: 1; }
    .eps-card .leaflet-control-zoom { margin: 4px 4px 0 0; }
    .eps-card .leaflet-control-zoom a { width: 26px; height: 26px; line-height: 26px; font-size: 17px; }
    .eps-card h3 { top: 4px; left: 4px; max-width: calc(100% - 40px); }
    .eps-card .leaflet-control-attribution { font-size: 8px; }
    .eps-controls { gap: 8px; }
    .eps-controls button { min-height: 44px; padding: 8px 12px; }
    .eps-controls input[type="range"] {
        -webkit-appearance: none;
        appearance: none;
        height: 44px;
        margin: 0;
        padding: 0;
        background: transparent;
        cursor: pointer;
    }
    .eps-controls input[type="range"]:focus-visible { outline: 2px solid #117f7a; outline-offset: 2px; border-radius: 8px; }
    .eps-controls input[type="range"]::-webkit-slider-runnable-track { height: 6px; border-radius: 999px; background: #b9cedb; }
    .eps-controls input[type="range"]::-webkit-slider-thumb {
        -webkit-appearance: none;
        appearance: none;
        width: 28px;
        height: 28px;
        margin-top: -11px;
        border: 2px solid #fff;
        border-radius: 50%;
        background: #115885;
        box-shadow: 0 1px 5px rgba(15, 56, 82, .45);
    }
    .eps-controls input[type="range"]::-moz-range-track { height: 6px; border-radius: 999px; background: #b9cedb; }
    .eps-controls input[type="range"]::-moz-range-progress { height: 6px; border-radius: 999px; background: #115885; }
    .eps-controls input[type="range"]::-moz-range-thumb {
        width: 24px;
        height: 24px;
        border: 2px solid #fff;
        border-radius: 50%;
        background: #115885;
        box-shadow: 0 1px 5px rgba(15, 56, 82, .45);
    }
}
