/* Landing Page — Motion-based product walkthrough */

:root {
    --lp-ink: #050505;
    --lp-paper: #ffffff;
    --lp-stone: #e7e7e7;
    --lp-muted: #777777;
    --lp-accent: #ffffff;
    --lp-accent-hover: #f1f1f1;
    --lp-hero-bg: #000000;
}

/* Reset for landing page */
.landing-page {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.6;
    color: var(--lp-ink);
    background: var(--lp-paper);
}

body:has(.landing-page) .container,
body.landing-page-active .container {
    max-width: 100%;
    padding: 0;
}

/* ========== Header ========== */

.landing-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 16px 0;
    background: transparent;
    transition: background 0.3s;
}

.landing-header.scrolled {
    background: var(--lp-hero-bg);
}

.landing-header-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.landing-logo a {
    font-size: 1.25rem;
    font-weight: 600;
    color: white;
    text-decoration: none;
    letter-spacing: -0.01em;
}

.landing-nav {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.landing-nav-link {
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    font-size: 0.9rem;
    padding: 6px 14px;
    border-radius: 4px;
    transition: color 0.2s;
}

.landing-nav-link:hover {
    color: white;
    text-decoration: none;
}

.landing-nav-link.signup-btn {
    background: var(--lp-accent);
    color: var(--lp-hero-bg);
    font-weight: 600;
}

.landing-nav-link.signup-btn:hover {
    background: rgba(255,255,255,0.9);
}

/* ========== Hero ========== */

.hero {
    background: var(--lp-hero-bg);
    color: white;
    padding: 100px 24px 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 50vh;
}

.hero-container {
    max-width: 1000px;
    margin: 0 auto;
    width: 100%;
}

.hero-title {
    font-size: 4.5rem;
    font-weight: 600;
    letter-spacing: -0.04em;
    line-height: 1.05;
    margin-bottom: 0;
    opacity: 0;
    animation: hero-entrance 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.1s forwards;
}

/* Animated voice waveform between title and subtitle */
.hero-wave {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 3px;
    height: 28px;
    margin: 1.5rem 0 1.8rem;
    opacity: 0;
    animation: hero-entrance 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.2s forwards;
}

.hero-wave span {
    width: 2px;
    background: rgba(255,255,255,0.35);
    border-radius: 1px;
    height: 4px;
    animation: hero-wave-bar 0.8s ease-in-out infinite alternate;
}

.hero-wave span:nth-child(4n+1) { animation-duration: 0.7s; }
.hero-wave span:nth-child(4n+2) { animation-duration: 0.95s; animation-delay: 0.15s; }
.hero-wave span:nth-child(4n+3) { animation-duration: 0.6s; animation-delay: 0.05s; }
.hero-wave span:nth-child(4n)   { animation-duration: 1.05s; animation-delay: 0.25s; }

@keyframes hero-wave-bar {
    0% { height: 4px; }
    100% { height: 22px; }
}

.hero-subtitle {
    font-size: 1.2rem;
    opacity: 0;
    margin-bottom: 2.5rem;
    font-weight: 400;
    animation: hero-entrance 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.35s forwards;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    opacity: 0;
    animation: hero-entrance 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.5s forwards;
}

@keyframes hero-entrance {
    from { opacity: 0; transform: translateY(24px); }
    to { opacity: 1; transform: translateY(0); }
}

.btn-primary {
    background: var(--lp-accent);
    color: var(--lp-hero-bg);
    padding: 12px 28px;
    border-radius: 4px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: opacity 0.2s;
    display: inline-block;
    border: none;
    cursor: pointer;
}

.btn-primary:hover {
    opacity: 0.9;
    color: var(--lp-hero-bg);
    text-decoration: none;
}

.btn-secondary {
    background: transparent;
    color: white;
    padding: 12px 28px;
    border: 1px solid rgba(255,255,255,0.4);
    border-radius: 4px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: border-color 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.btn-secondary:hover {
    border-color: white;
}

/* ========== Scenes ========== */

.scene {
    padding: 80px 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    border-bottom: 1px solid var(--lp-stone);
}

.scene:last-of-type {
    border-bottom: none;
}

.scene-label {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--lp-muted);
    margin-bottom: 48px;
    text-align: center;
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 0.5s, transform 0.5s;
}

.scene-visible .scene-label {
    opacity: 1;
    transform: translateY(0);
}

.scene-stage {
    max-width: 640px;
    width: 100%;
}

/* ========== Scene: Voice → Cards ========== */

/* Step labels — "You say" / "Cards appear" */
.scene-step-label {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--lp-accent);
    font-weight: 600;
    margin-bottom: 8px;
    opacity: 0;
}

[data-scene="voice"].scene-visible .scene-step-input {
    animation: scene-fade-in 0.3s ease forwards 0.1s;
}

[data-scene="voice"].scene-visible .scene-step-output {
    animation: scene-fade-in 0.3s ease forwards;
    animation-delay: calc(var(--typing-duration, 2s) - 0.1s);
}

/* Flow arrow between voice input and board */
.scene-flow-arrow {
    text-align: center;
    padding: 10px 0;
    color: var(--lp-muted);
    opacity: 0;
}

[data-scene="voice"].scene-visible .scene-flow-arrow {
    animation: scene-fade-in 0.3s ease forwards;
    animation-delay: calc(var(--typing-duration, 2s) - 0.3s);
}

.scene-voice-input {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 0;
    padding: 16px 20px;
    background: #f8f8f8;
    border-radius: 8px;
    border: 1px solid var(--lp-stone);
}

.scene-mic {
    font-size: 1.5rem;
    flex-shrink: 0;
    position: relative;
    opacity: 0;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
}

[data-scene="voice"].scene-visible .scene-mic {
    animation: scene-fade-in 0.3s ease forwards 0.2s;
}

/* Recording dot — red blink */
.scene-rec-dot {
    position: absolute;
    top: 1px;
    right: 1px;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #ef4444;
    opacity: 0;
}

[data-scene="voice"].scene-visible .scene-rec-dot {
    animation: rec-blink 1.2s ease-in-out 0.4s infinite;
}

[data-scene="voice"].recording-done .scene-rec-dot {
    animation: none;
    opacity: 0;
}

@keyframes rec-blink {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 1; }
}

/* Mic pulse rings */
.scene-mic::before,
.scene-mic::after {
    content: '';
    position: absolute;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 2px solid var(--lp-accent);
    opacity: 0;
}

[data-scene="voice"].scene-visible .scene-mic::before {
    animation: mic-pulse 2s ease-out 0.5s infinite;
}

[data-scene="voice"].scene-visible .scene-mic::after {
    animation: mic-pulse 2s ease-out 1.3s infinite;
}

[data-scene="voice"].recording-done .scene-mic::before,
[data-scene="voice"].recording-done .scene-mic::after {
    animation: none;
    opacity: 0;
}

@keyframes mic-pulse {
    0% { transform: scale(1); opacity: 0.5; }
    100% { transform: scale(2.5); opacity: 0; }
}

/* Waveform bars — animated audio visualizer */
.scene-waveform {
    display: flex;
    align-items: center;
    gap: 2px;
    height: 24px;
    flex-shrink: 0;
}

.scene-waveform span {
    width: 3px;
    background: var(--lp-accent);
    border-radius: 2px;
    height: 4px;
    opacity: 0;
    transition: height 0.3s ease;
}

[data-scene="voice"].scene-visible .scene-waveform span {
    opacity: 0.7;
    animation: waveform-pulse 0.5s ease-in-out infinite alternate;
}

.scene-waveform span:nth-child(1) { animation-delay: 0s; }
.scene-waveform span:nth-child(2) { animation-delay: 0.12s; }
.scene-waveform span:nth-child(3) { animation-delay: 0.24s; }
.scene-waveform span:nth-child(4) { animation-delay: 0.08s; }
.scene-waveform span:nth-child(5) { animation-delay: 0.2s; }

@keyframes waveform-pulse {
    0% { height: 4px; }
    100% { height: 18px; }
}

/* Stop waveform after recording finishes */
[data-scene="voice"].recording-done .scene-waveform span {
    animation: none;
    height: 4px;
    opacity: 0.3;
}

.scene-transcript {
    font-size: 0.95rem;
    color: var(--lp-ink);
    font-style: italic;
    min-height: 1.4em;
}

.scene-typing {
    display: inline;
    border-right: 2px solid var(--lp-accent);
    padding-right: 2px;
    animation: scene-blink-cursor 0.6s step-end infinite;
}

.scene-typing.typing-done {
    border-right-color: transparent;
    animation: none;
}

@keyframes scene-blink-cursor {
    50% { border-color: transparent; }
}

.scene-board {
    display: flex;
    gap: 12px;
}

.scene-column {
    flex: 1;
    background: #fafafa;
    border: 1px solid var(--lp-stone);
    border-radius: 8px;
    padding: 12px;
    min-height: 120px;
}

.scene-col-title {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--lp-muted);
    margin-bottom: 12px;
}

.scene-card {
    background: white;
    border: 1px solid var(--lp-stone);
    border-radius: 4px;
    padding: 10px 12px;
    font-size: 0.85rem;
    margin-bottom: 8px;
    color: var(--lp-ink);
}

/* Cards pop in with spring bounce */
[data-scene="voice"] .scene-card-1,
[data-scene="voice"] .scene-card-2,
[data-scene="voice"] .scene-card-3 {
    opacity: 0;
    transform: translateY(12px) scale(0.95);
}

[data-scene="voice"].scene-visible .scene-card-1 {
    animation: card-pop-in 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    animation-delay: var(--typing-duration, 2s);
}
[data-scene="voice"].scene-visible .scene-card-2 {
    animation: card-pop-in 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    animation-delay: calc(var(--typing-duration, 2s) + 0.3s);
}
[data-scene="voice"].scene-visible .scene-card-3 {
    animation: card-pop-in 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    animation-delay: calc(var(--typing-duration, 2s) + 0.6s);
}

@keyframes card-pop-in {
    0% { opacity: 0; transform: translateY(12px) scale(0.95); }
    60% { opacity: 1; transform: translateY(-3px) scale(1.02); }
    100% { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes scene-fade-in {
    to { opacity: 1; }
}

/* ========== Scene: Drag ========== */

/* Board needs position context for cursor */
.scene-drag-board {
    position: relative;
}

/*
 * Drag scene timeline (shared: delay 0s, duration 1.3s)
 *   0%  (t=0.00s) — cursor + moving card are already active at origin
 *   8%  (t=0.10s) — card lifts
 *  68%  (t=0.88s) — card reaches In Progress
 *  82%  (t=1.07s) — card drops into place
 *  92%+ (t=1.20s) — cursor fades, card settles
 */

/* Origin card — starts normal, becomes ghost as soon as the card lifts. */
[data-scene="drag"].scene-visible .scene-drag-origin {
    animation: origin-to-ghost 0.23s ease forwards 0.1s;
}

@keyframes origin-to-ghost {
    0% {
        background: white;
        color: var(--lp-ink);
        opacity: 1;
    }
    5% {
        border-style: dashed;
    }
    100% {
        background: transparent;
        color: var(--lp-muted);
        opacity: 0.35;
        border-style: dashed;
    }
}

/* Moving card — same duration/easing as cursor */
[data-scene="drag"] .scene-card-moving {
    opacity: 0;
    transform: translateX(-140%);
}

[data-scene="drag"].scene-visible .scene-card-moving {
    animation: card-drag-across 1.3s cubic-bezier(0.2, 0, 0, 1) forwards;
}

@keyframes card-drag-across {
    0% {
        opacity: 1;
        transform: translateX(-140%);
    }
    8% {
        transform: translateX(-140%) translateY(-10px);
        box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    }
    68% {
        transform: translateX(4px) translateY(-10px);
        box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    }
    82% {
        transform: translateX(-2px) translateY(0);
        box-shadow: 0 2px 6px rgba(0,0,0,0.06);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
        box-shadow: none;
    }
}

/* Cursor — same duration/easing as card */
.scene-cursor {
    position: absolute;
    opacity: 0;
    z-index: 10;
    pointer-events: none;
    filter: drop-shadow(0 1px 2px rgba(0,0,0,0.15));
}

[data-scene="drag"].scene-visible .scene-cursor {
    animation: cursor-path 1.3s cubic-bezier(0.2, 0, 0, 1) forwards;
}

@keyframes cursor-path {
    0%   { left: 14%; top: 42%; opacity: 1; }
    8%   { left: 14%; top: 38%; }
    68%  { left: 48%; top: 38%; }
    82%  { left: 48%; top: 42%; opacity: 1; }
    92%  { left: 48%; top: 42%; opacity: 0; }
    100% { left: 48%; top: 42%; opacity: 0; }
}

/* Column glows as card approaches, then solidifies */
.scene-col-highlight {
    border-color: var(--lp-accent);
    border-style: dashed;
}

[data-scene="drag"].scene-visible .scene-col-highlight {
    animation: col-receive 1.3s ease forwards;
}

@keyframes col-receive {
    0%, 28% {
        border-style: dashed;
        box-shadow: none;
    }
    58% {
        box-shadow: inset 0 0 12px rgba(99, 102, 241, 0.12);
    }
    78% {
        border-style: solid;
        box-shadow: inset 0 0 12px rgba(99, 102, 241, 0.12);
    }
    100% {
        border-style: solid;
        box-shadow: none;
    }
}

/* Done is static context for the drag demo; only the dragged card should move. */
[data-scene="drag"] .scene-card-done {
    color: var(--lp-muted);
}

[data-scene="drag"].scene-visible .scene-card-done {
    animation: none;
}

/* ========== Scene: Group ========== */

.scene-containers {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.scene-container {
    border: 1px solid transparent;
    border-left: 3px solid transparent;
    border-radius: 8px;
    padding: 18px 20px;
    background: rgba(255, 255, 255, 0.92);
}

.scene-container-label {
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--lp-muted);
    margin-bottom: 12px;
    opacity: 0;
}

.scene-board-rows {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.scene-board-row {
    display: grid;
    grid-template-columns: 34px minmax(140px, 1fr) minmax(140px, 220px);
    align-items: center;
    gap: 12px;
    min-height: 70px;
    background: white;
    border: 1px solid var(--lp-stone);
    border-radius: 8px;
    padding: 12px 14px;
    box-shadow: 0 12px 28px rgba(0,0,0,0.06);
    opacity: 0;
    transform: translate(var(--scatter-x, 0), var(--scatter-y, 0)) rotate(var(--scatter-r, 0deg));
}

.scene-board-handle {
    width: 28px;
    height: 28px;
    border: 1px solid var(--lp-stone);
    border-radius: 6px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
}

.scene-board-handle span {
    width: 12px;
    height: 2px;
    background: var(--lp-muted);
    border-radius: 999px;
}

.scene-board-copy {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.scene-board-title {
    font-weight: 700;
    color: var(--lp-ink);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.scene-board-meta {
    font-size: 0.74rem;
    color: var(--lp-muted);
}

.scene-board-preview {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
    align-self: stretch;
}

.scene-board-preview span {
    border-left: 1px solid var(--lp-stone);
    padding-left: 6px;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.scene-board-preview i {
    display: block;
    height: 8px;
    border-radius: 3px;
    background: #f1f1f1;
    border: 1px solid #e6e6e6;
}

/* Boards appear scattered, hold, then fly into containers */
[data-scene="group"].scene-visible .scene-board-row {
    animation: board-scatter-gather 1s cubic-bezier(0.22, 1, 0.36, 1) forwards 0.08s;
}

[data-scene="group"].scene-visible .scene-container-1 .scene-board-row:nth-child(2) { animation-delay: 0.14s; }
[data-scene="group"].scene-visible .scene-container-1 .scene-board-row:nth-child(3) { animation-delay: 0.18s; }
[data-scene="group"].scene-visible .scene-container-2 .scene-board-row:nth-child(1) { animation-delay: 0.14s; }
[data-scene="group"].scene-visible .scene-container-2 .scene-board-row:nth-child(2) { animation-delay: 0.2s; }

@keyframes board-scatter-gather {
    0% {
        opacity: 0;
        transform: translate(var(--scatter-x, 0), var(--scatter-y, 0)) rotate(var(--scatter-r, 0deg));
    }
    15% {
        opacity: 0.8;
        transform: translate(var(--scatter-x, 0), var(--scatter-y, 0)) rotate(var(--scatter-r, 0deg));
    }
    35% {
        opacity: 0.8;
        transform: translate(var(--scatter-x, 0), var(--scatter-y, 0)) rotate(var(--scatter-r, 0deg));
    }
    90% {
        opacity: 1;
        transform: translate(1px, 0) rotate(0deg);
    }
    100% {
        opacity: 1;
        transform: translate(0, 0) rotate(0deg);
    }
}

/* Container borders draw in as boards gather */
[data-scene="group"].scene-visible .scene-container-1 {
    animation: container-draw-purple 0.35s ease forwards 0.45s;
}

[data-scene="group"].scene-visible .scene-container-2 {
    animation: container-draw-green 0.35s ease forwards 0.55s;
}

@keyframes container-draw-purple {
    from { border-color: transparent; border-left-color: transparent; }
    to { border-color: var(--lp-stone); border-left-color: var(--lp-accent); }
}

@keyframes container-draw-green {
    from { border-color: transparent; border-left-color: transparent; }
    to { border-color: var(--lp-stone); border-left-color: #10b981; }
}

/* Labels appear after borders */
[data-scene="group"].scene-visible .scene-container-1 .scene-container-label {
    animation: scene-fade-in 0.25s ease forwards 0.75s;
}

[data-scene="group"].scene-visible .scene-container-2 .scene-container-label {
    animation: scene-fade-in 0.25s ease forwards 0.85s;
}

/* ========== Scene: Calendar ========== */

.scene-sync {
    display: grid;
    grid-template-columns: minmax(220px, 270px) minmax(170px, 210px) 64px minmax(220px, 270px);
    align-items: center;
    gap: 18px;
    justify-content: center;
}

.scene-voice-capture,
.scene-parse-panel,
.scene-calendar-event {
    background: #ffffff;
    border: 1px solid var(--lp-stone);
    border-radius: 10px;
    box-shadow: 0 18px 42px rgba(0,0,0,0.08);
    opacity: 0;
}

.scene-voice-capture {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 16px;
}

[data-scene="calendar"].scene-visible .scene-voice-capture {
    animation: card-pop-in 0.45s cubic-bezier(0.34, 1.56, 0.64, 1) forwards 0.2s;
}

.scene-voice-topline {
    display: flex;
    align-items: center;
    gap: 8px;
}

.scene-voice-mic {
    width: 30px;
    height: 30px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--lp-stone);
    border-radius: 50%;
    font-size: 1rem;
    background: #fafafa;
}

[data-scene="calendar"].scene-visible .scene-voice-mic {
    animation: mic-listening-pulse 1.2s ease-in-out 0.2s infinite;
}

.scene-voice-status {
    font-size: 0.74rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--lp-muted);
}

.scene-voice-quote {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--lp-ink);
    line-height: 1.35;
}

.scene-wave {
    display: flex;
    align-items: flex-end;
    gap: 4px;
    height: 22px;
}

.scene-wave span {
    width: 4px;
    height: 8px;
    border-radius: 999px;
    background: var(--lp-ink);
    opacity: 0.35;
}

[data-scene="calendar"].scene-visible .scene-wave span {
    animation: wave-listen 0.9s ease-in-out infinite;
}

[data-scene="calendar"].scene-visible .scene-wave span:nth-child(2) { animation-delay: 0.1s; }
[data-scene="calendar"].scene-visible .scene-wave span:nth-child(3) { animation-delay: 0.2s; }
[data-scene="calendar"].scene-visible .scene-wave span:nth-child(4) { animation-delay: 0.3s; }
[data-scene="calendar"].scene-visible .scene-wave span:nth-child(5) { animation-delay: 0.4s; }

.scene-parse-panel {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 14px;
}

[data-scene="calendar"].scene-visible .scene-parse-panel {
    animation: scene-fade-in-up 0.38s ease forwards 0.58s;
}

.scene-parse-label {
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--lp-muted);
}

.scene-parse-chip {
    border: 1px solid var(--lp-stone);
    border-radius: 999px;
    padding: 7px 10px;
    background: #fafafa;
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--lp-ink);
    opacity: 0;
}

[data-scene="calendar"].scene-visible .scene-parse-chip {
    animation: chip-resolve 0.32s ease forwards 0.82s;
}

[data-scene="calendar"].scene-visible .scene-parsed-time {
    animation-delay: 0.96s;
}

/* Animated dots replacing static arrow */
.scene-sync-arrow {
    display: flex;
    gap: 6px;
    align-items: center;
    opacity: 0;
}

[data-scene="calendar"].scene-visible .scene-sync-arrow {
    animation: scene-fade-in 0.3s ease forwards 1.12s;
}

.sync-dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--lp-muted);
    opacity: 0.2;
}

[data-scene="calendar"].scene-visible .sync-dot:nth-child(1) {
    animation: dot-travel 1.2s ease-in-out 1.18s infinite;
}
[data-scene="calendar"].scene-visible .sync-dot:nth-child(2) {
    animation: dot-travel 1.2s ease-in-out 1.28s infinite;
}
[data-scene="calendar"].scene-visible .sync-dot:nth-child(3) {
    animation: dot-travel 1.2s ease-in-out 1.38s infinite;
}
[data-scene="calendar"].scene-visible .sync-dot:nth-child(4) {
    animation: dot-travel 1.2s ease-in-out 1.48s infinite;
}
[data-scene="calendar"].scene-visible .sync-dot:nth-child(5) {
    animation: dot-travel 1.2s ease-in-out 1.58s infinite;
}

@keyframes dot-travel {
    0%, 20% { opacity: 0.2; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.5); }
    80%, 100% { opacity: 0.2; transform: scale(1); }
}

.scene-calendar-event {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
}

[data-scene="calendar"].scene-visible .scene-calendar-event {
    animation: card-pop-in 0.45s cubic-bezier(0.34, 1.56, 0.64, 1) forwards 1.35s;
}

.scene-cal-icon {
    font-size: 1.5rem;
}

.scene-cal-title {
    font-size: 0.9rem;
    font-weight: 600;
}

.scene-cal-time {
    font-size: 0.8rem;
    color: var(--lp-muted);
}

.scene-cal-saved {
    margin-top: 3px;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--lp-ink);
}

@keyframes mic-listening-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(0,0,0,0.14); }
    50% { box-shadow: 0 0 0 8px rgba(0,0,0,0.04); }
}

@keyframes wave-listen {
    0%, 100% { height: 8px; opacity: 0.35; }
    50% { height: 22px; opacity: 0.85; }
}

@keyframes chip-resolve {
    from { opacity: 0; transform: translateY(6px) scale(0.96); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

/* ========== Scene: Languages ========== */

.scene-languages {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.scene-lang-row {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 12px 16px;
    background: #fafafa;
    border: 1px solid var(--lp-stone);
    border-radius: 8px;
    opacity: 0;
}

/* Alternate slide directions */
[data-scene="language"].scene-visible .scene-lang-1 {
    animation: lang-slide-left 0.5s cubic-bezier(0.22, 1, 0.36, 1) forwards 0.2s;
}
[data-scene="language"].scene-visible .scene-lang-2 {
    animation: lang-slide-right 0.5s cubic-bezier(0.22, 1, 0.36, 1) forwards 0.45s;
}
[data-scene="language"].scene-visible .scene-lang-3 {
    animation: lang-slide-left 0.5s cubic-bezier(0.22, 1, 0.36, 1) forwards 0.7s;
}
[data-scene="language"].scene-visible .scene-lang-4 {
    animation: lang-slide-right 0.5s cubic-bezier(0.22, 1, 0.36, 1) forwards 0.95s;
}

@keyframes lang-slide-left {
    from { opacity: 0; transform: translateX(-20px); }
    to { opacity: 1; transform: translateX(0); }
}

@keyframes lang-slide-right {
    from { opacity: 0; transform: translateX(20px); }
    to { opacity: 1; transform: translateX(0); }
}

.scene-lang-flag {
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    color: var(--lp-accent);
    width: 28px;
    text-align: center;
    flex-shrink: 0;
}

.scene-lang-text {
    font-size: 0.9rem;
    color: var(--lp-ink);
}

/* ========== Final CTA ========== */

.scene-final {
    padding: 100px 24px;
    background: var(--lp-hero-bg);
    color: white;
    text-align: center;
    border-bottom: none;
}

.scene-final .scene-stage {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.final-line {
    font-size: 1.1rem;
    opacity: 0.85;
    margin-bottom: 24px;
}

.btn-final {
    font-size: 1.1rem;
    padding: 14px 36px;
}

.trial-start-form {
    display: flex;
    justify-content: center;
    margin: 0;
}

.trial-start-form .btn-final {
    appearance: none;
    cursor: pointer;
}

.btn-final-secondary {
    margin-top: 12px;
}

.final-login {
    margin-top: 20px;
    font-size: 0.85rem;
    opacity: 0.7;
}

.final-login a {
    color: white;
    text-decoration: underline;
}

/* ========== Responsive ========== */

@media (max-width: 768px) {
    .hero {
        padding: 80px 20px 48px;
        min-height: 40vh;
    }

    .hero-title {
        font-size: 3rem;
    }

    .scene {
        padding: 60px 16px;
    }

    .scene-board {
        flex-direction: column;
    }

    /* Swap drag animation for simple pop-in on stacked columns */
    [data-scene="drag"] .scene-card-moving {
        transform: translateY(12px) scale(0.95);
    }
    [data-scene="drag"].scene-visible .scene-card-moving {
        animation-name: card-pop-in;
        animation-duration: 0.5s;
        animation-timing-function: cubic-bezier(0.34, 1.56, 0.64, 1);
    }

    .scene-cursor {
        display: none;
    }

    [data-scene="drag"].scene-visible .scene-drag-origin {
        animation-delay: 0.3s;
    }

    .scene-sync {
        grid-template-columns: minmax(0, 1fr);
        gap: 16px;
    }

    .scene-sync-arrow {
        justify-content: center;
        transform: none;
    }

    .scene-board-rows {
        flex-direction: column;
    }

    /* Reduce scatter to vertical-only on mobile */
    [data-scene="group"] .scene-board-row {
        --scatter-x: 0px !important;
        --scatter-r: 0deg !important;
    }

    .scene-board-row {
        grid-template-columns: 30px minmax(0, 1fr);
    }

    .scene-board-preview {
        display: none;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2.2rem;
    }

    .hero-actions {
        flex-direction: column;
    }

    .btn-primary, .btn-secondary {
        width: 100%;
        text-align: center;
        justify-content: center;
    }
}

/* ========== Reduced motion ========== */

@media (prefers-reduced-motion: reduce) {
    .hero-title, .hero-subtitle, .hero-actions, .hero-wave {
        opacity: 1 !important;
        transform: none !important;
        animation: none !important;
    }

    .hero-wave span {
        animation: none !important;
        height: 8px !important;
    }

    .scene-label {
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
    }

    .scene-card-1, .scene-card-2, .scene-card-3,
    .scene-card-moving, .scene-card-done, .scene-drag-origin,
    .scene-container, .scene-voice-capture, .scene-parse-panel,
    .scene-parse-chip,
    .scene-sync-arrow, .scene-calendar-event,
    .scene-lang-row, .scene-mic, .scene-board-row,
    .scene-container-label {
        opacity: 1 !important;
        transform: none !important;
        animation: none !important;
    }

    .scene-container {
        border-color: var(--lp-stone) !important;
    }
    .scene-container-1 {
        border-left-color: var(--lp-accent) !important;
    }
    .scene-container-2 {
        border-left-color: #10b981 !important;
    }

    .scene-cursor {
        display: none !important;
    }

    .scene-mic::before,
    .scene-mic::after {
        animation: none !important;
        display: none;
    }

    .scene-rec-dot {
        display: none !important;
    }

    .scene-waveform span,
    .scene-wave span {
        opacity: 0.5 !important;
        animation: none !important;
        height: 8px !important;
    }

    .scene-step-label,
    .scene-flow-arrow {
        opacity: 1 !important;
        animation: none !important;
    }

    .sync-dot {
        opacity: 0.6 !important;
        animation: none !important;
    }

    .scene-typing {
        animation: none;
        border-right: none;
    }

    .scene-col-highlight {
        border-style: solid;
    }
}

/* ========== Monochrome light/shadow style layer ========== */

.landing-page {
    background:
        radial-gradient(circle at 50% -18rem, rgba(0, 0, 0, 0.08), transparent 38rem),
        var(--lp-paper);
}

.landing-header.scrolled {
    background: rgba(0, 0, 0, 0.92);
    border-bottom: 1px solid rgba(255, 255, 255, 0.14);
    box-shadow: 0 16px 44px rgba(0, 0, 0, 0.45);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
}

.landing-nav-link.signup-btn,
.landing-page .btn-primary,
.btn-final {
    background: #ffffff !important;
    color: #000000 !important;
    border: 1px solid rgba(255, 255, 255, 0.72) !important;
    box-shadow: 0 18px 42px rgba(255, 255, 255, 0.10), 0 12px 30px rgba(0, 0, 0, 0.26) !important;
}

.landing-nav-link.signup-btn:hover,
.landing-page .btn-primary:hover,
.btn-final:hover {
    background: #eeeeee !important;
    color: #000000 !important;
    opacity: 1;
}

.landing-page .btn-secondary {
    background: rgba(255, 255, 255, 0.06) !important;
    color: #ffffff !important;
    border-color: rgba(255, 255, 255, 0.34) !important;
    box-shadow: 0 18px 42px rgba(0, 0, 0, 0.28) !important;
}

.landing-page .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.12) !important;
    border-color: #ffffff !important;
}

.hero,
.scene-final {
    background:
        radial-gradient(circle at 50% -12rem, rgba(255, 255, 255, 0.18), transparent 34rem),
        #000000 !important;
}

.hero-wave span,
.scene-waveform span,
.scene-wave span,
.scene-rec-dot,
.sync-dot {
    background: currentColor !important;
    color: #ffffff;
}

.scene {
    background: #ffffff;
}

.scene:nth-of-type(even) {
    background: #fbfbfb;
}

.scene-stage,
.scene-voice-input,
.scene-board,
.scene-containers,
.scene-sync,
.scene-languages {
    filter: drop-shadow(0 20px 42px rgba(0, 0, 0, 0.08));
}

.scene-voice-input,
.scene-column,
.scene-card,
.scene-container,
.scene-board-row,
.scene-voice-capture,
.scene-parse-panel,
.scene-parse-chip,
.scene-calendar-event,
.scene-lang-row {
    background: #ffffff !important;
    border-color: var(--lp-stone) !important;
    color: var(--lp-ink) !important;
    box-shadow: 0 14px 34px rgba(0, 0, 0, 0.08);
}

.scene-column {
    position: relative;
}

.scene-column + .scene-column::before {
    content: "";
    position: absolute;
    top: 0.65rem;
    bottom: 0.65rem;
    left: -0.4rem;
    width: 1px;
    background: linear-gradient(to bottom, transparent, rgba(0, 0, 0, 0.18), transparent);
    pointer-events: none;
}

.scene-step-label,
.scene-voice-status,
.scene-parse-label,
.scene-cal-saved,
.scene-lang-flag,
.scene-label,
.scene-col-highlight,
.scene-container-1,
.scene-container-2,
.scene-container-label,
.final-login a {
    color: #050505 !important;
    border-color: #050505 !important;
    border-left-color: #050505 !important;
}

.scene-mic::before,
.scene-mic::after {
    border-color: #050505 !important;
}

.scene-typing {
    border-right-color: #050505 !important;
}

@keyframes col-receive {
    0%, 35% {
        border-style: dashed;
        box-shadow: none;
    }
    55%, 72% {
        border-style: solid;
        box-shadow: inset 0 0 14px rgba(0, 0, 0, 0.10);
    }
    100% {
        border-style: solid;
        box-shadow: none;
    }
}

@keyframes container-draw-purple {
    from { border-color: transparent; border-left-color: transparent; }
    to { border-color: var(--lp-stone); border-left-color: #050505; }
}

@keyframes container-draw-green {
    from { border-color: transparent; border-left-color: transparent; }
    to { border-color: var(--lp-stone); border-left-color: #050505; }
}
