/* 糖心Vlog传媒 - tang-xin.biz */
:root {
  --bg: #0c0b10;
  --bg-elevated: #16141c;
  --bg-soft: #1e1b26;
  --line: rgba(255, 255, 255, 0.08);
  --text: #f4f0f7;
  --text-muted: #a89bb0;
  --brand-a: #ff7a3d;
  --brand-b: #e91e8c;
  --brand-grad: linear-gradient(135deg, #ff7a3d 0%, #e91e8c 100%);
  --radius: 14px;
  --shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
  --max: 1180px;
  --font-display: "ZCOOL XiaoWei", "Noto Serif SC", serif;
  --font-body: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  background:
    radial-gradient(ellipse 80% 50% at 10% -10%, rgba(255, 122, 61, 0.18), transparent 55%),
    radial-gradient(ellipse 70% 45% at 90% 0%, rgba(233, 30, 140, 0.16), transparent 50%),
    linear-gradient(180deg, #120f18 0%, var(--bg) 35%, #0a0910 100%);
  color: var(--text);
  line-height: 1.75;
  min-height: 100vh;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: #ffb08a;
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: #fff;
}

.container {
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(16px);
  background: rgba(12, 11, 16, 0.82);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  color: var(--text);
  font-family: var(--font-display);
  font-size: 1.35rem;
  letter-spacing: 0.04em;
}

.brand img {
  width: 42px;
  height: 42px;
  border-radius: 10px;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1.1rem;
  align-items: center;
}

.nav a {
  color: var(--text-muted);
  font-size: 0.95rem;
}

.nav a:hover,
.nav a.active {
  color: var(--text);
  background: var(--brand-grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.menu-toggle {
  display: none;
  width: 40px;
  height: 40px;
  padding: 0;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  background: var(--bg-soft);
  border: 1px solid var(--line);
  color: var(--text);
  border-radius: 10px;
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.menu-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.menu-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.menu-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Hero */
.hero {
  position: relative;
  overflow: hidden;
  padding: 3.5rem 0 2.5rem;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 2rem;
  align-items: center;
}

.hero-copy h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.25;
  margin: 0 0 1rem;
  background: var(--brand-grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-copy .lead {
  color: var(--text-muted);
  font-size: 1.08rem;
  margin: 0 0 1.5rem;
  max-width: 36em;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.35rem;
  border-radius: 999px;
  font-weight: 600;
  border: 1px solid transparent;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  background: var(--brand-grad);
  color: #fff;
  box-shadow: 0 10px 28px rgba(233, 30, 140, 0.28);
}

.btn-primary:hover {
  color: #fff;
}

.btn-ghost {
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
}

.hero-visual {
  position: relative;
  border-radius: 22px;
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid var(--line);
  animation: floatIn 0.9s ease both;
}

.hero-visual img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: top;
}

.hero-badge {
  position: absolute;
  left: 1rem;
  bottom: 1rem;
  padding: 0.55rem 0.9rem;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(8px);
  font-size: 0.9rem;
}

@keyframes floatIn {
  from {
    opacity: 0;
    transform: translateY(18px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.section {
  padding: 3rem 0;
}

.section-head {
  margin-bottom: 1.6rem;
  max-width: 46rem;
}

.section-head h2 {
  font-family: var(--font-display);
  font-size: clamp(1.55rem, 3vw, 2.1rem);
  margin: 0 0 0.6rem;
}

.section-head p {
  margin: 0;
  color: var(--text-muted);
}

.prose {
  color: var(--text-muted);
  font-size: 1.02rem;
}

.prose p {
  margin: 0 0 1.1rem;
}

.prose h2,
.prose h3 {
  color: var(--text);
  font-family: var(--font-display);
  margin: 2rem 0 0.85rem;
}

.prose ul,
.prose ol {
  padding-left: 1.2rem;
  margin: 0 0 1.1rem;
}

.prose li {
  margin-bottom: 0.45rem;
}

/* Category / media grids */
.cat-grid,
.media-grid,
.feature-grid,
.vlog-grid {
  display: grid;
  gap: 1rem;
}

.cat-grid {
  grid-template-columns: repeat(4, 1fr);
}

.media-grid {
  grid-template-columns: repeat(3, 1fr);
}

.feature-grid {
  grid-template-columns: repeat(3, 1fr);
}

.vlog-grid {
  grid-template-columns: repeat(4, 1fr);
}

.media-card,
.feature-card,
.cat-card {
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.25s ease, border-color 0.25s ease;
  animation: rise 0.7s ease both;
}

.media-card:hover,
.feature-card:hover,
.cat-card:hover {
  transform: translateY(-4px);
  border-color: rgba(255, 122, 61, 0.35);
}

.media-card img,
.cat-card img,
.feature-card img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  object-position: top;
}

.media-card .body,
.cat-card .body,
.feature-card .body {
  padding: 0.9rem 1rem 1.1rem;
}

.media-card h3,
.cat-card h3,
.feature-card h3 {
  margin: 0 0 0.4rem;
  font-size: 1.05rem;
  font-family: var(--font-display);
}

.media-card p,
.cat-card p,
.feature-card p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.92rem;
}

.feature-card {
  display: grid;
  grid-template-rows: auto 1fr;
}

.feature-card img {
  aspect-ratio: 16 / 10;
}

/* Split content */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  align-items: center;
}

.split.reverse .copy {
  order: 2;
}

.split img {
  border-radius: var(--radius);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  aspect-ratio: 3 / 4;
  object-fit: cover;
  object-position: top;
  width: 100%;
}

.pill-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
}

.pill-list li a {
  display: inline-block;
  padding: 0.35rem 0.8rem;
  border-radius: 999px;
  background: var(--bg-soft);
  border: 1px solid var(--line);
  color: var(--text-muted);
  font-size: 0.88rem;
}

.pill-list li a:hover {
  color: #fff;
  border-color: rgba(233, 30, 140, 0.45);
}

/* TOC / internal links box */
.toc-box {
  background: linear-gradient(145deg, rgba(255, 122, 61, 0.08), rgba(233, 30, 140, 0.08));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.2rem 1.35rem;
  margin: 1.5rem 0;
}

.toc-box h3 {
  margin: 0 0 0.7rem;
  font-family: var(--font-display);
  font-size: 1.15rem;
}

.toc-box ol {
  margin: 0;
  padding-left: 1.2rem;
  color: var(--text-muted);
}

.toc-box a {
  color: #ffb08a;
}

/* FAQ */
.faq details {
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.9rem 1.1rem;
  margin-bottom: 0.7rem;
}

.faq summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--text);
}

.faq details p {
  color: var(--text-muted);
  margin: 0.7rem 0 0;
}

/* Page banner for secondary pages */
.page-banner {
  padding: 2.6rem 0 1.4rem;
  border-bottom: 1px solid var(--line);
  margin-bottom: 0.5rem;
}

.page-banner h1 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3.5vw, 2.4rem);
  margin: 0 0 0.5rem;
}

.page-banner p {
  margin: 0;
  color: var(--text-muted);
}

.breadcrumb {
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-bottom: 0.8rem;
}

.breadcrumb a {
  color: var(--text-muted);
}

.content-wrap {
  display: grid;
  grid-template-columns: 1fr 260px;
  gap: 1.8rem;
  padding: 2rem 0 3rem;
}

.side-nav {
  position: sticky;
  top: 5.5rem;
  align-self: start;
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1rem;
}

.side-nav h3 {
  margin: 0 0 0.7rem;
  font-size: 0.95rem;
  font-family: var(--font-display);
}

.side-nav a {
  display: block;
  padding: 0.4rem 0;
  color: var(--text-muted);
  font-size: 0.9rem;
  border-bottom: 1px solid var(--line);
}

.side-nav a:last-child {
  border-bottom: 0;
}

/* Error pages */
.error-page {
  min-height: 70vh;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 3rem 1rem;
}

.error-page .code {
  font-family: var(--font-display);
  font-size: clamp(4rem, 12vw, 7rem);
  line-height: 1;
  background: var(--brand-grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  margin: 0;
}

.error-page h1 {
  margin: 0.5rem 0 0.8rem;
  font-family: var(--font-display);
}

.error-page p {
  color: var(--text-muted);
  max-width: 28rem;
  margin: 0 auto 1.4rem;
}

/* Footer */
.site-footer {
  margin-top: 2rem;
  border-top: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.35);
  padding: 2.4rem 0 1.6rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 1.5rem;
  margin-bottom: 1.6rem;
}

.footer-brand {
  display: flex;
  gap: 0.8rem;
  align-items: flex-start;
}

.footer-brand img {
  width: 48px;
  height: 48px;
  border-radius: 12px;
}

.footer-brand h3 {
  margin: 0 0 0.4rem;
  font-family: var(--font-display);
}

.footer-brand p,
.footer-col p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.92rem;
}

.footer-col h4 {
  margin: 0 0 0.7rem;
  font-size: 0.95rem;
}

.footer-col a {
  display: block;
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 0.4rem;
}

.copyright {
  border-top: 1px solid var(--line);
  padding-top: 1rem;
  color: var(--text-muted);
  font-size: 0.85rem;
  text-align: center;
}

/* Mobile */
@media (max-width: 960px) {
  .hero-grid,
  .split,
  .content-wrap,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .split.reverse .copy {
    order: 0;
  }

  .cat-grid,
  .feature-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .media-grid,
  .vlog-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .side-nav {
    position: static;
  }

  .menu-toggle {
    display: inline-flex;
  }

  .header-inner {
    position: relative;
    flex-wrap: nowrap;
  }

  .nav {
    display: none;
    position: absolute;
    top: calc(100% + 0.35rem);
    right: 0;
    left: auto;
    width: min(260px, calc(100vw - 2rem));
    flex-direction: column;
    align-items: stretch;
    gap: 0.15rem;
    padding: 0.55rem;
    margin: 0;
    background: rgba(22, 20, 28, 0.98);
    border: 1px solid var(--line);
    border-radius: 12px;
    box-shadow: var(--shadow);
    z-index: 120;
  }

  .nav.open {
    display: flex;
  }

  .nav a {
    padding: 0.55rem 0.75rem;
    border-radius: 8px;
  }

  .nav a:hover,
  .nav a.active {
    background: var(--bg-soft);
    -webkit-background-clip: unset;
    background-clip: unset;
    color: var(--text);
  }
}

@media (max-width: 560px) {
  .cat-grid,
  .media-grid,
  .feature-grid,
  .vlog-grid {
    grid-template-columns: 1fr;
  }

  .hero {
    padding-top: 2rem;
  }

  .hero-visual img {
    aspect-ratio: 3 / 4;
  }
}
