.sv-page .sv-server-row { position: relative; }
.sv-page .sv-server-link, .sv-page .sr-server-link { color: inherit; text-decoration: none; }
.sv-page .sv-server-link::after { content: ""; position: absolute; inset: 0; z-index: 1; border-radius: 5px; }
.sv-page .sv-server-link:focus-visible::after { outline: 2px solid var(--ui-accent); outline-offset: 4px; }
.sv-page .sv-server:hover .sv-server-link, .sv-page .sr-server-link:hover { color: var(--ui-accent); text-decoration: underline; text-underline-offset: .15em; }
.sv-page .sv-server-row :is(.sv-favorite,.sv-button) { position: relative; z-index: 2; }
.sv-page .sv-details > summary { z-index: 2; }
.sv-page .sv-map-preview { display: block; width: min(100%, 100px); height: auto; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 5px; margin-bottom: 4px; }
.sv-page .sv-map-preview[hidden] { display: none; }
.sv-page .sr-picture { color: inherit; text-decoration: none; }

.modern-site .svd {
    container-type: inline-size;
    min-width: 0;
    padding: clamp(14px, 2.5vw, 30px);
    border: 1px solid var(--ui-line);
    border-radius: 12px;
    background: var(--ui-surface);
    color: var(--ui-ink);
    overflow-wrap: anywhere;
}
.svd *, .svd *::before, .svd *::after { box-sizing: border-box; }
.svd :is(h1,h2,p,figure,dl,dd) { margin: 0; }
.svd :is(a,summary):focus-visible { outline: 2px solid var(--ui-accent); outline-offset: 3px; }
.svd .svd-back a { color: var(--ui-muted); font-weight: 600; text-decoration: none; }
.svd .svd-back a:hover { color: var(--ui-accent); text-decoration: underline; }
.svd .svd-header { display: flex; align-items: flex-start; justify-content: space-between; flex-wrap: wrap; gap: 18px; padding-block: 18px 21px; }
.svd-header > div { min-width: 0; flex: 1 1 280px; }
.svd .svd-header h1, .svd #svd-title { color: var(--ui-ink); font-size: clamp(26px, 4.8cqi, 43px); line-height: 1.15; margin: 8px 0; }
.svd .svd-header code { color: var(--ui-muted); background: transparent; padding: 0; font: 500 13px/1.5 ui-monospace, Consolas, monospace; }
.svd-status { display: inline-flex; align-items: center; gap: 7px; color: var(--ui-muted); font-size: 12px; font-weight: 700; }
.svd-status::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.svd-status[data-state="on"]::before { background: #5baf78; }
.svd-status[data-state="off"]::before { background: #b26a60; }
.svd .svd-play { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 9px 15px; border-radius: 7px; background: var(--ui-action); color: var(--ui-on-action); text-decoration: none; font-weight: 700; }
.svd .svd-play:hover { text-decoration: underline; text-underline-offset: .15em; }
.svd-overview { display: grid; grid-template-columns: minmax(0,1fr); gap: 17px; padding-block: 0 20px; }
.svd-overview:has(figure) { grid-template-columns: minmax(0, .85fr) minmax(0, 1fr); align-items: start; }
.svd-overview figure { position: relative; overflow: hidden; border-radius: 8px; background: var(--ui-soft); }
.svd-overview figure img { display: block; width: 100%; height: auto; }
.svd-overview figcaption { position: absolute; left: 8px; bottom: 8px; max-width: calc(100% - 16px); padding: 3px 7px; border-radius: 4px; background: #141a1ddb; color: #fff; font: 600 12px/1.45 ui-monospace, Consolas, monospace; }
.svd-facts { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px 18px; align-content: start; }
.svd-facts dt, .svd-summary, .svd-x, .svd-y, .svd-note { color: var(--ui-muted); }
.svd-facts dt { font-size: 12px; line-height: 1.45; }
.svd-facts dd { font-size: 15px; line-height: 1.55; font-weight: 650; }
.svd-history { border-top: 1px solid var(--ui-line); padding-top: 20px; }
.svd-history-head { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin-bottom: 13px; }
.svd .svd-history-head h2 { font-size: clamp(22px, 4.2cqi, 30px); line-height: 1.2; color: var(--ui-ink); }
.svd-periods { display: flex; gap: 3px; max-width: 100%; padding: 3px; border: 1px solid var(--ui-line); border-radius: 7px; background: var(--ui-soft); }
.svd .svd-periods a { display: inline-grid; place-items: center; min-height: 39px; padding: 4px 9px; border-radius: 4px; font-size: 13px; font-weight: 650; color: var(--ui-ink); text-decoration: none; }
.svd .svd-periods a[aria-current] { background: var(--ui-action); color: var(--ui-on-action); }
.svd .svd-periods a:hover { text-decoration: underline; }
.svd .svd-summary, .svd .svd-note { margin-block: 8px; font-size: 13px; }
.svd-graph { display: grid; grid-template-columns: auto minmax(0,1fr); gap: 6px; padding: 13px 11px 8px; border: 1px solid var(--ui-line); border-radius: 8px; background: var(--ui-soft); font-variant-numeric: tabular-nums; }
.svd .svd-graph svg { display: block; width: 100%; height: clamp(145px, 28cqi, 205px); fill: none; }
.svd-gridline { stroke: var(--ui-line); stroke-width: 1; vector-effect: non-scaling-stroke; }
.svd-hour-bar { fill: var(--ui-accent); }
.svd-trace { fill: none; stroke: var(--ui-accent); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.svd-point { fill: var(--ui-accent); stroke: var(--ui-accent); stroke-width: 1.5; vector-effect: non-scaling-stroke; }
.svd-x, .svd-y { display: flex; justify-content: space-between; font-size: 11px; line-height: 1.2; }
.svd-x { grid-column: 2; }
.svd-y { flex-direction: column; align-items: flex-end; padding-block: 1px; }
.svd .svd-empty { padding: 17px; border: 1px dashed var(--ui-line); border-radius: 7px; color: var(--ui-muted); }
.svd-recent { margin-top: 15px; }
.svd-recent summary { width: fit-content; padding: 5px 0; color: var(--ui-ink); cursor: pointer; font-weight: 600; }
.svd-recent table { width: 100%; margin-top: 10px; border-collapse: collapse; table-layout: fixed; color: var(--ui-ink); font-size: 13px; }
.svd-recent :is(th,td) { padding: 6px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--ui-line); }
.svd-recent th { color: var(--ui-muted); font-weight: 600; }
@container (max-width: 470px) {
    .svd .svd-overview:has(figure) { grid-template-columns: minmax(0,1fr); }
    .svd .svd-header { padding-block: 13px 16px; gap: 12px; }
    .svd .svd-header h1 { margin: 6px 0; }
    .svd .svd-play { width: 100%; }
    .svd .svd-history-head { align-items: flex-start; flex-direction: column; }
}
