/* Pengaturan: meniru Pengaturan Sistem macOS (Tahoe). Sidebar melayang di kiri, kartu berbaris di kanan.
   Tema gelap bawaan (sesuai screenshot), .st-light untuk tema terang. */
.app-pengaturan {
  --st-side-w: 232px;
  --st-bg: #1d1d1f; --st-side: #262628; --st-edge: #ffffff14; --st-card: #ffffff0c; --st-sep: #ffffff12;
  --st-text: #f2f2f7; --st-mut: #98989f; --st-fill: #ffffff14; --st-hover: #ffffff0d; --st-acc: #0b5fd8; --st-on: #0a84ff;
  border-radius: 16px; background: var(--st-bg); color-scheme: dark;
  container: st / inline-size;
}
.app-pengaturan.st-light {
  --st-bg: #ececee; --st-side: #f6f6f7; --st-edge: #0000000f; --st-card: #ffffff; --st-sep: #00000010;
  --st-text: #1d1d1f; --st-mut: #6e6e73; --st-fill: #0000000d; --st-hover: #0000000a; --st-acc: #0a64e0; --st-on: #0a7cf5;
  color-scheme: light;
}
.app-pengaturan .titlebar { position: absolute; top: 0; left: 0; right: 0; z-index: 4; height: 52px; padding-left: 24px; background: none; border: 0; border-radius: 16px 16px 0 0; }
.app-pengaturan .win-title { display: none; }
.app-pengaturan .win-body { position: relative; overflow: hidden; border-radius: 16px; background: var(--st-bg); }
.window.is-maximized.app-pengaturan .win-body { border-radius: 0; }

.st { position: absolute; inset: 0; color: var(--st-text); font: 13px/1.35 var(--font-ui); -webkit-font-smoothing: antialiased; }
.st button, .st input { font: inherit; color: inherit; }
.st :focus-visible { outline: 2px solid var(--st-on); outline-offset: 1px; }

/* toolbar di title bar */
.st-tools { position: absolute; left: calc(var(--st-side-w) + 22px); top: 11px; display: flex; align-items: center; gap: 12px; }
.st-nav { display: flex; height: 30px; padding: 0 2px; border: 1px solid var(--st-edge); border-radius: 15px; background: var(--st-fill); }
.st-navb { width: 28px; height: 28px; display: grid; place-items: center; border: 0; background: none; padding: 0; border-radius: 13px; cursor: default; color: var(--st-text, #f2f2f7); }
.st-navb + .st-navb { border-left: 1px solid var(--st-edge); border-radius: 0 13px 13px 0; }
.st-navb svg { width: 12px; height: 12px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.st-navb:disabled { opacity: .35; }
.st-navb:not(:disabled):hover { background: var(--st-hover); }
.app-pengaturan .st-tools { color: var(--st-text); }
.st-tooltitle { margin: 0; font: 600 15px var(--font-ui); color: var(--st-text); opacity: 0; transition: opacity .15s; pointer-events: none; white-space: nowrap; }
.st-tooltitle.is-shown { opacity: 1; }

/* sidebar */
.st-side { position: absolute; top: 8px; left: 8px; bottom: 8px; width: var(--st-side-w); display: flex; flex-direction: column; padding: 50px 8px 8px; border: 1px solid var(--st-edge); border-radius: 18px; background: var(--st-side); box-shadow: 0 6px 24px #0000002a; box-sizing: border-box; }
.st-search { display: flex; align-items: center; gap: 6px; height: 30px; margin: 0 4px 10px; padding: 0 10px; border-radius: 15px; background: var(--st-fill); color: var(--st-mut); cursor: text; }
.st-search svg { width: 14px; height: 14px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; }
.st-search input { flex: 1; min-width: 0; border: 0; outline: 0; background: none; color: var(--st-text); font-size: 13px; }
.st-search input::placeholder { color: var(--st-mut); }
.st-search input::-webkit-search-cancel-button { filter: grayscale(1); }
.st-list { flex: 1; min-height: 0; overflow-y: auto; padding: 0 2px; scrollbar-width: thin; }
.st-account { display: flex; align-items: center; gap: 9px; width: 100%; margin: 0 0 12px; padding: 5px 6px; border: 0; border-radius: 9px; background: none; text-align: left; cursor: default; }
.st-account:hover { background: var(--st-hover); }
.st-account.is-on { background: var(--st-acc); color: #fff; }
.st-account-t { display: flex; flex-direction: column; min-width: 0; }
.st-account-t strong { font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.st-account-t small { font-size: 11px; color: var(--st-mut); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.st-account.is-on small { color: #ffffffc0; }
.st-avatar { flex: none; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: linear-gradient(#f4a35c, #c9672c); color: #fff; font: 600 13px var(--font-ui); box-shadow: inset 0 0 0 1px #ffffff30; }
.st-avatar-xl { width: 64px; height: 64px; font-size: 24px; margin: 0 auto 10px; }
.st-group { display: flex; flex-direction: column; gap: 2px; margin-bottom: 14px; }
.st-item { display: flex; align-items: center; gap: 8px; width: 100%; height: 30px; padding: 0 7px; border: 0; border-radius: 8px; background: none; text-align: left; cursor: default; }
.st-item:hover { background: var(--st-hover); }
.st-item.is-on { background: var(--st-acc); color: #fff; }
.st-item-l { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.st-item-sub { color: var(--st-mut); font-size: 11px; }
.st-item.is-on .st-item-sub { color: #ffffffb0; }
.st-empty { margin: 18px 8px; color: var(--st-mut); text-align: center; }

/* ikon ubin */
.st-ic { flex: none; display: inline-block; width: 20px; height: 20px; }
.st-ic svg { display: block; width: 100%; height: 100%; filter: drop-shadow(0 .5px .5px #0000004d); }
.st-ic-xl { width: 64px; height: 64px; margin: 0 auto 10px; }

/* panel kanan */
.st-main { position: absolute; top: 0; bottom: 0; right: 0; left: calc(var(--st-side-w) + 8px); }
/* latar toolbar: isi yang digulir lewat di bawahnya tidak bertabrakan dengan tombol < > dan judul */
.st-main::before { content: ''; position: absolute; top: 0; left: 0; right: 10px; height: 54px; z-index: 1; pointer-events: none;
  background: linear-gradient(var(--st-bg) 78%, transparent); }
.st-content { position: relative; height: 100%; overflow-y: auto; box-sizing: border-box; padding: 56px 22px 24px 14px; display: flex; flex-direction: column; gap: 12px; scrollbar-width: thin; }
.st-card { flex: none; border-radius: 12px; background: var(--st-card); }
.app-pengaturan.st-light .st-card { box-shadow: 0 0 0 .5px #0000000d; }
.st-head { padding: 22px 28px 20px; text-align: center; }
.st-head-t { margin: 0 0 4px; font: 700 22px/1.2 var(--font-ui); letter-spacing: -.3px; }
.st-head-d { margin: 0 auto; max-width: 520px; color: var(--st-mut); font-size: 13px; }
.st-hero { flex: none; padding: 6px 0 8px; text-align: center; }
.st-rows { padding: 0 12px; }
.st-row { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 44px; padding: 7px 0; border: 0; border-top: 1px solid var(--st-sep); background: none; text-align: left; box-sizing: border-box; }
.st-rows > .st-row:first-child, .st-rows > .st-note:first-child + .st-row { border-top: 0; }
/* Seperti macOS: garis pemisah baris berikon mulai dari teks, bukan dari ikon */
.st-rows > .st-row:has(> .st-ic):not(:first-child) { border-top: 0; background: linear-gradient(var(--st-sep), var(--st-sep)) no-repeat 30px 0 / calc(100% - 30px) 1px; }
.st-row.is-link { cursor: default; }
.st-row-t { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.st-row-l { overflow-wrap: anywhere; }
.st-row-sub, .st-row-lock { color: var(--st-mut); font-size: 11px; }
.st-row-lock { display: flex; align-items: center; gap: 4px; }
.st-row-lock svg { width: 11px; height: 11px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.2; }
.st-row-v { flex: none; max-width: 55%; color: var(--st-mut); text-align: right; overflow-wrap: anywhere; }
.st-chev { flex: none; display: grid; place-items: center; width: 10px; color: var(--st-mut); }
.st-chev svg { width: 7px; height: 11px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.st-note { margin: 0; padding: 12px 2px; color: var(--st-mut); font-size: 12px; }
.st-rows > .st-note + .st-note, .st-rows > .st-row + .st-note { border-top: 1px solid var(--st-sep); }

/* kontrol */
.st-switch { flex: none; position: relative; width: 38px; height: 22px; padding: 0; border: 0; border-radius: 11px; background: var(--st-fill); box-shadow: inset 0 0 0 1px var(--st-edge); cursor: default; transition: background .15s; }
.st-switch::after { content: ''; position: absolute; top: 2px; left: 2px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px #0005; transition: transform .15s; }
.st-switch[aria-checked=true] { background: var(--st-on); }
.st-switch[aria-checked=true]::after { transform: translateX(16px); }
.st-switch:disabled { opacity: .45; }
.st-btn { flex: none; height: 26px; padding: 0 12px; border: 0; border-radius: 7px; background: var(--st-fill); box-shadow: inset 0 0 0 .5px var(--st-edge); cursor: default; white-space: nowrap; }
.st-btn:not(:disabled):hover { background: var(--st-hover); filter: brightness(1.3); }
.st-btn:disabled { opacity: .45; }
.st-slider-w { flex: 0 1 260px; display: flex; align-items: center; gap: 8px; min-width: 120px; color: var(--st-mut); }
.st-slider { flex: 1; min-width: 0; accent-color: var(--st-on); }
.st-slider-ic svg { display: block; width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; }
.st-row.is-choice { padding: 14px 0 12px; }
.st-choices { display: flex; flex-wrap: wrap; gap: 18px; justify-content: center; width: 100%; }
.st-choice { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 0; border: 0; background: none; cursor: default; }
.st-choice:disabled { opacity: .4; }
.st-swatch { display: block; width: 92px; height: 58px; border-radius: 9px; background-size: cover; background-position: center; box-shadow: 0 0 0 1px var(--st-edge); }
.st-choice.is-on .st-swatch { box-shadow: 0 0 0 3px var(--st-on); }
.st-choice-l { font-size: 12px; }
.st-choice.is-on .st-choice-l { font-weight: 600; }
.st-sw-terang { background: linear-gradient(#f4f4f6 0 22%, #fff 22%), #fff; }
.st-sw-gelap { background: linear-gradient(#3a3a3e 0 22%, #1f1f22 22%); }
.st-sw-otomatis { background: linear-gradient(90deg, #f4f4f6 0 50%, #1f1f22 50%); }
.st-sw-gradien { background: radial-gradient(120% 80% at 85% 108%, #ff9f5a8c 0%, #ff9f5a00 55%), linear-gradient(180deg, #151a3d, #0b0d24); }
.st-sw-foto { background-color: #555; }

/* penyimpanan */
.st-storage { padding: 16px 16px 18px; }
.st-storage-h { font-weight: 600; }
.st-storage-s { margin: 2px 0 10px; color: var(--st-mut); font-size: 12px; }
.st-bar { display: flex; height: 14px; overflow: hidden; border-radius: 4px; background: var(--st-fill); }
.st-bar span { display: block; height: 100%; }
.st-bar span + span { box-shadow: inset 1px 0 #00000040; }

@container st (max-width: 720px) {
  .st, .st-tools { --st-side-w: 196px; }
  .st-content { padding-right: 14px; }
  .st-head { padding: 18px 16px; }
  .st-row-v { max-width: 48%; }
}

/* Aksesibilitas > Kurangi gerakan (pengaturan.js) */
#desktop.reduce-motion *, #desktop.reduce-motion *::before, #desktop.reduce-motion *::after { animation: none !important; transition: none !important; }
