[hidden] { display: none !important; }
/* Manga Yugen — single stylesheet. Dark by default; html.light switches theme. */
:root {
  --bg: #0b0b0e;
  --bg2: #121216;
  --card: #15151a;
  --card2: #1c1c22;
  --line: #26262e;
  --text: #f3f0ea;
  --muted: #9b9aa6;
  --accent: #ff8202;
  --on-accent: #1a0e00;
  --accent-soft: rgba(255, 130, 2, 0.14);
  --gold: #f6b93b;
  --blue: #38a9f5;
  --ok: #22c55e;
  --danger: #ef4444;
  --r: 14px;
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  --head: 64px;
  color-scheme: dark;
}
html.light {
  --bg: #faf8f5;
  --bg2: #f1eee9;
  --card: #ffffff;
  --card2: #f5f2ee;
  --line: #e4dfd8;
  --text: #17161b;
  --muted: #6b6975;
  --accent: #e26f00;
  --on-accent: #fff;
  --accent-soft: rgba(226, 111, 0, 0.1);
  --shadow: 0 10px 30px rgba(30, 20, 10, 0.1);
  color-scheme: light;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 80px; }
body { margin: 0; background: var(--bg); color: var(--text); font: 15px/1.55 "Plus Jakarta Sans", system-ui, sans-serif; -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--accent); }
img { max-width: 100%; display: block; }
h1, h2, h3, h4 { line-height: 1.2; letter-spacing: -0.02em; margin: 0 0 0.4em; text-wrap: balance; }
h1 { font-size: clamp(26px, 4vw, 34px); font-weight: 800; }
h2 { font-size: 20px; font-weight: 800; margin-top: 1.4em; }
h3 { font-size: 17px; font-weight: 700; }
h4 { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); }
p { margin: 0 0 0.8em; }
code { background: var(--card2); border-radius: 6px; padding: 1px 6px; font-size: 0.9em; }
::selection { background: rgba(255, 130, 2, 0.35); }
input, textarea, select, button { font: inherit; color: inherit; }
input, textarea, select {
  width: 100%; background: var(--bg2); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; outline: none; transition: border-color 0.15s, box-shadow 0.15s;
}
input:focus, textarea:focus, select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
textarea { resize: vertical; }
input[type="checkbox"], input[type="radio"] { width: auto; accent-color: var(--accent); }
input[type="color"] { height: 42px; padding: 4px; width: 80px; }
input[type="range"] { padding: 0; accent-color: var(--accent); }
.i { width: 18px; height: 18px; flex-shrink: 0; vertical-align: -3px; }
.i.fill { fill: currentColor; }
.i.accent, .accent { color: var(--accent); }
.accent-2 { color: var(--blue); font-weight: 700; font-size: 12px; text-transform: uppercase; letter-spacing: 0.06em; }
.only-light { display: none; }
html.light .only-light { display: inline; }
html.light .only-dark { display: none; }
.muted { color: var(--muted); }
.sm { font-size: 12.5px; }
.lead { font-size: 16px; margin-top: -4px; }
.center { text-align: center; }
.pad { padding: 18px; }
.hp { position: absolute; left: -9999px; }
.wrap { max-width: 1360px; margin: 0 auto; padding: 0 20px; }
.page { padding-top: 28px; padding-bottom: 40px; }
.narrow { max-width: 820px; }
.stack > * + * { margin-top: 44px; }
.show-sm { display: none !important; }

/* ---------- buttons & bits ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: 10px; border: 1px solid transparent;
  background: var(--accent); color: var(--on-accent); font-weight: 700; font-size: 14px; cursor: pointer; white-space: nowrap; transition: transform 0.1s, filter 0.15s, background 0.15s;
}
.btn:hover { color: #fff; filter: brightness(1.08); }
.btn:active { transform: scale(0.98); }
.btn:disabled, .btn.disabled { opacity: 0.5; pointer-events: none; }
.btn-sm { height: 32px; padding: 0 12px; font-size: 13px; border-radius: 8px; }
.btn-lg { height: 46px; padding: 0 20px; font-size: 15px; }
.btn-block { width: 100%; }
.btn-ghost { background: transparent; border-color: var(--line); color: var(--text); }
.btn-ghost:hover { background: var(--card2); color: var(--text); }
.btn-soft { background: var(--accent-soft); color: var(--accent); }
.btn-soft:hover { color: var(--accent); }
.btn-icon { width: 40px; padding: 0; }
.btn.danger, .btn-ghost.danger { background: transparent; border-color: rgba(239, 68, 68, 0.4); color: var(--danger); }
.btn.danger:hover { background: rgba(239, 68, 68, 0.1); color: var(--danger); }
.btns { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.btns.center { justify-content: center; }
.icon-btn {
  position: relative; display: inline-flex; align-items: center; justify-content: center; width: 38px; height: 38px; border-radius: 10px; border: 0; background: transparent; color: var(--text); cursor: pointer;
}
.icon-btn:hover { background: var(--card2); color: var(--text); }
.icon-btn.disabled { opacity: 0.3; pointer-events: none; }
.icon-btn.danger { color: var(--danger); }
.dot { position: absolute; top: 3px; right: 2px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 99px; background: var(--accent); color: var(--on-accent); font-size: 10px; font-weight: 800; line-height: 16px; text-align: center; }
.link-btn { background: none; border: 0; padding: 0; cursor: pointer; color: var(--muted); font-size: 13px; font-weight: 600; display: inline-flex; gap: 5px; align-items: center; }
.link-btn:hover { color: var(--text); }
.link-btn.danger:hover { color: var(--danger); }
.link-btn.accent { color: var(--accent); margin-top: 4px; }
.chips { display: flex; flex-wrap: wrap; gap: 7px; margin: 12px 0; }
.chip { display: inline-flex; align-items: center; padding: 4px 11px; border-radius: 99px; border: 1px solid var(--line); background: color-mix(in srgb, var(--card) 60%, transparent); font-size: 12.5px; font-weight: 600; }
.chip:hover { border-color: var(--accent); }
.chip-opt { position: relative; display: inline-flex; cursor: pointer; margin: 0 6px 7px 0; }
.chip-opt input { position: absolute; opacity: 0; pointer-events: none; }
.chip-opt span { padding: 5px 12px; border-radius: 99px; border: 1px solid var(--line); font-size: 13px; font-weight: 600; transition: all 0.15s; }
.chip-opt span i { font-style: normal; opacity: 0.55; font-size: 11px; }
.chip-opt input:checked + span { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.chip-opt input:focus-visible + span { box-shadow: 0 0 0 3px var(--accent-soft); }
.pill { display: inline-flex; align-items: center; gap: 5px; padding: 4px 10px; border-radius: 99px; font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.06em; }
.pill .i { width: 13px; height: 13px; }
.pill-accent { background: var(--accent-soft); color: var(--accent); }
.pills { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin: 14px 0 18px; }
.pills a { padding: 7px 14px; border-radius: 99px; background: var(--card); border: 1px solid var(--line); font-size: 13.5px; font-weight: 600; white-space: nowrap; display: inline-flex; gap: 6px; align-items: center; }
.pills a.on { background: var(--text); color: var(--bg); border-color: var(--text); }
.pills a i { font-style: normal; opacity: 0.6; font-size: 12px; }
.pills a i.hot { opacity: 1; background: var(--accent); color: var(--on-accent); border-radius: 99px; padding: 0 6px; }
.kind { display: inline-flex; align-items: center; padding: 2px 7px; border-radius: 6px; font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em; background: rgba(0, 0, 0, 0.65); color: #fff; }
.kind-novel { background: #1d8fe0; }
.status { font-size: 12px; font-weight: 700; text-transform: capitalize; color: var(--muted); }
.status-ongoing { color: var(--ok); }
.status::before { content: "● "; }
.rating { display: inline-flex; align-items: center; gap: 4px; font-weight: 700; }
.rating .i { color: var(--gold); width: 15px; height: 15px; }
.badge { display: inline-flex; align-items: center; gap: 3px; margin-left: 6px; padding: 1px 6px; border-radius: 5px; font-size: 10.5px; font-weight: 800; letter-spacing: 0.03em; vertical-align: 1px; }
.badge-author { background: linear-gradient(135deg, #f6b93b, #ff8202); color: #fff; }
.badge-team { background: var(--accent-soft); color: var(--accent); }
.badge-mod { background: rgba(56, 169, 245, 0.15); color: var(--blue); }
.tag { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 6px; background: var(--card2); font-size: 11.5px; font-weight: 600; }
.tag .i { width: 13px; height: 13px; }
.tag-pin { color: var(--accent); background: var(--accent-soft); }
.tag-spoiler { color: var(--danger); background: rgba(239, 68, 68, 0.12); }
.st { display: inline-block; padding: 1px 8px; border-radius: 99px; font-size: 11px; font-weight: 700; background: var(--card2); }
.st-live { background: rgba(34, 197, 94, 0.14); color: var(--ok); }
.st-pending { background: rgba(246, 185, 59, 0.16); color: var(--gold); }
.st-rejected { background: rgba(239, 68, 68, 0.14); color: var(--danger); }
.notice { padding: 12px 16px; border-radius: 12px; background: var(--card); border: 1px solid var(--line); margin: 0 0 18px; display: flex; gap: 8px; align-items: flex-start; }
.notice.ok { border-color: rgba(34, 197, 94, 0.4); background: rgba(34, 197, 94, 0.07); }
.notice.danger { border-color: rgba(239, 68, 68, 0.4); background: rgba(239, 68, 68, 0.07); }
.notice.sm { padding: 6px 10px; margin: 6px 0 0; font-size: 13px; }
.empty-box { display: block; padding: 40px 20px; text-align: center; border: 1.5px dashed var(--line); border-radius: var(--r); color: var(--muted); font-size: 15px; line-height: 1.8; }
.empty-box b { color: var(--text); }
.empty-box .btn { margin-top: 12px; }
.empty-box.big { padding: 60px 20px; }
.empty-box .i { width: 30px; height: 30px; }
.form-error { color: var(--danger); font-size: 13px; margin: 4px 0; min-height: 0; }
.form-error:empty { display: none; }
.hint { font-size: 11.5px; color: var(--muted); }
.label { display: block; font-weight: 600; font-size: 13.5px; margin-bottom: 6px; }
.chk { display: inline-flex !important; align-items: center; gap: 8px; cursor: pointer; font-size: 13.5px; }
.big-ico .i { width: 46px; height: 46px; color: var(--accent); margin: 0 auto 10px; }
.error-page { padding: 80px 20px; }
.big-num { font-size: 90px; font-weight: 900; color: var(--accent); line-height: 1; }
.toast { position: fixed; left: 50%; bottom: 90px; transform: translateX(-50%); z-index: 100; padding: 11px 18px; border-radius: 12px; background: var(--text); color: var(--bg); font-weight: 600; font-size: 14px; box-shadow: var(--shadow); max-width: calc(100% - 32px); }
.toast.bad { background: var(--danger); color: #fff; }
.spoiler { background: var(--text); color: transparent; border-radius: 4px; cursor: pointer; padding: 0 3px; transition: all 0.2s; }
.spoiler.open { background: var(--card2); color: inherit; }
.spoiler-block { margin: 8px 0; }
.spoiler-block summary { cursor: pointer; padding: 10px 14px; border: 1.5px dashed var(--line); border-radius: 10px; color: var(--muted); list-style: none; }
.spoiler-block[open] summary { margin-bottom: 10px; }
.md p:last-child { margin-bottom: 0; }
.md blockquote { margin: 0 0 0.8em; padding-left: 12px; border-left: 3px solid var(--accent); color: var(--muted); }
.md ul, .md ol { margin: 0 0 0.8em; padding-left: 22px; }
.md a { color: var(--accent); }
.md .mention { font-weight: 700; }
.clamp { display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.quote { padding: 10px 14px; background: var(--bg2); border-radius: 10px; font-size: 14px; }
.flags { list-style: none; padding: 0; margin: 8px 0; }
.flags li { display: flex; gap: 6px; color: var(--gold); font-size: 13px; font-weight: 600; margin-bottom: 3px; }
.ok-text { color: var(--ok); font-size: 13px; font-weight: 600; display: flex; gap: 6px; }

/* ---------- header ---------- */
.top { position: sticky; top: 0; z-index: 50; height: var(--head); background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: blur(16px); border-bottom: 1px solid var(--line); }
.top-in { display: flex; align-items: center; gap: 14px; height: 100%; }
.logo { display: inline-flex; align-items: center; gap: 9px; font-weight: 800; font-size: 18px; letter-spacing: -0.02em; }
.logo:hover { color: var(--text); }
.logo-mark { width: 36px; height: 36px; flex: none; }
.main-nav { display: flex; gap: 2px; margin-left: 10px; }
.main-nav a { padding: 8px 12px; border-radius: 9px; color: var(--muted); font-weight: 600; font-size: 14.5px; }
.main-nav a:hover { color: var(--text); background: var(--card2); }
.main-nav a.on { color: var(--text); box-shadow: inset 0 -2px 0 var(--accent); border-radius: 9px 9px 0 0; }
.search { flex: 1; max-width: 360px; margin-left: auto; position: relative; }
.search .i { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); color: var(--muted); }
.search input { padding-left: 36px; height: 38px; background: var(--card); }
.top-actions { display: flex; align-items: center; gap: 4px; }
.search-mobile { display: none; }
.av { border-radius: 50%; object-fit: cover; display: inline-flex; align-items: center; justify-content: center; color: #fff; font-weight: 800; flex-shrink: 0; vertical-align: middle; }
details.menu { position: relative; }
details.menu > summary { list-style: none; cursor: pointer; display: flex; }
details.menu > summary::-webkit-details-marker { display: none; }
.menu-pop { position: absolute; right: 0; top: calc(100% + 8px); min-width: 220px; background: var(--card); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); padding: 6px; z-index: 60; }
.follow-menu .menu-pop { left: 0; right: auto; }
.menu-pop a, .menu-pop button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 10px; border-radius: 9px; font-size: 14px; font-weight: 600; background: none; border: 0; cursor: pointer; text-align: left; }
.menu-pop a:hover, .menu-pop button:hover { background: var(--card2); color: var(--text); }
.menu-pop .danger { color: var(--danger); }
.menu-head { padding: 8px 10px 10px; border-bottom: 1px solid var(--line); margin-bottom: 4px; display: flex; flex-direction: column; }

/* ---------- footer, tab bar, support ---------- */
.foot { margin-top: 60px; border-top: 1px solid var(--line); background: var(--bg2); }
.foot-grid { display: grid; grid-template-columns: 1.5fr repeat(3, 1fr); gap: 30px; padding-top: 36px; padding-bottom: 30px; }
.foot-grid a, .foot-grid .link-btn { display: block; margin: 7px 0; color: var(--muted); font-size: 14px; font-weight: 500; }
.foot-grid a:hover, .foot-grid .link-btn:hover { color: var(--text); }
.foot-grid .logo { display: inline-flex; color: var(--text); font-size: 18px; font-weight: 800; margin: 0 0 8px; }
.foot-grid .link-btn { display: inline-flex; }
.foot-bottom { border-top: 1px solid var(--line); padding-top: 16px; padding-bottom: 20px; font-size: 13px; }
.tabbar { display: none; }
.support-fab { position: fixed; right: 18px; bottom: 18px; z-index: 40; display: flex; align-items: center; gap: 7px; padding: 10px 15px; border-radius: 99px; border: 1px solid var(--line); background: var(--card); color: var(--text); font-weight: 700; font-size: 13.5px; cursor: pointer; box-shadow: var(--shadow); }
.support-fab:hover { border-color: var(--accent); }
.support { position: fixed; right: 18px; bottom: 18px; z-index: 70; width: min(380px, calc(100vw - 24px)); height: min(520px, calc(100dvh - 100px)); display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow); overflow: hidden; }
.support[hidden] { display: none; }
.support-head { display: flex; justify-content: space-between; align-items: center; padding: 10px 10px 10px 16px; border-bottom: 1px solid var(--line); }
.support-log { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 8px; }
.support-log.static { max-height: 460px; border: 1px solid var(--line); border-radius: 12px; margin-bottom: 10px; }
.support-hello { font-size: 14px; }
.msg { max-width: 85%; align-self: flex-start; }
.msg p { margin: 0; padding: 9px 12px; border-radius: 14px 14px 14px 4px; background: var(--card2); white-space: pre-wrap; font-size: 14px; }
.msg.mine { align-self: flex-end; text-align: right; }
.msg.mine p { background: var(--accent); color: var(--on-accent); border-radius: 14px 14px 4px 14px; text-align: left; }
.support-form { border-top: 1px solid var(--line); padding: 10px; display: grid; gap: 6px; }
.support-form input { padding: 7px 10px; font-size: 13px; }
.support-send { display: flex; gap: 8px; align-items: flex-end; }
.support-send textarea { min-height: 42px; }

/* ---------- home ---------- */
.hero { position: relative; overflow: hidden; min-height: 420px; }
.hero-slide { position: absolute; inset: 0; opacity: 0; transition: opacity 0.9s; pointer-events: none; }
.hero-slide.on { position: relative; opacity: 1; pointer-events: auto; }
.hero-bg { position: absolute; inset: -40px; width: calc(100% + 80px); height: calc(100% + 80px); max-width: none; object-fit: cover; filter: blur(40px) saturate(1.2); opacity: 0.38; }
.hero-slide::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, var(--bg) 10%, transparent 70%), linear-gradient(0deg, var(--bg), transparent 50%); }
.hero-in { position: relative; z-index: 1; display: flex; align-items: center; gap: 40px; padding-top: 50px; padding-bottom: 70px; }
.hero-text { flex: 1; max-width: 660px; }
.hero-tags { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 12px; }
.hero h1 { font-size: clamp(30px, 5vw, 52px); }
.hero-desc { color: var(--muted); font-size: 16.5px; max-width: 600px; }
.hero-poster img { width: 250px; aspect-ratio: 2/3; object-fit: cover; border-radius: 16px; transform: rotate(2deg); box-shadow: 0 30px 60px rgba(0, 0, 0, 0.5); transition: transform 0.3s; }
.hero-poster:hover img { transform: rotate(0); }
.hero-dots { position: absolute; left: 0; right: 0; bottom: 26px; z-index: 2; display: flex; gap: 7px; }
.hero-dots button { width: 16px; height: 6px; border-radius: 9px; border: 0; background: color-mix(in srgb, var(--text) 25%, transparent); cursor: pointer; transition: all 0.3s; padding: 0; }
.hero-dots button.on { width: 32px; background: var(--accent); }
.empty-lib { padding: 80px 20px; text-align: center; }
.sec-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 10px 14px; margin-bottom: 14px; }
.sec-head h2 { margin: 0; display: flex; gap: 8px; align-items: center; }
.sec-head p { margin: 2px 0 0; color: var(--muted); font-size: 14px; }
.see-all { display: inline-flex; align-items: center; gap: 2px; color: var(--muted); font-size: 14px; font-weight: 600; white-space: nowrap; }
.row { display: flex; gap: 16px; overflow-x: auto; padding-bottom: 6px; scroll-snap-type: x proximity; scrollbar-width: none; }
.row::-webkit-scrollbar { display: none; }
.row > * { scroll-snap-align: start; flex-shrink: 0; }
.card { display: block; width: 168px; }
.grid .card { width: auto; }
.poster { position: relative; aspect-ratio: 2/3; border-radius: 12px; overflow: hidden; background: var(--card2); box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2); }
.poster img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s; }
.poster > span:first-child { display: flex; height: 100%; align-items: center; justify-content: center; padding: 10px; text-align: center; font-weight: 700; color: var(--muted); }
.card:hover .poster img { transform: scale(1.05); }
.poster-tags { position: absolute; left: 8px; top: 8px; display: flex; gap: 4px; }
.card-rating { position: absolute; right: 8px; top: 8px; background: rgba(0, 0, 0, 0.6); color: #fff; padding: 1px 7px; border-radius: 6px; font-size: 11.5px; backdrop-filter: blur(4px); }
.card-ch { position: absolute; inset: auto 0 0; padding: 26px 9px 7px; background: linear-gradient(transparent, rgba(0, 0, 0, 0.85)); color: #fff; font-size: 11.5px; font-weight: 600; }
.card h3 { margin: 9px 2px 2px; font-size: 14px; font-weight: 700; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card:hover h3 { color: var(--accent); }
.card p { margin: 0 2px; font-size: 12.5px; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card p.reason .i { width: 12px; height: 12px; color: var(--accent); margin-right: 3px; vertical-align: -1px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 24px 16px; }
.grid-2 { grid-template-columns: 1fr 1fr; gap: 16px 12px; }
.resume { display: flex; gap: 12px; width: 320px; padding: 10px; border-radius: var(--r); background: var(--card); border: 1px solid var(--line); }
.resume:hover { border-color: var(--accent); color: var(--text); }
.resume img { width: 64px; aspect-ratio: 2/3; object-fit: cover; border-radius: 8px; }
.resume > div { display: flex; flex-direction: column; flex: 1; min-width: 0; gap: 2px; }
.resume b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.resume .muted { font-size: 12.5px; }
.resume .accent { font-size: 12.5px; font-weight: 700; display: flex; gap: 4px; align-items: center; margin-top: auto; }
.resume .accent .i { width: 12px; height: 12px; }
.bar { height: 5px; border-radius: 9px; background: var(--card2); overflow: hidden; margin: 6px 0 4px; }
.bar i { display: block; height: 100%; background: var(--accent); border-radius: 9px; transition: width 0.3s; }
.fresh { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 20px; }
.fresh a { display: flex; align-items: center; gap: 12px; padding: 8px; border-radius: 12px; }
.fresh a:hover { background: var(--card); color: var(--text); }
.fresh img, .fresh .ph { width: 42px; aspect-ratio: 2/3; object-fit: cover; border-radius: 6px; background: var(--card2); }
.fresh div { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.fresh b, .fresh div .muted { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 14px; }
.fresh div .muted { font-size: 13px; }
.cta { display: flex; justify-content: space-between; align-items: flex-end; gap: 30px; flex-wrap: wrap; padding: 36px; border-radius: 22px; border: 1px solid var(--line); background: radial-gradient(circle at 0 0, rgba(255, 130, 2, 0.22), transparent 55%), var(--card); }
.cta h2 { margin-top: 0; font-size: 26px; }
.cta > div:first-child { max-width: 560px; }
.cta-stats { display: flex; gap: 30px; }
.cta-stats div { display: flex; flex-direction: column; }
.cta-stats b { font-size: 28px; font-weight: 900; }
.cta-stats span { color: var(--muted); font-size: 13px; }
.split { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 30px; }
.list-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; }
.li { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.li:last-child { border-bottom: 0; }
a.li:hover { background: var(--card2); color: var(--text); }
.li > div { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.li b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.li .sm { display: inline-flex; align-items: center; gap: 4px; }
.li.unread { background: var(--accent-soft); }
.li.on { background: var(--card2); }
.li.dim { opacity: 0.5; }
.li-poster { width: 34px; aspect-ratio: 2/3; object-fit: cover; border-radius: 5px; }
.meme-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.meme-grid a { position: relative; aspect-ratio: 1; border-radius: 12px; overflow: hidden; background: var(--card2); }
.meme-grid img { width: 100%; height: 100%; object-fit: cover; }
.meme-grid span { position: absolute; inset: auto 0 0; padding: 20px 8px 6px; background: linear-gradient(transparent, rgba(0, 0, 0, 0.8)); color: #fff; font-size: 12px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---------- browse / updates / search ---------- */
.browse { display: grid; grid-template-columns: 250px 1fr; gap: 32px; margin-top: 20px; }
.filters { position: sticky; top: 84px; align-self: start; max-height: calc(100vh - 100px); overflow-y: auto; }
.f-group { margin-bottom: 20px; }
.f-group h4 { margin-bottom: 9px; }
.browse-bar { display: flex; gap: 10px; margin-bottom: 8px; }
.browse-bar select { width: 190px; }
.input-icon { position: relative; display: block; flex: 1; }
.input-icon .i { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); }
.input-icon input { padding-left: 38px; }
.big-search input { height: 52px; font-size: 17px; }
.big-search { margin-bottom: 20px; }
.day { position: sticky; top: var(--head); background: var(--bg); padding: 12px 0 8px; z-index: 2; font-size: 13px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); margin: 18px 0 6px; }
.upd { display: flex; gap: 14px; padding: 12px; background: var(--card); border: 1px solid var(--line); border-radius: var(--r); margin-bottom: 10px; }
.upd img { width: 64px; aspect-ratio: 2/3; object-fit: cover; border-radius: 8px; }
.upd-title { font-weight: 700; }
.upd .chips { margin: 8px 0 4px; }
.comm-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.comm-tile { display: flex; gap: 12px; padding: 14px; border-radius: var(--r); background: var(--card); border: 1px solid var(--line); transition: transform 0.15s, border-color 0.15s; }
.comm-tile:hover { border-color: var(--accent); transform: translateY(-2px); color: var(--text); }
.comm-tile > div { display: flex; flex-direction: column; min-width: 0; }
.comm-tile .muted { font-size: 13px; }
.comm-icon { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 12px; color: #fff; font-weight: 900; font-size: 18px; flex-shrink: 0; overflow: hidden; }
.comm-icon img { width: 100%; height: 100%; object-fit: cover; }
.comm-icon.sm { width: 24px; height: 24px; border-radius: 7px; font-size: 11px; }
.comm-icon.lg { width: 64px; height: 64px; font-size: 26px; border-radius: 16px; }
.comm-icon.xl { width: 84px; height: 84px; font-size: 34px; border-radius: 22px; border: 4px solid var(--bg); }
.people { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.people a { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 16px; background: var(--card); border: 1px solid var(--line); border-radius: var(--r); text-align: center; }

/* ---------- series ---------- */
.series-top { position: relative; overflow: hidden; }
.banner-bg { position: absolute; inset: -60px; width: calc(100% + 120px); height: calc(100% + 120px); max-width: none; object-fit: cover; filter: blur(50px); opacity: 0.3; }
.series-top::after { content: ""; position: absolute; inset: 0; background: linear-gradient(transparent, var(--bg)); }
.series-head { position: relative; z-index: 1; display: flex; gap: 32px; padding-top: 36px; padding-bottom: 30px; }
.series-poster { width: 230px; flex-shrink: 0; aspect-ratio: 2/3; border-radius: 16px; overflow: hidden; box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5); background: var(--card2); }
.series-poster img { width: 100%; height: 100%; object-fit: cover; }
.series-info { flex: 1; min-width: 0; }
.series-info h1 { font-size: clamp(28px, 4vw, 42px); }
.alt { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 13.5px; }
.stats { display: flex; flex-wrap: wrap; gap: 8px 22px; margin: 14px 0 4px; font-size: 14px; color: var(--muted); }
.stats > span { display: inline-flex; align-items: center; gap: 6px; }
.stats b { color: var(--text); }
.series-body { display: grid; grid-template-columns: 1fr 320px; gap: 40px; }
.desc { color: var(--muted); font-size: 15.5px; line-height: 1.7; }
.adapt { display: flex; align-items: center; gap: 14px; margin: 20px 0; padding: 12px; border-radius: var(--r); border: 1px solid var(--line); background: linear-gradient(90deg, rgba(56, 169, 245, 0.1), transparent); }
.adapt img { width: 46px; aspect-ratio: 2/3; object-fit: cover; border-radius: 6px; }
.adapt div { display: flex; flex-direction: column; }
.tabs { margin-top: 24px; }
.tab-bar { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 16px; }
.tab-bar button { background: none; border: 0; padding: 10px 16px; font-weight: 700; color: var(--muted); cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.tab-bar button.on { color: var(--text); border-color: var(--accent); }
.tab-bar i { font-style: normal; font-size: 12px; opacity: 0.6; }
.tab { display: none; }
.tab.on { display: block; }
.ch-tools { display: flex; gap: 10px; margin-bottom: 12px; }
.chapters { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; max-height: 720px; overflow-y: auto; }
.chapters a { display: flex; align-items: center; gap: 14px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.chapters a:last-child { border-bottom: 0; }
.chapters a:hover { background: var(--card2); color: var(--text); }
.chapters a > span:first-child { flex: 1; min-width: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; }
.chapters small { flex-basis: 100%; color: var(--muted); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chapters a.read b { color: var(--muted); font-weight: 600; }
.chapters a.current { background: var(--accent-soft); }
.chapters i.new, .chapters i.reading { font-style: normal; font-size: 10px; font-weight: 800; padding: 1px 6px; border-radius: 5px; background: var(--accent); color: var(--on-accent); }
.chapters i.reading { background: var(--accent-soft); color: var(--accent); }
.chapters .sm { display: inline-flex; gap: 4px; align-items: center; }
.chapters .i { width: 15px; height: 15px; }
.i.ok { color: var(--ok); }
.series-side h3 { display: flex; gap: 7px; align-items: center; }

/* ---------- reader ---------- */
body.reading { background: #08080a; }
html.light body.reading { background: var(--bg); }
/* reader top: header + chapter line; hidden while reading (body.ui-hidden), tap the page to bring it back */
.r-top { position: fixed; inset: 0 0 auto; z-index: 50; background: color-mix(in srgb, var(--bg) 90%, transparent); backdrop-filter: blur(16px); border-bottom: 1px solid var(--line); transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1); }
body.ui-hidden .r-top { transform: translateY(-100%); }
.r-head { height: 54px; display: flex; align-items: center; gap: 6px; padding: 0 10px; }
.r-title { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.25; }
.r-title a { font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.r-title span { font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.size-btn { gap: 6px; min-width: 76px; }
.size-btn span { font-variant-numeric: tabular-nums; }
.r-sub { position: relative; height: 44px; display: flex; align-items: center; justify-content: center; gap: 8px; padding: 0 10px; border-top: 1px solid var(--line); }
.r-sub select, .r-end-nav select { width: 170px; height: 34px; padding: 0 10px; }
.r-sub .btn { min-width: 112px; }
.r-sub .btn.disabled { opacity: 0.35; pointer-events: none; }
.r-progress { position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; }
.r-progress i { display: block; height: 100%; width: 0; background: var(--accent); }
.reader { padding-top: 99px; cursor: default; }
.pages { margin: 0 auto; width: var(--page-w, 50vw); max-width: 100%; }
.pages img { width: 100%; min-height: 200px; background: #111; user-select: none; }
.pages img[src] { min-height: 0; }
.novel { max-width: 720px; margin: 0 auto; padding: 50px 22px 30px; font: 19px/1.8 Literata, Georgia, serif; }
.novel.sans { font-family: "Plus Jakarta Sans", system-ui, sans-serif; }
.novel h1 { font-family: "Plus Jakarta Sans", system-ui, sans-serif; font-size: 1.55em; margin-bottom: 1.4em; }
.novel p { margin: 0 0 1.1em; }
.novel-kicker { font: 700 12px "Plus Jakarta Sans", sans-serif !important; text-transform: uppercase; letter-spacing: 0.18em; color: var(--muted); margin-bottom: 8px !important; }
body[data-paper="dark"] { background: #121214; --text: #e6e3dc; }
body[data-paper="sepia"] { background: #f4ecd8; --text: #4b3b2a; --muted: #85705a; --line: #e2d5b8; --bg: #f4ecd8; --card: #fbf5e6; --card2: #ece2c8; --bg2: #efe5cc; color-scheme: light; }
body[data-paper="light"] { background: #fff; --text: #1d1d1f; --muted: #6b6975; --line: #e4dfd8; --bg: #fff; --card: #fff; --card2: #f5f2ee; --bg2: #f6f4f0; color-scheme: light; }
.novel-settings { position: fixed; top: 108px; right: 12px; z-index: 55; width: 290px; padding: 16px; display: grid; gap: 14px; background: var(--card); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow); font-size: 13.5px; font-weight: 600; }
.novel-settings[hidden] { display: none; }
.seg { display: flex; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.seg button { flex: 1; padding: 8px 4px; border: 0; background: none; cursor: pointer; font-size: 13px; font-weight: 600; }
.seg button + button { border-left: 1px solid var(--line); }
.seg button.on { background: var(--accent); color: var(--on-accent); }
.seg .serif { font-family: Literata, serif; }
.r-end { max-width: 720px; margin: 0 auto; padding: 40px 20px 120px; display: flex; flex-direction: column; align-items: center; gap: 18px; text-align: center; }
.caps { text-transform: uppercase; letter-spacing: 0.14em; font-size: 12px; font-weight: 700; }
.next-card { width: 100%; display: flex; justify-content: space-between; align-items: center; padding: 20px 24px; border-radius: 18px; background: var(--accent); color: var(--on-accent); text-align: left; box-shadow: 0 14px 34px rgba(255, 130, 2, 0.3); transition: transform 0.15s; }
.next-card:hover { color: #fff; transform: translateY(-2px); }
.next-card span { opacity: 0.85; font-size: 13px; display: block; }
.next-card b { font-size: 21px; }
.next-card .i { width: 30px; height: 30px; }
.caught-up { width: 100%; padding: 26px; border-radius: 18px; border: 1px solid var(--line); background: var(--card); display: flex; flex-direction: column; gap: 6px; align-items: center; font-size: 28px; }
.caught-up b { font-size: 17px; }
.caught-up span { font-size: 14px; }
.r-end-nav { display: flex; gap: 8px; align-items: center; }
/* bottom bar: compact strip (rating + comment count) whenever the reading chrome is shown;
   tapping it expands rating, reactions and comments */
.r-bar { --peek: 56px; position: fixed; inset: auto 0 0; z-index: 45; max-height: min(74vh, 700px); display: flex; flex-direction: column; background: var(--card); border-top: 1px solid var(--line); border-radius: 20px 20px 0 0; box-shadow: 0 -14px 36px rgba(0, 0, 0, 0.3); transform: translateY(calc(100% - var(--peek) - env(safe-area-inset-bottom))); transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1); }
body.ui-hidden:not(.bar-full) .r-bar { transform: translateY(100%); }
body.bar-full .r-bar { transform: none; }
.r-peek { flex: none; height: var(--peek); width: 100%; max-width: 900px; margin: 0 auto; display: flex; align-items: center; gap: 22px; padding: 0 20px; border: 0; background: none; color: var(--text); cursor: pointer; font-size: 14px; }
.peek-item { display: inline-flex; align-items: center; gap: 6px; }
.peek-item .i { width: 18px; height: 18px; color: var(--muted); }
.peek-item .i.fill { color: var(--gold); fill: var(--gold); }
.peek-more { margin-left: auto; display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 99px; background: var(--card2); }
.peek-more .chev { transition: transform 0.3s; }
body.bar-full .peek-more .chev { transform: rotate(180deg); }
.r-bar-in { flex: 1; overflow-y: auto; padding: 4px 20px 24px; max-width: 900px; margin: 0 auto; width: 100%; border-top: 1px solid var(--line); }
.r-rate { display: flex; flex-wrap: wrap; gap: 14px 40px; padding: 8px 0 16px; border-bottom: 1px solid var(--line); }
.r-rate h4 { margin-bottom: 8px; }
.stars-input { display: flex; align-items: center; gap: 2px; flex-wrap: wrap; }
.stars-input button { border: 0; background: none; padding: 2px; cursor: pointer; color: color-mix(in srgb, var(--muted) 45%, transparent); }
.stars-input button .i { width: 30px; height: 30px; }
.stars-input button.on { color: var(--gold); }
.stars-input button.on .i { fill: currentColor; }
.stars-input .muted { margin-left: 10px; font-size: 13px; }
.reactions { display: flex; flex-wrap: wrap; gap: 6px; }
.reactions button { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 99px; border: 1px solid var(--line); background: var(--bg2); font-size: 18px; cursor: pointer; transition: transform 0.12s; }
.reactions button:hover { transform: translateY(-2px); border-color: var(--accent); }
.reactions button.on { border-color: var(--accent); background: var(--accent-soft); }
.reactions b { font-size: 13px; color: var(--muted); }
.r-comments h4 { display: flex; align-items: center; gap: 7px; margin: 18px 0 12px; }

/* ---------- comments & votes ---------- */
.comments { margin-top: 18px; display: flex; flex-direction: column; gap: 18px; text-align: left; }
.comment { display: flex; gap: 11px; }
.c-main { flex: 1; min-width: 0; }
.c-head { font-size: 13.5px; display: flex; align-items: center; flex-wrap: wrap; gap: 0 4px; }
.ulink { font-weight: 700; }
.c-body { margin-top: 3px; font-size: 15px; overflow-wrap: anywhere; }
.c-actions { display: flex; align-items: center; gap: 14px; margin-top: 6px; }
.replies { margin-top: 12px; padding-left: 14px; border-left: 2px solid var(--line); display: flex; flex-direction: column; gap: 14px; }
.replies:empty { display: none; }
.comment-form { display: flex; gap: 11px; text-align: left; }
.cf-box { flex: 1; min-width: 0; border: 1px solid var(--line); border-radius: 14px; background: var(--bg2); overflow: hidden; }
.cf-box:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.cf-box textarea { border: 0; background: transparent; box-shadow: none !important; min-height: 46px; }
.cf-bar { display: flex; align-items: center; gap: 12px; padding: 6px 8px 6px 12px; border-top: 1px solid var(--line); }
.cf-bar .btn { margin-left: auto; }
.cf-box .form-error { padding: 0 12px 8px; }
.reply-to { font-size: 12.5px; }
.signin-cta { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border: 1.5px dashed var(--line); border-radius: 14px; color: var(--muted); text-align: left; }
.signin-cta b { color: var(--accent); }
.votes { display: inline-flex; flex-direction: column; align-items: center; gap: 0; padding: 4px 2px; border-radius: 99px; background: var(--card2); align-self: flex-start; }
.votes button { border: 0; background: none; cursor: pointer; color: var(--muted); padding: 3px; border-radius: 99px; display: flex; }
.votes button:hover { color: var(--accent); background: var(--accent-soft); }
.votes button.on { color: var(--accent); }
.votes button[data-v="-1"]:hover, .votes button[data-v="-1"].on { color: var(--blue); background: rgba(56, 169, 245, 0.12); }
.votes b { font-size: 13px; min-width: 22px; text-align: center; }
.votes-sm { flex-direction: row; padding: 0 2px; }
.votes-sm .i { width: 15px; height: 15px; }

/* ---------- community ---------- */
.with-side { display: grid; grid-template-columns: 1fr 300px; gap: 30px; align-items: start; }
.feed { min-width: 0; }
.feed-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.feed-head h1 { margin: 0; }
.side { position: sticky; top: 84px; display: flex; flex-direction: column; gap: 14px; }
.side-card { padding: 16px; border-radius: var(--r); background: var(--card); border: 1px solid var(--line); display: flex; flex-direction: column; gap: 8px; }
.side-card h4 { margin: 0 0 4px; }
.side-list a { display: flex; align-items: center; gap: 9px; padding: 6px 4px; border-radius: 8px; font-weight: 600; font-size: 14px; }
.side-list a:hover { background: var(--card2); color: var(--text); }
.posts { display: flex; flex-direction: column; gap: 10px; }
.tag-series { color: var(--blue); }
.back { display: inline-flex; align-items: center; gap: 3px; color: var(--muted); font-weight: 600; font-size: 14px; margin-bottom: 12px; }
.gallery { display: grid; gap: 6px; margin-top: 14px; border-radius: 14px; overflow: hidden; }
.gallery.g2 { grid-template-columns: 1fr 1fr; }
.gallery.g3 { grid-template-columns: 1fr 1fr 1fr; }
.gallery img { width: 100%; max-height: 640px; object-fit: contain; background: var(--card2); }
.gallery.g2 img, .gallery.g3 img { aspect-ratio: 1; object-fit: cover; }
.post-comments { margin-top: 28px; }
.post-comments h2 { margin-top: 0; }
.comm-banner { height: 150px; background: radial-gradient(120% 140% at 0% 0%, var(--cc), transparent 60%), radial-gradient(90% 120% at 100% 0%, color-mix(in srgb, var(--cc) 55%, #7c3aed), transparent 65%), var(--bg2); }
.comm-page { padding-top: 0; }
.comm-head { display: flex; align-items: flex-end; gap: 16px; margin-top: -32px; flex-wrap: wrap; }
.comm-head > div:nth-child(2) { flex: 1; min-width: 200px; }
.comm-head h1 { margin: 0; }
.comm-desc { margin: 14px 0 6px; max-width: 720px; }
.pager { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 22px; }
.prefix-input { display: flex; align-items: center; border: 1px solid var(--line); border-radius: 10px; background: var(--bg2); overflow: hidden; }
.prefix-input span { padding: 0 4px 0 12px; color: var(--muted); font-weight: 700; }
.prefix-input input { border: 0; background: transparent; box-shadow: none !important; padding-left: 2px; }
.opt { border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; }
.opt summary { cursor: pointer; font-weight: 600; display: flex; gap: 8px; align-items: center; list-style: none; }
.opt[open] summary { margin-bottom: 12px; }
.opt [data-poll] { display: grid; gap: 8px; }
.row-2 { display: grid; grid-template-columns: 2fr 1fr; gap: 12px; align-items: end; }
.row-2.rev { grid-template-columns: 1fr 2fr; }
.row-between { display: flex; justify-content: space-between; align-items: center; }
.dropzone { position: relative; display: flex; align-items: center; justify-content: center; gap: 12px; padding: 18px; border: 2px dashed var(--line); border-radius: 14px; color: var(--muted); cursor: pointer; text-align: center; transition: all 0.15s; }
.dropzone:hover, .dropzone.over { border-color: var(--accent); background: var(--accent-soft); }
.dropzone.big { padding: 34px 20px; flex-direction: column; gap: 8px; }
.dropzone.big > .i { width: 30px; height: 30px; }
.dropzone.busy { opacity: 0.6; pointer-events: none; }
.dropzone.has { border-style: solid; padding: 14px; }
.dropzone b { color: var(--text); }
.thumbs { display: flex; flex-wrap: wrap; gap: 8px; }
.thumbs:empty { display: none; }
.thumb { position: relative; }
.thumb img { width: 92px; height: 92px; object-fit: cover; border-radius: 10px; }
.thumb button { position: absolute; top: -6px; right: -6px; width: 22px; height: 22px; border-radius: 50%; border: 0; background: var(--text); color: var(--bg); cursor: pointer; font-weight: 800; line-height: 1; }

/* ---------- forms, auth, profile ---------- */
.card-form { display: flex; flex-direction: column; gap: 14px; padding: 22px; margin-bottom: 18px; border-radius: 18px; background: var(--card); border: 1px solid var(--line); }
.card-form.flat { padding: 0; border: 0; background: none; margin: 0; }
.card-form label { display: flex; flex-direction: column; gap: 6px; font-weight: 600; font-size: 13.5px; }
.card-form h3 { margin: 6px 0 -4px; }
.card-form > .btn { align-self: flex-start; }
.avatar-row { display: flex; align-items: center; gap: 16px; }
.swatches { display: flex; gap: 8px; flex-wrap: wrap; }
.swatches label { cursor: pointer; }
.swatches input { position: absolute; opacity: 0; }
.swatches span { display: block; width: 32px; height: 32px; border-radius: 50%; transition: transform 0.15s; }
.swatches input:checked + span { box-shadow: 0 0 0 3px var(--bg), 0 0 0 5px var(--text); }
.auth-wrap { min-height: calc(100vh - 220px); display: flex; align-items: center; justify-content: center; padding: 40px 16px; background: radial-gradient(circle at 50% 0, rgba(255, 130, 2, 0.15), transparent 60%); }
.auth-card { width: 100%; max-width: 420px; padding: 32px; border-radius: 22px; background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow); }
.auth-card .logo { margin-bottom: 16px; }
.auth-card form { display: flex; flex-direction: column; gap: 12px; margin: 18px 0; }
.auth-card label { display: flex; flex-direction: column; gap: 6px; font-weight: 600; font-size: 13.5px; }
.auth-card small { margin-top: -8px; }
.profile-banner { height: 150px; background: linear-gradient(120deg, var(--c), color-mix(in srgb, var(--c) 15%, var(--bg))); }
.profile { padding-top: 0; }
.profile-head { display: flex; align-items: flex-end; gap: 18px; margin-top: -52px; flex-wrap: wrap; }
.profile-head > div:nth-child(2) { flex: 1; min-width: 200px; padding-bottom: 4px; }
.profile-head h1 { margin: 0; }
.profile-av { position: relative; border-radius: 50%; border: 5px solid var(--bg); }
.online { position: absolute; right: 6px; bottom: 6px; width: 18px; height: 18px; border-radius: 50%; background: var(--ok); border: 3px solid var(--bg); }
.bio { margin: 16px 0 0; max-width: 680px; white-space: pre-line; }
.stat-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin: 20px 0; max-width: 680px; }
.stat-row div { padding: 14px; border-radius: var(--r); background: var(--card); border: 1px solid var(--line); display: flex; flex-direction: column; }
.stat-row b { font-size: 22px; font-weight: 900; }
.stat-row span { font-size: 12.5px; color: var(--muted); }

/* ---------- studio ---------- */
.studio-list { display: flex; flex-direction: column; gap: 10px; }
.studio-item { display: flex; align-items: center; gap: 16px; padding: 12px; border-radius: var(--r); background: var(--card); border: 1px solid var(--line); }
.studio-item > img, .studio-item .ph { width: 60px; aspect-ratio: 2/3; object-fit: cover; border-radius: 8px; background: var(--card2); }
.si-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.si-title { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.steps { display: flex; gap: 6px; list-style: none; padding: 0; margin: 10px 0 26px; counter-reset: s; }
.steps li { flex: 1; counter-increment: s; padding: 10px 0 0; border-top: 3px solid var(--line); color: var(--muted); font-weight: 700; font-size: 13px; }
.steps li::before { content: counter(s) ". "; }
.steps li.on { border-color: var(--accent); color: var(--text); }
.wstep { display: none; }
.wstep.on { display: block; animation: fadeUp 0.3s; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(8px); } }
.kind-pick { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.kind-pick button { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; padding: 26px; text-align: left; border-radius: 18px; border: 1.5px solid var(--line); background: var(--card); cursor: pointer; transition: all 0.15s; }
.kind-pick button:hover { border-color: var(--accent); transform: translateY(-2px); box-shadow: var(--shadow); }
.kind-pick .i { width: 34px; height: 34px; color: var(--accent); }
.kind-pick b { font-size: 17px; }
.details-grid { display: grid; grid-template-columns: 220px 1fr; gap: 26px; }
.poster-pick { aspect-ratio: 2/3; border-radius: 16px; border: 2px dashed var(--line); display: flex; align-items: center; justify-content: center; cursor: pointer; overflow: hidden; background: var(--card); transition: border-color 0.15s; align-self: start; }
.poster-pick:hover { border-color: var(--accent); }
.poster-pick.has { border-style: solid; }
.poster-pick img { width: 100%; height: 100%; object-fit: cover; }
.poster-ph { display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; padding: 14px; color: var(--muted); }
.poster-ph .i { width: 30px; height: 30px; }
.poster-ph b { color: var(--text); }
.wnav { display: flex; justify-content: space-between; gap: 10px; margin-top: 24px; }
.wizard.single .card-form.flat { margin-bottom: 0; }
.page-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 10px; margin-top: 14px; }
.page-item { position: relative; border-radius: 10px; overflow: hidden; background: var(--card2); border: 1px solid var(--line); cursor: grab; }
.page-item img { width: 100%; aspect-ratio: 3/4; object-fit: cover; object-position: top; }
.pi-num { position: absolute; left: 6px; top: 6px; background: rgba(0, 0, 0, 0.7); color: #fff; font-weight: 800; font-size: 12px; padding: 1px 7px; border-radius: 6px; }
.pi-name { display: block; padding: 4px 6px; font-size: 11px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pi-actions { position: absolute; right: 4px; top: 4px; display: flex; gap: 2px; opacity: 0; transition: opacity 0.15s; }
.page-item:hover .pi-actions { opacity: 1; }
.pi-actions button { width: 24px; height: 24px; border-radius: 6px; border: 0; background: rgba(0, 0, 0, 0.75); color: #fff; cursor: pointer; font-weight: 800; }
.upload-progress { margin: 16px 0 0; }
.upload-progress .bar { height: 8px; }
.review-sum { display: flex; gap: 18px; padding: 16px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); margin-bottom: 16px; }
.review-sum img { width: 110px; aspect-ratio: 2/3; object-fit: cover; border-radius: 10px; }
.review-sum h3 { margin: 6px 0 2px; }
.done { text-align: center; padding: 30px 10px; }
.done-ico { font-size: 54px; }
.poster-sm { width: 76px; aspect-ratio: 2/3; object-fit: cover; border-radius: 10px; background: var(--card2); }

/* ---------- admin ---------- */
.admin h1 { display: flex; gap: 10px; align-items: center; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 12px; margin-bottom: 20px; }
.stat-card { padding: 18px; border-radius: var(--r); background: var(--card); border: 1px solid var(--line); display: flex; flex-direction: column; }
.stat-card b { font-size: 28px; font-weight: 900; }
.stat-card span { color: var(--muted); font-size: 13px; }
a.stat-card:hover { border-color: var(--accent); color: var(--text); }
.review-card { display: flex; gap: 16px; padding: 16px; border-radius: var(--r); background: var(--card); border: 1px solid var(--line); margin-bottom: 10px; }
.rc-main { flex: 1; min-width: 0; }
.rc-actions { display: flex; flex-direction: column; gap: 8px; }
.table-wrap { overflow-x: auto; border-radius: var(--r); border: 1px solid var(--line); background: var(--card); }
.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th { text-align: left; padding: 10px 14px; font-size: 12px; text-transform: uppercase; letter-spacing: 0.05em; color: var(--muted); border-bottom: 1px solid var(--line); }
.table td { padding: 10px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table tr:last-child td { border-bottom: 0; }
.table tr.banned, .table tr.dim { opacity: 0.55; }
.table .actions { display: flex; flex-wrap: wrap; gap: 6px; justify-content: flex-end; }
.u-cell { display: flex; gap: 10px; align-items: center; }
.u-cell > div { display: flex; flex-direction: column; }
.inline-search { max-width: 420px; margin-bottom: 14px; }
.inline-form { display: flex; gap: 6px; }
.inline-form input { padding: 5px 9px; width: 130px; }
.support-grid { display: grid; grid-template-columns: 320px 1fr; gap: 18px; align-items: start; }
.support-admin .support-send textarea { min-height: 60px; }

/* ---------- responsive ---------- */
@media (max-width: 1100px) {
  .series-body, .with-side { grid-template-columns: 1fr; }
  .side { position: static; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 860px) {
  :root { --head: 58px; }
  .main-nav, .search, .hide-sm { display: none !important; }
  .show-sm { display: inline-flex !important; }
  .search-mobile { display: inline-flex; }
  .top-actions { margin-left: auto; }
  .logo-text { display: none; }
  .tabbar { position: fixed; inset: auto 0 0; z-index: 45; display: grid; grid-template-columns: repeat(5, 1fr); padding-bottom: env(safe-area-inset-bottom); background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(16px); border-top: 1px solid var(--line); }
  .tabbar a { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 0 7px; font-size: 10.5px; font-weight: 600; color: var(--muted); }
  .tabbar a.on { color: var(--accent); }
  .tabbar .i { width: 21px; height: 21px; }
  .support-fab { bottom: 76px; right: 12px; padding: 10px; }
  .support-fab span { display: none; }
  .support { bottom: 70px; right: 12px; }
  .toast { bottom: 140px; }
  .foot { padding-bottom: 70px; }
  .reading .support-fab { display: none; }
  .hero-poster { display: none; }
  .hero-in { padding-top: 30px; padding-bottom: 60px; }
  .hero { min-height: 0; }
  .card { width: 138px; }
  .grid { grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 20px 12px; }
  .fresh, .split, .browse, .details-grid, .support-grid { grid-template-columns: minmax(0, 1fr); }
  .browse { gap: 0; }
  .filters { display: none; position: static; max-height: none; padding: 16px; margin-bottom: 16px; border: 1px solid var(--line); border-radius: var(--r); background: var(--card); }
  .filters.open { display: block; }
  .browse-bar select { width: 140px; }
  .series-head { flex-direction: column; align-items: center; text-align: center; padding-top: 24px; }
  .series-poster { width: 180px; }
  .series-info .stats, .series-info .chips, .series-info .btns, .series-info .hero-tags { justify-content: center; }
  .cta { padding: 26px; }
  .post-card { padding: 12px; gap: 10px; }
  .post-card > .votes { display: none; }
  .post-full { flex-direction: column; padding: 16px; }
  .post-full > .votes { flex-direction: row; align-self: flex-start; order: 2; }
  .stat-row { grid-template-columns: 1fr 1fr; }
  .kind-pick { grid-template-columns: 1fr; }
  .details-grid .poster-pick { width: 180px; justify-self: center; }
  .review-card { flex-direction: column; }
  .rc-actions { flex-direction: row; flex-wrap: wrap; }
  .r-head { height: 50px; }
  .pages { width: 100%; }
  .r-sub .btn { min-width: 0; }
  .r-sub .btn span { display: none; }
  .r-sub select { flex: 1; max-width: 220px; }
  .reader { padding-top: 95px; }
  .stars-input button .i { width: 34px; height: 34px; }
  .row-2 { grid-template-columns: 1fr; }
  h2 { font-size: 18px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* Compact community previews and clear destinations. */
.cm-home { padding: 24px; border: 1px solid var(--line); border-radius: 20px; background: var(--bg2); }
.cm-home .sec-head { margin-bottom: 18px; }
.cm-preview-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.cm-preview { min-width: 0; display: flex; flex-direction: column; gap: 16px; padding: 16px; border: 1px solid var(--line); border-radius: 14px; background: var(--card); transition: border-color .15s, background .15s; }
.cm-preview:hover { color: var(--text); border-color: var(--cc, var(--accent)); background: var(--card2); }
.cm-preview-top { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; font-size: 11px; color: var(--muted); }
.cm-preview-top > span:not(.comm-icon) { min-width: 0; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cm-preview-top > i { font-style: normal; padding: 3px 6px; border-radius: 6px; background: var(--card2); color: var(--text); font-size: 10px; }
.cm-preview-content { display: flex; align-items: flex-start; gap: 10px; flex: 1; min-width: 0; }
.cm-preview-content > img { width: 72px; height: 88px; object-fit: cover; border-radius: 8px; flex: none; }
.cm-preview-content > span { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.cm-preview-content b { font-size: 14px; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cm-preview-content .muted { font-size: 12px; line-height: 1.6; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cm-preview-foot { display: flex; justify-content: space-between; align-items: center; gap: 8px; font-size: 10px; color: var(--muted); }
.cm-preview-foot > span:first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 45%; }
.cm-preview-foot > span:last-child { display: flex; align-items: center; gap: 4px; flex: none; }
.cm-preview-foot .i { width: 12px; height: 12px; }
.cm-preview-poll { border-top: 3px solid #a78bfa; }
.cm-preview-image { border-top: 3px solid #2dd4bf; }
.cm-preview-spoiler { border-top: 3px solid var(--muted); }
.cm-home-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 18px; }
.cm-home-actions > .btn:last-child { margin-left: auto; }
.community-nav { display: flex; flex-wrap: wrap; gap: 8px; padding-bottom: 20px; margin-bottom: 24px; border-bottom: 1px solid var(--line); }
.community-nav a { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 9px 14px; border: 1px solid var(--line); border-radius: 10px; font-size: 13px; font-weight: 700; background: var(--card); }
.community-nav a[aria-current="page"] { color: var(--accent); border-color: var(--accent); background: var(--accent-soft); }
.community-intro { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 24px; }
.community-intro h1 { margin-bottom: 6px; }
.community-intro p { max-width: 560px; margin: 0; }
.pc-type { font-size: 10px; padding: 3px 7px; border-radius: 6px; background: var(--card2); color: var(--muted); }
.pc-image .pc-type { color: #2dd4bf; }
.pc-poll .pc-type { color: #a78bfa; }
.pc-text.big { -webkit-line-clamp: 4; font-size: 16px; }
#creator { scroll-margin-top: 90px; }
#creator .chk { align-items: flex-start; white-space: normal; line-height: 1.7; }
#creator .chk input { flex: none; margin-top: 6px; width: 16px; height: 16px; }
.reader-image-error { margin: 12px auto; max-width: 640px; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 12px; padding: 16px; background: var(--card); color: var(--text); border: 1px solid var(--line); border-radius: 12px; }
.paged img[hidden] + .reader-image-error, .paged img:not(.on) + .reader-image-error { display: none; }
@media (max-width: 1100px) { .cm-preview-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) {
  .cm-home { padding: 16px; border-radius: 16px; }
  .cm-home .sec-head { flex-wrap: wrap; gap: 8px; }
  .cm-preview-grid { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .cm-preview { padding: 14px; gap: 12px; }
  .cm-preview-content > img { width: 64px; height: 72px; }
  .cm-home-actions { gap: 8px; }
  .cm-home-actions > .btn { flex: 1 1 100%; white-space: normal; text-align: center; margin: 0; }
  .community-nav { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .community-nav a { min-width: 0; padding: 10px 7px; font-size: 12px; white-space: normal; text-align: center; }
  .community-nav a:last-child:nth-child(odd) { grid-column: 1 / -1; }
  .pc-type { margin-left: auto; }
}
.badge .i { width: 11px; height: 11px; vertical-align: -1px; }

/* languages */
.lang { display: inline-flex; align-items: center; padding: 2px 6px; border-radius: 6px; font-size: 10px; font-weight: 800; letter-spacing: 0.06em; background: var(--accent); color: var(--on-accent); line-height: 1.4; }
.lang-btn { width: auto; padding: 0 10px; gap: 6px; font-size: 12px; }
.lang-menu .menu-pop a.on { background: var(--accent-soft); color: var(--accent); }
.lang-menu .menu-pop .muted { margin-left: auto; }
.lang-note { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.translations { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0 0; align-items: center; }
.translations a { display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px 5px 6px; border-radius: 99px; border: 1px solid var(--line); font-size: 13px; font-weight: 600; }
.translations a:hover { border-color: var(--accent); }

/* sign in with Google */
.btn-google { margin-top: 18px; background: #fff; color: #1f1f1f; border: 1px solid #dadce0; gap: 10px; }
.btn-google:hover { color: #1f1f1f; filter: brightness(0.97); }
.btn-google .i { width: 20px; height: 20px; }
.or { display: flex; align-items: center; gap: 12px; margin: 18px 0 0; color: var(--muted); font-size: 12.5px; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }

/* legal & info pages */
.legal-nav { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 18px; }
.legal-nav a { padding: 6px 12px; border-radius: 99px; border: 1px solid var(--line); font-size: 13px; font-weight: 600; color: var(--muted); }
.legal-nav a.on, .legal-nav a:hover { color: var(--accent); border-color: var(--accent); }
.legal h2 { font-size: 19px; margin: 28px 0 8px; }
.legal p, .legal li { line-height: 1.7; }
.legal ul { padding-left: 20px; }
.legal .card-form { margin-top: 20px; }
.foot-bottom { display: flex; align-items: center; gap: 12px 28px; flex-wrap: wrap; }
.foot-legal { display: flex; gap: 16px; flex-wrap: wrap; }
.foot-legal a { color: var(--muted); }
.foot-legal a:hover { color: var(--text); }
.report-link { display: inline-flex; align-items: center; gap: 6px; margin-top: 18px; }
.card-form .chk { flex-direction: row; align-items: flex-start; font-weight: 500; line-height: 1.5; }
.card-form .chk input { margin-top: 3px; flex: none; }

/* Manga / Novels switch */
.kind-switch { display: inline-flex; padding: 3px; border-radius: 99px; background: var(--card2); border: 1px solid var(--line); flex: none; }
.kind-switch a { padding: 6px 14px; border-radius: 99px; font-size: 13.5px; font-weight: 700; color: var(--muted); transition: background 0.15s, color 0.15s; }
.kind-switch a:hover { color: var(--text); }
.kind-switch a.on { background: var(--accent); color: var(--on-accent); }
@media (max-width: 860px) {
  .kind-switch { margin-left: auto; }
  .kind-switch a { padding: 5px 11px; font-size: 12.5px; }
  .top-in .logo-text { display: none; }
}
@media (max-width: 420px) {
  .top-in { gap: 8px; }
  .top-actions { gap: 0; }
  .kind-switch a { padding: 5px 9px; }
  .top-actions .btn-sm { padding-inline: 11px; }
}
@media (max-width: 374px) {
  .top-actions .btn-sm { display: none; } /* "Join free" — the bottom tab bar has Sign in */
}

/* ---------- simplified header ---------- */
.top-actions { margin-left: auto; }
.search-btn { display: inline-flex; align-items: center; gap: 8px; height: 38px; min-width: 220px; padding: 0 8px 0 12px; border-radius: 10px; border: 1px solid var(--line); background: var(--card); color: var(--muted); font: inherit; font-size: 14px; cursor: pointer; transition: border-color 0.15s; }
.search-btn:hover { border-color: color-mix(in srgb, var(--accent) 60%, var(--line)); color: var(--text); }
.search-btn kbd, .search-field kbd { margin-left: auto; padding: 1px 7px; border-radius: 6px; border: 1px solid var(--line); background: var(--card2); font: 600 11px/1.6 inherit; color: var(--muted); }
.guest-btn { border: 1px solid var(--line); }
.menu-pop hr { border: 0; border-top: 1px solid var(--line); margin: 6px 4px; }
.menu-pop a.on { color: var(--accent); background: var(--accent-soft); }
.menu-label { display: flex; align-items: center; gap: 8px; padding: 8px 10px 4px; font-size: 11.5px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); }
.menu-label .i { width: 14px; height: 14px; }
@media (max-width: 860px) {
  .search-btn { min-width: 0; width: 38px; padding: 0; justify-content: center; border-radius: 99px; }
  .search-btn span, .search-btn kbd { display: none; }
}

/* ---------- search overlay ---------- */
body.no-scroll { overflow: hidden; }
.search-ov { position: fixed; inset: 0; z-index: 90; background: rgba(5, 5, 8, 0.6); backdrop-filter: blur(6px); display: flex; justify-content: center; align-items: flex-start; padding: 9vh 16px 16px; }
.search-ov[hidden] { display: none; }
.search-box { width: 100%; max-width: 640px; max-height: 76vh; display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow); overflow: hidden; animation: pop-in 0.18s ease-out; }
@keyframes pop-in { from { opacity: 0; transform: translateY(-6px) scale(0.98); } }
.search-field { display: flex; align-items: center; gap: 10px; padding: 0 16px; border-bottom: 1px solid var(--line); }
.search-field .i { color: var(--accent); width: 20px; height: 20px; flex: none; }
.search-field input { border: 0; background: none; height: 58px; padding: 0; font-size: 17px; box-shadow: none !important; }
.search-results { overflow-y: auto; padding: 6px; }
.sr-head { padding: 8px 10px 4px; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; }
.sr-item { display: flex; align-items: center; gap: 12px; padding: 8px 10px; border-radius: 12px; }
.sr-item:hover, .sr-item.on { background: var(--card2); color: var(--text); }
.sr-item img, .sr-ph { width: 40px; height: 56px; object-fit: cover; border-radius: 6px; flex: none; background: var(--card2); }
.sr-main { display: flex; flex-direction: column; min-width: 0; }
.sr-main b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sr-main span { font-size: 13px; }
.sr-all { display: block; padding: 12px 10px; font-weight: 700; color: var(--accent); }
.sr-empty { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 30px 16px; text-align: center; }
.request-box { margin: 20px auto; max-width: 460px; padding: 30px; text-align: center; border: 1px dashed var(--line); border-radius: 18px; display: flex; flex-direction: column; align-items: center; gap: 8px; }
@media (max-width: 860px) {
  .search-ov { padding: 0; }
  .search-box { max-width: none; max-height: 100%; height: 100%; border-radius: 0; }
}
@media (max-width: 860px) { .top-actions { margin-left: 0; } }

/* ---------- page-by-page reading (manga) ---------- */
.mode-btn { gap: 6px; }
.page-count { min-width: 64px; text-align: center; font-size: 13px; font-weight: 700; color: var(--muted); font-variant-numeric: tabular-nums; }
body.paged .reader { padding-top: 0; }
body.paged .pages { width: 100%; max-width: none; height: 100vh; height: 100dvh; display: flex; align-items: center; justify-content: center; overflow: hidden; }
body.paged .pages img { display: none; width: auto; height: auto; max-width: min(100%, var(--page-w, 100%)); max-height: 100%; min-height: 0; object-fit: contain; background: none; }
body.paged .pages img.on { display: block; }
body.paged:not(.paged-end) .r-end, body.paged:not(.paged-end) #reader-end { display: none; }
body.paged.paged-end .pages { display: none; }
body.paged.paged-end .reader { padding-top: 99px; }
@media (max-width: 860px) {
  .mode-btn span { display: none; }
  body.paged .pages img { max-width: 100%; }
}

/* generated avatars & community icons */
.comm-icon { overflow: hidden; }
.comm-icon img { width: 100%; height: 100%; object-fit: cover; display: block; }
.av-picks { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.av-picks button { padding: 0; border: 2px solid transparent; border-radius: 99px; background: none; cursor: pointer; line-height: 0; transition: transform 0.12s; }
.av-picks button:hover { transform: scale(1.06); }
.av-picks button.on { border-color: var(--accent); }
.av-picks img { width: 52px; height: 52px; border-radius: 99px; }

/* ---------- levels ---------- */
.badge-lv { background: var(--card2); color: var(--muted); border: 1px solid var(--line); font-variant-numeric: tabular-nums; }
.badge-lv.lv-5, .badge-lv.lv-6, .badge-lv.lv-7, .badge-lv.lv-8, .badge-lv.lv-9 { color: var(--accent); border-color: color-mix(in srgb, var(--accent) 45%, transparent); }
.badge-lv.lv-10 { color: #1a1200; background: linear-gradient(135deg, #ffd166, #f6b93b); border-color: transparent; }
.av.frame-orange { box-shadow: 0 0 0 2px var(--bg), 0 0 0 4px var(--accent); }
.av.frame-gold { box-shadow: 0 0 0 2px var(--bg), 0 0 0 4px #f6b93b, 0 0 14px rgba(246, 185, 59, 0.55); }
.level-card { display: flex; gap: 18px; align-items: center; margin: 18px 0; padding: 16px 18px; border-radius: var(--r); border: 1px solid var(--line); background: var(--card); }
.lv-ring { width: 74px; height: 74px; flex: none; border-radius: 99px; display: flex; flex-direction: column; align-items: center; justify-content: center; background: conic-gradient(var(--accent), #ff3d68, var(--accent)); color: #fff; box-shadow: inset 0 0 0 5px rgba(0, 0, 0, 0.25); }
.lv-ring b { font-size: 26px; line-height: 1; }
.lv-ring span { font-size: 10px; text-transform: uppercase; letter-spacing: 0.1em; opacity: 0.85; }
.lv-ring.lv-10 { background: conic-gradient(#ffd166, #f6b93b, #ffd166); color: #1a1200; }
.lv-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.lv-top { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.lv-top b { font-size: 17px; }
.lv-streak { font-size: 13px; font-weight: 700; color: var(--accent); }
.lv-perks { display: flex; flex-wrap: wrap; gap: 6px; }
.lv-perks span { font-size: 12px; padding: 3px 9px; border-radius: 99px; border: 1px dashed var(--line); color: var(--muted); }
.lv-perks span.on { border-style: solid; border-color: color-mix(in srgb, var(--ok) 50%, transparent); color: var(--ok); }

/* ---------- landing pages & blog ---------- */
.breadcrumbs { font-size: 13px; color: var(--muted); margin-bottom: 10px; }
.breadcrumbs a { color: var(--muted); }
.landing .lead { font-size: 18px; }
.landing-text { max-width: 760px; margin: 10px 0 16px; line-height: 1.7; }
.landing h2 { margin: 28px 0 12px; display: flex; align-items: center; gap: 8px; }
.landing-more { margin-top: 30px; }
.blog-list { display: flex; flex-direction: column; gap: 14px; margin-top: 18px; }
.blog-card { display: flex; gap: 16px; padding: 14px; border-radius: var(--r); border: 1px solid var(--line); background: var(--card); transition: border-color 0.15s; }
.blog-card:hover { border-color: var(--accent); color: var(--text); }
.blog-card img { width: 96px; aspect-ratio: 2/3; object-fit: cover; border-radius: 10px; flex: none; }
.blog-card h2 { font-size: 19px; margin: 4px 0 6px; }
.blog-article h1 { font-size: clamp(26px, 4vw, 38px); line-height: 1.15; margin: 6px 0 12px; }
.blog-article .md { font-size: 16.5px; line-height: 1.75; }
.blog-article .md h3 { font-size: 21px; margin: 28px 0 8px; }
.blog-cover { width: 100%; max-height: 380px; object-fit: cover; border-radius: 16px; margin: 10px 0 20px; }
.blog-more { padding-left: 18px; line-height: 1.9; }
.table-wrap { overflow-x: auto; margin: 14px 0; }
.md table { border-collapse: collapse; width: 100%; font-size: 14.5px; }
.md th, .md td { padding: 9px 12px; border: 1px solid var(--line); text-align: left; }
.md th { background: var(--card2); }
.md hr { border: 0; border-top: 1px solid var(--line); margin: 24px 0; }
.blog-admin textarea[name="body"] { font-family: ui-monospace, monospace; font-size: 13.5px; }
@media (max-width: 860px) { .level-card { align-items: flex-start; } .blog-card img { width: 70px; } }
.origin-note { font-size: 12.5px; font-weight: 600; color: var(--muted); align-self: center; }
.page-hint { position: fixed; left: 50%; top: 50%; transform: translate(-50%, -50%); z-index: 70; width: min(340px, calc(100vw - 40px)); padding: 18px 20px; border-radius: 18px; background: color-mix(in srgb, var(--card) 94%, transparent); backdrop-filter: blur(10px); border: 1px solid var(--line); box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 6px; text-align: center; font-size: 14px; animation: pop-in 0.25s ease-out; cursor: pointer; transition: opacity 0.3s; }
.page-hint b { font-size: 16px; color: var(--accent); }
.page-hint .muted { font-size: 12.5px; }
.page-hint.out { opacity: 0; }

/* ---------- Continue reading: remove button ---------- */
.resume-wrap { position: relative; flex: none; transition: opacity 0.2s, transform 0.2s; }
.resume-wrap.gone { opacity: 0; transform: scale(0.96); }
.resume-x { position: absolute; top: 6px; right: 6px; width: 26px; height: 26px; border-radius: 99px; border: 1px solid var(--line); background: var(--card2); color: var(--muted); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; opacity: 0; transition: opacity 0.15s, color 0.15s; }
.resume-x .i { width: 14px; height: 14px; }
.resume-wrap:hover .resume-x, .resume-x:focus-visible { opacity: 1; }
.resume-x:hover { color: var(--danger); border-color: var(--danger); }
@media (hover: none) { .resume-x { opacity: 1; } }

/* ---------- hover card ---------- */
/* series cards: info panel on hover (desktop) — the card itself turns into it, like Crunchyroll */
.card { position: relative; }
.card-link, .card-t { display: block; color: inherit; }
.card-meta { display: flex; align-items: flex-start; gap: 2px; }
.card-t { flex: 1; min-width: 0; }
.card-save { display: none; flex: none; padding: 0; border: 0; background: none; box-shadow: none; width: 34px; height: 34px; margin: 4px -4px 0 0; border-radius: 10px; align-items: center; justify-content: center; color: var(--muted); }
.card-save .i { width: 18px; height: 18px; }
.card-save.on { color: var(--accent); }
.card-save.on .i { fill: currentColor; }
@media (hover: none) { .card-save { display: inline-flex; } }
.card-ov { position: absolute; inset: -4px; z-index: 3; display: flex; flex-direction: column; padding: 13px 12px 11px; border-radius: 14px; color: #fff; pointer-events: none; }
/* the dark wash fades in first, then the text rises in a beat later — feels like the poster dims */
.card-ov::before { content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; background: linear-gradient(180deg, rgba(14, 14, 20, 0.94), rgba(8, 8, 12, 0.98)); box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.09) inset, 0 16px 40px rgba(0, 0, 0, 0.45); opacity: 0; transition: opacity 0.22s cubic-bezier(0.2, 0.8, 0.2, 1); }
.card-ov > * { opacity: 0; transform: translateY(6px); transition: opacity 0.2s ease-out, transform 0.24s cubic-bezier(0.2, 0.8, 0.2, 1); }
.card.ov-on .card-ov { pointer-events: auto; }
.card.ov-on .card-ov::before { opacity: 1; }
.card.ov-on .card-ov > * { opacity: 1; transform: none; transition-delay: 0.07s; }
@media (prefers-reduced-motion: reduce) { .card-ov > * { transform: none; } }
.ov-body { flex: 1; min-height: 0; display: flex; flex-direction: column; gap: 5px; overflow: hidden; color: #fff !important; }
.ov-title { font-size: 14.5px; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.ov-meta { display: flex; flex-wrap: wrap; gap: 3px 9px; font-size: 12px; font-weight: 700; color: rgba(255, 255, 255, 0.78); }
.ov-rating { display: inline-flex; align-items: center; gap: 3px; color: #ffc53d; }
.ov-rating .i { width: 12px; height: 12px; }
.ov-rating i { font-style: normal; font-weight: 600; color: rgba(255, 255, 255, 0.55); }
.ov-status { text-transform: capitalize; }
.ov-ongoing { color: #4ade80; }
.ov-origin { font-size: 11.5px; font-weight: 600; color: rgba(255, 255, 255, 0.6); }
.ov-body > * { flex: none; }
.ov-body > .ov-desc { flex: 1 1 auto; min-height: 0; overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: var(--lines, 6); }
.ov-desc { margin-top: 3px; font-size: 12.5px; line-height: 1.5; color: rgba(255, 255, 255, 0.88); }
.ov-actions { display: flex; gap: 6px; padding-top: 8px; }
.ov-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 34px; min-width: 34px; padding: 0 10px; border-radius: 10px; font-size: 13px; font-weight: 800; color: #fff; background: rgba(255, 255, 255, 0.12); transition: background 0.15s, color 0.15s; }
.ov-btn:hover { background: rgba(255, 255, 255, 0.2); color: #fff; }
.ov-btn .i { width: 16px; height: 16px; }
.ov-play { flex: 1; background: var(--accent); color: var(--on-accent); }
.ov-play:hover { background: color-mix(in srgb, var(--accent) 85%, #fff); color: var(--on-accent); }
.ov-list.on { color: var(--accent); }
.saver-btn.on { color: var(--ok); background: color-mix(in srgb, var(--ok) 16%, transparent); }
.resume-wrap .resume { padding-right: 34px; }
.sr-aka { font-size: 12.5px; color: var(--accent); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* =====================================================================
   Community redesign — colour comes from each community (--cc), orange stays for the main action
   ===================================================================== */
:root { --violet: #8b5cf6; --pink: #ec4899; --teal: #14b8a6; --sky: #38bdf8; --cc: var(--accent); }
.feed-head { margin-bottom: 4px; }
.feed-head p { margin: 4px 0 0; }

/* community chips under the title */
.comm-chips { display: flex; gap: 8px; overflow-x: auto; padding: 12px 0 14px; scrollbar-width: none; scroll-snap-type: x proximity; }
.comm-chips::-webkit-scrollbar { display: none; }
.comm-chips a { flex: none; display: inline-flex; align-items: center; gap: 7px; padding: 6px 13px 6px 6px; border-radius: 99px; font-size: 13.5px; font-weight: 700; background: color-mix(in srgb, var(--cc) 14%, var(--card)); border: 1px solid color-mix(in srgb, var(--cc) 35%, transparent); scroll-snap-align: start; transition: transform 0.12s, background 0.15s; }
.comm-chips a:hover { transform: translateY(-1px); background: color-mix(in srgb, var(--cc) 24%, var(--card)); color: var(--text); }
.comm-chips a.more { padding-left: 12px; background: var(--card); border-color: var(--line); color: var(--muted); }
.comm-icon.xs { width: 20px; height: 20px; border-radius: 6px; }

/* segmented sort tabs */
.seg-tabs { display: flex; gap: 4px; padding: 4px; margin: 14px 0 12px; border-radius: 14px; background: var(--card); border: 1px solid var(--line); width: max-content; max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.seg-tabs a { display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 10px; font-size: 14px; font-weight: 700; color: var(--muted); white-space: nowrap; }
.seg-tabs a .i { width: 16px; height: 16px; }
.seg-tabs a:hover { color: var(--text); background: var(--card2); }
.seg-tabs a.on { color: var(--text); background: var(--card2); box-shadow: inset 0 -2px 0 var(--accent); }

/* ---------- quick composer ---------- */
.composer { position: relative; padding: 14px 16px; border-radius: 18px; background: var(--card); border: 1px solid var(--line); transition: border-color 0.15s, box-shadow 0.15s; }
.composer:focus-within, .composer.open { border-color: color-mix(in srgb, var(--accent) 45%, var(--line)); box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25); }
.composer.drag { border-style: dashed; border-color: var(--accent); }
.composer.busy::after { content: "Uploading…"; position: absolute; right: 16px; top: 14px; font-size: 12px; color: var(--muted); }
.cmp-main { display: flex; gap: 12px; align-items: flex-start; }
.cmp-main > .av { flex: none; margin-top: 2px; }
.cmp-fields { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.cmp-fields input, .cmp-fields textarea { border: 0; background: none; padding: 8px 0; box-shadow: none !important; resize: none; }
.cmp-fields textarea { font-size: 16px; line-height: 1.5; min-height: 44px; }
.cmp-title { font-size: 17px; font-weight: 800; display: none; }
.composer.open .cmp-title { display: block; }
.cmp-more { display: none; flex-direction: column; gap: 12px; padding-top: 10px; margin-top: 6px; border-top: 1px solid var(--line); }
.composer.open .cmp-more { display: flex; }
.cmp-label { display: flex; align-items: center; gap: 6px; margin: 0 0 6px; font-size: 12.5px; font-weight: 800; color: var(--muted); text-transform: uppercase; letter-spacing: 0.06em; }
.cmp-label .i { width: 14px; height: 14px; }
.cmp-poll { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.cmp-series { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.cmp-series input[type="search"] { flex: 1; min-width: 200px; }
.cmp-ch { width: 110px; }
.cmp-picked { display: flex; align-items: center; gap: 10px; padding: 6px 6px 6px 8px; border-radius: 12px; background: var(--card2); flex: 1; min-width: 200px; }
.cmp-picked[hidden] { display: none; }
.cmp-picked img { width: 28px; aspect-ratio: 2/3; object-fit: cover; border-radius: 4px; }
.cmp-picked b { flex: 1; font-size: 14px; }
.cmp-series-results { flex-basis: 100%; display: flex; flex-direction: column; gap: 4px; }
.cmp-series-results:empty { display: none; }
.cmp-series-results button { display: flex; align-items: center; gap: 10px; padding: 6px 8px; border-radius: 10px; border: 0; background: var(--card2); cursor: pointer; text-align: left; font: inherit; font-size: 14px; color: var(--text); }
.cmp-series-results button:hover { background: var(--accent-soft); }
.cmp-series-results img { width: 26px; aspect-ratio: 2/3; object-fit: cover; border-radius: 4px; }
.cmp-comms { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.cmp-comms::-webkit-scrollbar { display: none; }
.cc-chip { position: relative; flex: none; cursor: pointer; }
.cc-chip input { position: absolute; opacity: 0; pointer-events: none; }
.cc-chip > span { display: inline-flex; align-items: center; gap: 6px; padding: 5px 11px 5px 5px; border-radius: 99px; border: 1px solid var(--line); font-size: 13px; font-weight: 700; color: var(--muted); transition: all 0.12s; }
.cc-chip input:checked + span { color: var(--text); border-color: var(--cc); background: color-mix(in srgb, var(--cc) 20%, transparent); }
.cc-chip input:focus-visible + span { box-shadow: 0 0 0 3px var(--accent-soft); }
.cmp-bar { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.cmp-tool { position: relative; display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 11px; border-radius: 10px; border: 0; background: none; color: var(--muted); font: inherit; font-size: 13.5px; font-weight: 700; cursor: pointer; }
.cmp-tool:hover, .cmp-tool.on { background: var(--card2); color: var(--text); }
.cmp-tool .i { width: 18px; height: 18px; }
.cmp-tool[data-cmp-image] .i { color: var(--teal); }
.cmp-tool[data-cmp-toggle="poll"] .i { color: var(--violet); }
.cmp-tool[data-cmp-toggle="series"] .i { color: var(--sky); }
.cmp-spoiler input { position: absolute; opacity: 0; }
.cmp-spoiler:has(input:checked) { background: rgba(239, 68, 68, 0.14); color: var(--danger); }
.cmp-count { font-size: 12px; margin-right: 6px; }
.composer .form-error:empty { display: none; }
.composer-guest { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: 18px; background: linear-gradient(120deg, color-mix(in srgb, var(--violet) 18%, var(--card)), var(--card)); border: 1px solid var(--line); }
.composer-guest > .i { width: 26px; height: 26px; color: var(--violet); }
.composer-guest > span:nth-child(2) { flex: 1; display: flex; flex-direction: column; }
.composer-guest:hover { color: var(--text); border-color: var(--violet); }
.submit-page .composer { margin-top: 14px; }

/* ---------- post card ---------- */
.posts { gap: 12px; }
.pc { position: relative; display: flex; flex-direction: column; gap: 10px; padding: 14px 16px 10px; border-radius: 18px; background: var(--card); border: 1px solid var(--line); transition: border-color 0.15s; }
.pc::before { content: ""; position: absolute; left: 0; top: 16px; bottom: 16px; width: 3px; border-radius: 0 3px 3px 0; background: var(--cc); opacity: 0.85; }
.pc:hover { border-color: color-mix(in srgb, var(--cc) 40%, var(--line)); }
.pc-new { animation: pop-in 0.35s ease-out; border-color: var(--accent); }
.pc-head { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; font-size: 13px; }
.pc-comm { display: inline-flex; align-items: center; gap: 6px; font-weight: 800; color: color-mix(in srgb, var(--cc) 70%, var(--text)); }
.pc-comm:hover { color: var(--cc); }
.pc-user { display: inline-flex; align-items: center; gap: 6px; }
.pc-user b { font-weight: 700; }
.pc-sep { color: var(--muted); }
.pc-time { font-size: 12.5px; }
.pc-pin { color: var(--muted); display: inline-flex; }
.pc-pin .i { width: 14px; height: 14px; }
.pc-link { display: flex; flex-direction: column; gap: 6px; color: var(--text); }
.pc-link:hover { color: var(--text); }
.pc-title { margin: 0; font-size: 18px; font-weight: 800; line-height: 1.3; letter-spacing: -0.01em; }
.pc-text { margin: 0; font-size: 14.5px; line-height: 1.55; color: color-mix(in srgb, var(--text) 82%, var(--muted)); white-space: pre-line; display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.pc-text.big { font-size: 16.5px; color: var(--text); -webkit-line-clamp: 8; }
.pc-spoiler { margin: 0; display: inline-flex; align-items: center; gap: 8px; padding: 10px 14px; border-radius: 12px; background: repeating-linear-gradient(45deg, var(--card2), var(--card2) 10px, transparent 10px, transparent 20px); color: var(--muted); font-weight: 700; font-size: 14px; align-self: flex-start; }
/* short text-only posts: big quote on the community colour */
.pc-quote .pc-link { padding: 26px 22px; border-radius: 14px; background: radial-gradient(130% 160% at 0% 0%, color-mix(in srgb, var(--cc) 55%, transparent), transparent 60%), radial-gradient(120% 140% at 100% 100%, color-mix(in srgb, var(--violet) 35%, transparent), transparent 55%), var(--card2); }
.pc-quote .pc-text.big { font-size: clamp(18px, 2.4vw, 22px); font-weight: 700; line-height: 1.4; color: #fff; text-shadow: 0 1px 12px rgba(0, 0, 0, 0.25); }
html.light .pc-quote .pc-text.big { color: var(--text); text-shadow: none; }
.pc-series { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 12px; background: var(--card2); color: var(--text); max-width: 440px; }
.pc-series img { width: 34px; aspect-ratio: 2/3; object-fit: cover; border-radius: 6px; }
.pc-series > span { flex: 1; min-width: 0; display: flex; flex-direction: column; font-size: 13.5px; line-height: 1.3; }
.pc-series b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pc-series > .i { color: var(--muted); }
.pc-series:hover { color: var(--text); background: color-mix(in srgb, var(--cc) 14%, var(--card2)); }
.pc-media { display: grid; gap: 4px; border-radius: 14px; overflow: hidden; background: var(--card2); }
.pc-media span { position: relative; display: block; overflow: hidden; }
.pc-media img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.3s; }
.pc-media:hover img { transform: scale(1.02); }
.pc-media.m1 { align-self: flex-start; width: fit-content; max-width: 100%; background: none; }
.pc-media.m1 img { width: auto; max-width: 100%; max-height: 480px; object-fit: contain; border-radius: 14px; }
.pc-media.m2 { grid-template-columns: 1fr 1fr; aspect-ratio: 2/1.1; }
.pc-media.m3 { grid-template-columns: 2fr 1fr; grid-template-rows: 1fr 1fr; aspect-ratio: 16/10; }
.pc-media.m3 span:first-child { grid-row: span 2; }
.pc-media.m4 { grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; aspect-ratio: 1/0.8; }
.pc-media i { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; background: rgba(0, 0, 0, 0.55); color: #fff; font-style: normal; font-size: 24px; font-weight: 800; }
/* actions row */
.pc-actions { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; margin-top: 2px; }
.pc-spacer { flex: 1; }
.pc-act { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 10px; border-radius: 99px; border: 0; background: none; color: var(--muted); font: inherit; font-size: 13.5px; font-weight: 700; cursor: pointer; transition: background 0.12s, color 0.12s; }
.pc-act:hover { background: var(--card2); color: var(--text); }
.pc-act .i { width: 17px; height: 17px; }
.pc-act.on { color: var(--accent); }
.pc-act.on .i { fill: currentColor; }
.vote-pill { display: inline-flex; align-items: center; gap: 2px; height: 34px; padding: 0 3px; border-radius: 99px; background: var(--card2); }
.vote-pill button { width: 28px; height: 28px; display: inline-flex; align-items: center; justify-content: center; border: 0; border-radius: 99px; background: none; color: var(--muted); cursor: pointer; }
.vote-pill button .i { width: 17px; height: 17px; }
.vote-pill button[data-v="1"]:hover, .vote-pill button[data-v="1"].on { color: var(--accent); background: var(--accent-soft); }
.vote-pill button[data-v="-1"]:hover, .vote-pill button[data-v="-1"].on { color: var(--violet); background: color-mix(in srgb, var(--violet) 16%, transparent); }
.vote-pill b { min-width: 20px; text-align: center; font-size: 13.5px; font-variant-numeric: tabular-nums; }
/* reactions */
.react { display: inline-flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.react-chip { display: inline-flex; align-items: center; gap: 4px; height: 30px; padding: 0 9px; border-radius: 99px; border: 1px solid var(--line); background: var(--card2); font-size: 15px; cursor: pointer; transition: transform 0.12s, border-color 0.12s; }
.react-chip b { font-size: 12.5px; color: var(--muted); font-variant-numeric: tabular-nums; }
.react-chip:hover { transform: translateY(-1px); }
.react-chip.on { border-color: var(--pink); background: color-mix(in srgb, var(--pink) 16%, var(--card2)); }
.react-chip.on b { color: var(--pink); }
.react-add { position: relative; }
.react-pick { position: absolute; bottom: calc(100% + 6px); left: 0; z-index: 30; display: flex; gap: 2px; padding: 5px; border-radius: 99px; background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow); animation: pop-in 0.15s ease-out; }
.react-pick[hidden] { display: none; }
.react-pick button { width: 38px; height: 38px; border: 0; border-radius: 99px; background: none; font-size: 21px; cursor: pointer; transition: transform 0.12s; }
.react-pick button:hover { transform: scale(1.25); background: var(--card2); }
.react-pick button.on { background: color-mix(in srgb, var(--pink) 20%, transparent); }
/* polls (feed + post page) */
.poll { display: flex; flex-direction: column; gap: 6px; max-width: 560px; }
.poll-row { position: relative; display: flex; justify-content: space-between; align-items: center; gap: 10px; min-height: 42px; padding: 9px 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--card2); overflow: hidden; font: inherit; font-weight: 600; font-size: 14.5px; color: var(--text); text-align: left; width: 100%; }
button.poll-row { cursor: pointer; transition: border-color 0.12s, transform 0.12s; }
button.poll-row:hover { border-color: var(--cc); transform: translateX(2px); }
.poll-row i { position: absolute; inset: 0 auto 0 0; background: color-mix(in srgb, var(--cc) 26%, transparent); transition: width 0.5s ease-out; }
.poll-row span, .poll-row b { position: relative; }
.poll-row.mine { border-color: var(--cc); }
.poll-row.mine span::after { content: " ✓"; color: var(--cc); }
.poll .muted { margin: 2px 0 0; }
.load-more { margin-top: 4px; }
/* post page */
.post-full { display: flex; flex-direction: column; gap: 12px; padding: 20px; border-radius: 20px; background: var(--card); border: 1px solid var(--line); }
.post-full h1 { font-size: clamp(22px, 3vw, 30px); margin: 2px 0 0; letter-spacing: -0.015em; }
.post-full .md { font-size: 16px; line-height: 1.7; }
.post-full .md-big { font-size: 18px; }
.post-full .gallery { margin-top: 0; }
.pc-more > summary { list-style: none; }
.pc-more .menu-pop { bottom: calc(100% + 6px); top: auto; }

/* ---------- community page ---------- */
.comm-page { --cc: var(--accent); }
.comm-head { margin-top: -40px; align-items: flex-end; }
.comm-head .comm-icon.xl { box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35); }
.comm-title { flex: 1; min-width: 200px; }
.comm-title h1 { margin: 0; font-size: clamp(24px, 3.5vw, 32px); }
.comm-title p { margin: 2px 0 0; }
.comm-stats { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: 13.5px; color: var(--muted); }
.comm-stats b { color: var(--text); }
.faces { display: inline-flex; margin-right: 4px; }
.faces .av { margin-left: -7px; box-shadow: 0 0 0 2px var(--bg); }
.faces .av:first-child { margin-left: 0; }
.pinned-list { display: flex; flex-direction: column; margin-bottom: 12px; border-radius: 14px; border: 1px solid var(--line); background: var(--card); overflow: hidden; }
.pinned-list a { display: flex; align-items: center; gap: 10px; padding: 10px 14px; font-size: 14px; font-weight: 600; }
.pinned-list a + a { border-top: 1px solid var(--line); }
.pinned-list a .i { width: 15px; height: 15px; color: var(--cc); flex: none; }
.pinned-list a:hover { background: var(--card2); color: var(--text); }

/* ---------- sidebar ---------- */
.side-card h4 { display: flex; align-items: center; gap: 7px; font-size: 13px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); }
.side-card h4 .i { width: 16px; height: 16px; color: var(--accent); }
.side-list a > span:not(.comm-icon):not(.rank) { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side-list a i { font-style: normal; font-size: 12px; }
.side-foot { display: flex; justify-content: space-between; margin-top: 4px; }
.side-series { display: flex; flex-direction: column; gap: 8px; }
.side-series a { display: flex; align-items: center; gap: 10px; }
.side-series img { width: 36px; aspect-ratio: 2/3; object-fit: cover; border-radius: 6px; }
.side-series span { display: flex; flex-direction: column; min-width: 0; font-size: 13.5px; }
.side-series b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side-series i { font-style: normal; font-size: 12px; }
.rank { width: 20px; height: 20px; flex: none; display: inline-flex; align-items: center; justify-content: center; border-radius: 6px; background: var(--card2); font-size: 11.5px; font-weight: 800; color: var(--muted); }
.rank.r1 { background: linear-gradient(135deg, #ffd166, #f6b93b); color: #1a1200; }
.rank.r2 { background: linear-gradient(135deg, #e5e7eb, #9ca3af); color: #111; }
.rank.r3 { background: linear-gradient(135deg, #f0b27a, #b9770e); color: #1a0e00; }
.side-rules { font-size: 13px; color: var(--muted); }

@media (max-width: 1100px) { .with-side { grid-template-columns: 1fr; } .side { position: static; } }
@media (max-width: 860px) {
  .pc { padding: 12px 12px 8px; border-radius: 16px; }
  .pc-title { font-size: 17px; }
  .pc-actions { gap: 2px; }
  .pc-act { padding: 0 8px; }
  .cmp-tool span { display: none; }
  .cmp-poll { grid-template-columns: 1fr; }
  .comm-head { margin-top: -30px; }
}

/* ---------- home: "From the community" strip ---------- */
.ct-row { display: flex; gap: 14px; overflow-x: auto; padding: 4px 2px 10px; scroll-snap-type: x mandatory; scrollbar-width: none; }
.ct-row::-webkit-scrollbar { display: none; }
.ct { position: relative; flex: none; width: 260px; height: 300px; display: flex; flex-direction: column; gap: 10px; padding: 16px; border-radius: 20px; overflow: hidden; background: var(--card); border: 1px solid var(--line); scroll-snap-align: start; color: var(--text); transition: transform 0.18s, box-shadow 0.18s; }
a.ct:hover { color: var(--text); transform: translateY(-3px); box-shadow: 0 14px 34px rgba(0, 0, 0, 0.35); }
.ct-comm { position: relative; z-index: 1; display: inline-flex; align-items: center; gap: 6px; align-self: flex-start; padding: 4px 10px 4px 4px; border-radius: 99px; font-size: 12px; font-weight: 800; background: color-mix(in srgb, var(--cc) 22%, rgba(0, 0, 0, 0.25)); backdrop-filter: blur(6px); color: #fff; }
.ct-body { position: relative; z-index: 1; flex: 1; min-height: 0; display: flex; flex-direction: column; gap: 6px; overflow: hidden; }
.ct-body b { font-size: 17px; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.ct-body span { font-size: 14px; line-height: 1.5; color: color-mix(in srgb, var(--text) 78%, var(--muted)); display: -webkit-box; -webkit-line-clamp: 6; -webkit-box-orient: vertical; overflow: hidden; }
.ct-foot { position: relative; z-index: 1; display: flex; align-items: center; gap: 7px; font-size: 12.5px; font-weight: 700; }
.ct-foot > span:first-of-type { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ct-stats { display: inline-flex; align-items: center; gap: 4px; color: var(--muted); font-variant-numeric: tabular-nums; }
.ct-stats .i { width: 14px; height: 14px; }
/* tile variants */
.ct-text { background: linear-gradient(170deg, color-mix(in srgb, var(--cc) 16%, var(--card)), var(--card) 55%); }
.ct-quote { background: radial-gradient(130% 120% at 0% 0%, color-mix(in srgb, var(--cc) 70%, transparent), transparent 62%), radial-gradient(120% 120% at 100% 100%, color-mix(in srgb, var(--violet) 55%, transparent), transparent 60%), #15151d; border-color: transparent; }
.ct-quote .ct-body { justify-content: center; }
.ct-quote .ct-body span { font-size: 19px; font-weight: 800; line-height: 1.35; color: #fff; -webkit-line-clamp: 7; }
.ct-quote .ct-foot, .ct-img .ct-foot { color: #fff; }
.ct-quote .ct-stats, .ct-img .ct-stats { color: rgba(255, 255, 255, 0.8); }
.ct-img { border-color: transparent; background: #000; }
.ct-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s; }
a.ct-img:hover .ct-bg { transform: scale(1.04); }
.ct-img::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0, 0, 0, 0.35), transparent 30%, transparent 45%, rgba(0, 0, 0, 0.88)); }
.ct-img .ct-body { justify-content: flex-end; }
.ct-img .ct-body b { color: #fff; text-shadow: 0 1px 8px rgba(0, 0, 0, 0.5); }
.ct-prompt { justify-content: center; align-items: flex-start; gap: 10px; background: radial-gradient(120% 90% at 0% 0%, color-mix(in srgb, var(--accent) 38%, transparent), transparent 60%), radial-gradient(120% 120% at 100% 100%, color-mix(in srgb, var(--pink) 30%, transparent), transparent 60%), var(--card); }
.ct-prompt b { font-size: 20px; line-height: 1.25; }
.ct-prompt > span:not(.btn):not(.ct-prompt-ico) { color: color-mix(in srgb, var(--text) 75%, var(--muted)); font-size: 14px; }
.ct-prompt-ico { width: 46px; height: 46px; border-radius: 14px; display: flex; align-items: center; justify-content: center; background: var(--accent); color: var(--on-accent); }
.ct-prompt .btn { margin-top: 6px; }
.ct-poll { width: 300px; background: linear-gradient(170deg, color-mix(in srgb, var(--cc) 22%, var(--card)), var(--card) 60%); }
.ct-poll .ct-comm { color: #fff; }
.ct-q { font-size: 16px; font-weight: 800; line-height: 1.3; color: var(--text); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.ct-poll .poll { gap: 5px; }
.ct-poll .poll-row { min-height: 36px; padding: 6px 12px; font-size: 13.5px; }
.ct-more { width: 200px; justify-content: center; align-items: center; text-align: center; gap: 8px; background: var(--card2); }
.ct-more .i { width: 34px; height: 34px; color: var(--violet); }
.ct-more span { font-size: 13px; color: var(--muted); }
@media (max-width: 860px) { .ct { width: 78vw; max-width: 300px; } .ct-poll { width: 84vw; max-width: 330px; } .ct-more { width: 46vw; } }
.ct-body span { white-space: pre-line; }

/* ---------- profile ---------- */
.i.pink { color: var(--pink); } .i.sky { color: var(--sky); } .i.violet { color: var(--violet); } .i.teal { color: var(--teal); }
.pf-banner { position: relative; height: 220px; overflow: hidden; background: radial-gradient(90% 140% at 10% 0%, var(--pc), transparent 60%), radial-gradient(70% 120% at 90% 10%, color-mix(in srgb, var(--pc) 45%, var(--violet)), transparent 65%), radial-gradient(60% 100% at 55% 100%, color-mix(in srgb, var(--pink) 45%, transparent), transparent 70%), var(--bg2); }
.pf-banner::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 45%, var(--bg)); }
.pf-banner img { width: 100%; height: 100%; object-fit: cover; }
.pf { padding-top: 0; }
.pf-head { position: relative; display: flex; align-items: flex-end; gap: 20px; margin-top: -64px; flex-wrap: wrap; }
.pf-av { position: relative; flex: none; }
.pf-av .av { width: 124px; height: 124px; box-shadow: 0 0 0 5px var(--bg), 0 14px 34px rgba(0, 0, 0, 0.4); }
.pf-av .av.frame-orange { box-shadow: 0 0 0 4px var(--bg), 0 0 0 7px var(--accent), 0 14px 34px rgba(0, 0, 0, 0.4); }
.pf-av .av.frame-gold { box-shadow: 0 0 0 4px var(--bg), 0 0 0 7px #f6b93b, 0 0 26px rgba(246, 185, 59, 0.6); }
.pf-av .online { position: absolute; right: 8px; bottom: 8px; width: 20px; height: 20px; border-radius: 99px; background: var(--ok); box-shadow: 0 0 0 4px var(--bg); }
.pf-id { flex: 1; min-width: 240px; padding-bottom: 4px; }
.pf-id h1 { margin: 0; font-size: clamp(26px, 4vw, 36px); letter-spacing: -0.02em; }
.pf-handle { margin: 2px 0 0; color: var(--muted); font-size: 14px; }
.pf-lv { color: color-mix(in srgb, var(--pc) 70%, var(--text)); }
.pf-badges { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.pf-badges:empty { display: none; }
.pf-bio { margin: 10px 0 0; max-width: 640px; font-size: 15px; line-height: 1.55; white-space: pre-line; }
.pf-actions { display: flex; gap: 8px; align-items: center; padding-bottom: 6px; }
.pf-stats { display: grid; grid-template-columns: repeat(6, 1fr); gap: 1px; margin: 22px 0 6px; border-radius: 16px; overflow: hidden; background: var(--line); border: 1px solid var(--line); }
.pf-stats div { display: flex; flex-direction: column; align-items: center; padding: 14px 6px; background: var(--card); }
.pf-stats b { font-size: 22px; font-variant-numeric: tabular-nums; }
.pf-stats span { font-size: 12px; color: var(--muted); font-weight: 600; text-align: center; }
.pf-tabs { margin: 16px 0 18px; }
.pf-grid { display: grid; grid-template-columns: 1fr 340px; gap: 26px; align-items: start; }
.pf-main { display: flex; flex-direction: column; gap: 26px; min-width: 0; }
.pf-side { display: flex; flex-direction: column; gap: 14px; }
.pf-side .level-card { margin: 0; }
.pf-sec .sec-head h2 { display: flex; align-items: center; gap: 8px; font-size: 20px; }
.pf-empty { padding: 22px; border-radius: 16px; border: 1px dashed var(--line); color: var(--muted); display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.fav-row { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; }
.fav { position: relative; display: flex; flex-direction: column; gap: 6px; color: var(--text); }
.fav img { width: 100%; aspect-ratio: 2/3; object-fit: cover; border-radius: 14px; box-shadow: 0 8px 22px rgba(0, 0, 0, 0.35); transition: transform 0.18s; }
.fav:hover img { transform: translateY(-3px) rotate(-1deg); }
.fav b { font-size: 13px; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.fav-n { position: absolute; left: -6px; top: -6px; z-index: 1; width: 26px; height: 26px; border-radius: 99px; display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 900; background: var(--pc, var(--accent)); color: #fff; box-shadow: 0 0 0 3px var(--bg); }
.pf-reading { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 10px; }
.pf-reading a { display: flex; gap: 12px; padding: 10px; border-radius: 14px; background: var(--card); border: 1px solid var(--line); color: var(--text); }
.pf-reading a:hover { border-color: color-mix(in srgb, var(--sky) 50%, var(--line)); }
.pf-reading img { width: 46px; aspect-ratio: 2/3; object-fit: cover; border-radius: 8px; }
.pf-reading span { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; font-size: 13.5px; }
.pf-reading b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pf-reading .bar { display: block; height: 5px; margin-top: auto; border-radius: 9px; background: var(--card2); }
.pf-reading .bar i { display: block; height: 100%; border-radius: 9px; background: var(--sky); }
.genre-bars { display: flex; flex-direction: column; gap: 6px; }
.gb { position: relative; display: block; padding: 6px 10px; border-radius: 9px; overflow: hidden; background: var(--card2); font-size: 13px; font-weight: 700; color: var(--text); }
.gb i { position: absolute; inset: 0 auto 0 0; opacity: 0.35; }
.gb span { position: relative; }
.gb0 i { background: var(--accent); } .gb1 i { background: var(--violet); } .gb2 i { background: var(--pink); } .gb3 i { background: var(--sky); } .gb4 i { background: var(--teal); } .gb5 i { background: var(--gold); }
.gb:hover { color: var(--text); }
.ach-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(88px, 1fr)); gap: 8px; }
.ach { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 10px 4px; border-radius: 12px; background: var(--card2); text-align: center; filter: grayscale(1); opacity: 0.45; cursor: help; }
.ach i { font-style: normal; font-size: 24px; }
.ach b { font-size: 11px; line-height: 1.2; }
.ach.got { filter: none; opacity: 1; background: linear-gradient(160deg, color-mix(in srgb, var(--gold) 22%, var(--card2)), var(--card2)); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--gold) 35%, transparent); }
@media (max-width: 1100px) { .pf-grid { grid-template-columns: 1fr; } }
@media (max-width: 860px) {
  .pf-banner { height: 150px; }
  .pf-head { margin-top: -54px; gap: 14px; align-items: flex-start; }
  .pf-av .av { width: 96px; height: 96px; }
  .pf-id { min-width: 0; flex-basis: 100%; }
  .pf-actions { position: absolute; right: 0; top: 60px; }
  .pf-stats { grid-template-columns: repeat(3, 1fr); }
  .fav-row { grid-template-columns: repeat(3, 1fr); }
}

/* ---------- settings ---------- */
.settings { max-width: 1060px; }
.set-layout { display: grid; grid-template-columns: 220px 1fr; gap: 28px; align-items: start; }
.set-nav { position: sticky; top: 84px; display: flex; flex-direction: column; gap: 2px; }
.set-nav a { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 12px; font-weight: 700; font-size: 14.5px; color: var(--muted); }
.set-nav a .i { width: 18px; height: 18px; }
.set-nav a:hover { background: var(--card); color: var(--text); }
.set-nav a.on { background: var(--card); color: var(--text); box-shadow: inset 3px 0 0 var(--accent); }
.set-nav a:last-child { margin-top: 10px; border-top: 1px solid var(--line); border-radius: 0; padding-top: 14px; }
.set-main { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.set-card { scroll-margin-top: 84px; display: flex; flex-direction: column; gap: 14px; padding: 22px; border-radius: 20px; background: var(--card); border: 1px solid var(--line); }
.set-card h2 { display: flex; align-items: center; gap: 10px; margin: 0; font-size: 21px; }
.set-card > p.muted { margin: -6px 0 0; }
.set-card .card-form.flat { padding: 0; border: 0; background: none; margin: 0; }
.set-row { display: flex; flex-direction: column; gap: 8px; }
/* live preview of the profile header */
.pf-preview { border-radius: 16px; overflow: hidden; border: 1px solid var(--line); background: var(--bg2); }
.pf-preview-banner { height: 92px; background: radial-gradient(90% 140% at 10% 0%, var(--pc), transparent 60%), radial-gradient(70% 120% at 90% 10%, color-mix(in srgb, var(--pc) 45%, var(--violet)), transparent 65%), var(--card2); transition: background 0.3s; }
.pf-preview-banner img { width: 100%; height: 100%; object-fit: cover; }
.pf-preview-banner img[hidden] { display: none; }
.pf-preview-body { display: flex; gap: 14px; padding: 0 16px 14px; }
.pf-preview-body .av { margin-top: -30px; box-shadow: 0 0 0 4px var(--bg2); flex: none; }
.pf-preview-body > div { display: flex; flex-direction: column; min-width: 0; padding-top: 8px; }
.pf-preview-body b { font-size: 17px; }
.pf-preview-body p { margin: 6px 0 0; font-size: 13.5px; color: color-mix(in srgb, var(--text) 80%, var(--muted)); white-space: pre-line; }
/* switches */
.switch-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 0; border-top: 1px solid var(--line); cursor: pointer; }
.set-card h2 + .switch-row { border-top: 0; }
.switch-row > span { display: flex; flex-direction: column; gap: 2px; }
.switch-row b { font-size: 15px; }
.switch-row .muted { font-size: 13px; }
input.switch { appearance: none; -webkit-appearance: none; flex: none; width: 48px; height: 28px; padding: 0; border: 0; border-radius: 99px; background: var(--card2); box-shadow: inset 0 0 0 1px var(--line); position: relative; cursor: pointer; transition: background 0.2s; }
input.switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 99px; background: #fff; box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3); transition: transform 0.2s cubic-bezier(0.3, 1.4, 0.5, 1); }
input.switch:checked { background: var(--ok); box-shadow: none; }
input.switch:checked::after { transform: translateX(20px); }
input.switch:focus-visible { outline: 3px solid var(--accent-soft); }
/* favourites editor */
.fav-edit { display: flex; flex-wrap: wrap; gap: 10px; }
.fav-edit:empty::before { content: "No favourites yet — search below to add your top series."; color: var(--muted); font-size: 14px; }
.fav-item { position: relative; width: 104px; display: flex; flex-direction: column; gap: 6px; }
.fav-item img { width: 100%; aspect-ratio: 2/3; object-fit: cover; border-radius: 12px; }
.fav-item b { font-size: 12.5px; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.fav-item .icon-btn { position: absolute; top: 4px; right: 4px; width: 28px; height: 28px; background: rgba(0, 0, 0, 0.6); color: #fff; }
.fav-search { display: flex; flex-direction: column; gap: 8px; }
.acct-line { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.acct-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.danger-zone { border: 1px solid color-mix(in srgb, var(--danger) 40%, var(--line)); border-radius: 14px; padding: 12px 16px; }
.danger-zone summary { display: flex; align-items: center; gap: 8px; cursor: pointer; color: var(--danger); font-weight: 700; list-style: none; }
.danger-zone[open] summary { margin-bottom: 8px; }
.btn.danger { background: var(--danger); color: #fff; }
.swatches { flex-wrap: wrap; }
@media (max-width: 860px) {
  .set-layout { grid-template-columns: 1fr; gap: 12px; }
  .set-nav { position: sticky; top: calc(var(--head) - 1px); z-index: 20; flex-direction: row; overflow-x: auto; gap: 6px; padding: 8px 0; margin: 0 -16px; padding-inline: 16px; background: var(--bg); scrollbar-width: none; }
  .set-nav a { flex: none; padding: 8px 12px; background: var(--card); border: 1px solid var(--line); border-radius: 99px; font-size: 13.5px; }
  .set-nav a.on { box-shadow: none; border-color: var(--accent); }
  .set-nav a:last-child { margin: 0; border-top: 1px solid var(--line); padding-top: 8px; border-radius: 99px; }
  .set-card { padding: 16px; border-radius: 16px; scroll-margin-top: 130px; }
}
.pf-id h1 { text-shadow: 0 2px 14px rgba(0, 0, 0, 0.45); }
html.light .pf-id h1 { text-shadow: 0 1px 10px rgba(255, 255, 255, 0.7); }
.pf-side .level-card { flex-direction: column; align-items: stretch; gap: 12px; }
.pf-side .lv-ring { width: 58px; height: 58px; position: absolute; }
.pf-side .level-card { position: relative; }
.pf-side .lv-ring b { font-size: 21px; }
.pf-side .lv-top { padding-left: 70px; min-height: 58px; flex-direction: column; align-items: flex-start; justify-content: center; gap: 2px; }
.pf-side .lv-perks span { font-size: 11.5px; }

/* ---------- composer sheet (bottom sheet on phones, dialog on desktop) ---------- */
.i.gold { color: var(--gold); }
.sheet { position: fixed; inset: 0; z-index: 95; background: rgba(5, 5, 8, 0); display: flex; align-items: center; justify-content: center; padding: 16px; transition: background 0.25s; }
.sheet[hidden] { display: none; }
.sheet.on { background: rgba(5, 5, 8, 0.6); backdrop-filter: blur(4px); }
.sheet-panel { width: 100%; max-width: 640px; max-height: calc(100dvh - 32px); overflow-y: auto; border-radius: 22px; background: var(--card); border: 1px solid var(--line); box-shadow: 0 30px 80px rgba(0, 0, 0, 0.5); transform: translateY(20px) scale(0.98); opacity: 0; transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.2s; }
.sheet.on .sheet-panel { transform: none; opacity: 1; }
.sheet-head { position: sticky; top: 0; z-index: 2; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; padding: 12px 16px; border-bottom: 1px solid var(--line); background: var(--card); }
.sheet-head b { font-size: 16px; }
.sheet-head .link-btn { justify-self: start; color: var(--muted); font-weight: 700; }
.sheet .composer { border: 0; border-radius: 0; box-shadow: none !important; background: none; }

/* ---------- mobile polish ---------- */
a, button, label, summary { -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
@media (max-width: 860px) {
  /* 16px+ text in fields stops iPhones from zooming in when you tap them */
  input, textarea, select { font-size: 16px !important; }
  .sheet { align-items: flex-end; padding: 0; }
  .sheet-panel { max-width: none; max-height: 94dvh; border-radius: 22px 22px 0 0; border-bottom: 0; transform: translateY(100%); opacity: 1; padding-bottom: env(safe-area-inset-bottom); }
  .sheet-panel::before { content: ""; display: block; width: 40px; height: 5px; margin: 8px auto 0; border-radius: 99px; background: var(--line); }
  .sheet .cmp-fields textarea { min-height: 120px; }
  /* feed cards go edge-to-edge-ish and get bigger tap targets */
  .feed .posts { margin: 0 -6px; }
  .pc-act, .vote-pill { height: 38px; }
  .vote-pill button { width: 32px; height: 32px; }
  .react-chip { height: 34px; }
  .seg-tabs { width: 100%; }
  .seg-tabs a { flex: 1; justify-content: center; padding: 8px 10px; }
  .composer { padding: 12px; }
  .cmp-main > .av { width: 34px; height: 34px; }
  .pf-tabs { width: auto; }
  .pf-tabs a { flex: none; }
}
/* the composer never grows wider than its column (the community chip row scrolls instead) */
.composer, .cmp-more, .cmp-comms, .cmp-main, .cmp-fields { min-width: 0; max-width: 100%; }
.cmp-fields textarea { overflow: hidden; }
.sheet-panel { overflow-x: hidden; }
.seg-opt { position: relative; }
.with-side > *, .pf-grid > * { min-width: 0; }
@media (max-width: 860px) { .r-end-nav { width: 100%; } .r-end-nav select { flex: 1; min-width: 0; width: auto; } .r-end-nav .btn { flex: none; } }

/* ---------- Manga / Novels switch: gliding highlight ---------- */
.kind-switch { position: relative; display: inline-grid; grid-template-columns: 1fr 1fr; isolation: isolate; }
.kind-switch a { position: relative; z-index: 1; text-align: center; background: none !important; transition: color 0.25s; }
.kind-switch a.on { color: var(--muted); }
.kind-switch[data-kind="manga"] a[data-kind-to="manga"], .kind-switch[data-kind="novel"] a[data-kind-to="novel"] { color: var(--on-accent); }
.ks-ind { position: absolute; z-index: 0; top: 3px; bottom: 3px; left: 3px; width: calc(50% - 3px); border-radius: 99px; background: linear-gradient(135deg, var(--accent), color-mix(in srgb, var(--accent) 70%, var(--pink))); box-shadow: 0 4px 14px rgba(255, 130, 2, 0.35); transition: transform 0.35s cubic-bezier(0.3, 1.3, 0.5, 1); }
.kind-switch[data-kind="novel"] .ks-ind { transform: translateX(100%); background: linear-gradient(135deg, #3a86ff, var(--violet)); box-shadow: 0 4px 14px rgba(99, 102, 241, 0.4); }
.kind-switch[data-kind="novel"] a[data-kind-to="novel"] { color: #fff; }

/* ---------- page slide when switching Manga / Novels ----------
   The other side is fetched ahead of time and swapped in place (public/app.js), so the slide is just two
   GPU transforms — no page load, no full-page snapshots. */
.kind-swap { overflow-x: clip; }
.kind-old { position: fixed !important; left: 0; right: 0; z-index: 1; pointer-events: none; will-change: transform, opacity; }
.kind-new { will-change: transform, opacity; }
@media (prefers-reduced-motion: reduce) { .ks-ind { transition: none; } }

/* ---------- "lite": old/slow phones (set in the page head) — drop the expensive effects ---------- */
.lite *, .lite *::before, .lite *::after { backdrop-filter: none !important; -webkit-backdrop-filter: none !important; }
.lite .top, .lite .tabbar, .lite .r-top { background: var(--bg); }
.lite .hero-bg, .lite .banner-bg { display: none; }
.lite .card, .lite .pc, .lite .ct { box-shadow: none !important; }
.feed-title { margin: 0 0 2px; }

/* ---------- "not on Manga Yugen yet" card (search) ---------- */
.spinner { width: 22px; height: 22px; border-radius: 99px; border: 3px solid var(--line); border-top-color: var(--accent); animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.sr-looking { flex-direction: row; justify-content: center; }
.disc { display: flex; flex-direction: column; gap: 12px; padding: 16px; margin: 6px; border-radius: 16px; background: radial-gradient(120% 120% at 0% 0%, color-mix(in srgb, var(--dc) 24%, transparent), transparent 60%), var(--card2); border: 1px solid color-mix(in srgb, var(--dc) 30%, var(--line)); }
.disc-label { margin: 0; font-size: 11.5px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.disc-main { display: flex; gap: 14px; }
.disc-cover { width: 96px; aspect-ratio: 2/3; object-fit: cover; border-radius: 10px; flex: none; box-shadow: 0 8px 22px rgba(0, 0, 0, 0.35); }
.disc-info { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.disc-title { font-size: 19px; line-height: 1.25; }
.disc-alt { font-size: 13px; }
.disc-meta { font-size: 13px; font-weight: 600; display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.disc-score { font-style: normal; color: var(--gold); }
.disc-genres { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 4px; }
.disc-genres i { font-style: normal; font-size: 11.5px; font-weight: 700; padding: 2px 8px; border-radius: 99px; background: var(--card); color: var(--muted); }
.disc-desc { margin: 0; font-size: 13.5px; line-height: 1.55; color: color-mix(in srgb, var(--text) 82%, var(--muted)); white-space: pre-line; display: -webkit-box; -webkit-line-clamp: 5; -webkit-box-orient: vertical; overflow: hidden; }
.disc-legal { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.disc-legal a { padding: 5px 11px; border-radius: 99px; font-size: 13px; font-weight: 700; background: var(--card); border: 1px solid var(--line); }
.disc-legal a:hover { border-color: var(--ok); color: var(--text); }
.disc-actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.disc-src { margin-left: auto; }
.disc-more { margin: 0; }
.discover-box { max-width: 640px; margin: 10px 0 20px; }
.discover-box .disc { margin: 0; }

/* ---------- browse filters ---------- */
.browse2 { display: flex; flex-direction: column; gap: 12px; margin: 16px 0 8px; }
.b-search { display: block; }
.b-search input { height: 48px; font-size: 16px; border-radius: 14px; }
.b-filters { display: flex; gap: 8px; align-items: center; }
.b-sel { width: auto; height: 38px; padding: 0 34px 0 14px; border-radius: 99px; font-size: 13.5px; font-weight: 700; background-color: var(--card); }
.b-sort { margin-left: auto; }
.seg2 { display: inline-flex; flex: none; padding: 3px; border-radius: 99px; border: 1px solid var(--line); background: var(--card); }
.seg-opt { position: relative; }
.seg-opt input { position: absolute; opacity: 0; pointer-events: none; }
.seg-opt span { display: block; padding: 6px 14px; border-radius: 99px; font-size: 13.5px; font-weight: 700; color: var(--muted); cursor: pointer; white-space: nowrap; }
.seg-opt input:checked + span { background: var(--accent); color: var(--on-accent); }
.seg-opt input:focus-visible + span { box-shadow: 0 0 0 3px var(--accent-soft); }
.b-genres { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.b-genres .chip-opt { margin: 0; }
.more-genres { display: contents; }
.more-genres > summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }
.more-genres > summary::-webkit-details-marker { display: none; }
.more-genres[open] > summary { color: var(--accent); }
.more-genres > .chips { flex-basis: 100%; display: flex; flex-wrap: wrap; gap: 6px; }
.b-count { margin: 4px 0 14px; font-size: 13.5px; }

/* ---------- phones: header, bottom tab bar, browse ---------- */
.tab-me { font: inherit; }
@media (max-width: 860px) {
  .wrap { padding-inline: 16px; }
  .page { padding-top: 22px; }
  .hero-desc { font-size: 15px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
  .hero h1 { font-size: 30px; }
  .hero-dots { bottom: 22px; }
  .hero-in { padding-bottom: 52px; }
  /* header: logo · Manga/Novels · (bell) search — the account lives in the "Me" tab */
  .top-in { gap: 10px; }
  .top .account-menu { display: none; }
  .top .kind-switch { margin: 0 auto; }
  .top .kind-switch a { padding: 7px 15px; font-size: 13.5px; }
  .top-actions { margin-left: 0; gap: 8px; }
  .top-actions .icon-btn, .top-actions .search-btn { width: 40px; height: 40px; min-width: 0; padding: 0; border-radius: 12px; border: 1px solid var(--line); background: var(--card); display: inline-flex; align-items: center; justify-content: center; position: relative; }
  .top-actions .search-btn span, .top-actions .search-btn kbd { display: none; }
  .top-actions .icon-btn .dot { position: absolute; top: -4px; right: -4px; }
  .support-fab { display: none; }
  .support { bottom: calc(72px + env(safe-area-inset-bottom)); }

  /* bottom tab bar: five equal tabs, Home in the middle */
  .tabbar { display: grid; grid-template-columns: repeat(5, 1fr); align-items: stretch; height: calc(62px + env(safe-area-inset-bottom)); padding: 0 4px env(safe-area-inset-bottom); }
  .tabbar > a, .tabbar > button { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; min-width: 0; height: 62px; padding: 0; border: 0; background: none; color: var(--muted); font-size: 10.5px; font-weight: 700; letter-spacing: 0.01em; cursor: pointer; }
  .tabbar > a.on, .tabbar > button.on { color: var(--text); }
  .tabbar > a.on .i { color: var(--accent); }
  .tabbar .i { width: 22px; height: 22px; }
  .tab-home .tab-ico { display: grid; place-items: center; width: 54px; height: 32px; border-radius: 99px; background: var(--card2); border: 1px solid var(--line); transition: background 0.2s, border-color 0.2s; }
  .tab-home.on .tab-ico { background: linear-gradient(135deg, var(--accent), color-mix(in srgb, var(--accent) 70%, var(--pink))); border-color: transparent; box-shadow: 0 6px 16px rgba(255, 130, 2, 0.35); }
  .tabbar > .tab-home.on .i { color: #fff; }
  .tabbar > a, .tabbar > button { justify-content: flex-start; padding-top: 7px; }
  .tabbar > a > .i, .tabbar > button > .i { margin: 5px 0; }
  .tab-me .av { margin: 4px 0; }
  .tab-me .av { width: 24px; height: 24px; box-shadow: 0 0 0 2px var(--bg), 0 0 0 3.5px var(--line); }
  .tab-dot { position: absolute; top: 10px; left: calc(50% + 8px); width: 9px; height: 9px; border-radius: 99px; background: var(--accent); box-shadow: 0 0 0 2px var(--bg); }
  .foot { padding-bottom: calc(72px + env(safe-area-inset-bottom)); }
  .toast { bottom: calc(84px + env(safe-area-inset-bottom)); }

  /* "Me" sheet */
  .me-items { padding: 6px 10px 14px; }
  .me-items .menu-head { flex-direction: row; align-items: center; gap: 12px; padding: 10px 8px 14px; }
  .me-items .menu-head > span { display: flex; flex-direction: column; min-width: 0; }
  .me-items a, .me-items button { display: flex; align-items: center; gap: 14px; width: 100%; padding: 13px 10px; border: 0; border-radius: 12px; background: none; color: var(--text); font: inherit; font-size: 15.5px; font-weight: 600; text-align: left; cursor: pointer; }
  .me-items a:active, .me-items button:active { background: var(--card2); }
  .me-items .i { width: 20px; height: 20px; color: var(--muted); }
  .me-items hr { border: 0; border-top: 1px solid var(--line); margin: 6px 4px; }
  .me-items .menu-label { padding: 12px 10px 4px; }

  /* browse: one search field, then a row of filters and a row of genres you swipe sideways */
  .browse2 { gap: 10px; margin: 12px 0 6px; }
  .b-filters, .b-genres { flex-wrap: nowrap; overflow-x: auto; margin: 0 -16px; padding: 2px 16px; scrollbar-width: none; }
  .b-filters::-webkit-scrollbar, .b-genres::-webkit-scrollbar { display: none; }
  .b-filters > *, .b-genres > *, .more-genres > .chips > * { flex: none; }
  .b-sort { margin-left: 0; }
  .seg-opt span { padding: 6px 12px; }
  .more-genres > .chips { flex-basis: auto; flex-wrap: nowrap; display: contents; }
  .b-count { margin: 2px 0 12px; }
  .page h1 { font-size: 26px; margin-bottom: 4px; }
}
@media (max-width: 380px) {
  .top .kind-switch a { padding: 6px 11px; font-size: 13px; }
  .top-actions { gap: 6px; }
}

/* ---------- spoilers: blurred until tapped ---------- */
.veil { position: relative; border-radius: 14px; }
.veil:not(.open) { min-height: 64px; }
.veil:not(.open) .veil-in { filter: blur(9px); opacity: 0.55; user-select: none; pointer-events: none; max-height: 220px; overflow: hidden; }
.veil.open .veil-btn { display: none; }
.veil-btn { position: absolute; inset: 0; z-index: 2; display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; padding: 12px 16px; border: 1.5px dashed color-mix(in srgb, var(--gold) 55%, var(--line)); border-radius: 14px; background: color-mix(in srgb, var(--bg) 35%, transparent); color: var(--text); font: inherit; text-align: left; cursor: pointer; }
.veil-btn:hover { border-color: var(--gold); }
.veil-btn > .i { width: 22px; height: 22px; color: var(--gold); flex: none; }
.veil-btn > span { display: flex; flex-direction: column; min-width: 0; }
.veil-btn b { font-size: 14px; line-height: 1.3; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.veil-btn i { font-style: normal; font-size: 12.5px; color: var(--muted); font-weight: 600; }
.c-veil:not(.open) { min-height: 54px; }
.c-veil .veil-btn { justify-content: flex-start; }
.post-veil:not(.open) { min-height: 120px; margin: 6px 0; }
.lite .veil:not(.open) .veil-in { filter: none; visibility: hidden; }
.hide-btn { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; }
.hide-btn .i { width: 14px; height: 14px; }
.cf-spoiler-for { margin: 0 8px 8px; width: calc(100% - 16px); }
.cmp-spoiler-for input { width: 100%; }
.cf-bar { flex-wrap: wrap; }
.warn-text { color: var(--gold); font-weight: 700; }

/* notifications */
.notif-ico { display: grid; place-items: center; width: 34px; height: 34px; flex: none; border-radius: 99px; background: color-mix(in srgb, var(--accent) 16%, transparent); color: var(--accent); }
.notif-ico .i { width: 17px; height: 17px; }
.team-msg { align-items: flex-start; background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 12%, transparent), transparent 70%); }
.team-msg p { margin: 4px 0 6px; white-space: pre-line; line-height: 1.55; }
.team-ico { display: grid; place-items: center; width: 34px; height: 34px; flex: none; border-radius: 10px; background: var(--accent); color: var(--on-accent); }
.team-ico .i { width: 18px; height: 18px; }

/* ---------- reactions on the pages ---------- */
.pages { position: relative; }
.marks { position: absolute; inset: 0; pointer-events: none; z-index: 3; transition: opacity 0.18s; }
.marks.faded { opacity: 0.08; }
.marks.faded .mk-spot { pointer-events: none; }
.mk-spot { position: absolute; transform: translate(-50%, -50%); pointer-events: auto; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 0; border: 0; background: none; cursor: pointer; font: inherit; animation: mk-in 0.25s ease-out both; }
@keyframes mk-in { from { opacity: 0; transform: translate(-50%, -50%) scale(0.6); } }
.mk-emo { display: inline-flex; align-items: center; padding: 3px 7px 3px 3px; border-radius: 99px; background: rgba(12, 12, 16, 0.78); box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35); }
.mk-emo i { font-style: normal; font-size: 19px; line-height: 1; margin-left: -4px; filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.5)); }
.mk-emo i:first-child { margin-left: 3px; }
.mk-emo b { margin-left: 5px; font-size: 11.5px; font-weight: 800; color: #fff; }
.mk-note { max-width: 170px; padding: 5px 9px; border-radius: 12px 12px 12px 3px; background: rgba(255, 255, 255, 0.94); color: #111; font-size: 12px; font-weight: 600; line-height: 1.3; text-align: left; box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.mk-note b { color: var(--accent); }
.mk-mine .mk-emo, .mk-mine .mk-note { box-shadow: 0 0 0 2px var(--accent), 0 4px 14px rgba(0, 0, 0, 0.35); }
.mk-pop { position: fixed; z-index: 95; max-height: 60vh; overflow-y: auto; padding: 12px 14px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 8px; }
.mk-pop-head { display: flex; align-items: center; justify-content: space-between; }
.mk-pop-emo { display: flex; flex-wrap: wrap; gap: 6px; }
.mk-pop-emo span { display: inline-flex; align-items: center; gap: 4px; padding: 3px 9px; border-radius: 99px; background: var(--card2); font-size: 16px; }
.mk-pop-emo b { font-size: 12.5px; }
.mk-pop-note { padding: 8px 10px; border-radius: 10px; background: var(--card2); }
.mk-pop-note p { margin: 0 0 2px; font-size: 14px; }
.mk-picker { position: fixed; inset: 0; z-index: 96; display: flex; align-items: flex-end; justify-content: center; background: rgba(5, 5, 8, 0); transition: background 0.2s; }
.mk-picker.on { background: rgba(5, 5, 8, 0.5); }
.mk-pick-panel { width: 100%; max-width: 520px; padding: 14px 16px calc(18px + env(safe-area-inset-bottom)); border-radius: 20px 20px 0 0; background: var(--card); border: 1px solid var(--line); border-bottom: 0; display: flex; flex-direction: column; gap: 10px; transform: translateY(100%); transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1); }
.mk-picker.on .mk-pick-panel { transform: none; }
.mk-pick-head { display: flex; align-items: center; justify-content: space-between; }
.mk-pick-panel p { margin: 0; }
.mk-emoji { display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; }
.mk-emoji button { height: 50px; border-radius: 14px; border: 1px solid var(--line); background: var(--card2); font-size: 26px; cursor: pointer; transition: transform 0.1s, border-color 0.15s; }
.mk-emoji button:active { transform: scale(0.92); }
.mk-emoji button.on { border-color: var(--accent); background: var(--accent-soft); }
.mk-note-form { display: flex; gap: 8px; }
.mk-note-form input { flex: 1; min-width: 0; }
.mk-mine-list { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--muted); }
.mk-banner { position: fixed; left: 50%; top: calc(14px + env(safe-area-inset-top)); transform: translateX(-50%); z-index: 96; display: flex; align-items: center; gap: 12px; padding: 8px 8px 8px 16px; border-radius: 99px; background: var(--card); border: 1px solid var(--accent); box-shadow: var(--shadow); font-weight: 700; font-size: 14px; white-space: nowrap; }
body.mk-placing .pages img { cursor: crosshair; }
body.mk-placing .r-top, body.mk-placing .r-bar { transform: translateY(-100%); }
body.mk-placing .r-bar { transform: translateY(100%); }
.pages img { -webkit-touch-callout: none; }

/* bottom bar of the reader: rating · comments · Reactions · React · ▲ */
.r-peek { cursor: default; gap: 8px; }
.peek-main { display: flex; align-items: center; gap: 18px; height: 100%; padding: 0 4px; border: 0; background: none; color: var(--text); font: inherit; font-size: 14px; cursor: pointer; }
.peek-act { display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 12px; border-radius: 99px; border: 1px solid var(--line); background: var(--card2); color: var(--text); font: inherit; font-size: 13px; font-weight: 700; cursor: pointer; }
.peek-act .i { width: 16px; height: 16px; }
.peek-act.on { border-color: var(--accent); color: var(--accent); background: var(--accent-soft); }
.peek-react { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.r-peek { justify-content: center; }
.r-peek .peek-act:first-of-type { margin-left: 10px; }
.peek-more { margin-left: 0; border: 0; color: var(--text); cursor: pointer; flex: none; }
@media (max-width: 560px) {
  .r-peek { padding: 0 12px; }
  .peek-main { gap: 12px; }
  .peek-lbl { display: none; }
  .peek-act { padding: 0 10px; }
}
@media (max-width: 360px) { .peek-act span { display: none; } }
.peek-main + .peek-more { margin-left: 10px; }
.reading .toast { bottom: auto; top: calc(108px + env(safe-area-inset-top)); }

/* ---------- friends & messages ---------- */
.fr-layout { display: grid; grid-template-columns: 340px minmax(0, 1fr); gap: 18px; align-items: start; }
.fr-side h1 { margin-bottom: 12px; }
.fr-tabs { display: flex; gap: 4px; padding: 4px; margin-bottom: 12px; border-radius: 14px; background: var(--card); border: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.fr-tabs a { flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 8px 6px; border-radius: 10px; font-size: 12.5px; font-weight: 700; color: var(--muted); white-space: nowrap; }
.fr-tabs a .i { width: 16px; height: 16px; }
.fr-tabs a.on { background: var(--card2); color: var(--text); }
.fr-tabs a i { font-style: normal; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 99px; background: var(--accent); color: var(--on-accent); font-size: 11px; display: inline-grid; place-items: center; }
.fr-list { display: flex; flex-direction: column; gap: 2px; }
.fr-row { display: flex; align-items: center; gap: 12px; padding: 9px 10px; border-radius: 14px; color: var(--text); }
a.fr-row:hover, .fr-row.on { background: var(--card); color: var(--text); }
.fr-row.on { box-shadow: inset 3px 0 0 var(--accent); }
.fr-av { position: relative; flex: none; display: inline-flex; }
.fr-av .online, .rm .online { position: absolute; right: 0; bottom: 0; width: 11px; height: 11px; border-radius: 99px; background: var(--ok); box-shadow: 0 0 0 2px var(--bg); }
.fr-main { flex: 1; min-width: 0; display: flex; flex-direction: column; color: var(--text); }
.fr-main b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fr-last { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fr-badge { font-style: normal; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 99px; background: var(--accent); color: var(--on-accent); font-size: 11.5px; font-weight: 800; display: grid; place-items: center; }
.fr-go { color: var(--muted); }
.fr-acts { display: flex; gap: 6px; }
.fr-label { margin: 14px 10px 4px; font-size: 11.5px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.fr-note { padding: 10px; margin: 0; }
.fr-empty { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 34px 16px; text-align: center; }
.fr-empty > .i { width: 30px; height: 30px; color: var(--muted); }
.fr-empty .btn { margin-top: 6px; }
.fr-find { display: flex; flex-direction: column; gap: 8px; padding: 2px; }
.fr-find .muted.sm { margin: 0 4px 6px; }
.fr-new-room { margin-bottom: 8px; }
.pf-id { font-weight: 700; color: var(--muted); font-size: 0.92em; opacity: 0.8; }
.menu-n { font-style: normal; margin-left: auto; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 99px; background: var(--accent); color: var(--on-accent); font-size: 11.5px; font-weight: 800; display: inline-grid; place-items: center; }

.chat { display: flex; flex-direction: column; height: calc(100vh - var(--head) - 60px); min-height: 420px; border-radius: 20px; background: var(--card); border: 1px solid var(--line); overflow: hidden; position: sticky; top: calc(var(--head) + 16px); }
.chat-idle { align-items: center; justify-content: center; }
.chat-head { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.chat-who { display: flex; align-items: center; gap: 10px; color: var(--text); min-width: 0; }
.chat-who > span { display: flex; flex-direction: column; min-width: 0; }
.chat-back { display: none; }
.chat-log { flex: 1; overflow-y: auto; padding: 16px 14px; display: flex; flex-direction: column; gap: 6px; overscroll-behavior: contain; }
.chat-hint { margin: auto; text-align: center; max-width: 320px; font-size: 14px; }
.bubble { display: flex; align-items: flex-end; gap: 8px; max-width: 82%; animation: pop-in 0.18s ease-out; }
.bubble.mine { align-self: flex-end; flex-direction: row-reverse; }
.b-av { flex: none; display: inline-flex; }
.b-in { padding: 8px 12px; border-radius: 16px 16px 16px 5px; background: var(--card2); min-width: 0; }
.bubble.mine .b-in { border-radius: 16px 16px 5px 16px; background: linear-gradient(135deg, var(--accent), color-mix(in srgb, var(--accent) 75%, var(--pink))); color: var(--on-accent); }
.b-in p { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; line-height: 1.45; font-size: 14.5px; }
.b-name { display: block; font-size: 12px; color: var(--accent); margin-bottom: 1px; }
.b-meta { display: block; margin-top: 2px; font-size: 11px; opacity: 0.65; }
.b-meta i { font-style: normal; font-weight: 800; }
.chat-form { display: flex; align-items: flex-end; gap: 8px; padding: 10px; border-top: 1px solid var(--line); background: var(--card); }
.chat-form textarea { flex: 1; min-height: 42px; max-height: 160px; resize: none; border-radius: 14px; padding: 10px 14px; line-height: 1.4; }
.chat-form .btn-icon { width: 42px; height: 42px; flex: none; border-radius: 14px; }
.chat-locked { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 14px; border-top: 1px solid var(--line); color: var(--muted); }
@media (max-width: 860px) {
  .fr-layout { grid-template-columns: minmax(0, 1fr); }
  .friends-page .chat-idle { display: none; }
  .friends-page.has-chat .fr-side { display: none; }
  .friends-page.has-chat { padding-top: 0; padding-bottom: 0; }
  .friends-page.has-chat .chat { position: fixed; inset: var(--head) 0 calc(62px + env(safe-area-inset-bottom)); height: auto; min-height: 0; border-radius: 0; border: 0; z-index: 30; }
  .chat-back { display: inline-flex; }
  .top .msg-btn { display: none; }
}

/* ---------- reading rooms ---------- */
.room-tag { display: inline-flex; align-items: center; gap: 6px; font-size: 11.5px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: var(--teal, #2dd4bf); }
.room-tag .i { width: 14px; height: 14px; }
.room-box { display: flex; align-items: center; gap: 12px; padding: 10px; border-radius: 14px; background: linear-gradient(135deg, color-mix(in srgb, #2dd4bf 12%, var(--card2)), var(--card2)); border: 1px solid color-mix(in srgb, #2dd4bf 30%, var(--line)); }
.room-box > img { width: 52px; aspect-ratio: 2/3; object-fit: cover; border-radius: 8px; flex: none; }
.room-box-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.room-box-main b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.room-faces { display: flex; align-items: center; gap: 6px; }
.room-faces .av { margin-right: -12px; box-shadow: 0 0 0 2px var(--card2); }
.room-faces .av:last-of-type { margin-right: 6px; }
.room-row .room-poster { width: 42px; height: 60px; object-fit: cover; border-radius: 8px; flex: none; background: var(--card2); }
.room-privacy { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.rp-opt { position: relative; cursor: pointer; }
.rp-opt input { position: absolute; opacity: 0; pointer-events: none; }
.rp-opt > span { display: flex; flex-direction: column; gap: 4px; height: 100%; padding: 12px 14px; border-radius: 14px; border: 1.5px solid var(--line); background: var(--card2); }
.rp-opt b { display: inline-flex; align-items: center; gap: 6px; }
.rp-opt b .i { width: 16px; height: 16px; }
.rp-opt input:checked + span { border-color: var(--accent); background: var(--accent-soft); }
.invite-list { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.inv-opt { position: relative; display: inline-flex; align-items: center; gap: 8px; padding: 5px 12px 5px 5px; border-radius: 99px; border: 1.5px solid var(--line); background: var(--card2); font-size: 13.5px; font-weight: 700; cursor: pointer; color: var(--text); }
.inv-opt input { position: absolute; opacity: 0; pointer-events: none; }
.inv-opt:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); }
.inv-opt .i { width: 14px; height: 14px; color: var(--muted); }
.room-hero { display: flex; gap: 24px; align-items: center; margin-bottom: 26px; }
.room-cover { width: 150px; aspect-ratio: 2/3; object-fit: cover; border-radius: 16px; box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4); flex: none; }
.room-info h1 { margin: 6px 0 4px; }
.room-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: 20px; align-items: start; }
.room-col h2 { display: flex; align-items: center; gap: 8px; font-size: 18px; }
.room-members { display: flex; flex-direction: column; gap: 4px; }
.rm { position: relative; display: flex; align-items: center; gap: 12px; padding: 8px 10px; border-radius: 14px; color: var(--text); }
.rm:hover { background: var(--card); color: var(--text); }
.rm > span { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.rm .online { left: 40px; right: auto; bottom: 8px; }
.rm-host { font-style: normal; font-size: 11px; font-weight: 800; padding: 2px 8px; border-radius: 99px; background: var(--card2); color: var(--muted); }
.room-invite { margin-top: 12px; }
.room-invite > summary { list-style: none; display: inline-flex; }
.room-invite > summary::-webkit-details-marker { display: none; }
.room-leave { margin-top: 16px; display: inline-block; }
.room-chat-col .chat { height: 520px; position: static; }
@media (max-width: 860px) {
  .room-hero { flex-direction: column; text-align: center; }
  .room-hero .btns { justify-content: center; }
  .room-cover { width: 120px; }
  .room-grid { grid-template-columns: minmax(0, 1fr); }
  .room-chat-col .chat { height: 70vh; }
  .room-privacy { grid-template-columns: 1fr; }
}

/* reader: who's where, under the chapter bar */
.room-strip { display: flex; align-items: center; gap: 6px; padding: 6px 14px; overflow-x: auto; scrollbar-width: none; border-top: 1px solid var(--line); }
.room-strip::-webkit-scrollbar { display: none; }
.rs-title { display: inline-flex; align-items: center; gap: 5px; flex: none; padding: 5px 10px; border-radius: 99px; background: color-mix(in srgb, #2dd4bf 16%, transparent); color: #2dd4bf; font-size: 12px; font-weight: 800; }
.rs-title .i { width: 14px; height: 14px; }
.rs-m { display: inline-flex; align-items: center; gap: 7px; flex: none; padding: 3px 10px 3px 3px; border-radius: 99px; background: var(--card2); color: var(--text); }
.rs-m > span { display: flex; flex-direction: column; line-height: 1.1; }
.rs-m b { font-size: 12px; max-width: 90px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rs-m i { font-style: normal; font-size: 11px; color: var(--muted); font-weight: 700; }
.rs-m.here { box-shadow: 0 0 0 1.5px #2dd4bf inset; }
.rs-m.me i { color: var(--accent); }
body.has-room .reader { padding-top: 140px; }
body.has-room.paged .reader { padding-top: 0; }
.r-tabs { display: flex; gap: 4px; padding: 4px; margin: 12px 0; border-radius: 12px; background: var(--card2); }
.r-tabs button { flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 8px; border: 0; border-radius: 9px; background: none; color: var(--muted); font: inherit; font-weight: 700; font-size: 13.5px; cursor: pointer; }
.r-tabs button.on { background: var(--card); color: var(--text); box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2); }
.r-tabs .i { width: 15px; height: 15px; }
.r-tabs button i { font-style: normal; opacity: 0.6; }
.r-room { position: static; height: min(52vh, 460px); border-radius: 16px; }
.fr-tabs { display: grid; grid-template-columns: repeat(5, 1fr); }
.fr-tabs a { flex-direction: column; gap: 3px; padding: 7px 2px; font-size: 11.5px; position: relative; }
.fr-tabs a i { position: absolute; top: 3px; right: 8px; }
.room-tag { white-space: nowrap; }
@media (max-width: 560px) {
  .room-box { flex-wrap: wrap; }
  .room-box > .btn, .room-box > .muted { flex: 1 0 100%; justify-content: center; }
}

/* ---------- Reading Wrapped ---------- */
.wr-body { background: #07070b; overflow: hidden; }
.wr { position: fixed; inset: 0; display: grid; place-items: center; background: radial-gradient(80% 60% at 50% 0%, #1c1030, #07070b 70%); user-select: none; -webkit-user-select: none; }
.wr-stage { position: relative; width: min(440px, 100vw); height: min(800px, 100dvh); border-radius: 26px; overflow: hidden; box-shadow: 0 40px 120px rgba(0, 0, 0, 0.6); }
.wr-progress { position: absolute; z-index: 5; top: max(14px, calc((100dvh - 800px) / 2 + 14px)); left: 50%; transform: translateX(-50%); width: min(440px, 100vw); padding: 0 14px; display: flex; gap: 4px; }
.wr-progress i { flex: 1; height: 3px; border-radius: 9px; background: rgba(255, 255, 255, 0.25); overflow: hidden; position: relative; }
.wr-progress i::after { content: ""; position: absolute; inset: 0; background: #fff; transform-origin: left; transform: scaleX(0); }
.wr-progress i.wr-done::after { transform: scaleX(1); }
.wr-progress i.wr-now::after { animation: wr-fill 6.5s linear forwards; }
.wr.paused .wr-progress i.wr-now::after { animation-play-state: paused; }
@keyframes wr-fill { to { transform: scaleX(1); } }
.wr-slide { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; padding: 70px 30px 50px; text-align: center; color: #fff; opacity: 0; pointer-events: none; transition: opacity 0.45s; }
.wr-slide.on { opacity: 1; pointer-events: auto; }
.wr-slide.on > * { animation: wr-up 0.7s cubic-bezier(0.2, 0.8, 0.2, 1) both; }
.wr-slide.on > *:nth-child(2) { animation-delay: 0.12s; }
.wr-slide.on > *:nth-child(3) { animation-delay: 0.24s; }
.wr-slide.on > *:nth-child(4) { animation-delay: 0.36s; }
.wr-slide.on > *:nth-child(5) { animation-delay: 0.48s; }
@keyframes wr-up { from { opacity: 0; transform: translateY(26px) scale(0.97); } }
.wr-intro { background: radial-gradient(120% 80% at 20% 10%, #ff8202, transparent 55%), radial-gradient(120% 80% at 90% 90%, #c026d3, transparent 55%), #12081f; }
.wr-time { background: linear-gradient(160deg, #3a0ca3, #7209b7 50%, #f72585); }
.wr-chapters { background: linear-gradient(160deg, #ff8202, #ff4d6d); }
.wr-scroll { background: linear-gradient(180deg, #0b3d91, #00a5cf 60%, #06d6a0); }
.wr-top { background: radial-gradient(100% 70% at 50% 0%, #4c1d95, #0f0a1f 70%); }
.wr-genres { background: linear-gradient(160deg, #134e4a, #0f766e 50%, #84cc16); }
.wr-peak { background: linear-gradient(160deg, #7f1d1d, #ea580c 60%, #facc15); }
.wr-persona { background: radial-gradient(90% 60% at 50% 30%, #f472b6, #6d28d9 60%, #1e1b4b); }
.wr-social { background: linear-gradient(160deg, #1e3a8a, #6366f1 60%, #a855f7); }
.wr-summary { background: radial-gradient(120% 80% at 0% 0%, #ff8202 0%, transparent 50%), radial-gradient(120% 80% at 100% 100%, #6366f1, transparent 55%), #0e0b16; gap: 18px; }
.wr-kicker { margin: 0; font-size: 14px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; opacity: 0.85; }
.wr-huge { margin: 0; font-size: 108px; line-height: 0.95; font-weight: 800; letter-spacing: -0.05em; }
.wr-big { margin: 0; font-size: clamp(52px, 15vw, 74px); line-height: 1; font-weight: 800; letter-spacing: -0.04em; text-shadow: 0 6px 30px rgba(0, 0, 0, 0.25); }
.wr-title { margin: 0; font-size: 30px; line-height: 1.15; font-weight: 800; }
.wr-lead { margin: 0; font-size: 17px; line-height: 1.45; max-width: 330px; opacity: 0.95; }
.wr-small { margin: 6px 0 0; font-size: 14px; opacity: 0.8; }
.wr-tap { margin-top: 26px; font-size: 13px; font-weight: 700; opacity: 0.7; }
.wr-av .av { box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.9), 0 18px 40px rgba(0, 0, 0, 0.4); }
.wr-cover { width: 150px; aspect-ratio: 2/3; object-fit: cover; border-radius: 14px; box-shadow: 0 24px 50px rgba(0, 0, 0, 0.55); transform: rotate(-3deg); }
.wr-list { list-style: none; margin: 10px 0 0; padding: 0; display: flex; flex-direction: column; gap: 7px; width: 100%; max-width: 320px; text-align: left; }
.wr-list li { display: flex; align-items: center; gap: 10px; padding: 6px 10px 6px 8px; border-radius: 12px; background: rgba(255, 255, 255, 0.1); }
.wr-list li > span { width: 18px; font-weight: 800; opacity: 0.7; text-align: center; }
.wr-list img { width: 28px; height: 40px; object-fit: cover; border-radius: 5px; }
.wr-list b { font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wr-bars { display: flex; flex-direction: column; gap: 8px; width: 100%; max-width: 320px; margin-top: 12px; }
.wr-bar { height: 38px; border-radius: 10px; background: rgba(255, 255, 255, 0.12); overflow: hidden; }
.wr-bar span { display: flex; align-items: center; height: 100%; width: var(--w); padding: 0 12px; border-radius: 10px; background: rgba(255, 255, 255, 0.9); color: #0f3d36; font-weight: 800; font-size: 14px; white-space: nowrap; }
.wr-slide.on .wr-bar span { animation: wr-grow 0.9s cubic-bezier(0.2, 0.8, 0.2, 1) var(--d) both; }
@keyframes wr-grow { from { width: 0; } }
.wr-ruler { width: 6px; height: 140px; margin-top: 18px; border-radius: 9px; background: repeating-linear-gradient(180deg, #fff 0 2px, transparent 2px 14px); opacity: 0.6; }
.wr-emoji { font-size: 96px; line-height: 1; filter: drop-shadow(0 12px 30px rgba(0, 0, 0, 0.35)); }
.wr-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; width: 100%; max-width: 330px; margin: 8px 0; }
.wr-grid div { padding: 14px 10px; border-radius: 16px; background: rgba(255, 255, 255, 0.12); display: flex; flex-direction: column; }
.wr-grid b { font-size: 30px; line-height: 1.1; }
.wr-grid span { font-size: 12.5px; opacity: 0.8; font-weight: 700; }
.wr-card { width: 100%; max-width: 340px; padding: 18px; border-radius: 22px; background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.16); backdrop-filter: blur(10px); display: flex; flex-direction: column; gap: 12px; text-align: left; }
.wr-card-head { display: flex; align-items: center; gap: 10px; }
.wr-card-head div { display: flex; flex-direction: column; }
.wr-card-head span { font-size: 12px; opacity: 0.75; font-weight: 700; }
.wr-card-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.wr-card-grid div { padding: 10px 12px; border-radius: 14px; background: rgba(255, 255, 255, 0.1); display: flex; flex-direction: column; }
.wr-card-grid b { font-size: 24px; line-height: 1.1; }
.wr-card-grid span { font-size: 11.5px; opacity: 0.75; font-weight: 700; }
.wr-card-top { display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: 14px; background: rgba(255, 255, 255, 0.1); }
.wr-card-top img { width: 34px; height: 48px; object-fit: cover; border-radius: 6px; }
.wr-card-top span { display: flex; flex-direction: column; min-width: 0; }
.wr-card-top i { font-style: normal; font-size: 11px; opacity: 0.7; font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em; }
.wr-card-top b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wr-card-persona { display: flex; align-items: center; gap: 8px; }
.wr-card-persona span { font-size: 26px; }
.wr-card-persona i { margin-left: auto; font-style: normal; font-size: 12px; font-weight: 700; opacity: 0.75; }
.wr-card-url { margin: 0; font-size: 11px; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase; opacity: 0.55; text-align: center; }
.wr-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.wr-nav { position: absolute; top: 50%; transform: translateY(-50%); z-index: 6; width: 46px; height: 46px; border-radius: 99px; border: 0; background: rgba(255, 255, 255, 0.12); color: #fff; display: grid; place-items: center; cursor: pointer; }
.wr-nav:hover { background: rgba(255, 255, 255, 0.22); }
.wr-prev { left: calc(50% - 300px); }
.wr-next { right: calc(50% - 300px); }
.wr-close { position: absolute; z-index: 6; top: max(26px, calc((100dvh - 800px) / 2 + 26px)); right: max(14px, calc(50% - 206px)); color: #fff; background: rgba(0, 0, 0, 0.25); }
@media (max-width: 640px) {
  .wr-stage { border-radius: 0; height: 100dvh; width: 100vw; }
  .wr-progress { top: calc(10px + env(safe-area-inset-top)); }
  .wr-close { top: calc(22px + env(safe-area-inset-top)); right: 12px; }
  .wr-nav { display: none; }
}
.wr-empty .big-ico .i { width: 46px; height: 46px; color: var(--accent); }
.wr-comm { padding: 2px 10px; border-radius: 99px; background: #fff; color: color-mix(in srgb, var(--cc) 75%, #000); }
.wr-promo { display: grid; grid-template-columns: auto 1fr; gap: 2px 12px; align-items: center; padding: 14px 16px; margin-bottom: 14px; border-radius: 18px; color: #fff; background: radial-gradient(120% 120% at 0% 0%, #ff8202, transparent 60%), radial-gradient(120% 120% at 100% 100%, #c026d3, transparent 60%), #2a1240; box-shadow: 0 10px 30px rgba(192, 38, 211, 0.25); }
.wr-promo:hover { color: #fff; transform: translateY(-1px); }
.wr-promo span { grid-row: span 2; font-size: 28px; }
.wr-promo i { font-style: normal; font-size: 12.5px; opacity: 0.85; }

/* ---------- anime → manga guides ---------- */
.kicker { display: inline-flex; align-items: center; gap: 6px; margin: 0 0 8px; font-size: 12px; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent); }
.kicker .i { width: 14px; height: 14px; }
.an-index-head { max-width: 760px; margin-bottom: 22px; }
.an-index-head h1 { font-size: clamp(30px, 5vw, 46px); }
.an-search { max-width: 520px; margin-top: 14px; }
.an-search input { height: 50px; border-radius: 14px; font-size: 16px; }
.an-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 22px 16px; }
.an-grid.sm { grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 16px 12px; }
.an-card { display: flex; flex-direction: column; gap: 4px; color: var(--text); }
.an-card:hover { color: var(--accent); }
.an-img { display: block; aspect-ratio: 2/3; border-radius: 12px; overflow: hidden; background: var(--card2); margin-bottom: 4px; box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2); }
.an-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s; }
.an-card:hover .an-img img { transform: scale(1.05); }
.an-card b { font-size: 14px; line-height: 1.25; }
.an-none { margin-top: 18px; }
.an-seo { max-width: 760px; margin-top: 40px; }
.an-hero { position: relative; overflow: hidden; background: linear-gradient(180deg, color-mix(in srgb, var(--ac) 22%, var(--bg)), var(--bg)); }
.an-banner { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0.32; -webkit-mask-image: linear-gradient(#000 30%, transparent); mask-image: linear-gradient(#000 30%, transparent); }
.an-hero-in { position: relative; display: flex; gap: 28px; align-items: flex-end; padding-top: 46px; padding-bottom: 26px; }
.an-cover { width: 180px; aspect-ratio: 2/3.1; object-fit: cover; border-radius: 16px; box-shadow: 0 24px 50px rgba(0, 0, 0, 0.5); flex: none; }
.an-hero-text { max-width: 760px; }
.an-hero-text h1 { font-size: clamp(28px, 4.4vw, 44px); margin: 6px 0 10px; }
.an-answer { font-size: 18px; line-height: 1.55; margin: 0 0 10px; padding: 14px 16px; border-radius: 14px; background: color-mix(in srgb, var(--card) 85%, transparent); border-left: 4px solid var(--ac); }
.crumbs a { color: var(--muted); }
.crumbs a:hover { color: var(--text); }
.an-page { max-width: 980px; }
.ep-picker { padding: 20px; border-radius: 22px; background: var(--card); border: 1px solid var(--line); margin-bottom: 18px; }
.ep-picker h2 { display: flex; align-items: center; gap: 8px; font-size: 19px; }
.ep-parts { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding-bottom: 4px; margin: 0 -4px 12px; padding-inline: 4px; }
.ep-part { flex: none; padding: 8px 14px; border-radius: 99px; border: 1px solid var(--line); background: var(--card2); color: var(--muted); font: inherit; font-size: 13.5px; font-weight: 700; cursor: pointer; white-space: nowrap; }
.ep-part.on { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.ep-part i { font-style: normal; margin-left: 6px; padding: 1px 6px; border-radius: 99px; background: var(--ok); color: #fff; font-size: 10.5px; }
.ep-slide { display: flex; align-items: center; gap: 10px; }
.ep-range { flex: 1; }
.ep-range input[type="range"] { width: 100%; height: 34px; padding: 0; background: none; border: 0; accent-color: var(--accent); cursor: pointer; }
.ep-ticks { display: flex; justify-content: space-between; font-size: 12px; font-weight: 700; color: var(--muted); }
.ep-out { margin-top: 14px; padding: 18px; border-radius: 18px; background: var(--card2); display: flex; flex-direction: column; gap: 8px; align-items: flex-start; min-height: 150px; }
.ep-head { display: flex; flex-direction: column; gap: 2px; }
.ep-num { font-size: 12.5px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent); }
.ep-head b { font-size: 16px; }
.ep-main { font-size: clamp(26px, 5vw, 34px); font-weight: 800; letter-spacing: -0.02em; line-height: 1.1; }
.ep-main.sm { font-size: 22px; }
.ep-main.filler { color: var(--muted); }
.ep-note { margin: 0; font-size: 14px; color: var(--muted); }
.ep-next { font-size: 16px; }
.ep-next b { color: var(--accent); }
.an-read, .an-link { display: flex; align-items: center; gap: 14px; padding: 12px 16px; margin-bottom: 18px; border-radius: 16px; border: 1px solid var(--line); background: var(--card); color: var(--text); }
.an-read:hover, .an-link:hover { border-color: var(--accent); color: var(--text); }
.an-read img { width: 44px; height: 62px; object-fit: cover; border-radius: 8px; }
.an-read > span, .an-link > span { flex: 1; display: flex; flex-direction: column; }
.an-link > .i:first-child { width: 22px; height: 22px; color: var(--accent); }
.an-official { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 16px; margin-bottom: 18px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); }
.an-official b { display: inline-flex; align-items: center; gap: 6px; }
.an-official span { display: flex; gap: 6px; flex-wrap: wrap; }
.an-official a { padding: 5px 11px; border-radius: 99px; background: var(--card2); border: 1px solid var(--line); font-size: 13px; font-weight: 700; }
.an-seasons h2, .an-faq h2, .an-about h2, .an-more h2 { margin-top: 30px; }
.an-part { margin-bottom: 10px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); overflow: hidden; }
.an-part > summary { list-style: none; display: flex; align-items: center; gap: 12px; padding: 14px 16px; cursor: pointer; }
.an-part > summary::-webkit-details-marker { display: none; }
.an-part > summary > span { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.an-part > summary .i { transition: transform 0.2s; color: var(--muted); }
.an-part[open] > summary .i { transform: rotate(180deg); }
.an-part-answer { margin: 0 16px 10px; line-height: 1.55; }
.an-note { display: flex; gap: 8px; margin: 0 16px 12px; padding: 10px 12px; border-radius: 12px; background: color-mix(in srgb, var(--gold) 10%, transparent); font-size: 13.5px; line-height: 1.5; }
.an-note .i { width: 16px; height: 16px; flex: none; margin-top: 2px; color: var(--gold); }
.an-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.an-table th { text-align: left; padding: 8px 16px; font-size: 12px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); border-bottom: 1px solid var(--line); }
.an-table td { padding: 9px 16px; border-bottom: 1px solid var(--line); vertical-align: top; }
.an-table td:first-child { font-weight: 800; white-space: nowrap; width: 70px; }
.an-table td:last-child { white-space: nowrap; font-weight: 700; }
.an-table small { display: block; color: var(--muted); font-size: 12.5px; margin-top: 2px; }
.an-table tr.filler td { color: var(--muted); }
.an-table tr:last-child td { border-bottom: 0; }
.an-filler { padding: 2px 8px; border-radius: 99px; background: var(--card2); font-size: 12px; }
.an-about p { line-height: 1.65; color: color-mix(in srgb, var(--text) 85%, var(--muted)); }
.faq { border-bottom: 1px solid var(--line); }
.faq summary { padding: 14px 0; font-weight: 700; cursor: pointer; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; float: right; color: var(--muted); font-weight: 400; }
.faq[open] summary::after { content: "–"; }
.faq p { margin: 0 0 14px; line-height: 1.6; }
.an-src { margin-top: 30px; line-height: 1.6; }
.an-src details summary { cursor: pointer; font-weight: 700; }
@media (max-width: 860px) {
  .an-hero-in { flex-direction: column; align-items: flex-start; gap: 16px; padding-top: 24px; }
  .an-cover { width: 110px; }
  .an-answer { font-size: 16px; }
  .an-grid { grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 16px 10px; }
  .an-table td, .an-table th { padding: 8px 10px; }
  .an-table td:last-child { white-space: normal; }
  .ep-picker { padding: 16px; border-radius: 18px; }
}
@media (max-width: 860px) { .an-cover { display: none; } .an-hero-in { padding-top: 18px; } }

/* ---------- character tier lists ---------- */
.tl-head { display: flex; justify-content: space-between; gap: 20px; align-items: center; flex-wrap: wrap; margin: 6px 0 20px; }
.tl-head h1 { margin-bottom: 4px; }
.tl-fav { display: flex; align-items: center; gap: 12px; padding: 10px 16px 10px 10px; border-radius: 18px; background: linear-gradient(135deg, color-mix(in srgb, #ff4d6d 22%, var(--card)), var(--card)); border: 1px solid color-mix(in srgb, #ff4d6d 35%, var(--line)); }
.tl-fav img { width: 54px; height: 72px; object-fit: cover; border-radius: 10px; }
.tl-fav > span { display: flex; flex-direction: column; }
.tl-fav i { font-style: normal; font-size: 11.5px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: #ff4d6d; }
.tl-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items: start; }
.tl-col h2 { display: flex; align-items: center; gap: 8px; font-size: 18px; }
.tl-their { margin-top: 24px; }
.tl-board { display: flex; flex-direction: column; gap: 6px; }
.tl-row { display: flex; min-height: 80px; border-radius: 14px; background: var(--card); border: 1px solid var(--line); overflow: hidden; transition: border-color 0.15s, background 0.15s; }
.tl-label { flex: none; width: 52px; display: grid; place-items: center; font-size: 24px; font-weight: 800; color: #111; background: var(--tc); }
.tl-items { flex: 1; display: flex; flex-wrap: wrap; gap: 6px; padding: 6px; align-content: flex-start; min-width: 0; }
.tl-char { position: relative; width: 58px; flex: none; display: flex; flex-direction: column; align-items: center; gap: 2px; cursor: pointer; border-radius: 10px; outline: none; }
.tl-char img { width: 58px; height: 74px; object-fit: cover; border-radius: 9px; background: var(--card2); pointer-events: none; }
.tl-char i { font-style: normal; font-size: 10.5px; font-weight: 700; max-width: 58px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--muted); }
.tl-char[data-avg]::after { content: attr(data-avg); position: absolute; top: 3px; right: 3px; padding: 0 4px; border-radius: 6px; background: rgba(0, 0, 0, 0.7); color: #fff; font-size: 10px; font-weight: 800; }
.tl-char.sel img, .tl-char:focus-visible img { box-shadow: 0 0 0 3px var(--accent); transform: translateY(-2px); }
.tl-editor.picking .tl-row, .tl-editor.picking .tl-pool { border-color: color-mix(in srgb, var(--accent) 45%, var(--line)); cursor: pointer; }
.tl-row.drop, .tl-pool.drop { border-color: var(--accent); background: var(--accent-soft); }
.tl-pool { display: flex; flex-wrap: wrap; gap: 6px; padding: 10px; margin-top: 10px; min-height: 90px; border-radius: 14px; border: 1.5px dashed var(--line); align-content: flex-start; }
.tl-pool-label { flex-basis: 100%; }
.tl-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.tl-help { margin: -4px 0 10px; }
.show-touch { display: none; }
@media (hover: none) { .show-touch { display: inline; } .hide-touch { display: none; } }
.tl-credit { margin-top: 26px; }
.tl-teaser .i:first-child { color: #ff4d6d; }
.tl-faces { display: flex; }
.tl-faces img { width: 30px; height: 30px; border-radius: 99px; object-fit: cover; object-position: top; margin-left: -8px; box-shadow: 0 0 0 2px var(--card); }
@media (max-width: 860px) {
  .tl-grid { grid-template-columns: minmax(0, 1fr); }
  .tl-col:last-child { order: -1; }
  .tl-label { width: 40px; font-size: 20px; }
  .tl-char, .tl-char img { width: 50px; }
  .tl-char img { height: 64px; }
}
.tl-spin { margin: 30px auto 16px; width: 40px; height: 40px; }
.tl-editor, .tl-editor * { -webkit-tap-highlight-color: transparent; }

/* ---------- library list ---------- */
.lib-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 12px; }
.lib-item { display: flex; gap: 14px; padding: 12px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); min-width: 0; }
.lib-item > a:first-child { flex: none; }
.lib-item > a:first-child img { width: 76px; aspect-ratio: 2/3; object-fit: cover; border-radius: 10px; display: block; background: var(--card2); }
.lib-item > div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; align-items: flex-start; }
.lib-title { font-weight: 800; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; color: var(--text); }
.lib-item .bar { width: 100%; margin-top: 2px; }
.lib-item .btn { margin-top: auto; }
.li-poster { width: 40px; aspect-ratio: 2/3; object-fit: cover; border-radius: 6px; flex: none; }
@media (max-width: 860px) {
  .lib-grid { grid-template-columns: minmax(0, 1fr); }
  .series-info { width: 100%; }
  .series-info .alt { white-space: normal; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .series-info .btns { flex-wrap: wrap; justify-content: center; }
  .series-info .stats { gap: 6px 16px; }
}
.cmp-spoiler .i { color: var(--gold); }
.cmp-tool[href] .i { color: #2dd4bf; }
.cmp-tool[data-hide-text] .i { color: var(--pink); }
.cmp-bar { flex-wrap: wrap; row-gap: 6px; }

/* ---------- polish pass ---------- */
.an-link > .tl-faces { flex: none; display: flex; flex-direction: row; padding: 0 6px 0 14px; }
/* support lives in the footer and the account menu — no floating button over the content */
.support-fab { display: none !important; }
.support { bottom: 20px; }
/* comfortable reading width for long text */
.series-main > .desc { max-width: 72ch; }
.series-main > .desc + .link-btn { margin-bottom: 6px; }
.series-main > .an-link, .series-main > .tl-teaser { margin-bottom: 12px; }
/* numbers line up */
.stats b, .pf-stats b, .wr-grid b, .wr-card-grid b, .ep-main, .page-count, .vote-pill b, .react-chip b, .fr-badge, .tl-char[data-avg]::after { font-variant-numeric: tabular-nums; }
/* keyboard focus is always visible */
a:focus-visible, button:focus-visible, summary:focus-visible, [tabindex]:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 8px; }
/* hero: poster sits on the right, balanced against the text */
@media (min-width: 861px) {
  .hero-in { justify-content: space-between; padding-right: clamp(20px, 6vw, 110px); }
  .hero-poster img { width: 236px; }
}
@media (max-width: 860px) {
  /* series page: big Read button on its own line, the rest share the line below evenly */
  .series-info .btns { display: grid; grid-template-columns: 1fr auto auto; gap: 8px; width: 100%; max-width: 420px; margin-inline: auto; }
  .series-info .btns > :first-child { grid-column: 1 / -1; justify-content: center; }
  .series-info .btns > .follow-menu > summary { width: 100%; justify-content: center; }
  .series-info .btns > .btn { justify-content: center; }
}

/* ---------- horizontal rows: fading edges + arrows (desktop) ---------- */
.row-wrap { position: relative; }
.row-wrap > .row, .row-wrap > .ct-row { --fl: 0px; --fr: 0px; -webkit-mask-image: linear-gradient(to right, transparent 0, #000 var(--fl), #000 calc(100% - var(--fr)), transparent 100%); mask-image: linear-gradient(to right, transparent 0, #000 var(--fl), #000 calc(100% - var(--fr)), transparent 100%); }
.row-wrap.can-right > .row, .row-wrap.can-right > .ct-row { --fr: 56px; }
.row-wrap.can-left > .row, .row-wrap.can-left > .ct-row { --fl: 40px; }
.row-btn { position: absolute; top: 38%; z-index: 4; width: 42px; height: 42px; margin-top: -21px; display: grid; place-items: center; border-radius: 99px; border: 1px solid var(--line); background: color-mix(in srgb, var(--card) 92%, transparent); color: var(--text); box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35); cursor: pointer; opacity: 0; pointer-events: none; transition: opacity 0.18s, transform 0.18s, background 0.15s; }
.row-btn .i { width: 20px; height: 20px; }
.row-btn:hover { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.row-btn:active { transform: scale(0.94); }
.row-prev { left: -14px; }
.row-next { right: -14px; }
@media (hover: hover) and (pointer: fine) {
  .row-wrap.can-left:hover .row-prev, .row-wrap.can-right:hover .row-next { opacity: 1; pointer-events: auto; }
}
.ct-row + .row-btn, .row-wrap:has(.ct-row) .row-btn { top: 50%; }
@media (max-width: 860px) { .row-btn { display: none; } .row-wrap.can-left > .row, .row-wrap.can-left > .ct-row { --fl: 0px; } .row-wrap.can-right > .row, .row-wrap.can-right > .ct-row { --fr: 28px; } }

/* ---------- admin ---------- */
@media (max-width: 860px) { .stat-grid { grid-template-columns: 1fr 1fr; gap: 10px; } .stat-card { padding: 14px; } .stat-card b { font-size: 24px; } }
.table td.actions { white-space: normal; min-width: 260px; }
.table td.actions > * { margin: 2px 4px 2px 0; }
.table td { vertical-align: middle; }

/* Measured control sizes and modal layouts across phones, tablets and desktops. */
html { scrollbar-gutter: stable; }
html:has(body.paged) { scrollbar-gutter: auto; }
.top-in .logo { flex-shrink: 0; white-space: nowrap; }
.skip-link { position: fixed; top: 8px; left: 16px; z-index: 120; padding: 10px 16px; border-radius: 10px; background: var(--accent); color: var(--on-accent); transform: translateY(-160%); font-weight: 700; }
.skip-link:focus { transform: none; }
.hero-dots { gap: 2px; bottom: 12px; }
.hero-dots button, .hero-dots button.on { display: grid; place-items: center; width: 44px; height: 44px; background: transparent; border-radius: 10px; transition: none; }
.hero-dots button::before { content: ""; width: 16px; height: 6px; border-radius: 99px; background: color-mix(in srgb, var(--text) 25%, transparent); transition: width .2s, background .2s; }
.hero-dots button.on::before { width: 28px; background: var(--accent); }
.search-field { flex-shrink: 0; }
.search-field input { flex: 1; min-width: 0; }
.search-field [data-search-close] { flex: none; width: 44px; height: 44px; }
.search-results { min-height: 0; overscroll-behavior: contain; }
.me-sheet .sheet-head { display: flex; justify-content: space-between; }
.menu-head b { overflow-wrap: anywhere; }
.sheet-panel { overscroll-behavior: contain; }
.sec-head > div, .notice > :last-child { min-width: 0; }
.sec-head h2, .notice, .md, .desc { overflow-wrap: anywhere; }
.sec-head .see-all { flex: none; }
.row-btn:focus-visible { opacity: 1; pointer-events: auto; }

@media (min-width: 861px) and (max-width: 1100px) {
  .top .search-btn { min-width: 44px; width: 44px; height: 44px; padding: 0; justify-content: center; }
  .top .search-btn span, .top .search-btn kbd { display: none; }
  .top-in { gap: 10px; }
  .main-nav { margin-left: 0; }
  .main-nav a { padding-inline: 10px; }
}
@media (max-width: 860px) {
  .hero-in { padding-bottom: 72px; }
  .hero-dots { bottom: 10px; }
  .top-actions .search-btn, .top-actions .icon-btn { width: 44px; height: 44px; flex: none; }
  .top-actions .msg-btn { display: none; } /* Messages are also in the account sheet. */
  .kind-switch a { min-height: 38px; display: inline-flex; align-items: center; justify-content: center; }
  .search-box { height: 100dvh; max-height: 100dvh; padding-top: env(safe-area-inset-top); padding-bottom: env(safe-area-inset-bottom); }
  .search-field { padding-inline: 12px; gap: 8px; }
  .btn, .btn-sm, .icon-btn, .cmp-tool, .peek-act { min-height: 44px; }
  .btn-icon, .icon-btn { min-width: 44px; }
  a.chip, .seg-opt span, .pills a, .seg-tabs a { min-height: 40px; display: inline-flex; align-items: center; }
  .link-btn { min-height: 36px; }
  .peek-act { min-width: 44px; }
  .r-head .icon-btn, .r-head .btn { min-height: 44px; }
  .r-sub select { min-width: 0; height: 40px; }
  .r-sub .btn { min-height: 40px; }
  .r-peek { gap: 6px; }
  .support { bottom: calc(72px + env(safe-area-inset-bottom)); max-height: calc(100dvh - 150px); }
}
@media (max-width: 380px) {
  .top-in { gap: 6px; }
  .top .kind-switch a { padding-inline: 9px; }
  .top-actions { gap: 4px; }
  .r-peek { padding-inline: 8px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* Optional analytics choices and operational controls share the site's spacing. */
.analytics-consent { position: fixed; z-index: 85; left: 24px; bottom: 24px; width: min(440px, calc(100vw - 48px)); padding: 20px; border: 1px solid var(--line); border-radius: 16px; background: var(--card); box-shadow: 0 8px 40px #0005; max-height: calc(100dvh - 160px); overflow: auto; }
.analytics-consent[hidden], .analytics-options[hidden] { display: none; }
.analytics-consent strong { font-size: 16px; }
.analytics-consent p { margin: 10px 0 16px; font-size: 13px; line-height: 1.65; color: var(--muted); }
.analytics-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.analytics-actions .btn { flex: 1; white-space: nowrap; min-height: 44px; }
.analytics-actions .link-btn { width: 100%; min-height: 36px; text-align: center; }
.analytics-options { display: grid; gap: 12px; margin-block: 16px; padding-top: 14px; border-top: 1px solid var(--line); font-size: 13px; }
.analytics-options label { display: flex; align-items: start; gap: 10px; line-height: 1.5; cursor: pointer; }
.analytics-options input { margin-top: 3px; flex: none; width: 18px; height: 18px; }
.analytics-reader-choices { text-align: center; padding: 24px; margin: 0; font-size: 12px; }
.bot-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px; }
.bot-control { min-width: 0; }
.bot-control [hidden] { display: none !important; }
.bot-control h2 { margin-top: 0; }
.bot-control input, .bot-control select { max-width: 100%; min-width: 0; }
.bot-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-block: 20px; }
.bot-stats > * { min-width: 0; padding: 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); overflow-wrap: anywhere; }
.bot-stat { display: grid; gap: 8px; }
.bot-stat strong { font-size: 20px; }
.bot-staged-poster { max-width: 160px; max-height: 240px; object-fit: contain; border-radius: 12px; }
.bot-staging-review .pages img { max-width: 100%; height: auto; }
.bot-staging-review .pages { display: grid; gap: 12px; }
.bot-token-form { display: flex; align-items: end; gap: 12px; }
.bot-token-form label { flex: 1; min-width: 0; }
.bot-jobs { display: grid; gap: 12px; }
.bot-job { border: 1px solid var(--line); border-radius: 12px; padding: 16px; min-width: 0; overflow-wrap: anywhere; }
.bot-log { white-space: pre-wrap; overflow-wrap: anywhere; max-height: 260px; overflow: auto; padding: 16px; background: var(--bg); border-radius: 10px; font-size: 12px; line-height: 1.6; }
.bot-token-output { display: block; white-space: pre-wrap; overflow-wrap: anywhere; padding: 14px; border-radius: 8px; background: var(--bg); max-width: 100%; }
.series-aliases { margin-block: 18px; border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; }
.series-aliases summary { cursor: pointer; font-weight: 600; min-height: 28px; }
.series-aliases ul { margin: 12px 0 0; padding-left: 20px; font-size: 13px; line-height: 1.8; overflow-wrap: anywhere; }
.series-alias-label { color: var(--muted); font-size: 12px; }
.identify-intro { max-width: 720px; margin-bottom: 28px; }
.identify-intro h1 { margin-bottom: 12px; }
.identify-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(240px, .6fr); gap: 28px; align-items: start; }
.identify-form { min-width: 0; }
.identify-form .cmp-fields { min-width: 0; }
.identify-form .cmp-title { font-size: 16px; }
.identify-form textarea { min-height: 130px; }
.identify-clues { display: grid; gap: 16px; margin-block: 16px; }
.identify-clues label { display: grid; gap: 6px; font-size: 13px; font-weight: 600; }
.identify-clues input, .identify-clues select { width: 100%; min-width: 0; font-size: 14px; }
.identify-hint { line-height: 1.7; overflow-wrap: anywhere; }
.identify-status { font-size: 12px; color: var(--muted); }
@media (max-width: 860px) {
  .analytics-consent { left: 12px; bottom: calc(76px + env(safe-area-inset-bottom)); width: calc(100vw - 24px); padding: 16px; max-height: calc(100dvh - 160px); }
  .reading .analytics-consent { bottom: calc(76px + env(safe-area-inset-bottom)); }
  .bot-grid, .identify-layout { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .bot-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .bot-token-form { flex-direction: column; align-items: stretch; }
  .identify-form .cmp-main { gap: 10px; }
  .identify-form .cmp-main > .av { display: none; }
  .identify-form .cmp-bar { flex-wrap: wrap; }
}
