/* =========================================
   1. VARIABLES & RESET
   ========================================= */
:root {
    /* Colors */
    --bg-dark: #0a0a0a;
    --bg-darker: #050505;
    --bg-card: #141414;
    --text-main: #ffffff;
    --text-muted: #a0a0a0;
    --accent: #00d084;
    /* Neon Teal */
    --accent-glow: rgba(0, 208, 132, 0.4);

    /* Fonts */
    --font-heading: 'Montserrat', sans-serif;
    --font-body: 'Spline Sans', sans-serif;

    /* Spacing */
    --container-width: 1200px;
    --section-padding: 100px 0;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: 0.3s ease;
}

ul {
    list-style: none;
}

h1,
h2,
h3,
h4 {
    font-family: var(--font-heading);
    font-weight: 700;
    text-transform: uppercase;
}

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
}

.text-center {
    text-align: center;
}

.accent-text {
    color: var(--accent);
}

/* =========================================
   2. BUTTONS & UI ELEMENTS
   ========================================= */
.btn-primary {
    display: inline-block;
    padding: 15px 40px;
    background-color: var(--accent);
    color: #000;
    font-weight: 700;
    font-family: var(--font-heading);
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: 50px;
    /* Round shape */
    transition: all 0.3s ease;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 0 20px var(--accent-glow);
}

.btn-outline {
    display: inline-block;
    padding: 12px 30px;
    border: 1px solid var(--text-muted);
    color: var(--text-main);
    font-family: var(--font-heading);
    font-weight: 600;
    margin-top: 20px;
    border-radius: 50px;
    /* Round shape */
    transition: 0.3s ease;
}

.btn-outline:hover {
    border-color: var(--accent);
    color: var(--accent);
}

/* =========================================
   3. NAVIGATION & SIDEBAR
   ========================================= */
/* =========================================
   3. NAVIGATION & SIDEBAR
   ========================================= */
.main-nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 20px 40px;
    display: flex;
    justify-content: space-between;
    /* Space out Logo, Links, Button */
    align-items: center;
    z-index: 1000;
    background-color: #000;

    /* Animation */
    /* Use 'both' to apply 0% state immediately and keep 100% state at end */
    animation: slideDownNav 0.5s ease both;
    animation-delay: 1s;
}

@keyframes slideDownNav {
    0% {
        transform: translateY(-100%);
        opacity: 0;
    }

    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

.logo {
    font-family: var(--font-body);
    /* Looks like sans-serif in ref */
    font-weight: 700;
    font-size: 1.5rem;
    color: #fff;
    letter-spacing: -0.5px;
}

.logo a {
    position: relative;
    padding-bottom: 5px;
}

.logo a.active {
    color: var(--accent);
}

.logo a.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--accent);
    box-shadow: 0 0 10px var(--accent-glow);
}

.nav-links {
    display: flex;
    gap: 30px;
    align-items: center;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    /* Center the links absolute to the screen */
}

.nav-links a {
    font-size: 0.95rem;
    font-weight: 500;
    color: #ccc;
    position: relative;
    padding-bottom: 5px;
}

.nav-links a:hover,
.nav-links a.active {
    color: #fff;
}

/* Underline indicator for active link */
.nav-links a.active::after,
.logo a.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--accent);
    box-shadow: 0 0 10px var(--accent-glow);
    animation: slideDownIndicator 0.3s ease forwards;
}

@keyframes slideDownIndicator {
    from {
        transform: translateY(-10px);
        opacity: 0;
    }

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

.btn-portfolio {
    background-color: var(--accent);
    color: #000;
    font-weight: 700;
    padding: 12px 30px;
    /* Increased padding */
    border-radius: 50px;
    /* Fully rounded (capsule/pill) */
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: 0.3s ease;
    text-transform: uppercase;
    /* Match typical button style */
}

.btn-portfolio:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 15px var(--accent-glow);
}

.mobile-menu-btn {
    display: none;
    font-size: 1.5rem;
    color: var(--text-main);
}

/* =========================================
   4. HERO SECTION
   ========================================= */
.hero-section {
    position: relative;
    height: 100vh;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* Placeholder for background video/image */
/* =========================================
   FIXED VIDEO BACKGROUND
   ========================================= */
.video-bg-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -999;
    /* Stay behind everything */
    overflow: hidden;
    background-color: #000;
    /* Fallback color */
}

.video-bg {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.3;
    /* Dark overlay effect built-in */
}

/* Texture Overlay for Cinematic Feel */
.video-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 50px 50px;
    z-index: -998;
    pointer-events: none;
}

/* =========================================
   TYPEWRITER / WORD SWAP ANIMATION
   ========================================= */
.typing-container {
    font-size: 2.5rem;
    font-family: var(--font-heading);
    font-weight: 700;
    margin-bottom: 40px;
}

.typing-static {
    color: var(--text-main);
}

.typing-dynamic {
    color: var(--accent);
    position: relative;
}

.typing-dynamic::after {
    content: '';
    position: absolute;
    right: -5px;
    top: 10%;
    width: 3px;
    height: 80%;
    background-color: var(--accent);
    animation: blink 0.8s infinite;
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }
}

/* =========================================
   PROJECT CARDS (HOVER OVERLAY)
   ========================================= */
.projects-grid {
    display: flex;
    overflow-x: auto;
    gap: 30px;
    margin-top: 40px;
    padding-bottom: 20px;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    /* Smooth scrolling for JS */
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    /* Hide scrollbar Firefox */
    -ms-overflow-style: none;
    /* IE */
}

.projects-grid::-webkit-scrollbar {
    display: none;
    /* Hide scrollbar Chrome/Safari */
}

/* Navigation Buttons */
.project-nav {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 20px;
}

.nav-btn {
    background: transparent;
    border: 1px solid var(--accent);
    color: var(--accent);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
    font-size: 1.2rem;
}

.nav-btn:hover {
    background: var(--accent);
    color: #000;
    box-shadow: 0 0 10px var(--accent-glow);
}

.project-card {
    position: relative;
    height: 400px;
    flex: 0 0 28%;
    /* Show 3.5 items (approx 28% * 3.5 + gaps = 100%) */
    min-width: 280px;
    scroll-snap-align: start;

    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    background-color: var(--bg-card);
}

/* Back to Start Button Styling */
.project-restart-container {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 150px;
    /* Narrow slot at the end */
    height: 400px;
    /* Match card height */
    scroll-snap-align: center;
}

.btn-restart-round {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    border: 1px solid var(--accent);
    background: rgba(0, 0, 0, 0.3);
    color: var(--accent);
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    /* Bouncy transition */
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-restart-round:hover {
    background: var(--accent);
    color: #000;
    transform: scale(1.1) rotate(-360deg);
    box-shadow: 0 0 20px var(--accent-glow);
}

.project-thumbnail {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.project-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: auto;
    max-height: 60%;
    padding: 20px 25px;
    background: linear-gradient(to top,
            rgba(0, 0, 0, 0.95) 0%,
            rgba(0, 0, 0, 0.85) 50%,
            rgba(0, 0, 0, 0.4) 80%,
            rgba(0, 0, 0, 0) 100%);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    opacity: 0;
    transition: opacity 0.4s ease;
    border-bottom: 2px solid var(--accent);
}

/* Hover Effects */
.project-card:hover .project-overlay {
    opacity: 1;
}

.project-card:hover .project-thumbnail {
    transform: scale(1.1);
}

.project-title {
    font-size: 1.5rem;
    color: var(--accent);
    margin-bottom: 5px;
}

.project-company {
    font-size: 0.9rem;
    color: var(--text-muted);
    font-style: italic;
    margin-bottom: 20px;
}

.project-desc {
    font-size: 0.95rem;
    color: #ddd;
    line-height: 1.5;
}

.hero-content {
    text-align: center;
    z-index: 1;
    width: 100%;
}

.hero-title-large {
    font-family: var(--font-heading);
    /* Heavy font */
    font-size: 7rem;
    /* Massive size */
    font-weight: 900;
    color: #e0e0e0;

    line-height: 1;
    text-transform: uppercase;
    margin-bottom: 10px;
    letter-spacing: -2px;

    /* Animation: Scale Down + Drop In + Fade */
    opacity: 0;
    animation: heroReveal 3s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    animation-delay: 0.5s;
    text-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
}

@keyframes heroReveal {
    0% {
        opacity: 0;
        transform: scale(1.15) translateY(-30px);
    }

    100% {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.hero-subtitle-modern {
    font-family: var(--font-body);
    font-size: 3rem;
    font-weight: 600;
    color: #fff;
    text-transform: capitalize;

    /* Standard Centering */
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1px;
    width: 100%;

    /* Animation */
    opacity: 0;
    animation: fadeInUp 1.5s ease-out forwards;
    animation-delay: 1.5s;
}

.subtitle-dynamic,
.subtitle-static {
    /* No forced width or flex-grow, just natural width */
    display: inline-block;
}

.hero-subtitle-modern .accent-text {
    color: var(--accent);
    font-weight: 700;
}

.hero-subtitle {
    font-size: 1.2rem;
    letter-spacing: 5px;
    color: var(--accent);
    margin-bottom: 20px;
}

.hero-title {
    font-size: 5rem;
    line-height: 1;
    margin-bottom: 30px;
    text-shadow: 0 0 30px rgba(0, 0, 0, 0.5);
}

.hero-description {
    font-size: 1.2rem;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto 40px;
}

.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    opacity: 0.7;
}

/* Typing Cursor Effect */
.typing-cursor::after {
    content: '|';
    animation: blinkCursor 0.8s step-end infinite;
    color: var(--accent);
    margin-left: 2px;
}

@keyframes blinkCursor {

    from,
    to {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }
}

.mouse {
    width: 26px;
    height: 40px;
    border: 2px solid var(--text-muted);
    border-radius: 15px;
    position: relative;
}

.wheel {
    width: 4px;
    height: 8px;
    background-color: var(--accent);
    border-radius: 2px;
    position: absolute;
    top: 6px;
    left: 50%;
    transform: translateX(-50%);
    animation: scroll 1.5s infinite;
}

/* =========================================
   TEXT STROKE ANIMATION
   ========================================= */
.text-stroke-animation {
    --text-content: 'VISUAL DESIGN & COMBAT';
    /* Default text, will be overridden inline or by JS if needed */
    --text-color: var(--accent);
    /* Using our neon teal variable */
    --stroke-width: 2px;
    --animation-duration: 6s;

    position: relative;
    color: transparent;
    /* Hide the fill color of the base text */
    -webkit-text-stroke: var(--stroke-width) var(--text-color);
    display: inline-block;
}

.text-stroke-animation::after {
    content: attr(data-text);
    /* Dynamically get text from HTML attribute */
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 100%;
    color: var(--text-color);
    -webkit-text-stroke: 0px transparent;
    border-right: var(--stroke-width) solid var(--text-color);
    overflow: hidden;
    white-space: nowrap;
    /* Ensure text doesn't wrap during width animation */
    animation: slide var(--animation-duration) linear infinite;
}

@keyframes slide {

    0%,
    10% {
        width: 0;
    }

    70%,
    90% {
        width: 100%;
    }

    100% {
        width: 0;
    }
}

@keyframes scroll {
    0% {
        top: 6px;
        opacity: 1;
    }

    100% {
        top: 20px;
        opacity: 0;
    }
}

/* =========================================
   5. BIO / STATS SECTION
   ========================================= */
/* =========================================
   5. BIO / STATS SECTION (Refactored)
   ========================================= */
.bio-section {
    padding: var(--section-padding);
    background-color: var(--bg-darker);
    /* Keeping dark theme */
    color: var(--text-main);
}

.bio-grid-new {
    display: grid;
    grid-template-columns: 0.8fr 2.6fr 1.1fr;
    /* Stats - Text (Wider) - Image (Narrower) */
    gap: 40px;
    align-items: stretch;
    /* All columns equal height */
}

/* --- Left Column: Stats --- */
.bio-stats-column {
    grid-row: 1 / span 2;
    /* Spans height of Title + Content */
    display: flex;
    flex-direction: column;
    align-items: center;
    border-right: 1px dotted rgba(255, 255, 255, 0.2);
    padding-right: 20px;
}

.stat-block {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    margin: 15px 0;
    /* increased from 10px */
}

.stat-icon {
    font-size: 1.3rem;
    /* increased from 1rem */
    color: var(--text-muted);
    margin-bottom: 8px;
    opacity: 0.8;
}

.stat-value {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    /* increased from 1rem */
    font-weight: 700;
    line-height: 1.2;
    color: var(--accent);
    /* Changed to Accent Color */
}

.stat-desc {
    font-size: 0.65rem;
    /* increased from 0.5rem */
    text-transform: uppercase;
    color: var(--text-muted);
    letter-spacing: 1px;
    margin-top: 5px;
    max-width: 80px;
}

.stat-divider {
    width: 1px;
    height: 20px;
    /* increased from 15px */
    background-color: rgba(255, 255, 255, 0.1);
    margin: 5px 0;
}

/* --- Center Column: Text --- */
.bio-text-column {
    padding: 1px 0;
    /* Minimal top padding */
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    /* Align content to top, not center */
}

/* Header Wrapper */
/* Header Wrapper - Spans Text and Image Columns */
.bio-header {
    grid-column: 2 / -1;
    text-align: left;
    margin-bottom: 10px;
    /* Tighter gap to paragraphs */
    align-self: end;
}

.bio-title-large {
    font-size: 2.2rem;
    /* Large impact title */
    line-height: 1.1;
    color: var(--text-main);
    letter-spacing: -1px;
    font-weight: 800;
}

.bio-paragraphs p {
    font-size: 1.1rem;
    /* Increased font size */
    line-height: 1.9;
    /* More breathing room */
    color: #bbb;
    margin-bottom: 25px;
    text-align: left !important;
    /* Clean text block */
}

.bio-paragraphs strong {
    color: #fff;
    font-weight: 700;
}

.bio-cta {
    margin-top: 20px;
    text-align: center;
    /* Center align text */
    border-top: none;
    padding-top: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    /* Center align items */
    gap: 15px;
}

.logo-signature {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 900;
    color: var(--text-main);
    margin-bottom: 0;
}

.cta-text {
    margin-bottom: 0;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.icon-box {
    display: flex;
    gap: 15px;
}

/* --- Right Column: Image --- */
.bio-image-column {
    position: relative;
    height: 100%;
    /* No min-height fixed, let content drive or flex stretch */
    display: flex;
    align-items: flex-start;
    /* Align image to top */
    padding-top: 5px;
    /* Slight buffer if needed, or 0 */
}

.portrait-container {
    width: 100%;
    max-width: 300px;
    /* Reduced size to 300px (was 500px) */
    aspect-ratio: 1 / 1;
    /* Force Square Ratio */
    overflow: hidden;
    border-radius: 50%;
    /* Circle Shape */
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    margin: 0 auto;
    /* Center horizontally if smaller than col */
}

.portrait-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.9;
    transition: 0.5s ease;
}

.portrait-img:hover {
    opacity: 1;
    transform: scale(1.02);
}

@media screen and (max-width: 900px) {
    .bio-grid-new {
        grid-template-columns: 1fr;
    }

    .bio-stats-column {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: space-around;
        border-right: none;
        border-bottom: 1px dotted rgba(255, 255, 255, 0.2);
        padding-bottom: 20px;
        margin-bottom: 30px;
    }

    .stat-block {
        margin: 10px;
    }

    .bio-image-column {
        min-height: 400px;
    }
}

.image-placeholder {
    width: 100%;
    height: 400px;
    background-color: var(--bg-card);
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 5rem;
    color: var(--text-muted);
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
}

.image-placeholder::after {
    content: '';
    position: absolute;
    top: 20px;
    right: 20px;
    bottom: -20px;
    left: -20px;
    border: 1px solid var(--accent);
    z-index: -1;
    opacity: 0.5;
}

/* =========================================
   PROJECTS SECTION (EXPERIENCE)
   ========================================= */
.projects-section {
    position: relative;
    height: 100vh;
    /* Fix height to full screen */
    display: flex;
    flex-direction: column;
    justify-content: center;
    /* Center vertical */
    overflow: hidden;
    /* No vertical scroll */
    background-color: var(--bg-dark);
    /* Ensure background covers */
    padding: 0 var(--section-padding);
}

/* =========================================
   6. TIMELINE SECTION
   ========================================= */
.timeline-section {
    padding: var(--section-padding);
    background-color: var(--bg-dark);
}

.timeline {
    position: relative;
    max-width: 1000px;
    margin: 60px auto 0;
}

/* The vertical line */
.timeline::after {
    content: '';
    position: absolute;
    width: 2px;
    background-color: rgba(255, 255, 255, 0.1);
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -1px;
}

.timeline-item {
    padding: 10px 20px;
    position: relative;
    width: 50%;
    margin-bottom: -10px;
    /* Negative margin for overlap on desktop */
}

/* Circles on the line */
.timeline-item::after {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    box-sizing: border-box;
    /* Ensure border is included in width/height */
    right: 0;
    /* Align to right edge of the 50% box */
    transform: translateX(50%);
    /* Move right by 50% of its own width (8px) to center on the line */
    background-color: var(--bg-dark);
    border: 3px solid var(--accent);
    top: 25px;
    border-radius: 50%;
    z-index: 1;
    transition: 0.3s ease;
}

.timeline-item:hover::after {
    background-color: var(--accent);
    box-shadow: 0 0 15px var(--accent-glow);
}

/* Left and Right placement */
.left {
    left: 0;
    text-align: right;
}

.right {
    left: 50%;
    text-align: left;
}

.right::after {
    right: auto;
    /* Unset the right property from .timeline-item::after */
    left: 0;
    /* Align to left edge of the 50% box */
    transform: translateX(-50%);
    /* Move left by 50% of its own width (8px) to center on the line */
}

.timeline-content {
    background-color: transparent;
    padding: 20px;
    border-radius: 8px;
    /* Removed border and background */
    transition: 0.3s ease;
}

.timeline-item:hover .timeline-content {
    transform: translateY(-5px);
    border-color: rgba(0, 208, 132, 0.3);
}

.date {
    display: inline-block;
    background-color: rgba(0, 208, 132, 0.1);
    color: var(--accent);
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 15px;
}

.role {
    font-size: 1.5rem;
    margin-bottom: 5px;
}

.company {
    font-size: 1rem;
    color: var(--text-muted);
    font-weight: 400;
    margin-bottom: 15px;
}

.link-arrow {
    font-size: 0.9rem;
    color: var(--accent);
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-top: 10px;
}

.link-arrow i {
    transition: 0.3s ease;
}

.link-arrow:hover i {
    transform: translateX(5px);
}

/* =========================================
   7. FOOTER
   ========================================= */
.main-footer {
    padding: 50px 0;
    background-color: #000;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    text-align: center;
    color: var(--text-muted);
}

.footer-logo {
    color: var(--text-main);
    font-family: var(--font-heading);
    font-weight: 700;
    margin-bottom: 20px;
}

/* =========================================
   8. ANIMATIONS & RESPONSIVE
   ========================================= */

/* Keyframes */
@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

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

/* Base Animation Classes */
.fade-in {
    opacity: 0;
    /* Hidden by default */
    /* Will be triggered by JS adding .visible */
    transition: opacity 1s ease-out, transform 1s ease-out;
}

.fade-in-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 1s ease-out, transform 1s ease-out;
}

.visible {
    opacity: 1 !important;
    /* Only force transform reset if it's NOT a timeline content item (which needs transform for hover) */
    /* We use a specific override below instead of :not() for better browser support/specificity management if needed */
    transform: translateY(0) !important;
}

/* Override transform for timeline content to allow hover effect */
.timeline-content.visible {
    transform: none !important;
    /* Reset any entering transform */
}

/* Allow hover to win over .visible */
.timeline-content.visible:hover {
    transform: translateY(-5px) !important;
}

/* Ensure left/right animations reach 0 */
.timeline-slide-in-right.visible,
.timeline-slide-in-left.visible {
    left: 0 !important;
}

/* Staggered Delays for Scroll Elements */
.delay-100 {
    transition-delay: 0.1s;
}

.delay-200 {
    transition-delay: 0.2s;
}

.delay-300 {
    transition-delay: 0.3s;
}

/* Timeline Animations */

.timeline-slide-in-right {
    opacity: 0;
    position: relative;
    left: -80%;
    /* Start from deep inside (left) */
    transition: opacity 1s ease-out, left 1s ease-out;
    /* Animate LEFT, not Transform */
}

.timeline-slide-in-left {
    opacity: 0;
    position: relative;
    left: 80%;
    /* Start from deep inside (right) */
    transition: opacity 1s ease-out, left 1s ease-out;
    /* Animate LEFT, not Transform */
}


/* =========================================
   9. TIMELINE MASK
   ========================================= */
.timeline-mask {
    position: relative;
    width: 100%;
    height: 100%;
}

.timeline-item.right .timeline-mask {
    /* Clip Left side (timeline side) */
    /* top right bottom left */
    clip-path: inset(-100px -100px -100px 0);
}

.timeline-item.left .timeline-mask {
    /* Clip Right side (timeline side) */
    clip-path: inset(-100px 0 -100px -100px);
}

/* Fix Hover Effect conflict with .visible class */
.timeline-item:hover .timeline-content {
    transform: translateY(-5px) !important;
    border-color: rgba(0, 208, 132, 0.3);
}

/* =========================================
   10. SKILLS SECTION (NEW LAYOUT)
   ========================================= */
.skills-section {
    width: 100%;
    background-color: var(--bg-darker);
    overflow: hidden;
    padding: 0;
    /* Remove default padding to let image touch edges if needed */
}

.skills-container-fluid {
    /* Full width container */
    width: 100%;
    max-width: 100%;
    margin: 0;
}

.skills-grid {
    display: grid;
    grid-template-columns: 0.8fr 1.5fr 1.2fr;
    /* 20% - 40% - 40% approx */
    min-height: 800px;
    /* Ensure tall height */
}

/* Left Column: Title */
.skills-left {
    padding: 100px 60px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.skills-main-title {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 20px;
    color: var(--text-main);
}

.skills-line {
    width: 100%;
    max-width: 200px;
    height: 1px;
    background-color: rgba(255, 255, 255, 0.3);
    margin-bottom: 20px;
}

.skills-subtitle {
    font-size: 1rem;
    color: var(--accent);
    letter-spacing: 2px;
    font-weight: 600;
}

/* Center Column: Content */
.skills-center {
    padding: 100px 40px;
    border-left: 1px solid rgba(255, 255, 255, 0.05);
}

.skill-category {
    margin-bottom: 50px;
}

.skill-cat-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 20px;
    text-transform: uppercase;
}

.skill-cat-title .text-muted {
    color: var(--text-muted);
    font-size: 0.9rem;
    text-transform: none;
    font-weight: 400;
    margin-left: 10px;
}

.skill-list {
    list-style: none;
    padding-left: 10px;
}

.skill-list li {
    position: relative;
    padding-left: 20px;
    margin-bottom: 15px;
    color: #ccc;
    font-size: 0.95rem;
    line-height: 1.6;
}

.skill-list li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: var(--text-muted);
    font-size: 1.2rem;
    line-height: 1;
    top: -2px;
}

.skill-list strong {
    color: #fff;
    font-weight: 600;
}

/* Right Column: Image */
.skills-right {
    position: relative;
    height: 100%;
    width: 100%;
}

.skills-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.8;
}

.skills-right::after {
    /* Gradient overlay to blend with dark theme */
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, var(--bg-darker) 0%, transparent 20%);
}

/* Responsive */
@media screen and (max-width: 1024px) {
    .skills-grid {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto 400px;
    }

    .skills-left,
    .skills-center {
        padding: 60px 20px;
        border-left: none;
    }

    .skills-left {
        padding-bottom: 0;
    }
}

/* =========================================
   11. FOOTER UPDATES
   ========================================= */
.footer-info-grid {
    display: flex;
    justify-content: center;
    gap: 80px;
    flex-wrap: wrap;
    align-items: flex-start;
    /* Trigger alignment to top */
    padding-top: 20px;
}

.footer-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    text-align: center;
}

.footer-icon {
    font-size: 2.5rem;
    color: var(--text-main);
    margin-bottom: 5px;
    transition: 0.3s ease;
}

.footer-item:hover .footer-icon {
    color: var(--accent);
    transform: translateY(-5px);
}

.footer-label {
    font-family: var(--font-heading);
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--text-muted);
}

.hero-title {
    opacity: 0;
    animation: fadeIn 1.5s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    animation-delay: 0.8s;
    /* Wait for video/bg to settle */
}



.hero-subtitle {
    opacity: 0;
    animation: fadeInUp 1.5s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    animation-delay: 1.8s;
    /* Appears after title */
}

.hero-description {
    opacity: 0;
    animation: fadeInUp 1.5s ease-out forwards;
    animation-delay: 2.2s;
}

.hero-content .btn-primary {
    opacity: 0;
    animation: fadeIn 1s ease-out forwards;
    animation-delay: 2.6s;
}

/* Scroll Indicator */
.scroll-indicator {
    opacity: 0;
    animation: fadeIn 2s ease-out forwards;
    animation-delay: 3.5s;
    /* Last thing to appear */
}

/* CTA Title Desktop */
.cta-title {
    font-size: 3.5rem;
}

/* Mobile Responsive */
@media screen and (max-width: 768px) {
    .container {
        padding: 0 15px;
    }

    .main-nav {
        padding: 15px 15px;
    }

    /* Hero Section Mobile - Fix title overflow */
    .hero-title,
    .hero-title-large {
        font-size: 3rem;
        word-break: break-word;
        letter-spacing: -1px;
    }

    .hero-subtitle-modern {
        font-size: 1rem;
    }

    .hero-content {
        padding: 0 15px;
        text-align: center;
    }

    /* CTA Section Mobile */
    .cta-title {
        font-size: 2rem !important;
    }

    .cta-section {
        height: auto !important;
        min-height: 40vh;
        padding: 40px 0;
    }

    /* Bio Section Mobile - Complete overhaul */
    .bio-grid-new {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .bio-stats-column {
        order: 1;
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        gap: 15px;
        border-right: none;
        border-bottom: 1px dotted rgba(255, 255, 255, 0.2);
        padding-right: 0;
        padding-bottom: 20px;
    }

    .stat-block {
        margin: 5px 10px;
    }

    .bio-header {
        order: 2;
        grid-column: 1;
        text-align: center;
    }

    .bio-header .section-title {
        font-size: 1.8rem;
        text-align: left;
    }

    .bio-text-column {
        order: 3;
        padding: 0;
        text-align: left;
    }

    .bio-text-column p {
        text-align: left !important;
        text-align-last: left !important;
    }

    .bio-image-column {
        order: 4;
        min-height: 250px;
        display: flex;
        justify-content: center;
    }

    .portrait-frame {
        width: 180px;
        height: 180px;
    }

    .portrait-img {
        width: 100%;
        height: 100%;
    }

    /* Timeline Mobile */
    .timeline::after {
        left: 31px;
    }

    .timeline-item {
        width: 100%;
        padding-left: 70px;
        padding-right: 15px;
        margin-bottom: 30px;
    }

    .timeline-item::after {
        left: 23px;
    }

    .left {
        text-align: left;
    }

    .right {
        left: 0;
    }

    .sidebar-socials {
        display: none;
    }

    /* Skills Section Mobile */
    .skills-grid {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto !important;
        gap: 20px;
        min-height: auto !important;
        padding: 40px 20px;
    }

    .skills-left {
        padding: 0;
        text-align: center;
        align-items: center;
    }

    .skills-center {
        padding: 0;
        border-left: none;
    }

    .skills-right {
        display: none !important;
        height: 0 !important;
    }

    .skill-category {
        margin-bottom: 25px;
    }

    .skill-cat-title {
        font-size: 1rem;
    }

    .skill-list li {
        font-size: 0.9rem;
    }

    /* Partners Section Mobile */
    .partners-grid {
        gap: 15px !important;
    }

    .partner-logo {
        height: 25px !important;
        margin: 8px !important;
    }

    /* Footer Mobile */
    .footer-info-grid {
        flex-direction: column;
        gap: 20px;
        text-align: center;
        align-items: center;
    }

    .footer-item {
        flex-direction: column;
        gap: 10px;
        align-items: center;
        justify-content: center;
        width: 100%;
    }

    .footer-label {
        text-align: center;
    }

    /* CTA Section Mobile */
    .hero-section[style*="60vh"] {
        height: auto !important;
        padding: 60px 15px;
    }

    .hero-section[style*="60vh"] .hero-title {
        font-size: 1.8rem;
    }

    /* Typing Container */
    .typing-container {
        font-size: 1.5rem;
    }

    /* Section Title Mobile */
    .section-title {
        font-size: 1.8rem;
    }

    /* Nav Links Mobile Dropdown */
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: auto;
        transform: none;
        right: 15px;
        width: 200px;
        background-color: #000;
        flex-direction: column;
        padding: 15px;
        border-bottom-left-radius: 10px;
        border-bottom-right-radius: 10px;
        border: 1px solid rgba(255, 255, 255, 0.1);
        border-top: none;
    }

    .nav-links.mobile-active {
        display: flex;
        animation: slideDownMenu 0.3s ease forwards;
    }

    @keyframes slideDownMenu {
        from {
            opacity: 0;
            transform: translateY(-10px);
        }

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

    .mobile-menu-btn {
        display: block;
    }

    /* Portfolio Button Mobile */
    .btn-portfolio {
        padding: 8px 15px;
        font-size: 0.75rem;
    }

    /* Logo Mobile */
    .logo {
        font-size: 1.1rem;
    }
}

/* ADDED BY ANTIGRAVITY: PARTNER LOGOS */
.partner-logo {
    height: 80px !important;
    /* Increased size */
    max-width: 160px;
    width: auto;
    object-fit: contain;
    padding: 12px 20px;
    background: rgba(255, 255, 255, 0.03);
    /* Subtle glass bg */
    backdrop-filter: blur(4px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: pointer;
    vertical-align: middle;
}

.partner-logo:hover {
    transform: translateY(-5px) scale(1.05);
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
    box-shadow: 0 10px 30px rgba(0, 208, 132, 0.15);
}