/* ═══════════════════════════════════════════════════════════════════════════
   ChiFlowTV — Master Stylesheet
   Chinese Ink & Gold Aesthetic · Dual Light/Dark Theme
   ═══════════════════════════════════════════════════════════════════════════ */

/* ── Google Fonts ──────────────────────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@400;500;600;700&family=IM+Fell+English:ital@0;1&family=Inter:wght@300;400;500;600&display=swap');

/* ═══════════════════════════════════════════════════════════════════════════
   CSS VARIABLES — LIGHT MODE (Default: 宣纸白)
   ═══════════════════════════════════════════════════════════════════════════ */
:root {
  --bg-primary:    #faf8f5;
  --bg-secondary:  #f2ede6;
  --bg-card:       #ffffff;
  --bg-card-hover: #f7f4ef;

  --red:           #c0392b;
  --red-dark:      #922b21;
  --gold:          #c9a84c;
  --gold-light:    #e0c070;
  --gold-dark:     #9e7e32;
  --teal:          #1a6b5a;
  --ink:           #1a1a2e;

  --text-primary:  #1a1a2e;
  --text-secondary:#4a4a6a;
  --text-muted:    #8a8aaa;

  --border:        rgba(192,57,43,0.15);
  --border-strong: rgba(192,57,43,0.35);
  --shadow:        0 4px 24px rgba(26,26,46,0.10);
  --shadow-lg:     0 8px 40px rgba(26,26,46,0.15);

  --radius:        4px;
  --radius-lg:     8px;
  --font-title:    'Cinzel', serif;
  --font-sub:      'IM Fell English', serif;
  --font-body:     'Inter', sans-serif;
  --transition:    0.25s cubic-bezier(0.4,0,0.2,1);

  /* Navbar */
  --nav-bg:        rgba(250,248,245,0.92);
  --nav-border:    rgba(192,57,43,0.12);

  /* Paper texture */
  --hero-bg:       #f2ede6;
}

/* ═══════════════════════════════════════════════════════════════════════════
   CSS VARIABLES — DARK MODE (夜间: 深墨)
   ═══════════════════════════════════════════════════════════════════════════ */
[data-theme="dark"] {
  --bg-primary:    #0d1117;
  --bg-secondary:  #161b22;
  --bg-card:       #1c2128;
  --bg-card-hover: #21262d;

  --red:           #e05c4b;
  --red-dark:      #b84233;
  --gold:          #d4a843;
  --gold-light:    #e8c070;
  --gold-dark:     #a07830;
  --teal:          #39d0b0;
  --ink:           #f0ede4;

  --text-primary:  #e6edf3;
  --text-secondary:#8b949e;
  --text-muted:    #6e7681;

  --border:        rgba(61,139,128,0.20);
  --border-strong: rgba(61,139,128,0.45);
  --shadow:        0 4px 24px rgba(0,0,0,0.40);
  --shadow-lg:     0 8px 40px rgba(0,0,0,0.60);

  --nav-bg:        rgba(13,17,23,0.92);
  --nav-border:    rgba(61,139,128,0.15);
  --hero-bg:       #0d1117;
}

/* ═══════════════════════════════════════════════════════════════════════════
   RESET & BASE
   ═══════════════════════════════════════════════════════════════════════════ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  background: var(--bg-primary);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-weight: 400;
  line-height: 1.7;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background var(--transition), color var(--transition);
}

a {
  color: var(--red);
  text-decoration: none;
  transition: color var(--transition);
}
a:hover { color: var(--red-dark); }

[data-theme="dark"] a { color: var(--teal); }
[data-theme="dark"] a:hover { color: var(--gold); }

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

h1,h2,h3,h4,h5 {
  font-family: var(--font-title);
  font-weight: 600;
  line-height: 1.25;
  color: var(--text-primary);
}

/* ── Ornament / horizontal divider ────────────────────────────────────────── */
.ornament {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 0 auto 3rem;
  max-width: 320px;
}
.ornament::before,
.ornament::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border-strong);
}
.ornament span {
  color: var(--gold);
  font-size: 1.1rem;
  flex-shrink: 0;
}

/* ── Section label (印章风格) ──────────────────────────────────────────────── */
.section-label {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--red);
  border: 1px solid var(--border-strong);
  padding: 0.25rem 0.8rem;
  border-radius: 100px;
  margin-bottom: 1rem;
}
[data-theme="dark"] .section-label {
  color: var(--teal);
  border-color: var(--border-strong);
}

/* ── Horizontal rule with gap ──────────────────────────────────────────────── */
.hr-gap {
  border: none;
  height: 1px;
  background: var(--border);
  margin: 2rem 0;
}

/* ═══════════════════════════════════════════════════════════════════════════
   NAVIGATION
   ═══════════════════════════════════════════════════════════════════════════ */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  height: 68px;
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--nav-bg);
  backdrop-filter: blur(20px) saturate(1.5);
  -webkit-backdrop-filter: blur(20px) saturate(1.5);
  border-bottom: 1px solid var(--nav-border);
  transition: background var(--transition), box-shadow var(--transition);
}

.navbar.scrolled {
  box-shadow: var(--shadow);
}

.nav-logo {
  font-family: var(--font-title);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--ink) !important;
  letter-spacing: 0.05em;
}
.nav-logo span { color: var(--red); }
[data-theme="dark"] .nav-logo { color: var(--text-primary) !important; }
[data-theme="dark"] .nav-logo span { color: var(--teal); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.nav-links a {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-secondary);
  padding: 0.4rem 0.75rem;
  border-radius: var(--radius);
  transition: color var(--transition), background var(--transition);
}
.nav-links a:hover,
.nav-links a.active {
  color: var(--text-primary);
  background: var(--bg-secondary);
}
[data-theme="dark"] .nav-links a { color: var(--text-secondary); }
[data-theme="dark"] .nav-links a:hover,
[data-theme="dark"] .nav-links a.active {
  color: var(--text-primary);
  background: var(--bg-secondary);
}

/* Theme toggle button */
.theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: 1px solid var(--border-strong);
  border-radius: 50%;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  font-size: 1rem;
  transition: background var(--transition), color var(--transition), border-color var(--transition);
  margin-left: 0.5rem;
  flex-shrink: 0;
}
.theme-toggle:hover {
  background: var(--bg-secondary);
  color: var(--text-primary);
}

/* Hamburger */
.nav-hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  cursor: pointer;
  gap: 5px;
  padding: 4px;
}
.nav-hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: transform 0.3s ease, opacity 0.3s ease;
  transform-origin: center;
}

/* Hamburger → X animation */
.nav-hamburger.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-hamburger.open span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}
.nav-hamburger.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Mobile overlay */
.nav-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 998;
  backdrop-filter: blur(4px);
}
.nav-overlay.visible { display: block; }

/* ═══════════════════════════════════════════════════════════════════════════
   BUTTONS
   ═══════════════════════════════════════════════════════════════════════════ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  min-height: 44px;
  padding: 0.6rem 1.4rem;
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  cursor: pointer;
  border: none;
  transition: background var(--transition), color var(--transition),
              border-color var(--transition), box-shadow var(--transition),
              transform var(--transition);
  text-decoration: none;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }

.btn-primary,
.btn-red {
  background: var(--red);
  color: #fff;
}
.btn-primary:hover,
.btn-red:hover {
  background: var(--red-dark);
  color: #fff;
  box-shadow: 0 4px 16px rgba(192,57,43,0.30);
}

.btn-gold {
  background: var(--gold);
  color: #1a1a2e;
}
.btn-gold:hover {
  background: var(--gold-dark);
  color: #1a1a2e;
  box-shadow: 0 4px 16px rgba(201,168,76,0.30);
}

.btn-outline {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border-strong);
}
.btn-outline:hover {
  background: var(--bg-secondary);
  color: var(--text-primary);
}

.btn-teal {
  background: var(--teal);
  color: #fff;
}
.btn-teal:hover {
  opacity: 0.88;
}

.btn-full { width: 100%; }

.btn-sm {
  min-height: 36px;
  padding: 0.4rem 1rem;
  font-size: 0.8rem;
}

.btn-lg {
  min-height: 52px;
  padding: 0.85rem 2rem;
  font-size: 1rem;
}

/* Loading state */
.btn.loading {
  pointer-events: none;
  opacity: 0.7;
}
.btn.loading::after {
  content: '';
  display: inline-block;
  width: 14px; height: 14px;
  border: 2px solid currentColor;
  border-top-color: transparent;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  margin-left: 6px;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ═══════════════════════════════════════════════════════════════════════════
   HERO SECTION
   ═══════════════════════════════════════════════════════════════════════════ */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 120px 2rem 80px;
  background: var(--hero-bg);
  overflow: hidden;
}

/* Subtle paper texture via repeating pattern */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    repeating-linear-gradient(
      0deg,
      transparent,
      transparent 39px,
      var(--border) 39px,
      var(--border) 40px
    ),
    repeating-linear-gradient(
      90deg,
      transparent,
      transparent 39px,
      var(--border) 39px,
      var(--border) 40px
    );
  opacity: 0.4;
  pointer-events: none;
}

[data-theme="dark"] .hero::before { opacity: 0.15; }

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 800px;
}

.hero-eyebrow {
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 1.5rem;
}
[data-theme="dark"] .hero-eyebrow { color: var(--teal); }

.hero h1 {
  font-size: clamp(2.4rem, 6vw, 4.5rem);
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 1.5rem;
  line-height: 1.15;
}
[data-theme="dark"] .hero h1 { color: var(--text-primary); }

.hero h1 em {
  font-style: normal;
  color: var(--red);
}
[data-theme="dark"] .hero h1 em { color: var(--teal); }

.hero-sub {
  font-family: var(--font-sub);
  font-size: 1.15rem;
  color: var(--text-secondary);
  margin-bottom: 2.5rem;
  max-width: 540px;
  margin-left: auto;
  margin-right: auto;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* ═══════════════════════════════════════════════════════════════════════════
   SECTIONS
   ═══════════════════════════════════════════════════════════════════════════ */
.section {
  padding: 6rem 2rem;
}

.section--alt {
  background: var(--bg-secondary);
}

.section-header {
  text-align: center;
  margin-bottom: 3.5rem;
}
.section-header h2 {
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  color: var(--text-primary);
  margin-bottom: 0.75rem;
}
.section-header p {
  color: var(--text-secondary);
  max-width: 520px;
  margin: 0 auto;
  font-size: 0.975rem;
}

/* ═══════════════════════════════════════════════════════════════════════════
   VIDEO CARDS
   ═══════════════════════════════════════════════════════════════════════════ */
.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
  max-width: 1200px;
  margin: 0 auto;
}

.video-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: box-shadow var(--transition), transform var(--transition),
              border-color var(--transition);
  cursor: pointer;
}
.video-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--border-strong);
}

.video-thumb {
  position: relative;
  aspect-ratio: 16/9;
  background: var(--bg-secondary);
  overflow: hidden;
}
.video-thumb img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.video-card:hover .video-thumb img { transform: scale(1.04); }

.video-tag {
  position: absolute;
  top: 10px; left: 10px;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  background: var(--red);
  color: #fff;
  padding: 0.2rem 0.6rem;
  border-radius: 100px;
}
[data-theme="dark"] .video-tag { background: var(--teal); color: #0d1117; }

.video-lock {
  position: absolute;
  top: 10px; right: 10px;
  background: rgba(0,0,0,0.55);
  color: #fff;
  width: 28px; height: 28px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.75rem;
}

.video-duration {
  position: absolute;
  bottom: 8px; right: 8px;
  background: rgba(0,0,0,0.65);
  color: #fff;
  font-size: 0.7rem;
  padding: 0.15rem 0.45rem;
  border-radius: var(--radius);
}

.video-info {
  padding: 1rem;
}
.video-title {
  font-family: var(--font-title);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.3rem;
  line-height: 1.3;
}
.video-meta {
  font-size: 0.78rem;
  color: var(--text-muted);
  display: flex;
  gap: 0.75rem;
}

/* ═══════════════════════════════════════════════════════════════════════════
   PRICING SECTION
   ═══════════════════════════════════════════════════════════════════════════ */
.pricing-page {
  padding-top: 68px; /* navbar height */
  min-height: 100vh;
}

.pricing-header {
  text-align: center;
  padding: 5rem 2rem 3.5rem;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
}
.pricing-header h1 {
  font-size: clamp(1.8rem, 4.5vw, 3rem);
  margin: 0.5rem 0 1rem;
}
.pricing-header > p {
  color: var(--text-secondary);
  font-size: 1rem;
  max-width: 540px;
  margin: 0 auto;
  line-height: 1.7;
}

/* Pricing grid container */
.pricing-grid-wrap {
  padding: 4rem 2rem 5rem;
  max-width: 1100px;
  margin: 0 auto;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  align-items: start;
}

/* Individual pricing card */
.pricing-card {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem 1.75rem 2.25rem;
  display: flex;
  flex-direction: column;
  gap: 0;
  transition: box-shadow var(--transition), border-color var(--transition);
}

.pricing-card:hover {
  box-shadow: var(--shadow-lg);
}

/* Featured (yearly) card */
.pricing-card--featured {
  border: 2px solid var(--red);
  box-shadow: 0 0 0 4px rgba(192,57,43,0.07), var(--shadow);
}
[data-theme="dark"] .pricing-card--featured {
  border-color: var(--red);
  box-shadow: 0 0 0 4px rgba(224,92,75,0.10), var(--shadow);
}
.pricing-card--featured:hover {
  box-shadow: 0 0 0 4px rgba(192,57,43,0.12), var(--shadow-lg);
}

/* "MOST POPULAR" badge */
.plan-badge {
  position: absolute;
  top: -1px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--red);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  padding: 0.3rem 1rem;
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
  white-space: nowrap;
}

/* Plan name */
.plan-name {
  font-family: var(--font-title);
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-top: 1rem;
  margin-bottom: 0.5rem;
}
.pricing-card--featured .plan-name { margin-top: 1.6rem; }

/* Price block */
.plan-price {
  display: flex;
  align-items: baseline;
  gap: 0.3rem;
  margin-bottom: 0.4rem;
}
.plan-amount {
  font-family: var(--font-title);
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--ink);
  line-height: 1;
}
[data-theme="dark"] .plan-amount { color: var(--text-primary); }

.plan-period {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.plan-saving {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--teal);
  margin-bottom: 0.5rem;
}

/* Divider */
.plan-divider {
  width: 100%;
  height: 1px;
  background: var(--border);
  margin: 1.25rem 0;
}

/* Features list */
.plan-features {
  list-style: none;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  margin-bottom: 1.75rem;
}
.plan-features li {
  font-size: 0.875rem;
  color: var(--text-secondary);
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
}
.plan-features li::before {
  content: '✓';
  color: var(--red);
  font-weight: 700;
  flex-shrink: 0;
  line-height: 1.6;
}
[data-theme="dark"] .plan-features li::before { color: var(--teal); }

/* Trust signals row */
.trust-row {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1.5rem 2.5rem;
  padding: 2rem 2rem 3rem;
  border-top: 1px solid var(--border);
  max-width: 900px;
  margin: 0 auto;
}
.trust-item {
  font-size: 0.85rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

/* ═══════════════════════════════════════════════════════════════════════════
   FAQ SECTION
   ═══════════════════════════════════════════════════════════════════════════ */
.faq-section {
  max-width: 780px;
  margin: 0 auto;
  padding: 4rem 2rem 5rem;
}

.faq-section h2 {
  font-size: 1.6rem;
  margin-bottom: 2rem;
  text-align: center;
}

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.faq-item {
  border-bottom: 1px solid var(--border);
}
.faq-item:last-child { border-bottom: none; }

.faq-question {
  width: 100%;
  background: var(--bg-card);
  border: none;
  padding: 1.1rem 1.4rem;
  text-align: left;
  font-family: var(--font-body);
  font-size: 0.93rem;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: background var(--transition);
}
.faq-question:hover { background: var(--bg-card-hover); }

.faq-icon {
  font-size: 1.2rem;
  color: var(--text-muted);
  transition: transform 0.25s ease;
  flex-shrink: 0;
}
.faq-item.open .faq-icon { transform: rotate(45deg); color: var(--red); }
[data-theme="dark"] .faq-item.open .faq-icon { color: var(--teal); }

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
  background: var(--bg-card);
}
.faq-item.open .faq-answer { max-height: 200px; }
.faq-answer p {
  padding: 0 1.4rem 1.1rem;
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ═══════════════════════════════════════════════════════════════════════════
   FORMS — Auth Pages
   ═══════════════════════════════════════════════════════════════════════════ */
.auth-page {
  min-height: 100vh;
  padding: 100px 1.5rem 4rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-secondary);
}

.auth-card {
  width: 100%;
  max-width: 440px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2.5rem 2.25rem;
  box-shadow: var(--shadow-lg);
}

.auth-symbol {
  font-size: 2.2rem;
  text-align: center;
  margin-bottom: 1rem;
  color: var(--red);
  line-height: 1;
}
[data-theme="dark"] .auth-symbol { color: var(--teal); }

.auth-card h1 {
  font-size: 1.6rem;
  text-align: center;
  margin-bottom: 0.4rem;
}

.auth-sub {
  font-family: var(--font-sub);
  font-style: italic;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 1.75rem;
}

/* Form fields */
.form-group {
  margin-bottom: 1.1rem;
}
.form-group label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 0.4rem;
  letter-spacing: 0.04em;
}
.form-group label small {
  font-weight: 400;
  font-style: italic;
  color: var(--text-muted);
}
.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="password"] {
  width: 100%;
  height: 48px;
  padding: 0 1rem;
  background: var(--bg-primary);
  color: var(--text-primary);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: 0.9rem;
  transition: border-color var(--transition), box-shadow var(--transition);
  outline: none;
}
.form-group input:focus {
  border-color: var(--red);
  box-shadow: 0 0 0 3px rgba(192,57,43,0.12);
}
[data-theme="dark"] .form-group input:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(57,208,176,0.12);
}
.form-group input::placeholder { color: var(--text-muted); }

/* Checkbox */
.form-check {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 1.1rem;
  font-size: 0.85rem;
  color: var(--text-secondary);
  cursor: pointer;
}
.form-check input[type="checkbox"] {
  width: 18px; height: 18px;
  accent-color: var(--red);
  flex-shrink: 0;
  cursor: pointer;
}
[data-theme="dark"] .form-check input[type="checkbox"] {
  accent-color: var(--teal);
}

/* Password strength */
.password-strength {
  margin-top: 0.4rem;
  height: 3px;
  border-radius: 2px;
  background: var(--border);
  overflow: hidden;
  position: relative;
}
.password-strength-bar {
  height: 100%;
  border-radius: 2px;
  width: 0;
  transition: width 0.3s ease, background 0.3s ease;
}
.strength-weak   { background: #e74c3c; }
.strength-fair   { background: #f39c12; }
.strength-strong { background: #27ae60; }

.password-strength-text {
  font-size: 0.72rem;
  margin-top: 0.25rem;
  color: var(--text-muted);
}

/* Form footer links */
.auth-links {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.1rem;
  font-size: 0.8rem;
}
.auth-links a { color: var(--text-muted); }
.auth-links a:hover { color: var(--text-primary); }

.auth-switch {
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
}

.form-legal {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-align: center;
  margin-top: 1rem;
  line-height: 1.6;
}
.form-legal a { color: var(--text-secondary); text-decoration: underline; }

/* Alerts */
.alert {
  padding: 0.85rem 1rem;
  border-radius: var(--radius);
  font-size: 0.875rem;
  margin-bottom: 1.1rem;
  border-left: 4px solid transparent;
}
.alert-error {
  background: rgba(192,57,43,0.08);
  color: var(--red);
  border-left-color: var(--red);
}
[data-theme="dark"] .alert-error {
  background: rgba(224,92,75,0.10);
  color: #ff8a75;
  border-left-color: var(--red);
}
.alert-success {
  background: rgba(26,107,90,0.10);
  color: var(--teal);
  border-left-color: var(--teal);
}

/* Rate limit warning */
.alert-warning {
  background: rgba(201,168,76,0.12);
  color: var(--gold-dark);
  border-left-color: var(--gold);
}
[data-theme="dark"] .alert-warning {
  color: var(--gold);
}

/* ═══════════════════════════════════════════════════════════════════════════
   PAYWALL / VIDEO PLAYER
   ═══════════════════════════════════════════════════════════════════════════ */
.player-wrap {
  position: relative;
  aspect-ratio: 16/9;
  width: 100%;
  background: #000;
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.player-wrap iframe,
.player-wrap video {
  width: 100%; height: 100%;
  border: none;
}

/* Progress bar */
.player-progress {
  position: absolute;
  bottom: 0; left: 0;
  width: 0;
  height: 3px;
  background: var(--red);
  transition: width 0.5s linear;
  z-index: 5;
}

/* Paywall overlay */
.paywall-overlay {
  position: absolute;
  inset: 0;
  background: rgba(250,248,245,0.55);
  backdrop-filter: blur(10px) saturate(1.2);
  -webkit-backdrop-filter: blur(10px) saturate(1.2);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2rem;
  z-index: 10;
}
[data-theme="dark"] .paywall-overlay {
  background: rgba(13,17,23,0.72);
}
.paywall-overlay h3 {
  font-family: var(--font-title);
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
}
.paywall-overlay p {
  font-size: 0.875rem;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

/* ═══════════════════════════════════════════════════════════════════════════
   FEATURE CARDS (Home)
   ═══════════════════════════════════════════════════════════════════════════ */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
  max-width: 1100px;
  margin: 0 auto;
}
.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem 1.5rem;
  text-align: center;
  transition: box-shadow var(--transition), transform var(--transition);
}
.feature-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-3px);
}
.feature-icon {
  font-size: 2rem;
  margin-bottom: 1rem;
  display: block;
}
.feature-card h3 {
  font-size: 1rem;
  margin-bottom: 0.5rem;
}
.feature-card p {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

/* ═══════════════════════════════════════════════════════════════════════════
   BROWSE PAGE
   ═══════════════════════════════════════════════════════════════════════════ */
.browse-page {
  padding-top: 68px;
  min-height: 100vh;
}

.browse-header {
  background: var(--bg-secondary);
  padding: 3rem 2rem 2rem;
  border-bottom: 1px solid var(--border);
}
.browse-header h1 {
  font-size: clamp(1.5rem, 3.5vw, 2.2rem);
  margin-bottom: 0.4rem;
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.25rem;
}
.filter-btn {
  height: 36px;
  padding: 0 1rem;
  border: 1px solid var(--border-strong);
  border-radius: 100px;
  background: transparent;
  color: var(--text-secondary);
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  transition: background var(--transition), color var(--transition),
              border-color var(--transition);
}
.filter-btn:hover,
.filter-btn.active {
  background: var(--red);
  color: #fff;
  border-color: var(--red);
}
[data-theme="dark"] .filter-btn:hover,
[data-theme="dark"] .filter-btn.active {
  background: var(--teal);
  color: #0d1117;
  border-color: var(--teal);
}

.browse-content {
  padding: 3rem 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

/* ═══════════════════════════════════════════════════════════════════════════
   ACCOUNT PAGE
   ═══════════════════════════════════════════════════════════════════════════ */
.account-page {
  padding: calc(68px + 3rem) 2rem 4rem;
  max-width: 800px;
  margin: 0 auto;
  min-height: 100vh;
}
.account-page h1 {
  font-size: 1.8rem;
  margin-bottom: 2rem;
}

.membership-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  margin-bottom: 1.5rem;
}
.membership-card h2 {
  font-size: 1.1rem;
  margin-bottom: 1rem;
  color: var(--text-primary);
}
.membership-badge {
  display: inline-block;
  background: var(--red);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  padding: 0.2rem 0.7rem;
  border-radius: 100px;
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}
[data-theme="dark"] .membership-badge { background: var(--teal); color: #0d1117; }

/* ═══════════════════════════════════════════════════════════════════════════
   FOOTER
   ═══════════════════════════════════════════════════════════════════════════ */
.footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  padding: 3rem 2rem;
}
.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
  text-align: center;
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.5rem;
  justify-content: center;
}
.footer-links a {
  font-size: 0.85rem;
  color: var(--text-muted);
}
.footer-links a:hover { color: var(--text-primary); }
.footer-copy {
  font-size: 0.78rem;
  color: var(--text-muted);
}

.footer-simple {
  text-align: center;
  padding: 2rem;
  font-size: 0.8rem;
  color: var(--text-muted);
  border-top: 1px solid var(--border);
  background: var(--bg-secondary);
}

/* ═══════════════════════════════════════════════════════════════════════════
   WELCOME BANNER
   ═══════════════════════════════════════════════════════════════════════════ */
.welcome-banner {
  background: rgba(26,107,90,0.1);
  border-bottom: 1px solid rgba(26,107,90,0.25);
  padding: 0.85rem 2rem;
  text-align: center;
  font-size: 0.9rem;
  color: var(--teal);
}

/* ═══════════════════════════════════════════════════════════════════════════
   WATCH PAGE
   ═══════════════════════════════════════════════════════════════════════════ */
.watch-page {
  padding-top: 68px;
  min-height: 100vh;
}
.watch-layout {
  max-width: 1000px;
  margin: 0 auto;
  padding: 2rem;
}
.watch-meta {
  margin: 1.5rem 0 1rem;
}
.watch-meta h1 {
  font-size: clamp(1.2rem, 3vw, 1.8rem);
  margin-bottom: 0.5rem;
}
.watch-meta p {
  font-size: 0.875rem;
  color: var(--text-secondary);
}

/* ═══════════════════════════════════════════════════════════════════════════
   ADMIN
   ═══════════════════════════════════════════════════════════════════════════ */
.admin-layout {
  padding: calc(68px + 2rem) 2rem 3rem;
  max-width: 1100px;
  margin: 0 auto;
}
.admin-layout h1 {
  font-size: 1.6rem;
  margin-bottom: 1.5rem;
}
.admin-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  font-size: 0.875rem;
}
.admin-table th {
  background: var(--bg-secondary);
  padding: 0.75rem 1rem;
  text-align: left;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-bottom: 1px solid var(--border);
}
.admin-table td {
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--border);
  color: var(--text-secondary);
}
.admin-table tr:last-child td { border-bottom: none; }
.admin-table tr:hover td { background: var(--bg-secondary); }

/* ═══════════════════════════════════════════════════════════════════════════
   CHECKOUT PAGE
   ═══════════════════════════════════════════════════════════════════════════ */
.checkout-page {
  padding: calc(68px + 3rem) 2rem 5rem;
  max-width: 600px;
  margin: 0 auto;
  min-height: 100vh;
}
.payment-tab-bar {
  display: flex;
  gap: 0;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 1.5rem;
}
.payment-tab {
  flex: 1;
  height: 44px;
  background: transparent;
  border: none;
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  transition: background var(--transition), color var(--transition);
}
.payment-tab.active {
  background: var(--red);
  color: #fff;
}
.payment-panel { display: none; }
.payment-panel.active { display: block; }

/* ═══════════════════════════════════════════════════════════════════════════
   MOBILE BREAKPOINTS
   ═══════════════════════════════════════════════════════════════════════════ */

/* ── 1024px ─────────────────────────────────────────────────────────────── */
@media (max-width: 1024px) {
  .pricing-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
  }
  .plan-amount { font-size: 2.1rem; }
}

/* ── 768px ──────────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .navbar { padding: 0 1.25rem; }

  /* Show hamburger, hide links by default */
  .nav-hamburger { display: flex; }

  .nav-links {
    position: fixed;
    top: 0; right: 0;
    width: min(320px, 85vw);
    height: 100vh;
    background: var(--bg-card);
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    gap: 0;
    padding: 5rem 1.75rem 2rem;
    box-shadow: var(--shadow-lg);
    transform: translateX(100%);
    transition: transform 0.3s cubic-bezier(0.4,0,0.2,1);
    z-index: 999;
    overflow-y: auto;
  }
  .nav-links.open { transform: translateX(0); }

  .nav-links a {
    font-size: 1rem;
    padding: 0.85rem 0;
    width: 100%;
    border-bottom: 1px solid var(--border);
    border-radius: 0;
  }
  .nav-links a:last-child { border-bottom: none; }

  .nav-links .btn {
    margin-top: 1rem;
    width: 100%;
    justify-content: center;
  }

  .nav-links .theme-toggle {
    margin-top: 1rem;
    width: 100%;
    border-radius: var(--radius);
  }

  .admin-navbar {
    gap: 0.75rem;
    overflow-x: auto;
  }

  .admin-navbar .nav-links {
    position: static;
    width: auto;
    height: auto;
    flex: 1 1 auto;
    flex-direction: row;
    align-items: center;
    gap: 0.25rem;
    padding: 0;
    box-shadow: none;
    transform: none;
    overflow-x: auto;
    background: transparent;
  }

  .admin-navbar .nav-links a {
    width: auto;
    border-bottom: 0;
    white-space: nowrap;
    padding: 0.45rem 0.7rem;
    font-size: 0.85rem;
  }

  /* Pricing grid → 1 column on mobile */
  .pricing-grid {
    grid-template-columns: 1fr;
    max-width: 420px;
    margin: 0 auto;
  }
  .pricing-grid-wrap { padding: 2.5rem 1.25rem 3.5rem; }
  .pricing-header { padding: 4rem 1.25rem 2.5rem; }
  .plan-badge { font-size: 0.6rem; }

  /* Video grid */
  .video-grid { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }

  /* Features */
  .features-grid { grid-template-columns: 1fr 1fr; }

  /* Auth */
  .auth-card { padding: 2rem 1.5rem; }
  .auth-page { padding: 88px 1rem 3rem; }

  /* Hero */
  .hero { padding: 100px 1.25rem 60px; }
  .hero-actions { flex-direction: column; align-items: center; }
  .hero-actions .btn { width: 100%; max-width: 280px; }

  /* FAQ */
  .faq-section { padding: 3rem 1.25rem 4rem; }

  /* Trust row */
  .trust-row { gap: 1rem 1.5rem; }

  /* Watch */
  .watch-layout { padding: 1.5rem 1rem; }

  /* Admin */
  .admin-layout { padding: calc(68px + 1.5rem) 1rem 3rem; }
  .admin-table { font-size: 0.8rem; }
  .admin-table th, .admin-table td { padding: 0.65rem 0.75rem; }

  /* Checkout */
  .checkout-page { padding: calc(68px + 2rem) 1rem 4rem; }
}

/* ── 480px ──────────────────────────────────────────────────────────────── */
@media (max-width: 480px) {
  .section { padding: 4rem 1rem; }
  .features-grid { grid-template-columns: 1fr; }
  .pricing-card { padding: 1.75rem 1.25rem 2rem; }
  .plan-amount { font-size: 2rem; }
  .filter-bar { gap: 0.4rem; }
  .filter-btn { height: 34px; font-size: 0.75rem; padding: 0 0.75rem; }

  .browse-header { padding: 2.5rem 1rem 1.5rem; }
  .browse-content { padding: 2rem 1rem; }
}

/* ── Prevent horizontal scroll on 375px ────────────────────────────────── */
@media (max-width: 375px) {
  body { overflow-x: hidden; }
  .navbar { padding: 0 1rem; }
  .hero { padding: 90px 1rem 50px; }
  .auth-card { padding: 1.75rem 1.1rem; }
  .pricing-grid-wrap { padding: 2rem 1rem 3rem; }
}

/* ═══════════════════════════════════════════════════════════════════════════
   REFINED WELLNESS THEME OVERRIDES
   宣纸 · 松烟墨 · 朱砂 · 温润金
   ═══════════════════════════════════════════════════════════════════════════ */
body {
  background:
    radial-gradient(circle at 16% 10%, rgba(201,168,76,0.13), transparent 28rem),
    linear-gradient(180deg, rgba(255,255,255,0.6), rgba(242,237,230,0.28)),
    var(--bg-primary);
}

[data-theme="dark"] body {
  background:
    radial-gradient(circle at 16% 8%, rgba(57,208,176,0.10), transparent 26rem),
    linear-gradient(180deg, rgba(22,27,34,0.45), rgba(13,17,23,0.2)),
    var(--bg-primary);
}

.container {
  max-width: 1180px;
  margin: 0 auto;
}

.text-center { text-align: center; }
.mt-4 { margin-top: 2rem; }

.section-kicker,
.hero-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  color: var(--red);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

[data-theme="dark"] .section-kicker,
[data-theme="dark"] .hero-badge {
  color: var(--teal);
}

.section-dark {
  background:
    linear-gradient(135deg, rgba(16,37,31,0.95), rgba(26,26,46,0.96)),
    var(--ink);
  color: #f8f2e7;
}

.section-dark h2,
.section-dark h3,
.section-dark .video-title {
  color: #fff7e8;
}

.section-dark p,
.section-dark .video-desc,
.section-dark .video-category {
  color: rgba(248,242,231,0.72);
}

.hero {
  background:
    linear-gradient(135deg, rgba(250,248,245,0.92), rgba(236,228,208,0.78)),
    var(--hero-bg);
}

.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(115deg, transparent 0 62%, rgba(26,107,90,0.08) 62% 100%),
    radial-gradient(circle at 82% 20%, rgba(192,57,43,0.10), transparent 18rem);
  pointer-events: none;
}

[data-theme="dark"] .hero {
  background:
    linear-gradient(135deg, rgba(13,17,23,0.96), rgba(16,37,31,0.88)),
    var(--hero-bg);
}

.taichi-wrap,
.taichi-wrap-left {
  position: absolute;
  color: var(--gold);
  pointer-events: none;
  opacity: 0.72;
}

.taichi-wrap {
  width: min(34vw, 360px);
  right: 5vw;
  bottom: 8vh;
}

.taichi-wrap-left {
  width: min(24vw, 260px);
  left: 4vw;
  top: 18vh;
  opacity: 0.42;
}

.hero-scroll {
  position: absolute;
  bottom: 1.2rem;
  color: var(--text-muted);
  font-size: 0.68rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.page-header {
  padding: calc(68px + 4rem) 2rem 3rem;
  text-align: center;
  background:
    radial-gradient(circle at 50% 0%, rgba(201,168,76,0.18), transparent 22rem),
    var(--bg-secondary);
  border-bottom: 1px solid var(--border);
}

.page-header h1 {
  font-size: clamp(2rem, 5vw, 3.2rem);
  margin-bottom: 0.75rem;
}

.page-header p {
  color: var(--text-secondary);
  max-width: 560px;
  margin: 0 auto;
}

.browse-search {
  max-width: 620px;
  margin: 1.6rem auto 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.65rem;
}

.browse-search input[type="search"] {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  background: var(--bg-card);
  color: var(--text-primary);
  padding: 0 1rem;
  font-family: var(--font-body);
  font-size: 0.9rem;
  outline: none;
}

.browse-search input[type="search"]:focus {
  border-color: var(--red);
  box-shadow: 0 0 0 3px rgba(192,57,43,0.12);
}

.filter-bar {
  justify-content: center;
  padding: 1.25rem 1rem 0;
}

.video-card {
  display: block;
  color: inherit;
  box-shadow: 0 1px 0 rgba(255,255,255,0.45) inset;
}

.video-thumb {
  background:
    linear-gradient(135deg, rgba(26,107,90,0.15), rgba(201,168,76,0.18)),
    var(--bg-secondary);
}

.video-thumb-placeholder {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold);
  font-size: 3rem;
}

.video-play-btn {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity var(--transition), transform var(--transition);
}

.video-play-btn svg {
  width: 54px;
  height: 54px;
  fill: #fff;
  padding: 15px;
  border-radius: 50%;
  background: rgba(16,37,31,0.72);
  box-shadow: var(--shadow);
}

.video-card:hover .video-play-btn {
  opacity: 1;
  transform: scale(1.02);
}

.video-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 0.22rem 0.65rem;
  border-radius: 100px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.badge-preview {
  background: rgba(192,57,43,0.92);
  color: #fff;
}

.badge-member {
  background: rgba(26,107,90,0.92);
  color: #fff;
}

.video-category,
.video-meta-category,
.related-cat {
  color: var(--red);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 0.35rem;
}

[data-theme="dark"] .video-category,
[data-theme="dark"] .video-meta-category,
[data-theme="dark"] .related-cat {
  color: var(--teal);
}

.video-desc {
  color: var(--text-secondary);
  font-size: 0.85rem;
  line-height: 1.6;
}

.preview-bar {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 4px;
  background: rgba(255,255,255,0.24);
  z-index: 6;
}

.preview-bar-fill {
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--gold), var(--red));
}

.paywall-overlay {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.paywall-overlay.visible {
  opacity: 1;
  pointer-events: auto;
}

.paywall-content {
  position: relative;
  max-width: 620px;
  background: rgba(250,248,245,0.92);
  border: 1px solid rgba(201,168,76,0.38);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  box-shadow: var(--shadow-lg);
}

[data-theme="dark"] .paywall-content {
  background: rgba(22,27,34,0.92);
}

.paywall-icon {
  color: var(--gold);
  font-size: 2.1rem;
  line-height: 1;
  margin-bottom: 0.5rem;
}

.paywall-plans {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  margin: 1rem 0 1.25rem;
}

.paywall-plan {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.75rem;
  color: var(--text-primary);
  background: var(--bg-card);
}

.paywall-plan.selected,
.paywall-plan:hover {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(201,168,76,0.14);
}

.pp-name {
  font-size: 0.78rem;
  font-weight: 700;
}

.pp-price {
  color: var(--red);
  font-family: var(--font-title);
  font-size: 1.25rem;
  font-weight: 700;
}

.pp-period,
.paywall-login {
  color: var(--text-muted);
  font-size: 0.76rem;
}

.watch-layout {
  max-width: 1240px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 2rem;
}

.video-meta {
  display: block;
  margin-top: 1.25rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
}

.video-meta h1 {
  font-size: clamp(1.4rem, 3vw, 2.1rem);
  margin-bottom: 0.7rem;
}

.watch-sidebar {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1rem;
  align-self: start;
  position: sticky;
  top: 88px;
}

.watch-sidebar h3 {
  font-size: 1rem;
  margin-bottom: 1rem;
}

.related-card {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  gap: 0.75rem;
  padding: 0.75rem 0;
  border-top: 1px solid var(--border);
  color: inherit;
}

.related-card:first-of-type {
  border-top: none;
  padding-top: 0;
}

.related-thumb {
  width: 96px;
  aspect-ratio: 16/10;
  object-fit: cover;
  border-radius: var(--radius);
}

.related-title {
  color: var(--text-primary);
  font-size: 0.86rem;
  font-weight: 700;
  line-height: 1.35;
}

.footer-grid {
  max-width: 1100px;
  margin: 0 auto 2rem;
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 2rem;
}

.brand-name {
  font-family: var(--font-title);
  color: var(--gold);
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.footer-brand p,
.footer-col li {
  color: var(--text-secondary);
  font-size: 0.86rem;
}

.footer-col h4 {
  color: var(--text-primary);
  font-size: 0.85rem;
  margin-bottom: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.footer-col ul {
  list-style: none;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  color: var(--text-muted);
  font-size: 0.82rem;
}

.not-found-page {
  min-height: 100vh;
  padding: calc(68px + 5rem) 1.5rem 4rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.not-found-mark {
  color: var(--gold);
  font-family: var(--font-title);
  font-size: clamp(4rem, 16vw, 8rem);
  line-height: 1;
  opacity: 0.8;
}

.not-found-page h1 {
  margin: 0.8rem 0;
  font-size: clamp(1.8rem, 5vw, 3rem);
}

.not-found-page p {
  color: var(--text-secondary);
  max-width: 520px;
}

.not-found-actions {
  display: flex;
  gap: 0.8rem;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 1.6rem;
}

.account-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.account-avatar {
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--gold);
  background: radial-gradient(circle, rgba(201,168,76,0.16), rgba(26,107,90,0.10));
  border: 1px solid var(--border-strong);
  font-size: 1.8rem;
  flex: 0 0 auto;
}

.account-header h1 {
  margin: 0;
}

.account-header p {
  color: var(--text-muted);
}

.account-section,
.admin-form-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow);
}

.account-section h2 {
  font-size: 1rem;
  margin-bottom: 1rem;
}

.membership-badge.active,
.membership-badge.inactive {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  width: 100%;
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1rem;
  text-transform: none;
  letter-spacing: 0;
}

.membership-badge.active {
  border-color: rgba(26,107,90,0.35);
  background: rgba(26,107,90,0.08);
}

.membership-badge.inactive {
  background: rgba(201,168,76,0.08);
}

.badge-icon {
  color: var(--gold);
  font-size: 1.2rem;
}

.admin-page {
  padding: calc(68px + 2.5rem) 2rem 4rem;
  max-width: 1240px;
  margin: 0 auto;
}

.admin-page h1 {
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  margin-bottom: 1.5rem;
}

.admin-navbar {
  background: rgba(255,250,240,0.94);
}

.admin-hero {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--border);
}

.admin-hero h1 {
  margin: 0.2rem 0 0.35rem;
}

.admin-hero p {
  max-width: 720px;
  color: var(--text-secondary);
  line-height: 1.7;
}

.admin-eyebrow {
  color: var(--gold-dark);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.admin-hero-actions,
.admin-form-actions,
.admin-row-actions,
.admin-inline-action {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  flex-wrap: wrap;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.2rem;
  box-shadow: var(--shadow);
}

.stat-value {
  display: block;
  color: var(--gold);
  font-family: var(--font-title);
  font-size: 1.8rem;
  font-weight: 700;
}

.stat-label {
  color: var(--text-muted);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.admin-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin: 1.4rem 0;
}

.admin-two-col {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(360px, 0.85fr);
  gap: 1.4rem;
  align-items: start;
  margin-top: 1.6rem;
}

.admin-panel {
  margin-top: 1.6rem;
}

.admin-panel-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.8rem;
}

.admin-panel-head h2 {
  margin: 0 0 0.25rem;
  font-size: 1.1rem;
}

.admin-panel-head p {
  color: var(--text-muted);
  font-size: 0.84rem;
  line-height: 1.6;
}

.admin-metric-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
  margin: 1.3rem 0 1.6rem;
}

.admin-metric-card {
  display: block;
  min-height: 96px;
  padding: 1.1rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  color: var(--text-primary);
}

.admin-metric-card.active {
  border-color: rgba(201,168,76,0.65);
  background: linear-gradient(135deg, rgba(201,168,76,0.14), var(--bg-card));
}

.admin-metric-card span {
  display: block;
  color: var(--gold);
  font-family: var(--font-title);
  font-size: 1.55rem;
  font-weight: 700;
}

.admin-metric-card small {
  display: block;
  margin-top: 0.25rem;
  color: var(--text-muted);
  font-size: 0.78rem;
  line-height: 1.5;
}

.admin-search {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.admin-search input,
.admin-user-actions select {
  min-height: 38px;
  padding: 0 0.8rem;
  color: var(--text-primary);
  background: var(--bg-primary);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  font-family: var(--font-body);
}

.admin-editor-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 1.4rem;
  align-items: start;
}

.admin-side-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.3rem;
  box-shadow: var(--shadow);
}

.admin-side-card h2 {
  margin-bottom: 0.8rem;
  color: var(--gold-dark);
  font-size: 1rem;
}

.admin-side-card p {
  margin: 0.75rem 0;
  color: var(--text-secondary);
  font-size: 0.86rem;
  line-height: 1.7;
}

.admin-inline-action {
  flex-wrap: nowrap;
}

.admin-inline-action input {
  flex: 1 1 auto;
  min-width: 0;
}

.admin-thumb-preview {
  margin-top: 0.75rem;
}

.admin-thumb-preview img {
  display: block;
  width: min(260px, 100%);
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.admin-details {
  border-top: 1px solid var(--border);
  margin: 1.1rem 0;
  padding-top: 1rem;
}

.admin-details summary {
  cursor: pointer;
  color: var(--gold-dark);
  font-weight: 700;
}

.admin-check {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin: 1rem 0 1.2rem;
  color: var(--text-secondary);
  font-weight: 600;
}

.admin-video-cell {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 0.8rem;
  align-items: center;
  min-width: 260px;
}

.admin-video-cell strong,
.admin-video-cell small {
  display: block;
}

.admin-video-cell small,
.admin-muted {
  color: var(--text-muted);
  font-size: 0.76rem;
  word-break: break-all;
}

.admin-thumb {
  width: 76px;
  aspect-ratio: 16 / 9;
  display: grid;
  place-items: center;
  overflow: hidden;
  color: var(--gold);
  background: linear-gradient(135deg, rgba(201,168,76,0.16), rgba(26,107,90,0.10));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: var(--font-title);
}

.admin-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.link-button {
  background: none;
  border: 0;
  padding: 0;
  color: var(--gold-dark);
  font: inherit;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.link-button.danger,
.status-badge.failed {
  color: var(--red);
}

.admin-empty {
  display: grid;
  place-items: center;
  gap: 0.3rem;
  min-height: 120px;
  color: var(--text-muted);
  text-align: center;
}

.admin-empty strong {
  color: var(--text-primary);
}

.admin-pagination {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-top: 1.5rem;
}

.admin-pagination a,
.admin-pagination span {
  min-width: 38px;
  padding: 0.45rem 0.75rem;
  text-align: center;
  color: var(--text-primary);
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.admin-pagination .active {
  color: #1a1a2e;
  background: var(--gold);
  border-color: var(--gold);
  font-weight: 800;
}

.orders-table {
  width: 100%;
  border-collapse: collapse;
  overflow: hidden;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  font-size: 0.86rem;
}

.orders-table th,
.orders-table td {
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--border);
  text-align: left;
}

.orders-table th {
  color: var(--text-muted);
  background: var(--bg-secondary);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.orders-table tr:last-child td {
  border-bottom: none;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  border-radius: 100px;
  padding: 0.2rem 0.6rem;
  font-size: 0.72rem;
  font-weight: 700;
  background: rgba(201,168,76,0.12);
  color: var(--gold-dark);
}

.status-badge.completed {
  background: rgba(26,107,90,0.12);
  color: var(--teal);
}

.status-badge.pending {
  background: rgba(201,168,76,0.14);
  color: var(--gold-dark);
}

.status-badge.failed {
  background: rgba(192,57,43,0.12);
  color: var(--red);
}

.status-badge.admin {
  background: rgba(201,168,76,0.16);
  color: var(--gold-dark);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.form-group select,
.form-group textarea,
.form-group input[type="url"],
.form-group input[type="number"] {
  width: 100%;
  padding: 0.75rem 1rem;
  background: var(--bg-primary);
  color: var(--text-primary);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: 0.9rem;
  outline: none;
}

.form-group textarea {
  min-height: 120px;
  resize: vertical;
}

.form-group select:focus,
.form-group textarea:focus,
.form-group input[type="url"]:focus,
.form-group input[type="number"]:focus {
  border-color: var(--red);
  box-shadow: 0 0 0 3px rgba(192,57,43,0.12);
}

.form-hint {
  display: block;
  color: var(--text-muted);
  font-size: 0.76rem;
  margin-top: 0.35rem;
}

.form-checkbox label {
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

@media (max-width: 900px) {
  .watch-layout {
    grid-template-columns: 1fr;
  }

  .watch-sidebar {
    position: static;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .stats-grid {
    grid-template-columns: 1fr 1fr;
  }

  .admin-hero,
  .admin-panel-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .admin-two-col,
  .admin-editor-grid {
    grid-template-columns: 1fr;
  }

  .admin-metric-row {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 620px) {
  .taichi-wrap,
  .taichi-wrap-left,
  .hero-scroll {
    display: none;
  }

  .paywall-plans {
    grid-template-columns: 1fr;
  }

  .footer-grid,
  .footer-bottom {
    grid-template-columns: 1fr;
    display: block;
    text-align: center;
  }

  .footer-col {
    margin-top: 1.4rem;
  }

  .browse-search {
    grid-template-columns: 1fr;
  }

  .form-row,
  .stats-grid,
  .admin-metric-row {
    grid-template-columns: 1fr;
  }

  .admin-page {
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .admin-inline-action {
    align-items: stretch;
    flex-direction: column;
  }

  .admin-search {
    width: 100%;
  }

  .admin-search input {
    width: 100%;
  }

  .orders-table {
    display: block;
    overflow-x: auto;
    white-space: nowrap;
  }
}
