:root {
  color: #4b2b16;
  background: #fff4df;
  font-family: "Comic Sans MS", "Microsoft YaHei", "PingFang SC", sans-serif;
  font-synthesis: none;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  background:
    radial-gradient(circle at 15% 8%, rgba(255, 221, 145, 0.72), transparent 26rem),
    linear-gradient(180deg, #fff4df, #ffe8b8 50%, #f7dda4);
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  max-width: 100%;
}

.app-root {
  min-height: 100vh;
  overflow-x: hidden;
}

.home-root {
  color: #4b2b16;
}

.brand-hero {
  width: min(100%, 1040px);
  min-height: 86vh;
  margin: 0 auto;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 22px;
  padding: max(24px, env(safe-area-inset-top)) 18px 36px;
  text-align: center;
}

.brand-lockup {
  display: grid;
  justify-items: center;
  gap: 14px;
}

.site-logo-image {
  width: min(54vw, 270px);
  height: auto;
  border-radius: 24px;
  box-shadow: 0 18px 42px rgba(120, 72, 20, 0.17);
}

.brand-lockup h1 {
  margin: 0;
  color: #684017;
  font-size: clamp(3rem, 15vw, 6rem);
  line-height: 0.95;
}

.brand-lockup p {
  margin: 8px 0 0;
  color: #a96112;
  font-size: clamp(1.5rem, 7vw, 2.35rem);
  font-weight: 900;
}

.brand-lockup span,
.section-heading span,
.work-card-copy p,
.detail-copy p,
.guide-card p,
.character-list p,
.chapter-card span,
.character-card span,
.reader-summary span,
.comic-page p {
  line-height: 1.7;
}

.brand-lockup span {
  display: block;
  max-width: 28rem;
  margin: 10px auto 0;
  color: #6a4321;
  font-size: 1.02rem;
  font-weight: 800;
}

.primary-action,
.soft-action,
.card-button,
.chapter-card a,
.bottom-actions a,
.plain-link,
.reader-chapters a {
  min-height: 42px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 16px;
  font-weight: 900;
}

.primary-action,
.card-button,
.chapter-card a,
.bottom-actions a {
  color: #1d1510;
  background: linear-gradient(180deg, #ffe1a0, #d99142);
  box-shadow: 0 10px 20px rgba(158, 92, 19, 0.13);
}

.soft-action,
.plain-link,
.reader-chapters a {
  color: #5a3217;
  background: rgba(255, 251, 241, 0.9);
  border: 1px solid rgba(139, 84, 32, 0.18);
}

.shelf-section,
.page-shell,
.reader-shell {
  width: min(100%, 1060px);
  margin: 0 auto;
  padding: 26px 14px max(34px, env(safe-area-inset-bottom));
}

.section-heading {
  display: grid;
  gap: 5px;
  margin-bottom: 16px;
}

.section-heading p,
.eyebrow,
.reader-summary p,
.chapter-card p,
.character-card p {
  margin: 0;
  color: #a76518;
  font-weight: 900;
  letter-spacing: 0;
}

.section-heading h2 {
  margin: 0;
  color: #5b3116;
  font-size: clamp(1.6rem, 7vw, 2.6rem);
}

.section-heading span {
  color: #765029;
  font-weight: 800;
}

.shelf-grid {
  display: grid;
  gap: 16px;
}

.work-card {
  display: grid;
  gap: 13px;
  padding: 14px;
  border-radius: 24px;
  border: 1px solid rgba(139, 84, 32, 0.18);
  background: rgba(255, 250, 236, 0.88);
  box-shadow: 0 16px 34px rgba(119, 68, 21, 0.12);
}

.cover-wrap {
  display: block;
  overflow: hidden;
  border-radius: 18px;
  background: #fff7df;
}

.cover-wrap img {
  width: 100%;
  height: 100%;
}

.cover-portrait {
  aspect-ratio: 4 / 5;
}

.cover-portrait img {
  object-fit: cover;
}

.cover-wide {
  aspect-ratio: 16 / 9;
  background:
    linear-gradient(180deg, rgba(255, 241, 208, 0.06), rgba(0, 0, 0, 0.12)),
    #0d1016;
}

.cover-wide img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.work-card-copy {
  display: grid;
  gap: 7px;
}

.work-card-copy h3 {
  margin: 0;
  color: #5b3116;
  font-size: clamp(1.35rem, 6vw, 1.8rem);
  line-height: 1.16;
}

.work-card-copy strong {
  color: #744217;
}

.work-card-copy p {
  margin: 0;
  color: #5b3a1f;
}

.charged-card {
  color: #f2e3cf;
  background:
    linear-gradient(135deg, rgba(27, 31, 42, 0.96), rgba(20, 18, 16, 0.94)),
    #171a22;
  border-color: rgba(228, 181, 116, 0.26);
}

.charged-card .work-card-copy h3,
.charged-card .work-card-copy p,
.charged-card .work-card-copy strong {
  color: #f2e3cf;
}

.charged-card .eyebrow {
  color: #f0bd73;
}

.page-topbar,
.reader-top,
.action-row,
.tag-row,
.bottom-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.page-topbar {
  margin-bottom: 16px;
}

.round-button {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: inline-grid;
  place-items: center;
  background: rgba(255, 251, 241, 0.95);
  color: #6a3512;
  border: 1px solid rgba(139, 84, 32, 0.17);
  font-size: 2rem;
  line-height: 1;
}

.sweet-theme {
  color: #4b2b16;
  background:
    radial-gradient(circle at 12% 8%, rgba(255, 221, 145, 0.62), transparent 22rem),
    radial-gradient(circle at 88% 14%, rgba(121, 182, 74, 0.13), transparent 20rem),
    linear-gradient(180deg, #fff4df, #ffe8b8 54%, #f7dda4);
}

.charged-theme {
  color: #f4eadc;
  background:
    radial-gradient(circle at 16% 8%, rgba(70, 118, 160, 0.26), transparent 22rem),
    radial-gradient(circle at 88% 16%, rgba(218, 139, 55, 0.18), transparent 20rem),
    linear-gradient(180deg, #10131a, #16110f 55%, #0e1014);
}

.charged-theme .plain-link,
.charged-theme .reader-chapters a {
  color: #f6e4c8;
  background: rgba(255, 245, 223, 0.1);
  border-color: rgba(255, 220, 160, 0.18);
}

.charged-theme .section-heading h2,
.charged-theme .detail-copy h1,
.charged-theme .reader-top h1,
.charged-theme .reader-summary h2,
.charged-theme .chapter-card h3,
.charged-theme .character-card h3 {
  color: #fff3dc;
}

.charged-theme .section-heading span,
.charged-theme .detail-copy p,
.charged-theme .guide-card p,
.charged-theme .chapter-card span,
.charged-theme .character-card span,
.charged-theme .reader-summary span,
.charged-theme .comic-page p {
  color: #d8c8b5;
}

.charged-theme .eyebrow,
.charged-theme .section-heading p,
.charged-theme .reader-summary p,
.charged-theme .chapter-card p,
.charged-theme .character-card p {
  color: #e8ae63;
}

.detail-hero,
.intro-section,
.chapter-section,
.reader-summary,
.comic-page,
.bottom-actions {
  border: 1px solid rgba(139, 84, 32, 0.18);
  background: rgba(255, 250, 236, 0.88);
  box-shadow: 0 16px 34px rgba(119, 68, 21, 0.12);
}

.charged-theme .detail-hero,
.charged-theme .intro-section,
.charged-theme .chapter-section,
.charged-theme .reader-summary,
.charged-theme .comic-page,
.charged-theme .bottom-actions {
  border-color: rgba(244, 213, 172, 0.16);
  background: rgba(20, 24, 32, 0.78);
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.28);
}

.detail-hero {
  display: grid;
  gap: 18px;
  padding: 18px;
  border-radius: 26px;
}

.detail-copy {
  display: grid;
  gap: 12px;
}

.detail-copy h1,
.detail-copy h2,
.detail-copy p {
  margin: 0;
}

.detail-copy h1 {
  color: #6a3512;
  font-size: clamp(2rem, 9vw, 4.4rem);
  line-height: 1.05;
}

.detail-copy h2 {
  color: #a96112;
  font-size: clamp(1.05rem, 4.5vw, 1.55rem);
}

.detail-copy p {
  color: #5b3a1f;
}

.tag-row span {
  padding: 6px 10px;
  border-radius: 999px;
  color: #744217;
  background: rgba(255, 208, 91, 0.38);
  border: 1px solid rgba(139, 84, 32, 0.18);
  font-weight: 900;
}

.charged-theme .tag-row span {
  color: #ffe0aa;
  background: rgba(255, 187, 79, 0.12);
  border-color: rgba(255, 214, 144, 0.18);
}

.detail-cover {
  overflow: hidden;
  border-radius: 20px;
  box-shadow: 0 18px 42px rgba(120, 72, 20, 0.18);
}

.detail-cover img {
  width: 100%;
  height: 100%;
}

.charged-theme .detail-cover {
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.38);
}

.intro-section,
.chapter-section {
  display: grid;
  gap: 14px;
  margin-top: 16px;
  padding: 16px;
  border-radius: 24px;
}

.guide-card {
  display: grid;
  gap: 10px;
}

.guide-card h2 {
  margin: 0;
  color: #5b3116;
  font-size: clamp(1.35rem, 6vw, 1.9rem);
}

.guide-card p {
  margin: 0;
  color: #5b3a1f;
}

.character-list,
.character-grid,
.chapter-grid {
  display: grid;
  gap: 10px;
}

.character-list article,
.character-card,
.chapter-card {
  display: grid;
  gap: 8px;
  padding: 13px;
  border-radius: 16px;
  border: 1px solid rgba(139, 84, 32, 0.18);
  background: rgba(255, 251, 241, 0.66);
}

.charged-theme .character-card,
.charged-theme .chapter-card {
  border-color: rgba(255, 226, 180, 0.16);
  background: rgba(255, 245, 223, 0.08);
}

.character-list h3,
.character-list p,
.character-card h3,
.character-card span,
.chapter-card h3,
.chapter-card span {
  margin: 0;
}

.character-list h3,
.chapter-card h3 {
  color: #6a3512;
}

.character-intro-image {
  overflow: hidden;
  border-radius: 18px;
  border: 1px solid rgba(255, 226, 180, 0.18);
  background: #0d1016;
}

.character-intro-image img {
  width: 100%;
  height: auto;
  object-fit: contain;
}

.reader-shell {
  width: min(100%, 840px);
}

.reader-top {
  justify-content: space-between;
  margin-bottom: 14px;
}

.reader-top div {
  min-width: min(100%, 260px);
  text-align: center;
}

.reader-top p,
.reader-top h1 {
  margin: 0;
}

.reader-top p {
  color: #a76518;
  font-weight: 900;
}

.reader-top h1 {
  color: #5b3116;
  font-size: clamp(1.2rem, 5vw, 1.8rem);
}

.reader-chapters {
  display: grid;
  gap: 9px;
  margin-bottom: 14px;
}

.reader-chapters a {
  flex-direction: column;
  align-items: flex-start;
  min-height: 58px;
  border-radius: 16px;
  padding: 10px 13px;
}

.reader-chapters a.active {
  color: #1d1510;
  background: linear-gradient(180deg, #ffe1a0, #d99142);
  border-color: transparent;
}

.reader-chapters small {
  font-size: 0.78rem;
  opacity: 0.8;
}

.reader-summary {
  display: grid;
  gap: 8px;
  padding: 16px;
  border-radius: 22px;
}

.reader-summary h2 {
  margin: 0;
  color: #5b3116;
}

.reader-pages {
  display: grid;
  gap: 18px;
  margin-top: 18px;
}

.comic-page {
  display: grid;
  gap: 10px;
  padding: 10px;
  border-radius: 22px;
}

.page-caption {
  display: flex;
  align-items: center;
  gap: 9px;
  color: #6c3d18;
}

.charged-theme .page-caption {
  color: #f5dfbd;
}

.page-caption span {
  flex: 0 0 auto;
  padding: 5px 10px;
  border-radius: 999px;
  color: #6a3512;
  background: rgba(255, 189, 67, 0.36);
  font-weight: 900;
}

.charged-theme .page-caption span {
  color: #1d1510;
  background: #e5ad62;
}

.page-caption strong {
  min-width: 0;
  overflow-wrap: anywhere;
}

.comic-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: contain;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.35);
  box-shadow: 0 16px 36px rgba(119, 68, 21, 0.16);
}

.charged-theme .comic-image {
  background: #08090d;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.38);
}

.comic-page p {
  margin: 0;
  padding: 0 4px 4px;
  color: #5b3a1f;
  font-size: 0.94rem;
}

.bottom-actions {
  margin-top: 18px;
  padding: 12px;
  border-radius: 18px;
}

@media (min-width: 560px) {
  .work-card {
    grid-template-columns: 180px 1fr;
    align-items: start;
  }

  .work-card.cover-wide {
    grid-template-columns: minmax(220px, 0.95fr) minmax(0, 1fr);
  }

  .card-button {
    grid-column: 1 / -1;
    justify-self: start;
  }

  .character-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .reader-chapters {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 780px) {
  .shelf-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .work-card {
    grid-template-columns: 1fr;
  }

  .work-card.cover-wide {
    grid-template-columns: 1fr;
  }

  .detail-hero {
    grid-template-columns: minmax(0, 1fr) minmax(320px, 0.78fr);
    align-items: center;
    padding: 24px;
  }

  .charged-detail-hero {
    grid-template-columns: minmax(0, 0.86fr) minmax(360px, 1.14fr);
  }

  .intro-section,
  .chapter-section {
    padding: 20px;
  }

  .character-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .chapter-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .chapter-grid.two-chapters {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .comic-page {
    padding: 16px;
  }
}

@media (max-width: 430px) {
  .brand-hero {
    min-height: 78vh;
  }

  .primary-action,
  .soft-action,
  .card-button,
  .plain-link {
    width: 100%;
  }

  .reader-top {
    display: grid;
    justify-items: stretch;
  }

  .reader-top div {
    text-align: left;
  }
}
