/* ==========================================================================
   KRAFTOR - Premium Video Editing Portfolio (Neo-Lux Theme Redesign)
   ========================================================================== */

/* --- CSS Variables --- */
:root {
    --bg-color: #020204;            /* True cinematic deepest black */
    --bg-card: rgba(8, 8, 12, 0.7);  /* Dark glassmorphic background */
    
    --text-primary: #f8fafc;        /* High-contrast soft white */
    --text-secondary: #94a3b8;      /* Clean slate grey */
    
    /* Elegant Violet to Rose Accents */
    --accent: #818cf8;              /* Premium Indigo */
    --accent-gradient: linear-gradient(135deg, #6366f1 0%, #a855f7 50%, #ec4899 100%);
    --accent-glow: rgba(129, 140, 248, 0.2);
    
    --border-color: rgba(255, 255, 255, 0.04);
    --border-hover: rgba(129, 140, 248, 0.35);
    
    --font-main: 'Outfit', sans-serif;
    
    --cursor-size: 8px;
    --cursor-outline-size: 36px;
}

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

html {
    scroll-behavior: smooth;
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-main);
    overflow-x: hidden;
}

body {
    overflow-x: hidden;
    cursor: none; /* Hide default cursor for custom cursor */
}

a {
    color: inherit;
    text-decoration: none;
}

ul {
    list-style: none;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 6px;
}
::-webkit-scrollbar-track {
    background: var(--bg-color);
}
::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--accent);
}

/* --- Custom Cursor --- */
.cursor-dot, .cursor-outline {
    position: fixed;
    top: 0;
    left: 0;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    z-index: 9999;
    pointer-events: none;
    transition: width 0.2s, height 0.2s, background-color 0.2s;
}

.cursor-dot {
    width: var(--cursor-size);
    height: var(--cursor-size);
    background-color: var(--accent);
}

.cursor-outline {
    width: var(--cursor-outline-size);
    height: var(--cursor-outline-size);
    border: 1px solid rgba(255, 255, 255, 0.25);
    transition: width 0.2s, height 0.2s, background-color 0.2s, transform 0.08s ease-out;
}

.cursor-outline.hover {
    width: 48px;
    height: 48px;
    background-color: rgba(129, 140, 248, 0.12);
    border-color: var(--accent);
}

/* --- Cinematic Noise Overlay --- */
.noise-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    opacity: 0.02;
    pointer-events: none;
    z-index: 9998;
}

/* --- Ambient Glowing Orbs --- */
.bg-glow-orb {
    position: absolute;
    width: 50vw;
    height: 50vw;
    max-width: 600px;
    max-height: 600px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.07) 0%, rgba(168, 85, 247, 0.02) 55%, transparent 100%);
    filter: blur(120px);
    pointer-events: none;
    z-index: -1;
    transform: translate(-20%, -20%);
}

/* --- Hero Section (Floating Cinema Card) --- */
.hero {
    position: relative;
    height: 85vh;
    margin: 3rem 5rem;
    border-radius: 28px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 45px 120px rgba(0, 0, 0, 0.95), 0 0 80px rgba(99, 102, 241, 0.05);
}

.hero-video-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
}

.hero-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(2, 2, 4, 0.1) 0%, rgba(2, 2, 4, 0.8) 100%);
    z-index: -1;
}

/* Scroll Down Indicator */
.scroll-down {
    position: absolute;
    bottom: 35px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    opacity: 0.4;
    transition: opacity 0.3s;
    animation: bounce 2s infinite;
}

.scroll-down svg {
    color: white;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translate(-50%, 0); }
    40% { transform: translate(-50%, -10px); }
    60% { transform: translate(-50%, -5px); }
}

/* --- Section Formatting (Spacious & Clean Layout) --- */
.welcome-section,
.portfolio-section,
.showcase-section,
.about {
    position: relative;
    z-index: 2;
    overflow: hidden;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03); /* Thin premium division line */
}

.welcome-section {
    padding: 12rem 5rem 10rem 5rem;
    text-align: center;
}

.portfolio-section,
.showcase-section,
.about {
    padding: 10rem 5rem; /* Generous breathing room */
}

/* Container limits */
.welcome-container {
    max-width: 820px;
    margin: 0 auto;
}

.welcome-title {
    font-size: 4rem;
    font-weight: 800;
    letter-spacing: -1px;
    margin-bottom: 0.5rem;
}

.welcome-subtitle {
    font-size: 1.35rem;
    font-weight: 400;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 6px;
    margin-bottom: 2.5rem;
}

.welcome-desc {
    font-size: 1.2rem;
    line-height: 1.85;
    color: var(--text-secondary);
}

/* Accent Gradients */
.accent {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* --- Section Headers --- */
.section-header {
    max-width: 1200px;
    margin: 0 auto 4.5rem auto; /* Spaced out from content */
    padding: 0 1.5rem;
    position: relative;
}

.section-num {
    display: inline-block;
    font-family: monospace;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--accent);
    letter-spacing: 4px;
    margin-bottom: 1.2rem;
    padding: 0.3rem 0.8rem;
    background: rgba(129, 140, 248, 0.07);
    border: 1px solid rgba(129, 140, 248, 0.15);
    border-radius: 4px;
}

.section-header h2 {
    font-size: 3.2rem;
    font-weight: 800;
    letter-spacing: -0.5px;
    margin-bottom: 1rem;
}

.section-header p {
    font-size: 1.15rem;
    color: var(--text-secondary);
}

/* --- Sliders for Reels --- */
.reels-slider-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
    padding: 0 1.5rem;
}

.reels-slider {
    display: flex;
    gap: 2.2rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    padding: 1.5rem 0;
    scroll-behavior: smooth;
}

.reels-slider::-webkit-scrollbar {
    display: none;
}

/* --- Reel Cards (9:16 Aspect Ratio) --- */
.project-item.vertical {
    flex: 0 0 auto;
    width: 290px;
    height: 516px;
    scroll-snap-align: start;
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(12px);
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1), 
                border-color 0.5s, 
                box-shadow 0.5s;
}

.project-item.vertical:hover {
    transform: translateY(-12px) scale(1.025);
    border-color: var(--border-hover);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.8), 0 0 40px rgba(129, 140, 248, 0.2);
}

.project-video-container {
    width: 100%;
    height: 100%;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.project-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: none;
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-item:hover .project-video {
    transform: scale(1.05);
}

/* Reel Card Overlay Info */
.project-info {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 2.2rem 1.8rem 1.8rem 1.8rem;
    background: linear-gradient(to top, rgba(2, 2, 4, 0.95) 0%, rgba(2, 2, 4, 0.4) 60%, transparent 100%);
    z-index: 2;
}

.project-info h3 {
    font-size: 1.3rem;
    font-weight: 600;
    color: white;
    margin-bottom: 0.3rem;
}

.project-info span {
    font-size: 0.8rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 2px;
}

/* --- Interactive Slider Scroll Progress Bar --- */
.slider-progress-container {
    width: 100%;
    height: 2px;
    background: rgba(255, 255, 255, 0.04);
    margin-top: 2.5rem;
    border-radius: 1px;
    position: relative;
    overflow: hidden;
    max-width: 160px;
    margin-left: auto;
    margin-right: auto;
}

.slider-progress-bar {
    width: 0%;
    height: 100%;
    background: var(--accent-gradient);
    transition: width 0.15s ease-out;
}

/* --- Showcase Sections (Split Landscape Layout) --- */
.showcase-section {
    background: linear-gradient(to bottom, #020204, #050508);
}

.showcase-section.alt {
    background: linear-gradient(to bottom, #050508, #020204);
}

.showcase-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 5rem; /* Larger gap to separate video and details */
    align-items: center;
}

.showcase-section.alt .showcase-container {
    grid-template-columns: 0.8fr 1.2fr;
}

/* Glassmorphic Media Block */
.showcase-video {
    width: 100%;
    aspect-ratio: 16/9;
    border-radius: 24px;
    overflow: hidden;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    position: relative;
    box-shadow: 0 35px 80px rgba(0, 0, 0, 0.8);
    transition: border-color 0.5s, box-shadow 0.5s;
}

.showcase-video:hover {
    border-color: var(--border-hover);
    box-shadow: 0 40px 90px rgba(0, 0, 0, 0.8), 0 0 50px rgba(129, 140, 248, 0.15);
}

/* Showcase Details Card */
.showcase-details {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.category-tag {
    font-family: monospace;
    font-size: 0.85rem;
    color: var(--accent);
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 1rem;
}

.showcase-details h2 {
    font-size: 2.8rem;
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 1.2rem;
}

.production-badge {
    align-self: flex-start;
    padding: 0.4rem 1.1rem;
    background: rgba(129, 140, 248, 0.08);
    border: 1px solid rgba(129, 140, 248, 0.2);
    color: var(--accent);
    font-size: 0.85rem;
    font-weight: 600;
    border-radius: 30px;
    margin-bottom: 1.8rem;
}

.showcase-details p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
}

/* Modern List Style */
.features-list {
    display: flex;
    flex-direction: column;
    gap: 1.8rem;
}

.feature-item {
    display: flex;
    gap: 1.4rem;
}

.feature-item .icon {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    background: var(--accent-gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    font-weight: 700;
    color: white;
    box-shadow: 0 0 15px rgba(129, 140, 248, 0.25);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.4s;
}

.feature-item:hover .icon {
    transform: scale(1.15) rotate(5deg);
    box-shadow: 0 0 25px rgba(168, 85, 247, 0.5);
}

.feature-item h4 {
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 0.3rem;
}

.feature-item p {
    font-size: 0.98rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 0;
}

/* --- School Landscape 2-Column Grid --- */
.showcase-grid-2 {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem; /* Expanded gap to look distinct */
    padding: 0 1.5rem;
}

/* --- YouTube Lazy Loader --- */
.youtube-lazy-load {
    position: relative;
    width: 100%;
    height: 100%;
    cursor: pointer;
    background: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.youtube-thumbnail {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), filter 0.3s;
}

.youtube-lazy-load:hover .youtube-thumbnail {
    transform: scale(1.04);
    filter: brightness(0.8);
}

.youtube-lazy-load .play-button {
    position: absolute;
    width: 72px;
    height: 72px;
    background: rgba(129, 140, 248, 0.12);
    border: 2px solid var(--accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    z-index: 5;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), background 0.4s, box-shadow 0.4s;
    backdrop-filter: blur(8px);
    box-shadow: 0 0 30px rgba(129, 140, 248, 0.25);
}

.youtube-lazy-load:hover .play-button {
    transform: scale(1.1);
    background: var(--accent-gradient);
    border-color: white;
    box-shadow: 0 0 45px rgba(168, 85, 247, 0.5);
}

/* --- Inline Mute Button (Video hover mute controls) --- */
.project-mute-btn {
    position: absolute;
    top: 22px;
    right: 22px;
    background: rgba(2, 2, 4, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: white;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: none;
    z-index: 100;
    opacity: 0;
    transition: opacity 0.3s, background 0.3s, transform 0.3s;
    backdrop-filter: blur(8px);
}

.project-item:hover .project-mute-btn {
    opacity: 1;
}

.project-mute-btn:hover {
    background: var(--accent);
    transform: scale(1.08);
}

/* --- Mute Button (Hero Showreel) --- */
.mute-btn {
    position: absolute;
    bottom: 45px;
    right: 45px;
    background: rgba(2, 2, 4, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: none;
    z-index: 100;
    transition: background 0.3s, transform 0.3s;
    backdrop-filter: blur(8px);
}

.mute-btn:hover {
    background: var(--accent);
    transform: scale(1.08);
}

/* --- About Section --- */
.about {
    background: #020204;
}

.about-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6rem;
    align-items: center;
}

.about-text h2 {
    font-size: 4rem;
    font-weight: 900;
    line-height: 1.1;
    margin-bottom: 2rem;
    letter-spacing: -1px;
}

.about-text p {
    font-size: 1.18rem;
    line-height: 1.85;
    color: var(--text-secondary);
    margin-bottom: 3rem;
}

.stats {
    display: flex;
    gap: 5rem;
}

.stat-item h4 {
    font-size: 2.8rem;
    font-weight: 800;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 0.3rem;
}

.stat-item p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin: 0;
}

.about-visual {
    width: 100%;
}

.about-video-container {
    width: 100%;
    aspect-ratio: 16/10;
    border-radius: 24px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    box-shadow: 0 35px 80px rgba(0, 0, 0, 0.85);
}

.about-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* --- Footer / Contact Section --- */
.contact {
    padding: 12rem 5rem 5rem 5rem; /* Spacious padding */
    background: radial-gradient(circle at top, rgba(99, 102, 241, 0.08) 0%, rgba(2, 2, 4, 0) 65%), #020204;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.contact-content {
    max-width: 800px;
    margin-bottom: 7rem;
}

.huge-text {
    font-size: 8rem;
    font-weight: 950;
    line-height: 0.9;
    letter-spacing: -4px;
    margin-bottom: 2rem;
    background: linear-gradient(135deg, #ffffff 0%, rgba(255, 255, 255, 0.3) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.contact-content p {
    font-size: 1.3rem;
    color: var(--text-secondary);
    margin-bottom: 3.5rem;
    letter-spacing: 1px;
}

.cta-btn {
    display: inline-block;
    padding: 1.25rem 3.5rem;
    background: white;
    color: black;
    font-weight: 700;
    font-size: 1.15rem;
    border-radius: 40px;
    letter-spacing: 2px;
    box-shadow: 0 12px 35px rgba(255, 255, 255, 0.12);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s, background 0.3s, color 0.3s;
}

.cta-btn:hover {
    transform: translateY(-6px);
    background: var(--accent-gradient);
    color: white;
    box-shadow: 0 18px 45px rgba(168, 85, 247, 0.35);
}

.footer-bottom {
    width: 100%;
    max-width: 1200px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 2.2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.04);
}

.footer-bottom p {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.25);
}

.socials {
    display: flex;
    gap: 2rem;
}

.socials a {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 500;
    transition: color 0.3s;
}

.socials a:hover {
    color: var(--accent);
}

/* --- Responsive Design --- */
@media (max-width: 1024px) {
    .hero {
        margin: 2rem 3rem;
    }
    
    .portfolio-section,
    .showcase-section,
    .welcome-section,
    .about,
    .contact {
        padding: 8rem 3rem;
    }
    
    .about-container {
        gap: 3rem;
    }
    
    .huge-text {
        font-size: 6.5rem;
    }
}

@media (max-width: 768px) {
    body {
        cursor: auto;
    }
    
    .cursor-dot, .cursor-outline {
        display: none;
    }
    
    .hero {
        height: auto;
        aspect-ratio: 16/9;
        width: calc(100% - 2rem);
        margin: 1rem auto;
        border-radius: 18px;
    }
    
    .scroll-down {
        display: none;
    }
    
    .welcome-section,
    .portfolio-section,
    .showcase-section,
    .about {
        padding: 6.5rem 1.5rem; /* Breathing room on mobile */
    }
    
    .welcome-title {
        font-size: 2.4rem;
    }
    
    .welcome-subtitle {
        font-size: 1.1rem;
        letter-spacing: 2px;
    }
    
    .welcome-desc {
        font-size: 1.05rem;
    }
    
    .section-header {
        margin-bottom: 2.5rem;
    }
    
    .section-header h2 {
        font-size: 2.2rem;
    }
    
    .reels-slider-wrapper {
        padding: 0;
    }
    
    .reels-slider {
        padding: 0.5rem 1rem;
        margin: 0 -1rem;
        gap: 1.2rem;
    }
    
    .reels-slider .project-item.vertical {
        width: 220px;
        height: 391px;
        border-radius: 14px;
    }
    
    .project-mute-btn {
        opacity: 1;
        cursor: pointer;
        width: 36px;
        height: 36px;
        top: 15px;
        right: 15px;
    }
    
    .mute-btn {
        bottom: 15px;
        right: 15px;
        width: 40px;
        height: 40px;
        cursor: pointer;
    }
    
    .showcase-container,
    .showcase-section.alt .showcase-container {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }
    
    .showcase-section.alt .showcase-details {
        order: 1;
    }
    
    .showcase-grid-2 {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .showcase-details h2 {
        font-size: 2rem;
    }
    
    .about-container {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }
    
    .about-text h2 {
        font-size: 2.4rem;
    }
    
    .about-visual {
        margin-top: 1rem;
    }
    
    .contact {
        padding: 7rem 1.5rem 4rem 1.5rem;
    }
    
    .huge-text {
        font-size: 14vw;
        letter-spacing: -2px;
    }
    
    .cta-btn {
        padding: 1rem 2.2rem;
        font-size: 1rem;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 1.2rem;
        text-align: center;
        margin-top: 4rem;
    }
    
    .socials {
        justify-content: center;
        flex-wrap: wrap;
        gap: 1.2rem;
    }
}
