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

:root {
    /* Core colors */
    --color-primary: #0071e3;
    --color-primary-light: #2997ff;
    --color-primary-dark: #005bbf;
    --color-secondary: #ff6b9d;
    --color-accent: #9857d3;

    /* Holographic Gradients - Cosmic Blue */
    --gradient-primary: linear-gradient(135deg, #0071e3 0%, #00a2ff 50%, #00d2ff 100%);
    --gradient-hover: linear-gradient(135deg, #2997ff 0%, #4dc4ff 50%, #80e0ff 100%);
    --gradient-text: linear-gradient(135deg, #2997ff, #00d2ff);

    /* Theme colors - Light */
    --bg-primary: #f5f5f7;
    --bg-secondary: #ffffff;
    --text-primary: #1d1d1f;
    --text-secondary: #6e6e73;
    --accent: var(--color-primary);
    --accent-hover: var(--color-primary-light);

    /* Glass effects */
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(255, 255, 255, 0.5);
    --glass-shadow: rgba(0, 0, 0, 0.1);

    /* Navigation */
    --nav-bg: rgba(255, 255, 255, 0.8);
    --nav-border: rgba(255, 255, 255, 0.1);
    --nav-item-bg: rgba(255, 255, 255, 0.4);
    --nav-item-hover: rgba(255, 255, 255, 0.6);
    --nav-shadow: rgba(0, 0, 0, 0.05);

    /* Typography */
    --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-heading: 'Outfit', sans-serif;
    --font-size-base: 16px;
    --line-height-base: 1.6;

    /* Spacing */
    --space-xs: 0.25rem;
    --space-sm: 0.5rem;
    --space-md: 1rem;
    --space-lg: 1.5rem;
    --space-xl: 2rem;
    --space-2xl: 3rem;

    /* Transitions */
    --transition-fast: 200ms;
    --transition-base: 300ms;
    --transition-slow: 500ms;
    --ease-bounce: cubic-bezier(0.4, 2.5, 0.6, 1);
    --ease-spring: cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);

    /* Border radius */
    --radius-sm: 0.25rem;
    --radius-md: 0.5rem;
    --radius-lg: 1rem;
    --radius-xl: 1.5rem;
    --radius-2xl: 2rem;

    /* Elevation - Box shadows */
    --elevation-1: 0 2px 4px var(--glass-shadow);
    --elevation-2: 0 4px 8px var(--glass-shadow);
    --elevation-3: 0 8px 16px var(--glass-shadow);
    --elevation-4: 0 12px 24px var(--glass-shadow);
    --elevation-5: 0 16px 32px var(--glass-shadow);
}

[data-theme="dark"] {
    /* Theme colors - Dark (Deep Space) */
    --bg-primary: #050507;
    --bg-secondary: #0a0a0c;
    --text-primary: #f5f5f7;
    --text-secondary: #a1a1a6;
    --accent: #2997ff;
    --accent-hover: #409cff;

    /* Glass effects - Dark */
    --glass-bg: rgba(20, 20, 25, 0.6);
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-shadow: rgba(0, 0, 0, 0.5);

    /* Navigation - Dark */
    --nav-bg: rgba(0, 0, 0, 0.7);
    --nav-border: rgba(255, 255, 255, 0.05);
    --nav-item-bg: rgba(255, 255, 255, 0.1);
    --nav-item-hover: rgba(255, 255, 255, 0.15);
    --nav-shadow: rgba(0, 0, 0, 0.2);

    /* Elevation - Dark mode adjustments */
    --elevation-1: 0 2px 4px rgba(0, 0, 0, 0.3);
    --elevation-2: 0 4px 8px rgba(0, 0, 0, 0.35);
    --elevation-3: 0 8px 16px rgba(0, 0, 0, 0.4);
    --elevation-4: 0 12px 24px rgba(0, 0, 0, 0.45);
    --elevation-5: 0 16px 32px rgba(0, 0, 0, 0.5);
}

body {
    font-family: var(--font-primary);
    background: var(--bg-primary);
    color: var(--text-primary);
    overflow-x: hidden;
    min-height: 100vh;
    transition: background 0.3s ease, color 0.3s ease;
    position: relative;
    padding-top: 100px;
    /* Add padding for fixed nav */
}

/* Noise Texture Overlay */
body::after {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 9999;
    pointer-events: none;
    background-image: 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.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.05'/%3E%3C/svg%3E");
    opacity: 0.4;
    mix-blend-mode: overlay;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(circle at 20% 50%, rgba(120, 119, 198, 0.3), transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(255, 107, 107, 0.3), transparent 50%),
        radial-gradient(circle at 40% 20%, rgba(72, 219, 251, 0.3), transparent 50%);
    pointer-events: none;
    z-index: 0;
    opacity: 0.6;
}

[data-theme="dark"] body::before {
    background:
        radial-gradient(circle at 20% 50%, rgba(120, 119, 198, 0.15), transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(255, 107, 107, 0.15), transparent 50%),
        radial-gradient(circle at 40% 20%, rgba(72, 219, 251, 0.15), transparent 50%);
    opacity: 0.4;
}



/* Floating Nav */
.floating-nav {
    position: fixed;
    top: 24px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 1000px;
    z-index: 1000;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-content {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 12px 24px;
    border-radius: 100px;
    /* Capsule shape */
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow:
        0 10px 40px rgba(0, 0, 0, 0.08),
        0 0 0 1px rgba(255, 255, 255, 0.1);
}

[data-theme="dark"] .nav-content {
    background: rgba(20, 20, 20, 0.6);
    border-color: rgba(255, 255, 255, 0.08);
    box-shadow:
        0 10px 40px rgba(0, 0, 0, 0.2),
        0 0 0 1px rgba(255, 255, 255, 0.05);
}

/* Hide old nav styles */
nav {
    all: unset;
}

.logo {
    font-size: 20px;
    font-weight: 600;
    letter-spacing: -0.5px;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 8px;
    transition: transform 0.2s ease;
    text-decoration: none;
}

.logo:hover {
    transform: scale(1.02);
}

.logo i {
    font-size: 24px;
    background: linear-gradient(135deg, var(--accent), #ff6b9d);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-fill-color: transparent;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 24px;
}

.nav-links {
    display: flex;
    gap: 4px;
    list-style: none;
    align-items: center;
    background: transparent;
    padding: 0;
    border: none;
}

.nav-controls {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nav-links li {
    position: relative;
}

.nav-links a {
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    padding: 8px 16px;
    border-radius: 20px;
    transition: all 0.2s ease;
    display: block;
    position: relative;
    z-index: 1;
}

.nav-links a:hover {
    color: var(--text-primary);
    background: var(--nav-item-hover);
}

.nav-links a::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 20px;
    background: var(--accent);
    opacity: 0;
    transition: opacity 0.2s ease;
    z-index: -1;
}

.nav-links a:hover::before {
    opacity: 0.1;
}

/* Active state for nav links */
.nav-links a.active {
    color: var(--accent);
    background: var(--nav-item-hover);
}

.nav-links a.active::before {
    opacity: 0.15;
}

.theme-toggle {
    background: var(--nav-item-bg);
    backdrop-filter: blur(10px) saturate(180%);
    -webkit-backdrop-filter: blur(10px) saturate(180%);
    border: 1px solid var(--nav-border);
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 16px;
    color: var(--text-primary);
    position: relative;
    overflow: hidden;
}

.theme-toggle::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--accent);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.theme-toggle:hover {
    transform: scale(1.05);
    background: var(--nav-item-hover);
}

.theme-toggle:hover::before {
    opacity: 0.1;
}

.theme-toggle #themeIcon {
    position: relative;
    z-index: 1;
}

.hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 80px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 100px 60px;
    position: relative;
    z-index: 1;
}

.hero-content h1 {
    font-family: var(--font-heading);
    font-size: 72px;
    font-weight: 700;
    letter-spacing: -0.03em;
    margin-bottom: 24px;
    line-height: 1.05;
    color: var(--text-primary);
}

.hero-content p {
    font-size: 21px;
    color: var(--text-secondary);
    margin-bottom: 40px;
    line-height: 1.5;
    font-weight: 400;
}

.hero-image {
    position: relative;
    width: 100%;
    aspect-ratio: 1;
    border-radius: 40px;
    overflow: hidden;
    background: var(--glass-bg);
    backdrop-filter: blur(60px) saturate(200%);
    -webkit-backdrop-filter: blur(60px) saturate(200%);
    border: 1px solid var(--glass-border);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow:
        0 20px 60px var(--shadow),
        inset 0 1px 0 rgba(255, 255, 255, 0.3),
        inset 0 -1px 0 rgba(0, 0, 0, 0.1);
}

/* CHANGE 5: Added this rule to make the hero image fit 
*/
.hero-profile-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-image-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--accent) 0%, #ff6b9d 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 120px;
    position: relative;
    overflow: hidden;
}

.hero-image-placeholder::before {
    content: '';
    position: absolute;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent 30%, rgba(255, 255, 255, 0.4) 50%, transparent 70%);
    animation: shimmer 3s infinite;
}

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

    100% {
        transform: translateX(100%) translateY(100%);
    }
}

.glass-card {
    --card-padding: var(--space-2xl);
    --card-radius: var(--radius-2xl);

    background: var(--glass-bg);
    backdrop-filter: blur(40px) saturate(180%);
    -webkit-backdrop-filter: blur(40px) saturate(180%);
    border-radius: var(--card-radius);
    border: 1px solid var(--glass-border);
    padding: var(--card-padding);
    transition:
        transform var(--transition-base) var(--ease-spring),
        box-shadow var(--transition-base) var(--ease-out-expo),
        border-color var(--transition-base) var(--ease-out-expo);
    box-shadow: var(--elevation-3);
    position: relative;
    overflow: hidden;
    transform: translateZ(0);
    will-change: transform, box-shadow;

    /* Improved glass effect with gradient overlay */
    &::before {
        content: '';
        position: absolute;
        inset: 0;
        background: linear-gradient(120deg,
                rgba(255, 255, 255, 0.3),
                rgba(255, 255, 255, 0.1) 30%,
                rgba(255, 255, 255, 0) 60%);
        opacity: 0;
        transition: opacity var(--transition-base) var(--ease-out-expo);
    }

    &:hover::before {
        opacity: 1;
    }
}

.glass-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.5), transparent);
}

.glass-card:hover {
    transform: translateY(-12px) scale(1.02);
    box-shadow:
        0 20px 60px var(--shadow),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.3);
}

.cta-button {
    --button-height: 3.5rem;
    --button-padding: 0 var(--space-2xl);

    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: var(--button-height);
    padding: var(--button-padding);
    background: var(--gradient-primary);
    color: #ffffff;
    border-radius: var(--radius-2xl);
    text-decoration: none;
    font-weight: 500;
    font-size: 1.0625rem;
    letter-spacing: -0.01em;
    transition:
        transform var(--transition-base) var(--ease-spring),
        box-shadow var(--transition-base) var(--ease-out-expo),
        filter 0.3s ease;
    box-shadow:
        var(--elevation-2),
        0 0 0 0 rgba(var(--color-primary), 0.3);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transform: translateZ(0);
    will-change: transform;
    position: relative;
    overflow: hidden;
}

.cta-button::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--gradient-hover);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 0;
}

.cta-button span,
.cta-button i {
    position: relative;
    z-index: 1;
}

.cta-button:hover {
    background: var(--accent-hover);
    transform: scale(1.05);
    box-shadow: 0 12px 40px rgba(0, 113, 227, 0.5);
}

.section {
    padding: 100px 60px;
    transition: background 0.3s ease;
    position: relative;
    z-index: 1;
}

.section#education,
.section#blog {
    background: linear-gradient(135deg,
            rgba(41, 151, 255, 0.04),
            rgba(255, 107, 157, 0.04));
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-2xl);
    margin: 2rem var(--space-2xl);
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.section#education:hover,
.section#blog:hover {
    transform: translateY(-4px);
    box-shadow: var(--elevation-3);
}

.section#education::after,
.section#blog::after {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 20% 50%, rgba(41, 151, 255, 0.08), transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(255, 107, 157, 0.08), transparent 50%);
    filter: blur(60px);
    z-index: -1;
    opacity: 0.6;
    animation: subtle-pulse 8s ease-in-out infinite alternate;
}

@keyframes subtle-pulse {
    0% {
        opacity: 0.4;
        transform: scale(0.98);
    }

    100% {
        opacity: 0.6;
        transform: scale(1.02);
    }
}

.section#education::before,
.section#blog::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--bg-secondary);
    opacity: 0.92;
    z-index: -1;
}

.section:nth-child(even):not(#education):not(#blog) {
    background: var(--bg-primary);
}

.projects {
    max-width: 1200px;
    margin: 0 auto;
}

.section-title {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 60px;
    text-align: center;
    letter-spacing: -1.5px;
    color: var(--text-primary);
}

.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 32px;
}

.project-card {
    position: relative;
    overflow: hidden;
    transform: translateY(0);
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-card:hover {
    transform: translateY(-8px);
}

.project-card:hover .project-icon {
    transform: scale(1.05) rotate(-5deg);
    box-shadow: 0 12px 32px rgba(0, 113, 227, 0.4);
}

/* CHANGE 6: Modified this rule for <img> tags 
*/
.project-icon {
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    width: 80px;
    height: 80px;
    /* background: linear-gradient(135deg, var(--accent), #ff6b9d); -- REMOVED */
    border-radius: 20px;
    /* display: flex; -- REMOVED */
    /* align-items: center; -- REMOVED */
    /* justify-content: center; -- REMOVED */
    /* font-size: 36px; -- REMOVED */
    margin-bottom: 24px;
    box-shadow: 0 8px 24px rgba(0, 113, 227, 0.3);
    overflow: hidden;
    /* -- ADDED */
}

/* CHANGE 7: Added this rule for the new <img> tags 
*/
.project-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.project-card h3 {
    font-size: 28px;
    margin-bottom: 16px;
    font-weight: 600;
    color: var(--text-primary);
}

.project-card p {
    color: var(--text-secondary);
    line-height: 1.6;
    font-size: 17px;
}

.skills {
    max-width: 1000px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
    overflow: hidden;
}

/* animated soft-blobs background */
.skills::before {
    content: "";
    position: absolute;
    inset: -20%;
    z-index: 0;
    pointer-events: none;
    background:
        radial-gradient(28rem 18rem at 10% 20%, rgba(41, 151, 255, 0.18), transparent 30%),
        radial-gradient(20rem 16rem at 80% 70%, rgba(255, 107, 107, 0.14), transparent 30%),
        radial-gradient(18rem 14rem at 50% 40%, rgba(120, 119, 198, 0.12), transparent 30%);
    filter: blur(36px);
    opacity: 0.9;
    transform: translate3d(0, 0, 0);
    animation: blob-move 12s linear infinite alternate;
}

/* subtle motion for the blobs */
@keyframes blob-move {
    0% {
        transform: translate3d(-2%, -2%, 0) scale(1);
    }

    25% {
        transform: translate3d(3%, 1%, 0) scale(1.05);
    }

    50% {
        transform: translate3d(-3%, 3%, 0) scale(0.98);
    }

    75% {
        transform: translate3d(2%, -1%, 0) scale(1.02);
    }

    100% {
        transform: translate3d(-2%, -2%, 0) scale(1);
    }
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    justify-content: center;
    margin-top: 40px;
    position: relative;
    z-index: 2;
    /* keep tags above animated background */
}

.skill-tag {
    background: var(--glass-bg);
    backdrop-filter: blur(30px) saturate(180%);
    -webkit-backdrop-filter: blur(30px) saturate(180%);
    padding: var(--space-md) var(--space-lg);
    border-radius: var(--radius-2xl);
    border: 1px solid var(--glass-border);
    font-weight: 500;
    font-size: 0.9375rem;
    transition: all var(--transition-base) var(--ease-spring);
    color: var(--text-primary);
    box-shadow: var(--elevation-2);
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    cursor: pointer;
    will-change: transform;
    position: relative;
    overflow: hidden;
    transform: translateZ(0);
    backface-visibility: hidden;
}

.skill-tag::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--accent);
    opacity: 0;
    transform: scale(0.8);
    transition: all 80ms cubic-bezier(0.23, 1, 0.32, 1);
    z-index: 0;
}

.skill-tag span {
    position: relative;
    z-index: 1;
}

.skill-tag .skill-icon {
    position: relative;
    z-index: 1;
    transition: transform 120ms cubic-bezier(0.23, 1, 0.32, 1);
}

.skill-tag:hover {
    transform: translateY(-2px) scale(1.05);
    color: #ffffff;
    border-color: var(--accent);
    box-shadow:
        0 8px 16px rgba(0, 113, 227, 0.2),
        0 4px 8px rgba(0, 113, 227, 0.1);
}

.skill-tag:hover::before {
    opacity: 1;
    transform: scale(1);
}

.skill-tag:hover .skill-icon {
    transform: scale(1.2) rotate(-5deg);
}

.skill-tag:active {
    transform: translateY(0) scale(0.95);
    transition-duration: 60ms;
}

/* Add smooth entrance animation for skill tags */
.skill-tags {
    perspective: 1000px;
}

@keyframes skillTagEntrance {
    from {
        opacity: 0;
        transform: translateY(20px) rotateX(-10deg);
    }

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

.skill-tag {
    animation: skillTagEntrance 0.3s cubic-bezier(0.23, 1, 0.32, 1) both;
}

/* Stagger the entrance animation */
.skill-tag:nth-child(1) {
    animation-delay: 0.1s;
}

.skill-tag:nth-child(2) {
    animation-delay: 0.15s;
}

.skill-tag:nth-child(3) {
    animation-delay: 0.2s;
}

.skill-tag:nth-child(4) {
    animation-delay: 0.25s;
}

.skill-tag:nth-child(5) {
    animation-delay: 0.3s;
}

.skill-tag:nth-child(6) {
    animation-delay: 0.35s;
}

.skill-tag:nth-child(7) {
    animation-delay: 0.4s;
}

.skill-tag:nth-child(8) {
    animation-delay: 0.45s;
}

.skill-tag:nth-child(9) {
    animation-delay: 0.5s;
}

.skill-tag:nth-child(10) {
    animation-delay: 0.55s;
}

.skill-tag:nth-child(11) {
    animation-delay: 0.6s;
}

.skill-tag:nth-child(12) {
    animation-delay: 0.65s;
}

.skill-icon {
    font-size: 18px;
}

/* dark theme tuned */
[data-theme="dark"] .skills::before {
    background:
        radial-gradient(28rem 18rem at 10% 20%, rgba(41, 151, 255, 0.12), transparent 30%),
        radial-gradient(20rem 16rem at 80% 70%, rgba(255, 107, 107, 0.08), transparent 30%),
        radial-gradient(18rem 14rem at 50% 40%, rgba(120, 119, 198, 0.08), transparent 30%);
    filter: blur(32px) brightness(0.9);
    opacity: 0.6;
}

/* smaller screens: reduce blur & intensity */
@media (max-width: 600px) {
    .skills::before {
        inset: -30%;
        filter: blur(28px);
        opacity: 0.75;
        animation-duration: 14s;
    }
}

.contact {
    max-width: 800px;
    margin: 0 auto;
}

.contact-card {
    background: var(--glass-bg);
    backdrop-filter: blur(60px) saturate(200%);
    -webkit-backdrop-filter: blur(60px) saturate(200%);
    border-radius: 40px;
    padding: 80px 60px;
    border: 1px solid var(--glass-border);
    text-align: center;
    box-shadow:
        0 20px 60px var(--shadow),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.contact h2 {
    font-size: 48px;
    margin-bottom: 24px;
    font-weight: 700;
    color: var(--text-primary);
}

.contact p {
    font-size: 21px;
    color: var(--text-secondary);
    margin-bottom: 40px;
}

.social-links {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-top: 40px;
    flex-wrap: wrap;
}

.social-link {
    width: 56px;
    height: 56px;
    background: var(--glass-bg);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: var(--text-primary);
    font-size: 20px;
    transition: all 0.3s;
    border: 1px solid var(--glass-border);
    box-shadow: 0 4px 20px var(--shadow);
}

.social-link:hover {
    background: var(--accent);
    color: #ffffff;
    transform: scale(1.15);
    border-color: var(--accent);
    box-shadow: 0 8px 32px rgba(0, 113, 227, 0.4);
}

/* Mobile menu button styles */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 36px;
    height: 36px;
    background: var(--nav-item-bg);
    border: 1px solid var(--nav-border);
    border-radius: 50%;
    cursor: pointer;
    padding: 11px 8px;
    z-index: 1001;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.mobile-menu-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: var(--accent);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.mobile-menu-btn:hover {
    background: var(--nav-item-hover);
}

.mobile-menu-btn:hover::before {
    opacity: 0.1;
}

.mobile-menu-btn span {
    width: 20px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 1px;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    transform-origin: center;
}

.mobile-menu-btn.active {
    background: var(--nav-item-hover);
    transform: rotate(180deg);
}

.mobile-menu-btn.active span:nth-child(1) {
    transform: translateY(5px) rotate(45deg);
    background: var(--accent);
}

.mobile-menu-btn.active span:nth-child(2) {
    opacity: 0;
    transform: scale(0.5);
    background: var(--accent);
}

.mobile-menu-btn.active span:nth-child(3) {
    transform: translateY(-5px) rotate(-45deg);
    background: var(--accent);
}

/* Enhanced glass effect */
.glass-button {
    background: var(--glass-bg);
    backdrop-filter: blur(10px) saturate(180%);
    -webkit-backdrop-filter: blur(10px) saturate(180%);
    padding: 8px 16px;
    border-radius: 20px;
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
    text-decoration: none;
    font-size: 14px;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.glass-button:hover {
    background: var(--accent);
    color: #ffffff;
    border-color: var(--accent);
    transform: translateY(-2px);
}

.glass-button i {
    font-size: 16px;
}

/* Project enhancements */
.project-tech-stack {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin: 16px 0;
}

.project-tech-stack span {
    background: var(--glass-bg);
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 13px;
    border: 1px solid var(--glass-border);
}

.project-links {
    display: flex;
    gap: 12px;
    margin-top: 20px;
}

/* Blog styles */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 32px;
    max-width: 800px;
    margin: 0 auto;
}

.coming-soon {
    text-align: center;
    padding: 40px;
}

.coming-soon .blog-image {
    width: 80px;
    height: 80px;
    margin: 0 auto 24px;
    background: linear-gradient(135deg, var(--accent), #ff6b9d);
    border-radius: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    color: #ffffff;
}

.coming-soon h3 {
    font-size: 24px;
    margin-bottom: 16px;
    color: var(--text-primary);
}

.coming-soon p {
    color: var(--text-secondary);
    margin-bottom: 24px;
    line-height: 1.6;
}

.blog-topics {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
    margin-bottom: 24px;
}

.topic-tag {
    background: var(--glass-bg);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 13px;
    color: var(--text-secondary);
    border: 1px solid var(--glass-border);
}

.blog-card {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.blog-image {
    width: 100%;
    aspect-ratio: 16/9;
    background: linear-gradient(135deg, var(--accent), #ff6b9d);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
    color: #ffffff;
}

.blog-date {
    font-size: 14px;
    color: var(--text-secondary);
}

/* Timeline styles */
.timeline {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 32px;
}

.timeline-card {
    display: flex;
    gap: var(--space-lg);
    align-items: flex-start;
    padding: var(--space-xl);
    background: var(--glass-bg);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-radius: var(--radius-xl);
    border: 1px solid var(--glass-border);
    transition: transform var(--transition-base) var(--ease-spring),
        box-shadow var(--transition-base) var(--ease-out-expo);
    box-shadow: var(--elevation-2);
}

.timeline-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--elevation-3);
}

.timeline-icon {
    width: 3rem;
    height: 3rem;
    background: linear-gradient(135deg, var(--accent), var(--color-secondary));
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    color: #ffffff;
    flex-shrink: 0;
    transform: rotate(-5deg);
    transition: transform var(--transition-base) var(--ease-spring);
    box-shadow: var(--elevation-2);
}

.timeline-card:hover .timeline-icon {
    transform: rotate(0deg) scale(1.1);
}

.timeline-content {
    flex: 1;
}

.timeline-content h3 {
    font-size: 1.5rem;
    margin-bottom: var(--space-xs);
    color: var(--text-primary);
    font-weight: 600;
    letter-spacing: -0.01em;
}

.timeline-content h4 {
    font-size: 1.125rem;
    color: var(--text-secondary);
    margin-bottom: var(--space-xs);
    font-weight: 500;
}

.timeline-date {
    font-size: 0.875rem;
    color: var(--accent);
    margin-bottom: var(--space-sm);
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    padding: var(--space-xs) var(--space-sm);
    background: rgba(var(--color-primary), 0.1);
    border-radius: var(--radius-md);
}

.timeline-date i {
    font-size: 0.75rem;
}

.timeline-content p {
    color: var(--text-secondary);
    line-height: var(--line-height-base);
}

/* Interests styles */
.interests-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
    max-width: 1200px;
    margin: 0 auto;
}

.interest-card {
    text-align: center;
    padding: 32px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.hover-lift:hover {
    transform: translateY(-8px);
    box-shadow:
        0 20px 40px var(--shadow),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    border-color: var(--accent);
}

.interest-icon {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--accent), #ff6b9d);
    border-radius: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    color: #ffffff;
    margin: 0 auto 20px;
}

/* Section buttons */
.section-button {
    display: flex;
    justify-content: center;
    margin-top: 40px;
}

/* Easter egg */
/* Mystery Button */
.mystery-container {
    display: flex;
    justify-content: center;
    margin: 40px 0 20px;
    position: relative;
    z-index: 1;
}

.mystery-button {
    width: 40px;
    height: 40px;
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    font-size: 16px;
    text-decoration: none;
    border: 1px solid var(--glass-border);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0.5;
}

.mystery-button:hover {
    opacity: 1;
    transform: scale(1.1) rotate(15deg);
    color: var(--accent);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    background: var(--bg-secondary);
}

/* Loading animation */
.loading-posts {
    text-align: center;
    padding: 40px;
    color: var(--text-secondary);
}

.loading-posts i {
    font-size: 24px;
    margin-right: 10px;
}

/* More page styles */
.more-hero {
    text-align: center;
    padding: 100px 0;
    background: var(--bg-secondary);
    margin-bottom: -40px;
    position: relative;
    overflow: hidden;
}

.more-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg,
            rgba(0, 113, 227, 0.1) 0%,
            rgba(255, 107, 157, 0.1) 100%);
    z-index: 0;
}

.more-title {
    font-size: 64px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 16px;
    letter-spacing: -2px;
    position: relative;
    z-index: 1;
}

.more-subtitle {
    font-size: 24px;
    color: var(--text-secondary);
    font-weight: 400;
    position: relative;
    z-index: 1;
}

.quote-card {
    text-align: center;
    padding: 60px 40px;
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    margin-top: -80px;
}

.quote-icon {
    font-size: 32px;
    color: var(--accent);
    margin-bottom: 24px;
}

.quote-card blockquote {
    font-size: 24px;
    line-height: 1.5;
    color: var(--text-primary);
    font-weight: 500;
    margin: 0;
    margin-bottom: 20px;
}

.quote-author {
    font-size: 18px;
    color: var(--text-secondary);
}

.hobbies-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    margin: 40px 0;
}

.hobby-card {
    min-height: 300px;
    position: relative;
    overflow: hidden;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    padding: 0;
}

.hobby-content {
    padding: 32px;
    height: 100%;
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 1;
}

.hobby-icon {
    width: 60px;
    height: 60px;
    background: var(--accent);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: #ffffff;
    margin-bottom: 20px;
}

.hobby-card h3 {
    font-size: 24px;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.hobby-card p {
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 24px;
}

.hobby-badge {
    margin-top: auto;
    background: var(--glass-bg);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: 1px solid var(--glass-border);
}

.paddock-pass {
    background: linear-gradient(135deg, #FF1E1E, #FF8700);
    color: white;
    border: none;
    font-weight: 600;
    letter-spacing: 1px;
}

.hobby-card:hover {
    transform: translateY(-8px);
}

/* Mindset section styles */
.mindset-card {
    max-width: 800px;
    margin: 0 auto;
    padding: 60px;
}

.mindset-title {
    font-size: 36px;
    margin-bottom: 32px;
    color: var(--text-primary);
    text-align: center;
}

.mindset-content {
    color: var(--text-secondary);
    line-height: 1.8;
    font-size: 17px;
}

.mindset-content p {
    margin-bottom: 24px;
}

.mindset-signature {
    font-family: 'Pacifico', cursive;
    font-size: 24px;
    color: var(--accent);
    text-align: right;
    margin-top: 40px;
}

.instagram-card {
    max-width: 800px;
    margin: 0 auto;
    padding: 0;
    overflow: hidden;
}

.instagram-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 20px;
    border-bottom: 1px solid var(--glass-border);
    font-size: 18px;
    color: var(--text-primary);
}

.instagram-header i {
    font-size: 24px;
    background: linear-gradient(45deg, #405DE6, #5851DB, #833AB4, #C13584, #E1306C, #FD1D1D);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.instagram-embed {
    padding: 20px;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.loading-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    color: var(--text-secondary);
}

.loading-placeholder i {
    font-size: 24px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

@media (max-width: 768px) {
    .more-title {
        font-size: 48px;
    }

    .more-subtitle {
        font-size: 20px;
    }

    .quote-card {
        padding: 40px 24px;
        margin-top: -60px;
    }

    .quote-card blockquote {
        font-size: 20px;
    }

    .photo-grid {
        grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    }
}

/* Legal Pages Styles */
.legal-section {
    min-height: calc(100vh - 200px);
    padding-top: 60px;
}

.legal-title {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 40px;
    color: var(--text-primary);
    text-align: center;
}

.legal-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 40px;
    background: var(--glass-bg);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-radius: 24px;
    border: 1px solid var(--glass-border);
}

.last-updated {
    color: var(--text-secondary);
    font-size: 14px;
    margin-bottom: 32px;
    text-align: right;
}

.legal-content h2 {
    font-size: 24px;
    font-weight: 600;
    margin: 32px 0 16px;
    color: var(--text-primary);
}

.legal-content p {
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 16px;
}

.legal-content ul {
    list-style: disc;
    margin: 16px 0;
    padding-left: 24px;
    color: var(--text-secondary);
}

.legal-content ul li {
    margin-bottom: 8px;
    line-height: 1.6;
}

@media (max-width: 768px) {
    .legal-title {
        font-size: 36px;
    }

    .legal-content {
        padding: 24px;
        margin: 0 16px;
    }

    .legal-content h2 {
        font-size: 20px;
    }
}

/* Footer styles */
.footer {
    background: var(--bg-secondary);
    padding: 80px 60px 40px;
    position: relative;
    z-index: 1;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
    margin-bottom: 60px;
}

.footer-section h3 {
    font-size: 18px;
    margin-bottom: 20px;
    color: var(--text-primary);
}

.footer-section ul {
    list-style: none;
    padding: 0;
}

.footer-section ul li {
    margin-bottom: 12px;
}

.footer-section ul a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s;
}

.footer-section ul a:hover {
    color: var(--accent);
}

.footer-bottom {
    padding-top: 40px;
    border-top: 1px solid var(--glass-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-secondary);
    font-size: 14px;
}

.footer-links {
    display: flex;
    gap: 24px;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.3s;
}

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

.contact-grid {
    display: flex;
    gap: 16px;
    justify-content: center;
    margin-bottom: 32px;
}

.cta-button.secondary {
    background: transparent;
    border: 1px solid var(--accent);
    color: var(--accent);
}

.cta-button.secondary:hover {
    background: var(--accent);
    color: #ffffff;
}

/* Mobile menu styles */
.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--nav-bg);
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    transform: translateY(-10px);
}

.mobile-menu.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.mobile-nav-links {
    list-style: none;
    text-align: center;
    padding: 0;
    width: 100%;
    max-width: 320px;
}

.mobile-nav-links li {
    margin: 8px 0;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.mobile-menu.active .mobile-nav-links li {
    opacity: 1;
    transform: translateY(0);
}

.mobile-menu.active .mobile-nav-links li:nth-child(1) {
    transition-delay: 0.1s;
}

.mobile-menu.active .mobile-nav-links li:nth-child(2) {
    transition-delay: 0.15s;
}

.mobile-menu.active .mobile-nav-links li:nth-child(3) {
    transition-delay: 0.2s;
}

.mobile-menu.active .mobile-nav-links li:nth-child(4) {
    transition-delay: 0.25s;
}

.mobile-menu.active .mobile-nav-links li:nth-child(5) {
    transition-delay: 0.3s;
}

.mobile-menu.active .mobile-nav-links li:nth-child(6) {
    transition-delay: 0.35s;
}

.mobile-nav-links a {
    color: var(--text-primary);
    text-decoration: none;
    font-size: 24px;
    font-weight: 600;
    padding: 12px 24px;
    display: block;
    background: var(--nav-item-bg);
    border-radius: 16px;
    margin: 8px 16px;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid var(--nav-border);
    position: relative;
}

.mobile-nav-links a::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 16px;
    background: var(--accent);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.mobile-nav-links a:hover {
    background: var(--nav-item-hover);
    transform: translateY(-2px);
}

.mobile-nav-links a:hover::before {
    opacity: 0.1;
}

@media (max-width: 968px) {

    /* CHANGE 2: Added these rules to hide desktop nav and show mobile button.
    */
    .nav-links {
        display: none;
    }

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

    .section#education,
    .section#blog {
        margin: 1rem var(--space-md);
        border-radius: var(--radius-xl);
    }

    .blog-grid,
    .interests-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .timeline-card {
        flex-direction: column;
        text-align: center;
    }

    .timeline-icon {
        margin: 0 auto 16px;
    }

    .footer {
        padding: 60px 24px 32px;
    }

    .footer-grid {
        gap: 32px;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }

    .footer-links {
        justify-content: center;
    }

    .contact-grid {
        flex-direction: column;
    }

    .hero {
        grid-template-columns: 1fr;
        padding: 40px 24px;
        gap: 40px;
    }

    .hero-content {
        order: 2;
        text-align: center;
    }

    .hero-image {
        order: 1;
        max-width: 400px;
        margin: 0 auto;
    }

    nav {
        padding: 16px 24px;
    }

    .nav-links {
        /* This rule was redundant because it's now 'display: none' */
        /* gap: 24px; */
    }

    .hero-content h1 {
        font-size: 42px;
        letter-spacing: -1px;
    }

    .hero-content p {
        font-size: 18px;
    }

    .section-title {
        font-size: 36px;
    }

    .section {
        padding: 60px 24px;
    }

    .project-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .contact-card {
        padding: 40px 24px;
        border-radius: 24px;
    }

    .skill-tags {
        gap: 12px;
    }

    .skill-tag {
        padding: 12px 20px;
        font-size: 14px;
    }

}

/* --- Easter Egg: Retro Mode --- */
@import url('https://fonts.googleapis.com/css2?family=Press+Start+2P&display=swap');

html.retro-mode {
    filter: saturate(1.2) contrast(1.1);
}

html.retro-mode body {
    font-family: 'Press Start 2P', cursive;
}

html.retro-mode .glass-card,
html.retro-mode nav,
html.retro-mode .footer {
    border-color: #00ff00;
    box-shadow: 0 0 15px #00ff00, 0 0 5px #00ff00 inset;
    animation: retro-flicker 0.1s infinite alternate;
}

html.retro-mode .glass-card h3,
html.retro-mode .logo,
html.retro-mode .hero-content h1,
html.retro-mode .section-title {
    color: #00ff00;
    text-shadow: 0 0 5px #00ff00;
}

/* Scanline Overlay */
html.retro-mode body::after {
    content: ' ';
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    background: linear-gradient(to bottom, rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.25) 50%), linear-gradient(90deg, rgba(255, 0, 0, 0.06), rgba(0, 255, 0, 0.02), rgba(0, 0, 255, 0.06));
    background-size: 100% 4px, 3px 100%;
    z-index: 9999;
    pointer-events: none;
    animation: retro-scan 0.5s linear infinite;
}

@keyframes retro-flicker {
    from {
        opacity: 0.9;
    }

    to {
        opacity: 1;
    }
}

@keyframes retro-scan {
    from {
        background-position: 0 0;
    }

    to {
        background-position: 0 4px;
    }
}

/* --- Easter Egg: Idle Modal --- */
.idle-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.idle-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.idle-modal-card {
    max-width: 400px;
    width: calc(100% - 2rem);
    text-align: center;
    transform: scale(0.9);
    transition: all 0.3s ease;
}

.idle-modal-overlay.active .idle-modal-card {
    transform: scale(1);
}

.idle-modal-card h3 {
    font-size: 24px;
    margin-bottom: 12px;
}

.idle-modal-card p {
    color: var(--text-secondary);
    line-height: 1.6;
    font-size: 16px;
    margin-bottom: 24px;
}

.idle-signature {
    display: block;
    /* Makes the whole area clickable */
    font-style: italic;
    font-weight: 500;
    color: var(--text-primary);
    text-align: right;
    margin-bottom: 24px;
    text-decoration: none;
    /* Removes the link underline */
    transition: color 0.3s ease;
}

.idle-signature:hover {
    color: var(--accent);
    /* Adds a hover effect */
}

/* --- Easter Egg: SwiftUI Preview Mode --- */
.logo-preview-wrapper {
    position: relative;
    padding: 12px;
    border-radius: 20px;
    background: var(--nav-item-bg);
    border: 1px solid var(--glass-border);
    transition: all 0.3s ease;
    /* Simulates the "device" padding */
}

.logo-preview-wrapper::before {
    /* The "Home Bar" on an iPhone */
    content: '';
    position: absolute;
    bottom: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: var(--text-secondary);
    border-radius: 2px;
    opacity: 0.5;
}

.logo-preview-wrapper .logo {
    /* Add a little pulse like a "live" preview */
    animation: swiftui-pulse 2s infinite ease-in-out;
}

@keyframes swiftui-pulse {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.03);
    }

    100% {
        transform: scale(1);
    }
}

/* Scroll to Top Button */
.scroll-to-top {
    position: fixed;
    bottom: 30px;
    left: 30px;
    right: auto;
    width: 50px;
    height: 50px;
    background: var(--gradient-primary);
    backdrop-filter: blur(10px);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    box-shadow: var(--elevation-3);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 999;
}

.scroll-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-to-top:hover {
    background: var(--accent-hover);
    transform: translateY(-5px);
    box-shadow: var(--elevation-4);
}

/* Project Modal */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    padding: 20px;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    width: 100%;
    max-width: 900px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    transform: scale(0.95);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    padding: 0;
    /* Reset padding for custom layout */
    display: flex;
    flex-direction: column;
}

.modal-overlay.active .modal-content {
    transform: scale(1);
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease;
}

.modal-close:hover {
    background: rgba(0, 0, 0, 0.8);
}

.modal-body {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 0;
}

.modal-image-container {
    background: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 300px;
}

.modal-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.modal-info {
    padding: 40px;
    display: flex;
    flex-direction: column;
}

.modal-info h3 {
    font-size: 32px;
    margin-bottom: 16px;
    color: var(--text-primary);
}

.modal-tech-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 24px;
}

.modal-tech-stack span {
    background: var(--nav-item-bg);
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 14px;
    color: var(--text-secondary);
    border: 1px solid var(--glass-border);
}

.modal-info p {
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 32px;
    font-size: 16px;
}

.modal-links {
    margin-top: auto;
    display: flex;
    gap: 16px;
}

@media (max-width: 768px) {
    .modal-body {
        grid-template-columns: 1fr;
    }

    .modal-image-container {
        height: 250px;
    }

    .modal-info {
        padding: 24px;
    }
}

/* 3D Tilt Effect Classes */
.hero {
    perspective: 1000px;
    /* Enable 3D space */
}

.hero-content,
.hero-image {
    /* Removed default transition to prevent lag during mousemove */
    /* Transition will be added via JS for the reset */
    transform-style: preserve-3d;
}

.hero-profile-img {
    transform: translateZ(20px);
    /* Pop out slightly */
}

.hero-content,
.hero-image {
    transform-style: preserve-3d;
}

/* Live Status Indicator */
.live-status {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 8px 16px;
    border-radius: 20px;
    margin-bottom: 24px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 14px;
    color: var(--text-secondary);
}

.status-dot {
    width: 8px;
    height: 8px;
    background-color: #10b981;
    /* Green */
    border-radius: 50%;
    position: relative;
}

.status-dot::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    height: 100%;
    background-color: inherit;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 1;
    }

    100% {
        transform: translate(-50%, -50%) scale(3);
        opacity: 0;
    }
}

/* Bento Grid Styles */
.bento-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
    max-width: 1000px;
    margin: 0 auto;
}

.bento-card {
    padding: 24px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 200px;
    position: relative;
    overflow: hidden;
}

.col-span-2 {
    grid-column: span 2;
}

.row-span-2 {
    grid-row: span 2;
}

@media (max-width: 768px) {

    .col-span-2,
    .row-span-2 {
        grid-column: span 1;
        grid-row: span 1;
    }
}

.bento-icon {
    font-size: 24px;
    color: var(--color-primary-light);
    margin-bottom: 16px;
}

.bento-content h3 {
    font-size: 18px;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.bento-content p {
    font-size: 14px;
    color: var(--text-secondary);
}

/* Tech Grid in Bento */
.tech-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-top: auto;
}

.tech-grid span {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: var(--text-secondary);
    transition: color 0.3s ease;
}

.tech-grid span:hover {
    color: var(--color-primary-light);
}

/* Music Visualizer */
.music-visual {
    display: flex;
    gap: 4px;
    align-items: flex-end;
    height: 20px;
    margin-top: 16px;
}

.bar {
    width: 4px;
    background: var(--color-primary-light);
    animation: music-bounce 1s infinite ease-in-out;
}

.bar:nth-child(1) {
    animation-delay: 0.1s;
    height: 40%;
}

.bar:nth-child(2) {
    animation-delay: 0.3s;
    height: 100%;
}

.bar:nth-child(3) {
    animation-delay: 0.5s;
    height: 60%;
}

.bar:nth-child(4) {
    animation-delay: 0.2s;
    height: 80%;
}

@keyframes music-bounce {

    0%,
    100% {
        height: 20%;
    }

    50% {
        height: 100%;
    }
}

/* F1 Card Styles */
.f1-card {
    background: linear-gradient(135deg, rgba(220, 0, 0, 0.08), rgba(0, 0, 0, 0.15));
    border: 1px solid rgba(220, 0, 0, 0.3);
    position: relative;
    overflow: hidden;
}

.f1-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        repeating-linear-gradient(90deg,
            transparent,
            transparent 10px,
            rgba(220, 0, 0, 0.03) 10px,
            rgba(220, 0, 0, 0.03) 20px);
    pointer-events: none;
    opacity: 0.5;
}

.f1-track-container {
    position: relative;
    width: 100%;
    height: 100px;
    margin: 20px 0;
    background: rgba(0, 0, 0, 0.2);
    border: 2px solid rgba(220, 0, 0, 0.3);
    border-radius: 50px;
    overflow: visible;
    box-shadow:
        inset 0 2px 10px rgba(0, 0, 0, 0.3),
        0 0 20px rgba(220, 0, 0, 0.1);
}

.track-path {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 85%;
    height: 65%;
    border-radius: 35px;
    border: 3px dashed rgba(255, 40, 0, 0.4);
    box-shadow:
        0 0 10px rgba(255, 40, 0, 0.3),
        inset 0 0 10px rgba(255, 40, 0, 0.2);
    animation: track-pulse 2s ease-in-out infinite;
}

@keyframes track-pulse {

    0%,
    100% {
        border-color: rgba(255, 40, 0, 0.4);
        box-shadow:
            0 0 10px rgba(255, 40, 0, 0.3),
            inset 0 0 10px rgba(255, 40, 0, 0.2);
    }

    50% {
        border-color: rgba(255, 40, 0, 0.8);
        box-shadow:
            0 0 20px rgba(255, 40, 0, 0.6),
            inset 0 0 20px rgba(255, 40, 0, 0.4);
    }
}

.f1-car-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 32px;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.3));
}

.f1-stats {
    display: flex;
    gap: 12px;
    margin-top: 16px;
}

.f1-stat {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 8px 12px;
    background: rgba(220, 0, 0, 0.1);
    border: 1px solid rgba(220, 0, 0, 0.2);
    border-radius: 8px;
    flex: 1;
}

.stat-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-secondary);
    font-weight: 600;
}

.stat-value {
    font-size: 14px;
    font-weight: 700;
    color: #dc0000;
    text-shadow: 0 0 10px rgba(220, 0, 0, 0.3);
}

[data-theme="dark"] .stat-value {
    color: #ff2800;
    text-shadow: 0 0 10px rgba(255, 40, 0, 0.5);
}


/* Mindset Card Styles */
.mindset-quote {
    font-family: 'Georgia', serif;
    font-style: italic;
    font-size: 16px;
    line-height: 1.5;
    color: var(--text-primary);
    margin-top: 12px;
}

.hero-profile-img {
    transform: translateZ(20px);
    /* Pop out slightly */
}