/* ==========================================================================
   LATIN DANCE MN - INSTAGRAM REEL FLYER STYLESHEET
   ========================================================================== */

/* Design System Variables (Aligned with main site) */
:root {
    --bg-dark: hsl(260, 40%, 7%);
    --bg-darker: hsl(260, 45%, 4%);
    
    --accent-gold: hsl(45, 100%, 53%);
    --accent-pink: hsl(345, 95%, 60%);
    --accent-teal: hsl(155, 100%, 42%);
    --accent-purple: hsl(270, 75%, 50%);
    --accent-green: hsl(130, 80%, 45%);
    
    --text-light: hsl(20, 15%, 96%);
    --text-muted: hsl(260, 15%, 70%);
    
    /* Glassmorphism (Darker, more readable overlays over video) */
    --glass-bg: rgba(10, 8, 16, 0.82);
    --glass-border: rgba(255, 255, 255, 0.15);
    --glass-border-gold: rgba(255, 215, 0, 0.35);
    --glass-border-pink: rgba(255, 20, 147, 0.35);
    --glass-shadow: rgba(0, 0, 0, 0.8);
    --backdrop-blur: blur(32px);

    /* Fonts (Montserrat and Poppins for optimal readability) */
    --font-headers: 'Montserrat', sans-serif;
    --font-body: 'Poppins', sans-serif;
}

/* Base resets & layout */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-darker);
    color: var(--text-light);
    height: 100vh;
    display: flex;
    overflow: hidden;
    position: relative;
}

/* Ambient Background Glows */
.ambient-glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(120px);
    z-index: 1;
    pointer-events: none;
    opacity: 0.2;
}

.glow-1 {
    width: 600px;
    height: 600px;
    background: var(--accent-purple);
    top: -10%;
    left: -10%;
}

.glow-2 {
    width: 500px;
    height: 500px;
    background: var(--accent-gold);
    bottom: -10%;
    right: -10%;
}

/* ==========================================================================
   SIDEBAR CONTROL PANEL
   ========================================================================== */
.control-panel {
    width: 380px;
    background-color: rgba(10, 8, 16, 0.85);
    border-right: 1px solid var(--glass-border);
    backdrop-filter: blur(20px);
    padding: 30px;
    display: flex;
    flex-direction: column;
    gap: 30px;
    z-index: 10;
    overflow-y: auto;
}

.panel-header {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.back-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: color 0.2s ease;
}

.back-btn:hover {
    color: var(--accent-gold);
}

.control-panel h1 {
    font-family: var(--font-headers);
    font-size: 24px;
    font-weight: 800;
    letter-spacing: 0.5px;
    background: linear-gradient(135deg, var(--text-light) 30%, var(--text-muted) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.panel-header .subtitle {
    font-size: 14px;
    color: var(--accent-gold);
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.panel-section {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.panel-section h2 {
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding-bottom: 8px;
}

/* Buttons */
.btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 14px 20px;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent-pink) 0%, var(--accent-purple) 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(219, 31, 106, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(219, 31, 106, 0.5);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    color: var(--text-light);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
}

.help-text {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.4;
}

kbd {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    padding: 2px 6px;
    font-size: 10px;
    font-family: monospace;
}

/* Zoom controls */
.zoom-controls {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 6px;
}

.btn-zoom {
    padding: 8px 0;
    font-size: 12px;
    font-weight: 500;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    color: var(--text-muted);
    cursor: pointer;
    text-align: center;
    transition: all 0.2s ease;
}

.btn-zoom:hover, .btn-zoom.active {
    background: var(--accent-gold);
    color: var(--bg-darker);
    border-color: var(--accent-gold);
    font-weight: 600;
}

/* Instructions list */
.instructions ol {
    margin-left: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    font-size: 13px;
    color: var(--text-muted);
    line-height: 1.5;
}

.instructions code {
    background: rgba(255, 255, 255, 0.08);
    padding: 2px 5px;
    border-radius: 4px;
    color: var(--accent-gold);
    font-family: monospace;
}

.panel-footer {
    margin-top: auto;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.2);
    text-align: center;
}

/* ==========================================================================
   WORKSPACE PREVIEW AREA
   ========================================================================== */
.workspace {
    flex-grow: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #050407;
    background-image: 
        radial-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 0),
        radial-gradient(rgba(255, 255, 255, 0.02) 2px, transparent 0);
    background-size: 24px 24px, 120px 120px;
    position: relative;
    overflow: auto;
    z-index: 5;
    padding: 50px;
}

/* Canvas Scaler Container */
.canvas-container {
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(255, 255, 255, 0.05);
    border-radius: 40px;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    transform-origin: center center;
    background: var(--bg-darker);
    overflow: hidden;
}

/* ==========================================================================
   THE INSTAGRAM REEL CANVAS (9:16 - 1080x1920)
   ========================================================================== */
.reel-canvas {
    width: 1080px;
    height: 1920px;
    position: relative;
    overflow: hidden;
    background-color: black;
}

/* Video background and masks */
#bgVideo {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 2;
    transition: opacity 0.5s ease;
}

.video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        to bottom,
        rgba(10, 8, 16, 0.55) 0%,
        rgba(10, 8, 16, 0.2) 40%,
        rgba(10, 8, 16, 0.3) 65%,
        rgba(10, 8, 16, 0.85) 100%
    );
    z-index: 3;
    pointer-events: none;
}

/* Fallback animated gradient */
.animated-gradient {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, 
        hsl(260, 45%, 8%) 0%,
        hsl(135, 60%, 12%) 35%,
        hsl(45, 70%, 15%) 70%,
        hsl(260, 45%, 8%) 100%
    );
    background-size: 300% 300%;
    z-index: 1;
    animation: gradientShift 16s ease infinite;
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Additional glowing orbs inside canvas for ambient depth */
.canvas-glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.35;
    z-index: 4;
    pointer-events: none;
}

.glow-top-left {
    width: 450px;
    height: 450px;
    background: var(--accent-teal);
    top: 15%;
    left: -10%;
}

.glow-bottom-right {
    width: 500px;
    height: 500px;
    background: var(--accent-gold);
    bottom: 10%;
    right: -10%;
}

/* ==========================================================================
   FLYER CONTENT LAYER
   ========================================================================== */
.flyer-content {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 5;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 95px 75px;
    pointer-events: none; /* Make record mode completely clean of mouse pointers */
}

/* Header section */
.flyer-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
}

.location-badge {
    background: rgba(10, 8, 16, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(16px);
    border-radius: 50px;
    padding: 12px 30px;
    font-size: 22px;
    font-weight: 700;
    letter-spacing: 2px;
    color: var(--text-light);
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.location-badge i {
    width: 22px;
    height: 22px;
    color: var(--accent-gold);
}

.logo-backdrop {
    background: rgba(255, 255, 255, 0.95);
    padding: 15px 45px;
    border-radius: 25px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--accent-gold);
    margin-top: 10px;
}

.brand-logo {
    height: 120px;
    object-fit: contain;
}

/* Body Section: Titles & Event Details */
.flyer-body {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
}

.series-tag {
    font-family: var(--font-body);
    font-size: 24px;
    font-weight: 800;
    letter-spacing: 8px;
    color: var(--accent-gold);
    text-transform: uppercase;
    text-shadow: 0 4px 10px rgba(0,0,0,0.8);
    animation: fadeIn 1s ease forwards;
}

.title-forro {
    font-family: var(--font-headers);
    font-size: 165px;
    font-weight: 900;
    line-height: 0.95;
    letter-spacing: -2px;
    text-align: center;
    background: linear-gradient(135deg, #00ff55 0%, #ffdf00 65%, #ffffff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.9));
    margin-top: 5px;
}

.title-sub {
    font-family: var(--font-headers);
    font-size: 48px;
    font-weight: 900;
    letter-spacing: 4px;
    color: var(--text-light);
    text-align: center;
    text-shadow: 0 6px 15px rgba(0, 0, 0, 0.95), 0 2px 4px rgba(0, 0, 0, 0.9);
    margin-bottom: 30px;
}

/* Details Cards */
.details-grid {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
    max-width: 820px;
}

.glass-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    backdrop-filter: var(--backdrop-blur);
    border-radius: 20px;
    box-shadow: 0 15px 35px var(--glass-shadow);
}

.detail-card {
    display: flex;
    align-items: center;
    gap: 28px;
    padding: 28px 36px;
    position: relative;
    overflow: hidden;
}

/* Glowing border hover effect inside canvas */
.detail-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 6px;
    height: 100%;
    background: var(--accent-gold);
}

.card-icon {
    width: 76px;
    height: 76px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-icon i {
    width: 36px;
    height: 36px;
    color: var(--accent-gold);
}

.card-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.card-text .label {
    font-size: 16px;
    font-weight: 800;
    letter-spacing: 2px;
    color: var(--text-muted);
    text-transform: uppercase;
}

.card-text .value {
    font-size: 30px;
    font-weight: 700;
    color: var(--text-light);
    line-height: 1.2;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

.card-text .sub-value {
    font-size: 22px;
    color: var(--accent-gold);
    font-weight: 600;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

/* Pills (Free Parking & All Levels) */
.pills-container {
    display: flex;
    gap: 16px;
    margin-top: 15px;
}

.pill {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 15px 30px;
    border-radius: 50px;
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 1px;
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}

.pill-green {
    background: rgba(0, 156, 59, 0.15);
    border: 1px solid rgba(0, 156, 59, 0.4);
    color: #39ff7a;
}

.pill-green i {
    width: 22px;
    height: 22px;
    color: #39ff7a;
}

.pill-gold {
    background: rgba(255, 223, 0, 0.12);
    border: 1px solid rgba(255, 223, 0, 0.35);
    color: var(--accent-gold);
}

.pill-gold i {
    width: 22px;
    height: 22px;
    color: var(--accent-gold);
}

/* Footer Section: CTA / Register link */
.flyer-footer {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
    width: 100%;
}

.call-to-action {
    width: 100%;
    max-width: 820px;
    padding: 24px 35px;
    background: rgba(15, 10, 24, 0.9);
    border: 1px solid rgba(219, 31, 106, 0.45);
    position: relative;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.8);
}

.call-to-action::after {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: 20px;
    padding: 2px;
    background: linear-gradient(135deg, var(--accent-pink), var(--accent-purple));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
    opacity: 0.9;
}

.cta-header {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 2px;
    color: var(--accent-pink);
    margin-bottom: 8px;
    text-transform: uppercase;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.cta-header i {
    width: 18px;
    height: 18px;
}

.cta-message {
    font-size: 24px;
    font-weight: 600;
    color: var(--text-light);
    line-height: 1.4;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8);
}

.cta-message .highlight {
    color: #fff;
    font-weight: 800;
    border-bottom: 2px solid var(--accent-pink);
    padding-bottom: 2px;
}

.website-promo {
    background: linear-gradient(135deg, var(--accent-gold) 0%, #ffdf00 100%);
    padding: 18px 50px;
    border-radius: 50px;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-shadow: 0 12px 30px rgba(255, 215, 0, 0.45), 0 0 0 5px rgba(255, 215, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    margin-top: 10px;
}

.promo-label {
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 3px;
    color: rgba(0, 0, 0, 0.7);
    text-transform: uppercase;
}

.promo-url {
    font-family: var(--font-headers);
    font-size: 36px;
    font-weight: 900;
    color: #000;
    letter-spacing: 0.5px;
    text-shadow: none;
    animation: textGlowPulse 2.5s infinite ease-in-out;
}

/* ==========================================================================
   ANIMATIONS
   ========================================================================== */
@keyframes textGlowPulse {
    0%, 100% {
        text-shadow: 0 4px 15px rgba(255, 215, 0, 0.2);
        transform: scale(1);
    }
    50% {
        text-shadow: 0 4px 30px rgba(255, 215, 0, 0.5);
        transform: scale(1.02);
    }
}

.animate-fade-in {
    opacity: 0;
    animation: fadeIn 1.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.animate-slide-up {
    opacity: 0;
    transform: translateY(40px);
    animation: slideUp 1.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.animate-pulse {
    animation: pulseGlow 2s infinite ease-in-out;
}

@keyframes fadeIn {
    to { opacity: 1; }
}

@keyframes slideUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulseGlow {
    0%, 100% {
        opacity: 1;
        box-shadow: 0 8px 24px rgba(0, 156, 59, 0.2);
    }
    50% {
        opacity: 0.85;
        box-shadow: 0 8px 32px rgba(0, 156, 59, 0.5);
    }
}

/* ==========================================================================
   RECORDING MODE (FULLSCREEN LAYOUT OVERRIDE)
   ========================================================================== */
body.record-mode .control-panel {
    display: none;
}

body.record-mode .workspace {
    padding: 0;
    background: black;
    overflow: visible;
}

body.record-mode .canvas-container {
    border-radius: 0;
    box-shadow: none;
}
