/* ============================================================
   motionmind.css — MotionMind case study page
   Design: greyscale / monochromatic. Foundation-first.
   Requires: base.css + components.css
   ============================================================ */

/* ===================================================================
   SECTION NAV — greyscale (matches home/ggpoker)
   =================================================================== */
.section-nav__dot.active             { background: rgba(255,255,255,0.65); }
.section-nav__dot:hover:not(.active) { background: rgba(255,255,255,0.35); }
.section-nav__btn:hover:not(:disabled),
.section-nav__btn.pressed            { color: rgba(255,255,255,0.65); }

/* ===================================================================
   HERO — extends shared hero pattern from components.css
   =================================================================== */
.hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 100px 40px;
    position: relative;
    overflow: hidden;
    background: var(--bg-primary);
}

.hero__inner {
    max-width: var(--content-wide);
    margin: 0 auto;
    width: 100%;
    position: relative;
    z-index: 1;
    /* Copy takes full width; panel is absolutely positioned */
    display: block;
}

/* Left column — unconstrained width so headline never wraps */
.hero__copy {
    min-width: 0;
    position: relative;
    z-index: 2;
}

/* Keep sub-copy at readable width; stats span full row */
.hero__copy .hero__sub   { max-width: 52ch; }
.hero__copy .hero__stats { flex-wrap: nowrap; }

/* Right column — pushed to right edge, partially off-screen (hero clips it) */
.hero__visual {
    position: absolute;
    right: -10vw;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    perspective: 1000px;
    perspective-origin: 50% 60%;
    overflow: visible;
    z-index: 1;
}

/* 3D-transformed panel image */
.mm-panel-img {
    width: clamp(300px, 28vw, 500px);
    height: auto;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    transform: rotateX(10deg) rotateY(-20deg);
    transform-origin: center bottom;
    transform-style: preserve-3d;
    box-shadow:
        -20px 24px 60px rgba(0, 0, 0, 0.65),
        -6px  8px  20px rgba(0, 0, 0, 0.4);
    /* Panel image: animation is CSS-driven — JS just flips play-state via class */
    -webkit-mask-image: linear-gradient(
        to bottom,
        transparent  0%,
        black        14%,
        black        75%,
        transparent 100%
    );
    mask-image: linear-gradient(
        to bottom,
        transparent  0%,
        black        14%,
        black        75%,
        transparent 100%
    );
    display: block;
    transition: transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    opacity: 0; /* JS rAF animation reveals this — see motionmind.html script */
}


/* Greyscale em treatment — bright white on dimmed headline */
.hero__headline em { color: var(--text-primary); }

.hero__eyebrow  { margin-bottom: 32px; }
.hero__headline { margin-bottom: 28px; }  /* no max-width — 3fr column governs width */

/* ===================================================================
   HERO H1 SEQUENCE ANIMATION
   =================================================================== */

/* ".steps." hidden until counter finishes */
.mm-steps-suffix {
    opacity: 0;
    transition: opacity 0.4s ease;
}
.mm-steps-suffix.is-visible { opacity: 1; }

/* "Now: 15 clicks." hidden until after counter */
.mm-now-line {
    opacity: 0;
    transition: opacity 0.55s ease;
    display: block;
}
.mm-now-line.is-visible { opacity: 1; }

/* Sub-copy + stats — hidden until whole h1 is done */
.mm-hero-reveal {
    opacity: 0;
    transform: translateY(14px);
    transition: opacity 0.65s ease, transform 0.65s ease;
}
.mm-hero-reveal.is-visible {
    opacity: 1;
    transform: none;
}

/* Panel slide-up animation — synced with counter start (~200ms) */
@keyframes mm-panel-in {
    from { transform: translateY(calc(-50% + 52px)); }
    to   { transform: translateY(-50%); }
}

.hero__visual {
    animation: mm-panel-in 1.1s cubic-bezier(0.16, 1, 0.3, 1) 0.2s both;
}

/* ===================================================================
   CHAPTERS — standard dark section pattern
   =================================================================== */
.mm-chapter {
    padding: 100px 40px;
    background: #000;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.mm-chapter[data-nav-section] { min-height: unset; }

.mm-chapter--philosophy { padding-bottom: 120px; }

/* ── Inner containers ───────────────────────────────────────── */
.mm-chapter__inner {
    max-width: var(--content-wide);
    margin: 0 auto;
}

/* Two-column variant: left copy / right visual */
.mm-chapter__inner--grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: start;
}

@media (max-width: 900px) {
    .mm-chapter__inner--grid { grid-template-columns: 1fr; gap: 48px; }
}

/* ── Typography ─────────────────────────────────────────────── */
.mm-chapter__eyebrow {
    display: block;
    font-family: var(--font-mono);
    font-size: var(--fs-eyebrow);
    font-weight: 700;
    color: var(--text-muted);
    letter-spacing: 0.18em;
    text-transform: uppercase;
    margin-bottom: 20px;
}

.mm-chapter__title {
    font-size: var(--fs-section-h2);
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: -0.03em;
    line-height: 1.2;
    margin-bottom: 20px;
    max-width: 26ch;
}

.mm-chapter__title em { font-style: normal; color: var(--text-secondary); }

.mm-chapter__desc {
    font-size: var(--fs-body);
    color: var(--text-secondary);
    line-height: 1.75;
    max-width: 58ch;
    margin-bottom: 36px;
}

.mm-chapter__desc strong { color: var(--text-primary); }

/* Problem section — deck copy between h2 and body */
.mm-problem-deck {
    font-size: clamp(1.05rem, 1.6vw, 1.3rem);
    font-weight: 600;
    line-height: 1.4;
    color: var(--text-primary);
    margin: 0 0 28px;
}

.mm-problem-deck__kicker {
    display: block;
    color: var(--text-primary);
    font-style: italic;
    margin-top: 2px;
}

/* Mono text link */
.mm-chapter__link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: var(--font-mono);
    font-size: 0.68rem;
    font-weight: 700;
    color: var(--text-muted);
    text-decoration: none;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    border-bottom: 1px solid var(--border);
    padding-bottom: 2px;
    transition: color 0.2s, border-color 0.2s;
}

.mm-chapter__link:hover { color: var(--text-primary); border-color: var(--border-strong); }

/* Solid CTA button (build section) */
.mm-chapter__cta {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--bg-primary);
    background: var(--text-primary);
    text-decoration: none;
    padding: 12px 24px;
    border-radius: 8px;
    transition: opacity 0.2s, transform 0.15s;
}

.mm-chapter__cta:hover { opacity: 0.85; transform: translateY(-2px); }

/* ===================================================================
   DELIVERABLES BREAKDOWN — problem section right column
   =================================================================== */
.mm-deliverables {
    border: 1px solid var(--border);
    border-radius: 16px;
    overflow: hidden;
    background: rgba(255,255,255,0.02);
}

.mm-deliverables__heading {
    font-family: var(--font-mono);
    font-size: var(--fs-eyebrow);
    font-weight: 700;
    color: var(--text-muted);
    letter-spacing: 0.14em;
    text-transform: uppercase;
    padding: 24px 28px 16px;
    border-bottom: 1px solid var(--border);
}

.mm-deliverables__row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 28px;
    border-bottom: 1px solid var(--border-subtle);
    gap: 16px;
}

.mm-deliverables__row:last-of-type { border-bottom: 1px solid var(--border); }

.mm-deliverables__format {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.mm-deliverables__format-name {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-primary);
}

.mm-deliverables__format-calc {
    font-family: var(--font-mono);
    font-size: 0.6rem;
    color: var(--text-muted);
    letter-spacing: 0.06em;
}

.mm-deliverables__count {
    font-size: clamp(1.4rem, 2vw, 1.8rem);
    font-weight: 800;
    color: var(--text-primary);
    letter-spacing: -0.04em;
    flex-shrink: 0;
}

.mm-deliverables__total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 22px 28px 16px;
    gap: 16px;
}

.mm-deliverables__total-label {
    font-family: var(--font-mono);
    font-size: var(--fs-eyebrow);
    font-weight: 700;
    color: var(--text-muted);
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.mm-deliverables__total-num {
    font-size: clamp(2rem, 3.5vw, 2.8rem);
    font-weight: 900;
    color: var(--text-primary);
    letter-spacing: -0.05em;
}

.mm-deliverables__note {
    font-family: var(--font-mono);
    font-size: 0.58rem;
    color: var(--text-muted);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    padding: 0 28px 20px;
}

/* ===================================================================
   REGIONAL VARIANTS GRID — problem section right column
   =================================================================== */
.mm-region-grid-wrap {
    display: flex;
    flex-direction: column;
    gap: 16px;
    perspective: 900px;
}

.mm-region-grid__caption {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-secondary);
    line-height: 1.5;
    margin: 0;
}

.mm-region-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    transform: rotateX(10deg) rotateY(-6deg);
    transform-style: preserve-3d;
    transition: transform 0.4s ease;
}

.mm-region-grid-wrap:hover .mm-region-grid {
    transform: rotateX(5deg) rotateY(-3deg);
}

.mm-region-card {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.5);
    cursor: default;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    transform: translateZ(0);
}

.mm-region-card:hover {
    transform: translateZ(20px) scale(1.04);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.7);
    border-color: rgba(255, 255, 255, 0.28);
    z-index: 10;
}

.mm-region-card img {
    width: 100%;
    height: auto;
    display: block;
}

.mm-region-card__badge {
    position: absolute;
    bottom: 6px;
    left: 6px;
    background: rgba(0, 0, 0, 0.72);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    color: rgba(255, 255, 255, 0.85);
    font-family: var(--font-mono);
    font-size: 0.52rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    padding: 3px 7px;
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.mm-region-grid__sub {
    font-family: var(--font-mono);
    font-size: 0.62rem;
    color: var(--text-muted);
    letter-spacing: 0.06em;
    text-transform: uppercase;
    margin: 0;
    opacity: 0.7;
}

/* ===================================================================
   VIDEO DEMO PLACEHOLDER — build section right column
   =================================================================== */
.mm-demo-placeholder {
    border: 1px solid var(--border);
    border-radius: 12px;
    background: rgba(255,255,255,0.02);
    height: 100%;
    min-height: 320px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mm-demo-placeholder__inner {
    padding: 48px 40px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.mm-demo-placeholder__icon {
    font-size: 2rem;
    color: var(--text-muted);
    opacity: 0.4;
    margin-bottom: 4px;
}

.mm-demo-placeholder__label {
    font-size: var(--fs-body);
    color: var(--text-secondary);
    font-weight: 500;
}

.mm-demo-placeholder__sub {
    font-family: var(--font-mono);
    font-size: 0.6rem;
    color: var(--text-muted);
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

/* ===================================================================
   IMPACT STATS — flat strip (no box), ch.03
   =================================================================== */
.mm-impact-stats {
    display: flex;
    gap: 48px;
    flex-wrap: wrap;
    padding-top: 8px;
}

@media (max-width: 600px) { .mm-impact-stats { gap: 28px; } }

.mm-impact-stat__num {
    font-size: clamp(1.6rem, 2.8vw, 2.2rem);
    font-weight: 800;
    color: var(--text-primary);
    letter-spacing: -0.04em;
    line-height: 1;
    margin-bottom: 8px;
}

.mm-impact-stat__label {
    font-family: var(--font-mono);
    font-size: 0.6rem;
    color: var(--text-muted);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    line-height: 1.5;
}

/* ===================================================================
   PROOF ROW — ch.04 stats (left column)
   =================================================================== */
.mm-proof-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px 40px;
    padding-top: 24px;
    border-top: 1px solid var(--border);
    margin-bottom: 0;
}

.mm-proof-stat__num {
    font-size: clamp(1.6rem, 2.5vw, 2rem);
    font-weight: 800;
    color: var(--text-primary);
    letter-spacing: -0.04em;
    line-height: 1;
    margin-bottom: 8px;
}

.mm-proof-stat__lbl {
    font-family: var(--font-mono);
    font-size: 0.6rem;
    color: var(--text-muted);
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

/* ===================================================================
   TIME CALCULATOR — ch.02 left column
   =================================================================== */
.mm-time-calc {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.mm-time-calc__hero {
    font-size: clamp(1.5rem, 2.5vw, 2rem);
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-primary);
    letter-spacing: -0.02em;
}

.mm-time-calc__arrow {
    color: var(--violet);
}

.mm-time-calc__prompt {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin: 0;
    line-height: 1.5;
}

/* Slider row */
.mm-time-calc__slider-row {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.mm-time-calc__slider-label {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.mm-time-calc__range {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 4px;
    border-radius: 2px;
    background: var(--border);
    outline: none;
    cursor: pointer;
}
.mm-time-calc__range::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--amber);
    border: 2px solid var(--bg-primary);
    box-shadow: 0 0 0 2px var(--amber);
    cursor: pointer;
    transition: box-shadow 0.15s;
}
.mm-time-calc__range::-webkit-slider-thumb:hover {
    box-shadow: 0 0 0 4px rgba(245,158,11,0.25);
}
.mm-time-calc__range::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--amber);
    border: 2px solid var(--bg-primary);
    cursor: pointer;
}

/* Output comparison row */
.mm-time-calc__output {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-top: 4px;
}

.mm-time-out-item {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 16px;
    border-radius: 10px;
    background: rgba(255,255,255,0.03);
    border: 1px solid var(--border);
}

.mm-time-out-item__label {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
}

.mm-time-out-item__val {
    font-size: 1.3rem;
    font-weight: 700;
    line-height: 1;
    letter-spacing: -0.02em;
}

/* Colour coding per column */
.mm-time-out-item--manual  .mm-time-out-item__val { color: #f87171; }  /* red — slow */
.mm-time-out-item--mm      .mm-time-out-item__val { color: var(--violet); } /* violet — fast */
.mm-time-out-item--saved   .mm-time-out-item__val { color: var(--amber); } /* amber — value */
.mm-time-out-item--saved { border-color: rgba(245,158,11,0.25); }

/* Toggle pills — asset type selector */
.mm-type-toggles {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.mm-type-toggle {
    padding: 6px 14px;
    border-radius: 20px;
    border: 1px solid var(--border);
    background: transparent;
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s, color 0.15s;
}

.mm-type-toggle.is-active {
    border-color: var(--amber);
    background: rgba(245, 158, 11, 0.08);
    color: var(--amber);
}

.mm-type-toggle:not(.is-active):hover {
    border-color: rgba(255,255,255,0.3);
    color: var(--text-secondary);
}

/* Footnote */
.mm-time-calc__footnote {
    font-size: 0.72rem;
    color: var(--text-muted);
    opacity: 0.6;
    line-height: 1.6;
    margin: 0;
}

/* ===================================================================
   PROOF MEDIA — ch.04 right column (placeholder + link)
   =================================================================== */
.mm-proof-media {
    display: flex;
    flex-direction: column;
    align-items: center;   /* centre the 9:16 video horizontally in its column */
    gap: 24px;
}

.mm-media-placeholder {
    border: 1px solid var(--border);
    border-radius: 12px;
    background: rgba(255,255,255,0.02);
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 9:16 phone-style video — mirrors campaign page hero sizing */
.mm-proof-video {
    width: clamp(180px, 18vw, 280px);
    aspect-ratio: 9 / 16;
    object-fit: cover;
    border-radius: 20px;
    border: 1px solid rgba(255,255,255,0.1);
    box-shadow:
        0 0 0 1px rgba(255,255,255,0.04),
        0 32px 64px rgba(0,0,0,0.7),
        0 0 80px rgba(255,255,255,0.03);
    display: block;
}

.mm-media-placeholder__inner {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.mm-media-placeholder__icon {
    font-size: 2rem;
    color: var(--text-muted);
    opacity: 0.4;
}

.mm-media-placeholder__label {
    font-size: 0.85rem;
    color: var(--text-muted);
    font-weight: 500;
    line-height: 1.5;
}

/* ===================================================================
   PHILOSOPHY CARDS — ch.05
   =================================================================== */
.pain-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

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

.pain-card {
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 32px 28px;
    background: rgba(255,255,255,0.02);
    transition: border-color 0.2s, background 0.2s;
}

.pain-card:hover { border-color: var(--border-strong); background: rgba(255,255,255,0.04); }

.pain-card__label {
    font-family: var(--font-mono);
    font-size: var(--fs-eyebrow);
    font-weight: 700;
    color: var(--text-muted);
    letter-spacing: 0.14em;
    text-transform: uppercase;
    margin-bottom: 16px;
}

.pain-card__divider { height: 1px; background: var(--border); margin-bottom: 20px; }

.pain-card__text {
    font-size: var(--fs-body);
    color: var(--text-secondary);
    line-height: 1.75;
}

/* ===================================================================
   RESPONSIVE
   =================================================================== */

/* Tablet ≤ 900px — collapse 2-col chapter grid to single column */
@media (max-width: 900px) {
    .mm-chapter__inner--grid {
        grid-template-columns: 1fr;
        gap: 48px;
    }

    /* Right column (visual/panel) stacks below text */
    .mm-chapter__right {
        order: 2;
    }

    .mm-chapter__left {
        order: 1;
    }
}

/* Tablet ≤ 900px — hero 2-col collapses, panel image hides */
@media (max-width: 900px) {
    .hero__inner { grid-template-columns: 1fr; }
    .hero__visual { display: none; }
}

/* Mobile ≤ 768px */
@media (max-width: 768px) {
    .hero                    { padding: 80px 24px 60px; }
    .mm-chapter              { padding: 64px 24px; }
    .mm-chapter--philosophy  { padding-bottom: 72px; }
    .mm-impact-stats         { gap: 24px; }

    /* Hero headline — fluid clamp in --fs-hero handles mobile sizing */

    /* Deliverables panel — stack columns vertically */
    .mm-deliverables {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    /* Proof stats (2×2 grid) — maintain 2 cols */
    .mm-proof-stats {
        gap: 20px;
    }
}

/* Small mobile ≤ 480px */
@media (max-width: 480px) {
    .hero                    { padding: 80px 20px 48px; }
    .mm-chapter              { padding: 48px 20px; }
    .mm-impact-stats         { flex-direction: column; gap: 20px; }

    /* Proof stats 2×2 → single column */
    .mm-proof-stats {
        grid-template-columns: 1fr;
    }
}

/* ── Click-to-play thumbnail component ───────────────────────────────────── */
.bb-vid-thumb {
    position: relative;
    cursor: pointer;
    border-radius: 20px;
    overflow: hidden;
}
.bb-vid-thumb__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    border-radius: inherit;
}
.bb-vid-thumb__play {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    cursor: pointer;
    transition: background 0.2s;
    padding: 0;
    border-radius: inherit;
}
.bb-vid-thumb__play:hover { background: rgba(0,0,0,0.18); }
.bb-vid-thumb__play svg  { width: 54px; height: 54px; filter: drop-shadow(0 2px 10px rgba(0,0,0,0.6)); }

