/* ElosBook — linguagem PERFORMANCE: preto absoluto + verde neon */
/* =====================================================================
   TEMAS. O tema escolhido fica em <html data-theme="...">.
   neon = padrão (preto + verde neon) · grafite = escuro suave · claro = fundo branco
   ===================================================================== */
:root, [data-theme="neon"] {
  --bg: #0A0A0A; --bg-2: #121212; --bg-3: #1A1A1A; --line: #262626;
  --text: #F2F2F2; --text-rgb: 242, 242, 242; --muted: #8A8A8A;
  --neon: #00FF88; --accent-rgb: 0, 255, 136; --neon-dim: rgba(0, 255, 136, 0.12); --on-accent: #001a0d;
  --warn: #FFB020; --warn-rgb: 255, 176, 32; --err: #FF4D5E; --err-rgb: 255, 77, 94;
  --gold: #FFC83D; --gold-rgb: 255, 200, 61; --on-gold: #0A0A0A;
  --tint-accent: #102a1d; --tint-accent-strong: #0f3a26; --tint-gold: #3a2f0f; --tint-gold-soft: #1a160b;
  --tint-warn: #221a0b; --tint-err: #2a1519;
  --glass: rgba(10, 10, 10, .92); --tag-text: #cfcfcf; --star-off: #3a3a3a; --shadow-a: .5;
  color-scheme: dark;
}
[data-theme="grafite"] {
  --bg: #15181A; --bg-2: #1D2124; --bg-3: #252A2E; --line: #31383D;
  --text: #ECEFF1; --text-rgb: 236, 239, 241; --muted: #98A3AB;
  --neon: #4ADE80; --accent-rgb: 74, 222, 128; --neon-dim: rgba(74, 222, 128, 0.12); --on-accent: #0b2416;
  --warn: #F5B942; --warn-rgb: 245, 185, 66; --err: #F06272; --err-rgb: 240, 98, 114;
  --gold: #F2C14E; --gold-rgb: 242, 193, 78; --on-gold: #15181A;
  --tint-accent: #1d2e25; --tint-accent-strong: #223a2d; --tint-gold: #352d1b; --tint-gold-soft: #26231b;
  --tint-warn: #2b2517; --tint-err: #2e1d21;
  --glass: rgba(21, 24, 26, .92); --tag-text: #c3cbd1; --star-off: #3d454b; --shadow-a: .45;
  color-scheme: dark;
}
[data-theme="claro"] {
  --bg: #F6F7F5; --bg-2: #FFFFFF; --bg-3: #EEF1EE; --line: #DDE3DE;
  --text: #121614; --text-rgb: 18, 22, 20; --muted: #5E6A63;
  --neon: #00994F; --accent-rgb: 0, 153, 79; --neon-dim: rgba(0, 153, 79, 0.10); --on-accent: #FFFFFF;
  --warn: #B37400; --warn-rgb: 179, 116, 0; --err: #D12F42; --err-rgb: 209, 47, 66;
  --gold: #A87900; --gold-rgb: 168, 121, 0; --on-gold: #FFFFFF;
  --tint-accent: #E6F5EC; --tint-accent-strong: #D3EFDF; --tint-gold: #FBEFD0; --tint-gold-soft: #FFF8E6;
  --tint-warn: #FFF2DC; --tint-err: #FDE9EC;
  --glass: rgba(246, 247, 245, .92); --tag-text: #3C4641; --star-off: #D3D9D4; --shadow-a: .14;
  color-scheme: light;
}
:root {
  --radius: 14px;
  --display: 'Archivo Black', system-ui, sans-serif;
  --body: 'Inter', system-ui, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, monospace;
}
/* No tema claro, o brilho neon vira sombra discreta */
[data-theme="claro"] .btn-primary, [data-theme="claro"] .tab-big .tab-icon, [data-theme="claro"] .create-cta,
[data-theme="claro"] .rank-row.me, [data-theme="claro"] .done-burst, [data-theme="claro"] .chain-badge.lit,
[data-theme="claro"] .premium-cta, [data-theme="claro"] .code-box { box-shadow: 0 2px 10px rgba(0,0,0,.08); text-shadow: none; }
[data-theme="claro"] .logo-big img, [data-theme="claro"] .chain-icon.lit { filter: none; }
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--text); font-family: var(--body); font-size: 15px; line-height: 1.45; -webkit-tap-highlight-color: transparent; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; text-align: left; }
input, select, textarea { font: inherit; color: inherit; }
img { display: block; }
h1, h2, h3 { margin: 0; }
p { margin: 0; }
a { color: inherit; text-decoration: none; }

.app { max-width: 430px; margin: 0 auto; min-height: 100vh; position: relative; padding-bottom: 92px; background: var(--bg); }
.screen { animation: fade .18s ease-out; }
@keyframes fade { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

/* ---------- Tipografia ---------- */
/* Títulos em fonte de app (Inter); a fonte esportiva fica só para logo e números (.big-num, .num). */
.display { font-family: var(--body); font-weight: 800; font-size: 26px; line-height: 1.15; letter-spacing: -0.4px; }
.display-sm { font-family: var(--body); font-weight: 700; font-size: 17px; line-height: 1.25; letter-spacing: -0.2px; }
.num { font-family: var(--display); letter-spacing: 0; }
.mono { font-family: var(--mono); letter-spacing: .3px; }
.neon { color: var(--neon); }
.muted { color: var(--muted); }
.small { font-size: 12.5px; }
.center { text-align: center; }
.right { text-align: right; }
.clamp1, .clamp2, .clamp4 { display: -webkit-box; -webkit-box-orient: vertical; overflow: hidden; }
.clamp1 { -webkit-line-clamp: 1; } .clamp2 { -webkit-line-clamp: 2; } .clamp4 { -webkit-line-clamp: 4; }
.big-num { font-family: var(--display); font-size: 26px; line-height: 1; }

/* ---------- Layout ---------- */
.grow { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.row { display: flex; align-items: center; }
.row.gap { gap: 10px; } .gap-sm { gap: 8px; }
.row .grow { display: flex; }
.stack { display: flex; flex-direction: column; gap: 12px; }
.stack-sm { display: flex; flex-direction: column; gap: 8px; }
.pad { padding: 0 16px 8px; }
.pad-x { padding-left: 16px; padding-right: 16px; }
.section { padding: 18px 16px 4px; display: flex; flex-direction: column; gap: 8px; }
.section-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 2px; }
.section-head h2 { font-family: var(--body); font-size: 17px; letter-spacing: -0.2px; color: var(--text); font-weight: 700; }
.hero { padding: 14px 16px 6px; display: flex; flex-direction: column; gap: 4px; }
.hero .grow { gap: 2px; }
.hero-date { display: block; }
.hero-date::first-letter { text-transform: uppercase; }
.eyebrow { font-size: 12.5px; font-weight: 600; color: var(--muted); }

.demo-banner { background: var(--neon-dim); color: var(--neon); font-size: 10.5px; text-align: center; padding: 5px 8px; letter-spacing: .5px; }

/* ---------- Topbar ---------- */
.topbar { position: sticky; top: 0; z-index: 10; display: flex; align-items: center; gap: 8px; padding: 12px 12px; background: var(--glass); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); margin-bottom: 12px; }
.topbar-title { flex: 1; text-align: center; min-width: 0; }
.topbar-title h1 { font-family: var(--body); font-weight: 700; font-size: 17px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.topbar-spacer { width: 36px; }
.icon-btn { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; font-size: 18px; background: var(--bg-3); }

/* ---------- Botões ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 48px; padding: 0 18px; border-radius: 12px; font-family: var(--body); font-weight: 700; font-size: 15px; letter-spacing: 0; text-align: center; transition: transform .08s, opacity .15s; }
.btn:active { transform: scale(.97); }
.btn:disabled { opacity: .35; cursor: not-allowed; }
.btn-primary { background: var(--neon); color: var(--on-accent); box-shadow: 0 0 22px rgba(var(--accent-rgb), .28); }
.btn-ghost { border: 1px solid var(--line); background: var(--bg-2); color: var(--text); font-family: var(--body); font-weight: 600; text-transform: none; letter-spacing: 0; }
.btn-sm { min-height: 36px; padding: 0 12px; font-size: 13.5px; }
.btn-lg { min-height: 54px; font-size: 16px; }
.danger { color: var(--err); }
.link { color: var(--neon); font-weight: 600; font-size: 13px; }

/* ---------- Formulários ---------- */
.label { font-family: var(--body); font-size: 13px; font-weight: 600; color: var(--muted); margin-top: 4px; }
.input { width: 100%; background: var(--bg-2); border: 1px solid var(--line); border-radius: 12px; padding: 13px 14px; outline: none; font-size: 16px; }
.input:focus { border-color: var(--neon); box-shadow: 0 0 0 3px var(--neon-dim); }
.input-xl { font-size: 30px; padding: 12px 14px; font-weight: 700; }
.input-sm { padding: 8px 10px; font-size: 13px; width: auto; }
.input-inline { width: 90px; padding: 4px 8px; font-size: 13px; display: inline-block; }
textarea.input { resize: vertical; }
select.input { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 34px; }
.search-row { display: flex; gap: 8px; }
.search-row .btn { min-height: 50px; }
.toggle { display: flex; gap: 12px; align-items: flex-start; padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--bg-2); cursor: pointer; }
.toggle input { width: 20px; height: 20px; accent-color: var(--neon); margin-top: 2px; }
.opt { padding: 13px 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--bg-2); font-weight: 500; }
.opt.on { border-color: var(--neon); background: var(--neon-dim); color: var(--neon); }

.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { padding: 7px 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--bg-2); font-size: 13px; font-weight: 500; }
.chip-on { border-color: var(--neon); color: var(--neon); background: var(--neon-dim); }
.chip-soon { color: var(--muted); border-style: dashed; }
.soon { font-family: var(--mono); font-size: 9.5px; text-transform: uppercase; letter-spacing: .5px; background: var(--bg-3); padding: 1px 5px; border-radius: 5px; margin-left: 3px; }

/* Leitor de código de barras */
.scanner { position: relative; width: 100%; aspect-ratio: 4/3; border-radius: 14px; overflow: hidden; background: #000; }
.scanner video { width: 100%; height: 100%; object-fit: cover; }
.scanner-frame { position: absolute; left: 10%; right: 10%; top: 32%; bottom: 32%; border: 2px solid var(--neon); border-radius: 10px; box-shadow: 0 0 0 999px rgba(0,0,0,.45), 0 0 18px rgba(var(--accent-rgb), .5); }
.scanner-line { position: absolute; left: 6%; right: 6%; top: 50%; height: 2px; background: var(--neon); box-shadow: 0 0 10px var(--neon); animation: scanline 1.6s ease-in-out infinite alternate; }
@keyframes scanline { from { top: 12%; } to { top: 88%; } }
.seg { display: flex; background: var(--bg-2); border: 1px solid var(--line); border-radius: 12px; padding: 3px; gap: 3px; }
.seg-btn { flex: 1; padding: 9px 6px; border-radius: 9px; text-align: center; font-size: 13px; font-weight: 600; color: var(--muted); }
.seg-btn.on { background: var(--bg-3); color: var(--neon); }
.seg-sm .seg-btn { padding: 5px 8px; font-size: 11.5px; }
.tag { display: inline-block; font-size: 11.5px; padding: 3px 9px; border-radius: 999px; background: var(--bg-3); color: var(--tag-text); border: 1px solid var(--line); }
.tag-genre { color: var(--neon); border-color: rgba(var(--accent-rgb), .35); margin-top: 6px; }

/* ---------- Cartões ---------- */
.card { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; }
.neon-border { border-color: rgba(var(--accent-rgb), .45); box-shadow: inset 0 0 0 1px rgba(var(--accent-rgb), .08); }
.row-card { display: flex; align-items: center; gap: 12px; width: 100%; background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 12px; }
button.row-card:active { background: var(--bg-3); }

.cover { border-radius: 6px; object-fit: cover; flex-shrink: 0; background: var(--bg-3); box-shadow: 0 4px 14px rgba(0,0,0,var(--shadow-a)); }
.cover-sm { width: 44px; height: 64px; }
.cover-md { width: 100%; aspect-ratio: 2/3; height: auto; }
.cover-lg { width: 112px; height: 168px; }
.cover-gen { display: flex; flex-direction: column; justify-content: space-between; padding: 8px 7px; border-left: 4px solid rgba(0,0,0,.35); overflow: hidden; }
.cover-title { font-family: var(--display); font-size: 11px; line-height: 1.1; text-transform: uppercase; color: #fff; word-break: break-word; }
.cover-sm .cover-title { font-size: 7.5px; }
.cover-lg .cover-title { font-size: 15px; }
.cover-author { font-size: 9.5px; color: rgba(255,255,255,.65); }

.stars { display: inline-flex; align-items: center; gap: 5px; }
.stars-bg { position: relative; color: var(--star-off); letter-spacing: 1px; line-height: 1; }
.stars-fg { position: absolute; left: 0; top: 0; overflow: hidden; white-space: nowrap; color: var(--neon); }
.stars-num { font-family: var(--mono); font-size: 13px; }
.star-input { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px 0; }
.star-btn { font-size: 42px; color: var(--star-off); padding: 0 3px; transition: transform .1s, color .1s; }
.star-btn.on { color: var(--neon); text-shadow: 0 0 14px rgba(var(--accent-rgb), .5); }
.star-btn:active { transform: scale(1.2); }

.progress { height: 8px; background: var(--bg-3); border-radius: 99px; overflow: hidden; margin-top: 4px; }
.progress.thin { height: 4px; }
.progress > div { height: 100%; background: var(--neon); box-shadow: 0 0 10px var(--neon); border-radius: 99px; transition: width .4s; }

.live-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--neon); box-shadow: 0 0 8px var(--neon); animation: pulse 1.4s infinite; vertical-align: middle; }
@keyframes pulse { 50% { opacity: .35; } }

/* ---------- Home ---------- */
.timer-banner { margin: 6px 16px 0; display: flex; align-items: center; gap: 8px; width: calc(100% - 32px); padding: 12px 14px; border-radius: 12px; background: var(--neon-dim); border: 1px solid rgba(var(--accent-rgb), .4); color: var(--neon); }
.alert-card { margin: 10px 16px 0; display: flex; align-items: center; gap: 12px; width: calc(100% - 32px); padding: 12px 14px; border-radius: 14px; background: var(--tint-gold-soft); border: 1px solid rgba(var(--warn-rgb), .35); }
.alert-icon { font-size: 22px; }
.ch-card { display: flex; flex-direction: column; gap: 8px; width: 100%; padding: 16px; border-radius: 18px; background: linear-gradient(160deg, var(--tint-accent) 0%, var(--bg-2) 60%); border: 1px solid rgba(var(--accent-rgb), .3); }
.ch-card-top { display: flex; justify-content: space-between; gap: 8px; }
.ch-card-pos { display: flex; justify-content: space-between; align-items: flex-end; }

/* ---------- Desafios ---------- */
.ch-row { display: flex; align-items: center; gap: 12px; width: 100%; padding: 14px; background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius); }
.ch-emoji { font-size: 26px; width: 40px; height: 40px; display: grid; place-items: center; background: var(--bg-3); border-radius: 10px; }
.dim { opacity: .5; }
.ch-meta { display: flex; flex-direction: column; gap: 3px; margin-top: -4px; }
.steps { display: flex; gap: 6px; padding: 0 16px 12px; }
.steps span { flex: 1; height: 4px; border-radius: 4px; background: var(--bg-3); }
.steps span.on { background: var(--neon); box-shadow: 0 0 8px rgba(var(--accent-rgb), .5); }
.type-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.type-card { display: flex; flex-direction: column; gap: 4px; padding: 12px; border-radius: 14px; border: 1px solid var(--line); background: var(--bg-2); }
.type-card.on { border-color: var(--neon); background: var(--neon-dim); }
.type-card.on b { color: var(--neon); }
.type-emoji { font-size: 24px; }
.code-box { font-size: 36px; font-weight: 700; letter-spacing: 8px; color: var(--neon); padding: 16px; border: 2px dashed rgba(var(--accent-rgb), .5); border-radius: 14px; text-align: center; text-shadow: 0 0 16px rgba(var(--accent-rgb), .5); }
.rules { margin: 0; padding-left: 0; list-style: none; display: flex; flex-direction: column; gap: 7px; }
.teams { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 6px; }
.team { padding: 12px; border-radius: 14px; background: var(--bg-2); border: 1px solid var(--line); display: flex; flex-direction: column; gap: 4px; }
.team.lead { border-color: var(--neon); background: var(--neon-dim); }
.rank-row { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 14px; background: var(--bg-2); border: 1px solid var(--line); }
.rank-row.me { border-color: var(--neon); background: var(--neon-dim); box-shadow: 0 0 18px rgba(var(--accent-rgb), .15); }
.rank-row.me b { color: var(--neon); }
.rank-pos { width: 28px; text-align: center; font-weight: 700; font-size: 15px; color: var(--muted); }
.rank-score { font-family: var(--display); font-size: 20px; }
.team-tag { font-size: 10px; font-family: var(--mono); padding: 1px 6px; border-radius: 6px; background: var(--bg-3); color: var(--muted); font-weight: 500; }
.avatar { border-radius: 50%; display: inline-grid; place-items: center; font-weight: 700; color: #fff; flex-shrink: 0; }
.avatar-me { background: var(--neon); color: var(--on-accent); }

.log-item { padding: 12px; border-radius: 14px; background: var(--bg-2); border: 1px solid var(--line); display: flex; flex-direction: column; gap: 10px; }
.log-photo { width: 100%; max-height: 160px; object-fit: cover; border-radius: 10px; cursor: zoom-in; }
.log-photo.zoom { max-height: none; cursor: zoom-out; }
.log-foot { flex-wrap: wrap; }
.status { font-size: 11.5px; font-family: var(--mono); padding: 3px 8px; border-radius: 6px; background: var(--bg-3); color: var(--muted); }
.status-verificado { color: var(--neon); background: var(--neon-dim); }
.status-contestado { color: var(--warn); background: rgba(var(--warn-rgb), .12); }
.status-invalido { color: var(--err); background: rgba(var(--err-rgb), .12); }
.vote { padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--bg-3); font-size: 13px; font-weight: 600; }
.vote.on { border-color: var(--neon); color: var(--neon); background: var(--neon-dim); }
.vote-flag.on { border-color: var(--err); color: var(--err); background: rgba(var(--err-rgb), .12); }

/* ---------- Registrar ---------- */
.page-input { display: flex; flex-direction: column; gap: 8px; }
.timer-run { display: flex; align-items: center; gap: 8px; white-space: nowrap; color: var(--neon); }
.photo-drop { display: block; padding: 18px; text-align: center; border: 1.5px dashed var(--line); border-radius: 12px; color: var(--muted); cursor: pointer; }
.photo-drop.required { border-color: var(--neon); color: var(--neon); }
.photo-prev { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.photo-prev img { width: 100%; max-height: 220px; object-fit: cover; border-radius: 12px; }
.msg { font-size: 13px; padding: 10px 12px; border-radius: 10px; }
.msg-warn { background: rgba(var(--warn-rgb), .1); color: var(--warn); }
.msg-err { background: rgba(var(--err-rgb), .1); color: var(--err); }
.rules-box { background: var(--bg-2); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; }
.rules-box summary { cursor: pointer; color: var(--neon); }
.rules-box ul { margin: 8px 0 0; padding-left: 18px; display: flex; flex-direction: column; gap: 4px; }
.done-view { padding: 24px 16px; display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; }
.done-burst { font-size: 56px; width: 100px; height: 100px; border-radius: 50%; display: grid; place-items: center; background: var(--neon-dim); border: 2px solid var(--neon); box-shadow: 0 0 40px rgba(var(--accent-rgb), .35); color: var(--neon); margin: 0 auto; }
.done-view .card { text-align: left; width: 100%; }

/* ---------- Comunidade ---------- */
.genre-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.genre-card { display: flex; flex-direction: column; gap: 3px; padding: 12px; border-radius: 14px; background: var(--bg-2); border: 1px solid var(--line); }
.genre-card b { font-size: 13.5px; line-height: 1.2; }
.genre-emoji { font-size: 22px; }
.genre-hero { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.genre-emoji-xl { font-size: 54px; }
.book-hero { display: flex; gap: 16px; padding: 4px 16px 12px; align-items: flex-start; }
.book-title { font-family: var(--body); font-weight: 800; font-size: 20px; line-height: 1.2; letter-spacing: -0.3px; }
.rating-box { margin: 4px 16px 12px; padding: 14px; border-radius: 16px; background: var(--bg-2); border: 1px solid var(--line); display: flex; gap: 16px; align-items: center; }
.rating-big { display: flex; flex-direction: column; align-items: center; gap: 4px; min-width: 92px; }
.rating-big .big-num { font-size: 40px; color: var(--neon); }
.dist { flex: 1; display: flex; flex-direction: column; gap: 4px; }
.dist-row { display: flex; align-items: center; gap: 8px; }
.dist-bar { flex: 1; height: 7px; background: var(--bg-3); border-radius: 9px; overflow: hidden; }
.dist-bar > div { height: 100%; background: var(--neon); border-radius: 9px; }
.book-actions { display: flex; gap: 8px; }
.book-actions .btn { flex: 1; padding: 0 6px; }
.friend-read { padding: 6px 0; }
.review { padding: 14px; border-radius: 14px; background: var(--bg-2); border: 1px solid var(--line); display: flex; flex-direction: column; gap: 10px; }
.review-text { white-space: pre-wrap; font-size: 14.5px; }
.review-text.spoiler { filter: blur(6px); user-select: none; cursor: pointer; }
.badge-proven { display: inline-block; margin-left: 6px; font-size: 10.5px; font-family: var(--mono); color: var(--neon); background: var(--neon-dim); padding: 1px 6px; border-radius: 6px; vertical-align: middle; }

/* ---------- Perfil / Onboarding ---------- */
.profile-head { display: flex; align-items: center; gap: 14px; padding: 4px 16px 10px; }
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; padding: 0 16px; }
.stat { background: var(--bg-2); border: 1px solid var(--line); border-radius: 12px; padding: 10px 6px; display: flex; flex-direction: column; align-items: center; }
.stat b { font-family: var(--display); font-size: 20px; }
.stat span { font-size: 11px; color: var(--muted); }
.shelf-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.shelf-item { display: flex; flex-direction: column; gap: 6px; width: 100%; }
.shelf-cell { position: relative; }
.shelf-more { position: absolute; top: 4px; right: 4px; width: 30px; height: 30px; border-radius: 50%; background: var(--glass); border: 1px solid var(--line); color: var(--text); font-size: 16px; line-height: 1; }
.btn-danger { background: transparent; border: 1px solid var(--err); color: var(--err); }
.on-shelf { display: flex; align-items: center; gap: 8px; }
.onboarding { padding: 40px 20px 20px; display: flex; flex-direction: column; gap: 28px; }
.logo-big { display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; }
.logo-big img { filter: drop-shadow(0 0 24px rgba(var(--accent-rgb), .35)); }
.logo-big .display { font-family: var(--display); font-weight: 400; font-size: 38px; text-transform: uppercase; letter-spacing: -0.5px; }
.pitch { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.pitch li { display: flex; flex-direction: column; padding: 12px 14px; background: var(--bg-2); border: 1px solid var(--line); border-radius: 12px; }
.pitch span { color: var(--muted); font-size: 13px; }

/* ---------- Diversos ---------- */
.empty { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px; padding: 22px 12px; border: 1px dashed var(--line); border-radius: var(--radius); }
.empty-icon { font-size: 34px; }
.spinner-wrap { display: grid; place-items: center; padding: 40px; }
.spinner { width: 28px; height: 28px; border: 3px solid var(--bg-3); border-top-color: var(--neon); border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.modal-bg { position: fixed; inset: 0; background: rgba(0,0,0,.7); z-index: 50; display: flex; align-items: flex-end; justify-content: center; }
.modal { width: 100%; max-width: 430px; background: var(--bg-2); border-top: 1px solid var(--line); border-radius: 20px 20px 0 0; padding: 16px 16px 28px; animation: up .2s ease-out; }
@keyframes up { from { transform: translateY(40px); opacity: 0; } }
.modal-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.modal-head h2 { font-family: var(--body); font-weight: 700; font-size: 17px; }
.toasts { position: fixed; left: 50%; transform: translateX(-50%); bottom: 96px; z-index: 60; display: flex; flex-direction: column; gap: 6px; width: min(400px, calc(100% - 32px)); pointer-events: none; }
.toast { padding: 12px 14px; border-radius: 12px; background: var(--tint-accent); border: 1px solid rgba(var(--accent-rgb), .4); color: var(--text); font-size: 14px; animation: up .2s ease-out; box-shadow: 0 8px 30px rgba(0,0,0,var(--shadow-a)); }
.toast-err { background: var(--tint-err); border-color: rgba(var(--err-rgb), .5); }

/* ---------- Barra de abas ---------- */
.tabbar { position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); width: 100%; max-width: 430px; z-index: 20; display: flex; align-items: center; justify-content: space-around; padding: 8px 6px calc(10px + env(safe-area-inset-bottom)); background: var(--glass); backdrop-filter: blur(12px); border-top: 1px solid var(--line); }
.tab { display: flex; flex-direction: column; align-items: center; gap: 2px; width: 64px; color: var(--muted); }
.tab.active { color: var(--neon); }
.tab-icon { display: grid; place-items: center; height: 24px; }
.tab-label { font-size: 10.5px; font-weight: 600; }
.tab-big .tab-icon { width: 52px; height: 52px; border-radius: 16px; background: var(--neon); color: var(--on-accent); display: grid; place-items: center; margin-top: -22px; box-shadow: 0 0 20px rgba(var(--accent-rgb), .35); }

/* ---------- Corrente / Meu treino ---------- */
.hero-row { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.tagline { font-family: var(--body); font-weight: 600; font-size: 17px; line-height: 1.35; color: var(--text); }
.tagline-sm { font-size: 13px; color: var(--muted); font-weight: 500; }
.training-card { display: flex; flex-direction: column; gap: 6px; width: 100%; padding: 12px 14px; border-radius: 16px; background: var(--bg-2); border: 1px solid var(--line); }
.training-icon { font-size: 24px; }
.today-goal { padding: 16px; border-radius: 18px; background: linear-gradient(160deg, var(--tint-accent), var(--bg-2) 70%); border: 1px solid rgba(var(--accent-rgb), .3); display: flex; flex-direction: column; gap: 8px; }
.today-goal-num b { font-family: var(--display); font-size: 36px; line-height: 1; }
.stat-grid.three { grid-template-columns: repeat(3, 1fr); padding: 0; }
.after-log { width: 100%; text-align: left; }
.history-row { padding: 8px 0; border-bottom: 1px solid var(--line); }
.history-date { width: 52px; flex-shrink: 0; }
.tag-solo { color: var(--warn); border-color: rgba(var(--warn-rgb), .35); }

/* Gráfico de barras: série única, barras finas, topo arredondado na base, meta tracejada */
.chart { display: flex; flex-direction: column; gap: 6px; }
.chart-readout { min-height: 18px; }
.chart-plot { position: relative; height: 150px; display: flex; align-items: flex-end; gap: 2px; border-bottom: 1px solid var(--line); }
.chart-goal { position: absolute; left: 0; right: 0; border-top: 1px dashed rgba(var(--text-rgb), .35); pointer-events: none; }
.chart-goal span { position: absolute; right: 0; top: -16px; font-family: var(--mono); font-size: 10px; color: var(--muted); background: var(--bg); padding: 0 4px; }
.bar { flex: 1; height: 100%; display: flex; align-items: flex-end; justify-content: center; cursor: pointer; }
.bar-fill { width: 70%; max-width: 26px; border-radius: 4px 4px 0 0; background: rgba(var(--accent-rgb), .35); transition: background .15s; }
.bar.hit .bar-fill { background: var(--neon); }
.bar.sel .bar-fill, .bar:hover .bar-fill { box-shadow: 0 0 0 2px var(--bg), 0 0 0 3px var(--text); }
.chart-x { display: flex; gap: 2px; }
.chart-x span { flex: 1; text-align: center; font-size: 10px; color: var(--muted); }

/* ---------- Desafios: chamada para criar ---------- */
.create-cta { display: flex; align-items: center; gap: 14px; width: 100%; padding: 18px 16px; border-radius: 20px; background: linear-gradient(150deg, var(--tint-accent-strong) 0%, var(--tint-accent) 55%, var(--bg-2) 100%); border: 1.5px solid var(--neon); box-shadow: 0 0 28px rgba(var(--accent-rgb), .18); }
.create-cta-icon { font-size: 38px; }
.create-cta .display-sm { color: var(--neon); }
.create-cta-types { margin-top: 6px; }
.create-cta-types .tag { font-size: 10.5px; padding: 2px 7px; }
.create-cta-arrow { font-size: 24px; color: var(--neon); }
/* "Comece a ler" (tela inicial) e sessão de leitura com cronômetro */
.start-card { display: flex; align-items: center; gap: 14px; width: 100%; padding: 16px; border-radius: 20px; background: var(--neon); color: var(--on-accent); box-shadow: 0 0 26px rgba(var(--accent-rgb), .25); }
.start-card .display-sm { color: var(--on-accent); }
.start-card .muted { color: var(--on-accent); opacity: .75; }
.start-icon { width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center; font-size: 22px; background: rgba(0,0,0,.14); flex-shrink: 0; }
.start-cta { font-family: var(--mono); font-weight: 700; font-size: 12px; letter-spacing: .06em; }
.start-card.live { background: var(--tint-accent); color: var(--text); border: 1.5px solid var(--neon); }
.start-card.live .start-icon { background: var(--neon-dim); color: var(--neon); }
.start-card.live .start-cta, .start-card.live .mono { color: var(--neon); }
.start-card.live .muted { color: var(--muted); opacity: 1; }
.start-clock { display: block; font-size: 26px; line-height: 1.1; color: var(--text); }
[data-theme="claro"] .start-card { box-shadow: 0 2px 10px rgba(0,0,0,.1); }
.session { display: flex; flex-direction: column; align-items: stretch; gap: 14px; padding: 8px 20px 24px; }
.session-book { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; }
.session-clock { font-family: var(--mono); font-weight: 700; font-size: 64px; line-height: 1; text-align: center; color: var(--neon); margin: 10px 0 0; font-variant-numeric: tabular-nums; }
.session-clock.paused { color: var(--muted); }
.pick-main { display: flex; flex-direction: column; gap: 2px; text-align: left; }
.msg-ok { background: var(--neon-dim); color: var(--neon); }

/* ---------- Tela inicial: painel do dia ---------- */
.icon { display: inline-block; vertical-align: middle; flex-shrink: 0; }
.home-head { display: flex; align-items: center; gap: 12px; padding: 16px 16px 12px; }
.home-head .display { font-size: 24px; }
.avatar-btn { border-radius: 50%; }
.today-card { display: flex; flex-direction: column; gap: 12px; padding: 16px; border-radius: 20px; background: var(--bg-2); border: 1px solid var(--line); }
.today-metrics { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.today-metrics > * { display: flex; flex-direction: column; gap: 4px; text-align: left; }
.today-metrics .eyebrow { display: inline-flex; align-items: center; gap: 4px; }
.today-num { font-family: var(--display); font-size: 30px; line-height: 1; font-weight: 400; }
.today-num small { font-family: var(--body); font-size: 13px; font-weight: 600; color: var(--muted); }
.today-goal-btn .progress { margin-top: 4px; }
.today-status { font-size: 13.5px; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.today-status.ok { color: var(--neon); }
.today-status.warn { color: var(--text); }
.today-cta { width: 100%; }
.today-cta.live { background: var(--tint-accent); color: var(--neon); border: 1.5px solid var(--neon); box-shadow: none; }
.list { display: flex; flex-direction: column; border-radius: var(--radius); background: var(--bg-2); border: 1px solid var(--line); overflow: hidden; }
.list-row { display: flex; align-items: center; gap: 12px; width: 100%; padding: 10px 14px; min-height: 56px; text-align: left; color: var(--text); background: var(--bg-2); }
.list > .list-row + .list-row { border-top: 1px solid var(--line); }
.pad > .list-row, .section > .list-row { border: 1px solid var(--line); border-radius: var(--radius); }
.list-row.soft { background: var(--tint-gold-soft); border-color: rgba(var(--warn-rgb), .3); }
.list-row .grow b { font-weight: 600; }
.list-icon { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: var(--bg-3); color: var(--neon); flex-shrink: 0; }
.list-icon.premium-icon { background: rgba(var(--gold-rgb), .16); }
.list-row .premium-badge { margin-left: 4px; }
.list-row.soft .list-icon { background: rgba(var(--warn-rgb), .14); color: var(--warn); }
.grow-btn { flex: 1; min-width: 0; text-align: left; color: var(--text); }
.round-btn { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: var(--neon); color: var(--on-accent); flex-shrink: 0; }
.pos { display: flex; flex-direction: column; align-items: flex-end; line-height: 1.1; }
.pos b { font-size: 20px; }
.pos small { font-size: 11px; color: var(--muted); }
.muted.icon, .icon.muted { color: var(--muted); }

/* Conversa do livro */
.spoiler-info { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: var(--radius); background: var(--tint-accent); color: var(--text); }
.spoiler-info .icon { color: var(--neon); }
.composer { display: flex; flex-direction: column; gap: 8px; padding: 12px; border-radius: var(--radius); background: var(--bg-2); border: 1px solid var(--line); }
.composer.reply { margin-top: 8px; padding: 10px; background: var(--bg-3); }
.composer-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.page-tag { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: var(--muted); }
.page-tag input { width: 70px; padding: 6px 8px; border-radius: 8px; border: 1px solid var(--line); background: var(--bg-3); color: var(--text); font: inherit; }
.comment { display: flex; gap: 10px; padding: 12px; border-radius: var(--radius); background: var(--bg-2); border: 1px solid var(--line); }
.comment.is-reply { padding: 10px 0 0; border: 0; border-top: 1px solid var(--line); border-radius: 0; margin-top: 10px; background: transparent; }
.comment-head { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.page-chip { font-size: 11.5px; font-weight: 700; color: var(--neon); background: var(--neon-dim); padding: 1px 7px; border-radius: 999px; }
.comment-text { white-space: pre-wrap; line-height: 1.45; margin-top: 2px; }
.comment-actions { display: flex; gap: 14px; margin-top: 6px; }
.c-act { font-size: 13px; font-weight: 600; color: var(--muted); }
.c-act.on { color: var(--err); }
.c-act:disabled { opacity: .6; }
.spoiler-lock { display: inline-flex; align-items: center; gap: 6px; margin-top: 4px; padding: 8px 10px; border-radius: 10px; background: var(--bg-3); color: var(--muted); font-size: 13px; text-align: left; }
.locked-box { display: flex; flex-direction: column; gap: 4px; align-items: flex-start; padding: 14px; border-radius: var(--radius); border: 1.5px dashed var(--line); background: var(--bg-2); }

/* Enviar sugestão */
.feedback-types { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.feedback-type { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 6px; border-radius: var(--radius); border: 1.5px solid var(--line); background: var(--bg-2); font-size: 13px; font-weight: 600; color: var(--text); text-align: center; }
.feedback-type.on { border-color: var(--neon); background: var(--neon-dim); }
.feedback-emoji { font-size: 24px; }

/* Anotações de leitura */
.last-note { display: flex; flex-direction: column; gap: 6px; padding: 12px 14px; border-radius: var(--radius); background: var(--tint-accent); border-left: 3px solid var(--neon); }
.last-note p { font-size: 15px; line-height: 1.45; font-style: italic; }
.note-item { display: flex; flex-direction: column; gap: 4px; padding: 12px 14px; }
.note-item + .note-item { border-top: 1px solid var(--line); }
.note-item p { white-space: pre-wrap; line-height: 1.45; }
.note-meta { display: flex; justify-content: space-between; align-items: center; gap: 8px; }

/* Configurações: grupos e listas no estilo dos apps de celular */
.settings-group { display: flex; flex-direction: column; gap: 14px; padding: 14px; border-radius: var(--radius); background: var(--bg-2); border: 1px solid var(--line); }
.field { display: flex; flex-direction: column; gap: 6px; }
.field-label { font-size: 13px; font-weight: 600; color: var(--text); }
.field-hint { font-size: 12px; color: var(--muted); }
.input-readonly { display: flex; align-items: center; flex: 1; background: var(--bg-3); color: var(--muted); }
.settings-list { display: flex; flex-direction: column; border-radius: var(--radius); background: var(--bg-2); border: 1px solid var(--line); overflow: hidden; }
.settings-row { display: flex; align-items: center; gap: 12px; width: 100%; padding: 12px 14px; min-height: 52px; text-align: left; color: var(--text); }
.settings-row + .settings-row { border-top: 1px solid var(--line); }
.settings-row .grow b { font-weight: 600; font-size: 15px; }
.settings-row.danger b { color: var(--err); }
.theme-mini { position: relative; width: 34px; height: 34px; border-radius: 9px; border: 1px solid rgba(128,128,128,.35); flex-shrink: 0; overflow: hidden; }
.theme-mini span { position: absolute; right: 6px; bottom: 6px; width: 10px; height: 10px; border-radius: 50%; }
.radio { width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--line); flex-shrink: 0; }
.radio.on { border-color: var(--neon); box-shadow: inset 0 0 0 5px var(--bg-2), inset 0 0 0 12px var(--neon); }
.settings-foot { padding: 18px 0 8px; }
.theme-pick { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.theme-pick-opt { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 10px 6px; border-radius: 12px; border: 1.5px solid var(--line); background: var(--bg-2); font-size: 13.5px; font-weight: 600; color: var(--text); }
.theme-pick-opt.on { border-color: var(--neon); background: var(--neon-dim); }
.theme-pick-opt .theme-mini { width: 100%; height: 30px; }
.profile-about .chips { gap: 6px; }

/* Escolha de tema (Perfil > Aparência) */
.theme-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.theme-opt { display: flex; flex-direction: column; gap: 4px; padding: 12px; border-radius: var(--radius); background: var(--bg-2); border: 1.5px solid var(--line); }
.theme-opt.on { border-color: var(--neon); background: var(--neon-dim); }
.theme-swatch { position: relative; width: 100%; height: 44px; border-radius: 10px; border: 1px solid rgba(128,128,128,.35); margin-bottom: 4px; }
.theme-dot { position: absolute; right: 10px; top: 50%; width: 18px; height: 18px; margin-top: -9px; border-radius: 50%; }

/* Aviso de navegador interno (Instagram/Facebook/TikTok) na tela de entrada */
.inapp-warning { display: flex; flex-direction: column; gap: 8px; border-color: var(--gold); background: var(--tint-gold-soft); text-align: left; }
.inapp-warning b { color: var(--gold); }
.inapp-warning a.btn { text-align: center; text-decoration: none; }

/* Bloco Premium "Crie suas regras": dourado para diferenciar do grátis */
.premium-cta { background: linear-gradient(150deg, var(--tint-gold) 0%, var(--tint-gold-soft) 55%, var(--bg-2) 100%); border-color: var(--gold); box-shadow: 0 0 24px rgba(var(--gold-rgb), .14); }
.premium-cta .display-sm, .premium-cta .create-cta-arrow { color: var(--gold); }
.premium-badge { display: inline-block; vertical-align: middle; margin-left: 6px; padding: 2px 7px; border-radius: 999px; background: var(--gold); color: var(--on-gold); font: 700 10px/1.4 'JetBrains Mono', monospace; letter-spacing: .06em; }
.rule-row { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 14px; background: var(--bg-2); border: 1px solid var(--line); }
.rule-row b, .example-card b { display: block; }
.rule-icon { font-size: 20px; width: 26px; text-align: center; }
.example-card { display: flex; flex-direction: column; gap: 4px; border-color: rgba(var(--gold-rgb), .33); }

/* ---------- Acervo / resumo ---------- */
.carousel { display: flex; gap: 12px; overflow-x: auto; padding-bottom: 6px; scroll-snap-type: x mandatory; margin: 0 -16px; padding-left: 16px; padding-right: 16px; }
.carousel-item { flex: 0 0 104px; display: flex; flex-direction: column; gap: 5px; scroll-snap-align: start; }
.resumo { display: flex; flex-direction: column; gap: 10px; padding: 14px; border-radius: 16px; background: var(--bg-2); border: 1px solid rgba(var(--accent-rgb), .3); }
.resumo > p:first-child { font-size: 15px; line-height: 1.55; }
.resumo-meta { display: flex; flex-wrap: wrap; gap: 6px; }
.tag-tema { color: var(--neon); background: transparent; border-color: rgba(var(--accent-rgb), .25); }
.synopsis { white-space: pre-line; }
/* ---------- Corrente: 1 elo = 1 dia seguido lendo ---------- */
.chain-badge { display: flex; flex-direction: column; align-items: center; justify-content: center; min-width: 70px; height: 74px; border-radius: 18px; background: var(--bg-2); border: 1px solid var(--line); flex-shrink: 0; gap: 1px; }
.chain-badge span { font-size: 20px; line-height: 1; filter: grayscale(1) opacity(.5); }
.chain-badge b { font-family: var(--display); font-size: 22px; line-height: 1.05; color: var(--muted); }
.chain-badge small { font-family: var(--mono); font-size: 9.5px; text-transform: uppercase; letter-spacing: .5px; color: var(--muted); }
.chain-badge.lit { border-color: rgba(var(--accent-rgb), .55); background: linear-gradient(160deg, var(--tint-accent-strong), var(--tint-accent)); box-shadow: 0 0 22px rgba(var(--accent-rgb), .18); }
.chain-badge.lit span { filter: none; }
.chain-badge.lit b, .chain-badge.lit small { color: var(--neon); }
.chain-badge.risk { border-color: rgba(var(--warn-rgb), .6); box-shadow: 0 0 18px rgba(var(--warn-rgb), .15); }
.corrente { padding: 14px; border-radius: 18px; background: var(--bg-2); border: 1px solid var(--line); display: flex; flex-direction: column; gap: 12px; }
.corrente.risk { border-color: rgba(var(--warn-rgb), .45); background: linear-gradient(160deg, var(--tint-warn), var(--bg-2) 70%); }
.corrente-num { font-family: var(--body); font-weight: 700; font-size: 17px; line-height: 1.25; }
.corrente-warn { display: flex; flex-direction: column; gap: 8px; }
.corrente-warn .btn { align-self: flex-start; }
.chain-icon { font-size: 28px; filter: grayscale(1) opacity(.5); }
.chain-icon.lit { filter: drop-shadow(0 0 8px rgba(var(--accent-rgb), .55)); }
.chain-tag { display: inline-block; font-family: var(--mono); font-size: 10.5px; font-weight: 700; color: var(--neon); background: var(--neon-dim); padding: 1px 6px; border-radius: 6px; vertical-align: middle; white-space: nowrap; }

/* Semana como corrente: cada dia lido é um elo (anel); dias seguidos ficam ligados por uma haste */
/* A Corrente: os últimos 7 dias como elos de corrente (oval vazado); dias seguidos ficam ligados */
.week-chain { display: grid; grid-template-columns: repeat(7, 1fr); padding: 4px 0 2px; }
.wc { position: relative; display: flex; flex-direction: column; align-items: center; gap: 7px; }
.wc-link { position: relative; z-index: 1; width: 34px; height: 22px; border-radius: 11px; border: 3.5px solid var(--line); background: var(--bg-2); }
.wc.on .wc-link { border-color: var(--neon); box-shadow: 0 0 8px rgba(var(--accent-rgb), .35); }
.wc.linked::before { content: ''; position: absolute; top: 9.5px; right: calc(50% + 14px); width: calc(100% - 28px); height: 3.5px; border-radius: 2px; background: var(--neon); z-index: 0; }
.wc.today .wc-link { border-style: dashed; border-color: var(--neon); }
.wc.today.on .wc-link { border-style: solid; background: var(--neon-dim); }
.wc-label { font-size: 11px; font-weight: 600; color: var(--muted); }
.wc.today .wc-label { color: var(--neon); }
[data-theme="claro"] .wc.on .wc-link { box-shadow: none; }
/* =====================================================================
   NOVIDADES (novembro): menu lateral, barra nova, Buscar livros, estante com pastas,
   página do livro por status, gráfico de Minha leitura, mini perfil do desafio
   ===================================================================== */
body.no-scroll { overflow: hidden; }

/* botão ▶ do meio da barra */
.tab-big { width: 64px; }
.tab-big .tab-icon { margin-top: -18px; width: 56px; height: 56px; border-radius: 50%; box-shadow: 0 6px 18px -4px rgba(var(--accent-rgb), .55); }
.tab-big.live .tab-icon { animation: pulse-live 1.8s ease-in-out infinite; }
@keyframes pulse-live { 50% { box-shadow: 0 0 0 8px rgba(var(--accent-rgb), .12), 0 6px 18px -4px rgba(var(--accent-rgb), .55); } }

/* foto que abre o menu */
.menu-btn { position: relative; flex-shrink: 0; }
.menu-badge { position: absolute; right: -3px; bottom: -3px; width: 19px; height: 19px; border-radius: 50%; display: grid; place-items: center;
  background: var(--bg-2); color: var(--text); border: 1px solid var(--line); box-shadow: 0 1px 3px rgba(0,0,0,.15); }

/* menu lateral */
.drawer-wrap { position: fixed; inset: 0; z-index: 60; pointer-events: none; }
.drawer-wrap.open { pointer-events: auto; }
.drawer-scrim { position: absolute; inset: 0; background: rgba(0, 0, 0, .45); opacity: 0; transition: opacity .25s; }
.drawer-wrap.open .drawer-scrim { opacity: 1; }
.drawer { position: absolute; top: 0; bottom: 0; left: max(0px, calc(50% - 215px)); width: min(86%, 360px); background: var(--bg-2);
  border-right: 1px solid var(--line); transform: translateX(-105%); transition: transform .28s cubic-bezier(.2, .8, .2, 1);
  overflow-y: auto; padding: calc(env(safe-area-inset-top) + 8px) 0 calc(env(safe-area-inset-bottom) + 18px); box-shadow: 8px 0 30px rgba(0,0,0,.18); }
.drawer-wrap.open .drawer { transform: none; }
.dm-head { display: flex; align-items: flex-start; gap: 6px; padding: 12px 10px 12px 16px; }
.dm-me { display: flex; align-items: center; gap: 12px; flex: 1; min-width: 0; text-align: left; }
.dm-me b { display: block; font-size: 17px; }
.dm-me .small { display: block; }
.dm-elos { display: inline-flex; align-items: center; gap: 4px; color: var(--neon); font-weight: 700; font-size: 13px; margin-top: 2px; }
.dm-banner { display: flex; align-items: center; gap: 12px; margin: 4px 14px 10px; padding: 12px; width: calc(100% - 28px); text-align: left; border-radius: 14px;
  background: linear-gradient(120deg, #0B3D2A, #00994F); color: #fff; }
.dm-banner b { display: block; font-size: 14px; color: #fff; }
.dm-banner .small { opacity: .85; }
.dm-banner-eyebrow { display: block; font-size: 10.5px; text-transform: uppercase; letter-spacing: .07em; opacity: .8; font-weight: 600; }
.dm-premium { display: flex; align-items: center; gap: 10px; margin: 0 14px 4px; padding: 11px 12px; width: calc(100% - 28px); border-radius: 12px;
  background: var(--tint-gold-soft); color: var(--gold); font-weight: 700; border: 1px solid rgba(var(--gold-rgb), .25); }
.dm-label { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 700; padding: 16px 18px 4px; }
.dm-item { display: flex; align-items: center; gap: 12px; width: 100%; padding: 9px 18px; text-align: left; font-weight: 500; color: var(--text); }
.dm-item:hover, .dm-item:focus-visible { background: var(--bg-3); }
.dm-icon { width: 32px; height: 32px; border-radius: 9px; display: grid; place-items: center; background: var(--bg-3); color: var(--neon); flex-shrink: 0; }
.dm-right { font-size: 12px; color: var(--muted); font-weight: 600; }
.dm-sep { height: 1px; background: var(--line); margin: 14px 18px 6px; }
.dm-foot { padding: 14px 18px 0; }
.dm-note { display: flex; gap: 6px; align-items: flex-start; background: var(--bg-3); padding: 10px 12px; border-radius: 10px; }

/* Buscar livros */
.genre-chips { margin: 4px 0 2px; }
.chips.nowrap { flex-wrap: nowrap; overflow-x: auto; margin: 0 -16px; padding: 2px 16px 6px; scrollbar-width: none; }
.chips.nowrap::-webkit-scrollbar { display: none; }
.chips.nowrap .chip { white-space: nowrap; }
.typo-hint { background: var(--tint-accent); color: var(--text); padding: 8px 12px; border-radius: 10px; }
.list-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.list-card { min-height: 92px; border-radius: 14px; padding: 12px; color: #fff; display: flex; flex-direction: column; justify-content: space-between; text-align: left;
  box-shadow: inset 0 -40px 40px -30px rgba(0,0,0,.25); }
.list-card b { font-size: 14.5px; line-height: 1.2; color: #fff; }
.list-card span { font-size: 12px; opacity: .85; }
.list-card.wide { min-height: 78px; }
.book-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px 10px; }
.book-grid-item { display: flex; flex-direction: column; gap: 5px; text-align: left; min-width: 0; }
.book-grid-item b { font-weight: 600; }
.star-1 { color: var(--gold); }

/* página do livro */
.status-seg { margin-top: 6px; }
.status-seg .seg-btn { font-size: 12.5px; padding: 9px 2px; }
[data-theme="claro"] .status-seg .seg-btn.on { background: var(--neon); color: var(--on-accent); }
.status-hint { display: flex; gap: 6px; align-items: center; margin-top: 10px; }
.my-rating { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; }
.buy-btn { width: 100%; justify-content: center; gap: 8px; display: flex; align-items: center; text-decoration: none; }
.buy-note { margin-top: 6px; }

/* estante e pastas */
.folder-row { display: flex; gap: 10px; overflow-x: auto; margin: 0 -16px; padding: 2px 16px 6px; scrollbar-width: none; }
.folder-row::-webkit-scrollbar { display: none; }
.folder-card { flex: 0 0 92px; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 12px 6px; border-radius: 14px;
  border: 1px solid var(--line); background: var(--bg-2); color: var(--muted); text-align: center; }
.folder-card b { color: var(--text); font-size: 12.5px; line-height: 1.15; }
.folder-card small { font-size: 11px; }
.folder-card.on { border-color: var(--neon); background: var(--tint-accent); color: var(--neon); }
.folder-card.add { border-style: dashed; }
.folder-actions { margin-top: 8px; }
.note-book { width: 100%; text-align: left; color: var(--text); }

/* meta pessoal */
.goal-row { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 12px; border-radius: 12px; background: var(--bg-3); text-align: left; color: var(--text); }
.goal-row b { display: block; font-size: 13.5px; }
.goal-row .icon { color: var(--neon); flex-shrink: 0; }
.goal-row.static { background: transparent; padding: 4px 0; }
.goal-card { display: flex; flex-direction: column; gap: 10px; }
.goal-card-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.goal-sep { margin-top: 8px; padding-top: 12px; border-top: 1px solid var(--line); }
.status-pill { background: var(--tint-accent); color: var(--text); padding: 8px 12px; border-radius: 10px; font-size: 13px; }

/* gráfico de Minha leitura */
.chart-card { display: flex; flex-direction: column; gap: 12px; padding: 14px 14px 12px; }
.rchart-readout { display: flex; flex-direction: column; gap: 2px; min-height: 48px; }
.rchart-val { display: flex; align-items: baseline; gap: 2px; }
.rchart-val b { font-family: var(--display); font-size: 28px; letter-spacing: -.02em; color: var(--neon); }
.rchart-val b.tm { color: var(--chart-min); }
.rchart-val small { font-size: 13px; color: var(--muted); font-weight: 600; margin-right: 6px; }
.rchart-dot { width: 4px; height: 4px; border-radius: 50%; background: var(--line); margin: 0 8px 6px 2px; align-self: center; }
.rchart-svg { width: 100%; height: auto; display: block; overflow: visible; touch-action: pan-y; }
.rchart { --chart-min: #2B8CD6; }
[data-theme="neon"] .rchart, :root .rchart { --chart-min: #4FB3FF; }
[data-theme="claro"] .rchart { --chart-min: #2B7BC0; }
.g-pag-a { stop-color: var(--neon); stop-opacity: 1; }
.g-pag-b { stop-color: var(--neon); stop-opacity: .55; }
.g-min-a { stop-color: var(--chart-min); stop-opacity: 1; }
.g-min-b { stop-color: var(--chart-min); stop-opacity: .5; }
.rc-grid { stroke: var(--line); stroke-dasharray: 2 4; }
.rc-base { stroke: var(--line); }
.rc-axis { font-size: 9.5px; fill: var(--muted); font-family: var(--mono); }
.rc-axis.tm { fill: var(--chart-min); }
.rc-goal { stroke: var(--gold); stroke-width: 1.4; stroke-dasharray: 5 4; }
.rc-goal-t { font-size: 9.5px; fill: var(--gold); font-weight: 700; }
.rc-x { font-size: 10px; fill: var(--muted); font-weight: 600; }
.rc-val { font-size: 9.5px; fill: var(--text); font-weight: 700; }
.rc-hot { fill: transparent; cursor: pointer; }
.rc-col rect:not(.rc-hot) { transition: opacity .15s; }
.rc-col.dim rect:not(.rc-hot), .rc-col.dim .rc-val { opacity: .35; }
.rc-col.today .rc-x { fill: var(--neon); }
.rc-hitdot { fill: var(--gold); }
.rchart-legend { display: flex; gap: 16px; font-size: 12px; color: var(--muted); }
.rchart-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.lg-pag { background: var(--neon); }
.lg-min { background: var(--chart-min); }
.chart-foot { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); padding-top: 10px; }
.chart-foot div { display: flex; flex-direction: column; align-items: center; gap: 1px; text-align: center; }
.chart-foot div + div { border-left: 1px solid var(--line); }
.chart-foot b { font-size: 15px; }
.chart-foot span { font-size: 11px; color: var(--muted); }

/* mini perfil no desafio */
.rank-row.clickable { cursor: pointer; }
.rank-row.clickable:active { transform: scale(.99); }
.mini-bars { display: flex; align-items: flex-end; gap: 8px; height: 76px; margin-top: 8px; }
.mini-bar { flex: 1; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 4px; }
.mini-bar span { width: 100%; max-width: 20px; min-height: 3px; border-radius: 5px 5px 2px 2px; background: var(--neon); opacity: .85; }
.mini-bar small { font-size: 10px; color: var(--muted); }
.mini-bar.today small { color: var(--neon); font-weight: 700; }
.drawer { visibility: hidden; transition: transform .28s cubic-bezier(.2, .8, .2, 1), visibility 0s linear .28s; }
.drawer-wrap.open .drawer { visibility: visible; transition: transform .28s cubic-bezier(.2, .8, .2, 1); }
@media (min-width: 480px) { .drawer { transform: translateX(-30px); opacity: 0; } .drawer-wrap.open .drawer { opacity: 1; } .drawer, .drawer-wrap.open .drawer { transition-property: transform, opacity, visibility; } }

/* cartão Hoje: livro atual dentro do cartão */
.now-book { display: flex; align-items: center; gap: 12px; width: 100%; padding: 10px 12px; border-radius: 12px; background: var(--bg-3); text-align: left; color: var(--text); }
.now-book b { display: block; font-size: 15px; }
.now-book .progress { margin-top: 5px; }
.now-goal { display: flex; align-items: center; gap: 5px; font-size: 12px; margin-top: 6px; color: var(--neon); font-weight: 600; }
.now-goal.muted { color: var(--muted); font-weight: 500; text-decoration: underline; text-underline-offset: 2px; }
.today-links { display: flex; justify-content: center; gap: 18px; }
.modal .list-row .round-btn { pointer-events: none; }

/* Regras Oficiais e contestação */
.official-rules { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 6px; }
.official-rules li { display: flex; gap: 8px; align-items: flex-start; }
.official-rules li span { flex-shrink: 0; width: 18px; text-align: center; }
.log-highlight { margin: 8px 0 2px; padding: 8px 12px; border-left: 3px solid var(--neon); background: var(--bg-3); border-radius: 0 10px 10px 0; font-size: 13.5px; font-style: italic; }
.proof-box { margin-top: 10px; padding: 12px; border-radius: 12px; background: var(--tint-warn); border: 1px solid rgba(var(--warn-rgb), .35); }
.proof-sent { margin-top: 8px; }
.status-em_analise { color: var(--warn); }
.status-provado { color: var(--neon); }
.trust { font-weight: 600; }
.trust.high { color: var(--neon); }
.input-required { border-color: var(--neon); }

/* ===================== Tutorial de primeiro acesso ===================== */
.tutorial { position: fixed; inset: 0; z-index: 80; background: var(--bg); display: flex; flex-direction: column; max-width: 430px; margin: 0 auto;
  padding: calc(env(safe-area-inset-top) + 14px) 22px calc(env(safe-area-inset-bottom) + 18px); }
.tut-top { display: flex; justify-content: space-between; align-items: center; min-height: 28px; }
.tut-slide { flex: 1; display: flex; flex-direction: column; justify-content: center; text-align: center; gap: 14px; animation: tut-in .35s ease; }
@keyframes tut-in { from { opacity: 0; transform: translateX(24px); } to { opacity: 1; transform: none; } }
.tut-slide .display { font-size: 27px; line-height: 1.12; }
.tut-text { color: var(--muted); font-size: 16px; line-height: 1.45; max-width: 330px; margin: 0 auto; }
.tut-bottom { display: flex; flex-direction: column; gap: 12px; }
.tut-dots { display: flex; justify-content: center; gap: 8px; }
.tut-dot { width: 8px; height: 8px; border-radius: 99px; background: var(--line); transition: width .25s, background .25s; }
.tut-dot.on { width: 24px; background: var(--neon); }

.tut-art { height: 250px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; position: relative; }
.tut-logo { width: 92px; height: 92px; border-radius: 24px; box-shadow: 0 10px 30px -8px rgba(var(--accent-rgb), .5); }
.tut-books { display: flex; align-items: flex-end; gap: 6px; }
.tut-books span { width: 26px; border-radius: 4px 4px 2px 2px; box-shadow: inset -3px 0 0 rgba(0,0,0,.15); }

.tut-chain { display: flex; padding-left: 12px; }
.tut-ring-wrap { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.tut-ring { width: 46px; height: 30px; border-radius: 16px; border: 5px solid var(--line); margin-left: -12px; animation: tut-ring .5s ease both; }
.tut-ring.on { border-color: var(--neon); }
.tut-ring.today { border-color: var(--neon); border-style: dashed; }
.tut-ring-wrap small { font-size: 11px; color: var(--muted); margin-left: -12px; }
@keyframes tut-ring { from { opacity: 0; transform: scale(.6); } to { opacity: 1; transform: none; } }
.tut-big { font-size: 15px; color: var(--muted); font-weight: 600; }
.tut-big b { font-family: var(--display); font-size: 44px; color: var(--neon); margin-right: 4px; }

.tut-phone { width: 190px; padding: 18px 14px; border-radius: 22px; background: var(--bg-2); border: 1px solid var(--line);
  display: flex; flex-direction: column; align-items: center; gap: 8px; box-shadow: 0 14px 30px -14px rgba(0,0,0,.3); }
.tut-clock { font-family: var(--mono); font-size: 38px; color: var(--neon); }
.tut-stop { background: var(--neon); color: var(--on-accent); border-radius: 10px; padding: 7px 16px; font-weight: 700; font-size: 13px; }
.tut-play { position: absolute; bottom: 8px; right: calc(50% - 130px); width: 58px; height: 58px; border-radius: 50%; display: grid; place-items: center;
  background: var(--neon); color: var(--on-accent); box-shadow: 0 8px 20px -6px rgba(var(--accent-rgb), .6); animation: pulse-live 1.8s ease-in-out infinite; }

.tut-rank { width: 100%; max-width: 300px; display: flex; flex-direction: column; gap: 8px; }
.tut-row { display: flex; align-items: center; gap: 10px; padding: 11px 14px; border-radius: 14px; background: var(--bg-2); border: 1px solid var(--line); text-align: left; }
.tut-row.me { border-color: var(--neon); background: var(--tint-accent); }
.tut-badge { font-size: 13px; font-weight: 600; padding: 7px 12px; border-radius: 99px; background: #25D366; color: #fff; }

.tut-covers { display: flex; gap: 10px; }
.tut-cover { width: 84px; height: 124px; border-radius: 8px; color: #fff; padding: 8px; display: flex; flex-direction: column; justify-content: space-between;
  text-align: left; box-shadow: inset -4px 0 0 rgba(0,0,0,.18), 0 10px 20px -10px rgba(0,0,0,.4); }
.tut-cover b { font-size: 12px; line-height: 1.15; }
.tut-cover span { font-size: 11px; font-weight: 700; }
.tut-chips { display: flex; gap: 6px; flex-wrap: wrap; justify-content: center; }
.tut-chips span { font-size: 12.5px; padding: 6px 11px; border-radius: 99px; border: 1px solid var(--line); background: var(--bg-2); }

/* iPhone com o app instalado (tela cheia): reserva a faixa do relógio/bateria no topo */
.app { padding-top: env(safe-area-inset-top); }
.app::before { content: ''; position: fixed; top: 0; left: 0; right: 0; height: env(safe-area-inset-top); background: var(--bg); z-index: 40; pointer-events: none; }
.topbar { top: env(safe-area-inset-top); }

/* ===================== Minha estante: prateleiras, tudo junto, vitrine ===================== */
.books-parts { margin: 2px 0 6px; }
.view-toggle { display: flex; gap: 6px; }
.view-toggle button { flex: 1; padding: 9px 8px; border-radius: 12px; border: 1px solid var(--line); background: var(--bg-2); font-size: 13px; font-weight: 600; color: var(--muted); }
.view-toggle button.on { border-color: var(--neon); background: var(--tint-accent); color: var(--text); }
.sort-row { align-items: center; }

.shelf-row { position: relative; }
.shelf-row-head { display: flex; align-items: center; gap: 8px; width: 100%; text-align: left; color: var(--text); padding: 2px 0 8px; }
.shelf-row-head b { font-size: 15.5px; }
.shelf-emoji { font-size: 18px; }
.shelf-scroll { display: flex; gap: 10px; overflow-x: auto; margin: 0 -16px; padding: 0 16px 2px; scrollbar-width: none; align-items: flex-end; }
.shelf-scroll::-webkit-scrollbar { display: none; }
.shelf-plank { height: 7px; margin: 0 -4px; border-radius: 4px; background: linear-gradient(180deg, #C9A57A, #9C7748); box-shadow: 0 4px 8px -4px rgba(80, 50, 20, .55); }
[data-theme="neon"] .shelf-plank, [data-theme="grafite"] .shelf-plank { background: linear-gradient(180deg, #5b4a37, #3b2f22); }
.shelf-empty { width: 100%; padding: 22px 10px; color: var(--muted); font-size: 13px; border: 1px dashed var(--line); border-radius: 12px; margin-bottom: 6px; }
.shelf-group-head { display: flex; justify-content: space-between; align-items: baseline; margin-top: 6px; padding-top: 12px; border-top: 1px solid var(--line); }
.shelf-group-head b { font-size: 13px; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); }

.sc { flex: 0 0 84px; display: flex; flex-direction: column; gap: 4px; text-align: left; min-width: 0; padding-bottom: 6px; }
.sc-cover { position: relative; display: block; }
.sc-badge { position: absolute; top: -5px; right: -5px; width: 20px; height: 20px; border-radius: 50%; background: var(--neon); color: var(--on-accent);
  font-size: 11px; font-weight: 800; display: grid; place-items: center; box-shadow: 0 1px 4px rgba(0,0,0,.25); }
.sc-badge.quero { background: var(--bg-2); font-size: 10px; border: 1px solid var(--line); }
.sc-stars { color: var(--gold); font-size: 11px; letter-spacing: 1px; }
.sc-stars span { color: var(--star-off); }
.sc-more { justify-content: center; align-items: center; height: 120px; border: 1px dashed var(--line); border-radius: 8px; color: var(--muted); font-weight: 700; }
.book-grid .sc { flex: none; }

.folder-cta { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 18px 14px; border-radius: 14px; border: 1px dashed var(--neon);
  background: var(--tint-accent); text-align: center; color: var(--text); width: 100%; }
.folder-cta-emojis { font-size: 22px; letter-spacing: 4px; }

.folder-hero { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 4px; padding: 4px 16px 14px; }
.folder-hero-emoji { font-size: 46px; line-height: 1.1; }
.folder-hero .display { font-size: 26px; }
.showcase { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px 14px; }
.showcase-cell { position: relative; }
.sc-big { flex: none; width: 100%; }
.sc-big .small { font-size: 13.5px; font-weight: 600; }
.sc-big .sc-stars { font-size: 14px; }
.sc-big .sc-badge { width: 26px; height: 26px; font-size: 13px; }

.emoji-pick { display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; }
.emoji-opt { font-size: 22px; padding: 7px 0; border-radius: 10px; border: 1px solid var(--line); background: var(--bg-2); }
.emoji-opt.on { border-color: var(--neon); background: var(--tint-accent); }
.pick-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px 10px; max-height: 52vh; overflow-y: auto; padding: 4px 2px; }
.pick-cell { position: relative; display: flex; flex-direction: column; gap: 4px; text-align: left; opacity: .55; transition: opacity .15s; }
.pick-cell.on { opacity: 1; }
.pick-check { position: absolute; top: 6px; right: 6px; width: 24px; height: 24px; border-radius: 50%; border: 2px solid #fff; background: rgba(0,0,0,.35);
  color: #fff; font-weight: 800; display: grid; place-items: center; font-size: 13px; }
.pick-cell.on .pick-check { background: var(--neon); border-color: var(--neon); color: var(--on-accent); }
.book-folders { margin-top: 10px; }
.folder-line { width: 100%; text-align: left; color: var(--text); align-items: center; }
.folder-line .icon { color: var(--neon); flex-shrink: 0; }
.showcase-cell .shelf-more { left: 6px; right: auto; top: 6px; }
.sort-row .link.muted { color: var(--muted); font-weight: 500; }
.tut-shelf { width: 100%; max-width: 310px; display: flex; flex-direction: column; gap: 8px; text-align: left; }
.tut-shelf-label { font-weight: 700; font-size: 14px; }
.tut-shelf-books { display: flex; gap: 8px; align-items: flex-end; }
.tut-mini { position: relative; flex: 1; height: 104px; border-radius: 6px; color: #fff; padding: 6px; box-shadow: inset -3px 0 0 rgba(0,0,0,.18); }
.tut-mini:nth-child(2) { height: 96px; } .tut-mini:nth-child(4) { height: 110px; }
.tut-mini b { font-size: 10.5px; line-height: 1.15; display: block; }
.tut-mini-check { position: absolute; top: -6px; right: -6px; width: 20px; height: 20px; border-radius: 50%; background: var(--neon); color: var(--on-accent);
  font-size: 11px; font-weight: 800; display: grid; place-items: center; }
.tut-plank { height: 7px; border-radius: 4px; background: linear-gradient(180deg, #C9A57A, #9C7748); }

/* elo partido: o dia em que a corrente quebrou */
.wc.broken .wc-link { border-color: rgba(var(--err-rgb), .75); }
.wc.broken .wc-link::after { content: ''; position: absolute; left: 50%; top: -6px; bottom: -6px; width: 5px; margin-left: -2.5px; background: var(--bg-2); transform: rotate(22deg); }
.wc.broken .wc-label { color: var(--err); }
.chain-caption { text-align: center; font-size: 12.5px; font-weight: 600; margin-top: -4px; }
.chain-caption.ok { color: var(--neon); }
.chain-caption.warn { color: var(--warn); }
.chain-caption.err { color: var(--err); }
.chain-caption.muted { color: var(--muted); font-weight: 500; }

/* Seus amigos hoje (estilo stories): anel verde em quem já leu */
.friends-today { margin: 2px 0 12px; }
.friends-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; margin-bottom: 8px; }
.friends-head b { font-size: 14px; }
.friends-row { display: flex; gap: 12px; overflow-x: auto; padding: 2px 16px 4px; scrollbar-width: none; }
.friends-row::-webkit-scrollbar { display: none; }
.friend { flex: 0 0 62px; display: flex; flex-direction: column; align-items: center; gap: 4px; color: var(--muted); }
.friend small { font-size: 11.5px; max-width: 62px; text-align: center; }
.friend-ring { position: relative; padding: 3px; border-radius: 50%; border: 2.5px solid var(--line); display: grid; place-items: center; }
.friend-ring .avatar { opacity: .55; }
.friend.read .friend-ring { border-color: var(--neon); }
.friend.read .friend-ring .avatar { opacity: 1; }
.friend.read small { color: var(--text); font-weight: 600; }
.friend-check { position: absolute; right: -2px; bottom: -2px; width: 20px; height: 20px; border-radius: 50%; background: var(--neon); color: var(--on-accent);
  font-size: 11px; font-weight: 800; display: grid; place-items: center; border: 2px solid var(--bg); }

/* Visão Pastas: cartões lado a lado com as capas em leque */
.fgrid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.fcard { display: flex; flex-direction: column; border-radius: 16px; background: var(--bg-2); border: 1px solid var(--line); overflow: hidden; text-align: left; color: var(--text);
  box-shadow: 0 2px 8px -4px rgba(0,0,0,.12); transition: transform .12s; }
.fcard:active { transform: scale(.98); }
.fcard-art { position: relative; height: 112px; background: linear-gradient(160deg, var(--tint-accent), var(--bg-3)); display: block; overflow: hidden; }
.fcard-cover { position: absolute; bottom: -14px; width: 54px; box-shadow: 0 6px 14px -6px rgba(0,0,0,.45); border-radius: 5px; overflow: hidden; }
.fcard-cover .cover { width: 54px; height: 80px; }
.fcard-cover.c0 { left: calc(50% - 27px); z-index: 3; transform: translateY(-14px); }
.fcard-cover.c1 { left: calc(50% - 64px); z-index: 2; transform: rotate(-10deg); }
.fcard-cover.c2 { left: calc(50% + 10px); z-index: 1; transform: rotate(10deg); }
.fcard-empty { position: absolute; inset: 0; display: grid; place-items: center; font-size: 38px; opacity: .6; }
.fcard-info { display: flex; flex-direction: column; gap: 1px; padding: 10px 12px 11px; min-width: 0; }
.fcard-info b { font-size: 14px; }
.fcard-new { border-style: dashed; border-color: var(--neon); }
.fcard-new .fcard-art { background: var(--tint-accent); }
.fcard-plus { position: absolute; inset: 0; display: grid; place-items: center; font-size: 44px; font-weight: 300; color: var(--neon); }

/* página do livro: subtítulo que diz quem vê; ver mais resenhas */
.section-sub { margin: -6px 0 8px; }
.more-reviews { width: 100%; justify-content: center; margin-top: 4px; }

/* Meta de leitura: formulário, resumo e tela do primeiro acesso */
.goal-form .field-label { margin-top: 6px; }
.goal-other { width: 76px; padding: 7px 10px; border-radius: 999px; }
.goal-preview { display: flex; flex-direction: column; gap: 2px; padding: 12px 14px; border-radius: 12px; background: var(--tint-accent); }
.goal-preview b { font-size: 16px; color: var(--neon); }
.goal-summary { display: flex; align-items: center; gap: 12px; }
.goal-summary b { display: block; font-size: 16px; }
.goal-emoji { font-size: 28px; }
.status-pill.late { background: var(--tint-warn); }
.goal-books { display: block; margin-top: 4px; font-size: 11.5px; }
.goal-cta { border-color: var(--neon); background: var(--tint-accent); }
.goal-onb { overflow-y: auto; }
.goal-onb-body { display: flex; flex-direction: column; gap: 12px; padding: 12px 0 24px; }
.goal-onb-hero { font-size: 54px; text-align: center; }
.goal-onb .display { text-align: center; font-size: 27px; }
.goal-onb .tut-text { text-align: center; }
/* chip "Escolher data": o calendário do celular abre ao tocar */
.chip-date { position: relative; overflow: hidden; cursor: pointer; }
.chip-date input[type="date"] { position: absolute; inset: 0; opacity: 0; width: 100%; height: 100%; cursor: pointer; }
