:root {
  color-scheme: dark;
  --ink: #edf3f7;
  --muted: #a6b5c1;
  --quiet: #7f919f;
  --accent: #8fc7df;
  --focus: #b5e5f2;
  --surface: rgb(22 34 45 / 94%);
  --surface-strong: rgb(19 30 40 / 97%);
  --surface-soft: rgb(33 49 63 / 88%);
  --edge: rgb(225 242 250 / 14%);
  --edge-strong: rgb(225 242 250 / 22%);
  --shadow: 0 20px 60px rgb(0 0 0 / 20%);
  --radius-lg: 24px;
  --radius-md: 17px;
  --radius-sm: 11px;
  font-family: Inter, "SF Pro Display", "Segoe UI", "Microsoft YaHei", sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

html[data-theme="light"] {
  color-scheme: light;
  --ink: #1b2a34;
  --muted: #465c6a;
  --quiet: #607382;
  --accent: #266886;
  --focus: #155c7b;
  --surface: rgb(245 249 251 / 94%);
  --surface-strong: rgb(248 251 252 / 98%);
  --surface-soft: rgb(237 244 247 / 92%);
  --edge: rgb(31 59 75 / 16%);
  --edge-strong: rgb(31 59 75 / 24%);
  --shadow: 0 18px 54px rgb(27 50 63 / 12%);
}
html[data-theme="light"] .primary-button { color: #fff; }

* { box-sizing: border-box; }
body { min-width: 320px; min-height: 100vh; margin: 0; color: var(--ink); background: #101923; }
button, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
button { color: inherit; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 3px;
}
[hidden] { display: none !important; }

.wallpaper {
  position: fixed;
  z-index: -1;
  inset: 0;
  background-color: #101923;
  background-image:
    linear-gradient(118deg, rgb(9 15 23 / 72%), rgb(13 23 33 / 52%) 54%, rgb(9 16 23 / 68%)),
    radial-gradient(ellipse at 88% 8%, rgb(74 118 143 / 35%), transparent 42%),
    radial-gradient(ellipse at 8% 92%, rgb(45 81 102 / 32%), transparent 45%),
    var(--wallpaper-image, none);
  background-size: cover;
  background-position: center;
  pointer-events: none;
}
html[data-theme="light"] .wallpaper {
  background-image:
    linear-gradient(118deg, rgb(226 235 240 / 74%), rgb(236 242 245 / 53%) 54%, rgb(222 232 237 / 70%)),
    radial-gradient(ellipse at 88% 8%, rgb(101 148 170 / 26%), transparent 42%),
    radial-gradient(ellipse at 8% 92%, rgb(97 136 153 / 22%), transparent 45%),
    var(--wallpaper-image, none);
}

.app-shell { width: min(1540px, 100%); min-height: 100vh; margin: 0 auto; padding: 22px 30px 24px; }
.topbar { display: grid; grid-template-columns: 202px minmax(220px, 1fr) auto; align-items: center; gap: 24px; min-height: 54px; margin-bottom: 24px; }
.brand { display: inline-flex; align-items: center; gap: 11px; width: fit-content; font-size: 17px; font-weight: 650; letter-spacing: .025em; }
.brand-mark { display: flex; align-items: center; gap: 3px; height: 20px; transform: skew(-18deg); }
.brand-mark i { display: block; width: 4px; border-radius: 4px; background: var(--accent); }
.brand-mark i:nth-child(1) { height: 10px; opacity: .65; }
.brand-mark i:nth-child(2) { height: 16px; opacity: .85; }
.brand-mark i:nth-child(3) { height: 20px; }
.search-box { display: flex; align-items: center; gap: 12px; min-height: 52px; padding: 0 16px; border: 1px solid var(--edge-strong); border-radius: 16px; color: var(--muted); background: var(--surface); box-shadow: 0 8px 24px rgb(0 0 0 / 7%); -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px); }
.search-box > svg { width: 18px; height: 18px; flex: 0 0 auto; fill: none; stroke: currentColor; stroke-width: 1.7; }
.search-box input { width: 100%; min-width: 0; border: 0; outline: 0; color: var(--ink); background: transparent; font-size: 14px; }
.search-box input::placeholder { color: var(--muted); opacity: .9; }
kbd { display: inline-flex; align-items: center; justify-content: center; min-width: 21px; height: 22px; padding: 0 5px; border: 1px solid var(--edge-strong); border-radius: 6px; color: var(--muted); background: rgb(255 255 255 / 4%); font: 11px ui-monospace, SFMono-Regular, Consolas, monospace; }
.top-actions { display: flex; align-items: center; justify-content: flex-end; gap: 8px; }
.icon-button, .quiet-button { display: inline-flex; align-items: center; justify-content: center; min-height: 40px; border: 1px solid var(--edge); border-radius: 12px; color: var(--muted); background: var(--surface); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); transition: color .16s ease, border-color .16s ease, background-color .16s ease, transform .16s ease; cursor: pointer; }
.icon-button { width: 40px; padding: 0; }
.icon-button svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.55; stroke-linecap: round; stroke-linejoin: round; }
.quiet-button { padding: 0 13px; font-size: 12px; }
.icon-button:hover, .quiet-button:hover { color: var(--ink); border-color: var(--edge-strong); transform: translateY(-1px); }

.workspace { display: grid; grid-template-columns: 218px minmax(0, 1fr); align-items: start; gap: 26px; }
.glass-surface { border: 1px solid var(--edge-strong); background: var(--surface); box-shadow: var(--shadow); -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px); }
.sidebar { position: sticky; top: 20px; display: flex; flex-direction: column; min-height: min(76vh, 690px); max-height: calc(100vh - 112px); padding: 18px 12px 13px; overflow: hidden; border-radius: 21px; }
.sidebar-label { padding: 2px 9px 15px; color: var(--quiet); font-size: 11px; font-weight: 650; letter-spacing: .09em; text-transform: uppercase; }
.category-list { display: grid; gap: 4px; overflow: auto; scrollbar-width: thin; scrollbar-color: var(--edge-strong) transparent; }
.category-button { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 39px; padding: 0 10px; border: 1px solid transparent; border-radius: 11px; color: var(--muted); background: transparent; text-align: left; cursor: pointer; transition: color .15s ease, background-color .15s ease, transform .15s ease; }
.category-button:hover { color: var(--ink); background: rgb(255 255 255 / 5%); }
.category-button[aria-current="page"] { color: var(--ink); border-color: var(--edge); background: var(--surface-soft); box-shadow: 0 4px 12px rgb(0 0 0 / 9%); }
.category-glyph { display: grid; place-items: center; width: 20px; height: 20px; color: var(--accent); flex: 0 0 auto; }
.category-glyph svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.55; stroke-linecap: round; stroke-linejoin: round; }
.category-name { overflow: hidden; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.category-count { margin-left: auto; color: var(--quiet); font-size: 10px; font-variant-numeric: tabular-nums; }
.category-lock { margin-left: auto; color: var(--quiet); }
.category-lock svg { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 1.6; }
.sidebar-bottom { display: flex; align-items: center; gap: 10px; margin-top: auto; padding: 15px 9px 1px; border-top: 1px solid var(--edge); }
.sidebar-bottom strong, .sidebar-bottom small { display: block; }
.sidebar-bottom strong { font-size: 11px; font-weight: 550; }
.sidebar-bottom small { margin-top: 4px; color: var(--quiet); font-size: 10px; }
.sync-dot { width: 7px; height: 7px; border-radius: 50%; background: #d0a96d; box-shadow: 0 0 0 4px rgb(208 169 109 / 11%); }
.sync-dot.is-ready { background: #80c5a6; box-shadow: 0 0 0 4px rgb(128 197 166 / 11%); }

.main-content { min-width: 0; padding: 17px 0 0; }
.content-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; margin-bottom: 22px; }
.eyebrow { margin: 0 0 8px; color: var(--quiet); font-size: 10px; font-weight: 650; letter-spacing: .12em; text-transform: uppercase; }
.title-line { display: flex; align-items: center; gap: 10px; }
h1 { margin: 0; font-size: clamp(22px, 2.2vw, 29px); font-weight: 600; letter-spacing: -.035em; }
.count-pill { min-width: 25px; padding: 4px 7px; border: 1px solid var(--edge); border-radius: 20px; color: var(--muted); background: var(--surface); font-size: 10px; text-align: center; font-variant-numeric: tabular-nums; }
.view-switch { display: inline-flex; padding: 3px; border: 1px solid var(--edge); border-radius: 11px; background: var(--surface); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); }
.view-switch button { display: grid; place-items: center; width: 31px; height: 29px; border: 0; border-radius: 8px; color: var(--quiet); background: transparent; cursor: pointer; }
.view-switch button[aria-pressed="true"] { color: var(--ink); background: var(--surface-soft); }
.view-switch svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }

.section-caption { display: flex; align-items: center; gap: 8px; margin: 0 0 11px; color: var(--muted); font-size: 11px; font-weight: 550; }
.section-caption span + span { color: var(--quiet); font-size: 10px; font-weight: 450; }
.pinned-section { margin: 0 0 20px; }
.pinned-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.pinned-item { display: flex; align-items: center; gap: 9px; min-width: 0; min-height: 46px; padding: 0 11px; border: 1px solid var(--edge); border-radius: 13px; color: var(--muted); background: var(--surface); font-size: 11px; cursor: pointer; }
.pinned-item:hover { color: var(--ink); border-color: var(--edge-strong); }
.pinned-item .site-mark { width: 25px; height: 25px; font-size: 11px; }
.pinned-item span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.locked-section { margin: 0 0 20px; }
.locked-list { display: flex; flex-wrap: wrap; gap: 8px; }
.locked-item { display: inline-flex; align-items: center; gap: 9px; min-height: 41px; padding: 0 12px; border: 1px solid var(--edge); border-radius: 12px; color: var(--muted); background: var(--surface); cursor: pointer; }
.locked-item:hover { border-color: var(--edge-strong); color: var(--ink); }
.locked-item svg { width: 14px; height: 14px; fill: none; stroke: var(--accent); stroke-width: 1.6; }
.locked-item span { font-size: 11px; }

.bookmark-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 11px; }
.bookmark-grid[data-view="list"] { grid-template-columns: 1fr; gap: 7px; }
.bookmark-card { position: relative; display: flex; min-width: 0; min-height: 82px; border: 1px solid var(--edge); border-radius: var(--radius-md); overflow: hidden; background: var(--surface); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); transition: transform .16s ease, border-color .16s ease, background-color .16s ease; }
.bookmark-card:hover { transform: translateY(-2px); border-color: var(--edge-strong); background: var(--surface-strong); }
.bookmark-open { display: flex; align-items: center; gap: 12px; width: 100%; min-width: 0; min-height: inherit; padding: 14px 42px 14px 15px; border: 0; color: inherit; background: transparent; text-align: left; cursor: pointer; }
.site-mark { display: grid; place-items: center; width: 37px; height: 37px; border: 1px solid var(--edge); border-radius: 11px; color: var(--mark-ink, var(--accent)); background: var(--mark-bg, rgb(255 255 255 / 8%)); font-size: 14px; font-weight: 650; text-transform: uppercase; flex: 0 0 auto; }
.bookmark-copy { display: block; min-width: 0; }
.bookmark-title { display: block; overflow: hidden; color: var(--ink); font-size: 12px; font-weight: 550; text-overflow: ellipsis; white-space: nowrap; }
.bookmark-domain { display: block; margin-top: 6px; overflow: hidden; color: var(--muted); font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.pin-button { position: absolute; top: 9px; right: 9px; display: grid; place-items: center; width: 26px; height: 26px; border: 1px solid transparent; border-radius: 8px; color: var(--quiet); background: transparent; opacity: 0; cursor: pointer; transition: opacity .15s ease, color .15s ease, background-color .15s ease; }
.bookmark-card:hover .pin-button, .pin-button:focus-visible, .pin-button[aria-pressed="true"] { opacity: 1; }
.pin-button[aria-pressed="true"] { color: var(--accent); background: rgb(255 255 255 / 7%); }
.pin-button svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.5; }
.bookmark-grid[data-view="list"] .bookmark-card { min-height: 62px; border-radius: 13px; }
.bookmark-grid[data-view="list"] .bookmark-open { padding: 9px 46px 9px 12px; }
.bookmark-grid[data-view="list"] .site-mark { width: 32px; height: 32px; border-radius: 9px; }
.bookmark-grid[data-view="list"] .bookmark-copy { display: flex; align-items: baseline; gap: 10px; }
.bookmark-grid[data-view="list"] .bookmark-domain { margin-top: 0; }
.empty-state { display: grid; justify-items: center; min-height: 285px; align-content: center; padding: 28px; border: 1px dashed var(--edge-strong); border-radius: 20px; background: var(--surface); text-align: center; }
.empty-mark { display: grid; place-items: center; width: 43px; height: 43px; margin-bottom: 14px; border: 1px solid var(--edge); border-radius: 14px; color: var(--accent); background: var(--surface-soft); font-size: 25px; }
.empty-state h2 { margin: 0; font-size: 15px; font-weight: 550; }
.empty-state p { max-width: 350px; margin: 8px 0 15px; color: var(--muted); font-size: 12px; line-height: 1.7; }
.empty-state a { color: var(--accent); font-size: 11px; }
.page-footer { display: flex; justify-content: space-between; gap: 14px; margin-top: 25px; color: var(--quiet); font-size: 10px; }
.page-footer kbd { height: 18px; min-width: 18px; }

.unlock-dialog { width: min(390px, calc(100% - 28px)); padding: 0; border: 1px solid var(--edge-strong); border-radius: 22px; color: var(--ink); background: var(--surface-strong); box-shadow: 0 28px 90px rgb(0 0 0 / 38%); -webkit-backdrop-filter: blur(24px); backdrop-filter: blur(24px); }
.unlock-dialog::backdrop { background: rgb(3 8 13 / 65%); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); }
.unlock-dialog form { position: relative; padding: 28px; }
.dialog-close { position: absolute; top: 15px; right: 16px; width: 30px; height: 30px; border: 1px solid var(--edge); border-radius: 9px; color: var(--muted); background: transparent; font-size: 20px; line-height: 1; cursor: pointer; }
.lock-emblem { display: grid; place-items: center; width: 46px; height: 46px; margin-bottom: 17px; border: 1px solid var(--edge); border-radius: 15px; color: var(--accent); background: var(--surface-soft); }
.lock-emblem svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.unlock-dialog h2 { margin: 0; font-size: 20px; font-weight: 600; }
.dialog-note { margin: 8px 0 22px; color: var(--muted); font-size: 12px; line-height: 1.6; }
.field-label { display: block; margin-bottom: 7px; color: var(--muted); font-size: 11px; }
.unlock-dialog input { width: 100%; height: 43px; padding: 0 12px; border: 1px solid var(--edge-strong); border-radius: 11px; color: var(--ink); background: rgb(3 9 14 / 24%); }
.primary-button { display: inline-flex; align-items: center; justify-content: center; min-height: 42px; padding: 0 17px; border: 1px solid rgb(180 224 238 / 40%); border-radius: 11px; color: #0d1a22; background: var(--accent); font-size: 12px; font-weight: 650; cursor: pointer; transition: transform .15s ease, filter .15s ease; }
.primary-button:hover { filter: brightness(1.06); transform: translateY(-1px); }
.unlock-dialog .primary-button { width: 100%; margin-top: 14px; }
.form-error { margin: 9px 0 0; color: #f2a6a6; font-size: 11px; }
.toast { position: fixed; z-index: 4; right: 24px; bottom: 22px; max-width: min(420px, calc(100vw - 32px)); padding: 11px 15px; border: 1px solid var(--edge-strong); border-radius: 12px; color: var(--ink); background: var(--surface-strong); box-shadow: var(--shadow); font-size: 12px; }

@media (max-width: 1100px) {
  .app-shell { padding-right: 22px; padding-left: 22px; }
  .workspace { grid-template-columns: 194px minmax(0, 1fr); gap: 20px; }
  .bookmark-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pinned-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  .app-shell { padding: 13px 14px 18px; }
  .topbar { grid-template-columns: auto 1fr auto; gap: 10px; min-height: 48px; margin-bottom: 14px; }
  .brand { gap: 8px; font-size: 15px; }
  .search-box { grid-column: 1 / -1; grid-row: 2; min-height: 45px; padding: 0 12px; }
  .top-actions { grid-column: 3; grid-row: 1; gap: 6px; }
  .quiet-button { min-height: 36px; padding: 0 9px; font-size: 10px; }
  .icon-button { width: 36px; min-height: 36px; }
  .workspace { display: block; }
  .sidebar { position: static; min-height: 0; max-height: none; padding: 9px; border-radius: 15px; }
  .sidebar-label, .sidebar-bottom { display: none; }
  .category-list { display: flex; gap: 5px; overflow: auto; scrollbar-width: none; }
  .category-list::-webkit-scrollbar { display: none; }
  .category-button { width: auto; min-height: 34px; padding: 0 10px; gap: 7px; white-space: nowrap; }
  .category-glyph { width: 15px; height: 15px; }
  .category-glyph svg { width: 14px; height: 14px; }
  .category-count { margin-left: 1px; }
  .main-content { padding-top: 21px; }
  .content-head { align-items: center; margin-bottom: 17px; }
  h1 { font-size: 23px; }
  .pinned-row { gap: 7px; }
  .bookmark-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .bookmark-card { min-height: 76px; border-radius: 14px; }
  .bookmark-open { gap: 9px; padding: 11px 33px 11px 10px; }
  .site-mark { width: 31px; height: 31px; border-radius: 9px; }
  .bookmark-title { font-size: 11px; }
  .bookmark-domain { font-size: 9px; }
  .pin-button { top: 5px; right: 4px; width: 24px; height: 24px; opacity: 1; }
  .page-footer { margin-top: 20px; }
}
@media (max-width: 390px) {
  .bookmark-grid { grid-template-columns: 1fr; }
  .pinned-row { grid-template-columns: 1fr 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

.admin-page { padding: 0; }
.admin-shell { width: min(980px, 100%); min-height: 100vh; margin: 0 auto; padding: 25px 24px 60px; }
.admin-header { display: flex; align-items: center; justify-content: space-between; min-height: 45px; }
.back-link { color: var(--muted); font-size: 12px; }
.back-link:hover { color: var(--ink); }
.admin-intro { margin: 62px 0 28px; }
.admin-intro h1 { font-size: clamp(27px, 4vw, 42px); }
.admin-intro > p:last-child { margin-top: 10px; color: var(--muted); font-size: 13px; }
.admin-login { width: min(410px, 100%); margin: 0 auto; padding: 28px; border-radius: 21px; }
.login-mark { display: grid; place-items: center; width: 44px; height: 44px; margin-bottom: 18px; border: 1px solid var(--edge); border-radius: 14px; color: var(--accent); background: var(--surface-soft); font-size: 17px; font-weight: 700; }
.admin-login h2, .admin-panel h2 { margin: 0; font-size: 20px; font-weight: 600; letter-spacing: -.02em; }
.panel-copy { margin: 10px 0 22px; color: var(--muted); font-size: 12px; line-height: 1.7; }
.admin-login form { display: grid; }
.admin-login input, .admin-panel input, .admin-panel select { width: 100%; height: 42px; padding: 0 11px; border: 1px solid var(--edge-strong); border-radius: 10px; color: var(--ink); background: rgb(3 9 14 / 25%); }
.admin-login input + .field-label { margin-top: 14px; }
.full-button { width: 100%; margin-top: 17px; }
.admin-tabs { display: flex; gap: 4px; width: fit-content; margin: 0 auto 15px; padding: 4px; border-radius: 14px; }
.admin-tab { min-height: 35px; padding: 0 13px; border: 0; border-radius: 10px; color: var(--muted); background: transparent; font-size: 11px; cursor: pointer; }
.admin-tab[aria-pressed="true"] { color: var(--ink); background: var(--surface-soft); }
.admin-panel { padding: 27px; border-radius: 21px; }
.admin-panel-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 15px; }
.secondary-button, .file-picker { display: inline-flex; align-items: center; justify-content: center; min-height: 38px; padding: 0 13px; border: 1px solid var(--edge-strong); border-radius: 10px; color: var(--muted); background: var(--surface-soft); font-size: 11px; cursor: pointer; transition: color .15s ease, border-color .15s ease, transform .15s ease; }
.secondary-button:hover, .file-picker:hover { color: var(--ink); border-color: var(--accent); transform: translateY(-1px); }
.file-picker input { position: absolute; width: 1px; height: 1px; overflow: hidden; opacity: 0; pointer-events: none; }
.category-admin-list { display: grid; gap: 8px; }
.category-admin-row { display: grid; grid-template-columns: minmax(120px, 1fr) minmax(130px, 180px) minmax(150px, 220px); align-items: center; gap: 10px; padding: 10px; border: 1px solid var(--edge); border-radius: 12px; background: rgb(255 255 255 / 3%); }
.category-admin-name { min-width: 0; }
.category-admin-name strong, .category-admin-name small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.category-admin-name strong { font-size: 12px; font-weight: 550; }
.category-admin-name small { margin-top: 4px; color: var(--quiet); font-size: 10px; }
.category-admin-row select { height: 36px; }
.category-password { height: 36px !important; }
.category-admin-row .remove-category { width: 35px; min-height: 35px; padding: 0; }
.category-admin-row[data-mode="public"] .category-password { visibility: hidden; }
.panel-footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 21px; padding-top: 17px; border-top: 1px solid var(--edge); }
.status-copy { min-height: 17px; margin: 0; color: #82c8a8; font-size: 11px; }
.status-copy:empty { display: none; }
.wallpaper-preview { position: relative; display: grid; place-items: center; min-height: 180px; margin: 18px 0 14px; overflow: hidden; border: 1px solid var(--edge); border-radius: 16px; color: var(--muted); background: var(--surface-soft); background-position: center; background-size: cover; }
.wallpaper-preview::after { position: absolute; inset: 0; background: linear-gradient(120deg, rgb(7 14 20 / 40%), rgb(7 14 20 / 10%)); content: ""; }
.wallpaper-preview span { position: relative; z-index: 1; padding: 8px 11px; border: 1px solid var(--edge); border-radius: 9px; background: var(--surface); font-size: 11px; }
.wallpaper-controls { display: flex; flex-wrap: wrap; align-items: center; gap: 9px; }
.inline-label { display: inline-flex; align-items: center; gap: 8px; margin: 0 0 0 auto; color: var(--muted); }
.inline-label select { width: auto; min-width: 130px; height: 38px; }
.account-box, .sync-token-row, .import-box { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin-top: 18px; padding: 14px; border: 1px solid var(--edge); border-radius: 13px; background: rgb(255 255 255 / 3%); }
.account-box strong, .account-box small, .import-box strong, .import-box small { display: block; }
.account-box strong, .import-box strong { font-size: 12px; font-weight: 550; }
.account-box small, .import-box small { margin-top: 5px; color: var(--muted); font-size: 10px; line-height: 1.5; }
.sync-token-row code { display: block; min-width: 0; overflow: auto; color: var(--accent); font: 11px ui-monospace, SFMono-Regular, Consolas, monospace; white-space: nowrap; }
.import-box { flex-wrap: wrap; }
.import-box > div { flex: 1 1 230px; }
.import-box .form-hint { flex-basis: 100%; }
.form-hint { color: var(--quiet); font-size: 10px; line-height: 1.6; }
.password-form { display: grid; width: min(470px, 100%); }
.password-form .field-label:not(:first-child) { margin-top: 14px; }
.password-form .primary-button { width: fit-content; margin-top: 16px; }

@media (max-width: 620px) {
  .admin-shell { padding: 17px 14px 40px; }
  .admin-intro { margin: 42px 0 22px; }
  .admin-tabs { width: 100%; overflow: auto; justify-content: flex-start; scrollbar-width: none; }
  .admin-tabs::-webkit-scrollbar { display: none; }
  .admin-tab { flex: 0 0 auto; }
  .admin-panel { padding: 20px 16px; }
  .category-admin-row { grid-template-columns: 1fr 1fr; }
  .category-admin-name { grid-column: 1 / -1; }
  .category-admin-row .remove-category { justify-self: end; }
  .inline-label { width: 100%; margin: 2px 0 0; }
  .inline-label select { flex: 1; }
  .wallpaper-controls > button, .wallpaper-controls > .file-picker { flex: 1; }
  .panel-footer { align-items: flex-start; flex-direction: column; }
  .panel-footer .primary-button, .panel-footer .secondary-button { width: 100%; }
  .sync-token-row { align-items: stretch; flex-direction: column; }
  .sync-token-row .primary-button { width: 100%; }
}
