/* Settings kit: compact owner Settings + hidden Service area + device look (theme, accent, text size).
 * Everything is scoped under .sk so it never changes other pages. */
.sk { max-width: 1100px; }
.sk-tabs { display: flex; gap: 3px; overflow-x: auto; margin: 0 0 10px; padding: 3px; background: var(--card); border-radius: 10px; box-shadow: var(--shadow); scrollbar-width: none; }
.sk-tabs::-webkit-scrollbar { display: none; }
.sk-tabs button { border: 0; background: none; padding: 6px 13px; border-radius: 8px; font-weight: 600; font-size: 13px; color: var(--muted); white-space: nowrap; cursor: pointer; min-height: 32px; flex: none; }
.sk-tabs button.on { background: var(--brand); color: #fff; }
.sk .card { padding: 11px 14px 12px; margin-bottom: 10px; border-radius: 12px; }
.sk h2 { font-size: 14.5px; margin: 0 0 8px; }
.sk h3 { font-size: 11.5px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); margin: 11px 0 5px; font-weight: 700; }
.sk .grid { gap: 6px 10px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)) !important; }
.sk label.f, .sk div.f { margin: 0; }
.sk div.f > span.lbl { display: block; font-size: 11.5px; margin-bottom: 2px; font-weight: 600; color: var(--muted); }
.sk label.f > span { font-size: 11.5px; margin-bottom: 2px; font-weight: 600; line-height: 1.25; }
.sk input:not([type=checkbox]):not([type=radio]), .sk select, .sk textarea { min-height: 32px; padding: 4px 8px; font-size: 13px; border-radius: 7px; }
.sk textarea { min-height: 46px; }
.sk .btn { min-height: 32px; padding: 5px 12px; font-size: 13px; border-radius: 8px; }
.sk .btn.sm { min-height: 28px; padding: 3px 9px; font-size: 12.5px; }
.sk p.small { margin: 2px 0 8px; line-height: 1.4; }
.sk label.f.chk { min-height: 32px; font-size: 13px; }
.sk .row { gap: 8px; }
.sk .card > .btn.primary, .sk .card > .row { margin-top: 9px; }
.sk table th, .sk table td { padding: 6px 6px; font-size: 13px; }
.sk-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 0 0 10px; }
.sk-head b { font-size: 15px; }

/* desk shell (css/deskshell.css): the settings page wraps its cards one level deeper, in .sk - extend the
 * kit's compact-column rule (which only targets direct .settings-compact > .card) to that nesting */
@media (min-width: 821px) {
  body.nav-top:not(.ms-on) .settings-compact .sk > .card { break-inside: avoid; page-break-inside: avoid; margin: 0 0 10px; }
  body.nav-top:not(.ms-on) .settings-compact .sk-head { column-span: all; }
}
.sk-pill { display: inline-block; padding: 2px 9px; border-radius: 99px; background: #fff3cd; color: #7a5a00; font-size: 11.5px; font-weight: 700; }
/* switches */
.sk-mods { display: grid; gap: 6px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.sk-mod, .sk-ft { display: flex; gap: 9px; align-items: flex-start; padding: 7px 9px; border: 1px solid var(--line); border-radius: 9px; cursor: pointer; background: var(--card); }
.sk-mod:hover, .sk-ft:hover { border-color: var(--brand); }
.sk-mod span, .sk-ft span { display: flex; flex-direction: column; gap: 1px; min-width: 0; font-size: 13px; line-height: 1.3; }
.sk-mod small, .sk-ft small { color: var(--muted); font-size: 11.5px; line-height: 1.3; }
.sk input.sw { appearance: none; -webkit-appearance: none; width: 34px; height: 20px; min-height: 0; border-radius: 99px; background: #c4cbd6; position: relative; flex: none; margin-top: 1px; cursor: pointer; border: 0; padding: 0; transition: background .15s; }
.sk input.sw::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: left .15s; box-shadow: 0 1px 2px rgba(0,0,0,.3); }
.sk input.sw:checked { background: var(--ok); }
.sk input.sw:checked::after { left: 16px; }
.sk input.sw:disabled { opacity: .5; cursor: not-allowed; }
.sk-feats { display: grid; gap: 5px; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.sk-ft { padding: 5px 8px; align-items: center; }
.sk-ft input.sw { width: 28px; height: 16px; margin-top: 0; }
.sk-ft input.sw::after { width: 12px; height: 12px; }
.sk-ft input.sw:checked::after { left: 14px; }
details.sk-grp > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 14px; }
details.sk-grp > summary::-webkit-details-marker { display: none; }
details.sk-grp > summary::before { content: "▸"; color: var(--muted); font-size: 12px; transition: transform .12s; }
details.sk-grp[open] > summary::before { transform: rotate(90deg); }
details.sk-grp > summary .cnt { font-size: 11.5px; font-weight: 600; color: var(--muted); }
details.sk-grp > summary .spacer { flex: 1; }
details.sk-grp .sk-feats { margin-top: 8px; }
.sk-off { opacity: .45; }
.sk-save { position: sticky; bottom: 62px; z-index: 6; display: flex; gap: 8px; align-items: center; justify-content: flex-end; padding: 8px 10px; background: var(--card); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); margin-top: 6px; }
.sk-save .msg { flex: 1; font-size: 12.5px; color: var(--muted); }
.sk-save.dirty .msg { color: var(--warn); font-weight: 700; }
.sk-plan { display: inline-flex; background: var(--bg); border-radius: 9px; padding: 3px; gap: 3px; }
.sk-plan button { border: 0; background: none; padding: 5px 14px; border-radius: 7px; font-weight: 700; font-size: 13px; color: var(--muted); cursor: pointer; }
.sk-plan button.on { background: var(--card); color: var(--brand); box-shadow: var(--shadow); }
.sk-sw { display: inline-flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.sk-acc { display: flex; gap: 8px; flex-wrap: wrap; }
.sk-acc button { width: 30px; height: 30px; border-radius: 50%; border: 3px solid transparent; cursor: pointer; padding: 0; }
.sk-acc button.on { border-color: var(--ink); }
@media (max-width: 640px) {
  .sk .card { padding: 10px 11px 11px; }
  .sk-mods, .sk-feats { grid-template-columns: minmax(0, 1fr); }
  .sk-save { bottom: 72px; }
}

/* ---------- device look: theme + text size ---------- */
html[data-size="s"] body { font-size: 13.5px; }
html[data-size="l"] body { font-size: 17px; }
html[data-theme="dark"] { color-scheme: dark; --bg: #0e151e; --card: #172230; --ink: #e5ecf4; --muted: #93a4b8; --line: #2a394a; --brand-soft: #1b3a52; --ok: #35c486; --ok-soft: #123a2b; --warn: #f0b04a; --warn-soft: #3a2c12; --bad: #ff7b72; --bad-soft: #3d1b19; --shadow: 0 1px 2px rgba(0,0,0,.4), 0 4px 14px rgba(0,0,0,.25); }
html[data-theme="dark"] input, html[data-theme="dark"] select, html[data-theme="dark"] textarea { background: #0f1923; color: var(--ink); border-color: var(--line); }
html[data-theme="dark"] .btn { background: var(--card); color: var(--ink); }
html[data-theme="dark"] .btn.primary { color: #fff; }
html[data-theme="dark"] tr.click:hover td { background: #1b2a3a; }
html[data-theme="dark"] .sk input.sw { background: #3b4a5c; }
html[data-theme="dark"] .modal, html[data-theme="dark"] .modal-bg .modal { background: var(--card); color: var(--ink); }
html[data-theme="dark"] .b-warn { background: #3a2c12; color: #f0b04a; }
html[data-theme="dark"] a { color: #6cb8ee; }
html[data-theme="dark"] .navlink.active, html[data-theme="dark"] .btn.primary { background: var(--brand); }
