@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@300;500;700&family=Poppins:wght@300;400;600&display=swap');

:root {
    --primary-color: #9d4edd;
    --accent-color: #e0aaff;
    --bg-dark: #100A17; 
    --glass-bg: rgba(16, 10, 23, 0.85); 
    --glass-border: rgba(255, 255, 255, 0.1);
    --text-main: #ffffff;
    --text-dim: #cccccc;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
    
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.3) transparent;
}

::-webkit-scrollbar {
    width: 14px; 
    height: 14px;
}

::-webkit-scrollbar-track {
    background: transparent; 
}

::-webkit-scrollbar-thumb {
    background-color: rgba(255, 255, 255, 0.3); 
    border-radius: 20px; 
    border: 4px solid transparent; 
    background-clip: content-box; 
    transition: background-color 0.3s ease;
}

::-webkit-scrollbar-thumb:hover {
    background-color: var(--accent-color);
}

body, html {
    height: 100%;
    overflow: hidden;
    color: var(--text-main);
    background-color: #100A17;
}

.background-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0; 
    pointer-events: none;
}

.background-container iframe {
    width: 100%;
    height: 100%;
    border: none;
    background: transparent; 
}

/* Navbar Styles */
nav {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 98%; 
    max-width: 1600px; 
    height: 80px;
    z-index: 100; 
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 40px;
    
    background: rgba(16, 10, 23, 0.8);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 50px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-header {
    display: flex;
    align-items: center;
    width: auto;
}

.logo a {
    font-family: 'Montserrat', sans-serif;
    font-size: 28px;
    font-weight: 700;
    color: white;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 2px;
    text-shadow: 0 0 10px rgba(157, 78, 221, 0.5);
}

nav ul {
    display: flex;
    list-style: none;
    align-items: center;
}

nav ul li {
    margin-left: 30px;
}

nav ul li a {
    text-decoration: none;
    color: var(--text-dim);
    font-size: 16px;
    font-weight: 500;
    text-transform: uppercase;
    transition: all 0.3s ease;
    padding: 8px 16px;
    border-radius: 20px;
}

nav ul li a:hover, nav ul li a.active {
    color: white;
    background: rgba(157, 78, 221, 0.2);
    box-shadow: 0 0 15px rgba(157, 78, 221, 0.3);
}

.checkbtn {
    font-size: 30px;
    color: white;
    cursor: pointer;
    display: none;
}

#check {
    display: none;
}

main {
    height: 100%;
    width: 100%;
    position: relative;
    z-index: 1; 
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding-top: 120px; 
    padding-bottom: 20px;
    box-sizing: border-box;
    pointer-events: none; 
}

.glass-panel {
    pointer-events: auto; 
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 15px 40px 0 rgba(0, 0, 0, 0.5);
    color: white;
    max-width: 900px;
    width: 90%;
    
    position: relative;
    text-align: center;
    overflow-y: auto; 
    max-height: 100%; 
    
    transition: all 0.3s ease;
}

h1 {
    font-family: 'Montserrat', sans-serif;
    font-size: 2.5em;
    margin-bottom: 20px;
    font-weight: 700;
}

.typed-container {
    min-height: 3em; 
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

.typed-container h1 {
    margin-bottom: 0; 
}

p {
    font-size: 1.1em;
    line-height: 1.6;
    color: #eee;
    margin-bottom: 10px;
}

button, .btn {
    background: linear-gradient(45deg, #5a189a, #7b2cbf);
    color: white;
    border: none;
    border-radius: 50px;
    padding: 12px 30px;
    font-size: 1.1em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(90, 24, 154, 0.4);
    text-decoration: none;
    display: inline-block;
    margin: 10px;
    font-family: 'Montserrat', sans-serif;
}

.btn.secondary {
    background: transparent;
    border: 1px solid var(--accent-color);
    box-shadow: none;
}

.btn.small {
    padding: 8px 20px;
    font-size: 0.9em;
}

.btn.disabled {
    background: #555;
    cursor: not-allowed;
    box-shadow: none;
    color: #aaa;
    border: none;
}

button:hover, .btn:hover {
    transform: translateY(-2px);
    background: linear-gradient(45deg, #5a189a, #7b2cbf);
    box-shadow: 0 0 20px rgba(157, 78, 221, 0.6);
}

.btn.secondary:hover {
    background: rgba(157, 78, 221, 0.2);
    box-shadow: 0 0 15px rgba(157, 78, 221, 0.2);
}

button:active, .btn:active {
    transform: translateY(1px);
    box-shadow: 0 2px 5px rgba(90, 24, 154, 0.4);
}

.content-section {
    transition: opacity 0.3s ease, transform 0.3s ease;
    opacity: 1;
    transform: translateX(0);
}

.content-section.hidden {
    display: none;
    opacity: 0;
    transform: translateX(20px);
}

.content-section.fade-out {
    opacity: 0;
    transform: translateX(-20px);
}

.content-section.active {
    display: block;
    animation: fadeInSection 0.4s ease-out forwards;
}

@keyframes fadeInSection {
    from { opacity: 0; transform: translateX(20px); }
    to { opacity: 1; transform: translateX(0); }
}

.resume-content {
    text-align: left;
    margin-bottom: 30px;
}

.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
}

.tags span {
    background: rgba(157, 78, 221, 0.2);
    border: 1px solid var(--primary-color);
    border-radius: 15px;
    padding: 5px 12px;
    font-size: 0.85em;
    color: var(--accent-color);
}

.education-experience {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin: 20px 0;
}

.education-experience i {
    color: var(--primary-color);
    margin-right: 8px;
    width: 20px;
    text-align: center;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.back-btn {
    background: transparent;
    border: none;
    color: var(--text-dim);
    font-size: 0.9em;
    padding: 5px 10px;
    margin: 0;
    box-shadow: none;
}

.back-btn:hover {
    color: white;
    transform: translateX(-3px);
    box-shadow: none;
    background: transparent; 
}

.carousel-container {
    position: relative;
    width: 100%;
    margin: 0 auto;
}

.carousel-track-container {
    overflow: hidden;
    border-radius: 15px;
    background: rgba(0,0,0,0.2);
    box-shadow: inset 0 0 20px rgba(0,0,0,0.5);
    padding: 5px; 
}

.carousel-track {
    display: flex;
    transition: transform 0.4s ease-in-out;
    padding: 0;
    list-style: none;
}

.carousel-slide {
    min-width: 100%;
    padding: 20px;
    box-sizing: border-box;
}

.project-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.project-img-container {
    width: 100%;
    height: 250px;
    border-radius: 10px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
}

.project-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform 0.3s ease;
}

.project-img:hover {
    transform: scale(1.02);
}

.project-info {
    text-align: left;
    width: 100%;
}

.project-info h3 {
    color: var(--accent-color);
    font-family: 'Montserrat', sans-serif;
    margin-bottom: 10px;
}

.nav-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.08); 
    border: 1px solid rgba(255, 255, 255, 0.15); 
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.2em;
    cursor: pointer;
    z-index: 10;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0;
    opacity: 0; 
    transition: all 0.3s ease;
    
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    box-shadow: 
        0 4px 6px rgba(0,0,0,0.1),
        inset 0 1px 0 rgba(255,255,255,0.2);
}

.carousel-container:hover .nav-arrow {
    opacity: 1;
}

.nav-arrow:hover {
    background: rgba(255, 255, 255, 0.15);
    color: var(--accent-color);
    transform: translateY(-50%) scale(1.1);
    border-color: rgba(255, 255, 255, 0.3);
    box-shadow: 
        0 6px 12px rgba(0,0,0,0.2),
        inset 0 1px 0 rgba(255,255,255,0.3);
}

.nav-arrow.left { left: -10px; }
.nav-arrow.right { right: -10px; }

.carousel-nav-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-top: 15px;
}

.carousel-nav {
    display: flex;
    justify-content: center;
    gap: 10px;
}

.carousel-indicator {
    border: none;
    border-radius: 50%;
    width: 8px;
    height: 8px;
    background: rgba(255,255,255,0.2);
    margin: 0;
    padding: 0;
    cursor: pointer;
    box-shadow: none;
    transition: all 0.3s ease;
}

.carousel-indicator.current-indicator {
    background: var(--primary-color);
    box-shadow: 0 0 8px var(--primary-color);
    transform: scale(1.3);
}

.swipe-instruction {
    display: none; 
    font-size: 0.75em;
    color: rgba(255,255,255,0.4);
    margin-top: 10px;
    font-weight: 400;
    letter-spacing: 1px;
    text-transform: uppercase;
    animation: pulse 2.5s infinite ease-in-out;
}

@keyframes pulse {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 0.8; }
}

@media (max-width: 858px) {
    .checkbtn {
        display: block;
    }
    
    .education-experience {
        grid-template-columns: 1fr;
    }

    nav {
        padding: 0 20px;
        top: 10px;
        width: 95%;
        flex-direction: column;
        justify-content: flex-start; 
        overflow: hidden; 
    }

    .nav-header {
        width: 100%;
        height: 80px; 
        justify-content: space-between;
    }

    nav ul {
        position: static;
        width: 100%;
        height: 0;
        background: transparent;
        backdrop-filter: none;
        top: auto;
        left: 0;
        width: 100%;
        transform: translateX(100%); 
        flex-direction: column;
        justify-content: flex-start; 
        opacity: 0;
        transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.4s ease;
    }

    nav ul li {
        margin: 20px 0;
        opacity: 0;
        transform: translateY(20px);
        transition: opacity 0.3s ease, transform 0.3s ease;
    }

    nav ul li a {
        font-size: 20px;
    }

    nav:has(#check:checked) {
        width: 100%;
        max-width: 100%;
        height: 100%;
        top: 0;
        border-radius: 0;
        background: rgba(16, 10, 23, 0.98); 
    }

    nav:has(#check:checked) ul {
        height: calc(100vh - 80px);
        opacity: 1;
        transform: translateX(0); 
        transition-delay: 0.1s;
    }
    
    nav:has(#check:checked) ul li {
        opacity: 1;
        transform: translateY(0);
    }
    
    nav:has(#check:checked) ul li:nth-child(1) { transition-delay: 0.2s; }
    nav:has(#check:checked) ul li:nth-child(2) { transition-delay: 0.3s; }
    nav:has(#check:checked) ul li:nth-child(3) { transition-delay: 0.4s; }
    nav:has(#check:checked) ul li:nth-child(4) { transition-delay: 0.5s; }
    nav:has(#check:checked) ul li:nth-child(5) { transition-delay: 0.6s; }

    .glass-panel {
        width: 90%;
        padding: 25px;
    }

    .nav-arrow {
        display: none !important;
    }

    .swipe-instruction {
        display: block;
    }
}

@media (max-height: 750px) and (max-width: 858px) {
    main {
        padding-top: 90px; 
    }
    nav {
        height: 60px;
    }
    .nav-header {
        height: 60px;
    }
    .logo a {
        font-size: 22px;
    }
    .glass-panel {
        padding: 20px;
    }
    h1 {
        font-size: 2em;
        margin-bottom: 15px;
    }
    p {
        font-size: 1em;
        line-height: 1.4;
    }
    .project-img-container {
        height: 180px;
    }
    .btn {
        padding: 10px 25px;
        font-size: 1em;
    }
}

input[type="text"], input[type="file"] {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    padding: 12px;
    color: white;
    font-size: 1em;
    width: 100%;
    margin-bottom: 15px;
    outline: none;
    transition: all 0.3s;
}

input[type="text"]:focus {
    background: rgba(255, 255, 255, 0.15);
    border-color: var(--accent-color);
    box-shadow: 0 0 10px rgba(224, 170, 255, 0.2);
}

#drop-zone {
    border: 2px dashed rgba(255, 255, 255, 0.3);
    border-radius: 15px;
    width: 100%;
    height: 200px;
    margin: 20px 0;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.3s ease;
    position: relative;
    background: rgba(0, 0, 0, 0.2);
}

#drop-zone.dragover {
    border-color: var(--accent-color);
    background: rgba(157, 78, 221, 0.2);
    box-shadow: 0 0 15px rgba(157, 78, 221, 0.3) inset;
}

.drop-text {
    font-size: 1.2em;
    color: rgba(255, 255, 255, 0.6);
    pointer-events: none;
}

video {
    max-width: 100%;
    max-height: 100%; 
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.5);
}

#error-popup {
    position: fixed;
    top: 100px;
    right: 20px;
    background: rgba(255, 0, 0, 0.2);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 100, 100, 0.3);
    color: white;
    padding: 15px 25px;
    border-radius: 10px;
    z-index: 1000;
    opacity: 0;
    transform: translateX(20px);
    transition: all 0.4s ease;
    pointer-events: none;
}

#error-popup.show {
    opacity: 1;
    transform: translateX(0);
}