/* ==========================================================================
   Bukit Batok Halloween - Vanilla Static Stylesheet
   ========================================================================== */

:root {
    --font-family: "Minion Pro", Georgia, serif;
    --font-size-base: 1.125rem;
    --font-weight-base: 500;
    --line-height-base: 1.7;
    
    --page-max-width: 66rem;
    --entry-max-width: 44rem;
    --spacing-unit: 1.5rem;
    --border-radius: 8px;

    /* Default Flat Black Dark Theme Palette */
    --color-bg: #000000;
    --color-surface: #111827;
    --color-surface-border: #1F2937;
    --color-text: #E5E7EB;
    --color-text-muted: #9CA3AF;
    --color-headings: #F9FAFB;
    --color-primary: #F87171;
    --color-primary-hover: #EF4444;
    --color-accent: #FB923C;
    --color-header-bg: rgba(0, 0, 0, 0.95);
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.5);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.4), 0 2px 4px -1px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.5), 0 4px 6px -2px rgba(0, 0, 0, 0.3);
}

/* Base Resets */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 100%;
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    background-color: var(--color-bg);

}

body {
    font-family: var(--font-family);
    font-size: var(--font-size-base);
    font-weight: var(--font-weight-base);
    line-height: var(--line-height-base);
    color: var(--color-text);
    background-color: var(--color-bg);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
}

/* Layout Containers */
.wrapper {
    width: 100%;
    max-width: var(--page-max-width);
    margin-left: auto;
    margin-right: auto;
    padding-left: 1.5rem;
    padding-right: 1.5rem;
}

.entry-wrapper {
    max-width: var(--entry-max-width);
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    color: var(--color-headings);
    font-weight: 700;
    line-height: 1.25;
    margin-bottom: 1rem;
}

h1 {
    font-size: clamp(2rem, 5vw, 3.25rem);
    letter-spacing: -0.025em;
}

h2 {
    font-size: clamp(1.5rem, 3.5vw, 2rem);
    letter-spacing: -0.02em;
    margin-top: 2rem;
}

p {
    margin-bottom: 1.25rem;
}

a {
    color: var(--color-primary);
    text-decoration: underline;
    transition: color 0.2s ease;
}

a:hover {
    color: var(--color-primary-hover);
    text-decoration: underline;
}

a:focus-visible, button:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
}

strong {
    font-weight: 700;
    text-decoration: underline;
    color: var(--color-text);
}

/* Header & Navigation */
.top {
    position: sticky;
    top: 0;
    z-index: 100;
    background-color: var(--color-header-bg);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--color-surface-border);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.top.sticky {
    box-shadow: var(--shadow-sm);
}

.top__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 4.5rem;
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--color-headings);
    text-decoration: none;
    letter-spacing: -0.01em;
}

.logo__icon {
    width: 1.5rem;
    height: 1.5rem;
    flex-shrink: 0;
}

.logo:hover {
    color: var(--color-primary);
    text-decoration: none;
}

/* Main Content & Hero */
.page {
    flex: 1 0 auto;
}

.hero {
    padding: 3.5rem 0 2.5rem;
    background-color: var(--color-bg);
    border-bottom: 1px solid var(--color-surface-border);
    text-align: center;
}

.hero__content {
    margin: 0 auto;
}

.hero__illustration {
    margin-bottom: 1.25rem;
    display: flex;
    justify-content: center;
}

.pumpkin-art {
    width: 104px;
    height: 104px;
    max-width: 100%;
    transition: transform 0.25s ease;
}

.pumpkin-art:hover {
    transform: scale(1.05) rotate(-1.5deg);
}

.hero__subtitle {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--color-accent);
    margin-top: 0.5rem;
    margin-bottom: 0;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.hero__date {
    font-size: 1rem;
    color: var(--color-text-muted);
    margin-top: 0.5rem;
    margin-bottom: 0;
}

/* In-Page Section Navigation */
.section-nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.35rem 0.5rem;
    padding: 1rem 1.25rem;
    margin-bottom: 2.5rem;
    background-color: var(--color-surface);
    border: 1px solid var(--color-surface-border);
    border-radius: var(--border-radius);
    font-size: 0.95rem;
    line-height: 1.5;
    text-align: center;
}

.section-nav a {
    color: var(--color-primary);
    font-weight: 600;
    white-space: nowrap;
    padding: 0.2rem 0.35rem;
    border-radius: 4px;
    transition: color 0.15s ease, background-color 0.15s ease;
}

.section-nav a:hover {
    color: var(--color-primary-hover);
    background-color: rgba(248, 113, 113, 0.12);
    text-decoration: none;
}

.nav-sep {
    color: var(--color-text-muted);
    opacity: 0.5;
    user-select: none;
}

/* Content Sections */
.content-section {
    margin-bottom: 2.75rem;
}

.content-section:last-child {
    margin-bottom: 1rem;
}

.content-section h2 {
    scroll-margin-top: 5.5rem;
    padding-bottom: 0.35rem;
    border-bottom: 1px solid var(--color-surface-border);
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.content-section ul {
    margin-top: 0.5rem;
    margin-bottom: 1.25rem;
    padding-left: 1.5rem;
}

.content-section ul li {
    margin-bottom: 0.5rem;
    line-height: var(--line-height-base);
}

.content-section small {
    display: inline-block;
    color: var(--color-text-muted);
    font-size: 0.875rem;
    line-height: 1.5;
    margin-top: -0.5rem;
    margin-bottom: 1rem;
}

.retro-note {
    margin-top: 2rem;
    padding-top: 1.25rem;
    border-top: 1px dashed var(--color-surface-border);
    font-style: italic;
    color: var(--color-text-muted);
    font-size: 0.9375rem;
}

/* Disclaimer Callout */
.disclaimer-card {
    background-color: var(--color-surface);
    border: 1px solid var(--color-surface-border);
    border-left: 4px solid var(--color-accent);
    border-radius: var(--border-radius);
    padding: 1.25rem 1.5rem;
    margin-top: 1rem;
}

.disclaimer-card p {
    margin-bottom: 0;
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--color-text);
}

/* Add to Calendar Widget */
.atc-wrap {
    background-color: var(--color-surface);
    border: 1px solid var(--color-surface-border);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    width: 100%;
    max-width: 360px;
    text-align: center;
    margin: 1.75rem auto 2rem;
    box-shadow: var(--shadow-md);
}

.atc-event-date {
    display: block;
    font-size: 0.8125rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--color-accent);
    margin-bottom: 0.25rem;
}

.atc-event h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--color-headings);
    margin: 0.25rem 0 1.25rem;
}

.atc-menu-wrap {
    position: relative;
    display: block;
    width: 100%;
}

.atc-trigger {
    width: 100%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    background-color: var(--color-primary);
    color: #FFFFFF;
    border: none;
    border-radius: 6px;
    padding: 0.75rem 1rem;
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s ease, transform 0.1s ease;
}

.atc-trigger:hover {
    background-color: var(--color-primary-hover);
}

.atc-trigger:active {
    transform: translateY(1px);
}

.atc-caret {
    margin-left: 2px;
    transition: transform 0.2s ease;
}

.atc-menu-wrap.open .atc-caret {
    transform: rotate(180deg);
}

.atc-menu {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    background-color: var(--color-bg);
    border: 1px solid var(--color-surface-border);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    padding: 0.5rem;
    z-index: 50;
    opacity: 0;
    transform: translateY(-6px) scale(0.98);
    transform-origin: top center;
    pointer-events: none;
    transition: opacity 0.15s ease, transform 0.15s ease;
}

.atc-menu-wrap.open .atc-menu {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: all;
}

.atc-menu a {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.625rem 0.75rem;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--color-text);
    text-decoration: none;
    transition: background-color 0.15s ease, color 0.15s ease;
    text-align: left;
}

.atc-menu a:hover {
    background-color: var(--color-surface);
    color: var(--color-primary);
    text-decoration: none;
}

.atc-ico {
    font-size: 1rem;
    width: 1.25rem;
    text-align: center;
    flex-shrink: 0;
}

/* Entry Content Wrapper */
.content__entry {
    padding: 2.5rem 1.5rem 4rem;
    margin: 0 auto;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: var(--border-radius);
    color: #FFFFFF;
    background-color: var(--color-primary);
    border: 1px solid transparent;
    cursor: pointer;
    text-decoration: none;
    transition: background-color 0.2s ease, transform 0.1s ease;
}

.btn:hover {
    background-color: var(--color-primary-hover);
    color: #FFFFFF;
    text-decoration: none;
    transform: translateY(-1px);
}

.btn:active {
    transform: translateY(0);
}

/* 404 Error Page */
.page--error .content {
    text-align: center;
}

.page--error .hero {
    background: none;
    border-bottom: none;
    padding: 5rem 0 1rem;
}

.page--error .entry-wrapper {
    text-align: center;
    padding-top: 1rem;
}

/* Footer */
.footer {
    flex-shrink: 0;
    border-top: 1px solid var(--color-surface-border);
    background-color: var(--color-surface);
    padding: 2rem 0;
    margin-top: auto;
}

.footer__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer__copyright {
    font-size: 0.9375rem;
    color: var(--color-text-muted);
}

.footer__bttop {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background-color: var(--color-bg);
    color: var(--color-headings);
    border: 1px solid var(--color-surface-border);
    cursor: pointer;
    box-shadow: var(--shadow-sm);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease, background-color 0.2s ease, transform 0.2s ease;
}

.footer__bttop.is-visible {
    opacity: 1;
    visibility: visible;
}

.footer__bttop:hover {
    background-color: var(--color-primary);
    color: #FFFFFF;
    border-color: var(--color-primary);
    transform: translateY(-2px);
}

.join-in {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.join-in-button {
    padding: 0.5rem 1rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: var(--border-radius);
    color: #FFFFFF;
    background-color: var(--color-primary);

    :hover {
    background-color: var(--color-primary-hover);
}
}



/* Progressive Image Loading */
img[loading] {
    opacity: 0;
    transition: opacity 0.3s ease;
}

img[loading].is-loaded {
    opacity: 1;
}

/* Print Styles */
@media print {
    .top, .footer, #backToTop {
        display: none;
    }

    body {
        background: #FFFFFF;
        color: #000000;
    }
}

@media (max-width: 800px) {
    p {
        text-align: justify;
    }
}

/* ==========================================================================
   Halloween Flip Countdown Timer
   ========================================================================== */

.countdown-section {
    margin-top: 1.75rem;
    margin-bottom: 0.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.countdown-title {
    font-size: 0.95rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--color-accent);
    margin-bottom: 0.85rem;
    text-shadow: 0 0 12px rgba(251, 146, 60, 0.4);
}

.countdown-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.85rem;
    flex-wrap: nowrap;
}

.countdown-segment {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.countdown-label {
    margin-top: 0.5rem;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--color-text-muted);
}

/* Flip Card Structure */
.flip-card {
    position: relative;
    width: 68px;
    height: 76px;
    perspective: 400px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 2.25rem;
    font-weight: 800;
    line-height: 1;
    border-radius: 6px;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.6), 0 0 15px rgba(126, 34, 206, 0.25);
}

/* Half card panels */
.card-top,
.card-bottom,
.card-back-top,
.card-back-bottom {
    position: absolute;
    left: 0;
    right: 0;
    height: 50%;
    overflow: hidden;
    background-color: #161622;
    color: #fb923c;
    text-shadow: 0 0 10px rgba(251, 146, 60, 0.5);
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

.card-top,
.card-back-top {
    top: 0;
    border-top-left-radius: 6px;
    border-top-right-radius: 6px;
    border-top: 1px solid rgba(251, 146, 60, 0.3);
    border-left: 1px solid rgba(251, 146, 60, 0.15);
    border-right: 1px solid rgba(251, 146, 60, 0.15);
    border-bottom: 1px solid rgba(0, 0, 0, 0.6);
    background: linear-gradient(180deg, #1f1f2e 0%, #161622 100%);
}

.card-bottom,
.card-back-bottom {
    top: 50%;
    border-bottom-left-radius: 6px;
    border-bottom-right-radius: 6px;
    border-bottom: 1px solid rgba(126, 34, 206, 0.4);
    border-left: 1px solid rgba(251, 146, 60, 0.15);
    border-right: 1px solid rgba(251, 146, 60, 0.15);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    background: linear-gradient(180deg, #12121c 0%, #0d0d14 100%);
}

/* Digits positioning inside halves */
.card-top .digit,
.card-back-top .digit {
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    height: 76px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-bottom .digit,
.card-back-bottom .digit {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 76px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 3D Flip Layers & Origin */
.card-top {
    z-index: 2;
    transform-origin: bottom;
}

.card-bottom {
    z-index: 1;
}

.card-back-top {
    z-index: 1;
}

.card-back-bottom {
    z-index: 2;
    transform-origin: top;
    transform: rotateX(90deg);
}

/* Flip Animations */
.flip-card.flip .card-top {
    animation: flipTop 0.25s ease-in forwards;
}

.flip-card.flip .card-back-bottom {
    animation: flipBottom 0.25s ease-out 0.25s forwards;
}

@keyframes flipTop {
    0% {
        transform: rotateX(0deg);
    }
    100% {
        transform: rotateX(-90deg);
    }
}

@keyframes flipBottom {
    0% {
        transform: rotateX(90deg);
    }
    100% {
        transform: rotateX(0deg);
    }
}

/* Middle Crease line */
.flip-card::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: calc(50% - 0.5px);
    height: 1px;
    background: rgba(0, 0, 0, 0.8);
    z-index: 5;
    pointer-events: none;
}

/* Expired / Celebration message */
.countdown-message {
    padding: 1rem 1.5rem;
    font-size: 1.25rem;
    font-weight: 700;
    color: #fb923c;
    background: rgba(22, 22, 34, 0.85);
    border: 1px solid rgba(251, 146, 60, 0.4);
    border-radius: var(--border-radius);
    box-shadow: 0 0 20px rgba(251, 146, 60, 0.25);
    text-shadow: 0 0 10px rgba(251, 146, 60, 0.6);
    margin-top: 0.5rem;
}

/* Responsiveness */
@media (max-width: 600px) {
    .countdown-container {
        gap: 0.5rem;
    }

    .flip-card {
        width: 54px;
        height: 62px;
        font-size: 1.75rem;
    }

    .card-top .digit,
    .card-back-top .digit,
    .card-bottom .digit,
    .card-back-bottom .digit {
        height: 62px;
    }

    .countdown-label {
        font-size: 0.7rem;
    }
}

@media (max-width: 380px) {
    .countdown-container {
        gap: 0.35rem;
    }

    .flip-card {
        width: 44px;
        height: 52px;
        font-size: 1.4rem;
        border-radius: 4px;
    }

    .card-top .digit,
    .card-back-top .digit,
    .card-bottom .digit,
    .card-back-bottom .digit {
        height: 52px;
    }

    .countdown-label {
        font-size: 0.625rem;
        margin-top: 0.35rem;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    .flip-card.flip .card-top,
    .flip-card.flip .card-back-bottom {
        animation: none !important;
    }
    .card-back-bottom {
        transform: rotateX(0deg);
    }
}

/* ==========================================================================
   Camera (Photo Booth & Ghost Hunt) - uses the site typography/colours above
   ========================================================================== */

/* Camera colour aliases point at the shared palette (single source of truth) */
:root {
    --cam-bg: var(--color-bg);
    --cam-text: var(--color-text);
    --cam-accent: var(--color-accent);
    --cam-primary: var(--color-primary);
    --cam-primary-hover: var(--color-primary-hover);
    --cam-panel: rgba(17, 24, 39, 0.85);
}

/* The intro/stage/review sections set display via their class rules, which
   would override the `hidden` attribute. Keep `hidden` authoritative so the
   JS show/hide logic works. */
[hidden] { display: none !important; }

.camera-page { overflow: hidden; }

/* Intro (headings and body text inherit the site styles above) */
.intro { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 1.5rem; text-align: center; }
.intro__inner { max-width: 28rem; }
.intro p { margin-bottom: 1rem; }
.intro__note { font-size: 0.9rem; color: var(--color-text-muted); }
.intro__error { color: var(--cam-primary); min-height: 1.5rem; margin-top: 1rem; }
.intro__back { display: inline-block; margin-top: 1.5rem; color: var(--cam-accent); }

/* Buttons */
.cam-btn { display: inline-flex; align-items: center; justify-content: center; padding: 0.8rem 1.6rem; font-size: 1rem; font-weight: 600; border: 1px solid #374151; border-radius: 8px; background: #111827; color: var(--cam-text); cursor: pointer; }
.cam-btn--primary { background: var(--cam-primary); border-color: var(--cam-primary); color: #fff; }
.cam-btn--primary:active { background: var(--cam-primary-hover); }
.cam-icon-btn { display: inline-flex; align-items: center; justify-content: center; width: 2.75rem; height: 2.75rem; border-radius: 50%; background: rgba(0,0,0,0.5); color: #fff; border: none; font-size: 1.4rem; text-decoration: none; cursor: pointer; }

/* Stage */
.stage { position: fixed; inset: 0; background: #000; }
.stage__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.stage__overlays { position: absolute; inset: 0; pointer-events: none; }
.stage__top { position: absolute; top: 0; left: 0; right: 0; display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; padding: calc(env(safe-area-inset-top) + 0.75rem) 0.75rem 0.75rem; }
.stage__bottom { position: absolute; bottom: 0; left: 0; right: 0; display: flex; align-items: center; justify-content: center; padding: 0.75rem 0.75rem calc(env(safe-area-inset-bottom) + 1.25rem); }

.mode-switch { display: flex; background: rgba(0,0,0,0.5); border-radius: 999px; padding: 0.2rem; }
.mode-switch__btn { border: none; background: transparent; color: #fff; padding: 0.4rem 0.9rem; border-radius: 999px; font-size: 0.85rem; font-weight: 600; cursor: pointer; }
.mode-switch__btn.is-active { background: var(--cam-primary); }

.shutter { width: 4.5rem; height: 4.5rem; border-radius: 50%; background: #fff; border: 4px solid rgba(255,255,255,0.5); cursor: pointer; }
.shutter:active { transform: scale(0.94); }

.mode-panel { position: absolute; left: 0; right: 0; bottom: 6.5rem; padding: 0 0.75rem; }

/* Review */
.review { position: fixed; inset: 0; background: #000; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 1rem; gap: 1rem; }
.review__img { max-width: 100%; max-height: 72vh; border-radius: 8px; }
.review__actions { display: flex; gap: 1rem; }
.review__hint { color: #9CA3AF; font-size: 0.9rem; text-align: center; }

/* 'fill' stretches the frame to the viewport exactly as capture.js stretches
   it onto the saved canvas, so the live preview matches the saved photo. */
.booth-frame-overlay { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: fill; }
.booth-frames { display: flex; gap: 0.5rem; overflow-x: auto; padding: 0.5rem; background: var(--cam-panel); border-radius: 10px; margin-bottom: 0.5rem; }
.booth-chip { flex: 0 0 auto; padding: 0.5rem 0.9rem; border-radius: 999px; border: 1px solid #374151; background: #111827; color: #fff; font-size: 0.85rem; cursor: pointer; }
.booth-chip[aria-pressed="true"] { background: var(--cam-accent); border-color: var(--cam-accent); color: #111; }

.hunt-detector { background: var(--cam-panel); border-radius: 10px; padding: 0.75rem 1rem; }
.hunt-meter { height: 0.6rem; background: rgba(255,255,255,0.15); border-radius: 999px; overflow: hidden; }
.hunt-meter__fill { height: 100%; width: 0%; background: linear-gradient(90deg, #60A5FA, var(--cam-accent), var(--cam-primary)); transition: width 0.4s ease; }
.hunt-status { margin-top: 0.5rem; font-size: 0.9rem; text-align: center; }

.ghost-sprite {
  position: absolute;
  width: 40%;
  transform: translate(-50%, -50%) scale(var(--scale, 1));
  pointer-events: none;
  filter: drop-shadow(0 0 12px rgba(180, 220, 255, 0.5));
  animation: ghost-bob 3s ease-in-out infinite, ghost-flicker 2.4s ease-in-out infinite;
}

@keyframes ghost-bob {
  0%, 100% { margin-top: -0.6rem; }
  50% { margin-top: 0.6rem; }
}

@keyframes ghost-flicker {
  0%, 100% { opacity: 0.92; }
  50% { opacity: 0.7; }
}

.ghost-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0,0,0,0.6);
  color: #fff;
  padding: 0.4rem 0.7rem;
  border-radius: 999px;
  font-size: 0.85rem;
}

/* Hidden ghost size tuner (enabled via /camera/#ghostdebug) */
.ghost-debug { margin-top: 0.5rem; background: rgba(0,0,0,0.82); border: 1px solid var(--cam-accent); border-radius: 10px; padding: 0.5rem 0.6rem; }
.ghost-debug__title { color: var(--cam-accent); font-weight: 700; font-size: 0.72rem; letter-spacing: 0.02em; margin-bottom: 0.45rem; }
.ghost-debug__row { display: flex; align-items: center; gap: 0.5rem; margin: 0.3rem 0; }
.ghost-debug__label { flex: 1; color: #E5E7EB; font-size: 0.85rem; }
.ghost-debug__val { min-width: 3.2ch; text-align: center; color: #FDBA74; font-weight: 700; font-variant-numeric: tabular-nums; }
.ghost-debug button { width: 2.2rem; height: 2.2rem; border-radius: 6px; border: 1px solid #374151; background: #111827; color: #fff; font-size: 1.2rem; line-height: 1; cursor: pointer; }
.ghost-debug__pick { margin-top: 0.5rem; width: 100%; padding: 0.4rem; border-radius: 6px; border: 1px solid var(--cam-accent); background: #111827; color: #fff; font-size: 0.85rem; }
