:root {
    --bg-color: #050505;
    --card-bg: #0a0a0a;
    --text-main: #e0e0e0;
    --text-muted: #a0a0a0;
    --neon-pink: #ff00ff;
    --neon-cyan: #00ffff;
    --neon-green: #00ff88;
    --border-radius: 12px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    display: flex;
    justify-content: center;
    padding: 40px 20px;
    position: relative;
    /* Context for absolute canvas */
}

#particles-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
    opacity: 0.4;
    /* Subtle backdrop */
}

/* Tooltips */
.tooltip {
    position: relative;
    cursor: pointer;
}

.tooltip::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: var(--neon-cyan);
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 0.8rem;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s;
    border: 1px solid var(--neon-cyan);
}

.tooltip:hover::after {
    opacity: 1;
}

.resume-container {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 40px;
    max-width: 1000px;
    width: 100%;
    /* Subtle glow around the document for web view */
    box-shadow: 0 0 100px rgba(0, 255, 255, 0.05);
}

/* --- SIDEBAR --- */
.sidebar {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.profile-section {
    text-align: center;
}

.pfp-container {
    position: relative;
    width: 150px;
    height: 150px;
    margin: 0 auto 20px;
}

.pfp {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--neon-cyan);
    position: relative;
    z-index: 2;
}

.glitch-border {
    position: absolute;
    top: -5px;
    left: -5px;
    right: -5px;
    bottom: -5px;
    border-radius: 50%;
    background: linear-gradient(45deg, var(--neon-pink), var(--neon-cyan), var(--neon-green));
    z-index: 1;
    filter: blur(10px);
    opacity: 0.7;
    animation: spin 4s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

.name {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1;
    margin-bottom: 5px;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: -1px;
    position: relative;
}

.role {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 1.1rem;
    color: var(--neon-cyan);
    margin-bottom: 20px;
    font-weight: 500;
}

.tagline {
    font-size: 0.95rem;
    color: var(--text-muted);
    font-style: italic;
    border-left: 2px solid var(--neon-pink);
    padding-left: 15px;
    text-align: left;
}

.contact-section {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 0.95rem;
    color: var(--text-muted);
}

.contact-item i {
    color: var(--neon-green);
    width: 20px;
    text-align: center;
}

.btn-neon {
    margin-top: 10px;
    background: transparent;
    border: 1px solid var(--neon-cyan);
    color: var(--neon-cyan);
    padding: 10px 20px;
    font-family: 'Space Grotesk', sans-serif;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-neon:hover {
    background: var(--neon-cyan);
    color: #000;
    box-shadow: 0 0 20px var(--neon-cyan);
}

/* --- MAIN CONTENT --- */
.main-content {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    padding: 40px;
    border: 1px solid #1a1a1a;
}

.section-title {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 1.8rem;
    color: #fff;
    margin-bottom: 30px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.section-title::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(to right, var(--neon-pink), transparent);
}

.timeline {
    border-left: 2px solid #222;
    padding-left: 30px;
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.job-card {
    position: relative;
    background: rgba(255, 255, 255, 0.02);
    padding: 20px;
    border-radius: 12px;
    border: 1px solid #1a1a1a;
    transition: all 0.3s ease;
}

.job-card:hover {
    transform: scale(1.02) translateX(5px);
    border-color: var(--neon-cyan);
    box-shadow: -5px 5px 20px rgba(0, 255, 255, 0.1);
}

.job-header {
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.company-logo {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    object-fit: cover;
    background: #000;
    border: 1px solid #333;
    padding: 2px;
}

.job-card::before {
    content: '';
    position: absolute;
    left: -48px;
    /* Adjusted for padding */
    top: 25px;
    width: 12px;
    height: 12px;
    background: var(--neon-cyan);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--neon-cyan);
    z-index: 10;
}

/* Animations */
.hidden {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease-out;
}

.show {
    opacity: 1;
    transform: translateY(0);
}

.job-title {
    font-size: 1.2rem;
    color: #fff;
    font-weight: 600;
}

.company {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 0.9rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.company.neon-pink {
    color: var(--neon-pink);
}

.company.neon-cyan {
    color: var(--neon-cyan);
}

.achievements {
    list-style: none;
    color: var(--text-muted);
}

.achievements li {
    margin-bottom: 8px;
    position: relative;
    padding-left: 15px;
}

.achievements li::before {
    content: '>';
    position: absolute;
    left: 0;
    color: var(--neon-green);
    font-weight: bold;
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.skill-tags span {
    background: #111;
    border: 1px solid #333;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    color: var(--text-main);
    transition: 0.3s;
}

.skill-tags span:hover {
    border-color: var(--neon-pink);
    color: var(--neon-pink);
}

/* --- PRELOADER --- */
#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    transition: opacity 0.5s ease-out;
}

.loader-content {
    text-align: center;
}

.glitch-loader {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 3rem;
    font-weight: bold;
    color: #fff;
    position: relative;
    margin-bottom: 20px;
    animation: twitch 3s infinite;
}

.glitch-loader::before,
.glitch-loader::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    background: #000;
}

.glitch-loader::before {
    left: 2px;
    text-shadow: -1px 0 var(--neon-pink);
    clip: rect(24px, 550px, 90px, 0);
    animation: glitch-anim-2 2.5s infinite linear alternate-reverse;
}

.glitch-loader::after {
    left: -2px;
    text-shadow: -1px 0 var(--neon-cyan);
    clip: rect(85px, 550px, 140px, 0);
    animation: glitch-anim 2s infinite linear alternate-reverse;
}

.loader-bar {
    width: 200px;
    height: 4px;
    background: #222;
    border-radius: 2px;
    overflow: hidden;
    margin: 0 auto;
}

.loader-progress {
    width: 0%;
    height: 100%;
    background: var(--neon-cyan);
    box-shadow: 0 0 10px var(--neon-cyan);
    animation: load 2s ease-in-out forwards;
}

@keyframes load {
    0% {
        width: 0%;
    }

    50% {
        width: 70%;
    }

    100% {
        width: 100%;
    }
}

@keyframes twitch {

    0%,
    100% {
        transform: skew(0deg);
    }

    20% {
        transform: skew(-2deg);
    }

    40% {
        transform: skew(2deg);
    }
}

/* --- WELCOME STRIP --- */
.welcome-strip {
    margin-top: 40px;
    /* Consistent spacing */
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    padding: 25px;
    text-align: center;
    position: relative;
    overflow: visible;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.mascot-container {
    position: relative;
    width: 120px;
    height: 120px;
    margin: -60px auto 10px;
    /* Pull it up to overlap the top */
}

.mascot-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    animation: float 4s ease-in-out infinite;
    filter: drop-shadow(0 10px 15px rgba(0, 255, 255, 0.2));
}

@keyframes float {
    0% {
        transform: translateY(0px) rotate(0deg);
    }

    50% {
        transform: translateY(-10px) rotate(2deg);
    }

    100% {
        transform: translateY(0px) rotate(0deg);
    }
}

.speech-bubble {
    position: absolute;
    top: 0;
    right: -20px;
    background: #fff;
    color: #000;
    padding: 8px 15px;
    border-radius: 15px;
    border-bottom-left-radius: 2px;
    font-size: 0.85rem;
    font-weight: bold;
    font-family: 'Space Grotesk', sans-serif;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    animation: popIn 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) 1s forwards;
    /* Delayed start */
    opacity: 0;
    transform: scale(0);
}

@keyframes popIn {
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.welcome-text h3 {
    margin: 5px 0;
    font-size: 1.1rem;
    color: #fff;
    font-family: 'Space Grotesk', sans-serif;
}

.welcome-text p {
    font-size: 0.9rem;
    color: var(--text-muted);
    line-height: 1.4;
    margin: 0;
}

/* --- PRINT / PDF STYLES --- */
@media print {
    * {
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }

    body {
        background-color: var(--bg-color) !important;
        /* Force Black */
        color: var(--text-main) !important;
        margin: 0;
        padding: 0;
    }

    .resume-container {
        display: grid;
        grid-template-columns: 280px 1fr;
        gap: 30px;
        box-shadow: none;
        width: 100%;
        max-width: none;
        border: none;
    }

    .sidebar {
        background: transparent !important;
        height: auto;
    }

    .main-content {
        background: var(--card-bg) !important;
        border: 1px solid #333 !important;
        color: var(--text-main) !important;
    }

    /* Hide interactive elements */
    #download-pdf,
    .btn-neon {
        display: none !important;
    }

    /* Ensure text visibility */
    .name,
    .role,
    .company,
    .achievements li {
        color: var(--text-main) !important;
        /* Keep it light on dark */
    }

    .company.neon-pink {
        color: var(--neon-pink) !important;
    }

    .company.neon-cyan {
        color: var(--neon-cyan) !important;
    }

    /* Keep the glitch border visual for the PDF 'vibe' */
    .glitch-border {
        display: block !important;
        opacity: 1 !important;
        filter: none !important;
    }

    /* Adjust page margins for PDF */
    @page {
        margin: 0;
        size: auto;
    }
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .resume-container {
        grid-template-columns: 1fr;
    }

    .sidebar {
        border-bottom: 1px solid #222;
        padding-bottom: 40px;
    }
}