body {
    margin: 0;
    font-family: 'Segoe UI', Arial, sans-serif;
    background: linear-gradient(135deg, #1f1c2c, #928dab);
    color: #fff;
    min-height: 100vh;
}
body.dark-mode {
    background: linear-gradient(135deg, #1f1c2c, #928dab);
    color: #fff;
}
body.light-mode {
    background: linear-gradient(120deg,
        #fff 0%, #fff 50%,
        #232323 50%, #232323 80%,
        #ffe066 80%, #ffe066 90%,
        #38d39f 90%, #38d39f 100%
    );
    color: #232323;
}
body.light-mode nav,
body.light-mode .about-banner,
body.light-mode .projects-banner,
body.light-mode .footer {
    background: rgba(31, 28, 44, 0.95) !important;
    color: #fff !important;
    box-shadow: 0 2px 16px rgba(0,0,0,0.10);
}
body.light-mode .project-card,
body.light-mode .skill-card,
body.light-mode .experience-card {
    background: #fff;
    color: #232323;
    box-shadow: 0 4px 24px 0 rgba(50,50,50,0.18), 0 2px 8px 0 rgba(100,181,246,0.13);
}
body.light-mode .project-card h3,
body.light-mode .skill-card,
body.light-mode .experience-card {
    color: #38d39f;
}
body.light-mode .footer-copy {
    color: #fff !important;
}
body.light-mode .social-pallet {
    background: rgba(255,255,255,0.85);
    border: 1.5px solid #ffe066;
}
body.light-mode .social-icon {
    color: #232323;
}
body.light-mode .social-icon:hover {
    color: #38d39f;
}
body.light-mode #loader-overlay {
    background: rgba(255,255,255,0.98);
}
body.light-mode .loader {
    border: 6px solid #ffe066;
    border-top: 6px solid #38d39f;
}
nav {
    background: rgba(31, 28, 44, 0.95);
    color: #fff;
    box-shadow: 0 2px 16px rgba(0,0,0,0.10);
    padding: 1.2rem 2.5rem 1.2rem 2rem;
    position: fixed;
    top: 0;
    right: 0;
    left: 0;
    height: auto;
    width: 100vw;
    z-index: 100;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    border-radius: 0 0 24px 24px;
    flex-wrap: wrap;
    overflow-x: visible;
    padding-right: 2.5rem;
}

nav .logo {
    margin-right: 0;
    margin-bottom: 0;
    margin-right: 2.5rem;
    font-size: 1.1rem;
    white-space: nowrap;
    color: #fff;
}

nav ul {
    list-style: none;
    display: flex;
    flex-direction: row;
    gap: 1.2rem;
    margin-left: auto;
    margin-right: 0;
    padding: 0 0 0 0;
    width: auto;
    overflow-x: visible;
    flex-wrap: nowrap;
    align-items: center;
}

nav ul.nav-links {
    margin-right: 2.5rem;
}

nav a {
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    transition: color 0.2s;
    padding: 0.5rem 0.7rem;
    border-radius: 8px;
    display: block;
    white-space: nowrap;
    flex-shrink: 0; /* Prevent shrinking */
    background: transparent;
    position: relative;
    overflow: hidden;
}

nav a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0.2em;
    width: 100%;
    height: 2px;
    background: #64b5f6;
    transform: scaleX(0);
    transition: transform 0.3s cubic-bezier(.4,0,.2,1);
    transform-origin: left;
}

nav a:hover::after, nav a.active::after {
    transform: scaleX(1);
}

nav a:hover, nav a.active {
    color: #64b5f6;
    background: #232136;
}
main {
    max-width: 900px;
    margin: 6rem auto 0 auto;
    padding: 2rem;
    background: transparent;
    color: #fff;
    border-radius: 0;
    box-shadow: none;
    position: relative;
    z-index: 1;
}
section {
    margin-bottom: 4rem;
    min-height: 90vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: transparent;
    color: #fff;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.7s cubic-bezier(.4,0,.2,1), transform 0.7s cubic-bezier(.4,0,.2,1);
}
section.visible {
    opacity: 1;
    transform: none;
}
.home-content {
    display: flex;
    align-items: center;
    gap: 2rem;
}
#profile-photo, .large-photo {
    border: none !important;
    box-shadow: none !important;
    background: none !important;
    border-radius: 5% !important;
    object-fit: cover;
}
#name {
    margin: 0 0 0.5rem 0;
    font-size: 2.2rem;
    font-weight: 700;
    color: #fff;
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif !important;
}
#description {
    font-size: 1.2rem;
    color: #b0bec5;
}
.about-flex {
    display: flex;
    gap: 3rem;
    flex-wrap: wrap;
}
.about-flex > div {
    flex: 1 1 200px;
}
#experience-list, #skills-list {
    padding-left: 1.2rem;
}
#projects-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
}
.project-item {
    background: #203a43;
    padding: 1rem;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
#add-project-btn {
    margin-top: 1.5rem;
    padding: 0.7rem 1.5rem;
    background: #64b5f6;
    color: #203a43;
    border: none;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}
#add-project-btn:hover {
    background: #42a5f5;
}
#contact {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 3rem 1rem 4rem 1rem;
    background: transparent;
    border-radius: 0;
    box-shadow: none;
    margin-bottom: 2rem;
    position: relative;
    min-width: 0;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.7s cubic-bezier(.4,0,.2,1), transform 0.7s cubic-bezier(.4,0,.2,1);
}
#contact.visible {
    opacity: 1;
    transform: none;
}
#contact h2 {
    margin-bottom: 0.5rem;
    font-size: 2.1rem;
    color: #1d3749;
    display: flex;
    align-items: center;
    gap: 0.7rem;
    gap: 0.5rem; /* smaller gap for better alignment */
    line-height: 1.1; /* helps with vertical alignment */
}
#contact h2::before {
    content: '\2709';
    font-size: 3.7rem;
    color: #0c2434;
    display: inline-block;
    vertical-align: middle;
    margin-bottom: 5%;
}
#contact-form {
    background: transparent;
    box-shadow: none;
    border-left: none;
    border-radius: 0;
    color: #fff;
    padding: 2.5rem 2rem 2rem 2rem;
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
    max-width: 420px;
    width: 100%;
    margin-top: 1.5rem;
}
#contact-form input, #contact-form textarea {
    background: #232136;
    color: #fff;
    border: 1.5px solid #5dade2;
    padding: 1.1rem;
    border-radius: 8px;
    font-size: 1.08rem;
    box-shadow: 0 1px 4px #23213622;
    transition: border 0.2s, box-shadow 0.2s;
}
#contact-form input:focus, #contact-form textarea:focus {
    border: 1.5px solid #4fc3f7;
    outline: none;
    box-shadow: 0 2px 8px #4fc3f733;
}
#contact-form textarea {
    min-height: 110px;
}
#contact-form button {
    background: #604eff22;
    color: #232136;
    border: none;
    border-radius: 8px;
    padding: 1rem 0;
    font-size: 1.15rem;
    font-weight: 700;
    cursor: pointer;
    margin-top: 0.5rem;
    box-shadow: 0 2px 8px #5dade233;
    transition: background 0.2s, color 0.2s, box-shadow 0.2s;
}
#contact-form button:hover {
    background: #dbe2e5;
    color: #fff;
    box-shadow: 0 4px 16px #4fc3f755;
}

/* Typing title fix: allow wrapping, hide border on wrap */
.typing {
    font-size: 1.5rem;
    font-family: 'Fira Mono', monospace;
    color: #928dab;
    min-height: 3em;
    max-width: 100%;
    width: 100%;
    overflow-wrap: break-word;
    display: inline-block;
    margin-bottom: 0.5rem;
    white-space: pre-line;
    box-sizing: border-box;
    line-height: 1.3;
}
.typing.done {
    /* nothing needed for caret, caret will be removed in JS */
}
.caret {
    display: inline-block;
    color: #928dab;
    animation: blink-caret 0.75s step-end infinite;
}
@keyframes blink-caret {
    from, to { opacity: 0 }
    50% { opacity: 1; }
}

@media (max-width: 700px) {
    .typing {
        font-size: 1.1rem;
    }
    nav ul {
        gap: 1rem;
        font-size: 0.95rem;
    }
    nav {
        padding: 1rem 0.5rem 1rem 1rem;
    }
}

/* Home Section Large Image and Typing Animation */
.home-content.large {
    display: flex;
    align-items: center;
    gap: 3rem;
    min-height: 70vh;
    background: none;
    color: #fff;
    border-radius: 0;
    box-shadow: none;
    padding: 3rem 2rem;
}
.large-photo {
    width: 38vw;
    min-width: 220px;
    max-width: 420px;
    height: 60vh;
    min-height: 320px;
    max-height: 520px;
    object-fit: cover;
    border: none;
    box-shadow: none;
    background: none;
    margin: 0;
    display: block;
    border-radius: 0;
}
.home-text {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 1.2rem;
    min-width: 0;
    min-height: 8em;
}
#name {
    margin: 0 0 0.5rem 0;
    font-size: 2.8rem;
    font-weight: 700;
    letter-spacing: 1px;
    color: #fff;
}
#description {
    color: #b0bec5;
    font-size: 1.15rem;
    margin-top: 0.5rem;
}

/* About Banner and Skills Cards */
.about-banner {
    background: rgba(31, 28, 44, 0.7);
    color: #fff;
    padding: 2rem 2rem 1rem 2rem;
    border-radius: 18px;
    margin-bottom: 2rem;
    box-shadow: 0 2px 12px rgba(0,0,0,0.10);
    text-align: center;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.7s cubic-bezier(.4,0,.2,1), transform 0.7s cubic-bezier(.4,0,.2,1);
}
.about-banner.visible {
    opacity: 1;
    transform: none;
}
.about-banner h2 {
    margin: 0 0 0.5rem 0;
    font-size: 2rem;
    color: #fff;
}
.about-banner p {
    color: #b0bec5;
    font-size: 1.1rem;
}

/* Experience Tree */
#experience-list {
    position: relative;
    margin: 0;
    padding: 0 0 0 2.5rem;
    list-style: none;
}
#experience-list::before {
    content: '';
    position: absolute;
    left: 1.1rem;
    top: 0.5rem;
    bottom: 0.5rem;
    width: 4px;
    background: linear-gradient(180deg, #928dab 0%, #232136 100%);
    border-radius: 2px;
}
.experience-card {
    background: #232136;
    color: #fff;
    padding: 1rem 1.5rem;
    border-radius: 10px;
    font-weight: 500;
    font-size: 1.05rem;
    box-shadow: 0 4px 24px 0 rgba(50,50,50,0.18), 0 2px 8px 0 rgba(100,181,246,0.13);
    margin-bottom: 1.5rem;
    position: relative;
    transition: transform 0.2s, box-shadow 0.2s;
    margin-left: 0.5rem;
    border: none;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.7s cubic-bezier(.4,0,.2,1), transform 0.7s cubic-bezier(.4,0,.2,1);
}
.experience-card.visible {
    opacity: 1;
    transform: none;
}
.experience-card:hover {
    transform: translateY(-4px) scale(1.03);
    box-shadow: 0 8px 32px 0 rgba(50,50,50,0.28), 0 4px 16px 0 rgba(100,181,246,0.18);
}
#experience-list li {
    position: relative;
    margin-bottom: 0.5rem;
}
#experience-list li::before {
    content: '';
    position: absolute;
    left: -2.1rem;
    top: 1.2rem;
    width: 18px;
    height: 18px;
    background: #928dab;
    border-radius: 50%;
    border: 3px solid #232136;
    z-index: 1;
    box-shadow: 0 2px 8px #928dab33;
}

.skills-section {
    flex: 1 1 300px;
}
.skills-cards {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-top: 0.5rem;
    justify-content: flex-start;
}
.skill-card {
    background: #232136;
    color: #fff;
    padding: 0.7rem 1.5rem;
    border-radius: 10px;
    font-weight: 600;
    font-size: 1rem;
    box-shadow: 0 4px 24px 0 rgba(50,50,50,0.18), 0 2px 8px 0 rgba(100,181,246,0.13);
    white-space: nowrap;
    transition: transform 0.2s, box-shadow 0.2s;
    border: none;
    border-left: none;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.7s cubic-bezier(.4,0,.2,1), transform 0.7s cubic-bezier(.4,0,.2,1);
}
.skill-card.visible {
    opacity: 1;
    transform: none;
}
.skill-card:hover {
    transform: scale(1.07);
    box-shadow: 0 8px 32px 0 rgba(50,50,50,0.28), 0 4px 16px 0 rgba(100,181,246,0.18);
}

/* Projects Grid */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}
.project-card {
    background: #232136;
    color: #fff;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.10);
    padding: 2rem 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    transition: transform 0.3s, box-shadow 0.3s;
    gap: 1rem;
    min-height: 220px;
    margin: 0;
    border: none;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.7s cubic-bezier(.4,0,.2,1), transform 0.7s cubic-bezier(.4,0,.2,1);
}
.project-card.visible {
    opacity: 1;
    transform: none;
}
.project-card h3 {
    margin: 0 0 0.5rem 0;
    font-size: 1.3rem;
    color: #928dab;
}
.project-card p {
    color: #b0bec5;
    font-size: 1.05rem;
}
.project-card a {
    color: #928dab;
    text-decoration: none;
    font-weight: 600;
    margin-top: 0.5rem;
    transition: color 0.2s;
}
.project-card a:hover {
    color: #fff;
    text-decoration: underline;
}

/* Remove carousel styles */
.carousel-container, .projects-carousel, .carousel-btn { display: none !important; }

/* Remove UI edit styles for projects */
#add-project-btn, .project-item button {
    display: none !important;
}

@media (max-width: 900px) {
    .home-content.large {
        flex-direction: column;
        align-items: flex-start;
        gap: 2rem;
        padding: 2rem 1rem;
    }
    .large-photo {
        width: 60vw;
        max-width: 90vw;
        height: 220px;
    }
    .projects-grid {
        max-width: 95vw;
    }
    nav {
        justify-content: space-between;
    }
    .logo {
        margin-right: 0;
    }
    nav ul.nav-links {
        display: none;
        position: fixed;
        top: 64px; /* height of navbar, adjust if needed */
        right: 2vw;
        left: auto;
        margin-top: 0;
        background: rgba(31, 28, 44, 0.98);
        flex-direction: column;
        gap: 0;
        min-width: 180px;
        width: max-content;
        max-width: 92vw;
        border-radius: 0 0 18px 18px;
        box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.18), 0 2px 8px 0 rgba(100,181,246,0.10);
        padding: 0.7rem 0;
        z-index: 12001;
        justify-content: flex-start;
        pointer-events: none;
    }
    nav ul.nav-links.open {
        display: flex !important;
        flex-direction: column;
        width: max-content;
        min-width: 180px;
        right: 2vw;
        left: auto;
        margin: 0 auto;
        margin-top: 0;
        box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.18), 0 2px 8px 0 rgba(100,181,246,0.10);
        pointer-events: auto;
        border-radius: 0 0 18px 18px;
        z-index: 13000;
        pointer-events: auto;
        overflow: hidden;
        align-items: flex-start;
        text-align: left;
    }
    nav ul.nav-links.open li {
        width: 100%;
    }
    nav ul.nav-links.open li a {
        text-align: left;
        justify-content: flex-start;
        padding-left: 1.2rem;
    }
    .mobile-nav-backdrop.active {
        display: block;
        z-index: 10999;
        pointer-events: none;
    }

    .mobile-nav-backdrop {
        pointer-events: none;
        display: none;
    }
    .hamburger {
        margin-left: 1.5rem;
        margin-right: 1.5rem;
        z-index: 202;
        order: 2;
    }
}

/* Subtle background shapes/overlays for visual interest */
body::before {
    content: '';
    position: fixed;
    top: -100px;
    left: -100px;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle at 30% 30%, #928dab33 0%, transparent 70%);
    z-index: 0;
    pointer-events: none;
}
body::after {
    content: '';
    position: fixed;
    bottom: -120px;
    right: -120px;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle at 70% 70%, #1f1c2c44 0%, transparent 80%);
    z-index: 0;
    pointer-events: none;
}

html {
    scroll-behavior: smooth;
}

.projects-banner {
    background: rgba(31, 28, 44, 0.7);
    color: #fff;
    padding: 2rem 2rem 1rem 2rem;
    border-radius: 18px;
    margin-bottom: 2rem;
    box-shadow: 0 2px 12px rgba(0,0,0,0.10);
    text-align: center;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.7s cubic-bezier(.4,0,.2,1), transform 0.7s cubic-bezier(.4,0,.2,1);
}
.projects-banner.visible {
    opacity: 1;
    transform: none;
}
.projects-banner h2 {
    margin: 0 0 0.5rem 0;
    font-size: 2rem;
    color: #fff;
}
.projects-banner p {
    color: #b0b7bc;
    font-size: 1.1rem;
}

/* Hamburger styles */
.hamburger {
    margin-left: 1.5rem;
    margin-right: 1.5rem;
    order: 2;
    z-index: 202;
}
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 38px;
    height: 38px;
    background: none;
    border: none;
    cursor: pointer;
    margin-left: 1rem;
}
.hamburger span {
    display: block;
    width: 26px;
    height: 3px;
    margin: 4px 0;
    background: #fff;
    border-radius: 2px;
    transition: 0.3s;
}

@media (max-width: 900px) {
    .hamburger {
        display: flex;
    }

    nav ul.nav-links li {
        width: 100%;
    }

    nav ul.nav-links li a {
        width: 100%;
        padding: 0.9rem 1.2rem;
        font-size: 1.08rem;
        border-radius: 0;
        margin: 0;
        white-space: nowrap; /* avoid wrapping */
        overflow-x: hidden;
        text-overflow: ellipsis; /* optional */
    }

    nav {
        padding: 1rem 1rem;
        overflow-x: hidden;
    }

    nav ul.nav-links li:last-child a {
        padding-right: 1.2rem;
    }
}

::-webkit-scrollbar-thumb {
    background: #64b5f6;
}
::-webkit-scrollbar-track {
    background: #232136;
}

.footer {
    background: rgba(31, 28, 44, 0.95);
    color: #fff;
    text-align: center;
    padding: 2rem 1rem 1rem 1rem;
    margin-top: 3rem;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.7s cubic-bezier(.4,0,.2,1), transform 0.7s cubic-bezier(.4,0,.2,1);
}
.footer.visible {
    opacity: 1;
    transform: none;
}
.footer-socials {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 1rem;
}
.footer-icon {
    color: #fff;
    transition: color 0.2s, transform 0.3s cubic-bezier(.4,0,.2,1);
    will-change: transform;
    display: inline-flex;
    align-items: center;
    font-size: 1.5rem;
}
.footer-icon:hover {
    color: #64b5f6;
    transform: translateY(-6px) scale(1.15) rotate(-6deg);
}
.footer-copy {
    font-size: 1rem;
    color: #b0bec5;
    margin-top: 0.5rem;
}

/* Card hover scale/shine */
.project-card, .skill-card, .experience-card {
    transition: transform 0.25s cubic-bezier(.4,0,.2,1), box-shadow 0.25s, background 0.3s;
    position: relative;
    overflow: hidden;
}
.project-card:hover, .skill-card:hover, .experience-card:hover {
    transform: translateY(-8px) scale(1.035);
    box-shadow: 0 8px 32px 0 rgba(100,181,246,0.18);
    background: rgba(100,181,246,0.08);
}
.project-card::after, .skill-card::after, .experience-card::after {
    content: '';
    position: absolute;
    top: -75%;
    left: -75%;
    width: 150%;
    height: 150%;
    background: linear-gradient(120deg, rgba(100,181,246,0.08) 0%, rgba(255,255,255,0.01) 60%);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
}
.project-card:hover::after, .skill-card:hover::after, .experience-card:hover::after {
    opacity: 1;
}

.footer-resume-btn {
    display: inline-block;
    margin: 0.5rem auto 0 auto;
    padding: 0.8rem 2.2rem;
    background: #ffffff9d;
    color: #373737;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 700;
    text-decoration: none;
    box-shadow: 0 2px 8px #64b5f633;
    transition: background 0.2s, color 0.2s, box-shadow 0.2s;
    cursor: pointer;
    margin-bottom: 1rem;
}
.footer-resume-btn:hover {
    background: #42a5f5;
    color: #fff;
    box-shadow: 0 4px 16px #64b5f655;
}

#contact-form {
    max-width: 100%;
    width: 100%;
}
@media (max-width: 600px) {
    #contact-form {
        padding: 1.2rem 0.5rem;
    }
}

.social-pallet {
    position: fixed;
    top: 50%;
    right: 2vw;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    background: rgba(31, 28, 44, 0.18);
    border-radius: 18px;
    padding: 1.2rem 0.7rem;
    z-index: 1200;
    box-shadow: 0 2px 16px rgba(100,181,246,0.10);
    align-items: center;
    transition: background 0.2s, box-shadow 0.2s;
    backdrop-filter: blur(2px);
}
.social-icon {
    color: #fff;
    opacity: 0.85;
    font-size: 1.7rem;
    transition: color 0.2s, transform 0.2s, opacity 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    padding: 0.3rem;
    background: none;
}
.social-icon:hover {
    color: #64b5f6;
    opacity: 1;
    transform: scale(1.18) translateY(-3px) rotate(-8deg);
    background: rgba(100,181,246,0.08);
}
@media (max-width: 700px) {
    .social-pallet {
        right: 0.5vw;
        padding: 0.7rem 0.2rem;
        gap: 1rem;
        max-width: 95vw;
        overflow: hidden;
    }
    .social-icon {
        font-size: 1.3rem;
        padding: 0.15rem;
        flex-shrink: 0;
    }
}

@media (max-width: 500px) {
    .social-pallet {
        right: 0.2vw;
        padding: 0.5rem 0.1rem;
        gap: 0.7rem;
        max-width: 90vw;
    }
    .social-icon {
        font-size: 1.1rem;
        padding: 0.1rem;
    }
}

/* Loader Overlay */
#loader-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(31, 28, 44, 0.98);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    transition: opacity 0.5s;
}
#loader-overlay.hidden {
    opacity: 0;
    pointer-events: none;
}
.loader {
    border: 6px solid #928dab33;
    border-top: 6px solid #64b5f6;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    animation: spin-loader 1s linear infinite;
}
@keyframes spin-loader {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

#mode-toggle {
    background: none;
    border: 2px solid #ffe066;
    font-size: 0.85rem;
    margin-top: 1.2rem;
    margin-bottom: 0.2rem;
    border-radius: 50%;
    cursor: pointer;
    color: #232323;
    transition: color 0.2s, border 0.2s, background 0.2s;
    outline: none;
    position: relative;
    z-index: 300;
    align-self: center;
    width: 1.2rem;
    height: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
}
#mode-toggle .mode-icon {
    font-size: 0.85rem;
    pointer-events: none;
}
#mode-toggle:focus {
    outline: 2px solid #38d39f;
}
body.light-mode #mode-toggle {
    color: #232323;
    border: 2px solid #38d39f;
    background: #ffe066;
}
body.light-mode #mode-toggle:focus {
    outline: 2px solid #232323;
}

body.light-mode nav .logo,
body.light-mode nav a,
body.light-mode nav ul.nav-links {
    color: #fff !important;
}
body.light-mode nav a:hover, body.light-mode nav a.active {
    color: #64b5f6 !important;
    background: #232136 !important;
}

body.light-mode h3,
body.light-mode .experience-card,
body.light-mode .skill-card,
body.light-mode .project-card h3 {
    color: #232323 !important;
}
body.light-mode #contact-form button {
    background: #fffbe6;
    color: #232323;
    border: 1.5px solid #ffe066;
}
body.light-mode #contact-form button:hover {
    background: #ffe066;
    color: #232323;
}

body.light-mode #contact h2,
body.light-mode #name,
body.light-mode .project-card p,
body.light-mode #description,
body.light-mode .projects-banner p {
    color: #232323 !important;
}

body.light-mode #contact h2 {
    color: #ffe066 !important;
}

body.light-mode .projects-banner p {
    color: #b0b7bc !important;
}

.exp-header {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.7rem 1.2rem;
    margin-bottom: 0.3em;
    font-size: 1.08rem;
    font-weight: 600;
}
.exp-role {
    color: #8c8b8b;
    font-weight: 700;
    font-size: 1.08rem;
}
.exp-company {
    color: #ced2d1;
    font-weight: 600;
    font-size: 1.08rem;
}
.exp-location {
    color: #928dab;
    font-size: 0.98rem;
    font-weight: 500;
}
.exp-dates {
    margin-left: auto;
    color: #b0bec5;
    font-size: 0.98rem;
    font-weight: 400;
}
.exp-bullets {
    list-style: disc inside;
    margin: 0.2em 0 0 0.5em;
    padding-left: 0;
}
/* Remove custom bullet styling */
.exp-bullets li::before { display: none !important; content: none !important; }
body.light-mode .exp-role,
body.light-mode .exp-company {
    color: #232323 !important;
}
body.light-mode .exp-location {
    color: #232323 !important;
}
body.light-mode .exp-dates {
    color: #232323 !important;
}

.disabled-link {
    color: #b0b7bc !important;
    background: #e0e0e0 !important;
    border-radius: 6px;
    padding: 0.4em 1em;
    margin-right: 0.7em;
    text-decoration: none;
    cursor: not-allowed !important;
    pointer-events: auto;
    opacity: 0.7;
    font-weight: 600;
    transition: background 0.2s, color 0.2s;
}
.disabled-link:hover {
    background: #cccccc !important;
    color: #888 !important;
}

#splash-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: #232136;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.7s;
    overflow: hidden;
}
#splash-screen.show {
    opacity: 1;
    pointer-events: auto;
    transition: opacity 0.7s;
}
#splash-screen.hide {
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.7s;
}
#splash-screen > .splash-text,
#splash-screen > .splash-progressbar-container {
    z-index: 2;
}
#splash-screen .splash-text {
    font-size: 3rem;
    font-weight: bold;
    color: #fff;
    letter-spacing: 0.2em;
    font-family: 'Segoe UI', Arial, sans-serif;
    margin-bottom: 2rem;
    text-align: center;
    word-break: break-word;
}
@media (max-width: 600px) {
    #splash-screen .splash-text {
        font-size: 1.6rem;
        letter-spacing: 0.08em;
        margin-bottom: 1.2rem;
        padding: 0 0.5rem;
    }
    .splash-progressbar-container {
        width: 140px;
        height: 7px;
    }
    .doodle-icon {
        font-size: 1.2rem;
    }
}
@media (max-width: 400px) {
    #splash-screen .splash-text {
        font-size: 1.1rem;
        margin-bottom: 0.7rem;
    }
    .splash-progressbar-container {
        width: 90px;
        height: 6px;
    }
}
.splash-progressbar-container {
    width: 220px;
    height: 8px;
    background: rgba(255,255,255,0.15);
    border-radius: 6px;
    overflow: hidden;
    margin-top: 0.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.10);
}
.splash-progressbar {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #38d39f 0%, #ffe066 100%);
    border-radius: 6px;
    transition: width 2s linear;
}

.splash-doodles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none;
    z-index: 1;
}
.doodle-icon {
    position: absolute;
    font-size: 2.2rem;
    opacity: 0.18;
    user-select: none;
    animation: doodle-float 3.5s ease-in-out infinite alternate;
}
.doodle-icon:nth-child(1) { top: 12%; left: 18%; transform: rotate(-12deg); animation-delay: 0s; }
.doodle-icon:nth-child(2) { top: 60%; left: 12%; transform: rotate(8deg); animation-delay: 0.5s; }
.doodle-icon:nth-child(3) { top: 30%; left: 70%; transform: rotate(-8deg); animation-delay: 1s; }
.doodle-icon:nth-child(4) { top: 75%; left: 60%; transform: rotate(15deg); animation-delay: 1.5s; }
.doodle-icon:nth-child(5) { top: 20%; left: 80%; transform: rotate(-18deg); animation-delay: 2s; }
.doodle-icon:nth-child(6) { top: 80%; left: 30%; transform: rotate(10deg); animation-delay: 2.5s; }
.doodle-icon:nth-child(7) { top: 50%; left: 50%; transform: rotate(-5deg); animation-delay: 1.2s; }
.doodle-icon:nth-child(8) { top: 10%; left: 60%; transform: rotate(20deg); animation-delay: 0.8s; }
.doodle-icon:nth-child(9) { top: 65%; left: 75%; transform: rotate(-10deg); animation-delay: 1.8s; }
.doodle-icon:nth-child(10) { top: 40%; left: 35%; transform: rotate(7deg); animation-delay: 0.3s; }
@keyframes doodle-float {
    0% { transform: translateY(0) scale(1) rotate(var(--doodle-rot, 0deg)); }
    100% { transform: translateY(-18px) scale(1.08) rotate(var(--doodle-rot, 0deg)); }
}

/* ===== Background animated shapes (decorative) ===== */
#bg-anim {
    position: fixed;
    inset: 0;
    z-index: 0; /* behind main content which uses z-index:1 */
    pointer-events: none;
    overflow: hidden;
}
.bg-shape {
    position: absolute;
    width: var(--size, 120px);
    height: var(--size, 120px);
    left: var(--left, 10%);
    top: var(--top, 100%);
    /* soft radial glow so shapes read on top of gradient */
    background: radial-gradient(circle at 30% 30%, var(--color, #64b5f6) 0%, rgba(255,255,255,0) 65%);
    border-radius: var(--round, 50%);
    opacity: var(--opa, 0.22);
    filter: blur(var(--blur, 10px));
    transform: translateY(0) translateX(0) rotate(var(--rot, 0deg));
    will-change: transform, opacity;
    animation-name: floatUp;
    animation-timing-function: linear;
    animation-iteration-count: infinite;
    animation-duration: var(--dur, 18s);
    animation-delay: var(--delay, 0s);
    mix-blend-mode: screen; /* helps bright shapes show over the dark gradient */
}

@keyframes floatUp {
    0% {
        transform: translateY(120vh) translateX(0) rotate(var(--rot, 0deg));
        opacity: 0;
    }
    8% {
        opacity: var(--opa, 0.12);
    }
    92% {
        opacity: var(--opa, 0.12);
    }
    100% {
        transform: translateY(-30vh) translateX(var(--drift, 0px)) rotate(calc(var(--rot, 0deg) + 360deg));
        opacity: 0;
    }
}

@media (max-width: 700px) {
    /* Subtle: reduce blur and amount on small screens via JS-driven counts */
    .bg-shape { filter: blur(10px); opacity: 0.12; }
}

/* End background animated shapes */
