/* ==========================================================
   有妖气漫画 · 官网样式表
   风格：妖气黄漫画风 · 炭黑描边 · 对话气泡 · 移动优先
   ========================================================== */

:root {
  --ink: #221b14;
  --ink-soft: #6f6252;
  --paper: #fffdf7;
  --cream: #fff6e0;
  --yellow: #ffc53d;
  --yellow-deep: #f5a800;
  --sakura: #ff8fb2;
  --red: #ff5a3c;
  --line: #221b14;
  --shadow: 6px 6px 0 rgba(34, 27, 20, 0.95);
  --radius-lg: 18px;
  --radius-md: 12px;
  --radius-sm: 8px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.001s !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001s !important;
  }
}

body {
  background: var(--paper);
  color: var(--ink);
  font-family: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.7;
  overflow-x: hidden;
}

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

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

ul,
ol {
  list-style: none;
}

button {
  font-family: inherit;
}

h1,
h2,
h3,
.brand-name {
  font-family: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  font-weight: 900;
  line-height: 1.24;
  letter-spacing: 0.01em;
}

:focus-visible {
  outline: 3px solid var(--yellow-deep);
  outline-offset: 2px;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 10px;
  z-index: 100;
  background: var(--paper);
  border: 2px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 8px 16px;
  font-weight: 700;
}

.skip-link:focus {
  left: 10px;
}

.container {
  width: min(1120px, 100% - 40px);
  margin-inline: auto;
}

section[id] {
  scroll-margin-top: 78px;
}

/* ========== 顶部导航 ========== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 253, 247, 0.92);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border-bottom: 2px solid transparent;
  transition: border-color 0.25s, box-shadow 0.25s;
}

.site-header.is-scrolled {
  border-bottom-color: var(--line);
  box-shadow: 0 4px 0 rgba(34, 27, 20, 0.14);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 68px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.brand-icon {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  border: 2px solid var(--line);
  background: var(--paper);
}

.brand-name {
  font-size: 1.32rem;
  letter-spacing: 0.02em;
}

.nav-toggle {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: 46px;
  height: 46px;
  background: var(--paper);
  border: 2px solid var(--line);
  border-radius: var(--radius-sm);
  box-shadow: 3px 3px 0 rgba(34, 27, 20, 0.9);
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 3px;
  border-radius: 99px;
  background: var(--ink);
  transition: transform 0.22s, opacity 0.22s;
}

.nav-toggle.is-active span:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}

.nav-toggle.is-active span:nth-child(2) {
  opacity: 0;
}

.nav-toggle.is-active span:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}

.site-nav {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 20px 22px;
  background: var(--paper);
  border-bottom: 2px solid var(--line);
  transform: translateY(-10px);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.22s, opacity 0.22s;
}

.site-nav.is-open {
  transform: none;
  opacity: 1;
  pointer-events: auto;
}

.site-nav a {
  display: block;
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  font-weight: 700;
}

.site-nav a:hover {
  background: var(--cream);
}

.site-nav .nav-download {
  margin-top: 6px;
  text-align: center;
  background: var(--yellow);
  color: var(--ink);
  border: 2px solid var(--line);
  border-radius: 999px;
  box-shadow: 3px 3px 0 rgba(34, 27, 20, 0.9);
}

@media (min-width: 900px) {
  .nav-toggle {
    display: none;
  }

  .site-nav {
    position: static;
    flex-direction: row;
    align-items: center;
    gap: 4px;
    padding: 0;
    background: none;
    border-bottom: 0;
    transform: none;
    opacity: 1;
    pointer-events: auto;
  }

  .site-nav a {
    padding: 9px 13px;
  }

  .site-nav .nav-download {
    margin: 0 0 0 8px;
    padding: 10px 22px;
    background: var(--yellow);
    color: var(--ink);
    box-shadow: 4px 4px 0 rgba(34, 27, 20, 0.9);
    transition: transform 0.15s, box-shadow 0.15s;
  }

  .site-nav .nav-download:hover {
    transform: translate(-2px, -2px);
    box-shadow: 7px 7px 0 rgba(34, 27, 20, 0.9);
    background: var(--yellow-deep);
  }
}

/* ========== 按钮 ========== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 28px;
  border: 2.5px solid var(--line);
  border-radius: 999px;
  font-weight: 900;
  font-size: 1rem;
  transition: transform 0.15s, box-shadow 0.15s, background 0.15s;
}

.btn-primary {
  background: var(--yellow);
  color: var(--ink);
  box-shadow: 5px 5px 0 var(--line);
}

.btn-primary:hover {
  transform: translate(-2px, -2px);
  box-shadow: 8px 8px 0 var(--line);
  background: var(--yellow-deep);
}

.btn-ghost {
  background: var(--paper);
  box-shadow: 5px 5px 0 var(--line);
}

.btn-ghost:hover {
  transform: translate(-2px, -2px);
  box-shadow: 8px 8px 0 var(--line);
}

.btn-lg {
  padding: 16px 42px;
  font-size: 1.1rem;
}

/* ========== 首页 Hero ========== */

.hero {
  position: relative;
  overflow: hidden;
  padding: 56px 0 68px;
  background: linear-gradient(180deg, var(--yellow) 0%, #ffd873 55%, var(--paper) 100%);
}

.hero-dots {
  position: absolute;
  inset: 0;
  z-index: 0;
  background-image: radial-gradient(rgba(34, 27, 20, 0.14) 2.5px, transparent 2.5px);
  background-size: 26px 26px;
  -webkit-mask-image: radial-gradient(circle at 78% 30%, #000 0%, transparent 60%);
  mask-image: radial-gradient(circle at 78% 30%, #000 0%, transparent 60%);
  pointer-events: none;
}

.hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr;
  gap: 44px;
  align-items: center;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 6px 14px;
  background: var(--paper);
  border: 2px solid var(--line);
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 700;
  box-shadow: 3px 3px 0 rgba(34, 27, 20, 0.85);
  transform: rotate(-1deg);
}

.eyebrow-bubble {
  width: 14px;
  height: 12px;
  border-radius: 6px 6px 6px 2px;
  background: var(--sakura);
  border: 1.5px solid var(--line);
}

.hero h1 {
  margin: 20px 0 16px;
  font-size: clamp(2.4rem, 7.4vw, 3.9rem);
  letter-spacing: 0.02em;
}

.h1-accent {
  position: relative;
  z-index: 0;
  color: var(--red);
  white-space: nowrap;
}

.h1-accent::after {
  content: "";
  position: absolute;
  left: -5px;
  right: -5px;
  bottom: 5px;
  height: 0.52em;
  z-index: -1;
  background: var(--sakura);
  border-radius: 6px;
  transform: rotate(-1.5deg);
}

.hero-sub {
  max-width: 32em;
  color: var(--ink);
  font-weight: 500;
  font-size: 1.05rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin: 26px 0 0;
}

.hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 32px;
  margin-top: 34px;
  padding-top: 22px;
  border-top: 2.5px dashed rgba(34, 27, 20, 0.35);
}

.hero-stats strong {
  display: block;
  font-size: 1.55rem;
  line-height: 1.2;
  color: var(--red);
  letter-spacing: 0.02em;
}

.hero-stats span {
  font-size: 0.85rem;
  color: var(--ink-soft);
  font-weight: 700;
}

/* 主视觉海报 */

.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
  padding: 26px 4px 30px;
}

.hero-poster {
  position: relative;
  width: min(300px, 76vw);
  aspect-ratio: 3 / 4;
  overflow: hidden;
  border: 3px solid var(--line);
  border-radius: 22px;
  background: var(--paper);
  box-shadow: 12px 12px 0 rgba(34, 27, 20, 0.95);
  transform: rotate(1.5deg);
}

.hero-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.poster-tag {
  position: absolute;
  left: 14px;
  bottom: 14px;
  padding: 6px 14px;
  background: var(--yellow);
  border: 2px solid var(--line);
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 900;
  box-shadow: 3px 3px 0 rgba(34, 27, 20, 0.9);
}

.hero-icon {
  position: absolute;
  top: -10px;
  left: 4%;
  width: 96px;
  height: 96px;
  border-radius: 26px;
  border: 3px solid var(--line);
  background: var(--paper);
  box-shadow: 6px 6px 0 rgba(34, 27, 20, 0.9);
  transform: rotate(-8deg);
  animation: wiggle 3.4s ease-in-out infinite;
  z-index: 2;
}

@keyframes wiggle {
  0%,
  100% {
    transform: rotate(-8deg) translateY(0);
  }
  50% {
    transform: rotate(-4deg) translateY(-9px);
  }
}

.speech-chip {
  position: absolute;
  padding: 8px 15px;
  background: var(--paper);
  border: 2.5px solid var(--line);
  border-radius: 14px;
  font-size: 0.84rem;
  font-weight: 900;
  box-shadow: 4px 4px 0 rgba(34, 27, 20, 0.9);
  white-space: nowrap;
}

.speech-chip::after {
  content: "";
  position: absolute;
  bottom: -9px;
  left: 22px;
  width: 14px;
  height: 14px;
  background: var(--paper);
  border-right: 2.5px solid var(--line);
  border-bottom: 2.5px solid var(--line);
  transform: rotate(45deg);
  clip-path: polygon(0 0, 100% 100%, 0 100%);
}

.chip-top {
  top: 2%;
  right: 0;
  transform: rotate(2deg);
}

.chip-top::after {
  left: auto;
  right: 24px;
}

.chip-bottom {
  bottom: 2%;
  left: 0;
  transform: rotate(-2deg);
  background: var(--sakura);
  color: var(--ink);
}

.chip-bottom::after {
  background: var(--sakura);
}

/* ========== 通用区块 ========== */

.section {
  padding: 64px 0;
}

.section-head {
  max-width: 640px;
  margin-bottom: 36px;
}

.section-tag {
  display: inline-block;
  padding: 5px 14px;
  margin-bottom: 14px;
  background: var(--yellow);
  border: 2px solid var(--line);
  border-radius: var(--radius-sm);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.16em;
  box-shadow: 3px 3px 0 rgba(34, 27, 20, 0.85);
}

.section-head h2 {
  font-size: clamp(1.6rem, 4.6vw, 2.4rem);
  margin-bottom: 10px;
}

.head-accent {
  color: var(--red);
}

.section-sub {
  color: var(--ink-soft);
  font-weight: 500;
}

/* ========== 特色功能 ========== */

.feature-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

.feature-card {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 22px 20px;
  background: var(--paper);
  border: 2.5px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  transition: transform 0.18s, box-shadow 0.18s;
}

.feature-card:hover {
  transform: translate(-3px, -3px);
  box-shadow: 9px 9px 0 var(--line);
}

.feature-icon {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 54px;
  height: 54px;
  border-radius: 16px;
  background: var(--cream);
  border: 2px solid var(--line);
  color: var(--red);
  transform: rotate(-4deg);
}

.feature-icon svg {
  width: 27px;
  height: 27px;
  transform: rotate(4deg);
}

.feature-text h3 {
  font-size: 1.16rem;
  margin-bottom: 4px;
}

.feature-text p {
  color: var(--ink-soft);
  font-size: 0.94rem;
}

/* ========== 精选漫画 ========== */

.showcase {
  background: linear-gradient(180deg, var(--paper) 0%, var(--cream) 50%, var(--paper) 100%);
}

.show-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 22px;
}

.show-item {
  margin: 0;
  padding: 10px 10px 14px;
  background: var(--paper);
  border: 2.5px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  transition: transform 0.18s, box-shadow 0.18s;
}

.show-item:hover {
  transform: translate(-3px, -3px) rotate(-0.5deg);
  box-shadow: 9px 9px 0 var(--line);
}

.show-item img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border: 2px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--cream);
}

.show-item figcaption {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 12px;
  padding: 0 4px;
}

.show-tag {
  padding: 3px 12px;
  background: var(--red);
  color: #fff;
  border: 2px solid var(--line);
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 900;
  box-shadow: 2px 2px 0 rgba(34, 27, 20, 0.9);
}

.show-name {
  font-weight: 900;
  font-size: 0.98rem;
}

/* ========== 漫画分类 ========== */

.lib-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

.lib-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 5px;
  min-height: 168px;
  padding: 26px 24px;
  background: var(--cream);
  border: 2.5px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: transform 0.18s, box-shadow 0.18s;
}

.lib-card:hover {
  transform: translate(-3px, -3px);
  box-shadow: 9px 9px 0 var(--line);
}

.lib-card::before {
  content: "";
  position: absolute;
  right: -22px;
  top: -22px;
  width: 92px;
  height: 92px;
  border-radius: 20px;
  background: rgba(255, 197, 61, 0.55);
  border: 3px solid var(--line);
  transform: rotate(18deg);
  pointer-events: none;
}

.lib-c1 {
  background: #ffe9ef;
}
.lib-c2 {
  background: #fff0d9;
}
.lib-c3 {
  background: #ffeede;
}
.lib-c4 {
  background: #eceaff;
}
.lib-c5 {
  background: #ffe3d6;
}
.lib-c6 {
  background: #fdf3c8;
}

.lib-card h3 {
  position: relative;
  z-index: 1;
  font-size: 1.26rem;
  letter-spacing: 0.03em;
}

.lib-card p {
  position: relative;
  z-index: 1;
  color: var(--ink-soft);
  font-size: 0.9rem;
}

.lib-go {
  position: relative;
  z-index: 1;
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 14px;
  background: var(--paper);
  border: 2px solid var(--line);
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 900;
  box-shadow: 2px 2px 0 rgba(34, 27, 20, 0.85);
  transition: background 0.15s;
}

.lib-card:hover .lib-go {
  background: var(--yellow);
}

/* ========== 更新动态 ========== */

.update-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  max-width: 760px;
}

.update-item {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  padding: 20px 22px;
  background: var(--paper);
  border: 2.5px solid var(--line);
  border-radius: var(--radius-md);
  box-shadow: 4px 4px 0 rgba(34, 27, 20, 0.9);
  transition: transform 0.18s, box-shadow 0.18s;
}

.update-item:hover {
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0 var(--line);
}

.update-ver {
  flex: none;
  padding: 4px 14px;
  background: var(--yellow);
  border: 2px solid var(--line);
  border-radius: var(--radius-sm);
  font-weight: 900;
  font-size: 0.95rem;
  box-shadow: 3px 3px 0 rgba(34, 27, 20, 0.9);
}

.update-body h3 {
  font-size: 1.1rem;
  margin-bottom: 4px;
}

.update-body p {
  color: var(--ink-soft);
  font-size: 0.93rem;
}

/* ========== 下载区 ========== */

.download {
  padding-top: 48px;
}

.download-card {
  position: relative;
  display: grid;
  grid-template-columns: 1fr;
  gap: 34px;
  padding: 40px 28px;
  background: linear-gradient(135deg, var(--yellow), #ffd873);
  border: 3px solid var(--line);
  border-radius: 26px;
  box-shadow: 12px 12px 0 rgba(34, 27, 20, 0.95);
  overflow: hidden;
}

.download-card::before {
  content: "";
  position: absolute;
  right: -34px;
  top: -34px;
  width: 150px;
  height: 150px;
  border-radius: 26px;
  background: rgba(255, 143, 178, 0.35);
  border: 3px solid var(--line);
  transform: rotate(18deg);
  pointer-events: none;
}

.dl-copy .section-tag {
  background: var(--red);
  color: #fff;
}

.dl-copy h2 {
  font-size: clamp(1.7rem, 4.8vw, 2.4rem);
  margin: 4px 0 8px;
}

.dl-sub {
  font-weight: 500;
  color: rgba(34, 27, 20, 0.82);
}

.dl-points {
  display: grid;
  gap: 10px;
  margin: 20px 0 26px;
}

.dl-points li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
}

.dl-points li::before {
  content: "";
  flex: none;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: var(--red);
  border: 2px solid var(--line);
}

.dl-note {
  margin-top: 16px;
  font-size: 0.82rem;
  color: rgba(34, 27, 20, 0.75);
  font-weight: 500;
}

.dl-visual {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px 0;
}

.dl-icon {
  width: min(150px, 46%);
  height: auto;
  border-radius: 36px;
  border: 3px solid var(--line);
  background: var(--paper);
  box-shadow: 8px 8px 0 rgba(34, 27, 20, 0.9);
  transform: rotate(-6deg);
}

.dl-chip {
  position: absolute;
  bottom: 4px;
  left: 2%;
  padding: 7px 14px;
  background: var(--paper);
  border: 2px solid var(--line);
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 900;
  box-shadow: 3px 3px 0 rgba(34, 27, 20, 0.9);
  transform: rotate(-2deg);
  white-space: nowrap;
}

/* ========== 页脚 ========== */

.site-footer {
  margin-top: 56px;
  background: var(--ink);
  color: #fff6e0;
  padding: 42px 0 34px;
}

.footer-inner {
  display: grid;
  gap: 24px;
  justify-items: center;
  text-align: center;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  font-size: 1.3rem;
  letter-spacing: 0.03em;
}

.footer-brand img {
  border-radius: 12px;
  border: 2px solid rgba(255, 246, 224, 0.4);
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 22px;
  font-size: 0.92rem;
  font-weight: 700;
}

.footer-nav a {
  transition: color 0.15s;
}

.footer-nav a:hover {
  color: var(--yellow);
}

.footer-meta {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 0.85rem;
  color: rgba(255, 246, 224, 0.66);
}

.footer-meta a {
  text-decoration: underline;
}

/* ========== 响应式 ========== */

@media (min-width: 560px) {
  .feature-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .show-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .lib-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 640px) {
  .update-list {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 900px) {
  .hero {
    padding: 76px 0 88px;
  }

  .hero-inner {
    grid-template-columns: 1.08fr 0.92fr;
    gap: 48px;
  }

  .hero-visual {
    padding: 18px 10px 30px;
  }

  .section {
    padding: 84px 0;
  }

  .show-grid {
    grid-template-columns: repeat(4, 1fr);
  }

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

  .download-card {
    grid-template-columns: 1.25fr 0.75fr;
    align-items: center;
    padding: 52px 56px;
  }

  .download {
    padding-top: 60px;
  }
}
