
/* Always respect view state, even when grid classes define display. */
[hidden] { display: none !important; }

:root {
  --bg: #f5f5f7;
  --ink: #111113;
  --muted: #6e6e73;
  --panel: rgba(255,255,255,0.78);
  --line: rgba(0,0,0,0.08);
  --shadow: 0 24px 70px rgba(0,0,0,0.12);
  --radius-xl: 32px;
  --radius-lg: 24px;
  --radius-md: 16px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(255,255,255,0.9), transparent 34rem),
    linear-gradient(135deg, #fbfbfd 0%, #f5f5f7 48%, #e9eaee 100%);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", sans-serif;
  letter-spacing: -0.02em;
}

.noise {
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.12;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.4'/%3E%3C/svg%3E");
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px clamp(18px, 5vw, 72px);
  backdrop-filter: blur(24px);
  background: rgba(245,245,247,0.72);
  border-bottom: 1px solid var(--line);
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  color: inherit;
  text-decoration: none;
}

.author-icon, .author-avatar {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: #111113;
  color: white;
  font-weight: 700;
  box-shadow: 0 16px 32px rgba(0,0,0,0.22);
}

.brand h1, .brand p { margin: 0; }
.brand h1 { font-size: 20px; }
.eyebrow {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.top-nav { display: flex; gap: 18px; }
.top-nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 14px;
  transition: color .2s ease;
}
.top-nav a:hover { color: var(--ink); }

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(280px, .9fr);
  gap: 28px;
  align-items: center;
  padding: clamp(48px, 8vw, 104px) clamp(18px, 5vw, 72px) 40px;
}
.hero h2 {
  margin: 0;
  font-size: clamp(44px, 7vw, 92px);
  line-height: .96;
  letter-spacing: -0.065em;
}
.hero-text {
  max-width: 620px;
  color: var(--muted);
  font-size: 19px;
  line-height: 1.8;
}
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 28px; }
.button {
  border: 0;
  border-radius: 999px;
  padding: 14px 22px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: transform .2s ease, box-shadow .2s ease;
}
.button:hover { transform: translateY(-2px); }
.primary { background: var(--ink); color: white; box-shadow: 0 14px 28px rgba(0,0,0,0.18); }
.ghost { background: rgba(255,255,255,.72); color: var(--ink); border: 1px solid var(--line); }

.hero-card {
  min-height: 430px;
  border-radius: 44px;
  background:
    linear-gradient(145deg, rgba(0,0,0,.78), rgba(25,25,29,.92)),
    radial-gradient(circle at 70% 25%, rgba(255,255,255,.35), transparent 16rem);
  box-shadow: var(--shadow);
  display: grid;
  place-items: end start;
  padding: 28px;
  overflow: hidden;
}
.glass-card {
  width: min(100%, 320px);
  padding: 26px;
  border-radius: 28px;
  background: rgba(255,255,255,.14);
  color: white;
  backdrop-filter: blur(28px);
  border: 1px solid rgba(255,255,255,.18);
}
.glass-card h3 { margin: 8px 0; font-size: 32px; }
.glass-card p { margin: 0; color: rgba(255,255,255,.72); }
.status-dot { display:block; width: 10px; height: 10px; border-radius: 50%; background: white; margin-bottom: 70px; }

.author-panel, .works-section, .security-section {
  padding: 38px clamp(18px, 5vw, 72px);
}
.profile-card {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 22px;
  text-align: left;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background: var(--panel);
  backdrop-filter: blur(24px);
  box-shadow: 0 14px 50px rgba(0,0,0,.06);
  cursor: pointer;
}
.profile-card h2, .profile-card p { margin: 0; }
.profile-card .tap-hint { margin-left: auto; color: var(--muted); font-weight: 700; }

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 22px;
}
.section-heading h2, .security-section h2 { margin: 0; font-size: clamp(32px, 5vw, 56px); }
.language-select { display: grid; gap: 6px; color: var(--muted); font-size: 13px; }
select {
  border: 1px solid var(--line);
  background: rgba(255,255,255,.82);
  border-radius: 999px;
  padding: 11px 16px;
  font-weight: 700;
  color: var(--ink);
}

.cover-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.cover-card {
  position: relative;
  min-height: 430px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
  padding: 24px;
  border: 1px solid rgba(255,255,255,.5);
  border-radius: 30px;
  color: white;
  cursor: pointer;
  box-shadow: 0 18px 42px rgba(0,0,0,.12);
  transition: transform .24s ease, box-shadow .24s ease;
}
.cover-card:hover { transform: translateY(-6px); box-shadow: 0 28px 70px rgba(0,0,0,.18); }
.cover-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--cover-bg);
  z-index: -2;
}
.cover-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,.86), rgba(0,0,0,.12) 62%, rgba(255,255,255,.1));
  z-index: -1;
}
.cover-card h3 { margin: 8px 0 10px; font-size: 30px; }
.cover-card p { margin: 0; color: rgba(255,255,255,.76); line-height: 1.6; }
.lang-badges { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 18px; }
.lang-badges span { padding: 6px 9px; border-radius: 999px; background: rgba(255,255,255,.16); font-size: 12px; font-weight: 700; }

.security-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-top: 24px; }
.security-grid article {
  padding: 22px;
  border-radius: 24px;
  background: rgba(255,255,255,.72);
  border: 1px solid var(--line);
}
.security-grid h3 { margin: 0 0 10px; }
.security-grid p { margin: 0; color: var(--muted); line-height: 1.7; }

.reader {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  grid-template-rows: auto 1fr auto;
  background: #050505;
  color: white;
}
.reader[hidden] { display: none; }
.reader-toolbar, .reader-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px clamp(14px, 3vw, 34px);
  background: rgba(5,5,5,.76);
  backdrop-filter: blur(24px);
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.reader-footer { border-top: 1px solid rgba(255,255,255,.08); border-bottom: 0; color: rgba(255,255,255,.62); }
.icon-button, .page-nav {
  border: 0;
  color: white;
  background: rgba(255,255,255,.1);
  border-radius: 50%;
  cursor: pointer;
}
.icon-button { width: 44px; height: 44px; font-size: 30px; }
.reader-title-block h2, .reader-title-block p { margin: 0; }
.reader-title-block h2 { font-size: 20px; }
.reader-controls { display: flex; align-items: center; gap: 10px; color: rgba(255,255,255,.62); }
.reader-controls select { background: rgba(255,255,255,.1); color: white; border-color: rgba(255,255,255,.14); }
.reader-controls option { color: #111; }

.reader-stage { position: relative; overflow: hidden; }
.page-track { height: 100%; display: flex; transition: transform .32s cubic-bezier(.2,.8,.2,1); }
.comic-page {
  flex: 0 0 100%;
  min-width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  padding: 18px;
}
.page-art {
  width: min(92vw, 680px);
  height: min(78vh, 920px);
  border-radius: 18px;
  background: white;
  color: #111;
  box-shadow: 0 22px 80px rgba(0,0,0,.56);
  display: grid;
  place-items: center;
  position: relative;
  overflow: hidden;
}
.page-art::before { content:""; position:absolute; inset:18px; border:2px solid #111; border-radius: 10px; opacity:.85; }
.page-art h3 { font-size: clamp(32px, 8vw, 74px); margin: 0; letter-spacing: -0.06em; }
.page-art p { color: #555; max-width: 70%; text-align: center; line-height: 1.8; z-index: 1; }
.ad-page .page-art { background: linear-gradient(135deg, #fff, #eee); }
.ad-page .page-art::after { content:"Sponsored / Next Action"; position:absolute; bottom:30px; color:#777; font-size: 13px; font-weight: 700; letter-spacing:.12em; text-transform: uppercase; }
.page-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  width: 52px;
  height: 52px;
  font-size: 42px;
}
.prev { left: 20px; }
.next { right: 20px; }
.reader-stage.vertical { overflow-y: auto; }
.reader-stage.vertical .page-track { display: block; height: auto; transform: none !important; }
.reader-stage.vertical .comic-page { min-height: 100vh; }
.reader-stage.vertical .page-nav { display: none; }

@media (max-width: 880px) {
  .site-header { align-items: flex-start; gap: 12px; }
  .top-nav { display: none; }
  .hero { grid-template-columns: 1fr; }
  .hero-card { min-height: 300px; }
  .cover-grid { grid-template-columns: 1fr; }
  .cover-card { min-height: 360px; }
  .section-heading { align-items: flex-start; flex-direction: column; }
  .security-grid { grid-template-columns: 1fr; }
  .profile-card { align-items: flex-start; flex-direction: column; }
  .profile-card .tap-hint { margin-left: 0; }
  .reader-toolbar { grid-template-columns: auto 1fr; flex-wrap: wrap; }
  .page-nav { width: 44px; height: 44px; font-size: 34px; }
  .prev { left: 8px; }
  .next { right: 8px; }
}

/* Language gate */
.language-gate {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  padding: 20px;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  background: rgba(245,245,247,.94);
  backdrop-filter: blur(30px);
}
.language-gate[hidden] { display: none; }
.language-gate-panel {
  width: min(920px, 100%);
  padding: clamp(28px, 5vw, 58px);
  border: 1px solid rgba(255,255,255,.8);
  border-radius: 40px;
  background: rgba(255,255,255,.78);
  box-shadow: 0 30px 100px rgba(0,0,0,.14);
  text-align: center;
}
.language-gate-brand {
  display: grid;
  place-items: center;
  width: 68px;
  height: 68px;
  margin: 0 auto 18px;
  border-radius: 50%;
  background: #111113;
  color: #fff;
  font-weight: 800;
}
.language-gate h1 { margin: 0; font-size: clamp(36px, 6vw, 66px); letter-spacing: -.055em; }
.language-gate-copy { color: var(--muted); margin: 14px auto 28px; }
.flag-language-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 12px; }
.flag-language-card {
  display: grid;
  place-items: center;
  gap: 8px;
  min-height: 130px;
  padding: 18px 12px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255,255,255,.74);
  cursor: pointer;
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}
.flag-language-card:hover { transform: translateY(-3px); box-shadow: 0 14px 34px rgba(0,0,0,.08); }
.flag-language-card.selected { border-color: #111113; box-shadow: 0 0 0 2px #111113 inset; }
.flag-language-card .flag { font-size: 42px; line-height: 1; }
.flag-language-card strong { font-size: 15px; }
.flag-language-card small { color: var(--muted); }
.continue-button { margin-top: 24px; min-width: 180px; }
.continue-button:disabled { opacity: .35; cursor: not-allowed; transform: none; }
.header-actions { display: flex; align-items: center; gap: 18px; }
.language-switcher {
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 9px 13px;
  background: rgba(255,255,255,.75);
  font-weight: 700;
  cursor: pointer;
}
.fallback-note { margin: 0; color: var(--muted); font-size: 13px; }
.language-fallback-badge { display: inline-flex; margin-top: 12px; padding: 6px 9px; border-radius: 999px; background: rgba(255,255,255,.16); font-size: 11px; }

@media (max-width: 760px) {
  .language-gate {
    place-items: start center;
    padding: 12px;
  }
  .language-gate-panel {
    width: 100%;
    margin: 0 auto 12px;
    padding: 28px 18px 34px;
    border-radius: 30px;
  }
  .language-gate h1 { font-size: clamp(34px, 11vw, 50px); }
  .language-gate-copy { line-height: 1.7; }
  .flag-language-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .flag-language-card { min-height: 130px; }
  .continue-button {
    position: sticky;
    bottom: 0;
    z-index: 2;
    width: 100%;
    margin-top: 18px;
    box-shadow: 0 12px 30px rgba(0,0,0,.2);
  }
  .top-nav { display: none; }
  .language-switcher span:last-child { display: none; }
}


.categories-section{padding:40px clamp(20px,6vw,88px) 72px}.category-chips{display:flex;flex-wrap:wrap;gap:12px}.category-chips button{appearance:none;border:1px solid rgba(0,0,0,.09);background:rgba(255,255,255,.76);border-radius:999px;padding:12px 20px;font:inherit;font-weight:650;cursor:pointer;box-shadow:0 8px 24px rgba(0,0,0,.05);transition:transform .2s ease,background .2s ease}.category-chips button:hover{transform:translateY(-2px);background:#fff}


/* Author library / Kindle-inspired collection flow */
.author-library {
  position: fixed;
  inset: 0;
  z-index: 90;
  overflow-y: auto;
  background: #f5f5f7;
  color: var(--ink);
  -webkit-overflow-scrolling: touch;
}
.author-library[hidden] { display: none; }
.library-appbar {
  position: sticky;
  top: 0;
  z-index: 4;
  min-height: 92px;
  display: grid;
  grid-template-columns: 48px 1fr 48px;
  align-items: center;
  gap: 12px;
  padding: 14px clamp(14px,4vw,34px);
  border-bottom: 1px solid var(--line);
  background: rgba(245,245,247,.9);
  backdrop-filter: blur(24px);
  text-align: center;
}
.library-appbar h2,.library-appbar p { margin:0; }
.library-appbar h2 { font-size:22px; }
.library-back,.library-close {
  width:44px;height:44px;border:0;border-radius:50%;cursor:pointer;
  background:rgba(0,0,0,.055);font-size:32px;color:var(--ink);
}
.library-close { font-size:26px; }
.library-tabs {
  position: sticky;
  top: 92px;
  z-index: 3;
  display:flex;
  gap:8px;
  padding:12px clamp(14px,4vw,34px);
  background:rgba(245,245,247,.92);
  backdrop-filter:blur(22px);
  border-bottom:1px solid var(--line);
}
.library-tabs button {
  flex:1;
  border:0;
  border-radius:999px;
  padding:11px 14px;
  color:var(--muted);
  background:transparent;
  font-weight:700;
  cursor:pointer;
}
.library-tabs button.active { background:#111113;color:white; }
.library-content { padding:24px clamp(14px,4vw,44px) 70px; max-width:1200px; margin:0 auto; }
.library-summary { margin:0 0 22px;color:var(--muted);font-size:17px; }
.series-grid,.volume-grid {
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:24px 18px;
}
.series-tile,.volume-tile {
  border:0;background:transparent;text-align:left;padding:0;cursor:pointer;color:inherit;
}
.book-cover {
  position:relative;
  aspect-ratio: 0.68;
  border-radius:12px;
  overflow:hidden;
  background:var(--book-bg);
  box-shadow:0 16px 36px rgba(0,0,0,.16);
  transition:transform .2s ease,box-shadow .2s ease;
}
.series-tile:hover .book-cover,.volume-tile:hover .book-cover { transform:translateY(-4px);box-shadow:0 24px 46px rgba(0,0,0,.22); }
.book-cover::after { content:"";position:absolute;inset:0;background:linear-gradient(145deg,rgba(255,255,255,.28),transparent 28%,rgba(0,0,0,.22)); }
.book-cover-copy { position:absolute;inset:0;z-index:1;display:flex;flex-direction:column;justify-content:flex-end;padding:16px;color:white; }
.book-cover-copy small { opacity:.75;font-weight:700;letter-spacing:.08em;text-transform:uppercase; }
.book-cover-copy strong { font-size:clamp(18px,3vw,30px);line-height:1;margin-top:6px; }
.book-count { position:absolute;right:9px;bottom:9px;z-index:2;display:grid;place-items:center;min-width:34px;height:34px;padding:0 8px;border-radius:999px;background:rgba(0,0,0,.76);color:white;font-weight:700;font-size:13px; }
.tile-title { margin:12px 2px 0;font-size:16px;font-weight:700;line-height:1.35; }
.tile-meta { margin:4px 2px 0;color:var(--muted);font-size:13px; }
@media (max-width:700px){
  .series-grid,.volume-grid{grid-template-columns:repeat(3,minmax(0,1fr));gap:24px 12px;}
  .library-content{padding-left:16px;padding-right:16px;}
  .book-cover{border-radius:5px;}
  .book-cover-copy{padding:9px;}
  .book-cover-copy strong{font-size:14px;}
  .book-cover-copy small{font-size:9px;}
  .tile-title{font-size:13px;}
  .tile-meta{font-size:11px;}
  .book-count{min-width:28px;height:28px;font-size:11px;right:6px;bottom:6px;}
}

/* Linktree / lit.link-inspired author hub */
.author-link-hub {
  width:min(1120px,calc(100% - 32px));
  margin:24px auto 18px;
  padding:22px;
  border:1px solid rgba(0,0,0,.07);
  border-radius:28px;
  background:rgba(255,255,255,.78);
  box-shadow:0 18px 54px rgba(0,0,0,.08);
  backdrop-filter:blur(22px);
}
.author-link-profile {
  display:flex;
  align-items:center;
  gap:16px;
  margin-bottom:18px;
}
.author-link-avatar {
  flex:0 0 auto;
  display:grid;
  place-items:center;
  width:76px;
  height:76px;
  border-radius:24px;
  background:#111113;
  color:white;
  font-weight:800;
  font-size:20px;
  box-shadow:0 14px 30px rgba(0,0,0,.18);
}
.author-link-copy h3 { margin:0 0 6px;font-size:28px;letter-spacing:-.04em; }
.author-link-copy p:last-child { margin:0;color:var(--muted);line-height:1.6; }
.author-link-list {
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:10px;
}
.author-social-link {
  position:relative;
  display:flex;
  align-items:center;
  gap:12px;
  min-height:58px;
  padding:12px 44px 12px 14px;
  border:1px solid rgba(0,0,0,.08);
  border-radius:18px;
  background:#fff;
  color:var(--ink);
  text-decoration:none;
  font-weight:750;
  box-shadow:0 8px 22px rgba(0,0,0,.05);
  transition:transform .2s ease,box-shadow .2s ease,border-color .2s ease;
}
.author-social-link:hover { transform:translateY(-2px);box-shadow:0 14px 28px rgba(0,0,0,.09);border-color:rgba(0,0,0,.16); }
.author-social-icon {
  display:grid;
  place-items:center;
  width:34px;
  height:34px;
  border-radius:11px;
  background:#111113;
  color:#fff;
  font-size:14px;
  font-weight:800;
}
.author-social-link small { display:block;color:var(--muted);font-weight:600;margin-top:2px; }
.author-social-arrow { position:absolute;right:16px;font-size:22px;color:var(--muted); }
@media (max-width:760px){
  .author-link-hub{width:calc(100% - 24px);margin:14px auto 12px;padding:16px;border-radius:24px;}
  .author-link-profile{align-items:flex-start;}
  .author-link-avatar{width:64px;height:64px;border-radius:20px;}
  .author-link-copy h3{font-size:24px;}
  .author-link-list{grid-template-columns:1fr;}
  .author-social-link{min-height:54px;}
}
.admin-entry{color:#6e6e73;text-decoration:none;font-size:12px;font-weight:800;padding:10px 2px}.admin-entry:hover{color:#111}@media(max-width:760px){.admin-entry{display:none}}


/* Reader reactions / comments */
.engagement-toggle {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 42px;
  padding: 9px 14px;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 999px;
  background: rgba(255,255,255,.09);
  color: white;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}
.engagement-toggle:hover { background: rgba(255,255,255,.15); }
.engagement-panel {
  position: fixed;
  z-index: 120;
  top: 76px;
  right: 18px;
  bottom: 74px;
  width: min(430px, calc(100vw - 36px));
  overflow-y: auto;
  padding: 22px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 28px;
  background: rgba(24,24,27,.96);
  color: white;
  box-shadow: 0 28px 90px rgba(0,0,0,.58);
  backdrop-filter: blur(24px);
}
.engagement-head,
.comment-list-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}
.engagement-head h3 { margin: 0; font-size: 24px; }
.engagement-close {
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 50%;
  background: rgba(255,255,255,.1);
  color: white;
  font-size: 25px;
  cursor: pointer;
}
.like-button {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 20px 0;
  padding: 16px 18px;
  border: 1px solid rgba(255,255,255,.13);
  border-radius: 18px;
  background: rgba(255,255,255,.07);
  color: white;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}
.like-button strong { margin-left: auto; }
.like-button[aria-pressed="true"] { background: white; color: #111; }
.like-icon { font-size: 23px; line-height: 1; }
.comment-form { display: grid; gap: 14px; }
.comment-form label { display: grid; gap: 7px; font-size: 13px; font-weight: 700; }
.comment-form input,
.comment-form textarea {
  width: 100%;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 14px;
  background: rgba(255,255,255,.08);
  color: white;
  padding: 13px 14px;
  font: inherit;
  resize: vertical;
}
.comment-form input:focus,
.comment-form textarea:focus { outline: 2px solid rgba(255,255,255,.72); outline-offset: 2px; }
.comment-rule { margin: 0; color: rgba(255,255,255,.58); font-size: 12px; line-height: 1.65; }
.comment-message { min-height: 20px; margin: 0; color: #9de2b0; font-size: 13px; }
.comment-message.error { color: #ff9f9f; }
.comment-submit {
  border: 0;
  border-radius: 999px;
  padding: 13px 18px;
  background: white;
  color: #111;
  font-weight: 800;
  cursor: pointer;
}
.comment-list-head { margin-top: 26px; padding-top: 22px; border-top: 1px solid rgba(255,255,255,.1); }
.comment-list-head h4 { margin: 0; font-size: 18px; }
.comment-list-head span { color: rgba(255,255,255,.58); font-size: 13px; }
.comment-list { display: grid; gap: 10px; margin-top: 14px; }
.comment-card { padding: 14px; border-radius: 16px; background: rgba(255,255,255,.07); }
.comment-card-head { display:flex; justify-content:space-between; gap:12px; align-items:center; }
.comment-card strong { font-size: 14px; }
.comment-card time { color: rgba(255,255,255,.46); font-size: 11px; }
.comment-card p { margin: 9px 0 0; color: rgba(255,255,255,.82); line-height: 1.65; white-space: pre-wrap; overflow-wrap: anywhere; }
.comment-empty { padding: 20px 8px; text-align: center; color: rgba(255,255,255,.48); font-size: 13px; }

@media (max-width: 700px) {
  .reader-toolbar { align-items: flex-start; }
  .reader-controls { flex-wrap: wrap; justify-content: flex-end; }
  .engagement-toggle #toolbarCommentLabel { display: none; }
  .engagement-panel {
    top: auto;
    right: 0;
    bottom: 0;
    left: 0;
    width: 100%;
    max-height: 82vh;
    border-radius: 28px 28px 0 0;
    padding-bottom: calc(22px + env(safe-area-inset-bottom));
  }
}

/* Hide fixed sample creator content until API data is loaded */
.hero-card,
.author-panel,
.categories-section {
  display: none !important;
}

/* catalog API patch: restore real data sections */
.hero-card,
.author-panel,
.categories-section {
  display: block !important;
}
.author-link-list:empty {
  display: none !important;
}
.profile-card.no-description,
.author-link-profile.no-description {
  align-items: center;
}
.profile-card.no-description h2,
.author-link-profile.no-description h3 {
  font-size: clamp(1.7rem, 4vw, 2.5rem);
  margin-bottom: 0;
}
/* project_AKI catalog UI fix v2 */
[hidden] { display: none !important; }

/* Real covers use the original card design */
.cover-card {
  background: transparent;
  text-align: left;
  border: 1px solid rgba(255,255,255,.5);
}
.cover-card::before {
  background-image: var(--cover-bg);
  background-size: cover;
  background-position: center;
  background-color: #b9b9bb;
}
.cover-card > * { position: relative; z-index: 1; }

.hero-card {
  background-color: #d6d6d8;
  background-size: cover;
  background-position: center;
  overflow: hidden;
}
.hero-card::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,.08), rgba(0,0,0,.28));
}
.hero-card .glass-card { position: relative; z-index: 1; }

/* Kindle-style series / chapter covers */
.book-cover {
  background-image: var(--book-bg);
  background-size: cover;
  background-position: center;
  background-color: #d7d7d9;
}

/* Refined author links */
.author-link-list { gap: 12px; }
.author-social-link {
  min-width: 0;
  overflow: hidden;
  text-decoration: none !important;
}
.author-social-link > span:nth-child(2) { min-width: 0; }
.author-social-link strong {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--ink);
}
.author-social-link small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.author-social-arrow { line-height: 1; }

/* Reader: never crop or upscale manga pages beyond the viewport */
.reader-stage { min-height: 0; }
.page-track { min-width: 0; }
.comic-page { box-sizing: border-box; }
.page-art {
  width: min(92vw, 760px);
  height: min(78vh, 1080px);
  padding: 0;
  background: #fff;
}
.page-art::before { display: none; }
.page-art img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  background: #fff;
}
.reader-stage.vertical .comic-page {
  min-height: auto;
  height: auto;
  padding: 0;
}
.reader-stage.vertical .page-art {
  width: min(100%, 900px);
  height: auto;
  min-height: 0;
  margin: 0 auto;
  border-radius: 0;
}
.reader-stage.vertical .page-art img {
  width: 100%;
  height: auto;
}

@media (max-width: 760px) {
  .reader-toolbar { padding: 12px 14px; gap: 10px; }
  .reader-title-block { min-width: 0; flex: 1; }
  .reader-title-block h2 { font-size: 18px; line-height: 1.25; }
  .reader-title-block .eyebrow { font-size: 10px; }
  .reader-controls { width: 100%; justify-content: flex-start; }
  .page-art {
    width: 100vw;
    height: calc(100dvh - 238px);
    max-height: none;
    border-radius: 0;
  }
  .comic-page { padding: 0; }
  .page-nav { background: rgba(0,0,0,.52); }
  .author-link-profile { gap: 14px; }
  .author-link-copy { min-width: 0; }
  .author-link-copy h3 { font-size: 26px; }
  .author-link-copy p:last-child { font-size: 15px; overflow-wrap: anywhere; }
  .author-social-link { padding: 12px 42px 12px 12px; }
}
/* project_AKI catalog UI fix v2 */
[hidden] { display: none !important; }

/* Real covers use the original card design */
.cover-card {
  background: transparent;
  text-align: left;
  border: 1px solid rgba(255,255,255,.5);
}
.cover-card::before {
  background-image: var(--cover-bg);
  background-size: cover;
  background-position: center;
  background-color: #b9b9bb;
}
.cover-card > * { position: relative; z-index: 1; }

.hero-card {
  background-color: #d6d6d8;
  background-size: cover;
  background-position: center;
  overflow: hidden;
}
.hero-card::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,.08), rgba(0,0,0,.28));
}
.hero-card .glass-card { position: relative; z-index: 1; }

/* Kindle-style series / chapter covers */
.book-cover {
  background-image: var(--book-bg);
  background-size: cover;
  background-position: center;
  background-color: #d7d7d9;
}

/* Refined author links */
.author-link-list { gap: 12px; }
.author-social-link {
  min-width: 0;
  overflow: hidden;
  text-decoration: none !important;
}
.author-social-link > span:nth-child(2) { min-width: 0; }
.author-social-link strong {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--ink);
}
.author-social-link small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.author-social-arrow { line-height: 1; }

/* Reader: never crop or upscale manga pages beyond the viewport */
.reader-stage { min-height: 0; }
.page-track { min-width: 0; }
.comic-page { box-sizing: border-box; }
.page-art {
  width: min(92vw, 760px);
  height: min(78vh, 1080px);
  padding: 0;
  background: #fff;
}
.page-art::before { display: none; }
.page-art img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  background: #fff;
}
.reader-stage.vertical .comic-page {
  min-height: auto;
  height: auto;
  padding: 0;
}
.reader-stage.vertical .page-art {
  width: min(100%, 900px);
  height: auto;
  min-height: 0;
  margin: 0 auto;
  border-radius: 0;
}
.reader-stage.vertical .page-art img {
  width: 100%;
  height: auto;
}

@media (max-width: 760px) {
  .reader-toolbar { padding: 12px 14px; gap: 10px; }
  .reader-title-block { min-width: 0; flex: 1; }
  .reader-title-block h2 { font-size: 18px; line-height: 1.25; }
  .reader-title-block .eyebrow { font-size: 10px; }
  .reader-controls { width: 100%; justify-content: flex-start; }
  .page-art {
    width: 100vw;
    height: calc(100dvh - 238px);
    max-height: none;
    border-radius: 0;
  }
  .comic-page { padding: 0; }
  .page-nav { background: rgba(0,0,0,.52); }
  .author-link-profile { gap: 14px; }
  .author-link-copy { min-width: 0; }
  .author-link-copy h3 { font-size: 26px; }
  .author-link-copy p:last-child { font-size: 15px; overflow-wrap: anywhere; }
  .author-social-link { padding: 12px 42px 12px 12px; }
}
/* project_AKI reader viewport fit v3 */
.reader {
  position: fixed;
  inset: 0;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  background: #000;
  overflow: hidden;
}

.reader-toolbar,
.reader-footer {
  position: relative;
  z-index: 20;
  background: #000;
}

.reader-stage {
  position: relative;
  min-width: 0;
  min-height: 0;
  width: 100%;
  height: 100%;
  background: #000;
  overflow: hidden;
}

.reader-stage.horizontal .page-track {
  display: flex;
  width: 100%;
  height: 100%;
  min-height: 0;
  transition: transform .28s ease;
}

.reader-stage.horizontal .comic-page {
  flex: 0 0 100%;
  width: 100%;
  height: 100%;
  min-height: 0;
  padding: 14px 72px;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #000;
}

.reader-stage.horizontal .page-art {
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  min-width: 0;
  min-height: 0;
  margin: 0;
  padding: 0;
  border-radius: 0;
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.reader-stage.horizontal .page-art img {
  display: block;
  width: auto !important;
  height: auto !important;
  max-width: 100% !important;
  max-height: 100% !important;
  object-fit: contain !important;
  object-position: center !important;
  background: #000;
}

.reader-stage.vertical {
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  background: #000;
}

.reader-stage.vertical .page-track {
  display: block;
  width: 100%;
  height: auto;
  transform: none !important;
  background: #000;
}

.reader-stage.vertical .comic-page {
  width: 100%;
  min-height: 0;
  height: auto;
  margin: 0 0 1cm;
  padding: 0;
  box-sizing: border-box;
  background: #000;
  display: flex;
  justify-content: center;
}

.reader-stage.vertical .comic-page:last-child {
  margin-bottom: 0;
}

.reader-stage.vertical .page-art {
  width: min(100%, 1000px);
  height: auto;
  min-height: 0;
  margin: 0 auto;
  padding: 0;
  border-radius: 0;
  background: #000;
  overflow: visible;
}

.reader-stage.vertical .page-art img {
  display: block;
  width: 100% !important;
  height: auto !important;
  max-width: 100% !important;
  max-height: none !important;
  object-fit: contain !important;
  background: #000;
}

@media (max-width: 760px) {
  .reader {
    min-height: 100dvh;
  }

  .reader-toolbar {
    max-height: 176px;
    overflow-y: auto;
  }

  .reader-stage.horizontal .comic-page {
    padding: 8px 0;
  }

  .reader-stage.horizontal .page-art {
    width: 100%;
    height: 100%;
  }

  .reader-stage.vertical .comic-page {
    margin-bottom: 1cm;
  }

  .page-nav {
    z-index: 15;
  }
}
/* project_AKI public UI v4 */
.hero-copy h2 { white-space: pre-line; }
.hero-actions .button.ghost { display: none !important; }
.hero-actions .button.primary {
  min-width: 220px;
  justify-content: center;
}

.book-cover {
  background: #d8d8da !important;
}
.book-cover-image {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}
.book-cover::after { z-index: 1; }
.book-cover-copy,
.book-count { z-index: 2; }

.library-tabs {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.library-tabs button { min-width: 0; }

.reader-footer span:last-child { display: none !important; }

@media (max-width: 700px) {
  .hero-copy h2 { line-height: .98; }
  .hero-actions { margin-top: 24px; }
  .hero-actions .button.primary { width: 100%; min-width: 0; }
  .library-tabs {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
    padding: 8px 10px;
  }
  .library-tabs button {
    padding: 11px 5px;
    font-size: 12px;
    white-space: nowrap;
  }
}
/* project_AKI public UI v5 */
.hero-copy h2 { white-space: pre-line; }
.hero-actions { display: none !important; }

.hero-card {
  position: relative;
  cursor: pointer;
  background-size: cover !important;
  background-position: center !important;
  opacity: 0;
  transition: opacity 1.2s ease;
  overflow: hidden;
}
.hero-card.hero-cover-visible { opacity: 1; }
.hero-card .glass-card { display: none !important; }

.cover-grid {
  align-items: stretch;
}
.cover-card.series-home-card {
  position: relative;
  overflow: hidden;
  min-height: 360px;
  padding: 0;
  text-align: left;
  background: #d8d8da;
  border: 0;
}
.cover-card-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}
.cover-card-shade {
  position: absolute;
  inset: 35% 0 0;
  background: linear-gradient(to bottom, transparent, rgba(0,0,0,.78));
}
.cover-card-copy {
  position: absolute;
  z-index: 2;
  left: 24px;
  right: 24px;
  bottom: 24px;
  color: #fff;
}
.cover-card-copy h3 { margin: 6px 0 10px; }
.cover-card-copy p { margin: 0; }

.category-chips button.active {
  background: #111;
  color: #fff;
}

.book-cover {
  background: #d8d8da !important;
}
.book-cover-image {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}
.book-cover::after { z-index: 1; }
.book-cover-copy,
.book-count { z-index: 2; }

.library-tabs { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.library-tabs button { min-width: 0; }
.reader-footer span:last-child { display: none !important; }

@media (max-width: 700px) {
  .hero-copy h2 { line-height: .98; }
  .cover-card.series-home-card { min-height: 330px; }
  .library-tabs {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
    padding: 8px 10px;
  }
  .library-tabs button {
    padding: 11px 5px;
    font-size: 12px;
    white-space: nowrap;
  }
}
/* project_AKI public UI v5 */
.hero-copy h2 { white-space: pre-line; }
.hero-actions { display: none !important; }

.hero-card {
  position: relative;
  cursor: pointer;
  background-size: cover !important;
  background-position: center !important;
  opacity: 0;
  transition: opacity 1.2s ease;
  overflow: hidden;
}
.hero-card.hero-cover-visible { opacity: 1; }
.hero-card .glass-card { display: none !important; }

.cover-grid {
  align-items: stretch;
}
.cover-card.series-home-card {
  position: relative;
  overflow: hidden;
  min-height: 360px;
  padding: 0;
  text-align: left;
  background: #d8d8da;
  border: 0;
}
.cover-card-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}
.cover-card-shade {
  position: absolute;
  inset: 35% 0 0;
  background: linear-gradient(to bottom, transparent, rgba(0,0,0,.78));
}
.cover-card-copy {
  position: absolute;
  z-index: 2;
  left: 24px;
  right: 24px;
  bottom: 24px;
  color: #fff;
}
.cover-card-copy h3 { margin: 6px 0 10px; }
.cover-card-copy p { margin: 0; }

.category-chips button.active {
  background: #111;
  color: #fff;
}

.book-cover {
  background: #d8d8da !important;
}
.book-cover-image {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}
.book-cover::after { z-index: 1; }
.book-cover-copy,
.book-count { z-index: 2; }

.library-tabs { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.library-tabs button { min-width: 0; }
.reader-footer span:last-child { display: none !important; }

@media (max-width: 700px) {
  .hero-copy h2 { line-height: .98; }
  .cover-card.series-home-card { min-height: 330px; }
  .library-tabs {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
    padding: 8px 10px;
  }
  .library-tabs button {
    padding: 11px 5px;
    font-size: 12px;
    white-space: nowrap;
  }
}
/* project_AKI category browse v6 */
.categories-section {
  padding-bottom: clamp(56px, 8vw, 120px);
}

.category-result {
  margin-top: 38px;
}

.category-result-title {
  margin: 0 0 24px;
  font-size: clamp(30px, 4vw, 54px);
  line-height: 1;
  letter-spacing: -0.04em;
}

.category-cover-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 320px));
  gap: 28px;
  align-items: stretch;
}

.category-cover-grid .cover-card.series-home-card {
  min-height: 430px;
  width: 100%;
}

.category-cover-grid:empty::after {
  content: '';
  display: block;
  min-height: 1px;
}

@media (max-width: 700px) {
  .category-result {
    margin-top: 28px;
  }

  .category-result-title {
    margin-bottom: 18px;
    font-size: 34px;
  }

  .category-cover-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .category-cover-grid .cover-card.series-home-card {
    min-height: 290px;
  }

  .category-cover-grid .cover-card-copy {
    left: 14px;
    right: 14px;
    bottom: 14px;
  }
}
