/* Cinematic Presentation Mode */
:root {
    --pres-bg: #0a0a0a;
    --pres-accent: var(--accent, #F7C85C);
    --pres-glass: rgba(255, 255, 255, 0.05);
    --pres-blur: blur(15px);
}

body.presentation-active {
    overflow: hidden !important;
    height: 100vh !important;
    width: 100vw !important;
    background: var(--pres-bg) !important;
    perspective: 1200px;
}

body.presentation-active main {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
}

/* Slide Transition Animations */
body.presentation-active section,
body.presentation-active .hero-slider,
body.presentation-active .pres-chunk {
    height: 100vh !important;
    width: 100vw !important;
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: absolute;
    top: 0;
    left: 0;
    margin: 0 !important;
    padding: 100px !important;
    background-size: cover !important;
    background-position: center !important;
    transition: all 0.7s cubic-bezier(0.6, 0.05, 0.01, 0.9);
    transform-style: preserve-3d;
    overflow: hidden;
}

/* Standard slide hidden state: Scaled down and tilted */
body.presentation-active section:not(.active-slide),
body.presentation-active .hero-slider:not(.active-slide),
body.presentation-active .pres-chunk:not(.active-slide) {
    opacity: 0;
    transform: scale(0.9) translateY(100px) rotateX(10deg);
    pointer-events: none;
}

/* Active slide state */
body.presentation-active section.active-slide,
body.presentation-active .hero-slider.active-slide,
body.presentation-active .pres-chunk.active-slide {
    display: flex !important;
    opacity: 1;
    transform: scale(1) translateY(0) rotateX(0deg);
    z-index: 10;
}

/* Internal Reveal Animations */
.active-slide .reveal-up {
    animation: presRevealUp 0.8s cubic-bezier(0.19, 1, 0.22, 1) forwards;
}

@keyframes presRevealUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Delay revealing children */
.active-slide h1, .active-slide .h1-pres { animation-delay: 0.2s; opacity: 0; animation-fill-mode: forwards; }
.active-slide p, .active-slide .p-pres { animation-delay: 0.4s; opacity: 0; animation-fill-mode: forwards; }
.active-slide .grid-pres, .active-slide .card-pres { animation-delay: 0.6s; opacity: 0; animation-fill-mode: forwards; }

body.presentation-active h1, 
body.presentation-active h2,
body.presentation-active .h1-pres {
    font-size: 4.5rem !important;
    font-weight: 800 !important;
    text-align: center;
    margin-bottom: 30px !important;
    color: var(--pres-accent) !important;
    text-transform: uppercase;
    letter-spacing: -1px;
    line-height: 1;
    text-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

body.presentation-active p,
body.presentation-active .p-pres {
    font-size: 1.8rem !important;
    text-align: center;
    max-width: 1000px;
    margin: 0 auto 40px !important;
    line-height: 1.4 !important;
    opacity: 0.8 !important;
    font-weight: 400;
}

/* Premium Controls - Glassmorphism */
.presentation-controls {
    position: fixed;
    bottom: -100px; /* Start off-screen */
    left: 50%;
    transform: translateX(-50%);
    z-index: 10000;
    display: flex;
    gap: 40px;
    align-items: center;
    background: rgba(15, 15, 15, 0.85);
    padding: 12px 35px;
    border-radius: 100px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    backdrop-filter: var(--pres-blur);
    box-shadow: 0 20px 50px rgba(0,0,0,0.6);
    opacity: 0;
    pointer-events: none;
    transition: all 0.6s cubic-bezier(0.19, 1, 0.22, 1);
}

body.presentation-active .presentation-controls {
    opacity: 1;
    bottom: 40px;
    pointer-events: auto;
}

.presentation-btn {
    background: none;
    border: none;
    color: white;
    font-size: 1.4rem;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.presentation-btn:hover {
    background: rgba(255,255,255,0.1);
    color: var(--pres-accent);
}

.exit-presentation {
    background: var(--pres-accent) !important;
    color: #000 !important;
    padding: 10px 25px !important;
    border-radius: 50px !important;
    font-weight: 800 !important;
    font-size: 0.75rem !important;
    margin-left: 10px !important;
    text-decoration: none;
}

/* Floating Action Button (FAB) */
.fab-present {
    position: fixed;
    bottom: 40px;
    right: 40px;
    width: 70px;
    height: 70px;
    background: var(--primary);
    color: var(--pres-accent);
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    cursor: pointer;
    z-index: 998;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 3px solid var(--pres-accent);
    text-decoration: none;
}

.fab-present:hover {
    transform: scale(1.1) translateY(-5px);
    background: var(--primary-dark);
}

.fab-present i {
    font-size: 1.6rem;
}

.fab-present span {
    font-size: 0.6rem;
    font-weight: 800;
    text-transform: uppercase;
    margin-top: 2px;
}

body.presentation-active .fab-present {
    display: none;
}

/* Progress Ring */
.pres-progress-container {
    position: relative;
    width: 50px;
    height: 50px;
}

.pres-progress-svg {
    transform: rotate(-90deg);
}

.pres-progress-bg {
    fill: none;
    stroke: rgba(255,255,255,0.1);
    stroke-width: 3;
}

.pres-progress-bar {
    fill: none;
    stroke: var(--pres-accent);
    stroke-width: 3;
    stroke-linecap: round;
    transition: stroke-dashoffset 0.5s ease;
}

/* Hide defaults */
body.presentation-active .top-bar,
body.presentation-active .header-main,
body.presentation-active footer,
body.presentation-active .news-ticker-container,
body.presentation-active .mobile-toggle {
    display: none !important;
}

/* Chunk styles for non-sectioned pages */
.pres-chunk {
    background: var(--pres-bg);
    color: white;
}
