/* ===== CSS Variables ===== */
:root {
    /* Electric Blue Theme Colors */
    --color-primary: #00d4ff;
    --color-secondary: #ffb800;
    --color-accent: #ff006e;
    --color-electric-blue: #0066ff;
    --color-amber: #ffa500;

    /* Dark Background Colors */
    --color-dark-bg: #0a0e27;
    --color-dark-secondary: #0f1729;
    --color-dark-card: #1a1f3a;

    /* Text Colors */
    --color-text-primary: #ffffff;
    --color-text-secondary: #b4bcd0;
    --color-text-muted: #6b7280;

    /* Gradients */
    --gradient-primary: linear-gradient(135deg, #00d4ff 0%, #0066ff 100%);
    --gradient-secondary: linear-gradient(135deg, #ffb800 0%, #ff006e 100%);
    --gradient-electric: linear-gradient(135deg, #00d4ff 0%, #ffb800 50%, #ff006e 100%);
    --gradient-pearl: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 25%, #ffffff 50%, #f1f3f5 75%, #e9ecef 100%);

    /* Shadows */
    --shadow-glow: 0 0 30px rgba(0, 212, 255, 0.3);
    --shadow-card: 0 10px 40px rgba(0, 0, 0, 0.4);
}

/* ===== Base Styles ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background-color: var(--color-dark-bg);
    color: var(--color-text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

/* ===== Advanced Background System ===== */
.glow-orbs {
    position: absolute;
    width: 100%;
    height: 100%;
    filter: blur(80px);
    opacity: 0.4;
}

.orb {
    position: absolute;
    border-radius: 50%;
    animation: orbFloat 20s infinite alternate cubic-bezier(0.4, 0, 0.2, 1);
}

.orb-1 {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--color-primary) 0%, transparent 70%);
    top: -10%;
    left: -10%;
    animation-duration: 25s;
}

.orb-2 {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, var(--color-electric-blue) 0%, transparent 70%);
    bottom: -10%;
    right: -10%;
    animation-duration: 30s;
    animation-delay: -5s;
}

.orb-3 {
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, var(--color-accent) 0%, transparent 70%);
    top: 40%;
    left: 40%;
    animation-duration: 20s;
    animation-delay: -3s;
}

@keyframes orbFloat {
    0% {
        transform: translate(0, 0) scale(1);
    }

    33% {
        transform: translate(50px, 100px) scale(1.1);
    }

    66% {
        transform: translate(-30px, 50px) scale(0.9);
    }

    100% {
        transform: translate(0, 0) scale(1);
    }
}

.cyber-grid {
    position: absolute;
    width: 200%;
    height: 200%;
    top: -50%;
    left: -50%;
    background-image:
        linear-gradient(to right, rgba(0, 212, 255, 0.05) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(0, 212, 255, 0.05) 1px, transparent 1px);
    background-size: 50px 50px;
    transform: perspective(1000px) rotateX(60deg);
    animation: gridFlow 40s linear infinite;
}

@keyframes gridFlow {
    0% {
        transform: perspective(1000px) rotateX(60deg) translateY(0);
    }

    100% {
        transform: perspective(1000px) rotateX(60deg) translateY(50px);
    }
}

.electric-beam {
    position: absolute;
    pointer-events: none;
    z-index: -1;
    opacity: 0.6;
}

@keyframes beamRunHorizontal {
    0% {
        left: -100px;
        opacity: 0;
    }

    10% {
        opacity: 0.6;
    }

    90% {
        opacity: 0.6;
    }

    100% {
        left: 110%;
        opacity: 0;
    }
}

@keyframes beamRunVertical {
    0% {
        top: -100px;
        opacity: 0;
    }

    10% {
        opacity: 0.6;
    }

    90% {
        opacity: 0.6;
    }

    100% {
        top: 110%;
        opacity: 0;
    }
}

.circuit-bg-overlay {
    position: absolute;
    inset: 0;
    opacity: 0.03;
    background-image: url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M10 10h80v80h-80z' fill='none' stroke='%2300d4ff' stroke-width='0.5'/%3E%3Ccircle cx='10' cy='10' r='2' fill='%2300d4ff'/%3E%3Ccircle cx='90' cy='10' r='2' fill='%2300d4ff'/%3E%3Ccircle cx='90' cy='90' r='2' fill='%2300d4ff'/%3E%3Ccircle cx='10' cy='90' r='2' fill='%2300d4ff'/%3E%3Cpath d='M10 50h20M80 50h20M50 10v20M50 80v20' stroke='%2300d4ff' stroke-width='0.5'/%3E%3C/svg%3E");
    background-size: 200px 200px;
}

/* Retain old .circuit-bg for specific section backgrounds if needed, but remove from body-level */
.circuit-bg {
    position: absolute;
    inset: 0;
    opacity: 0.05;
    background-image:
        repeating-linear-gradient(0deg, transparent, transparent 48px, rgba(0, 212, 255, 0.1) 49px, rgba(0, 212, 255, 0.1) 50px),
        repeating-linear-gradient(90deg, transparent, transparent 48px, rgba(0, 212, 255, 0.1) 49px, rgba(0, 212, 255, 0.1) 50px);
    background-size: 50px 50px;
    pointer-events: none;
}

/* ===== Navigation ===== */
.nav-glass {
    background: rgba(10, 14, 39, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 212, 255, 0.1);
    transition: all 0.3s ease;
}

/* ===== Brand Logo ===== */
.logo-container {
    text-decoration: none;
    display: flex;
    align-items: center;
}

.logo-box {
    position: relative;
    width: 45px;
    height: 45px;
    background: rgba(0, 212, 255, 0.1);
    border: 2px solid var(--color-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    clip-path: polygon(25% 0%, 100% 0%, 75% 100%, 0% 100%);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.logo-text {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 800;
    font-size: 1.4rem;
    color: white;
    z-index: 2;
    letter-spacing: -1px;
}

.logo-glow {
    position: absolute;
    inset: 0;
    background: var(--color-primary);
    opacity: 0;
    filter: blur(15px);
    transition: opacity 0.4s ease;
    z-index: 1;
}

.logo-container:hover .logo-box {
    transform: scale(1.1) skewX(-5deg);
    background: var(--color-primary);
    box-shadow: 0 0 20px var(--color-primary);
}

.logo-container:hover .logo-text {
    color: var(--color-dark-bg);
}

.logo-container:hover .logo-glow {
    opacity: 0.5;
}

.nav-link {
    color: var(--color-text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    position: relative;
    padding-bottom: 4px;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient-primary);
    transition: width 0.3s ease;
}

.nav-link:hover {
    color: var(--color-primary);
}

.nav-link:hover::after {
    width: 100%;
}

.nav-link.active {
    color: var(--color-primary);
}

.linkedin-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1.25rem;
    background: linear-gradient(135deg, #0077b5 0%, #005885 100%);
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 119, 181, 0.3);
}

.linkedin-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 119, 181, 0.5);
}

/* ===== Typography ===== */
.gradient-text {
    background: var(--gradient-electric);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-title {
    font-size: 3rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 4rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-title {
    font-size: clamp(2.5rem, 8vw, 5.5rem);
    background: var(--gradient-pearl);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 1.5rem;
    position: relative;
    z-index: 2;
    font-weight: 800;
    letter-spacing: -0.02em;
    text-shadow: 0 0 30px rgba(0, 212, 255, 0.2);
}

/* ===== Profile Image ===== */
.profile-img-container {
    position: relative;
    width: 200px;
    height: 200px;
    margin: 0 auto 2rem;
    z-index: 10;
}

.profile-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    border: 4px solid rgba(0, 212, 255, 0.3);
    box-shadow: 0 0 30px rgba(0, 212, 255, 0.4);
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.profile-img-container::before {
    content: '';
    position: absolute;
    top: -10px;
    left: -10px;
    right: -10px;
    bottom: -10px;
    border-radius: 50%;
    background: var(--gradient-primary);
    z-index: -1;
    opacity: 0.3;
    animation: pulse 6s infinite;
}

.profile-img-container:hover .profile-img {
    transform: scale(1.05) rotate(5deg);
    border-color: var(--color-primary);
    box-shadow: 0 0 50px rgba(0, 212, 255, 0.6);
}

.typing-animation {
    display: inline-block;
    overflow: hidden;
    white-space: nowrap;
    border-right: none;
    width: 0;
    max-width: fit-content;
    animation: typing 10s steps(40, end) infinite;
    vertical-align: bottom;
}

@keyframes typing {
    0% {
        width: 0;
    }

    20% {
        width: 100%;
    }

    /* Types in 2s (20% of 10s) */
    80% {
        width: 100%;
    }

    /* Holds for 6s */
    100% {
        width: 0;
    }

    /* Resets */
}

/* ===== Buttons ===== */
.btn-primary {
    display: inline-flex;
    align-items: center;
    padding: 1rem 2rem;
    background: var(--gradient-primary);
    color: white;
    text-decoration: none;
    border-radius: 12px;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(0, 212, 255, 0.4);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 30px rgba(0, 212, 255, 0.6);
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    padding: 1rem 2rem;
    background: transparent;
    color: var(--color-primary);
    text-decoration: none;
    border: 2px solid var(--color-primary);
    border-radius: 12px;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    background: var(--color-primary);
    color: var(--color-dark-bg);
    transform: translateY(-3px);
    box-shadow: 0 8px 30px rgba(0, 212, 255, 0.4);
}

/* ===== Cards ===== */
.card {
    background: var(--color-dark-card);
    border-radius: 16px;
    padding: 2rem;
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(0, 212, 255, 0.2);
    transition: all 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    border-color: rgba(0, 212, 255, 0.5);
    box-shadow: var(--shadow-card);
}

.card-glow {
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(0, 212, 255, 0.1) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.card:hover .card-glow {
    opacity: 1;
}

/* ===== Stats Cards ===== */
.stat-card {
    background: var(--color-dark-card);
    border-radius: 12px;
    padding: 1.25rem 1rem;
    text-align: center;
    border: 1px solid rgba(0, 212, 255, 0.2);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 140px;
}

.stat-card:hover {
    transform: translateY(-5px);
    border-color: var(--color-primary);
    box-shadow: 0 10px 30px rgba(0, 212, 255, 0.3);
}

.stat-icon {
    font-size: 1.75rem;
    margin-bottom: 0.5rem;
}

.stat-number {
    font-size: 1.8rem;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.25rem;
    line-height: 1.2;
}

.stat-text {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: 0.25rem;
    line-height: 1.2;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.stat-label {
    color: var(--color-text-secondary);
    font-size: 0.8rem;
    font-weight: 500;
}

/* ===== Skills Section ===== */
.skill-category {
    background: var(--color-dark-card);
    border-radius: 16px;
    padding: 2rem;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.skill-category::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg,
            #00d4ff,
            #0066ff,
            #ffb800,
            #ff006e,
            #00d4ff,
            #0066ff);
    background-size: 400% 400%;
    border-radius: 16px;
    z-index: -1;
    animation: electricBorder 8s linear infinite;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.skill-category::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--color-dark-card);
    border-radius: 16px;
    z-index: -1;
}

.skill-category:hover::before {
    opacity: 1;
}

.skill-category:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 40px rgba(0, 212, 255, 0.4);
}

@keyframes electricBorder {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

.skill-icon {
    font-size: 3rem;
    text-align: center;
    margin-bottom: 1rem;
}

.skill-item {
    margin-bottom: 1rem;
}

.skill-item span {
    display: block;
    color: var(--color-text-secondary);
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

.skill-bar {
    width: 100%;
    height: 8px;
    background: rgba(0, 212, 255, 0.1);
    border-radius: 10px;
    overflow: hidden;
}

.skill-progress {
    height: 100%;
    background: var(--gradient-primary);
    border-radius: 10px;
    transition: width 1s ease;
    box-shadow: 0 0 10px rgba(0, 212, 255, 0.5);
}

/* ===== Projects Section ===== */
.project-card {
    background: var(--color-dark-card);
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid rgba(0, 212, 255, 0.2);
    transition: all 0.3s ease;
}

.project-card:hover {
    transform: translateY(-10px);
    border-color: var(--color-primary);
    box-shadow: 0 15px 40px rgba(0, 212, 255, 0.4);
}

.project-image {
    width: 100%;
    height: 200px;
    background: linear-gradient(135deg, rgba(0, 212, 255, 0.2) 0%, rgba(255, 184, 0, 0.2) 100%);
    position: relative;
    overflow: hidden;
}

.project-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        repeating-linear-gradient(45deg, transparent, transparent 10px, rgba(0, 212, 255, 0.1) 10px, rgba(0, 212, 255, 0.1) 20px);
}

.project-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(10, 14, 39, 0.7);
    backdrop-filter: blur(5px);
}

.project-tag {
    padding: 0.5rem 1rem;
    background: var(--gradient-primary);
    color: white;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

.project-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    padding: 0.25rem 0.75rem;
    background: rgba(0, 212, 255, 0.2);
    border: 1px solid var(--color-primary);
    color: var(--color-primary);
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    z-index: 20;
    letter-spacing: 0.05em;
    backdrop-filter: blur(4px);
}

.tech-tag {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: rgba(255, 255, 255, 0.03);
    color: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(0, 212, 255, 0.2);
    border-radius: 4px;
    font-size: 0.85rem;
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(8px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    letter-spacing: -0.01em;
}

.tech-tag:hover {
    background: rgba(0, 212, 255, 0.1);
    border-color: #00d4ff;
    color: #00d4ff;
    box-shadow: 0 0 20px rgba(0, 212, 255, 0.3);
    transform: translateY(-2px) scale(1.02);
}

/* ===== Timeline ===== */
.timeline {
    position: relative;
    padding-left: 2rem;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--gradient-primary);
}

.timeline-item {
    position: relative;
    margin-bottom: 3rem;
    padding-left: 2rem;
}

.timeline-dot {
    position: absolute;
    left: -2rem;
    top: 0;
    width: 16px;
    height: 16px;
    background: var(--color-primary);
    border-radius: 50%;
    box-shadow: 0 0 20px rgba(0, 212, 255, 0.8);
    animation: pulse 2s infinite;
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.2);
    }
}

.timeline-content {
    background: var(--color-dark-card);
    border-radius: 12px;
    padding: 2rem;
    border: 1px solid rgba(0, 212, 255, 0.2);
    transition: all 0.3s ease;
}

.timeline-content:hover {
    transform: translateX(10px);
    border-color: var(--color-primary);
    box-shadow: 0 10px 30px rgba(0, 212, 255, 0.3);
}

.timeline-date {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: rgba(0, 212, 255, 0.1);
    color: var(--color-primary);
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

/* ===== Contact Section ===== */
.contact-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    background: var(--color-dark-card);
    color: var(--color-primary);
    text-decoration: none;
    border: 2px solid var(--color-primary);
    border-radius: 12px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.contact-btn:hover {
    background: var(--color-primary);
    color: var(--color-dark-bg);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 212, 255, 0.5);
}

/* ===== Circuit Nodes Animation ===== */
.circuit-node {
    position: absolute;
    border: 2px solid var(--color-primary);
    border-radius: 4px;
    animation: float 3s ease-in-out infinite;
    opacity: 0.3;
}

.circuit-node::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 50%;
    height: 50%;
    background: var(--color-primary);
    border-radius: 2px;
    box-shadow: 0 0 20px var(--color-primary);
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-20px);
    }
}

/* ===== Sections ===== */
.section-padding {
    padding: 6rem 0;
}

.bg-dark-secondary {
    background-color: var(--color-dark-secondary);
}

/* ===== Animations ===== */
.reveal-up {
    opacity: 0;
    animation: revealUp 0.8s ease forwards;
}

.reveal-left {
    opacity: 0;
    animation: revealLeft 0.8s ease forwards;
}

.reveal-right {
    opacity: 0;
    animation: revealRight 0.8s ease forwards;
}

@keyframes revealUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes revealLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes revealRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.hero-content {
    animation: fadeInScale 1s ease;
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.9);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* ===== Hobbies Section ===== */
.hobby-card {
    background: var(--color-dark-card);
    padding: 2.5rem 2rem;
    border-radius: 20px;
    border: 1px solid rgba(0, 212, 255, 0.1);
    text-align: center;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.hobby-card:hover {
    transform: translateY(-10px);
    border-color: var(--color-primary);
    box-shadow: 0 20px 40px rgba(0, 212, 255, 0.15);
}

.hobby-icon-wrapper {
    width: 60px;
    height: 60px;
    background: rgba(0, 212, 255, 0.1);
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 2rem;
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 212, 255, 0.2);
}

.hobby-card:hover .hobby-icon-wrapper {
    background: var(--color-primary);
    transform: rotate(10deg);
    box-shadow: 0 0 20px rgba(0, 212, 255, 0.4);
}

.hobby-card:hover .hobby-icon {
    filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.5));
}

/* ===== Responsive Design ===== */
@media (max-width: 768px) {
    .section-title {
        font-size: 2rem;
    }

    .section-padding {
        padding: 4rem 0;
    }

    .timeline {
        padding-left: 1.5rem;
    }

    .timeline-item {
        padding-left: 1.5rem;
    }

    .timeline-dot {
        left: -1.6rem;
    }
}

/* ===== Scrollbar Styling ===== */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--color-dark-bg);
}

::-webkit-scrollbar-thumb {
    background: var(--gradient-primary);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--color-primary);
}