
:root {
  --bg:#0f1720;
  --panel:#18212d;
  --panel-soft:rgba(255,255,255,.03);
  --text:#e5edf6;
  --muted:#9db0c3;
  --line:#2b3b4d;
  --accent:#f59e0b;
  --danger:#ef4444;
  --shadow:0 12px 30px rgba(0,0,0,.12);
  --radius-lg:18px;
  --radius-md:14px;
  --radius-sm:12px;
  --button-radius:6px;
  --button-height:42px;
}

html[data-theme='light'] {
  --bg:#eef2f7;
  --panel:#ffffff;
  --panel-soft:rgba(15,23,32,.03);
  --text:#1a2431;
  --muted:#5f7185;
  --line:#d7e0ea;
  --accent:#c97700;
  --shadow:0 12px 30px rgba(15,23,32,.08);
}

* { box-sizing:border-box; }
html, body { overflow-x:hidden; }
body {
  margin:0;
  background:var(--bg);
  color:var(--text);
  font-family:'Noto Sans Malayalam','Manjari',Inter,Arial,sans-serif;
}
a { color:inherit; text-decoration:none; }
img { max-width:100%; display:block; height:auto; }
button, input, select, textarea { font:inherit; }

/* Layout primitives */
.site-shell, .container { width:100%; max-width:none; margin:0 auto; padding:0 22px; }
.cluster, .row { display:flex; gap:10px; }
.cluster-wrap, .wrap { flex-wrap:wrap; }
.cluster-center, .center { align-items:center; }
.cluster-between, .between { justify-content:space-between; }
.cluster-gap, .gap { gap:10px; }
.stack { display:grid; gap:16px; }
.dashboard-stack { display:grid; gap:20px; }
.dashboard-stack .analytics-story-card + .analytics-story-card { margin-top:16px; }
.page-grid { display:grid; grid-template-columns:minmax(0,1fr) 320px; gap:20px; padding-top:22px; padding-bottom:22px; }
.page-grid.no-sidebar { grid-template-columns:minmax(0,1fr); }
.content-area, .sidebar-stack, .panel, .stack-card, .story-card, .ad-card { min-width:0; }
.sidebar-stack { display:grid; gap:14px; align-content:start; position:sticky; top:82px; height:fit-content; }

/* Surfaces */
.panel, .stack-card {
  background:var(--panel);
  border:1px solid var(--line);
  border-radius:var(--radius-lg);
  padding:18px;
  box-shadow:var(--shadow);
}
.panel-lite {
  background:var(--panel-soft);
  border:1px solid var(--line);
  border-radius:var(--radius-lg);
  padding:18px;
}
.flash {
  padding:14px 16px;
  border:1px solid var(--line);
  border-radius:var(--radius-sm);
  margin-bottom:14px;
  background:var(--panel);
  color:var(--text);
  font-weight:700;
  box-shadow:var(--shadow);
}
.flash--error, .flash--danger {
  background:rgba(239,68,68,.14);
  border-color:rgba(239,68,68,.38);
  color:#fecaca;
}
.flash--success {
  background:rgba(34,197,94,.14);
  border-color:rgba(34,197,94,.34);
  color:#bbf7d0;
}
.flash--warning {
  background:rgba(245,158,11,.16);
  border-color:rgba(245,158,11,.4);
  color:#fde68a;
}
.flash--info {
  background:rgba(59,130,246,.14);
  border-color:rgba(59,130,246,.34);
  color:#bfdbfe;
}
html[data-theme='light'] .flash {
  background:#ffffff;
  color:#17212d;
  border-color:#cfd9e5;
}
html[data-theme='light'] .flash--error,
html[data-theme='light'] .flash--danger {
  background:#fef2f2;
  border-color:#fecaca;
  color:#991b1b;
}
html[data-theme='light'] .flash--success {
  background:#f0fdf4;
  border-color:#bbf7d0;
  color:#166534;
}
html[data-theme='light'] .flash--warning {
  background:#fffbeb;
  border-color:#fde68a;
  color:#92400e;
}
html[data-theme='light'] .flash--info {
  background:#eff6ff;
  border-color:#bfdbfe;
  color:#1d4ed8;
}

/* Header */
.site-header {
  position:sticky;
  top:0;
  z-index:40;
  background:rgba(16,23,32,.92);
  backdrop-filter:blur(8px);
  border-bottom:1px solid var(--line);
}
html[data-theme='light'] .site-header { background:rgba(255,255,255,.92); }
.header-shell { display:grid; gap:10px; padding:8px 0 14px; }
.header-top { display:flex; justify-content:space-between; align-items:center; gap:14px; flex-wrap:wrap; }
.header-actions { display:flex; gap:10px; align-items:center; flex:1; justify-content:flex-end; }
.brand { font-size:24px; font-weight:800; padding:18px 0; color:var(--accent); min-width:0; }
.site-logo { max-height:42px; width:auto; }
.main-nav {
  display:flex;
  gap:14px;
  align-items:center;
  flex-wrap:wrap;
  overflow:auto;
  scrollbar-width:thin;
}
.main-nav a {
  padding:10px 12px;
  border-radius:10px;
  white-space:nowrap;
}
.main-nav a:hover { background:var(--panel-soft); }
.site-search { display:flex; gap:10px; align-items:center; max-width:520px; width:100%; min-width:0; }
.site-search input {
  width:100%;
  min-width:0;
  background:transparent;
  color:var(--text);
  border:1px solid var(--line);
  border-radius:var(--radius-sm);
  padding:10px 12px;
}
.site-search button, .button, .btn, .theme-switch, .mobile-theme-switch, .share-btn, .reading-pill {
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  min-height:var(--button-height);
  padding:10px 14px;
  border-radius:var(--button-radius);
  font-size:14px;
  font-weight:700;
  line-height:1;
  white-space:nowrap;
  cursor:pointer;
  transition:background-color .18s ease, border-color .18s ease, color .18s ease, transform .18s ease, box-shadow .18s ease;
}
.site-search button, .button, .btn {
  background:var(--accent);
  color:#111827;
  border:1px solid var(--accent);
}
.site-search button:hover, .button:hover, .btn:hover,
.theme-switch:hover, .mobile-theme-switch:hover, .share-btn:hover, .reading-pill:hover {
  transform:translateY(-1px);
  box-shadow:0 8px 16px rgba(0,0,0,.12);
}
.button-secondary, .btn-alt {
  background:transparent;
  color:var(--text);
  border:1px solid var(--line);
}
.button-small, .btn-small { min-height:38px; padding:8px 12px; font-size:14px; }
.button-danger, .danger { background:var(--danger); border-color:var(--danger); color:#fff; }
.theme-switch, .mobile-theme-switch, .share-btn, .reading-pill {
  border:1px solid var(--line);
  background:var(--panel);
  color:var(--text);
}
.theme-switch, .mobile-theme-switch { min-width:110px; }
.theme-switch-label { display:inline-block; min-width:72px; text-align:center; }

.mobile-breadcrumb-dropdown { display:none; position:relative; z-index:40; }
.mobile-breadcrumb-toggle {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  width:100%;
  background:var(--panel);
  color:var(--text);
  border:1px solid var(--line);
  border-radius:var(--radius-sm);
  padding:10px 12px;
  font-weight:700;
  cursor:pointer;
}
.mobile-breadcrumb-current { color:var(--muted); font-weight:600; margin-left:auto; }
.mobile-breadcrumb-list {
  display:none;
  position:absolute;
  top:calc(100% + 8px);
  left:0;
  right:0;
  z-index:50;
  background:var(--panel);
  border:1px solid var(--line);
  border-radius:var(--radius-md);
  box-shadow:0 12px 30px rgba(0,0,0,.18);
  padding:8px;
  max-height:70vh;
  overflow:auto;
}
.mobile-breadcrumb-list.is-open { display:grid; gap:4px; }
.mobile-breadcrumb-list a { display:block; padding:10px 12px; border-radius:10px; }
.mobile-breadcrumb-list a:hover { background:var(--panel-soft); }

/* Hero + sections */
.hero { padding:34px; }
.eyebrow { display:inline-block; margin-bottom:8px; color:var(--accent); font-weight:700; }
.hero h1 { font-size:42px; margin:8px 0 12px; }
.hero p, .meta { color:var(--muted); }
.section-heading { display:flex; justify-content:space-between; align-items:center; gap:12px; flex-wrap:wrap; margin-bottom:14px; }
.section-heading h2 { margin:0 0 4px; }
.home-section-block { margin-top:18px; }
.home-hero-grid { display:grid; grid-template-columns:minmax(0,1.3fr) minmax(240px,.7fr); gap:18px; align-items:stretch; }
.continue-reading-card { display:grid; gap:8px; align-content:start; text-decoration:none; min-height:100%; }
.continue-reading-card strong { font-size:1.1rem; }
.continue-reading-card small { color:var(--muted); }
.mobile-continue-card { display:grid; gap:6px; text-decoration:none; padding:14px 16px; margin-top:14px; border:1px solid var(--line); border-radius:18px; background:rgba(255,255,255,.06); color:inherit; }
.mobile-continue-card strong { font-size:1.02rem; }
.mobile-continue-card small { color:inherit; opacity:.8; }

/* Story cards */
.story-grid { display:grid; grid-template-columns:repeat(auto-fit,minmax(260px,1fr)); gap:16px; padding-top:22px; }
.aurora-card-grid { display:grid; grid-template-columns:repeat(auto-fit,minmax(250px,1fr)); gap:16px; }
.story-card {
  display:grid;
  gap:14px;
  overflow:hidden;
}
.story-card-cover-mode { grid-template-columns:96px 1fr; }
.story-card-icon-mode,
.story-card-text-mode { grid-template-columns:1fr; }
.story-card-media, .cover-wrap { width:96px; }
.story-card-cover-mode .story-card-media { width:96px; }
.story-card-icon-mode .story-card-media,
.story-card-text-mode .story-card-media { width:auto; }
.story-card-body { display:grid; gap:12px; min-width:0; }
.story-card-top, .story-card-footer { display:grid; gap:10px; }
.story-title, .story-title-wrap h1 { margin:0; line-height:1.25; }
.story-title a { display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; }
.story-card h3, .story-card p, .mini-story-title, .mini-story-author, .meta { overflow-wrap:anywhere; word-break:break-word; }
.story-badges, .story-stats, .story-actions-row, .pdf-novel-actions, .pdf-novel-badges { display:flex; gap:8px; flex-wrap:wrap; }
.story-badge, .tag-chip {
  display:inline-flex;
  align-items:center;
  padding:6px 10px;
  border-radius:999px;
  border:1px solid var(--line);
  background:var(--panel-soft);
  font-size:12px;
}
.story-tags { display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; }
.story-card-link { color:var(--accent); font-weight:700; }
.cover-wrap img, .story-card-media img, .cover-placeholder, .detail-cover {
  border-radius:var(--radius-md);
  border:1px solid var(--line);
  aspect-ratio:2/3;
  object-fit:cover;
}
.cover-placeholder {
  display:grid;
  place-items:center;
  background:linear-gradient(135deg,#223247,#131b24);
  font-size:42px;
  font-weight:800;
}
.detail-cover { width:180px; }
.story-header { display:grid; grid-template-columns:180px 1fr; gap:20px; min-width:0; }
.story-body-content {
  white-space:pre-wrap;
  line-height:1.85;
}
.story-body-content p,
.story-body-content blockquote,
.story-body-content ul,
.story-body-content ol,
.story-body-content pre,
.story-body-content h1,
.story-body-content h2,
.story-body-content h3 { margin:0 0 1em; }
.story-body-content br { content:""; display:block; margin-bottom:.45em; }
.story-body-content ul, .story-body-content ol { padding-left:1.5rem; }

.chapter-list { display:grid; gap:8px; }
.chapter-list a, .mini-story, .mini-story-row {
  display:block;
  padding:10px 12px;
  border-radius:var(--radius-sm);
  border:1px solid var(--line);
  background:var(--panel-soft);
}
.mini-story-rows { display:grid; gap:10px; }
.mini-story-row strong { display:block; margin-bottom:4px; }
.mini-story-row span { display:block; color:var(--muted); font-size:13px; }
.mini-story-title { display:block; }
.mini-story-author { display:block; color:var(--accent); font-size:13px; margin-top:4px; }
.author-link { color:var(--accent); font-weight:700; }

/* Forms */
.form-panel p, .field-wrap { display:grid; gap:6px; }
.form-panel input, .form-panel textarea, .form-panel select,
.story-submit-form input, .story-submit-form textarea, .story-submit-form select {
  width:100%;
  background:transparent;
  color:var(--text);
  border:1px solid var(--line);
  border-radius:var(--radius-sm);
  padding:10px 12px;
}
.story-submit-form .submit-grid { display:grid; grid-template-columns:minmax(0,2fr) minmax(320px,1fr); gap:20px; min-width:0; align-items:start; }
.story-submit-form .submit-main, .story-submit-form .submit-side { display:grid; gap:16px; }

.story-submit-form .submit-main { min-width:0; }
.story-submit-form .submit-side { min-width:0; position:sticky; top:96px; }
.story-submit-form .tox, .story-submit-form .tox-tinymce { width:100% !important; }
.story-submit-form .submission-details-below { align-self:start; }
.submit-inline-2 { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:14px; min-width:0; }
.editor-panel, .classic-editor {
  border:1px solid var(--line);
  border-radius:16px;
  padding:16px;
  background:var(--panel-soft);
}
.editor-header, .profile-main-header { display:flex; justify-content:space-between; align-items:center; gap:12px; flex-wrap:wrap; min-width:0; }
.rich-toolbar, .classic-toolbar {
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  overflow-x:auto;
  scrollbar-width:thin;
  padding-bottom:4px;
}
.rich-toolbar button, .classic-toolbar button, .classic-editor-tabs button {
  padding:8px 10px;
  border-radius:10px;
  border:1px solid var(--line);
  background:transparent;
  color:var(--text);
  cursor:pointer;
}
.rich-preview, .classic-editor-preview {
  display:none;
  margin-top:12px;
  padding:14px;
  border-radius:14px;
  border:1px dashed var(--line);
  background:var(--panel-soft);
}
.rich-preview.active, .classic-editor-preview.active { display:block; }
.classic-editor textarea { border:none; border-radius:0; background:transparent; min-height:320px; }
.classic-editor.text-mode textarea { font-family:ui-monospace,SFMono-Regular,Menlo,monospace; }

/* Profile */
.profile-shell { display:grid; gap:20px; }
.profile-top-card { padding:24px; }
.profile-top-layout { display:grid; grid-template-columns:180px 1fr; gap:24px; align-items:start; min-width:0; }
.profile-avatar-xl { width:160px; height:160px; }
.profile-main { display:grid; gap:18px; }
.profile-name { margin:0; font-size:34px; line-height:1.1; }
.profile-handle { margin-top:6px; }
.profile-stat-strip { display:grid; grid-template-columns:repeat(5,minmax(0,1fr)); gap:12px; min-width:0; }
.profile-stat, .info-list div, .profile-mini-stats div {
  padding:14px;
  border:1px solid var(--line);
  border-radius:14px;
  background:var(--panel-soft);
  text-align:center;
}
.profile-stat strong { display:block; font-size:22px; }
.profile-stat span, .info-list span, .profile-mini-stats span { display:block; color:var(--muted); font-size:13px; margin-bottom:6px; }
.profile-tabs { display:flex; gap:10px; flex-wrap:wrap; border-top:1px solid var(--line); padding-top:14px; min-width:0; }
.profile-tabs a { padding:10px 14px; border-radius:10px; background:var(--panel-soft); border:1px solid var(--line); }
.profile-tabs a.active { background:var(--accent); color:#111827; border-color:transparent; }
.profile-body-grid { display:grid; grid-template-columns:1.2fr 1fr 1fr; gap:18px; min-width:0; }
.info-list, .profile-mini-stats { display:grid; gap:12px; }
.author-card { text-align:center; }
.avatar { width:96px; height:96px; border-radius:999px; margin:0 auto 12px; object-fit:cover; border:1px solid var(--line); }
.avatar.placeholder { display:grid; place-items:center; background:linear-gradient(135deg,#223247,#131b24); font-size:40px; font-weight:800; }
.avatar.large { width:120px; height:120px; }
.author-profile-card .author-hero { display:grid; grid-template-columns:120px 1fr; gap:18px; align-items:center; }

/* Footer + misc */
.stack-links { display:grid; gap:8px; }
.stack-links a, .ad-card { display:block; padding:10px 12px; border:1px solid var(--line); border-radius:var(--radius-sm); }
.ad-card span { display:block; color:var(--muted); font-size:13px; margin-top:4px; }
.site-footer { border-top:1px solid var(--line); padding:28px 0 80px; margin-top:20px; }
.footer-grid { display:grid; gap:12px; }
.footer-menu, .footer-ad-row, .share-row { display:flex; gap:12px; flex-wrap:wrap; }
#scrollTopBtn {
  position:fixed;
  bottom:20px;
  right:20px;
  width:46px;
  height:46px;
  border:none;
  border-radius:999px;
  background:var(--accent);
  font-size:20px;
  font-weight:800;
  display:none;
  cursor:pointer;
}
.mobile-bottom-nav {
  display:none;
  position:fixed;
  left:0;
  right:0;
  bottom:0;
  z-index:45;
  background:rgba(16,23,32,.95);
  backdrop-filter:blur(10px);
  border-top:1px solid var(--line);
  grid-template-columns:repeat(4,1fr);
}
html[data-theme='light'] .mobile-bottom-nav { background:rgba(255,255,255,.95); }
.mobile-bottom-nav a {
  text-align:center;
  padding:12px 8px;
  font-size:13px;
  color:var(--text);
}

body.reader-page-active .mobile-bottom-nav { display:none !important; }
@media (max-width: 720px) {
  body.reader-page-active { padding-bottom:0; }
}

/* Utility spacing */
.panel-gap-top { margin-top:14px; }
.tag-list { display:flex; gap:8px; flex-wrap:wrap; }
.rate-form { display:flex; gap:10px; flex-wrap:wrap; align-items:center; }
.rate-form select { min-width:120px; }

/* Responsive */
@media (max-width:1150px) {
  .page-grid { grid-template-columns:1fr; }
  .sidebar-stack { position:static; }
  .story-header { grid-template-columns:1fr; }
  .detail-cover { width:140px; }
  .hero h1 { font-size:32px; }
  .header-top { flex-direction:column; align-items:stretch; }
  .header-actions { width:100%; justify-content:space-between; align-items:stretch; flex-wrap:nowrap; }
  .site-search { max-width:none; flex:1; }
  .site-search button, .theme-switch { flex:0 0 auto; }
  .main-nav { display:none; }
  .mobile-breadcrumb-dropdown { display:block; }
}

@media (max-width:1100px) {
  .story-submit-form .submit-grid,
  .profile-body-grid { grid-template-columns:1fr; }
  .profile-stat-strip { grid-template-columns:repeat(3,minmax(0,1fr)); }
}

@media (max-width:700px) {
  .site-shell, .container { padding:0 14px; }
  .panel, .stack-card { padding:14px; border-radius:16px; }
  .hero { padding:24px 18px; }
  .story-grid, .aurora-card-grid { grid-template-columns:1fr; gap:14px; }
  .story-card-cover-mode { grid-template-columns:78px 1fr; gap:12px; }
  .story-card-cover-mode .story-card-media { width:78px; }
  .story-badges, .story-stats, .pdf-novel-actions, .pdf-novel-badges, .share-row { gap:6px; }
  .section-heading { align-items:flex-start; }
  .section-heading > a { width:100%; }
  .submit-inline-2, .profile-top-layout { grid-template-columns:1fr; }
  .profile-avatar-wrap { display:flex; justify-content:center; }
  .profile-stat-strip { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .mobile-bottom-nav { display:grid; }
  .site-footer { padding-bottom:90px; }
}

/* Mobile-first home redesign */
.mobile-home-shell { display:grid; gap:18px; }
.mobile-home-hero {
  display:grid;
  gap:16px;
  background:linear-gradient(180deg, rgba(26,36,49,.98), rgba(16,23,32,.96));
  color:#f8fbff;
}
html[data-theme='light'] .mobile-home-hero {
  background:linear-gradient(180deg, #eef4fb, #ffffff);
  color:#16202b;
}
.mobile-home-hero__top { display:flex; align-items:flex-start; justify-content:space-between; gap:14px; }
.mobile-home-eyebrow {
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:6px 10px;
  border-radius:999px;
  background:rgba(255,255,255,.08);
  color:var(--accent);
  font-size:12px;
  font-weight:800;
  letter-spacing:.04em;
  text-transform:uppercase;
}
html[data-theme='light'] .mobile-home-eyebrow { background:rgba(21,31,43,.05); }
.mobile-home-hero h1 { margin:10px 0 8px; font-size:clamp(32px,5vw,48px); line-height:1.05; }
.mobile-home-hero p { margin:0; color:inherit; opacity:.82; max-width:62ch; }
.mobile-home-greeting {
  display:grid;
  gap:4px;
  padding:14px 16px;
  border-radius:16px;
  background:rgba(255,255,255,.06);
  border:1px solid rgba(255,255,255,.08);
}
html[data-theme='light'] .mobile-home-greeting {
  background:rgba(15,23,32,.04);
  border-color:rgba(15,23,32,.08);
}
.mobile-home-greeting strong { font-size:20px; }
.mobile-quick-grid { display:grid; gap:12px; grid-template-columns:repeat(3,minmax(0,1fr)); }
.mobile-quick-card {
  display:grid;
  gap:8px;
  padding:16px;
  border-radius:18px;
  background:rgba(9,14,20,.28);
  border:1px solid rgba(255,255,255,.08);
  min-height:126px;
}
html[data-theme='light'] .mobile-quick-card {
  background:#f8fbff;
  border-color:#dde6f0;
}
.mobile-quick-icon {
  display:grid;
  place-items:center;
  width:44px;
  height:44px;
  border-radius:14px;
  background:rgba(255,255,255,.08);
  font-size:22px;
}
html[data-theme='light'] .mobile-quick-icon { background:#eef3f9; }
.mobile-quick-card strong { font-size:20px; line-height:1.15; }
.mobile-quick-card small { color:var(--muted); font-size:13px; line-height:1.4; }
.mobile-home-section { display:grid; gap:16px; }
.mobile-section-head { display:flex; justify-content:space-between; align-items:flex-end; gap:12px; }
.mobile-section-head h2 { margin:0 0 4px; font-size:clamp(24px,4vw,32px); line-height:1.1; }
.mobile-section-head p { margin:0; color:var(--muted); }
.mobile-section-head a { color:#0f6adf; font-weight:700; white-space:nowrap; }
html[data-theme='dark'] .mobile-section-head a { color:#7cb5ff; }
.mobile-featured-stack { display:grid; gap:14px; }
.mobile-featured-card, .mobile-story-row {
  display:grid;
  grid-template-columns:100px 1fr;
  gap:14px;
  padding:14px;
  border-radius:18px;
  border:1px solid var(--line);
  background:var(--panel-soft);
}
.mobile-featured-cover, .mobile-story-thumb {
  width:100px;
  aspect-ratio:1;
  border-radius:16px;
  overflow:hidden;
  border:1px solid var(--line);
  background:linear-gradient(135deg,#223247,#131b24);
  display:grid;
  place-items:center;
  font-weight:800;
  font-size:30px;
}
.mobile-featured-cover img, .mobile-story-thumb img { width:100%; height:100%; object-fit:cover; }
.mobile-featured-copy, .mobile-story-copy { display:grid; gap:8px; align-content:center; min-width:0; }
.mobile-featured-badges, .mobile-inline-meta, .mobile-featured-stats {
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  color:var(--muted);
  font-size:14px;
}
.mobile-featured-badges span {
  display:inline-flex;
  align-items:center;
  padding:5px 9px;
  border-radius:999px;
  background:rgba(245,158,11,.12);
  color:var(--accent);
  font-weight:700;
}
.mobile-featured-copy h3, .mobile-story-copy h3 { margin:0; font-size:clamp(22px,3.5vw,30px); line-height:1.15; }
.mobile-featured-copy h3 a, .mobile-story-copy h3 a { display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; }
.mobile-featured-author, .mobile-story-copy p { margin:0; color:var(--muted); font-size:16px; }
.mobile-story-list { display:grid; gap:12px; }
.mobile-story-row.compact-row { grid-template-columns:1fr; padding:12px 14px; }
.mobile-story-copy.compact-copy h3 { font-size:20px; }
.mobile-update-list { display:grid; gap:10px; }
.mobile-update-row {
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:10px;
  padding:16px 14px;
  border-radius:16px;
  border:1px solid var(--line);
  background:var(--panel-soft);
}
.mobile-update-row strong { font-size:19px; line-height:1.25; }
.mobile-update-row span { color:var(--muted); font-size:14px; white-space:nowrap; }
.mobile-pdf-cta {
  background:linear-gradient(135deg, rgba(245,158,11,.14), rgba(245,158,11,.06));
}
html[data-theme='light'] .mobile-pdf-cta { background:linear-gradient(135deg, rgba(245,158,11,.14), rgba(255,255,255,.96)); }

.mobile-home-shell { width:100%; max-width: 1360px; margin: 0 auto; display:grid; gap:18px; }
.mobile-home-main, .mobile-home-sidebar { display:grid; gap:18px; align-content:start; }
.mobile-home-hero {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  box-shadow: 0 24px 64px rgba(0,0,0,.22);
}
.mobile-home-hero::after {
  content: "";
  position: absolute;
  inset: auto -10% -30% auto;
  width: 220px;
  height: 220px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(255,255,255,.18), rgba(255,255,255,0));
  pointer-events: none;
}
.mobile-home-greeting,
.mobile-quick-card,
.mobile-featured-card,
.mobile-story-row,
.mobile-update-row,
.mobile-home-section.panel {
  box-shadow: 0 16px 40px rgba(0,0,0,.12);
}
.mobile-home-section.panel {
  border-radius: 24px;
  padding: 18px;
  background: linear-gradient(180deg, rgba(17,24,33,.96), rgba(13,18,26,.98));
}
html[data-theme='light'] .mobile-home-section.panel {
  background: linear-gradient(180deg, #ffffff, #f7fbff);
}
.mobile-section-head { align-items: center; }
.mobile-section-head h2 { font-weight: 800; letter-spacing: -.03em; }
.mobile-section-head a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 14px;
  border-radius: 999px;
  background: rgba(124,181,255,.14);
  text-decoration: none;
}
.mobile-featured-card {
  grid-template-columns: 120px 1fr;
  border-radius: 22px;
}
.mobile-featured-cover {
  width: 120px;
  border-radius: 20px;
  aspect-ratio: 3 / 4;
}
.mobile-story-thumb { aspect-ratio: 3 / 4; }
.mobile-story-row { border-radius: 20px; }
.mobile-update-row { border-radius: 18px; }
.mobile-update-row strong { display: block; }
.mobile-featured-stats span,
.mobile-inline-meta span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(255,255,255,.05);
}
html[data-theme='light'] .mobile-featured-stats span,
html[data-theme='light'] .mobile-inline-meta span {
  background: rgba(15,23,32,.05);
}
@media (max-width:700px) {
  .mobile-home-shell { max-width: 100%; }
  .mobile-home-section.panel { padding: 16px; border-radius: 20px; }
  .mobile-featured-card { grid-template-columns: 96px 1fr; }
  .mobile-featured-cover { width: 96px; border-radius: 16px; }
}

@media (min-width:701px) {
  .mobile-home-shell { gap:22px; }
  .mobile-featured-stack { grid-template-columns:1.15fr .85fr; align-items:start; }
  .mobile-home-hero { padding:22px; }
  .mobile-story-list.compact { grid-template-columns:repeat(2,minmax(0,1fr)); }
}

@media (min-width: 1100px) {
  .mobile-home-shell {
    grid-template-columns: minmax(0, 1.7fr) minmax(320px, .9fr);
    gap: 24px;
  }
  .mobile-home-hero,
  .mobile-home-section.panel {
    padding: 20px;
  }
  .mobile-home-sidebar {
    position: sticky;
    top: 88px;
  }
}

@media (min-width: 1380px) {
  .mobile-home-shell {
    max-width: 1440px;
  }
}

@media (max-width:700px) {
  .mobile-home-shell { gap:14px; }
  .mobile-home-hero { padding:16px; border-radius:20px; }
  .mobile-home-hero__top { display:grid; gap:12px; }
  .mobile-home-hero__browse { width:100%; }
  .mobile-home-greeting strong { font-size:18px; }
  .mobile-quick-grid { grid-template-columns:1fr; }
  .mobile-quick-card { min-height:unset; grid-template-columns:auto 1fr; align-items:center; }
  .mobile-quick-card .mobile-quick-icon { grid-row:span 2; }
  .mobile-quick-card strong { font-size:18px; }
  .mobile-section-head { align-items:flex-start; }
  .mobile-section-head a { padding-top:2px; }
  .mobile-featured-card, .mobile-story-row { grid-template-columns:92px 1fr; gap:12px; padding:12px; }
  .mobile-featured-cover, .mobile-story-thumb { width:92px; border-radius:14px; }
  .mobile-featured-copy h3, .mobile-story-copy h3 { font-size:20px; }
  .mobile-update-row { display:grid; gap:6px; }
  .mobile-update-row span { white-space:normal; }
}

/* Story detail redesign */
.story-page-shell { display:grid; gap:18px; }
.story-detail-grid { display:grid; grid-template-columns:minmax(0,1.2fr) minmax(300px,.8fr); gap:18px; }
.story-detail-main-card, .story-mobile-side-card, .story-mobile-related-card, .story-mobile-comments-card { display:grid; gap:16px; }
.story-mobile-hero {
  padding:18px;
  background:linear-gradient(180deg, rgba(26,36,49,.98), rgba(16,23,32,.96));
  color:#f8fbff;
}
html[data-theme='light'] .story-mobile-hero {
  background:linear-gradient(180deg, #eef4fb, #ffffff);
  color:#16202b;
}
.story-mobile-hero__content { display:grid; grid-template-columns:124px 1fr; gap:16px; align-items:start; }
.story-mobile-cover-wrap { width:124px; }
.story-mobile-cover { width:124px; aspect-ratio:2/3; border-radius:22px; border:1px solid rgba(255,255,255,.1); object-fit:cover; }
.story-mobile-main { display:grid; gap:14px; min-width:0; }
.story-mobile-badges { display:flex; gap:8px; flex-wrap:wrap; }
.story-mobile-chip {
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:7px 11px;
  border-radius:999px;
  border:1px solid rgba(255,255,255,.1);
  background:rgba(255,255,255,.06);
  font-size:12px;
  font-weight:700;
}
html[data-theme='light'] .story-mobile-chip {
  background:rgba(15,23,32,.05);
  border-color:rgba(15,23,32,.08);
}
.story-mobile-hero h1 { margin:0; font-size:clamp(28px,4.8vw,42px); line-height:1.08; }
.story-mobile-author-row { display:flex; align-items:center; gap:8px; flex-wrap:wrap; color:inherit; opacity:.84; }
.story-mobile-author { color:var(--accent); font-weight:800; }
.story-mobile-dot { opacity:.45; }
.story-mobile-stats-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:10px; }
.story-mobile-stats-grid div {
  padding:12px;
  border-radius:16px;
  background:rgba(255,255,255,.06);
  border:1px solid rgba(255,255,255,.08);
  display:grid;
  gap:4px;
}
html[data-theme='light'] .story-mobile-stats-grid div {
  background:rgba(15,23,32,.04);
  border-color:rgba(15,23,32,.08);
}
.story-mobile-stats-grid strong { font-size:20px; line-height:1; }
.story-mobile-stats-grid span { font-size:12px; color:inherit; opacity:.72; }
.story-mobile-actions, .story-mobile-inline-actions, .story-mobile-side-actions { display:flex; gap:10px; flex-wrap:wrap; }
.story-mobile-surface {
  display:grid;
  gap:14px;
  padding:16px;
  border-radius:18px;
  border:1px solid var(--line);
  background:var(--panel-soft);
}
.story-mobile-description { font-size:1rem; }
.story-section-head { margin-bottom:0; }
.story-section-head--tight h2 { font-size:clamp(22px,4vw,28px); }
.story-share-row--mobile { padding-top:2px; }
.story-mobile-list { display:grid; gap:12px; }
.story-mobile-list-card {
  display:grid;
  gap:12px;
  padding:14px;
  border-radius:16px;
  border:1px solid var(--line);
  background:var(--panel);
}
.story-detail-side-stack { display:grid; gap:18px; align-content:start; }
.story-mobile-inline-actions--top { margin-bottom:6px; }
.story-mobile-chapter-list a {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
}
.story-mobile-comments-card .comment-card,
.story-mobile-comments-card .comment-reply {
  background:var(--panel-soft);
  border:1px solid var(--line);
  border-radius:16px;
  padding:14px;
}
.story-mobile-comments-card .comment-thread-list { display:grid; gap:12px; }
.story-mobile-comments-card .comment-reply { margin-top:10px; margin-left:14px; }
.story-mobile-rate-card .rate-form select {
  background:transparent;
  color:var(--text);
  border:1px solid var(--line);
  border-radius:12px;
  padding:10px 12px;
}

@media (max-width:980px) {
  .story-detail-grid { grid-template-columns:1fr; }
}

@media (max-width:700px) {
  .story-mobile-hero { padding:16px; }
  .story-mobile-hero__content { grid-template-columns:92px 1fr; gap:14px; }
  .story-mobile-cover-wrap, .story-mobile-cover { width:92px; }
  .story-mobile-stats-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .story-mobile-actions > *,
  .story-mobile-inline-actions > *,
  .story-mobile-side-actions > * { flex:1 1 calc(50% - 10px); }
  .story-mobile-list-card { padding:12px; }
  .story-mobile-comments-card .comment-reply { margin-left:8px; }
}


.reader-progress-track { position:sticky; top:0; z-index:60; height:4px; background:transparent; }
.reader-progress-track span { display:block; height:100%; width:0; background:var(--accent); box-shadow:0 0 14px rgba(245,158,11,.35); transition:width .12s linear; }

/* Reader redesign */
.reader-page-shell { display:grid; gap:18px; padding-bottom:88px; }
.reader-hero { background:linear-gradient(180deg, rgba(245,158,11,.12), rgba(245,158,11,0)) , var(--panel); }
.reader-hero__top, .reader-hero__actions, .reader-layout-grid, .reader-copy-bar, .reader-copy-actions, .reader-nav-actions, .reader-toolbar-grid, .reader-mobile-tools, .reader-story-card__summary, .reader-story-card__actions { display:flex; gap:12px; }
.reader-hero__top { justify-content:space-between; align-items:flex-start; flex-wrap:wrap; }
.reader-kicker, .reader-back-link { color:var(--accent); font-weight:700; margin:0 0 6px; display:inline-block; }
.reader-hero h1 { margin:0 0 10px; font-size:clamp(1.8rem, 4vw, 2.6rem); line-height:1.15; }
.reader-hero__meta { margin:0; color:var(--muted); }
.reader-hero__chips { display:flex; gap:8px; flex-wrap:wrap; }
.reader-chip { display:inline-flex; align-items:center; padding:8px 12px; border-radius:6px; border:1px solid var(--line); background:var(--panel-soft); font-size:13px; }
.reader-hero__actions { flex-wrap:wrap; }
.reader-layout-grid { display:grid; grid-template-columns:minmax(0,1.6fr) minmax(280px,.9fr); align-items:start; }

.reader-hero__actions { display:grid; grid-template-columns:repeat(auto-fit, minmax(140px, 1fr)); gap:10px; width:100%; }
.reader-hero__actions .button { width:100%; }
.reader-story-card__actions { display:grid; grid-template-columns:repeat(auto-fit, minmax(140px, 1fr)); gap:10px; }
.reader-story-card__actions .button { width:100%; margin:0; }
.reader-main-column, .reader-side-column { display:grid; gap:16px; }
.reader-content-card { padding:0; overflow:hidden; }
.reader-copy-bar { justify-content:space-between; align-items:center; padding:14px 18px; border-bottom:1px solid var(--line); color:var(--muted); flex-wrap:wrap; }
.reading-content { padding:22px 20px 30px; font-size:1.05rem; line-height:1.9; }
.reading-content p:first-child { margin-top:0; }
.reader-navigation-card .pagenavi-wrap { margin-top:14px; display:grid; gap:16px; }

.reader-navigation-card .pagenavi-summary {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
  margin: 0;
}
.reader-navigation-card .pagenavi-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-bottom: 8px;
}
.reader-navigation-card .pagenavi-link,
.reader-navigation-card .pagenavi-gap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  min-width: 48px;
  padding: 10px 16px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--text);
  font-weight: 700;
  line-height: 1;
}
.reader-navigation-card .pagenavi-link:hover {
  background: var(--panel-soft);
}
.reader-navigation-card .pagenavi-link.active {
  background: var(--accent);
  color: #111827;
  border-color: transparent;
  box-shadow: 0 10px 20px rgba(245, 158, 11, .22);
}
.reader-navigation-card .pagenavi-link.disabled,
.reader-navigation-card .pagenavi-gap {
  opacity: .72;
}
.reader-nav-actions {
  margin-top: 8px;
  row-gap: 14px;
  column-gap: 14px;
}
.reader-nav-actions .button {
  flex: 0 0 auto;
}
@media (max-width: 640px) {
  .reader-navigation-card .pagenavi-wrap {
    gap: 14px;
  }
  .reader-navigation-card .pagenavi-nav {
    gap: 10px;
    margin-bottom: 2px;
  }
  .reader-navigation-card .pagenavi-link,
  .reader-navigation-card .pagenavi-gap {
    min-width: 48px;
    min-height: 48px;
    padding: 10px 14px;
    border-radius: 14px;
    font-size: 16px;
  }
  .reader-nav-actions {
    margin-top: 12px;
  }
}
.reader-nav-actions, .reader-toolbar-grid, .reader-story-card__actions { flex-wrap:wrap; }
.reader-toolbar-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); }
.reader-mobile-tools { display:flex; flex-wrap:wrap; }
.reading-pill { border:1px solid var(--line); background:var(--panel-soft); color:var(--text); border-radius:6px; padding:8px 12px; }
.reader-story-card__summary { align-items:center; }
.reader-story-card__cover { width:72px; aspect-ratio:2/3; object-fit:cover; border-radius:14px; border:1px solid var(--line); }
.reader-related-grid { padding-top:0; grid-template-columns:1fr; }
.reader-mobile-dock {
  position:fixed; left:12px; right:12px; bottom:12px; z-index:35;
  display:none; grid-template-columns:repeat(4,minmax(0,1fr)); gap:10px;
  background:rgba(15,23,32,.9); border:1px solid var(--line); backdrop-filter:blur(10px);
  border-radius:20px; padding:10px; box-shadow:0 16px 40px rgba(0,0,0,.22);
}
html[data-theme='light'] .reader-mobile-dock { background:rgba(255,255,255,.92); }
.reader-mobile-dock a, .reader-mobile-dock span { display:flex; align-items:center; justify-content:center; padding:10px 8px; border-radius:14px; background:var(--panel-soft); font-weight:700; }
.reader-mobile-dock .is-disabled { opacity:.45; }
.reader-page-shell--immersive .reader-hero,
.reader-page-shell--immersive .reader-navigation-card,
.reader-page-shell--immersive .reader-tools-card,
.reader-page-shell--immersive .reader-related-card { background:rgba(24,33,45,.72); }
.reader-page-shell--immersive .reader-layout-grid { grid-template-columns:minmax(0,1fr); }
.reader-page-shell--immersive .reader-side-column { display:none; }
.reader-page-shell--immersive .reader-main-column { max-width:900px; margin:0 auto; }
.reader-page-shell--immersive .reader-content-card { box-shadow:0 22px 48px rgba(0,0,0,.22); }
.reader-page-shell--immersive .reader-copy-bar { position:sticky; top:12px; z-index:20; backdrop-filter:blur(10px); }
.reader-immersive-active .site-header, .reader-immersive-active .site-announcement, .reader-immersive-active .mobile-bottom-nav, .reader-immersive-active .site-footer { display:none; }
.reading-pill.is-active { background:var(--accent); color:#fff; border-color:var(--accent); }
.reader-page-shell[data-reading-bg='sepia'] .reader-content-card { background:#231a11; border-color:#4a3823; }
.reader-page-shell[data-reading-bg='sepia'] .reading-content { color:#f4e7ce; }
.reader-page-shell[data-reading-bg='night'] .reader-content-card { background:#0a1018; border-color:#1c2a39; }
.reader-page-shell[data-reading-bg='night'] .reading-content { color:#d8e4f3; }

@media (max-width: 980px) {
  .home-hero-grid { grid-template-columns:1fr; }
  .reader-layout-grid { grid-template-columns:1fr; }
  .reader-related-grid { grid-template-columns:repeat(auto-fit,minmax(220px,1fr)); }
}

@media (max-width: 720px) {
  .reader-page-shell { padding-bottom:104px; }
  .reader-hero { padding:18px; }
  .reader-content-card { border-radius:22px; }
  .reader-copy-bar { padding:12px 14px; }
  .reading-content { padding:18px 16px 26px; font-size:1.02rem; }
  .reader-toolbar-grid { display:none; }
  .reader-mobile-dock { display:grid; }
}

/* Listing / library redesign */
.listing-shell { display:grid; gap:18px; }
.listing-hero {
  display:grid; grid-template-columns:minmax(0,1.3fr) auto; gap:16px; align-items:end;
  padding:22px; background:linear-gradient(180deg, rgba(245,158,11,.14), rgba(245,158,11,0)), var(--panel);
}
.listing-kicker { display:inline-block; margin-bottom:8px; color:var(--accent); font-size:12px; font-weight:800; letter-spacing:.16em; text-transform:uppercase; }
.listing-hero h1 { margin:0 0 8px; font-size:clamp(1.8rem, 4vw, 2.6rem); line-height:1.05; }
.listing-hero__copy .meta { margin:0; max-width:62ch; }
.listing-hero__actions, .listing-action-row, .listing-chip-row, .listing-stat-row { display:flex; gap:10px; flex-wrap:wrap; }
.listing-hero__actions { justify-content:flex-end; align-items:center; }
.listing-chip-row { margin-top:14px; }
.listing-filter-card, .listing-recommended-card { padding:20px; }
.listing-filter-form-v2 { display:grid; gap:14px; }
.listing-filter-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:12px; }
.listing-filter-grid--single { grid-template-columns:minmax(0,1fr); }
.field-block--wide { grid-column:span 2; }
.listing-action-row { align-items:center; }
.listing-action-row--compact { gap:8px; }
.listing-grid-section { display:grid; gap:16px; }
.section-heading--mobile-spread { display:flex; justify-content:space-between; align-items:end; gap:16px; flex-wrap:wrap; }
.listing-story-grid { grid-template-columns:repeat(auto-fit,minmax(240px,1fr)); }
.listing-story-grid--compact { grid-template-columns:repeat(auto-fit,minmax(220px,1fr)); }
.listing-empty-state { padding:22px; }
.pdf-novel-grid--redesign { display:grid; grid-template-columns:repeat(auto-fit,minmax(280px,1fr)); gap:16px; }
.pdf-novel-card--redesign { display:grid; grid-template-columns:100px 1fr; gap:14px; align-items:start; }
.pdf-novel-card--redesign .pdf-novel-cover, .pdf-novel-card--redesign .pdf-novel-cover img { width:100px; }
.pdf-novel-card--redesign .pdf-novel-cover img, .pdf-cover-placeholder { aspect-ratio:3/4; border-radius:16px; object-fit:cover; }
.pdf-cover-placeholder { display:grid; place-items:center; background:var(--panel-soft); border:1px solid var(--line); color:var(--muted); font-weight:800; }
.pdf-novel-card--redesign h2 { margin:10px 0 8px; font-size:1.15rem; line-height:1.25; }
.pdf-novel-card--redesign p { margin:0 0 10px; }
.listing-stat-row { color:var(--muted); font-size:13px; margin-bottom:12px; }
.authors-grid--redesign { display:grid; grid-template-columns:repeat(auto-fit,minmax(240px,1fr)); gap:16px; }
.author-card--redesign { display:grid; gap:14px; }
.author-card__head { display:flex; gap:12px; align-items:center; }
.author-card__head h3 { margin:0 0 4px; }
.author-card__bio { margin:0; color:var(--muted); }
.author-card--redesign .avatar { width:72px; height:72px; border-radius:18px; object-fit:cover; border:1px solid var(--line); }
.author-card--redesign .avatar.placeholder { display:grid; place-items:center; background:var(--panel-soft); font-size:1.4rem; font-weight:800; }

@media (max-width: 980px) {
  .listing-hero { grid-template-columns:1fr; align-items:start; }
  .listing-hero__actions { justify-content:flex-start; }
  .listing-filter-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
}

@media (max-width: 700px) {
  .listing-shell { gap:14px; }
  .listing-hero, .listing-filter-card, .listing-recommended-card { padding:16px; border-radius:22px; }
  .listing-hero h1 { font-size:1.9rem; }
  .listing-filter-grid { grid-template-columns:1fr; }
  .field-block--wide { grid-column:auto; }
  .listing-story-grid,
  .listing-story-grid--compact,
  .authors-grid--redesign,
  .pdf-novel-grid--redesign { grid-template-columns:1fr; }
  .pdf-novel-card--redesign { grid-template-columns:86px 1fr; }
  .pdf-novel-card--redesign .pdf-novel-cover,
  .pdf-novel-card--redesign .pdf-novel-cover img { width:86px; }
  .listing-hero__actions > *,
  .listing-action-row > * { flex:1 1 calc(50% - 10px); text-align:center; justify-content:center; }
  .listing-chip-row { gap:8px; }
}


/* v130 performance and UX polish */
body { text-rendering:optimizeLegibility; -webkit-font-smoothing:antialiased; }
.site-shell { width:min(100%, 1440px); }
.page-grid.no-sidebar { width:min(100%, 1440px); margin-inline:auto; }
@media (min-width: 1280px) {
  .page-grid { grid-template-columns:minmax(0,1fr) 340px; gap:24px; }
}
.mobile-home-section.panel,
.mobile-featured-card,
.mobile-story-row,
.mobile-update-row,
.listing-grid-section,
.reader-content-card,
.reader-navigation-card,
.reader-tools-card,
.reader-related-card { content-visibility:auto; contain-intrinsic-size: 1px 520px; }
.mobile-home-main > .panel:first-child,
.reader-content-card { content-visibility:visible; }
.mobile-home-sidebar { align-self:start; }
.mobile-story-list { grid-template-columns:1fr; }
@media (min-width: 980px) {
  .mobile-home-main { grid-template-columns:minmax(0,1fr); }
  .mobile-story-list { grid-template-columns:1fr; }
}
@media (min-width: 1200px) {
  .mobile-featured-stack { grid-template-columns:minmax(0,1.2fr) minmax(0,.8fr); }
}
.mobile-update-row { min-height:72px; }
.mobile-update-row strong { flex:1; min-width:0; }
.reader-mobile-dock { padding-bottom: max(10px, env(safe-area-inset-bottom)); }
.reader-page .site-footer, .reader-page .mobile-bottom-nav { display:none !important; }
.reader-page .page-grid.no-sidebar { padding-bottom: 18px; }
@media (max-width: 720px) {
  .site-shell, .container { padding-inline:12px; }
  .mobile-home-hero h1 { font-size: clamp(2rem, 8vw, 2.7rem); }
  .mobile-section-head h2 { font-size: clamp(1.5rem, 6vw, 2rem); }
  .reader-mobile-dock { left:10px; right:10px; bottom:10px; }
}


/* v132 author profile cleanup */
.rr-author-shell {
  display:grid;
  gap:22px;
}
.rr-author-panel {
  display:grid;
  gap:18px;
}
.rr-author-hero {
  overflow:hidden;
  padding:0;
}
.rr-author-banner {
  min-height:120px;
  background:linear-gradient(135deg, rgba(245,158,11,.18), rgba(59,130,246,.12));
  border-bottom:1px solid var(--line);
}
.rr-author-hero-inner {
  display:grid;
  grid-template-columns:132px minmax(0,1fr);
  gap:22px;
  padding:22px;
  margin-top:-54px;
}
.rr-author-avatar-wrap {
  display:flex;
  align-items:flex-start;
  justify-content:center;
}
.rr-author-avatar {
  width:120px;
  height:120px;
  border-radius:28px;
  object-fit:cover;
  border:3px solid rgba(255,255,255,.75);
  box-shadow:0 14px 30px rgba(0,0,0,.18);
  background:var(--panel-soft);
}
html[data-theme='dark'] .rr-author-avatar {
  border-color:rgba(15,23,32,.9);
}
.rr-author-main {
  min-width:0;
  display:grid;
  gap:18px;
}
.rr-author-name {
  margin:0;
  font-size:clamp(2rem, 4vw, 3rem);
  line-height:1.02;
}
.rr-author-handle { margin-top:6px; }
.rr-author-stat-row {
  display:grid;
  grid-template-columns:repeat(5,minmax(0,1fr));
  gap:12px;
}
.rr-author-stat,
.rr-info-grid > div {
  display:grid;
  gap:6px;
  padding:14px;
  border:1px solid var(--line);
  border-radius:18px;
  background:var(--panel-soft);
}
.rr-author-stat strong,
.rr-info-grid strong {
  font-size:1.2rem;
  line-height:1.1;
}
.rr-author-stat span,
.rr-info-grid span {
  color:var(--muted);
  font-size:.82rem;
  text-transform:uppercase;
  letter-spacing:.04em;
}
.rr-author-tabs {
  display:flex;
  gap:10px;
  flex-wrap:wrap;
}
.rr-author-tabs a {
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:44px;
  padding:10px 14px;
  border-radius:14px;
  border:1px solid var(--line);
  background:var(--panel-soft);
  font-weight:700;
}
.rr-author-tabs a.active {
  background:var(--accent);
  color:#111827;
  border-color:transparent;
}
.rr-author-grid {
  display:grid;
  grid-template-columns:minmax(0,1.1fr) minmax(0,.9fr);
  gap:22px;
}
.rr-about-text {
  padding:16px 18px;
  border:1px solid var(--line);
  border-radius:18px;
  background:var(--panel-soft);
  line-height:1.75;
}
.rr-info-grid {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:12px;
}
.rr-featured-list,
.rr-release-list,
.rr-analytics-list {
  display:grid;
  gap:14px;
}
.rr-featured-item,
.rr-release-item,
.rr-analytics-item {
  display:grid;
  gap:12px;
  padding:16px;
  border:1px solid var(--line);
  border-radius:18px;
  background:var(--panel-soft);
}
.rr-featured-item {
  grid-template-columns:72px minmax(0,1fr);
  align-items:center;
}
.rr-featured-item img,
.rr-featured-item .cover-placeholder {
  width:72px;
  height:96px;
  border-radius:16px;
  object-fit:cover;
  border:1px solid var(--line);
}
.rr-featured-copy {
  min-width:0;
  display:grid;
  gap:6px;
}
.rr-featured-copy strong,
.rr-release-copy strong {
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
}
.rr-release-item {
  grid-template-columns:minmax(0,1fr) auto;
  align-items:center;
}
.rr-release-copy {
  min-width:0;
  display:grid;
  gap:6px;
}
.rr-release-copy span {
  color:var(--muted);
}
.rr-analytics-item .rr-bar {
  width:100%;
  height:10px;
  border-radius:999px;
  background:rgba(148,163,184,.16);
  overflow:hidden;
}
.rr-analytics-item .rr-bar span,
.progress-bar span {
  display:block;
  height:100%;
  border-radius:inherit;
  background:linear-gradient(90deg, var(--accent), #f59e0b);
}
.achievement-grid,
.achievement-progress-grid {
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(220px,1fr));
  gap:14px;
}
.achievement-card,
.achievement-progress-card {
  display:grid;
  gap:12px;
  padding:16px;
  border:1px solid var(--line);
  border-radius:18px;
  background:var(--panel-soft);
}
.achievement-card {
  grid-template-columns:48px minmax(0,1fr);
  align-items:start;
}
.achievement-icon {
  width:48px;
  height:48px;
  display:grid;
  place-items:center;
  border-radius:16px;
  background:rgba(245,158,11,.12);
  font-size:1.4rem;
}
.achievement-progress-card .progress-bar {
  width:100%;
  height:10px;
  border-radius:999px;
  background:rgba(148,163,184,.16);
  overflow:hidden;
}
.rr-author-story-grid {
  padding-top:0;
}

@media (max-width: 1100px) {
  .rr-author-grid {
    grid-template-columns:1fr;
  }
  .rr-author-stat-row {
    grid-template-columns:repeat(3,minmax(0,1fr));
  }
}

@media (max-width: 760px) {
  .rr-author-shell {
    gap:16px;
  }
  .rr-author-hero-inner {
    grid-template-columns:1fr;
    margin-top:-44px;
    gap:16px;
    padding:16px;
  }
  .rr-author-avatar-wrap {
    justify-content:flex-start;
  }
  .rr-author-avatar {
    width:96px;
    height:96px;
    border-radius:24px;
  }
  .rr-author-stat-row,
  .rr-info-grid,
  .achievement-grid,
  .achievement-progress-grid {
    grid-template-columns:1fr 1fr;
  }
  .rr-release-item {
    grid-template-columns:1fr;
    align-items:start;
  }
}

@media (max-width: 560px) {
  .rr-author-stat-row,
  .rr-info-grid,
  .achievement-grid,
  .achievement-progress-grid {
    grid-template-columns:1fr;
  }
  .rr-featured-item {
    grid-template-columns:64px minmax(0,1fr);
  }
  .rr-featured-item img,
  .rr-featured-item .cover-placeholder {
    width:64px;
    height:84px;
  }
}

/* v134 PDF novel cards cleanup */
.pdf-novel-grid--storyish {
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(250px,1fr));
  gap:16px;
}
.pdf-novel-card--storyish {
  display:grid;
  gap:14px;
  align-content:start;
  min-height:100%;
  min-width:0;
  overflow:hidden;
}
.pdf-novel-title {
  margin:0;
  min-width:0;
  font-size:clamp(1.45rem, 1.8vw, 1.9rem);
  line-height:1.18;
}
.pdf-novel-title a {
  display:-webkit-box;
  -webkit-line-clamp:3;
  -webkit-box-orient:vertical;
  overflow:hidden;
  overflow-wrap:anywhere;
  word-break:break-word;
}
.pdf-novel-author {
  margin:0;
  min-width:0;
  font-size:clamp(1.05rem, 1.6vw, 1.2rem);
  font-weight:800;
  color:var(--accent);
  overflow-wrap:anywhere;
  word-break:break-word;
}
.pdf-novel-author a { color:inherit; }
.pdf-novel-origin {
  margin:-6px 0 0;
  min-width:0;
  font-size:1rem;
  overflow-wrap:anywhere;
  word-break:break-word;
}
.pdf-novel-origin a { color:var(--text); }
.story-stat-pill {
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:7px 12px;
  border-radius:999px;
  border:1px solid var(--line);
  background:var(--panel-soft);
  color:var(--muted);
  font-size:13px;
  line-height:1;
}
.pdf-novel-actions {
  margin-top:auto;
}
.pdf-novel-actions .button {
  min-width:132px;
}
@media (max-width:700px) {
  .pdf-novel-grid--storyish { grid-template-columns:1fr; }
  .pdf-novel-card--storyish { gap:12px; }
  .pdf-novel-title { font-size:1.28rem; }
  .pdf-novel-author { font-size:1rem; }
}


.story-mobile-comments-card .comment-composer {
  width: 100%;
  display: grid;
  gap: 12px;
  padding: 16px;
}
.story-mobile-comments-card .story-comment-textarea {
  width: 100%;
  min-height: 150px;
  resize: none;
  display: block;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--text);
  line-height: 1.6;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.03);
}
.story-mobile-comments-card .story-comment-textarea::placeholder {
  color: var(--muted);
}
.story-mobile-comments-card .story-comment-textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(99,102,241,.16);
}
.story-mobile-comments-card .comment-composer > .button {
  justify-self: start;
}
.story-mobile-comments-card .replying-indicator {
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 14px;
  background: var(--panel-soft);
  border: 1px solid var(--line);
}
.story-mobile-comments-card .replying-indicator.active {
  display: flex;
}
.story-mobile-comments-card .comment-card p,
.story-mobile-comments-card .comment-reply p {
  margin: 8px 0 0;
  line-height: 1.65;
}
.story-mobile-comments-card .comment-card .cluster,
.story-mobile-comments-card .comment-reply .cluster {
  margin-top: 10px;
}
@media (max-width: 700px) {
  .story-mobile-comments-card .comment-composer {
    padding: 14px;
  }
  .story-mobile-comments-card .story-comment-textarea {
    min-height: 140px;
  }
  .story-mobile-comments-card .comment-composer > .button {
    width: 100%;
    justify-content: center;
  }
  .story-mobile-comments-card .replying-indicator {
    flex-direction: column;
    align-items: stretch;
  }
}


/* v140 comment UI polish */
.story-mobile-comments-card .comment-user {
  display:flex;
  align-items:flex-start;
  gap:12px;
}
.story-mobile-comments-card .comment-avatar {
  width:42px;
  height:42px;
  min-width:42px;
  border-radius:50%;
  object-fit:cover;
  display:grid;
  place-items:center;
  font-size:1rem;
  font-weight:700;
  background:var(--panel-soft);
  border:1px solid var(--line);
  color:var(--text);
}
.story-mobile-comments-card .comment-avatar.small {
  width:34px;
  height:34px;
  min-width:34px;
  font-size:.9rem;
}
.story-mobile-comments-card .comment-user-line {
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  gap:4px;
  line-height:1.2;
}
.story-mobile-comments-card .comment-user-link {
  font-weight:700;
  color:var(--text);
  text-decoration:none;
}
.story-mobile-comments-card .comment-role-text {
  font-size:1rem;
  font-weight:700;
}
.story-mobile-comments-card .comment-role-text.author { color:#f59e0b; }
.story-mobile-comments-card .comment-role-text.staff { color:#38bdf8; }
.story-mobile-comments-card .comment-role-text.admin { color:#ef4444; }
.story-mobile-comments-card .meta {
  margin-top:4px;
  font-size:.86rem;
  color:var(--muted);
}
.story-mobile-comments-card .story-comment-textarea {
  overflow:hidden;
}
@media (max-width:700px) {
  .story-mobile-comments-card .comment-avatar {
    width:38px;
    height:38px;
    min-width:38px;
  }
  .story-mobile-comments-card .comment-avatar.small {
    width:30px;
    height:30px;
    min-width:30px;
  }
}


/* Story detail continue reading CTA */
.mobile-story-cta {
  margin-top: 18px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: flex-start;
}
.mobile-story-cta-btn {
  min-height: 52px;
  border-radius: 16px;
  box-shadow: var(--shadow);
}
@media (max-width: 720px) {
  .mobile-story-cta {
    margin-top: 20px;
    padding-top: 14px;
    justify-content: stretch;
  }
  .mobile-story-cta-btn {
    width: 100%;
  }
}


.site-announcement{background:rgba(245,158,11,.12);border-bottom:1px solid rgba(245,158,11,.25);font-size:.95rem}.site-announcement .site-shell{padding:.7rem 1rem;text-align:center}.site-announcement a,.site-announcement span{color:var(--text);text-decoration:none;font-weight:600;display:block}

@media (max-width:700px) {
  .header-actions { gap:8px; }
  .site-search input { padding:10px 12px; }
  .site-search button, .theme-switch, .mobile-theme-switch {
    min-height:40px;
    padding:10px 12px;
    font-size:13px;
  }
  .theme-switch, .mobile-theme-switch { min-width:96px; }
  .theme-switch-label { min-width:60px; }
}


.shelf-grid { display:grid; grid-template-columns:repeat(auto-fit, minmax(220px,1fr)); gap:14px; }
.shelf-card {
  display:grid;
  gap:12px;
  padding:16px;
  border:1px solid var(--line);
  border-radius:18px;
  background:var(--panel-soft);
}
.shelf-card h3 { margin:0; font-size:1rem; }
.shelf-card .meta { margin:0; }
.shelf-card__actions { display:flex; flex-wrap:wrap; gap:10px; }
.reader-nav-actions .button, .reader-story-card__actions .button { flex:1 1 180px; }
.reader-mobile-dock a, .reader-mobile-dock span {
  border-radius:var(--button-radius);
  min-height:42px;
  display:flex;
  align-items:center;
  justify-content:center;
}
@media (max-width: 720px) {
  .site-search button, .button, .btn, .theme-switch, .mobile-theme-switch, .share-btn, .reading-pill {
    min-height:40px;
    padding:10px 12px;
    border-radius:var(--button-radius);
  }
  .reader-copy-bar { gap:10px; }
  .reader-copy-actions { width:100%; display:grid; grid-template-columns:1fr 1fr; gap:10px; }
  .reader-navigation-card { position:relative; }
  .reader-nav-actions { position:sticky; bottom:72px; z-index:12; background:var(--panel); padding-top:10px; }
  .reader-nav-actions .button { flex:1 1 calc(50% - 8px); }
  .reader-hero__actions { grid-template-columns:1fr 1fr; }
  .reader-story-card__actions { grid-template-columns:1fr; }
}


/* royalroad_208 polish */
:root {
  --button-radius: 6px;
  --button-height: 42px;
}

.button, .btn, .site-search button, .theme-switch, .mobile-theme-switch, .share-btn, .reading-pill,
.mobile-breadcrumb-toggle, .reader-mobile-dock a, .reader-mobile-dock span, .main-nav a {
  border-radius: var(--button-radius) !important;
}

.button, .btn, .site-search button, .theme-switch, .mobile-theme-switch, .share-btn, .reading-pill {
  min-height: var(--button-height);
  padding: 10px 14px;
  font-weight: 700;
}

.main-nav a {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 14px;
}

.hero,
.mobile-home-hero,
.story-mobile-hero,
.story-detail-main-card,
.story-mobile-side-card,
.story-mobile-related-card,
.story-mobile-comments-card,
.reader-hero,
.reader-content-card,
.reader-tools-card,
.reader-story-card,
.reader-related-card,
.reader-navigation-card,
.reader-sponsor-card,
.mobile-home-section.panel,
.continue-reading-card,
.story-card,
.stack-card,
.panel {
  border-radius: 20px;
}

.home-hero-grid {
  gap: 20px;
}

.hero {
  padding: 28px;
}

.hero h1 {
  line-height: 1.08;
  max-width: 14ch;
}

.continue-reading-card {
  padding: 18px;
  background: linear-gradient(180deg, rgba(245,158,11,.12), rgba(245,158,11,.04));
}
html[data-theme='light'] .continue-reading-card {
  background: linear-gradient(180deg, rgba(201,119,0,.10), rgba(201,119,0,.03));
}

.section-heading,
.mobile-section-head,
.story-section-head {
  gap: 14px;
}

.story-grid,
.aurora-card-grid,
.reader-related-grid {
  gap: 18px;
}

.story-card {
  height: 100%;
  padding: 18px;
}
.story-card-body {
  gap: 10px;
}
.story-card .story-title a {
  line-height: 1.3;
}
.story-badges, .story-stats, .story-actions-row, .pdf-novel-actions, .pdf-novel-badges {
  gap: 10px;
}

.story-mobile-stats-grid div,
.story-mobile-list-card,
.reader-story-card__summary,
.reader-copy-bar,
.reader-tools-card .reader-toolbar-grid,
.reader-tools-card .reader-mobile-tools,
.comment-card,
.comment-reply {
  border-radius: 16px;
}

.story-mobile-stats-grid div {
  min-height: 78px;
}

.story-mobile-actions > *,
.story-mobile-inline-actions > *,
.story-mobile-side-actions > * {
  justify-content: center;
}

.story-mobile-description,
.reading-content {
  text-wrap: pretty;
}

.reading-content {
  font-size: clamp(1.04rem, 0.98rem + .22vw, 1.14rem);
}

.reading-content p {
  margin: 0 0 1.15em;
}

.reader-toolbar-grid {
  gap: 10px;
}

.reading-pill {
  min-width: 0;
  flex: 1 1 auto;
}

.reader-mobile-dock {
  gap: 10px;
  padding: 12px;
  border-radius: 16px;
}

.reader-mobile-dock a, .reader-mobile-dock span {
  min-height: 44px;
}

.dashboard-two-col,
.story-detail-grid,
.reader-layout-grid {
  gap: 20px;
}

@media (max-width: 980px) {
  .hero {
    padding: 22px;
  }
  .hero h1 {
    max-width: none;
  }
  .story-detail-grid,
  .reader-layout-grid,
  .dashboard-two-col {
    gap: 16px;
  }
}

@media (max-width: 720px) {
  .site-shell, .container {
    padding: 0 14px;
  }
  .header-shell {
    gap: 8px;
    padding: 8px 0 12px;
  }
  .header-actions {
    width: 100%;
    justify-content: stretch;
  }
  .site-search {
    max-width: none;
  }
  .site-search input {
    min-height: 42px;
    border-radius: 6px;
  }
  .main-nav a,
  .mobile-breadcrumb-toggle,
  .mobile-breadcrumb-list a,
  .button,
  .btn,
  .theme-switch,
  .mobile-theme-switch,
  .share-btn,
  .reading-pill,
  .site-search button {
    border-radius: 6px !important;
  }
  .mobile-home-hero,
  .story-mobile-hero,
  .story-detail-main-card,
  .story-mobile-side-card,
  .story-mobile-related-card,
  .story-mobile-comments-card,
  .reader-hero,
  .reader-content-card,
  .reader-tools-card,
  .reader-story-card,
  .reader-related-card,
  .reader-navigation-card,
  .reader-sponsor-card,
  .mobile-home-section.panel,
  .panel,
  .stack-card,
  .story-card {
    border-radius: 16px;
  }
  .mobile-home-hero {
    padding: 18px;
  }
  .mobile-home-greeting,
  .mobile-continue-card,
  .story-mobile-list-card,
  .story-mobile-stats-grid div,
  .reader-copy-bar {
    border-radius: 14px;
  }
  .story-mobile-actions > *,
  .story-mobile-inline-actions > *,
  .story-mobile-side-actions > * {
    flex: 1 1 100%;
  }
  .story-mobile-stats-grid {
    gap: 8px;
  }
  .reader-mobile-dock {
    grid-template-columns: repeat(4, minmax(0,1fr));
    left: 10px;
    right: 10px;
  }
  .reading-content {
    font-size: 1.08rem;
    line-height: 2;
  }
}


/* 209 homepage feature refinement */
.home-featured-block { overflow:hidden; }
.home-featured-grid {
  display:grid;
  grid-template-columns:minmax(0,1.35fr) minmax(280px,.85fr);
  gap:20px;
  align-items:stretch;
}
.home-featured-story {
  display:grid;
  grid-template-columns:220px minmax(0,1fr);
  gap:18px;
  padding:18px;
  border:1px solid var(--line);
  border-radius:18px;
  background:linear-gradient(180deg, rgba(245,158,11,.10), rgba(245,158,11,.03));
}
html[data-theme='light'] .home-featured-story {
  background:linear-gradient(180deg, rgba(201,119,0,.08), rgba(201,119,0,.02));
}
.home-featured-cover, .home-featured-mini-thumb {
  display:block;
  text-decoration:none;
}
.home-featured-cover img, .home-featured-mini-thumb img {
  width:100%;
  height:100%;
  object-fit:cover;
  border-radius:16px;
  border:1px solid var(--line);
  aspect-ratio:2/3;
}
.home-featured-cover span, .home-featured-mini-thumb span {
  display:grid;
  place-items:center;
  border-radius:16px;
  border:1px solid var(--line);
  background:linear-gradient(135deg,#223247,#131b24);
  color:#fff;
  font-size:2.2rem;
  font-weight:800;
  aspect-ratio:2/3;
}
.home-featured-copy { display:grid; gap:12px; align-content:start; }
.home-featured-badges, .home-featured-stats, .home-featured-actions, .home-featured-mini-meta { display:flex; gap:10px; flex-wrap:wrap; }
.home-featured-badges span, .home-featured-stats span, .reader-stat-pill {
  display:inline-flex;
  align-items:center;
  min-height:36px;
  padding:6px 12px;
  border:1px solid var(--line);
  border-radius:12px;
  background:var(--panel-soft);
  font-weight:700;
}
.home-featured-copy h3, .home-featured-side__head h3, .home-featured-mini-copy h4 { margin:0; }
.home-featured-copy h3 a, .home-featured-mini-copy h4 a { color:inherit; }
.home-featured-author { margin:0; color:var(--muted); font-weight:700; }
.home-featured-summary { margin:0; }
.home-featured-side {
  display:grid;
  gap:14px;
  padding:18px;
  border:1px solid var(--line);
  border-radius:18px;
  background:var(--panel-soft);
}
.home-featured-mini-list { display:grid; gap:12px; }
.home-featured-mini-card {
  display:grid;
  grid-template-columns:72px minmax(0,1fr);
  gap:12px;
  align-items:center;
  padding:12px;
  border:1px solid var(--line);
  border-radius:16px;
  background:var(--panel);
}
.home-featured-mini-copy { display:grid; gap:6px; min-width:0; }
.home-featured-mini-copy p { margin:0; color:var(--muted); }
.home-featured-mini-copy h4 a {
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
}
.home-featured-mini-meta span { color:var(--muted); font-size:.92rem; }

/* 209 chapter polish */
.reader-hero__stats { display:flex; flex-wrap:wrap; gap:10px; margin-top:12px; }
.reader-content-card { position:relative; }
.reader-copy-bar {
  position:sticky;
  top:12px;
  z-index:10;
  backdrop-filter:blur(10px);
  background:color-mix(in srgb, var(--panel) 92%, transparent);
}
.reader-copy-actions .share-btn {
  min-height:42px;
  padding:10px 14px;
  border-radius:6px;
  border:1px solid var(--line);
  background:var(--panel-soft);
  color:var(--text);
  font-weight:700;
}
.reader-nextup-shell {
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:16px;
  flex-wrap:wrap;
}
.reader-nextup-shell strong { display:block; font-size:1.05rem; margin-bottom:6px; }
.reader-story-card__actions .button,
.reader-nav-actions .button,
.reader-hero__actions .button,
.reader-copy-actions .share-btn {
  min-height:44px;
  border-radius:6px;
}
.reader-navigation-card,
.reader-nextup-card,
.reader-sponsor-card,
.reader-tools-card,
.reader-story-card,
.reader-related-card {
  scroll-margin-top:90px;
}

@media (max-width: 980px) {
  .home-featured-grid { grid-template-columns:1fr; }
}
@media (max-width: 720px) {
  .home-featured-story { grid-template-columns:96px minmax(0,1fr); padding:14px; gap:14px; }
  .home-featured-side { padding:14px; }
  .home-featured-mini-card { grid-template-columns:64px minmax(0,1fr); }
  .reader-copy-bar { top:8px; padding:12px; }
  .reader-hero__stats { gap:8px; }
  .reader-stat-pill { min-height:34px; padding:6px 10px; }
}


/* 212 global button consistency pass */
:root {
  --button-radius:6px;
}

#scrollTopBtn,
.mobile-breadcrumb-toggle,
.mobile-section-head a,
.reader-navigation-card .pagenavi-link,
.reader-navigation-card .pagenavi-gap,
.reader-mobile-dock a,
.reader-mobile-dock span,
.reader-copy-actions .share-btn,
.reader-nav-actions .button,
.reader-hero__actions .button,
.reader-story-card__actions .button,
.reader-toolbar-grid .button,
.reader-mobile-tools .reading-pill {
  border-radius:var(--button-radius) !important;
}

#scrollTopBtn {
  min-width:46px;
  min-height:46px;
}

.mobile-section-head a,
.reader-navigation-card .pagenavi-link,
.reader-navigation-card .pagenavi-gap,
.reader-mobile-dock a,
.reader-mobile-dock span {
  min-height:var(--button-height);
  padding:10px 14px;
  font-size:14px;
  font-weight:700;
  line-height:1;
}

.reader-hero__actions {
  margin-top:18px;
}

@media (max-width: 720px) {
  .reader-hero__actions {
    margin-top:16px;
  }
}


/* Author cards cleanup */
.authors-grid--clean {
  display:grid;
  grid-template-columns:repeat(auto-fit, minmax(240px, 1fr));
  gap:18px;
}
.author-card--clean {
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:flex-start;
  text-align:center;
  gap:8px;
  padding:20px;
}
.author-card__avatar {
  width:72px;
  height:72px;
  border-radius:12px;
  object-fit:cover;
  border:1px solid var(--line);
  display:block;
}
.author-card__avatar--placeholder {
  display:grid;
  place-items:center;
  background:var(--panel-soft);
  font-size:1.5rem;
  font-weight:800;
}
.author-card__name {
  margin:2px 0 0;
  font-size:1.2rem;
  line-height:1.2;
}
.author-card__name a {
  color:var(--ink);
  text-decoration:none;
}
.author-card__name a:hover {
  color:var(--accent);
}
.author-card__handle {
  margin:0;
  color:var(--muted);
  font-size:.95rem;
}
.author-card--clean .author-card__bio {
  margin:4px 0 10px;
  color:var(--muted);
  max-width:28ch;
  min-height:2.6em;
}
.author-card__actions {
  display:flex;
  gap:10px;
  justify-content:center;
  flex-wrap:wrap;
  margin-top:auto;
}
.author-card__actions .button {
  min-width:118px;
}
@media (max-width: 640px) {
  .authors-grid--clean {
    grid-template-columns:1fr;
  }
  .author-card__actions {
    width:100%;
  }
  .author-card__actions .button {
    flex:1 1 140px;
  }
}
