/* LIFE QUEST — modern monochrome: pure black, white accents. */

@font-face { font-family: 'Inter'; src: url('../fonts/inter.woff2') format('woff2'); font-weight: 100 900; font-display: swap; }

:root {
  --r: 16px;
  --r-sm: 10px;
  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --ease: cubic-bezier(.2, .7, .2, 1);
}
/* ---------- colourways (picked in Settings; Midnight is the original) ---------- */
:root, [data-theme=midnight] {
  color-scheme: dark;
  --bg: #000; --surface: #0b0b0b; --surface-2: #141414;
  --fg: #fff; --muted: color-mix(in srgb, #fff 62%, transparent); --faint: color-mix(in srgb, #fff 38%, transparent);
  --line: color-mix(in srgb, #fff 9%, transparent); --line-2: color-mix(in srgb, #fff 18%, transparent);
  --accent: #fff; --on-accent: #000; --accent-text: #fff;
  --shadow: rgba(0, 0, 0, .6); --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='16' height='16' fill='none' stroke='%23fff' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}
[data-theme=ocean] {
  color-scheme: dark;
  --bg: #0a1220; --surface: #0f1a2c; --surface-2: #16243a;
  --fg: #e8f0fb; --muted: color-mix(in srgb, #e8f0fb 62%, transparent); --faint: color-mix(in srgb, #e8f0fb 38%, transparent);
  --line: color-mix(in srgb, #e8f0fb 9%, transparent); --line-2: color-mix(in srgb, #e8f0fb 18%, transparent);
  --accent: #6cb6ff; --on-accent: #06121f; --accent-text: #6cb6ff;
  --shadow: rgba(0, 0, 0, .6); --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='16' height='16' fill='none' stroke='%23e8f0fb' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}
[data-theme=forest] {
  color-scheme: dark;
  --bg: #0c1410; --surface: #121d17; --surface-2: #1a2820;
  --fg: #e9f3ec; --muted: color-mix(in srgb, #e9f3ec 62%, transparent); --faint: color-mix(in srgb, #e9f3ec 38%, transparent);
  --line: color-mix(in srgb, #e9f3ec 9%, transparent); --line-2: color-mix(in srgb, #e9f3ec 18%, transparent);
  --accent: #7fd3a0; --on-accent: #0b2015; --accent-text: #7fd3a0;
  --shadow: rgba(0, 0, 0, .6); --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='16' height='16' fill='none' stroke='%23e9f3ec' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}
[data-theme=plum] {
  color-scheme: dark;
  --bg: #160e1a; --surface: #1f1424; --surface-2: #2a1c31;
  --fg: #f6eaf7; --muted: color-mix(in srgb, #f6eaf7 62%, transparent); --faint: color-mix(in srgb, #f6eaf7 38%, transparent);
  --line: color-mix(in srgb, #f6eaf7 9%, transparent); --line-2: color-mix(in srgb, #f6eaf7 18%, transparent);
  --accent: #f08dc6; --on-accent: #2a0d1e; --accent-text: #f08dc6;
  --shadow: rgba(0, 0, 0, .6); --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='16' height='16' fill='none' stroke='%23f6eaf7' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}
[data-theme=paper] {
  color-scheme: light;
  --bg: #f6f6f4; --surface: #ffffff; --surface-2: #efefec;
  --fg: #141414; --muted: color-mix(in srgb, #141414 64%, transparent); --faint: color-mix(in srgb, #141414 42%, transparent);
  --line: color-mix(in srgb, #141414 10%, transparent); --line-2: color-mix(in srgb, #141414 20%, transparent);
  --accent: #141414; --on-accent: #ffffff; --accent-text: #141414;
  --shadow: rgba(20, 20, 20, .14); --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='16' height='16' fill='none' stroke='%23141414' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}
[data-theme=blush] {
  color-scheme: light;
  --bg: #fdf3f3; --surface: #ffffff; --surface-2: #fbe7ea;
  --fg: #3a2a2e; --muted: color-mix(in srgb, #3a2a2e 66%, transparent); --faint: color-mix(in srgb, #3a2a2e 44%, transparent);
  --line: color-mix(in srgb, #3a2a2e 10%, transparent); --line-2: color-mix(in srgb, #3a2a2e 20%, transparent);
  --accent: #c8476e; --on-accent: #ffffff; --accent-text: #b23c60;
  --shadow: rgba(120, 40, 60, .14); --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='16' height='16' fill='none' stroke='%233a2a2e' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}
[data-theme=lavender] {
  color-scheme: light;
  --bg: #f5f2ff; --surface: #ffffff; --surface-2: #ece6fd;
  --fg: #2e2843; --muted: color-mix(in srgb, #2e2843 66%, transparent); --faint: color-mix(in srgb, #2e2843 44%, transparent);
  --line: color-mix(in srgb, #2e2843 10%, transparent); --line-2: color-mix(in srgb, #2e2843 20%, transparent);
  --accent: #7656dc; --on-accent: #ffffff; --accent-text: #6446c8;
  --shadow: rgba(60, 40, 120, .14); --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='16' height='16' fill='none' stroke='%232e2843' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}
[data-theme=sand] {
  color-scheme: light;
  --bg: #f7f1e7; --surface: #fffdf8; --surface-2: #f0e7d7;
  --fg: #3a3128; --muted: color-mix(in srgb, #3a3128 66%, transparent); --faint: color-mix(in srgb, #3a3128 44%, transparent);
  --line: color-mix(in srgb, #3a3128 11%, transparent); --line-2: color-mix(in srgb, #3a3128 22%, transparent);
  --accent: #ad582c; --on-accent: #ffffff; --accent-text: #9a4c24;
  --shadow: rgba(90, 60, 30, .14); --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='16' height='16' fill='none' stroke='%233a3128' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}
[data-theme=peach] {
  color-scheme: light;
  --bg: #fff4ec; --surface: #ffffff; --surface-2: #ffe7d9;
  --fg: #4a3228; --muted: color-mix(in srgb, #4a3228 66%, transparent); --faint: color-mix(in srgb, #4a3228 44%, transparent);
  --line: color-mix(in srgb, #4a3228 10%, transparent); --line-2: color-mix(in srgb, #4a3228 20%, transparent);
  --accent: #c2552e; --on-accent: #ffffff; --accent-text: #a8461f;
  --shadow: rgba(150, 80, 40, .14); --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='16' height='16' fill='none' stroke='%234a3228' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}
[data-theme=mint] {
  color-scheme: light;
  --bg: #eefaf4; --surface: #ffffff; --surface-2: #d9f2e6;
  --fg: #203c35; --muted: color-mix(in srgb, #203c35 66%, transparent); --faint: color-mix(in srgb, #203c35 44%, transparent);
  --line: color-mix(in srgb, #203c35 10%, transparent); --line-2: color-mix(in srgb, #203c35 20%, transparent);
  --accent: #25785d; --on-accent: #ffffff; --accent-text: #1f6a52;
  --shadow: rgba(30, 90, 70, .14); --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='16' height='16' fill='none' stroke='%23203c35' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}
[data-theme=sky] {
  color-scheme: light;
  --bg: #eff6ff; --surface: #ffffff; --surface-2: #dbebfc;
  --fg: #1d3350; --muted: color-mix(in srgb, #1d3350 66%, transparent); --faint: color-mix(in srgb, #1d3350 44%, transparent);
  --line: color-mix(in srgb, #1d3350 10%, transparent); --line-2: color-mix(in srgb, #1d3350 20%, transparent);
  --accent: #356fb5; --on-accent: #ffffff; --accent-text: #2c5f9c;
  --shadow: rgba(40, 80, 140, .14); --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='16' height='16' fill='none' stroke='%231d3350' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}
[data-theme=butter] {
  color-scheme: light;
  --bg: #fffbe8; --surface: #fffef7; --surface-2: #faf0c4;
  --fg: #433a1c; --muted: color-mix(in srgb, #433a1c 66%, transparent); --faint: color-mix(in srgb, #433a1c 44%, transparent);
  --line: color-mix(in srgb, #433a1c 10%, transparent); --line-2: color-mix(in srgb, #433a1c 20%, transparent);
  --accent: #d4a017; --on-accent: #2e2400; --accent-text: #7d6200;
  --shadow: rgba(120, 100, 30, .14); --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='16' height='16' fill='none' stroke='%23433a1c' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}
[data-theme=candy] {
  color-scheme: light;
  --bg: #fdf3fa; --surface: #ffffff; --surface-2: #f5e2f1;
  --fg: #3c2943; --muted: color-mix(in srgb, #3c2943 66%, transparent); --faint: color-mix(in srgb, #3c2943 44%, transparent);
  --line: color-mix(in srgb, #3c2943 10%, transparent); --line-2: color-mix(in srgb, #3c2943 20%, transparent);
  --accent: #b04c92; --on-accent: #ffffff; --accent-text: #9b3f80;
  --shadow: rgba(120, 50, 110, .14); --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='16' height='16' fill='none' stroke='%233c2943' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}
[data-theme=sage] {
  color-scheme: light;
  --bg: #f2f6f0; --surface: #ffffff; --surface-2: #e2eadd;
  --fg: #2d3a2a; --muted: color-mix(in srgb, #2d3a2a 66%, transparent); --faint: color-mix(in srgb, #2d3a2a 44%, transparent);
  --line: color-mix(in srgb, #2d3a2a 10%, transparent); --line-2: color-mix(in srgb, #2d3a2a 20%, transparent);
  --accent: #587a4c; --on-accent: #ffffff; --accent-text: #4b6a40;
  --shadow: rgba(50, 70, 45, .14); --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='16' height='16' fill='none' stroke='%232d3a2a' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}
[data-theme=dusk] {
  color-scheme: dark;
  --bg: #1a1929; --surface: #222135; --surface-2: #2c2a43;
  --fg: #eceaff; --muted: color-mix(in srgb, #eceaff 64%, transparent); --faint: color-mix(in srgb, #eceaff 40%, transparent);
  --line: color-mix(in srgb, #eceaff 9%, transparent); --line-2: color-mix(in srgb, #eceaff 18%, transparent);
  --accent: #c6b4ff; --on-accent: #1f1640; --accent-text: #c6b4ff;
  --shadow: rgba(0, 0, 0, .55); --chev: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='16' height='16' fill='none' stroke='%23eceaff' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; background: var(--bg); color: var(--fg); transition: background-color .25s, color .25s;
  font: 400 16px/1.5 var(--font); font-feature-settings: 'cv11', 'ss01';
  -webkit-font-smoothing: antialiased;
}
::selection { background: var(--accent); color: var(--on-accent); }
a { color: inherit; text-decoration: none; }
p { margin: 0; }
h1, h2, h3 { margin: 0; font-weight: 600; letter-spacing: -.01em; }
.i { flex: none; display: block; }
.muted { color: var(--muted); }
.faint { color: var(--faint); }
.small { font-size: 13px; }
.num { font-variant-numeric: tabular-nums; }
.empty { color: var(--faint); font-size: 15px; padding: 6px 0; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 16px; top: 12px; z-index: 200; background: var(--accent); color: var(--on-accent); padding: 8px 12px; border-radius: 8px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- layout ---------- */
.shell { display: grid; grid-template-columns: minmax(0, 1fr); min-height: 100vh; }
.shell > * { min-width: 0; }
.side { position: sticky; top: 0; z-index: 40; background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 12px; padding: 14px 20px 10px; }
.avatar {
  width: 40px; height: 40px; flex: none; border-radius: 50%; display: grid; place-items: center;
  background: var(--accent); color: var(--on-accent); font-weight: 700; font-size: 15px;
}
.brand-text { flex: 1; min-width: 0; }
.brand-name { font-weight: 600; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.brand-lv { display: flex; align-items: center; gap: 10px; font-size: 12px; color: var(--muted); }
.brand-lv .bar { flex: 1; max-width: 160px; }
.badge { flex: none; font-size: 11px; font-weight: 600; padding: 3px 8px; border-radius: 999px; border: 1px solid var(--line-2); color: var(--muted); }

.nav { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding: 4px 20px 12px; }
.nav::-webkit-scrollbar { display: none; }
.nav a {
  flex: none; display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 14px;
  border-radius: 999px; font-size: 14px; font-weight: 500; color: var(--muted);
  border: 1px solid var(--line); transition: background .15s, color .15s, border-color .15s;
}
.nav a:hover { color: var(--fg); border-color: var(--line-2); }
.nav a.active { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.nav a .i { width: 17px; height: 17px; }
.side-foot { display: none; }

main { width: 100%; max-width: 760px; margin: 0 auto; padding: 20px 16px 110px; }
.view { display: grid; gap: 16px; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; padding: 6px 4px 2px; }
.page-head h1 { font-size: 28px; letter-spacing: -.02em; }
.page-head p { color: var(--muted); font-size: 14px; margin-top: 2px; }

@media (min-width: 960px) {
  .shell { grid-template-columns: 248px minmax(0, 1fr); }
  .side { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; border-bottom: 0; border-right: 1px solid var(--line); background: var(--bg); backdrop-filter: none; }
  .brand { padding: 24px 20px 18px; }
  .nav { flex-direction: column; overflow: visible; padding: 4px 12px; gap: 2px; }
  .nav a { height: 40px; border: 0; border-radius: var(--r-sm); padding: 0 12px; font-size: 14.5px; }
  .nav a.active { background: var(--surface-2); color: var(--fg); box-shadow: inset 3px 0 0 var(--accent); }
  .mobile-only { display: none; }
  .side-foot { display: block; margin-top: auto; padding: 16px 20px 22px; font-size: 12px; color: var(--faint); }
  main { padding: 36px 40px 80px; }
}

/* ---------- cards ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 18px; }
.card-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 14px; }
.card-head h2 { font-size: 15px; }
.card-head .meta { font-size: 13px; color: var(--muted); }
.grid-2 { display: grid; gap: 16px; }
@media (min-width: 680px) and (max-width: 959px), (min-width: 1120px) { .grid-2 { grid-template-columns: 1fr 1fr; } }

/* ---------- bars ---------- */
.bar { height: 6px; border-radius: 999px; background: color-mix(in srgb, var(--fg) 10%, transparent); overflow: hidden; }
.bar i { display: block; height: 100%; border-radius: inherit; background: var(--accent); transition: width .5s var(--ease); }
.bar.thick { height: 8px; }

/* ---------- controls ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 42px; padding: 0 16px; border-radius: 999px; cursor: pointer;
  font: 600 14px var(--font); color: var(--fg); background: transparent; border: 1px solid var(--line-2);
  transition: background .15s, color .15s, border-color .15s, transform .1s;
}
.btn:hover { border-color: var(--accent); }
.btn:active { transform: scale(.98); }
.btn.primary { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.btn.primary:hover { background: color-mix(in srgb, var(--accent) 86%, var(--bg)); }
.btn.sm { height: 34px; padding: 0 12px; font-size: 13px; }
.btn:disabled { opacity: .35; cursor: not-allowed; }
.icon-btn {
  width: 36px; height: 36px; flex: none; display: grid; place-items: center; border-radius: 50%;
  background: none; border: 0; color: var(--faint); cursor: pointer; transition: background .15s, color .15s;
}
.icon-btn:hover { background: var(--surface-2); color: var(--fg); }
.icon-btn .i { width: 18px; height: 18px; }
.text-btn { background: none; border: 0; padding: 0; color: var(--muted); font: 500 13px var(--font); cursor: pointer; }
.text-btn:hover { color: var(--fg); }

input, select, textarea {
  width: 100%; min-width: 0; font: 400 16px/1.4 var(--font); color: var(--fg);
  background: var(--bg); border: 1px solid var(--line-2); border-radius: var(--r-sm); padding: 10px 12px; min-height: 44px;
  transition: border-color .15s;
}
input::placeholder, textarea::placeholder { color: var(--faint); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); }
select {
  appearance: none; padding-right: 36px; cursor: pointer;
  background: var(--bg) var(--chev) no-repeat right 12px center;
}
input[type=number] { -moz-appearance: textfield; }
input[type=number]::-webkit-inner-spin-button { -webkit-appearance: none; }
textarea { resize: vertical; line-height: 1.55; }
.field { display: grid; gap: 6px; min-width: 0; font-size: 13px; color: var(--muted); font-weight: 500; }

.form { display: grid; gap: 12px; }
.fields { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); }
.row { display: flex; align-items: center; gap: 10px; min-width: 0; }
.row.wrap { flex-wrap: wrap; }
.row.end { justify-content: flex-end; }
.row.spread { justify-content: space-between; }
.grow { flex: 1; min-width: 0; }
.seg { display: inline-flex; padding: 3px; border-radius: 999px; border: 1px solid var(--line-2); gap: 2px; flex-wrap: wrap; }
.seg label { cursor: pointer; }
.seg input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.seg span { display: block; padding: 6px 14px; border-radius: 999px; font-size: 13px; font-weight: 500; color: var(--muted); }
.seg input:checked + span { background: var(--accent); color: var(--on-accent); }
.seg input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 1px; }

/* ---------- lists ---------- */
.list { list-style: none; margin: 0; padding: 0; }
.item { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.item:first-child { border-top: 0; padding-top: 2px; }
.item .body { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.item .title { font-size: 15.5px; }
.item .sub { font-size: 13px; color: var(--muted); margin-top: 2px; }
.item.done .title { color: var(--faint); text-decoration: line-through; }
.xp { flex: none; font-size: 12px; font-weight: 600; color: var(--faint); font-variant-numeric: tabular-nums; }
.pill { display: inline-block; font-size: 11px; font-weight: 600; letter-spacing: .02em; padding: 2px 8px; border-radius: 999px; border: 1px solid var(--line-2); color: var(--muted); vertical-align: 1px; margin-right: 6px; }
.pill.solid { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.due-late { color: var(--accent-text); font-weight: 600; }
.check {
  width: 26px; height: 26px; flex: none; border-radius: 50%; border: 1.5px solid var(--line-2);
  background: none; color: var(--on-accent); display: grid; place-items: center; cursor: pointer; padding: 0;
  transition: background .15s, border-color .15s, transform .1s;
}
.check:hover { border-color: var(--accent); }
.check:active { transform: scale(.9); }
.check .i { width: 15px; height: 15px; opacity: 0; }
.check.on { background: var(--accent); border-color: var(--accent); }
.check.on .i { opacity: 1; }
details > summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center; font-size: 15px; font-weight: 600; }
details > summary::-webkit-details-marker { display: none; }
details > summary::after { content: '+'; font-weight: 400; font-size: 20px; color: var(--muted); }
details[open] > summary::after { content: '−'; }
details[open] > summary { margin-bottom: 12px; }

/* ---------- home ---------- */
.hero { display: grid; gap: 18px; padding: 22px; }
.hero-top { display: flex; align-items: center; gap: 16px; }
.hero .avatar { width: 56px; height: 56px; font-size: 20px; }
.hero-name { font-size: 22px; font-weight: 650; letter-spacing: -.02em; display: flex; align-items: center; gap: 6px; }
.hero-sub { color: var(--muted); font-size: 14px; }
.lv-row { display: flex; justify-content: space-between; font-size: 13px; color: var(--muted); margin-bottom: 8px; }
.lv-row b { color: var(--fg); font-weight: 600; }
.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 680px) { .stats { grid-template-columns: repeat(3, 1fr); } }
.stat { display: grid; gap: 8px; padding: 14px; border-radius: 12px; background: var(--surface-2); border: 1px solid transparent; transition: border-color .15s; }
.stat:hover { border-color: var(--line-2); }
.stat-top { display: flex; justify-content: space-between; align-items: baseline; gap: 6px; }
.stat-name { font-size: 14px; font-weight: 600; }
.stat-lv { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
.stat-from { font-size: 12px; color: var(--faint); }
.today { display: grid; gap: 0; }
.today a { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.today a:first-child { border-top: 0; padding-top: 0; }
.today .i { color: var(--muted); }
.today .t-label { font-weight: 500; min-width: 72px; }
.today .t-val { flex: 1; min-width: 0; color: var(--muted); font-size: 14px; text-align: right; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dots { display: inline-flex; gap: 5px; vertical-align: middle; margin-right: 8px; }
.dots i { width: 8px; height: 8px; border-radius: 50%; background: color-mix(in srgb, var(--fg) 16%, transparent); }
.dots i.on { background: var(--accent); }
.quote { margin: 0; font-size: 19px; line-height: 1.45; letter-spacing: -.01em; font-weight: 450; }
.quote cite { display: block; margin-top: 10px; font-size: 14px; color: var(--muted); font-style: normal; }
.quote.big { font-size: 22px; }

/* ---------- prayer ---------- */
.daynav { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 14px; }
.daynav .date { text-align: center; }
.daynav .date b { display: block; font-size: 16px; font-weight: 600; }
.daynav .date span { font-size: 13px; color: var(--muted); }
.prayers { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.prayer {
  width: 100%; display: flex; align-items: center; gap: 14px; padding: 14px 16px;
  border-radius: 12px; border: 1px solid var(--line); background: var(--surface-2); color: var(--fg);
  font: 500 16px var(--font); text-align: left; cursor: pointer; transition: background .15s, border-color .15s, color .15s;
}
.prayer:hover { border-color: var(--line-2); }
.prayer .check { pointer-events: none; }
.prayer .name { flex: 1; }
.prayer.on { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.prayer.on .check { background: var(--on-accent); border-color: var(--on-accent); color: var(--accent); }
.prayer.on .check .i { opacity: 1; }
.prayer.on .xp { color: color-mix(in srgb, var(--on-accent) 55%, transparent); }
.fullday { text-align: center; font-size: 13px; color: var(--muted); margin-top: 12px; }
.pgrid { display: grid; grid-template-columns: 64px repeat(var(--cols), 1fr); gap: 8px 6px; align-items: center; justify-items: center; }
.pgrid .lbl { justify-self: start; font-size: 12px; color: var(--muted); }
.pgrid .dh { font-size: 12px; color: var(--muted); }
.pgrid .dh.sel { color: var(--fg); font-weight: 700; }
.cell { width: 22px; height: 22px; padding: 0; border-radius: 50%; border: 1.5px solid var(--line-2); background: none; cursor: pointer; }
.cell.on { background: var(--accent); border-color: var(--accent); }
.awrad-lbl, .awrad-cell { margin-top: 8px; }
.awrad-cell { border-radius: 6px; }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(100px, 1fr)); gap: 10px; }
.kpi { padding: 12px 14px; border-radius: 12px; background: var(--surface-2); }
.kpi b { display: block; font-size: 22px; font-weight: 650; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.kpi span { font-size: 12px; color: var(--muted); }

/* ---------- fitness chart ---------- */
.chart { display: grid; grid-template-columns: repeat(7, 1fr); gap: 10px; height: 150px; margin-top: 16px; }
.chart .col { display: grid; grid-template-rows: 18px 1fr 18px; justify-items: center; gap: 6px; }
.chart .v { font-size: 11px; color: var(--muted); font-variant-numeric: tabular-nums; }
.chart .b { width: 100%; max-width: 30px; display: flex; align-items: flex-end; border-radius: 8px; background: color-mix(in srgb, var(--fg) 6%, transparent); overflow: hidden; }
.chart .b i { width: 100%; border-radius: 8px; background: var(--accent); min-height: 0; transition: height .5s var(--ease); }
.chart .d { font-size: 12px; color: var(--muted); }
.chart .d.sel { color: var(--fg); font-weight: 700; }

/* ---------- books ---------- */
.book { padding: 14px 0; border-top: 1px solid var(--line); display: grid; gap: 10px; }
.book:first-child { border-top: 0; padding-top: 0; }
.book-title { font-size: 16px; font-weight: 600; }
.cover { width: 56px; aspect-ratio: 2 / 3; flex: none; object-fit: cover; border-radius: 6px; background: var(--surface-2); border: 1px solid var(--line); }
.cover.sm { width: 36px; border-radius: 4px; }
.isbn-result:empty { display: none; }
.stars { display: inline-flex; flex: none; }
.star { background: none; border: 0; padding: 2px; cursor: pointer; color: var(--line-2); font-size: 18px; line-height: 1; }
.star.on { color: var(--accent); }
.star:hover { color: var(--accent); }

/* ---------- notes ---------- */
.notes { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
@media (min-width: 680px) { .notes { grid-template-columns: 1fr 1fr; } }
.note {
  width: 100%; height: 100%; text-align: left; font: inherit; color: var(--fg); cursor: pointer;
  background: var(--surface-2); border: 1px solid transparent; border-radius: 12px; padding: 14px; display: grid; gap: 6px; align-content: start;
}
.note:hover, .note.sel { border-color: var(--line-2); }
.note-top { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.note-title { font-weight: 600; font-size: 15px; display: flex; gap: 6px; align-items: center; min-width: 0; }
.note-title .i { width: 14px; height: 14px; }
.note-date { font-size: 12px; color: var(--faint); flex: none; }
.snippet { font-size: 14px; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.editor-title { font-size: 20px; font-weight: 600; border: 0; padding: 4px 0; background: none; border-radius: 0; }
.editor-title:focus { border: 0; }
.editor-body { border: 0; padding: 4px 0; background: none; border-radius: 0; min-height: 260px; font-size: 16px; }

/* ---------- toast + level up ---------- */
.toast {
  position: fixed; left: 50%; bottom: 24px; z-index: 90; max-width: calc(100% - 32px);
  padding: 12px 18px; border-radius: 999px; background: var(--accent); color: var(--on-accent);
  font-size: 14px; font-weight: 600; box-shadow: 0 10px 40px var(--shadow);
  transform: translate(-50%, 140%); opacity: 0; transition: transform .3s var(--ease), opacity .3s; cursor: pointer;
}
.toast.show { transform: translate(-50%, 0); opacity: 1; }
.toast.err { background: var(--surface-2); color: var(--fg); border: 1px solid var(--line-2); border-radius: var(--r-sm); }
.levelup { position: fixed; inset: 0; z-index: 150; display: grid; place-items: center; padding: 24px; background: color-mix(in srgb, var(--bg) 80%, transparent); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); animation: fade .2s; }
.lu-card { width: min(340px, 100%); text-align: center; padding: 32px 24px 24px; border-radius: 24px; background: var(--surface); border: 1px solid var(--line-2); animation: pop .35s var(--ease); }
.lu-kicker { font-size: 13px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.lu-level { font-size: 72px; font-weight: 700; letter-spacing: -.04em; line-height: 1.1; margin: 4px 0 8px; }
.lu-line { color: var(--muted); font-size: 15px; margin-bottom: 4px; }
.lu-card .btn { margin-top: 18px; width: 100%; }
@keyframes fade { from { opacity: 0; } }
@keyframes pop { from { opacity: 0; transform: scale(.94); } }

/* ---------- sign in ---------- */
.auth { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.auth-card { width: min(380px, 100%); display: grid; gap: 22px; }
.auth-mark { width: 48px; height: 48px; border-radius: 14px; background: var(--accent); color: var(--on-accent); display: grid; place-items: center; }
.auth h1 { font-size: 30px; letter-spacing: -.03em; }
.auth p.lead { color: var(--muted); margin-top: 6px; }
.msg { min-height: 1.4em; font-size: 14px; color: var(--muted); }
.loading { min-height: 60vh; display: grid; place-items: center; color: var(--faint); font-size: 14px; }
.err-card h2 { margin-bottom: 6px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ---------- settings ---------- */
.i-wrap { width: 36px; height: 36px; flex: none; display: grid; place-items: center; border-radius: 10px; background: var(--surface-2); color: var(--muted); }
.switch-row { cursor: pointer; display: grid; gap: 1px; }
.switch { position: relative; flex: none; width: 46px; height: 28px; }
.switch input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; z-index: 1; width: 100%; height: 100%; min-height: 0; }
.switch i { position: absolute; inset: 0; border-radius: 999px; background: color-mix(in srgb, var(--fg) 14%, transparent); transition: background .15s; }
.switch i::after { content: ''; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: var(--muted); transition: transform .18s var(--ease), background .15s; }
.switch input:checked + i { background: var(--accent); }
.switch input:checked + i::after { transform: translateX(18px); background: var(--on-accent); }
.switch input:focus-visible + i { outline: 2px solid var(--accent); outline-offset: 2px; }
.nav a[data-view=settings] { margin-left: auto; }
@media (min-width: 960px) { .nav a[data-view=settings] { margin: 8px 0 0; } }
.banner { display: flex; align-items: center; gap: 14px; }
.banner .grow p:first-child { font-weight: 600; }

/* ---------- finance ---------- */
.monthnav { display: inline-flex; align-items: center; gap: 4px; }
.monthnav b { min-width: 118px; text-align: center; font-size: 15px; font-weight: 600; }
.amt { flex: none; font-weight: 600; font-variant-numeric: tabular-nums; }
.amt.in { color: var(--fg); }
.amt.out { color: var(--muted); }
.budget { display: grid; gap: 6px; padding: 10px 0; border-top: 1px solid var(--line); }
.budget:first-child { border-top: 0; padding-top: 0; }
.budget .row { justify-content: space-between; }
.budget .over { color: var(--accent-text); font-weight: 700; }
.bar.over i { background: repeating-linear-gradient(45deg, var(--accent) 0 6px, color-mix(in srgb, var(--accent) 55%, transparent) 6px 12px); }
.goal { display: grid; gap: 8px; padding: 12px 0; border-top: 1px solid var(--line); }
.goal:first-child { border-top: 0; padding-top: 0; }
.cat-row input.budget-in { width: 120px; }
.kpi.neg b { color: var(--muted); }

.mover { display: grid; flex: none; margin: -6px 0 -6px -6px; }
.mover .icon-btn { width: 30px; height: 24px; border-radius: 6px; }
.mover .icon-btn:disabled { opacity: .2; cursor: default; background: none; }
#dirty { margin-right: auto; }

/* ---------- prayer times ---------- */
.ptime { font-size: 14px; font-weight: 500; color: var(--muted); font-variant-numeric: tabular-nums; }
.prayer.on .ptime { color: color-mix(in srgb, var(--on-accent) 62%, transparent); }
.prayer.next:not(.on) { border-color: var(--accent); }
.prayer .pill { margin-left: 6px; vertical-align: 2px; }
.daynav .hijri { display: block; font-size: 12px; color: var(--faint); }
.pt-source { text-align: center; font-size: 12px; color: var(--faint); margin-top: 6px; }
.pt-source a { text-decoration: underline; }
.next-name { font-weight: 600; color: var(--fg); }

/* ---------- what's new ---------- */
.nav a.has-new { position: relative; }
.nav a.has-new::after { content: ''; position: absolute; top: 7px; right: 7px; width: 7px; height: 7px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 2px var(--bg); }
.nav a.has-new.active::after { background: var(--on-accent); box-shadow: 0 0 0 2px var(--accent); }
.log { display: grid; gap: 14px; }
.log-entry { padding-top: 14px; border-top: 1px solid var(--line); }
.log-entry:first-child { padding-top: 0; border-top: 0; }
.log-head { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; margin-bottom: 6px; }
.log-head b { font-weight: 600; }
.log-head .faint { margin-left: auto; }
.log-entry ul { margin: 0; padding-left: 18px; color: var(--muted); font-size: 14px; display: grid; gap: 3px; }

.dots i.aw { border-radius: 2px; margin-left: 3px; }
.today a { min-width: 0; }
.today .t-label { flex: none; }
.today .t-val { display: flex; align-items: center; justify-content: flex-end; gap: 0; }
.today .t-val .dots { flex: none; }
.today .t-txt { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- fine print ---------- */
.fine { max-width: 760px; margin: 0 auto; padding: 0 16px 28px; text-align: center; font-size: 11.5px; line-height: 1.5; color: var(--faint); }
.fine a { color: var(--muted); text-decoration: underline; text-underline-offset: 2px; }
.fine a:hover { color: var(--fg); }
main { padding-bottom: 36px; }
.auth { grid-template-rows: 1fr auto; }
.auth .fine { padding-top: 24px; align-self: end; }
@media (min-width: 960px) { .shell > .fine { grid-column: 2; padding: 0 40px 32px; } main { padding-bottom: 40px; } }
.today .t-label { min-width: 0; margin-right: auto; }
.today .dots { gap: 4px; margin-right: 6px; }
.today .dots i { width: 7px; height: 7px; }

/* ---------- barcode scanner ---------- */
.scanner { position: fixed; inset: 0; z-index: 160; background: #000; display: grid; grid-template-rows: auto 1fr auto auto; padding: max(12px, env(safe-area-inset-top)) 16px max(16px, env(safe-area-inset-bottom)); gap: 12px; }
.scan-top { display: flex; align-items: center; justify-content: space-between; }
.scan-title { font-weight: 600; font-size: 17px; }
.scan-close { color: var(--fg); }
.scan-stage { position: relative; overflow: hidden; border-radius: var(--r); background: #0b0b0b; min-height: 0; }
.scan-stage video { width: 100%; height: 100%; object-fit: cover; display: block; }
.scan-box { position: absolute; inset: 0; display: grid; place-items: center; pointer-events: none; }
.scan-box::before { content: ''; width: min(82%, 520px); aspect-ratio: 2 / 1; border-radius: 14px; box-shadow: 0 0 0 9999px rgba(0, 0, 0, .55); outline: 2px solid var(--fg); }
.scan-box i { position: absolute; width: min(74%, 470px); height: 2px; background: rgba(255, 255, 255, .85); animation: scanline 1.6s ease-in-out infinite alternate; }
@keyframes scanline { from { transform: translateY(-46px); } to { transform: translateY(46px); } }
.scan-hint { text-align: center; color: var(--muted); font-size: 14px; min-height: 1.4em; }
.scan-manual input { flex: 1; }
.scan-btn { flex: none; }

/* ---------- comics ---------- */
.cover-blank { display: grid; place-items: center; color: var(--faint); }
details.more { position: relative; flex: none; }
details.more > summary { list-style: none; font-size: 20px; line-height: 1; margin: 0; }
details.more > summary::after { content: none; }
details.more[open] > summary { margin: 0; background: var(--surface-2); color: var(--fg); }
.more-menu { position: absolute; right: 0; top: 40px; z-index: 30; min-width: 170px; display: grid; padding: 6px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line-2); box-shadow: 0 12px 30px var(--shadow); }
.more-menu .text-btn { text-align: left; padding: 10px 12px; border-radius: 8px; font-size: 14px; color: var(--fg); }
.more-menu .text-btn:hover { background: color-mix(in srgb, var(--fg) 7%, transparent); }
.item > .btn.sm { flex: none; }

/* ---------- sleep ---------- */
.sleep-chart { position: relative; }
.sleep-chart .goal-line { position: absolute; left: 0; right: 0; height: 0; border-top: 1.5px dashed color-mix(in srgb, var(--fg) 45%, transparent); z-index: 1; pointer-events: none; }
.sleep-chart .goal-line span { position: absolute; right: 0; top: -20px; font-size: 11px; color: var(--muted); background: var(--surface); padding: 0 4px; }
.sleep-chart .b i.under { background: color-mix(in srgb, var(--accent) 45%, transparent); }

/* ---------- goals ---------- */
.goal-card { display: grid; gap: 12px; }
.goal-title { font-size: 18px; font-weight: 600; letter-spacing: -.01em; overflow-wrap: anywhere; }

/* ---------- finance: sadaqah ---------- */
.amt.give { color: var(--accent-text); }

/* ---------- MTG ---------- */
.decks { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.deck { display: grid; text-align: left; padding: 0; border-radius: 12px; overflow: hidden; cursor: pointer; color: var(--fg); font: inherit;
  background: var(--surface-2); border: 1px solid var(--line); transition: border-color .15s, transform .15s var(--ease); }
.deck:hover { border-color: var(--line-2); }
.deck.sel { border-color: var(--accent); }
.deck img, .deck .deck-blank { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; display: block; background: var(--surface); }
.deck .deck-blank { display: grid; place-items: center; color: var(--faint); }
.deck-body { display: grid; gap: 4px; padding: 10px 12px 12px; min-width: 0; }
.deck-name { font-weight: 600; font-size: 14.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.deck-sub { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); min-width: 0; }
.deck-sub > span:last-child { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pips { display: inline-flex; gap: 2px; vertical-align: -3px; flex: none; }
.pip { display: inline-grid; place-items: center; width: 16px; height: 16px; border-radius: 50%; font: 700 9px/1 var(--font); font-style: normal;
  border: 1px solid var(--line-2); color: var(--fg); background: var(--bg); }
.pip-W { background: #f3efe0; color: #111; border-color: transparent; }
.pip-U { background: #2f6fb1; border-color: transparent; }
.pip-B { background: #2a2626; }
.pip-R { background: #c4442d; border-color: transparent; }
.pip-G { background: #2f7d4a; border-color: transparent; }
.add-deck { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); }
.deck-detail { display: grid; gap: 14px; scroll-margin-top: 16px; }
.deck-art { width: calc(100% + 36px); margin: -18px -18px 0; max-width: none; aspect-ratio: 16 / 7; object-fit: cover; display: block; border-radius: var(--r) var(--r) 0 0; }
.deck-stats { display: grid; gap: 8px; }
.chart.curve { grid-template-columns: repeat(8, 1fr); height: 120px; margin-top: 8px; }
.list-head { margin: 6px 0 4px; text-transform: uppercase; letter-spacing: .06em; font-size: 11.5px; font-weight: 600; }
.cardlist { list-style: none; margin: 0 0 10px; padding: 0; columns: 2 200px; column-gap: 20px; font-size: 14px; }
.cardlist li { padding: 2px 0; break-inside: avoid; overflow-wrap: anywhere; }
.cardlist .num { display: inline-block; min-width: 1.6em; color: var(--muted); }

/* ---------- mood ---------- */
.moods { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; }
.moods label { cursor: pointer; }
.moods input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.moods span { display: grid; justify-items: center; gap: 4px; padding: 10px 2px; border-radius: 12px; border: 1px solid var(--line-2); font-size: 12px; color: var(--muted); text-align: center; }
.moods span b { font-size: 24px; line-height: 1; font-weight: 400; filter: grayscale(1); opacity: .75; }
.moods input:checked + span { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.moods input:checked + span b { filter: none; opacity: 1; }
.moods input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.mood-cal { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; max-width: 360px; }
.mc-h { font-size: 11px; color: var(--faint); text-align: center; }
.mc { aspect-ratio: 1; border-radius: 6px; background: color-mix(in srgb, var(--fg) 6%, transparent); display: block; }
.mc.future { background: transparent; border: 1px dashed var(--line); }
.mc.sel { outline: 1.5px solid var(--fg); outline-offset: 1px; }
.mc.m1 { background: color-mix(in srgb, var(--accent) 14%, transparent); }
.mc.m2 { background: color-mix(in srgb, var(--accent) 30%, transparent); }
.mc.m3 { background: color-mix(in srgb, var(--accent) 50%, transparent); }
.mc.m4 { background: color-mix(in srgb, var(--accent) 75%, transparent); }
.mc.m5 { background: var(--accent); }
.mc-key { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 12px; }
.mc-key span { display: inline-flex; align-items: center; gap: 6px; }
.mc-key .mc { width: 12px; height: 12px; border-radius: 3px; }
.face { font-size: 20px; flex: none; filter: grayscale(1); }

/* ---------- people ---------- */
.person { flex-wrap: wrap; }
.person .body { flex-basis: 12em; }
.person .quick { gap: 6px; flex: none; }
.person .quick .btn { padding-left: 10px; padding-right: 10px; }

/* ---------- watchlist ---------- */
.seg.filter { align-self: flex-start; }
.item .btn.sm .i { margin-right: 2px; }

/* ---------- theme picker (dropdown) ---------- */
.theme-dd { position: relative; }
.theme-dd > summary.theme-dd-btn { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-radius: var(--r-sm); border: 1px solid var(--line-2); background: var(--bg); font-size: 15px; font-weight: 500; margin: 0; }
.theme-dd > summary.theme-dd-btn::after { content: ''; width: 16px; height: 16px; background: var(--chev) no-repeat center; flex: none; }
.theme-dd[open] > summary.theme-dd-btn { border-color: var(--accent); margin: 0; }
.theme-dd[open] > summary.theme-dd-btn::after { transform: rotate(180deg); }
.theme-menu { position: absolute; left: 0; right: 0; top: calc(100% + 6px); z-index: 40; max-height: min(62vh, 520px); overflow-y: auto; padding: 6px;
  border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line-2); box-shadow: 0 14px 34px var(--shadow); }
.theme-group { padding: 10px 10px 4px; font-size: 11.5px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--faint); }
.theme-row { display: flex; align-items: center; gap: 12px; padding: 9px 10px; border-radius: 8px; cursor: pointer; font-size: 15px; }
.theme-row:hover { background: color-mix(in srgb, var(--fg) 7%, transparent); }
.theme-row input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.theme-row .i { visibility: hidden; color: var(--accent-text); }
.theme-row:has(input:checked) { font-weight: 600; }
.theme-row:has(input:checked) .i { visibility: visible; }
.theme-row:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: -2px; }
.sw { position: relative; flex: none; width: 34px; height: 24px; border-radius: 7px; overflow: hidden; border: 1px solid color-mix(in srgb, var(--s3) 18%, transparent);
  background: linear-gradient(135deg, var(--s0) 0 55%, var(--s1) 55% 100%); }
.sw i { position: absolute; right: 4px; bottom: 4px; width: 10px; height: 10px; border-radius: 50%; background: var(--s2); }

/* ---------- watchlist: TMDB ---------- */
.tmdb-search { position: relative; }
.tmdb-results { position: absolute; left: 0; right: 0; top: calc(100% + 6px); z-index: 35; max-height: min(60vh, 420px); overflow-y: auto; padding: 6px;
  border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line-2); box-shadow: 0 12px 30px var(--shadow); }
.tmdb-hit { display: flex; align-items: center; gap: 12px; width: 100%; padding: 8px; border: 0; border-radius: 8px; background: none; color: var(--fg); font: inherit; text-align: left; cursor: pointer; }
.tmdb-hit:hover, .tmdb-hit:focus-visible { background: color-mix(in srgb, var(--fg) 7%, transparent); }
.tmdb-hit img, .tmdb-noimg { width: 34px; aspect-ratio: 2 / 3; flex: none; object-fit: cover; border-radius: 4px; background: var(--surface); }
.tmdb-hit .grow { display: grid; gap: 1px; }
.tmdb-hit .t { font-size: 14.5px; font-weight: 500; overflow-wrap: anywhere; }
.tmdb-hit .s { font-size: 12.5px; color: var(--muted); }
.tmdb-pick { display: flex; align-items: center; gap: 12px; padding: 10px; border-radius: 12px; background: var(--surface-2); }
.tmdb-pick .title { font-weight: 600; font-size: 15px; }
.tmdb-pick .sub { font-size: 13px; color: var(--muted); }
#tmdb-picked:empty { display: none; }
.wl-item { align-items: flex-start; flex-wrap: wrap; }
.wl-item > .cover.sm { width: 44px; }
.wl-item .body { flex-basis: 10em; }
.wl-acts { display: flex; align-items: center; gap: 8px; flex: none; margin-left: auto; }
.wtw { color: var(--accent-text) !important; }
.wtw:empty { display: none; }
.wtw-label { color: var(--muted); }
.ov { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.tmdb-credit { padding: 0 4px; }
.tmdb-credit a:hover { color: var(--fg); }
.wl-tabs { display: grid; grid-template-columns: 1fr 1fr; width: 100%; }
.wl-tabs span { text-align: center; padding: 9px 14px; font-size: 14px; }
.wl-tabs b { font-weight: 600; opacity: .6; margin-left: 4px; font-variant-numeric: tabular-nums; }
.wl-date { display: inline-flex; align-items: center; gap: 6px; margin-top: 4px; font-size: 13px; color: var(--muted); cursor: pointer; }
.wl-date input { width: auto; min-height: 30px; padding: 3px 8px; font-size: 13px; border-color: var(--line); background: transparent; }
.wl-when { gap: 8px; }
.wl-when[hidden] { display: none; }

/* ---------- music ---------- */
.album-art { width: 52px; aspect-ratio: 1; flex: none; object-fit: cover; border-radius: 6px; background: var(--surface-2); border: 1px solid var(--line); display: block; }
.album-art.sm { width: 44px; }
.album-art.blank { display: grid; place-items: center; color: var(--faint); }
.tmdb-hit img.sq, .tmdb-noimg.sq { aspect-ratio: 1; width: 40px; }
.np { display: flex; align-items: center; gap: 12px; padding: 10px; border-radius: 12px; background: var(--surface-2); margin-bottom: 12px; }
.np .title { font-weight: 600; overflow-wrap: anywhere; }
.np .sub { font-size: 13px; color: var(--muted); }
.eq { display: inline-flex; align-items: flex-end; gap: 2px; height: 16px; flex: none; }
.eq i { width: 3px; background: var(--accent); border-radius: 1px; animation: eq 1s ease-in-out infinite alternate; }
.eq i:nth-child(2) { animation-delay: -.4s; } .eq i:nth-child(3) { animation-delay: -.7s; }
@keyframes eq { from { height: 4px; } to { height: 16px; } }
.lfm .kpis { margin-bottom: 4px; }
.album-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-bottom: 6px; }
@media (min-width: 680px) { .album-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); } }
.ag .album-art { width: 100%; border-radius: 8px; }
.ag-t { font-size: 13px; font-weight: 600; margin-top: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ag-s { font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top-artists .item { padding: 8px 0; }
.top-artists .bar { margin-top: 6px; height: 4px; }

.captcha { min-height: 65px; display: flex; justify-content: center; }
.captcha:empty { display: none; }

/* ---------- swipe between sections ---------- */
#view { touch-action: pan-y pinch-zoom; overflow-x: clip; }
.view.in-right { animation: in-right .24s cubic-bezier(.2, .7, .2, 1); }
.view.in-left { animation: in-left .24s cubic-bezier(.2, .7, .2, 1); }
@keyframes in-right { from { transform: translateX(100%); } }
@keyframes in-left { from { transform: translateX(-100%); } }
