html, body {
    overflow-x: hidden;
    overflow-y: hidden;
    width: 100%;
    margin: 0;
    padding: 0;
    min-height: 1000px;
}

section {
    scroll-margin-top: 100px;
}

nav {
    z-index: 100 !important;
}

/* Hamburger Menu Styles */
.hamburger-menu {
    display: none;
    flex-direction: column;
    justify-content: space-around;
    width: 30px;
    height: 25px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 101;
}

.hamburger-line {
    width: 100%;
    height: 3px;
    background-color: white;
    transition: all 0.3s ease;
    border-radius: 2px;
}

.hamburger-menu.active .hamburger-line:nth-child(1) {
    transform: rotate(45deg) translate(8px, 8px);
}

.hamburger-menu.active .hamburger-line:nth-child(2) {
    opacity: 0;
}

.hamburger-menu.active .hamburger-line:nth-child(3) {
    transform: rotate(-45deg) translate(8px, -8px);
}

.nav-links {
    transition: all 0.3s ease;
}

/* Prevent flickering during screen resize */
@media (min-width: 769px) {
    .nav-links {
        display: flex !important;
        position: relative !important;
        top: auto !important;
        right: auto !important;
        flex-direction: row !important;
        background: transparent !important;
        backdrop-filter: none !important;
        padding: 0 !important;
        width: auto !important;
        border: none !important;
        opacity: 1 !important;
        visibility: visible !important;
    }
}

/* ==============================
   FLEXBOX MAIN CONTAINER
   ============================== */
#flex-main-container {
    display: flex;
    flex-direction: column;
    position: relative;
    width: 100%;
    min-height: 1000px;
}

/* Lock home section height - using flexbox */
#home {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    flex: 0 0 1000px;
    position: relative;
    width: 100%;
}

/* Matrix Rain Background */
.matrix-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    opacity: 0.4;
    pointer-events: none;
}

#home .text-center {
    position: relative;
    z-index: 2;
    transition: transform 0.5s ease;
}

#home .text-center.slide-up {
    transform: translateY(-250px);
}

#home .text-center.slide-up-work {
    transform: translateY(-130px);
}

/* Responsive Typography - Viewport-based scaling */
#home .text-center h1 {
    font-size: clamp(32px, 8vw, 65px);
    line-height: 1.1;
}

#home .text-center p {
    font-size: clamp(16px, 3vw, 27px);
    line-height: 1.4;
    margin-top: clamp(8px, 2vw, 12px);
}

nav a {
    transition: all 0.3s ease;
    display: inline-block;
    border: none;
}

nav a:hover {
    transform: scale(1.15);
    color: #fff;
}

/* Remove any default borders on links */
.nav-links a {
    border: none;
    outline: none;
}

div h1 {
    transition: all 0.3s  ease;
    display: inline-block;
}

div h1:hover {
    transform: scale(1.03);
}

/* Hover Glitch Effect */
.hover-glitch {
    position: relative;
    cursor: pointer;
    transition: all 0.3s ease;
}

.hover-glitch:hover {
    transform: scale(1.03);
}

.hover-glitch::before,
.hover-glitch::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
}

.hover-glitch::before {
    color: #ff00ff;
    z-index: -1;
    clip-path: polygon(0 0, 100% 0, 100% 45%, 0 45%);
}

.hover-glitch::after {
    color: #00ffff;
    z-index: -1;
    clip-path: polygon(0 55%, 100% 55%, 100% 100%, 0 100%);
}

.hover-glitch:hover::before {
    opacity: 1;
    animation: hover-glitch-left 0.4s infinite;
}

.hover-glitch:hover::after {
    opacity: 1;
    animation: hover-glitch-right 0.5s infinite;
}

@keyframes hover-glitch-left {
    0%, 30%, 35%, 50%, 55%, 70%, 75%, 100% {
        transform: translate(0);
        clip-path: polygon(0 0, 100% 0, 100% 45%, 0 45%);
    }
    1% {
        transform: translate(-22px, 0);
        clip-path: polygon(0 5%, 100% 8%, 100% 28%, 0 24%);
    }
    3% {
        transform: translate(-28px, 0);
        clip-path: polygon(0 18%, 100% 14%, 100% 42%, 0 46%);
    }
    51% {
        transform: translate(-26px, 0);
        clip-path: polygon(0 22%, 100% 20%, 100% 58%, 0 60%);
    }
    53% {
        transform: translate(-32px, 0);
        clip-path: polygon(0 2%, 100% 6%, 100% 50%, 0 47%);
    }
    71% {
        transform: translate(-20px, 0);
        clip-path: polygon(0 32%, 100% 30%, 100% 68%, 0 70%);
    }
    73% {
        transform: translate(-30px, 0);
        clip-path: polygon(0 12%, 100% 16%, 100% 44%, 0 40%);
    }
}

@keyframes hover-glitch-right {
    0%, 28%, 33%, 48%, 52%, 68%, 72%, 100% {
        transform: translate(0);
        clip-path: polygon(0 55%, 100% 55%, 100% 100%, 0 100%);
    }
    2% {
        transform: translate(24px, 0);
        clip-path: polygon(0 64%, 100% 60%, 100% 90%, 0 94%);
    }
    4% {
        transform: translate(30px, 0);
        clip-path: polygon(0 50%, 100% 54%, 100% 80%, 0 84%);
    }
    49% {
        transform: translate(28px, 0);
        clip-path: polygon(0 60%, 100% 57%, 100% 96%, 0 100%);
    }
    51% {
        transform: translate(34px, 0);
        clip-path: polygon(0 48%, 100% 50%, 100% 88%, 0 86%);
    }
    69% {
        transform: translate(22px, 0);
        clip-path: polygon(0 70%, 100% 68%, 100% 100%, 0 98%);
    }
    71% {
        transform: translate(32px, 0);
        clip-path: polygon(0 54%, 100% 60%, 100% 92%, 0 90%);
    }
}


div p {
    transition: all 0.3s  ease;
}

div p:hover {
    transform: scale(1.03);
}

/* ==============================
    GLITCH LOADING SCREEN STYLES
    ============================== */

    .loading-screen {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: #0a0a0a;
        display: flex;
        justify-content: center;
        align-items: center;
        z-index: 10000;
        transition: opacity 0.8s ease, visibility 0.8s ease;
    }
    
    .loading-screen.loaded {
        opacity: 0;
        visibility: hidden;
    }
    
    .glitch-wrapper {
        text-align: center;
        padding: 0 20px;
        max-width: 90%;
    }
    
    /* Main Glitch Text */
    .glitch-text {
        font-size: clamp(28px, 8vw, 48px);
        font-weight: 900;
        letter-spacing: clamp(4px, 2vw, 12px);
        color: #fff;
        position: relative;
        display: inline-block;
        animation: initial-text-glitch 0.6s ease-out, glitch-screen 1.8s 0.6s infinite;
    }
    
    /* Red layer (::before) */
    .glitch-text::before {
        content: attr(data-text);
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        color: #ff00ff;
        z-index: -1;
        animation: initial-text-glitch 0.6s ease-out, glitch-left 2.2s 0.6s infinite;
        clip-path: polygon(0 0, 100% 0, 100% 45%, 0 45%);
    }
    
    /* Cyan layer (::after) */
    .glitch-text::after {
        content: attr(data-text);
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        color: #00ffff;
        z-index: -1;
        animation: initial-text-glitch 0.6s ease-out, glitch-right 2.5s 0.6s infinite;
        clip-path: polygon(0 55%, 100% 55%, 100% 100%, 0 100%);
    }
    
    /* Subtext below main glitch */
    .loading-subtext {
        margin-top: 12px;
        font-size: clamp(10px, 2.5vw, 14px);
        letter-spacing: clamp(2px, 1vw, 6px);
        color: #aaa;
        font-weight: 400;
        text-transform: lowercase;
        position: relative;
        animation: initial-subtext-glitch 0.6s ease-out, text-glitch 2s 0.6s infinite;
    }

    /* ========================================
       LOADING BAR STYLES
       ======================================== */
    
    .loading-bar-container {
        width: clamp(250px, 80vw, 450px);
        height: clamp(16px, 3vw, 20px);
        background: rgba(255, 255, 255, 0.1);
        border-radius: 0;
        margin: clamp(20px, 5vw, 30px) auto clamp(12px, 3vw, 18px);
        overflow: hidden;
        position: relative;
        border: 2px solid rgba(255, 255, 255, 0.3);
    }
    
    .loading-bar-fill {
        height: 100%;
        width: 0%;
        background: #ffffff;
        border-radius: 0;
        transition: width 0.15s ease-out;
        box-shadow: 0 0 25px rgba(255, 255, 255, 0.6),
                    0 0 50px rgba(255, 255, 255, 0.3),
                    inset 0 0 15px rgba(255, 255, 255, 0.4);
        position: relative;
        animation: initial-bar-glitch 0.6s ease-out, bar-glitch 2.3s 0.6s infinite;
    }
    
    /* Animated glow effect on the bar */
    .loading-bar-fill::after {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: linear-gradient(90deg, 
            transparent, 
            rgba(255, 255, 255, 0.8), 
            transparent);
        animation: shimmer 1.5s infinite;
    }
    
    .loading-percentage {
        font-size: clamp(16px, 4vw, 20px);
        font-weight: 700;
        letter-spacing: clamp(2px, 0.5vw, 3px);
        color: #ffffff;
        font-family: 'Courier New', monospace;
        text-shadow: 0 0 15px rgba(255, 255, 255, 0.6);
        position: relative;
        animation: initial-percentage-glitch 0.6s ease-out, percentage-glitch 1.6s 0.6s infinite;
    }
    
    /* ========================================
       GLITCH ANIMATIONS
       ======================================== */
    
    @keyframes glitch-screen {
        0%, 70%, 76%, 85%, 89%, 94%, 97%, 100% {
            transform: translate(0) skew(0deg);
        }
        72%, 88% {
            transform: translate(-10px, 6px) skew(-4deg);
        }
        74%, 86% {
            transform: translate(12px, -8px) skew(5deg);
        }
        75%, 95% {
            transform: translate(-8px, -4px) skew(3deg);
        }
        87% {
            transform: translate(10px, 5px) skew(-6deg);
        }
        96% {
            transform: translate(-14px, 3px) skew(7deg);
        }
    }
    
    @keyframes glitch-left {
        0%, 68%, 73%, 82%, 87%, 92%, 96%, 100% {
            transform: translate(0);
            clip-path: polygon(0 0, 100% 0, 100% 45%, 0 45%);
        }
        69% {
            transform: translate(-22px, 0);
            clip-path: polygon(0 5%, 100% 8%, 100% 28%, 0 24%);
        }
        71% {
            transform: translate(-28px, 0);
            clip-path: polygon(0 18%, 100% 14%, 100% 42%, 0 46%);
        }
        83% {
            transform: translate(-26px, 0);
            clip-path: polygon(0 22%, 100% 20%, 100% 58%, 0 60%);
        }
        85% {
            transform: translate(-32px, 0);
            clip-path: polygon(0 2%, 100% 6%, 100% 50%, 0 47%);
        }
        93% {
            transform: translate(-20px, 0);
            clip-path: polygon(0 32%, 100% 30%, 100% 68%, 0 70%);
        }
        95% {
            transform: translate(-30px, 0);
            clip-path: polygon(0 12%, 100% 16%, 100% 44%, 0 40%);
        }
    }
    
    @keyframes glitch-right {
        0%, 66%, 72%, 80%, 85%, 90%, 94%, 100% {
            transform: translate(0);
            clip-path: polygon(0 55%, 100% 55%, 100% 100%, 0 100%);
        }
        68% {
            transform: translate(24px, 0);
            clip-path: polygon(0 64%, 100% 60%, 100% 90%, 0 94%);
        }
        70% {
            transform: translate(30px, 0);
            clip-path: polygon(0 50%, 100% 54%, 100% 80%, 0 84%);
        }
        81% {
            transform: translate(28px, 0);
            clip-path: polygon(0 60%, 100% 57%, 100% 96%, 0 100%);
        }
        83% {
            transform: translate(34px, 0);
            clip-path: polygon(0 48%, 100% 50%, 100% 88%, 0 86%);
        }
        91% {
            transform: translate(22px, 0);
            clip-path: polygon(0 70%, 100% 68%, 100% 100%, 0 98%);
        }
        93% {
            transform: translate(32px, 0);
            clip-path: polygon(0 54%, 100% 60%, 100% 92%, 0 90%);
        }
    }
    
    @keyframes pulse {
        0%, 100% {
            opacity: 0.5;
        }
        50% {
            opacity: 1;
        }
    }

    @keyframes shimmer {
        0% {
            transform: translateX(-100%);
        }
        100% {
            transform: translateX(100%);
        }
    }

    @keyframes bar-glitch {
        0%, 70%, 74%, 84%, 88%, 93%, 97%, 100% {
            transform: translateY(0) translateX(0);
            filter: none;
        }
        71% {
            transform: translateY(-4px) translateX(-3px);
            filter: drop-shadow(8px 0 0 rgba(255, 0, 255, 1)) 
                    drop-shadow(-8px 0 0 rgba(0, 255, 255, 1));
        }
        73% {
            transform: translateY(5px) translateX(4px);
            filter: drop-shadow(-10px 0 0 rgba(255, 0, 255, 1)) 
                    drop-shadow(10px 0 0 rgba(0, 255, 255, 1));
        }
        85% {
            transform: translateY(-3px) translateX(2px);
            filter: drop-shadow(12px 0 0 rgba(255, 0, 255, 0.9)) 
                    drop-shadow(-12px 0 0 rgba(0, 255, 255, 0.9));
        }
        87% {
            transform: translateY(6px) translateX(-5px);
            filter: drop-shadow(-6px 0 0 rgba(255, 0, 255, 1)) 
                    drop-shadow(6px 0 0 rgba(0, 255, 255, 1));
        }
        94% {
            transform: translateY(2px) translateX(3px);
            filter: drop-shadow(9px 0 0 rgba(255, 0, 255, 0.95)) 
                    drop-shadow(-9px 0 0 rgba(0, 255, 255, 0.95));
        }
    }

    @keyframes text-glitch {
        0%, 72%, 76%, 86%, 90%, 95%, 98%, 100% {
            transform: translate(0);
            text-shadow: 0 0 0 transparent;
        }
        73% {
            transform: translate(-3px, 1px);
            text-shadow: 2px 0 0 rgba(255, 0, 255, 0.8),
                         -2px 0 0 rgba(0, 255, 255, 0.8);
        }
        75% {
            transform: translate(4px, -2px);
            text-shadow: -3px 0 0 rgba(255, 0, 255, 0.9),
                         3px 0 0 rgba(0, 255, 255, 0.9);
        }
        87% {
            transform: translate(-2px, 2px);
            text-shadow: 4px 0 0 rgba(255, 0, 255, 0.7),
                         -4px 0 0 rgba(0, 255, 255, 0.7);
        }
        89% {
            transform: translate(3px, -1px);
            text-shadow: -2px 0 0 rgba(255, 0, 255, 1),
                         2px 0 0 rgba(0, 255, 255, 1);
        }
        96% {
            transform: translate(-4px, 1px);
            text-shadow: 3px 0 0 rgba(255, 0, 255, 0.85),
                         -3px 0 0 rgba(0, 255, 255, 0.85);
        }
    }

    @keyframes percentage-glitch {
        0%, 68%, 73%, 83%, 88%, 92%, 96%, 100% {
            transform: translate(0) scale(1);
            text-shadow: 0 0 15px rgba(255, 255, 255, 0.6);
        }
        69% {
            transform: translate(-4px, -2px) scale(1.05);
            text-shadow: 3px 0 0 rgba(255, 0, 255, 1),
                         -3px 0 0 rgba(0, 255, 255, 1),
                         0 0 20px rgba(255, 255, 255, 0.8);
        }
        71% {
            transform: translate(5px, 3px) scale(0.95);
            text-shadow: -4px 0 0 rgba(255, 0, 255, 1),
                         4px 0 0 rgba(0, 255, 255, 1),
                         0 0 25px rgba(255, 255, 255, 0.9);
        }
        84% {
            transform: translate(-3px, 2px) scale(1.03);
            text-shadow: 5px 0 0 rgba(255, 0, 255, 0.9),
                         -5px 0 0 rgba(0, 255, 255, 0.9),
                         0 0 18px rgba(255, 255, 255, 0.7);
        }
        86% {
            transform: translate(2px, -3px) scale(0.98);
            text-shadow: -3px 0 0 rgba(255, 0, 255, 1),
                         3px 0 0 rgba(0, 255, 255, 1),
                         0 0 22px rgba(255, 255, 255, 0.85);
        }
        93% {
            transform: translate(-2px, 1px) scale(1.02);
            text-shadow: 4px 0 0 rgba(255, 0, 255, 0.95),
                         -4px 0 0 rgba(0, 255, 255, 0.95),
                         0 0 20px rgba(255, 255, 255, 0.8);
        }
    }

    @keyframes initial-text-glitch {
        0%, 10%, 16%, 25%, 29%, 34%, 37%, 100% {
            transform: translate(0) skew(0deg);
        }
        12%, 28% {
            transform: translate(-10px, 6px) skew(-4deg);
        }
        14%, 26% {
            transform: translate(12px, -8px) skew(5deg);
        }
        15%, 35% {
            transform: translate(-8px, -4px) skew(3deg);
        }
        27% {
            transform: translate(10px, 5px) skew(-6deg);
        }
        36% {
            transform: translate(-14px, 3px) skew(7deg);
        }
    }

    @keyframes initial-subtext-glitch {
        0%, 12%, 16%, 26%, 30%, 35%, 38%, 100% {
            transform: translate(0);
            text-shadow: 0 0 0 transparent;
        }
        13% {
            transform: translate(-3px, 1px);
            text-shadow: 2px 0 0 rgba(255, 0, 255, 0.8),
                         -2px 0 0 rgba(0, 255, 255, 0.8);
        }
        15% {
            transform: translate(4px, -2px);
            text-shadow: -3px 0 0 rgba(255, 0, 255, 0.9),
                         3px 0 0 rgba(0, 255, 255, 0.9);
        }
        27% {
            transform: translate(-2px, 2px);
            text-shadow: 4px 0 0 rgba(255, 0, 255, 0.7),
                         -4px 0 0 rgba(0, 255, 255, 0.7);
        }
        29% {
            transform: translate(3px, -1px);
            text-shadow: -2px 0 0 rgba(255, 0, 255, 1),
                         2px 0 0 rgba(0, 255, 255, 1);
        }
        36% {
            transform: translate(-4px, 1px);
            text-shadow: 3px 0 0 rgba(255, 0, 255, 0.85),
                         -3px 0 0 rgba(0, 255, 255, 0.85);
        }
    }

    @keyframes initial-bar-glitch {
        0%, 10%, 14%, 24%, 28%, 33%, 37%, 100% {
            transform: translateY(0) translateX(0);
            filter: none;
        }
        11% {
            transform: translateY(-4px) translateX(-3px);
            filter: drop-shadow(8px 0 0 rgba(255, 0, 255, 1)) 
                    drop-shadow(-8px 0 0 rgba(0, 255, 255, 1));
        }
        13% {
            transform: translateY(5px) translateX(4px);
            filter: drop-shadow(-10px 0 0 rgba(255, 0, 255, 1)) 
                    drop-shadow(10px 0 0 rgba(0, 255, 255, 1));
        }
        25% {
            transform: translateY(-3px) translateX(2px);
            filter: drop-shadow(12px 0 0 rgba(255, 0, 255, 0.9)) 
                    drop-shadow(-12px 0 0 rgba(0, 255, 255, 0.9));
        }
        27% {
            transform: translateY(6px) translateX(-5px);
            filter: drop-shadow(-6px 0 0 rgba(255, 0, 255, 1)) 
                    drop-shadow(6px 0 0 rgba(0, 255, 255, 1));
        }
        34% {
            transform: translateY(2px) translateX(3px);
            filter: drop-shadow(9px 0 0 rgba(255, 0, 255, 0.95)) 
                    drop-shadow(-9px 0 0 rgba(0, 255, 255, 0.95));
        }
    }

    @keyframes initial-percentage-glitch {
        0%, 8%, 13%, 23%, 28%, 32%, 36%, 100% {
            transform: translate(0) scale(1);
            text-shadow: 0 0 15px rgba(255, 255, 255, 0.6);
        }
        9% {
            transform: translate(-4px, -2px) scale(1.05);
            text-shadow: 3px 0 0 rgba(255, 0, 255, 1),
                         -3px 0 0 rgba(0, 255, 255, 1),
                         0 0 20px rgba(255, 255, 255, 0.8);
        }
        11% {
            transform: translate(5px, 3px) scale(0.95);
            text-shadow: -4px 0 0 rgba(255, 0, 255, 1),
                         4px 0 0 rgba(0, 255, 255, 1),
                         0 0 25px rgba(255, 255, 255, 0.9);
        }
        24% {
            transform: translate(-3px, 2px) scale(1.03);
            text-shadow: 5px 0 0 rgba(255, 0, 255, 0.9),
                         -5px 0 0 rgba(0, 255, 255, 0.9),
                         0 0 18px rgba(255, 255, 255, 0.7);
        }
        26% {
            transform: translate(2px, -3px) scale(0.98);
            text-shadow: -3px 0 0 rgba(255, 0, 255, 1),
                         3px 0 0 rgba(0, 255, 255, 1),
                         0 0 22px rgba(255, 255, 255, 0.85);
        }
        33% {
            transform: translate(-2px, 1px) scale(1.02);
            text-shadow: 4px 0 0 rgba(255, 0, 255, 0.95),
                         -4px 0 0 rgba(0, 255, 255, 0.95),
                         0 0 20px rgba(255, 255, 255, 0.8);
        }
    }


/* ==============================
   FLEXBOX-BASED PANEL SYSTEM
   ============================== */

/* Slide-in Panels - Flexbox positioned */
.panel {
    position: absolute;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: stretch;
    top: 250px;
    right: -60%;
    flex: 0 0 auto;
    flex-basis: 35%;
    max-width: 35%;
    min-width: 200px;
    max-height: none;
    background: rgba(15, 15, 15, 0.95);
    backdrop-filter: blur(10px);
    z-index: 50;
    overflow-y: hidden;
    transition: all 0.5s ease;
    opacity: 0;
    box-shadow: 0 10px 50px rgba(0, 0, 0, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.panel.active {
    right: 5%;
    opacity: 1;
}

/* Left-side panel (About) - Flexbox positioned */
.panel-left {
    left: -35%;
    right: auto;
    top: 330px;
    flex-basis: 538px;
    max-width: 538px;
    min-width: 538px;
    width: 538px;
    height: auto;
    max-height: none;
    overflow-y: hidden;
}

.panel-left.active {
    left: 50%;
    right: auto;
    transform: translate(-50%, 0);
}

.panel-left .panel-content {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    text-align: center;
    padding: 30px 35px;
    overflow-y: hidden;
    flex: 1 1 auto;
}

.panel-left .panel-content h2 {
    margin-bottom: 20px;
    flex: 0 0 auto;
}

.panel-left .panel-content p {
    line-height: 1.7;
    font-size: 16px;
    flex: 0 0 auto;
}

/* Bottom panels (Strength boxes) - Flexbox positioned */
.panel-bottom {
    display: flex;
    flex-direction: column;
    top: 700px;
    bottom: auto;
    left: 50%;
    right: auto;
    transform: translateX(-50%) translateY(300px);
    flex-basis: 280px;
    max-width: 280px;
    min-width: 280px;
    width: 280px;
    height: auto;
    max-height: none;
    opacity: 0;
    visibility: hidden;
}

.panel-bottom.active {
    top: 600px;
    bottom: auto;
    transform: translateX(-50%) translateY(0);
    opacity: 1;
    visibility: visible;
}

/* Position strength boxes side by side using flexbox calc */
#strength-panel-1 {
    left: calc(50% - 320px);
}

#strength-panel-2 {
    left: 50%;
}

#strength-panel-3 {
    left: calc(50% + 320px);
}

/* Position work boxes side by side using flexbox calc */
#work-panel-1 {
    left: calc(50% - 320px);
}

#work-panel-2 {
    left: 50%;
}

#work-panel-3 {
    left: calc(50% + 320px);
}

/* Make work panels same height as strength panels - box appearance */
#work-panel-1,
#work-panel-2,
#work-panel-3 {
    min-height: 240px;
    height: 240px;
}

/* Move work panels up when active - positioned higher than strength panels */
#work-panel-1.active,
#work-panel-2.active,
#work-panel-3.active {
    top: 470px;
}

.panel-content {
    padding: 40px 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    text-align: center;
    overflow: hidden;
    flex: 1 1 auto;
}

.panel-bottom .panel-content h4 {
    color: #ffffff;
    flex: 0 0 auto;
}

.panel-bottom .panel-content p {
    font-size: 15px;
    line-height: 1.6;
    flex: 0 0 auto;
}

/* ==============================
   FLEXBOX RESPONSIVE LAYOUT
   Using flex properties for responsive behavior
   ============================== */


/* 1100px width breakpoint - Fluid viewport-based spacing */
@media (max-width: 1100px) {
    #strength-panel-1 {
        left: calc(50% - 28vw);
    }
    
    #strength-panel-3 {
        left: calc(50% + 28vw);
    }
}

/* 1000px - Fluid spacing and responsive sizing */
@media (max-width: 1000px) {
    nav {
        padding: 20px 32px;
    }
    
    #home {
        padding: 0 24px;
    }
    
    .panel-left {
        flex-basis: 55%;
        max-width: 538px;
        min-width: 400px;
        width: 55%;
        top: 340px;
    }
    
    .panel-left .panel-content {
        padding: 28px 32px;
    }
    
    .panel-left .panel-content h2 {
        font-size: clamp(26px, 3vw, 30px);
    }
    
    .panel-left .panel-content p {
        font-size: clamp(15px, 2vw, 16px);
        line-height: 1.65;
    }
    
    /* Hide all strength panels and work panels below 1000px */
    .panel-bottom {
        display: none !important;
    }
    
    #home .text-center.slide-up {
        transform: translateY(-230px);
    }
}

/* Tablet landscape - No strength panels */
@media (max-width: 900px) {
    #home {
        padding: 0 20px;
    }
    
    .panel-left {
        flex-basis: 60%;
        max-width: 500px;
        min-width: 300px;
        width: 60%;
        top: 360px;
    }
    
    .panel-left .panel-content {
        padding: 26px 30px;
    }
    
    .panel-left .panel-content h2 {
        font-size: clamp(24px, 3.5vw, 28px);
    }
    
    .panel-left .panel-content p {
        font-size: clamp(15px, 2.2vw, 16px);
        line-height: 1.6;
    }
    
    /* Hide all strength panels */
    .panel-bottom {
        display: none !important;
    }
    
    #home .text-center.slide-up {
        transform: translateY(-220px);
    }
}

/* Tablet portrait - Simplified single panel */
@media (max-width: 768px) {
    nav {
        padding: 18px 24px;
    }
    
    /* Show hamburger on tablet portrait */
    .hamburger-menu {
        display: flex;
    }
    
    .nav-links {
        position: fixed;
        top: -100%;
        right: 24px;
        flex-direction: column;
        background: rgba(15, 15, 15, 0.4);
        backdrop-filter: blur(10px);
        padding: 30px 24px;
        gap: 20px;
        width: 220px;
        border: 1px solid rgba(255, 255, 255, 0.1);
        transition: top 0.3s ease, opacity 0.3s ease;
        opacity: 0;
        visibility: hidden;
    }
    
    .nav-links.active {
        top: 75px;
        opacity: 1;
        visibility: visible;
    }
    
    .nav-links a {
        font-size: 16px;
        padding: 10px 0;
    }
    
    .panel {
        flex-basis: 85%;
        max-width: 500px;
        width: 85%;
    }
    
    .panel-left {
        flex-basis: 80%;
        max-width: 450px;
        min-width: 280px;
        width: 80%;
        top: 380px;
    }
    
    .panel-left .panel-content {
        padding: 24px 28px;
    }
    
    .panel-left .panel-content h2 {
        font-size: clamp(22px, 4vw, 26px);
    }
    
    .panel-left .panel-content p {
        font-size: clamp(14px, 2.5vw, 15px);
        line-height: 1.6;
    }
    
    /* Hide strength panels on tablet portrait - show only about panel */
    .panel-bottom {
        display: none !important;
    }
    
    #home .text-center.slide-up {
        transform: translateY(-200px);
    }
}

/* Mobile landscape - Hamburger menu and simplified layout */
@media (max-width: 640px) {
    nav {
        padding: 16px 20px;
    }
    
    nav .flex.flex-col div:first-child {
        font-size: 16px;
    }
    
    nav .flex.flex-col div:last-child {
        font-size: 10px;
    }
    
    /* Show hamburger, hide desktop nav */
    .hamburger-menu {
        display: flex;
    }
    
    .nav-links {
        position: fixed;
        top: -100%;
        right: 20px;
        flex-direction: column;
        background: rgba(15, 15, 15, 0.4);
        backdrop-filter: blur(10px);
        padding: 30px 20px;
        gap: 20px;
        width: 200px;
        border: 1px solid rgba(255, 255, 255, 0.1);
        transition: top 0.3s ease, opacity 0.3s ease;
        opacity: 0;
        visibility: hidden;
    }
    
    .nav-links.active {
        top: 70px;
        opacity: 1;
        visibility: visible;
    }
    
    .nav-links a {
        font-size: 16px;
        padding: 8px 0;
    }
    
    .panel {
        flex-basis: 90%;
        max-width: 90%;
        width: 90%;
    }
    
    .panel-left {
        flex-basis: 85%;
        max-width: 380px;
        min-width: 260px;
        width: 85%;
        top: 380px;
    }
    
    .panel-left .panel-content {
        padding: 20px;
    }
    
    .panel-left .panel-content h2 {
        font-size: clamp(20px, 5vw, 24px);
        margin-bottom: 12px;
    }
    
    .panel-left .panel-content p {
        font-size: clamp(13px, 3.5vw, 14px);
        line-height: 1.5;
    }
    
    /* Hide strength panels on mobile */
    .panel-bottom {
        display: none !important;
    }
}

/* Mobile portrait - Clean minimal design */
@media (max-width: 480px) {
    nav {
        padding: 12px 16px;
    }
    
    nav .flex.flex-col div:first-child {
        font-size: 14px;
    }
    
    nav .flex.flex-col div:last-child {
        font-size: 9px;
    }
    
    .nav-links {
        right: 16px;
        width: 180px;
        padding: 25px 16px;
        gap: 16px;
        visibility: hidden;
    }
    
    .nav-links.active {
        top: 60px;
        visibility: visible;
    }
    
    .nav-links a {
        font-size: 14px;
    }
    
    #home {
        padding: 0 16px;
    }
    
    .panel {
        flex-basis: 95%;
        max-width: 95%;
        width: 95%;
    }
    
    .panel-left {
        flex-basis: 92%;
        max-width: 340px;
        min-width: 240px;
        width: 92%;
        top: 300px;
    }
    
    .panel-left .panel-content {
        padding: 18px 20px;
    }
    
    .panel-left .panel-content h2 {
        font-size: clamp(18px, 5vw, 22px);
        margin-bottom: 12px;
    }
    
    .panel-left .panel-content p {
        font-size: clamp(12px, 3.5vw, 13px);
        line-height: 1.5;
    }
    
    /* Hide strength panels completely on mobile */
    .panel-bottom {
        display: none !important;
    }
    
    /* Adjust hero text slide for mobile with flexbox */
    #home .text-center.slide-up {
        transform: translateY(-140px);
    }
}

/* Very small screens - Ultra clean minimal */
@media (max-width: 360px) {
    nav {
        padding: 10px 12px;
    }
    
    nav .flex.flex-col div:first-child {
        font-size: 13px;
    }
    
    nav .flex.flex-col div:last-child {
        font-size: 8px;
    }
    
    .hamburger-menu {
        width: 26px;
        height: 22px;
    }
    
    .hamburger-line {
        height: 2.5px;
    }
    
    .nav-links {
        right: 12px;
        width: 160px;
        padding: 20px 12px;
        gap: 14px;
        visibility: hidden;
    }
    
    .nav-links.active {
        top: 55px;
        visibility: visible;
    }
    
    .nav-links a {
        font-size: 13px;
    }
    
    #home {
        padding: 0 12px;
    }
    
    .panel-left {
        flex-basis: 96%;
        max-width: 310px;
        min-width: 200px;
        width: 96%;
        top: 280px;
    }
    
    .panel-left .panel-content {
        padding: 16px 18px;
    }
    
    .panel-left .panel-content h2 {
        font-size: clamp(16px, 5vw, 20px);
        margin-bottom: 10px;
    }
    
    .panel-left .panel-content p {
        font-size: clamp(11px, 3.5vw, 12px);
        line-height: 1.4;
    }
    
    /* No strength panels on very small screens */
    .panel-bottom {
        display: none !important;
    }
    
    #home .text-center.slide-up {
        transform: translateY(-120px);
    }
}