/* =========================================
   1. VARIABLES & GLOBAL RESET
   ========================================= */
:root {
    /* Colors */
    --primary-color: #00ffc3;   /* Neon Cyan */
    --secondary-color: #7d2ae8; /* Deep Purple */
    --bg-dark: #0a0f1c;         /* Main Background */
    --bg-card: #111a2e;         /* Card Background */
    --text-main: #e2e8f0;
    --text-muted: #94a3b8;
    
    /* Typography */
    --font-heading: 'Outfit', sans-serif;
    --font-mono: 'Roboto Mono', monospace;

    /* Effects */
    --transition-base: all 0.3s ease;
    --shadow-glow: 0 0 20px rgba(0, 255, 195, 0.3);
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
}

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

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    font-family: var(--font-heading);
    overflow-x: hidden;
    position: relative;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5 { font-weight: 700; }
a { text-decoration: none; transition: var(--transition-base); }
ul { list-style: none; padding: 0; margin: 0; }

/* Custom Scrollbar (Cross-Browser) */
::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: var(--bg-dark); }
::-webkit-scrollbar-thumb { background: #334155; border-radius: 5px; }
::-webkit-scrollbar-thumb:hover { background: var(--primary-color); }

/* Firefox Scrollbar */
html {
    scrollbar-width: thin;
    scrollbar-color: #334155 var(--bg-dark);
}

/* Utility Classes */
.text-gradient {
    background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}
.section-padding { padding: 100px 0; }
.bg-darker { background: rgba(0,0,0,0.2); }

/* =========================================
   2. PRELOADER
   ========================================= */
#preloader {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: var(--bg-dark); z-index: 9999;
    display: flex; justify-content: center; align-items: center;
}
.loader-content { text-align: center; }
.loader-text {
    font-family: var(--font-mono); font-size: 1.5rem; color: var(--primary-color);
    letter-spacing: 2px;
}
.loader-line {
    width: 0; height: 2px; background: var(--secondary-color);
    margin-top: 10px; animation: loadLine 1.5s ease-in-out forwards;
}
@keyframes loadLine { 0% { width: 0; } 100% { width: 100%; } }

/* =========================================
   3. NAVBAR
   ========================================= */
.navbar {
    padding: 20px 0; transition: all 0.4s ease;
    background: transparent;
}
.navbar.scrolled {
    padding: 10px 0;
    background: rgba(10, 15, 28, 0.85);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--glass-border);
}
.brand-text { font-size: 1.5rem; font-weight: 700; color: #fff; }
.dot { color: var(--primary-color); }

.nav-link {
    color: var(--text-muted) !important;
    font-size: 0.95rem; margin: 0 10px; position: relative;
}
.nav-link:hover, .nav-link.active { color: #fff !important; }

/* Underline Animation */
.nav-link::after {
    content: ''; position: absolute; width: 0; height: 2px;
    bottom: 0px; left: 0; background-color: var(--primary-color);
    transition: width 0.3s ease;
}
.nav-link:hover::after, .nav-link.active::after { width: 100%; }

/* CTA Button */
.btn-custom {
    background: linear-gradient(45deg, var(--secondary-color), #5b10b0);
    color: white; border-radius: 50px; padding: 8px 25px;
    font-size: 0.9rem; border: none; position: relative; overflow: hidden;
    box-shadow: 0 5px 15px rgba(125, 42, 232, 0.2);
}
.btn-custom:hover {
    color: white; transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(125, 42, 232, 0.4);
}

/* Toggler */
.navbar-toggler { border: none; box-shadow: none !important; }
.bar-icon {
    display: block; width: 25px; height: 3px; margin: 5px auto;
    background-color: white; transition: all 0.3s ease-in-out;
}

/* Mobile Menu */
@media (max-width: 991px) {
    .navbar-collapse {
        background: var(--bg-card);
        padding: 20px; border-radius: 10px; margin-top: 10px;
        box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    }
    .nav-item { margin-bottom: 10px; }
}

/* =========================================
   4. HERO SECTION
   ========================================= */
.hero-section {
    min-height: 100vh;
    padding-top: 80px;
    position: relative;
    overflow: hidden; /* Ensures blobs don't cause scroll */
}

/* Background Blobs */
.hero-glow {
    position: absolute; width: 300px; height: 300px;
    filter: blur(100px); z-index: 0; opacity: 0.4; border-radius: 50%;
    will-change: transform; /* Performance optimization */
}
.glow-left { top: 20%; left: -100px; background: var(--secondary-color); }
.glow-right { bottom: 10%; right: -100px; background: var(--primary-color); }

/* Typography */
.inline-badge {
    display: inline-block; padding: 5px 15px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 20px; font-size: 0.85rem; color: var(--primary-color);
}
.hero-title {
    font-size: 3.5rem; font-weight: 800; color: #fff;
    line-height: 1.2; margin-bottom: 10px;
}
.hero-subtitle { font-size: 1.8rem; color: var(--text-main); font-weight: 300; }
.typing-text { color: var(--primary-color); font-weight: 600; }
.cursor { color: var(--text-main); animation: blink 1s infinite; }
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: 0; } }

.hero-desc {
    color: var(--text-muted); font-size: 1.1rem;
    max-width: 550px; margin: 0 auto;
}
@media (min-width: 992px) { .hero-desc { margin: 0; } }

/* Hero Buttons */
.btn-primary-glow {
    background-color: var(--primary-color); color: var(--bg-dark);
    font-weight: 600; padding: 12px 30px; border-radius: 8px;
    box-shadow: var(--shadow-glow); transition: var(--transition-base);
}
.btn-primary-glow:hover {
    background-color: #fff; transform: translateY(-3px);
    box-shadow: 0 0 30px rgba(0, 255, 195, 0.6);
}

/* Hero Image */
.hero-img-wrapper { position: relative; display: inline-block; padding: 20px; }
.blob-bg {
    position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
    width: 350px; height: 350px;
    background: linear-gradient(45deg, var(--secondary-color), var(--primary-color));
    border-radius: 40% 60% 70% 30% / 40% 50% 60% 50%;
    opacity: 0.2; z-index: -1; 
    animation: blobAnim 8s ease-in-out infinite alternate;
    will-change: border-radius;
}
@keyframes blobAnim {
    0% { border-radius: 40% 60% 70% 30% / 40% 50% 60% 50%; }
    100% { border-radius: 70% 30% 50% 50% / 30% 60% 40% 70%; }
}
.hero-img {
    width: 320px; height: 320px; object-fit: cover;
    border-radius: 30px; border: 2px solid var(--glass-border);
    box-shadow: 0 20px 40px rgba(0,0,0,0.5); background: #1a1a1a;
}
.floating-anim { animation: floatImage 4s ease-in-out infinite; }
@keyframes floatImage {
    0% { transform: translateY(0); }
    50% { transform: translateY(-15px); }
    100% { transform: translateY(0); }
}

/* Floating Icons */
.floating-card {
    position: absolute; width: 50px; height: 50px;
    background: rgba(255,255,255,0.1); backdrop-filter: blur(10px);
    border-radius: 12px; display: flex; justify-content: center; align-items: center;
    font-size: 1.5rem; color: #fff; box-shadow: 0 10px 20px rgba(0,0,0,0.2);
    animation: floatImage 5s ease-in-out infinite;
}
.card-python { top: 10%; left: -10px; color: #ffd43b; animation-delay: 0.5s; }
.card-ai { bottom: 15%; right: 0px; color: var(--primary-color); animation-delay: 1s; }

/* Scroll Mouse */
.scroll-down-btn {
    position: absolute; bottom: 30px; left: 50%; transform: translateX(-50%);
}
.mouse {
    width: 25px; height: 45px; border: 2px solid rgba(255,255,255,0.5);
    border-radius: 20px; position: relative;
}
.wheel {
    width: 4px; height: 8px; background: #fff; position: absolute; top: 6px;
    left: 50%; transform: translateX(-50%); border-radius: 2px;
    animation: scrollWheel 2s infinite;
}
@keyframes scrollWheel {
    0% { opacity: 1; top: 6px; }
    100% { opacity: 0; top: 25px; }
}

@media (max-width: 768px) {
    .hero-title { font-size: 2.5rem; }
    .hero-subtitle { font-size: 1.3rem; }
    .hero-img { width: 250px; height: 250px; }
    .blob-bg { width: 280px; height: 280px; }
}

/* =========================================
   5. SKILLS SECTION
   ========================================= */
.section-subtitle {
    color: var(--primary-color); font-family: var(--font-mono);
    text-transform: uppercase; letter-spacing: 2px;
    font-size: 0.9rem; margin-bottom: 10px;
}
.section-title { font-size: 2.5rem; color: #fff; margin-bottom: 20px; }
.line-divider {
    width: 60px; height: 3px; background: var(--primary-color);
    border-radius: 2px;
}

.skill-card {
    background: var(--bg-card); border: 1px solid var(--glass-border);
    border-radius: 20px; padding: 40px 30px; height: 100%;
    transition: var(--transition-base); position: relative; overflow: hidden; z-index: 1;
}
.skill-card:hover {
    transform: translateY(-10px); border-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.card-icon {
    width: 60px; height: 60px; border-radius: 15px;
    display: flex; justify-content: center; align-items: center;
    font-size: 1.8rem; margin-bottom: 25px; transition: 0.3s;
}
.icon-ai { background: rgba(0, 255, 195, 0.1); color: var(--primary-color); }
.icon-web { background: rgba(125, 42, 232, 0.1); color: var(--secondary-color); }
.icon-tools { background: rgba(255, 193, 7, 0.1); color: #ffc107; }

.skill-card:hover .icon-ai { background: var(--primary-color); color: var(--bg-dark); }
.skill-card:hover .icon-web { background: var(--secondary-color); color: #fff; }
.skill-card:hover .icon-tools { background: #ffc107; color: #000; }

.card-title { font-size: 1.5rem; color: #fff; margin-bottom: 10px; }
.card-desc { color: var(--text-muted); font-size: 0.95rem; margin-bottom: 30px; }

/* Progress Bars */
.skill-item { margin-bottom: 20px; }
.skill-item span {
    font-size: 0.9rem; font-weight: 600; color: #e2e8f0;
    margin-bottom: 8px; display: block;
}
.progress {
    height: 6px; background: rgba(255,255,255,0.1);
    border-radius: 10px; overflow: hidden;
}
.bg-ai { background: var(--primary-color); }
.bg-web { background: var(--secondary-color); }

/* Badges */
.badge-skill {
    display: inline-block; padding: 8px 15px; margin: 0 5px 10px 0;
    background: var(--glass-bg); border: 1px solid var(--glass-border);
    border-radius: 50px; font-size: 0.85rem; color: var(--text-muted);
    transition: 0.3s;
}
.badge-skill:hover {
    background: rgba(255,255,255,0.15); color: #fff;
    border-color: rgba(255,255,255,0.3);
}
@media (max-width: 768px) {
    .section-title { font-size: 2rem; }
    .skill-card { padding: 30px 20px; }
}

/* =========================================
   6. PROJECTS SECTION
   ========================================= */
.project-card {
    background: var(--bg-card); border-radius: 15px;
    overflow: hidden; transition: var(--transition-base);
    border: 1px solid var(--glass-border);
}
.project-card:hover {
    transform: translateY(-5px); border-color: rgba(255, 255, 255, 0.2);
}

.project-img-wrapper {
    position: relative; overflow: hidden; height: 220px;
}
.project-img {
    width: 100%; height: 100%; object-fit: cover;
    transition: transform 0.5s ease;
}
.project-card:hover .project-img { transform: scale(1.1); }

/* Overlay */
.project-overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(10, 15, 28, 0.7); backdrop-filter: blur(3px);
    display: flex; justify-content: center; align-items: center;
    opacity: 0; transition: 0.3s;
}
.project-card:hover .project-overlay { opacity: 1; }

.view-project-btn {
    width: 50px; height: 50px; display: flex; justify-content: center; align-items: center;
    font-size: 1.2rem; transition: 0.3s;
}
.view-project-btn:hover { transform: scale(1.1) rotate(90deg); }

.project-content { padding: 25px; }
.project-cat {
    font-size: 0.8rem; color: var(--primary-color);
    text-transform: uppercase; letter-spacing: 1px;
}
.project-title { font-size: 1.3rem; color: #fff; margin: 5px 0 10px; }
.project-short-desc { color: var(--text-muted); font-size: 0.9rem; margin-bottom: 15px; }

.project-tech-stack span {
    display: inline-block; font-size: 0.75rem;
    padding: 3px 10px; border-radius: 20px;
    background: var(--glass-bg); color: #e2e8f0; margin-right: 5px;
}

/* Modal */
.glass-modal {
    background: #151e32; border: 1px solid var(--glass-border);
    border-radius: 20px;
}
.glass-modal .text-muted { color: rgba(255, 255, 255, 0.7) !important; }
.modal-backdrop.show { opacity: 0.8; }

/* =========================================
   7. RESUME & CERTIFICATES
   ========================================= */
.icon-box {
    width: 45px; height: 45px;
    background: var(--primary-color);
    border-radius: 12px;
    display: flex; justify-content: center; align-items: center;
    font-size: 1.2rem; color: #000;
    box-shadow: var(--shadow-glow);
}

/* Timeline Cards */
.resume-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    padding: 30px;
    border-radius: 15px;
    margin-bottom: 25px;
    position: relative;
    transition: var(--transition-base);
    border-left: 3px solid var(--primary-color);
}
.resume-card:hover {
    transform: translateX(10px);
    background: rgba(255, 255, 255, 0.06);
}
.resume-date {
    display: inline-block;
    background: rgba(0, 255, 195, 0.15); /* Tinted Primary */
    color: var(--primary-color);
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 15px;
}
.resume-title { color: #fff; font-size: 1.25rem; margin-bottom: 5px; }
.resume-place { color: rgba(255, 255, 255, 0.8); font-size: 0.95rem; margin-bottom: 15px; }
.resume-desc { color: rgba(255, 255, 255, 0.5); font-size: 0.9rem; line-height: 1.6; }

/* Certificate Cards */
.cert-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 20px;
    transition: 0.3s;
}
.cert-card:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.2);
}
.cert-icon {
    width: 50px; height: 50px;
    background: var(--glass-bg);
    border-radius: 50%;
    display: flex; justify-content: center; align-items: center;
    margin-right: 20px;
    font-size: 1.5rem;
    color: var(--primary-color);
    flex-shrink: 0;
}
.cert-link {
    color: var(--primary-color);
    text-decoration: none;
    font-size: 0.85rem; font-weight: 600;
    transition: 0.3s;
}
.cert-link:hover { color: #fff; letter-spacing: 0.5px; }

/* =========================================
   8. CONTACT & FOOTER
   ========================================= */
.contact-info-wrapper {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
}

.contact-card {
    background: var(--glass-bg);
    border-radius: 15px;
    transition: var(--transition-base);
    border: 1px solid transparent;
}
.contact-card:hover {
    background: rgba(255, 255, 255, 0.06);
    transform: translateY(-5px);
    border-color: rgba(255, 255, 255, 0.1);
}

.icon-box-sm {
    width: 50px; height: 50px;
    background: var(--glass-bg);
    border-radius: 50%;
    display: flex; justify-content: center; align-items: center;
    color: var(--primary-color);
    font-size: 1.2rem;
    border: 1px solid var(--glass-border);
}

/* Unified Social Buttons */
.social-btn {
    display: inline-flex; justify-content: center; align-items: center;
    width: 45px; height: 45px;
    border-radius: 50%;
    background: var(--glass-bg);
    color: #fff;
    border: 1px solid var(--glass-border);
    transition: var(--transition-base);
    text-decoration: none;
    font-size: 1.1rem;
    margin: 0 5px; /* Spacing handled here */
}
.social-btn:hover {
    background: var(--primary-color);
    color: var(--bg-dark);
    transform: translateY(-3px) rotate(360deg);
    box-shadow: var(--shadow-glow);
}

/* Footer Specifics */
.footer-section {
    background-color: #05080f; padding: 60px 0 20px; margin-top: auto;
}
.footer-links a { color: var(--text-muted); display: block; margin-bottom: 8px; }
.footer-links a:hover { color: var(--primary-color); padding-left: 5px; }
.footer-divider { border-color: rgba(255,255,255,0.1); margin: 30px 0; }

/* Scroll Top */
.scroll-top {
    position: fixed; bottom: 30px; right: 30px; width: 45px; height: 45px;
    background: var(--primary-color); color: var(--bg-dark); border-radius: 50%;
    display: flex; justify-content: center; align-items: center;
    z-index: 1000; box-shadow: var(--shadow-glow);
    transition: 0.3s;
}
.scroll-top:hover { transform: translateY(-5px); background: #fff; }