/* R06 style.css · 6主题 + 5组动画 ★R66 */
:root {
  --bg-primary: #0D1117; --bg-card: #161B22; --bg-elevated: #1C2128;
  --accent: #FF6B35; --accent-alt: #FFB347; --accent-glow: rgba(255,107,53,0.3);
  --text-primary: #E6EDF3; --text-secondary: #8B949E; --text-tertiary: #6E7681;
  --border: #30363D; --border-light: #21262D;
  --success: #3FB950;
  --font-body: "PingFang SC", "Inter", "Noto Sans SC", sans-serif;
  --max-width: 1200px; --nav-height: 56px; --footer-h: 88px;
  --space-md: 1rem; --space-lg: 1.5rem; --space-xl: 2rem; --space-section: 4rem;
  --radius-md: 10px; --radius-lg: 16px; --radius-xl: 24px; --radius-full: 9999px;
  --transition-base: 300ms ease; --transition-theme: 800ms ease;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: var(--nav-height); }
body {
  font-family: var(--font-body);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  transition: background var(--transition-theme), color var(--transition-theme);
  padding-bottom: calc(var(--footer-h) + env(safe-area-inset-bottom, 0px) + 16px);
}
img { max-width: 100%; display: block; }
button { font: inherit; cursor: pointer; }

@keyframes fadeInUp { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fadeInRight { from { opacity: 0; transform: translateX(24px); } to { opacity: 1; transform: translateX(0); } }
@keyframes compareIn { from { opacity: 0; transform: scale(0.96); } to { opacity: 1; transform: scale(1); } }
@keyframes marquee { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }
@keyframes pulse { 0%, 100% { box-shadow: 0 0 0 0 var(--accent-glow); } 50% { box-shadow: 0 0 0 10px transparent; } }

.anim-hero { animation: fadeInUp 700ms cubic-bezier(0.22,1,0.36,1) both; }
.anim-in { animation: fadeInRight 500ms cubic-bezier(0.22,1,0.36,1) both; }
.anim-compare { animation: compareIn 400ms ease-out both; }

.gradient-text {
  background: linear-gradient(135deg, var(--accent), var(--accent-alt));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}

.section-header { text-align: center; margin-bottom: var(--space-xl); padding: 0 16px; }
.section-header h2 { font-size: 1.5rem; margin-bottom: 8px; }
.section-header p { color: var(--text-secondary); }

#navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  height: var(--nav-height);
  background: color-mix(in srgb, var(--bg-primary) 88%, transparent);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-light);
}
.nav-inner {
  max-width: var(--max-width); margin: 0 auto; padding: 0 16px;
  height: 100%; display: flex; align-items: center; justify-content: space-between;
}
.logo { font-weight: 700; color: var(--text-primary); text-decoration: none; font-size: 1rem; }
.nav-actions { display: flex; gap: 8px; align-items: center; }
.theme-switcher {
  border: 1px solid var(--border); background: var(--bg-card); color: var(--text-primary);
  padding: 6px 12px; border-radius: var(--radius-full); font-size: 0.85rem;
}
.nav-cta {
  background: var(--accent); color: #fff; padding: 8px 14px;
  border-radius: var(--radius-full); text-decoration: none; font-weight: 600; font-size: 0.85rem;
}

#hero {
  position: relative; min-height: 92vh;
  display: flex; align-items: center; justify-content: center;
  padding: calc(var(--nav-height) + 24px) 16px 32px; overflow: hidden;
}
#heroCanvas { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }
.hero-content { position: relative; z-index: 1; max-width: 760px; width: 100%; text-align: center; }
.hero-badge {
  display: inline-block; margin-bottom: 16px; padding: 4px 12px;
  background: color-mix(in srgb, var(--accent) 15%, transparent); color: var(--accent);
  border-radius: var(--radius-full); font-size: 0.85rem;
}
.hero-title { font-size: clamp(1.6rem, 5vw, 2.4rem); font-weight: 700; line-height: 1.25; margin-bottom: 12px; }
.hero-subtitle { color: var(--text-secondary); margin-bottom: 24px; font-size: 0.95rem; }

.hero-input-wrapper {
  text-align: left; background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius-xl); padding: 20px; transition: all var(--transition-base);
}
.hero-input-wrapper:focus-within { border-color: var(--accent); box-shadow: 0 0 20px var(--accent-glow); }
.input-area--compact { transform: scale(0.98); opacity: 0.85; }

.scenario-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.scenario-tag {
  padding: 6px 12px; background: var(--bg-elevated); border: 1px solid var(--border);
  border-radius: var(--radius-full); font-size: 0.82rem; color: var(--text-secondary);
}
.scenario-tag.active, .scenario-tag:hover { background: var(--accent); color: #fff; border-color: var(--accent); }

#userInput {
  width: 100%; min-height: 100px; padding: 14px; background: var(--bg-primary);
  border: 1px solid var(--border); border-radius: var(--radius-lg);
  color: var(--text-primary); font-family: inherit; resize: vertical;
}
#userInput:focus { outline: none; border-color: var(--accent); }

.btn-generate {
  display: block; width: 100%; margin-top: 12px; padding: 14px;
  background: linear-gradient(135deg, var(--accent), var(--accent-alt));
  color: #fff; border: none; border-radius: var(--radius-lg);
  font-size: 1rem; font-weight: 600;
}
.btn-sub { display: block; font-size: 0.72rem; font-weight: 400; opacity: 0.85; margin-top: 2px; }
.input-hints { display: flex; justify-content: space-between; margin-top: 8px; font-size: 0.75rem; color: var(--text-tertiary); }

.progress-stages { display: flex; flex-wrap: wrap; justify-content: center; gap: 16px; margin-top: 16px; }
.progress-stages .stage { font-size: 0.85rem; color: var(--text-secondary); }
.progress-stages .stage.active { color: var(--accent); font-weight: 600; }
.progress-stages .stage.done { color: var(--success); }

.result-preview { margin-top: 20px; }
.result-meta { text-align: center; font-size: 0.85rem; color: var(--accent); margin-bottom: 12px; font-weight: 600; }
.shot-cards { display: flex; flex-direction: column; gap: 12px; margin: 16px 0; }
.result-toolbar { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin-top: 16px; }

.script-card {
  background: var(--bg-elevated); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 14px;
}
.script-card__head { display: flex; gap: 8px; align-items: center; margin-bottom: 8px; flex-wrap: wrap; }
.script-card__badge { background: var(--accent); color: #fff; font-size: 0.72rem; padding: 2px 8px; border-radius: 999px; }
.script-card__dur, .script-card__cam { font-size: 0.75rem; color: var(--text-secondary); }
.script-card__title { font-size: 0.95rem; margin-bottom: 6px; }
.script-card__dialogue { font-size: 0.88rem; color: var(--text-secondary); margin-bottom: 10px; font-style: italic; }
.script-card__visual { height: 36px; border-radius: 8px; display: flex; align-items: center; padding: 0 12px; font-size: 0.75rem; color: #fff; }

.timeline { margin-bottom: 12px; }
.timeline__track { display: flex; gap: 4px; height: 36px; }
.timeline__seg {
  flex: 1; min-width: 32px; border: none; border-radius: 6px;
  background: color-mix(in srgb, var(--accent) 30%, var(--bg-elevated));
  color: var(--text-primary); font-size: 0.75rem; font-weight: 700;
}
.timeline__seg--active { background: var(--accent); color: #fff; }
.timeline__scale { display: flex; justify-content: space-between; font-size: 0.72rem; color: var(--text-tertiary); margin-top: 4px; }

.export-panel { background: var(--bg-primary); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 12px; }
.export-tabs { display: flex; gap: 6px; margin-bottom: 10px; flex-wrap: wrap; }
.export-tab { border: 1px solid var(--border); background: var(--bg-card); color: var(--text-secondary); padding: 4px 10px; border-radius: 6px; font-size: 0.75rem; }
.export-tab.active { background: var(--accent); color: #fff; border-color: var(--accent); }
.export-preview { max-height: 120px; overflow: auto; font-size: 0.75rem; color: var(--text-secondary); white-space: pre-wrap; margin-bottom: 10px; padding: 8px; background: var(--bg-elevated); border-radius: 8px; }
.export-actions { display: flex; gap: 8px; flex-wrap: wrap; }

.btn { display: inline-flex; align-items: center; justify-content: center; border: none; border-radius: 10px; padding: 8px 14px; font-weight: 600; text-decoration: none; }
.btn--primary { background: var(--accent); color: #fff; }
.btn--ghost { background: transparent; border: 1px solid var(--border); color: var(--text-primary); }
.btn--sm { padding: 6px 12px; font-size: 0.85rem; }

#compare, #features, #workflow, #demo, #cases, #trust, #faq, #cta { padding: var(--space-section) 16px; }

.compare-container { max-width: var(--max-width); margin: 0 auto; position: relative; height: 320px; border-radius: var(--radius-xl); overflow: hidden; border: 1px solid var(--border); }
.compare-slider { position: relative; width: 100%; height: 100%; }
.compare-before, .compare-after { position: absolute; inset: 0; padding: 16px; overflow: auto; }
.compare-before { z-index: 1; background: var(--bg-card); }
.compare-after { z-index: 2; background: color-mix(in srgb, var(--accent) 8%, var(--bg-card)); clip-path: inset(0 0 0 50%); }
.compare-before pre, .compare-after pre { white-space: pre-wrap; font-size: 0.85rem; line-height: 1.6; color: var(--text-secondary); font-family: inherit; }
.compare-slider-handle { position: absolute; top: 0; bottom: 0; left: 50%; width: 3px; background: var(--accent); z-index: 3; pointer-events: none; }
.compare-slider__range { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: ew-resize; z-index: 4; }
.compare-metrics { max-width: var(--max-width); margin: 16px auto 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 640px) { .compare-metrics { grid-template-columns: repeat(4, 1fr); } }
.compare-metric { text-align: center; padding: 12px; background: var(--bg-card); border-radius: var(--radius-md); border: 1px solid var(--border); }
.compare-metric .value { font-size: 1.25rem; font-weight: 700; color: var(--accent); }
.compare-metric .label { font-size: 0.72rem; color: var(--text-secondary); }

.bento-grid { max-width: var(--max-width); margin: 0 auto; display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.bento-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 18px; transition: transform var(--transition-base), border-color var(--transition-base); }
.bento-card:hover { border-color: var(--accent); transform: translateY(-2px); }
.bento-card.bento-large { grid-column: span 2; }
.bento-card.bento-wide { grid-column: span 2; }
.bento-icon { font-size: 1.5rem; display: block; margin-bottom: 8px; }
.bento-card h3 { font-size: 1rem; margin-bottom: 6px; }
.bento-card p { color: var(--text-secondary); font-size: 0.85rem; }
@media (max-width: 640px) { .bento-grid { grid-template-columns: 1fr; } .bento-card.bento-large, .bento-card.bento-wide { grid-column: span 1; } }

.steps-container { max-width: var(--max-width); margin: 0 auto; display: flex; align-items: center; justify-content: center; gap: 12px; flex-wrap: wrap; }
.step-card { text-align: center; padding: 20px; background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-lg); flex: 1; min-width: 140px; max-width: 240px; }
.step-number { font-size: 0.72rem; color: var(--accent); font-weight: 700; letter-spacing: 1px; }
.step-icon { font-size: 2rem; margin: 8px 0; }
.step-card p { color: var(--text-secondary); font-size: 0.85rem; }
.step-arrow { font-size: 1.5rem; color: var(--text-tertiary); }

.chat-demo { max-width: 640px; margin: 0 auto; display: flex; flex-direction: column; gap: 12px; }
.chat-bubble { display: flex; gap: 10px; align-items: flex-start; }
.chat-bubble.user { flex-direction: row-reverse; }
.bubble-avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--bg-card); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.bubble-text { max-width: 85%; padding: 12px 14px; border-radius: var(--radius-lg); font-size: 0.88rem; }
.chat-bubble.user .bubble-text { background: var(--accent); color: #fff; }
.chat-bubble.ai .bubble-text { background: var(--bg-card); border: 1px solid var(--border); }

.cases-scroll { max-width: var(--max-width); margin: 0 auto; display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 8px; }
.case-card { min-width: 260px; scroll-snap-align: start; background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 18px; cursor: pointer; flex-shrink: 0; }
.case-card:hover { border-color: var(--accent); }
.case-card__meta { font-size: 0.75rem; color: var(--accent); margin-top: 8px; display: block; }

.trust-metrics { max-width: var(--max-width); margin: 0 auto 24px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.metric { text-align: center; }
.metric-number { display: block; font-size: clamp(1.5rem, 4vw, 2rem); font-weight: 800; color: var(--accent); }
.metric-label { font-size: 0.82rem; color: var(--text-secondary); }
.logo-wall { max-width: var(--max-width); margin: 0 auto 24px; overflow: hidden; height: 48px; }
.logo-track { display: flex; gap: 32px; animation: marquee 30s linear infinite; white-space: nowrap; }
.logo-item { padding: 8px 16px; background: var(--bg-card); border-radius: 8px; font-size: 0.85rem; color: var(--text-secondary); }
.testimonials { max-width: var(--max-width); margin: 0 auto; display: grid; gap: 12px; }
.testimonial-card { padding: 18px; background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-lg); text-align: center; }
.testimonial-card footer { margin-top: 8px; font-size: 0.85rem; color: var(--text-secondary); }

.faq-list { max-width: 640px; margin: 0 auto; }
.faq-item { margin-bottom: 10px; background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-md); padding: 14px; }
.faq-item summary { font-weight: 600; cursor: pointer; list-style: none; }
.faq-item p { margin-top: 10px; color: var(--text-secondary); font-size: 0.88rem; }

#cta { text-align: center; background: linear-gradient(180deg, transparent, var(--bg-card)); }
.cta-inner h2 { font-size: 1.4rem; margin-bottom: 8px; }
.cta-inner > p { color: var(--text-secondary); margin-bottom: 16px; }
.btn-cta { padding: 14px 28px; background: var(--accent); color: #fff; border: none; border-radius: var(--radius-lg); font-size: 1rem; font-weight: 600; animation: pulse 2s ease-in-out infinite; }
.cta-note { margin-top: 12px; font-size: 0.75rem; color: var(--text-tertiary); }

.site-footer { text-align: center; padding: 24px 16px; color: var(--text-tertiary); font-size: 0.85rem; }

.contact-footer { position: fixed; left: 0; right: 0; bottom: 0; z-index: 90; background: var(--bg-card); border-top: 1px solid var(--border); padding: 10px 12px calc(10px + env(safe-area-inset-bottom)); }
.contact-footer__btns { display: flex; gap: 8px; }
.contact-footer__cta { flex: 1; text-align: center; padding: 10px; border-radius: 10px; background: #c41e1e; color: #fff !important; font-weight: 600; text-decoration: none; }
.contact-footer__btn { flex: 1; text-align: center; padding: 10px; border-radius: 10px; border: 1px solid var(--border); background: var(--bg-primary); color: var(--text-primary); text-decoration: none; }
.contact-footer__brand { margin: 8px 0 0; font-size: 0.7rem; color: var(--text-tertiary); text-align: center; }

.toast { position: fixed; left: 50%; bottom: calc(var(--footer-h) + 20px); transform: translateX(-50%); z-index: 2000; padding: 10px 16px; background: #0f172a; color: #fff; border-radius: 10px; font-size: 0.9rem; }
.toast[hidden] { display: none; }

/* 编辑模式 */
.edit-overlay { position: fixed; inset: 0; z-index: 300; background: var(--bg-primary); display: flex; flex-direction: column; }
.edit-header { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; border-bottom: 1px solid var(--border); }
.edit-layout { flex: 1; display: grid; grid-template-columns: 1fr; gap: 12px; padding: 16px; overflow: auto; }
@media (min-width: 768px) { .edit-layout { grid-template-columns: 1fr 1fr; } }
.edit-shot { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 12px; margin-bottom: 10px; }
.edit-shot label { font-size: 0.8rem; color: var(--accent); display: block; margin-bottom: 6px; }
.edit-shot input, .edit-shot textarea, .edit-shot select { width: 100%; margin-bottom: 8px; padding: 8px; background: var(--bg-primary); border: 1px solid var(--border); border-radius: 8px; color: var(--text-primary); font-family: inherit; }
.edit-shot__actions { display: flex; gap: 8px; }
.edit-shot__actions button { font-size: 0.75rem; padding: 4px 10px; border-radius: 6px; border: 1px solid var(--border); background: var(--bg-elevated); color: var(--text-primary); }

.ai-ball {
  position: fixed; right: 20px; bottom: calc(var(--footer-h) + 20px); z-index: 310;
  width: 52px; height: 52px; border-radius: 50%; border: none;
  background: linear-gradient(135deg, var(--accent), var(--accent-alt)); color: #fff; font-weight: 700;
  box-shadow: 0 4px 20px var(--accent-glow); animation: pulse 2s infinite;
}
.ai-menu {
  position: fixed; right: 20px; bottom: calc(var(--footer-h) + 80px); z-index: 311;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: 8px; display: flex; flex-direction: column; gap: 4px; min-width: 160px;
}
.ai-menu button { border: none; background: transparent; color: var(--text-primary); padding: 10px 12px; text-align: left; border-radius: 8px; }
.ai-menu button:hover { background: var(--bg-elevated); }

@media (max-width: 640px) {
  .trust-metrics { grid-template-columns: 1fr; }
  .steps-container { flex-direction: column; }
  .step-arrow { transform: rotate(90deg); }
}

/* 分享页 */
.share-page { min-height: 100vh; }
.share-header {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px; background: color-mix(in srgb, var(--bg-primary) 92%, transparent);
  backdrop-filter: blur(8px); border-bottom: 1px solid var(--border-light);
}
.share-header__back { color: var(--text-primary); text-decoration: none; font-weight: 600; font-size: 0.9rem; }
.share-main { max-width: 720px; margin: 0 auto; padding: 20px 16px 24px; }
.share-hero { text-align: center; margin-bottom: 20px; }
.share-meta { color: var(--accent); font-weight: 600; font-size: 0.9rem; margin-top: 8px; }
.share-cards { display: flex; flex-direction: column; gap: 12px; margin-bottom: 20px; }
.share-actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.share-empty { text-align: center; padding: 32px 16px; color: var(--text-secondary); }
.share-empty p { margin-bottom: 16px; }
