/* ============================================
   暖叮读 官网推广页 — KaDa 风格
   移动优先 · 清爽大气 · 红白配色
   ============================================ */

/* --- CSS Variables --- */
:root {
  --color-primary: #E84747;
  --color-primary-dark: #C62828;
  --color-primary-light: #FF6B6B;
  --color-white: #FFFFFF;
  --color-bg: #FFFFFF;
  --color-bg-light: #F8F9FA;
  --color-bg-warm: #FFF5F5;
  --color-text: #333333;
  --color-text-secondary: #666666;
  --color-text-muted: #999999;
  --color-border: #E8E8E8;
  --shadow-card: 0 2px 12px rgba(0, 0, 0, 0.06);
  --shadow-card-hover: 0 8px 28px rgba(0, 0, 0, 0.10);
  --shadow-nav: 0 1px 4px rgba(0, 0, 0, 0.06);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-pill: 999px;
  --font-family: "PingFang SC", "Noto Sans SC", "Microsoft YaHei", -apple-system, sans-serif;
  --max-width: 1200px;
  --transition: 0.25s ease;
}

/* --- Reset & Base --- */
*,
*::before,
*::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-family);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.7;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }

/* --- Utility --- */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

.section {
  padding: 60px 0;
}

.section-header {
  text-align: center;
  margin-bottom: 48px;
}

.section-title {
  font-size: 28px;
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: 12px;
  letter-spacing: 0.5px;
}

.section-subtitle {
  font-size: 16px;
  color: var(--color-text-secondary);
  max-width: 600px;
  margin: 0 auto;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 36px;
  font-size: 16px;
  font-weight: 600;
  border-radius: var(--radius-pill);
  border: none;
  cursor: pointer;
  transition: all var(--transition);
  white-space: nowrap;
  letter-spacing: 0.3px;
}

.btn-primary {
  background: var(--color-primary);
  color: var(--color-white);
  box-shadow: 0 4px 16px rgba(232, 71, 71, 0.3);
}

.btn-primary:hover {
  background: var(--color-primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(232, 71, 71, 0.4);
}

.btn-outline {
  background: transparent;
  color: var(--color-primary);
  border: 2px solid var(--color-primary);
}

.btn-outline:hover {
  background: var(--color-primary);
  color: var(--color-white);
  transform: translateY(-2px);
}

.btn-white {
  background: var(--color-white);
  color: var(--color-primary);
  box-shadow: var(--shadow-card);
}

.btn-white:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-card-hover);
}

.btn-lg {
  padding: 16px 44px;
  font-size: 18px;
}

.btn-sm {
  padding: 10px 24px;
  font-size: 14px;
}

/* --- Navbar --- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: var(--shadow-nav);
  height: 64px;
  display: flex;
  align-items: center;
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  font-weight: 700;
  color: var(--color-primary);
}

.nav-brand .brand-icon {
  width: 36px;
  height: 36px;
  background: var(--color-primary);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-white);
  font-size: 20px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-links a {
  font-size: 15px;
  color: var(--color-text-secondary);
  font-weight: 500;
  transition: color var(--transition);
  position: relative;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--color-primary);
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--color-primary);
  border-radius: 1px;
  transition: width var(--transition);
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  color: var(--color-text);
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-text);
  border-radius: 1px;
  transition: all var(--transition);
}

.nav-toggle span + span { margin-top: 6px; }

/* --- Hero --- */
.hero {
  padding: 120px 0 80px;
  background: linear-gradient(180deg, var(--color-bg-warm) 0%, var(--color-white) 100%);
  overflow: hidden;
}

.hero .container {
  display: flex;
  align-items: center;
  gap: 60px;
}

.hero-content {
  flex: 1;
  min-width: 0;
}

.hero-tag {
  display: inline-block;
  background: rgba(232, 71, 71, 0.1);
  color: var(--color-primary);
  font-size: 14px;
  font-weight: 600;
  padding: 6px 16px;
  border-radius: var(--radius-pill);
  margin-bottom: 20px;
}

.hero-title {
  font-size: 44px;
  font-weight: 800;
  line-height: 1.25;
  color: var(--color-text);
  margin-bottom: 16px;
  letter-spacing: 1px;
}

.hero-title .highlight {
  color: var(--color-primary);
  position: relative;
}

.hero-desc {
  font-size: 18px;
  color: var(--color-text-secondary);
  line-height: 1.7;
  margin-bottom: 36px;
  max-width: 480px;
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.hero-visual {
  flex: 0 0 360px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-mockup {
  width: 280px;
  height: 520px;
  background: var(--color-white);
  border-radius: 28px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.12);
  position: relative;
  overflow: hidden;
  border: 3px solid var(--color-border);
}

.hero-mockup-inner {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 24px;
  text-align: center;
}

.hero-mockup-inner .mock-icon {
  font-size: 56px;
  margin-bottom: 16px;
}

.hero-mockup-inner .mock-label {
  font-size: 14px;
  color: var(--color-text-muted);
  margin-bottom: 8px;
}

.hero-mockup-inner .mock-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--color-primary);
}

/* --- Features --- */
.features {
  background: var(--color-white);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.feature-card {
  text-align: center;
  padding: 36px 24px;
  border-radius: var(--radius-lg);
  background: var(--color-white);
  box-shadow: var(--shadow-card);
  transition: transform var(--transition), box-shadow var(--transition);
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-card-hover);
}

.feature-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 20px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 30px;
}

.feature-icon.red { background: #FFF0F0; }
.feature-icon.blue { background: #F0F4FF; }
.feature-icon.green { background: #F0FFF4; }
.feature-icon.orange { background: #FFF8F0; }

.feature-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: 8px;
}

.feature-desc {
  font-size: 14px;
  color: var(--color-text-secondary);
  line-height: 1.6;
}

/* --- Books Showcase --- */
.books-showcase {
  background: var(--color-bg-light);
}

/* --- Series List --- */
.series-list {
  display: flex;
  flex-direction: column;
  gap: 32px;
  max-width: 800px;
  margin: 0 auto;
}

.series-card {
  display: flex;
  gap: 24px;
  background: var(--color-white);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-card);
  transition: box-shadow var(--transition);
}

.series-card:hover {
  box-shadow: var(--shadow-card-hover);
}

.series-cover {
  flex: 0 0 160px;
  aspect-ratio: 3 / 4;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: #F0F0F0;
}

.series-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.series-cover .cover-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 48px;
  color: var(--color-text-muted);
}

.series-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.series-name {
  font-size: 20px;
  font-weight: 700;
  color: var(--color-text);
}

.series-tagline {
  font-size: 14px;
  color: var(--color-text-muted);
}

.series-count {
  font-size: 13px;
  color: var(--color-primary);
  font-weight: 600;
}

.series-vols {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.vol-tag {
  font-size: 12px;
  color: var(--color-white);
  padding: 3px 10px;
  border-radius: var(--radius-pill);
  white-space: nowrap;
}

/* --- Download --- */
.download {
  background: linear-gradient(180deg, var(--color-bg-warm) 0%, var(--color-white) 100%);
}

.download-grid {
  display: flex;
  justify-content: center;
  gap: 48px;
  flex-wrap: wrap;
}

.download-item {
  text-align: center;
  flex: 0 0 auto;
}

.download-qr {
  width: 160px;
  height: 160px;
  background: var(--color-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
  font-size: 14px;
  color: var(--color-text-muted);
  border: 2px dashed var(--color-border);
}

.download-platform {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 4px;
}

.download-platform .platform-icon {
  font-size: 24px;
}

.download-hint {
  font-size: 13px;
  color: var(--color-text-muted);
}

.download-note {
  text-align: center;
  margin-top: 32px;
  font-size: 14px;
  color: var(--color-text-muted);
}

/* --- Footer --- */
.footer {
  background: #2B2B2B;
  color: #BBBBBB;
  padding: 48px 0 32px;
}

.footer .container {
  text-align: center;
}

.footer-brand {
  font-size: 20px;
  font-weight: 700;
  color: var(--color-white);
  margin-bottom: 8px;
}

.footer-slogan {
  font-size: 14px;
  color: #999999;
  margin-bottom: 24px;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.footer-links a {
  font-size: 13px;
  color: #BBBBBB;
  transition: color var(--transition);
}

.footer-links a:hover {
  color: var(--color-white);
}

.footer-copy {
  font-size: 12px;
  color: #777777;
  padding-top: 20px;
  border-top: 1px solid #3A3A3A;
}

/* --- Back to top --- */
.back-to-top {
  position: fixed;
  bottom: 32px;
  right: 32px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--color-primary);
  color: var(--color-white);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  box-shadow: 0 4px 16px rgba(232, 71, 71, 0.35);
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: all var(--transition);
  z-index: 999;
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  background: var(--color-primary-dark);
  transform: translateY(-2px);
}

/* ============================================
   Responsive
   ============================================ */

/* Tablet (768px - 1024px) */
@media (max-width: 1024px) {
  .hero .container {
    gap: 40px;
  }

  .hero-title {
    font-size: 36px;
  }

  .hero-visual {
    flex: 0 0 280px;
  }

  .hero-mockup {
    width: 220px;
    height: 420px;
  }

  .features-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .series-card {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .series-cover {
    flex: 0 0 160px;
    width: 160px;
  }
}

/* Mobile (< 768px) */
@media (max-width: 768px) {
  .section {
    padding: 48px 0;
  }

  .section-title {
    font-size: 24px;
  }

  .section-header {
    margin-bottom: 36px;
  }

  /* Navbar mobile */
  .nav-links {
    display: none;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: var(--color-white);
    flex-direction: column;
    padding: 20px;
    gap: 16px;
    box-shadow: var(--shadow-card);
  }

  .nav-links.open {
    display: flex;
  }

  .nav-toggle {
    display: block;
  }

  /* Hero mobile */
  .hero {
    padding: 96px 0 48px;
  }

  .hero .container {
    flex-direction: column;
    text-align: center;
    gap: 32px;
  }

  .hero-title {
    font-size: 30px;
  }

  .hero-desc {
    font-size: 16px;
    max-width: 100%;
  }

  .hero-actions {
    justify-content: center;
  }

  .hero-visual {
    flex: 0 0 auto;
  }

  .hero-mockup {
    width: 200px;
    height: 380px;
    border-radius: 22px;
  }

  /* Features mobile */
  .features-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  /* Series mobile */
  .series-card {
    gap: 16px;
  }

  /* Download mobile */
  .download-grid {
    gap: 32px;
  }

  .back-to-top {
    bottom: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    font-size: 18px;
  }
}

/* Small Mobile (< 480px) */
@media (max-width: 480px) {
  .hero-title {
    font-size: 26px;
  }

  .hero-desc {
    font-size: 15px;
  }

  .btn-lg {
    padding: 14px 32px;
    font-size: 16px;
  }

  .hero-actions {
    flex-direction: column;
    align-items: center;
  }

  .series-card {
    padding: 16px;
  }
}
