/*--------------------------------------------------------------
# Variables & Theming
--------------------------------------------------------------*/
:root {
  --bg-color: #0b1120;
  --bg-color-glass: rgba(15, 23, 42, 0.7);
  --bg-color-glass-solid: rgba(15, 23, 42, 0.95);
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --accent-color: #00f0ff;
  --accent-secondary: #8b5cf6;
  --border-color: rgba(0, 240, 255, 0.2);
  --card-bg: rgba(30, 41, 59, 0.4);
  --card-bg-hover: rgba(30, 41, 59, 0.8);
  --font-heading: 'Outfit', sans-serif;
  --font-body: 'Inter', sans-serif;
  --glow: 0 0 15px rgba(0, 240, 255, 0.6);
  --glow-secondary: 0 0 15px rgba(139, 92, 246, 0.6);
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/*--------------------------------------------------------------
# General
--------------------------------------------------------------*/
body {
    font-family: var(--font-body);
    color: var(--text-main);
    background-color: var(--bg-color);
    background-image: 
        radial-gradient(circle at 10% 20%, rgba(0, 240, 255, 0.05) 0%, transparent 40%),
        radial-gradient(circle at 90% 80%, rgba(139, 92, 246, 0.05) 0%, transparent 40%);
    background-attachment: fixed;
}

a {
    color: var(--accent-color);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: #fff;
    text-shadow: var(--glow);
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    color: #fff;
}

/* Glassmorphism Utilities */
.glass-panel {
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    transition: var(--transition);
}

.glass-panel:hover {
    background: var(--card-bg-hover);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
}

/*--------------------------------------------------------------
# Back to top button
--------------------------------------------------------------*/
.back-to-top {
    position: fixed;
    visibility: hidden;
    opacity: 0;
    right: 15px;
    bottom: 15px;
    z-index: 996;
    background: var(--bg-color-glass-solid);
    border: 1px solid var(--accent-color);
    width: 45px;
    height: 45px;
    border-radius: 50%;
    transition: var(--transition);
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: var(--glow);
}

.back-to-top i {
    font-size: 24px;
    color: var(--accent-color);
    line-height: 0;
}

.back-to-top:hover {
    background: var(--accent-color);
    color: #000;
    box-shadow: 0 0 25px var(--accent-color);
}

.back-to-top:hover i {
    color: #000;
}

.back-to-top.active {
    visibility: visible;
    opacity: 1;
}

/*--------------------------------------------------------------
# Preloader
--------------------------------------------------------------*/
#preloader {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9999;
    overflow: hidden;
    background: var(--bg-color);
}

#preloader:before {
    content: "";
    position: fixed;
    top: calc(50% - 30px);
    left: calc(50% - 30px);
    border: 6px solid rgba(0, 240, 255, 0.2);
    border-top-color: var(--accent-color);
    border-radius: 50%;
    width: 60px;
    height: 60px;
    animation: animate-preloader 1s linear infinite;
    box-shadow: var(--glow);
}

@keyframes animate-preloader {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/*--------------------------------------------------------------
# Header & Navigation
--------------------------------------------------------------*/
#header {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 9997;
    transition: all 0.5s;
    padding: 15px;
    overflow-y: auto;
}

@media (max-width: 992px) {
    #header {
        width: 300px;
        background: var(--bg-color-glass-solid);
        backdrop-filter: blur(10px);
        border-right: 1px solid var(--border-color);
        left: -300px;
    }
}

@media (min-width: 992px) {
    #main { margin-left: 100px; }
    #footer { margin-left: 100px; }
}

.nav-menu {
    padding: 0;
    display: block;
}

.nav-menu * {
    margin: 0;
    padding: 0;
    list-style: none;
}

.nav-menu > ul > li {
    position: relative;
    white-space: nowrap;
}

.nav-menu a, .nav-menu a:focus {
    display: flex;
    align-items: center;
    color: var(--text-muted);
    padding: 10px 18px;
    margin-bottom: 12px;
    transition: var(--transition);
    font-size: 15px;
    border-radius: 50px;
    background: rgba(30, 41, 59, 0.4);
    border: 1px solid transparent;
    height: 56px;
    width: 100%;
    overflow: hidden;
}

.nav-menu a i, .nav-menu a:focus i {
    font-size: 20px;
}

.nav-menu a span, .nav-menu a:focus span {
    padding: 0 5px 0 10px;
    color: var(--text-main);
    font-weight: 500;
}

@media (min-width: 992px) {
    .nav-menu a, .nav-menu a:focus {
        width: 56px;
    }
    .nav-menu a span, .nav-menu a:focus span {
        display: none;
        color: #fff;
    }
}

.nav-menu a:hover, .nav-menu .active, .nav-menu .active:focus, .nav-menu li:hover > a {
    color: var(--accent-color);
    background: var(--bg-color-glass-solid);
    border: 1px solid var(--accent-color);
    box-shadow: inset 0 0 15px rgba(0, 240, 255, 0.1), var(--glow);
}

.nav-menu a:hover span, .nav-menu .active span, .nav-menu .active:focus span, .nav-menu li:hover > a span {
    color: var(--accent-color);
}

@media (min-width: 992px) {
    .nav-menu a:hover, .nav-menu li:hover > a {
        width: 100%;
        color: var(--accent-color);
    }
    .nav-menu a:hover span, .nav-menu li:hover > a span {
        display: block;
    }
}

.mobile-nav-toggle {
    position: fixed;
    right: 15px;
    top: 15px;
    z-index: 9998;
    border: 1px solid var(--accent-color);
    background: var(--bg-color-glass-solid);
    backdrop-filter: blur(5px);
    font-size: 28px;
    transition: var(--transition);
    outline: none !important;
    line-height: 0;
    cursor: pointer;
    border-radius: 50%;
    padding: 8px;
    color: var(--accent-color);
    box-shadow: var(--glow);
}

.mobile-nav-active { overflow: hidden; }
.mobile-nav-active #header { left: 0; }
.mobile-nav-active .mobile-nav-toggle {
    color: #0b1120;
    background-color: var(--accent-color);
}

/*--------------------------------------------------------------
# Hero Section
--------------------------------------------------------------*/
#hero {
    width: 100%;
    height: 100vh;
    background: radial-gradient(circle at center, rgba(15, 23, 42, 0.8) 0%, var(--bg-color) 100%);
    position: relative;
    overflow: hidden;
}

#hero::before {
    content: '';
    position: absolute;
    top: 0; right: 0; bottom: 0; left: 0;
    background: 
        linear-gradient(45deg, transparent 49%, rgba(0, 240, 255, 0.03) 50%, transparent 51%) 0 0 / 20px 20px,
        linear-gradient(-45deg, transparent 49%, rgba(139, 92, 246, 0.03) 50%, transparent 51%) 0 0 / 20px 20px;
    animation: backgroundShift 30s linear infinite;
    z-index: 0;
}

@keyframes backgroundShift {
    0% { background-position: 0 0; }
    100% { background-position: 400px 400px; }
}

@media (min-width: 992px) {
    #hero { padding-left: 160px; }
}

#hero .container {
    position: relative;
    z-index: 1;
}

#hero h1 {
    margin: 0;
    font-size: 72px;
    font-weight: 800;
    line-height: 1.2;
    background: linear-gradient(to right, #fff, var(--text-muted));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 30px rgba(255,255,255,0.1);
}

#hero p {
    color: var(--text-muted);
    margin: 20px 0 0 0;
    font-size: 28px;
    font-family: var(--font-body);
    font-weight: 300;
}

#hero p span {
    color: var(--accent-color);
    font-weight: 600;
    text-shadow: var(--glow);
}

#hero .social-links { margin-top: 40px; display: flex; gap: 20px;}
#hero .social-links a {
    font-size: 24px;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 50px;
    height: 50px;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 50%;
    color: var(--text-main);
    transition: var(--transition);
}

#hero .social-links a:hover {
    color: #0b1120;
    background: var(--accent-color);
    box-shadow: var(--glow);
    transform: translateY(-3px);
}

@media (max-width: 992px) {
    #hero { text-align: center; }
    #hero h1 { font-size: 40px; }
    #hero p { font-size: 22px; }
    #hero .social-links { justify-content: center; }
}

/* Scroll Down Animation */
#scroll {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
}

#scroll-down {
    display: block;
    text-align: center;
    padding-top: 60px;
    position: relative;
}

.arrow-down {
    display: block;
    margin: 0 auto;
    width: 15px;
    height: 15px;
    border-bottom: 2px solid var(--accent-color);
    border-right: 2px solid var(--accent-color);
    transform: rotate(45deg);
    animation: arrowBounce 2s infinite;
}

@keyframes arrowBounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0) rotate(45deg); }
    40% { transform: translateY(-10px) rotate(45deg); }
    60% { transform: translateY(-5px) rotate(45deg); }
}

#scroll-title {
    margin-top: 15px;
    display: block;
    text-transform: uppercase;
    color: var(--text-muted);
    font-size: 12px;
    letter-spacing: 2px;
}

/*--------------------------------------------------------------
# Sections General
--------------------------------------------------------------*/
section {
    padding: 80px 0;
    overflow: hidden;
}

.section-title {
    text-align: center;
    padding-bottom: 40px;
}

.section-title h2 {
    font-size: 36px;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 20px;
    padding-bottom: 20px;
    position: relative;
    color: #fff;
    letter-spacing: 1px;
}

.section-title h2::before {
    content: '';
    position: absolute;
    display: block;
    width: 120px;
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
    bottom: 1px;
    left: calc(50% - 60px);
}

.section-title h2::after {
    content: '';
    position: absolute;
    display: block;
    width: 40px;
    height: 3px;
    background: var(--accent-color);
    bottom: 0;
    left: calc(50% - 20px);
    box-shadow: var(--glow);
}

.section-title p {
    color: var(--text-muted);
    max-width: 800px;
    margin: 0 auto;
    font-size: 16px;
    line-height: 1.6;
}

/*--------------------------------------------------------------
# About
--------------------------------------------------------------*/
.about .content h3 {
    font-weight: 600;
    font-size: 24px;
    color: var(--accent-color);
    margin-bottom: 20px;
}

.about .content ul { list-style: none; padding: 0; }
.about .content ul li {
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    color: var(--text-main);
}
.about .content ul strong { margin-right: 10px; color: #fff;}
.about .content ul i {
    font-size: 16px;
    margin-right: 10px;
    color: var(--accent-color);
}
.about .content .fst-italic { color: var(--text-muted); margin-bottom: 20px; }

/*--------------------------------------------------------------
# Skills
--------------------------------------------------------------*/
.skills .progress {
    height: 60px;
    display: block;
    background: none;
    border-radius: 0;
}

.skills .progress .skill {
    padding: 10px 0;
    margin: 0;
    text-transform: uppercase;
    display: block;
    font-weight: 600;
    font-size: 14px;
    color: #fff;
    letter-spacing: 1px;
}

.skills .progress .skill .val { float: right; font-style: normal; color: var(--accent-color); }

.skills .progress-bar-wrap {
    background: var(--card-bg);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 10px;
    height: 12px;
    overflow: hidden;
}

.skills .progress-bar {
    height: 100%;
    width: 0;
    transition: .9s;
    background: linear-gradient(90deg, var(--accent-secondary), var(--accent-color));
    box-shadow: var(--glow);
    border-radius: 10px;
}

/*--------------------------------------------------------------
# Resume
--------------------------------------------------------------*/
.resume .resume-title {
    font-size: 24px;
    font-weight: 700;
    margin-top: 30px;
    margin-bottom: 20px;
    color: #fff;
}

.resume .resume-item {
    padding: 0 0 20px 25px;
    margin-top: -2px;
    border-left: 2px solid var(--border-color);
    position: relative;
}

.resume .resume-item h4 {
    line-height: 18px;
    font-size: 18px;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--accent-color);
    margin-bottom: 10px;
}

.resume .resume-item h5 {
    font-size: 14px;
    background: var(--card-bg);
    padding: 5px 15px;
    display: inline-block;
    font-weight: 500;
    margin-bottom: 15px;
    border-radius: 4px;
    border: 1px solid rgba(255,255,255,0.05);
    color: var(--text-muted);
}

.resume .resume-item p { color: var(--text-main); }
.resume .resume-item ul { padding-left: 20px; color: var(--text-muted); }
.resume .resume-item ul li { padding-bottom: 10px; }
.resume .resume-item::before {
    content: "";
    position: absolute;
    width: 16px;
    height: 16px;
    border-radius: 50px;
    left: -9px;
    top: 0;
    background: var(--bg-color);
    border: 2px solid var(--accent-color);
    box-shadow: var(--glow);
    transition: var(--transition);
}
.resume .resume-item:hover::before {
    background: var(--accent-color);
}

.resume button {
    background: transparent;
    border: 1px solid var(--accent-color);
    padding: 12px 40px;
    color: var(--accent-color);
    transition: var(--transition);
    border-radius: 50px;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
}
.resume button:hover {
    background: var(--accent-color);
    color: #0b1120;
    box-shadow: var(--glow);
}

/*--------------------------------------------------------------
# Projects
--------------------------------------------------------------*/
.projects .icon-box {
    text-align: center;
    padding: 40px 20px;
    transition: var(--transition);
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.projects .icon-box:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.5), inset 0 0 10px rgba(0, 240, 255, 0.1);
    border-color: var(--accent-color);
}

.projects .icon-box .icon {
    margin: 0 auto 20px auto;
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,0.05);
    border-radius: 50%;
    transition: var(--transition);
}

.projects .icon-box:hover .icon {
    background: var(--accent-color);
    box-shadow: var(--glow);
}

.projects .icon-box .icon i {
    font-size: 36px;
    color: var(--accent-color);
    transition: var(--transition);
}

.projects .icon-box:hover .icon i { color: #0b1120; }

.projects .icon-box .icon svg { display: none; /* Hide old svg backgrounds */ }

.projects .icon-box h4 {
    font-weight: 600;
    margin-bottom: 15px;
    font-size: 20px;
}
.projects .icon-box h4 a { color: #fff; }
.projects .icon-box:hover h4 a { color: var(--accent-color); }
.projects .icon-box p {
    color: var(--text-muted);
    font-size: 14px;
    line-height: 1.6;
    margin: 0;
    flex-grow: 1;
}

/*--------------------------------------------------------------
# Contact
--------------------------------------------------------------*/
.contact .info {
    width: 100%;
    background: var(--card-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 40px;
}

.contact .info i {
    font-size: 20px;
    color: var(--accent-color);
    float: left;
    width: 50px;
    height: 50px;
    background: rgba(0, 240, 255, 0.1);
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 50px;
    transition: var(--transition);
    border: 1px solid transparent;
}

.contact .info h4 {
    padding: 0 0 0 70px;
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 5px;
    color: #fff;
}

.contact .info p {
    padding: 0 0 0 70px;
    margin-bottom: 0;
    font-size: 15px;
    color: var(--text-muted);
}

.contact .info .email, .contact .info .phone,
.contact .info .address, .contact .info .linkedin,
.contact .info .github, .contact .info .whatsapp {
    margin-top: 30px;
}

.contact .info a:hover i {
    background: var(--accent-color);
    color: #0b1120;
    box-shadow: var(--glow);
    border-color: var(--accent-color);
}

/*--------------------------------------------------------------
# Footer
--------------------------------------------------------------*/
#footer {
    background: var(--bg-color-glass-solid);
    border-top: 1px solid var(--border-color);
    color: var(--text-muted);
    text-align: center;
    padding: 40px 0;
}

#footer h3 {
    font-size: 28px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 10px;
}

#footer p {
    font-size: 15px;
    margin-bottom: 30px;
}

#footer .social-links a {
    font-size: 20px;
    display: inline-block;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-main);
    line-height: 1;
    padding: 10px 0;
    margin: 0 5px;
    border-radius: 50%;
    text-align: center;
    width: 40px;
    height: 40px;
    transition: var(--transition);
    border: 1px solid rgba(255,255,255,0.1);
}

#footer .social-links a:hover {
    background: var(--accent-color);
    color: #0b1120;
    border-color: var(--accent-color);
    box-shadow: var(--glow);
    transform: translateY(-3px);
}

/*--------------------------------------------------------------
# Animations & Futuristic Effects
--------------------------------------------------------------*/
/* Hide Default Cursor */
@media (pointer: fine) {
    body, a, button, .icon-box, input, textarea {
        cursor: none !important;
    }
}

/* Custom Cursor */
.cursor-dot {
    width: 6px;
    height: 6px;
    background-color: var(--accent-color);
    box-shadow: var(--glow);
    position: fixed;
    top: 0;
    left: 0;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    z-index: 99999;
    pointer-events: none;
}

.cursor-outline {
    width: 30px;
    height: 30px;
    border: 1px solid var(--accent-color);
    position: fixed;
    top: 0;
    left: 0;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    z-index: 99998;
    pointer-events: none;
    transition: width 0.2s, height 0.2s, background-color 0.2s;
}

.cursor-outline.hover {
    width: 60px;
    height: 60px;
    background-color: rgba(0, 240, 255, 0.1);
    box-shadow: 0 0 15px rgba(0, 240, 255, 0.3);
}

/* tsParticles Container */
#tsparticles {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: 0;
}

/* Profile Image Animation */
.profile-img-wrapper {
    position: relative;
    width: 250px;
    height: 250px;
    border-radius: 50%;
    animation: floating 4s ease-in-out infinite;
    display: flex;
    justify-content: center;
    align-items: center;
}

.profile-img-wrapper::before {
    content: '';
    position: absolute;
    top: -5px; right: -5px; bottom: -5px; left: -5px;
    border-radius: 50%;
    background: linear-gradient(45deg, var(--accent-color), var(--accent-secondary), var(--accent-color), var(--accent-secondary));
    background-size: 400% 400%;
    z-index: -1;
    animation: rotateRing 8s linear infinite;
    filter: blur(5px);
    opacity: 0.8;
}

.profile-img-animated {
    border-radius: 50%;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border: 3px solid var(--bg-color);
}

@keyframes rotateRing {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes floating {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-15px); }
}

/* Glitch Hover Effect */
.section-title h2 {
    transition: var(--transition);
}

.section-title h2:hover {
    animation: glitch-anim 0.2s linear infinite;
    color: #fff;
}

@keyframes glitch-anim {
    0% { text-shadow: 2px 2px var(--accent-color), -2px -2px var(--accent-secondary); }
    25% { text-shadow: -2px 2px var(--accent-color), 2px -2px var(--accent-secondary); }
    50% { text-shadow: 2px -2px var(--accent-color), -2px 2px var(--accent-secondary); }
    75% { text-shadow: -2px -2px var(--accent-color), 2px 2px var(--accent-secondary); }
    100% { text-shadow: 2px 2px var(--accent-color), -2px -2px var(--accent-secondary); }
}
