@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;600;800&display=swap');

:root {
    --bg-primary: #0f172a;
    --accent: #38bdf8;
    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
    --card-bg: rgba(30, 41, 59, 0.7);
    /* Transparent for glassmorphism */
    --border: rgba(51, 65, 85, 0.5);
    --timeline-line: #334155;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-primary);
    color: var(--text-primary);
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    position: relative;
    /* Canvas handles background now */
}

/* Canvas Background */
#bg-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

/* Scroll Progress Bar */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    background: var(--accent);
    z-index: 1001;
    transition: width 0.1s;
}

a {
    text-decoration: none;
    color: inherit;
    transition: 0.3s;
}

ul {
    list-style: none;
}

/* Utility Classes */
.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 2rem;
}

.section-title {
    font-size: 2rem;
    margin-bottom: 3rem;
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: var(--accent);
    margin-top: 10px;
    border-radius: 2px;
}

section {
    padding: 5rem 0;
}

/* Header/Nav */
header {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(15px);
    /* Stronger blur */
    z-index: 1000;
    border-bottom: 1px solid var(--border);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.logo {
    font-weight: 800;
    font-size: 1.2rem;
    color: var(--text-primary);
    letter-spacing: 1px;
}

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-links a:hover {
    color: var(--accent);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: 70px;
}

.hero-content {
    max-width: 800px;
}

.hero h2 {
    color: var(--accent);
    font-size: 1.2rem;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.hero h1 {
    font-size: 4.5rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    background: -webkit-linear-gradient(45deg, #fff, #94a3b8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero p {
    font-size: 1.3rem;
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
    max-width: 650px;
}

.personal-info {
    margin-bottom: 2rem;
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.info-pill {
    background: rgba(56, 189, 248, 0.1);
    border: 1px solid rgba(56, 189, 248, 0.3);
    color: var(--accent);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.btn {
    display: inline-block;
    padding: 0.8rem 2rem;
    border-radius: 0.5rem;
    font-weight: 600;
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary {
    background: var(--accent);
    color: #0f172a;
    box-shadow: 0 0 20px rgba(56, 189, 248, 0.3);
}

.btn-primary:hover {
    background: #7dd3fc;
    box-shadow: 0 0 30px rgba(56, 189, 248, 0.5);
}

.btn-secondary {
    border: 2px solid var(--text-primary);
    margin-left: 1rem;
    background: transparent;
    color: var(--text-primary);
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    background: var(--text-primary);
    color: var(--bg-primary);
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
}

/* About / Extracto */
.about-card {
    background: var(--card-bg);
    padding: 3rem;
    border-radius: 1rem;
    border: 1px solid var(--border);
    backdrop-filter: blur(5px);
    font-size: 1.1rem;
}

/* Experience Timeline */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 2px;
    background: var(--timeline-line);
}

.timeline-item {
    margin-bottom: 4rem;
    padding-left: 3rem;
    position: relative;
}

.timeline-dot {
    position: absolute;
    left: -5px;
    top: 5px;
    width: 12px;
    height: 12px;
    background: var(--bg-primary);
    border: 2px solid var(--accent);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--accent);
}

.job-header h3 {
    font-size: 1.6rem;
    color: var(--text-primary);
    margin-bottom: 5px;
}

.job-header span {
    color: var(--accent);
    font-weight: 600;
    font-size: 1.1rem;
}

.job-date {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
    display: block;
    font-style: italic;
}

.achievements {
    list-style: disc;
    margin: 1rem 0 1.5rem 1.5rem;
    color: #cbd5e1;
}

.achievements li {
    margin-bottom: 0.5rem;
}

.job-tags {
    margin-top: 1rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
}

.tag {
    background: rgba(56, 189, 248, 0.08);
    color: var(--accent);
    padding: 0.3rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    border: 1px solid rgba(56, 189, 248, 0.2);
}

/* Skills Grid */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1.5rem;
}

.skill-card {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 0.8rem;
    border: 1px solid var(--border);
    backdrop-filter: blur(5px);
    transition: transform 0.2s, border-color 0.2s;
}

.skill-card:hover {
    transform: translateY(-5px);
    border-color: var(--accent);
}

.skill-card h4 {
    margin-bottom: 0.8rem;
    font-size: 1.2rem;
}

.skill-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* Contact Format */
.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.contact-item {
    background: var(--card-bg);
    padding: 2.5rem;
    border-radius: 1rem;
    text-align: center;
    border: 1px solid var(--border);
    backdrop-filter: blur(5px);
}

/* Animations */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 3rem;
    }

    .nav-links {
        display: none;
    }

    .timeline::before {
        left: 20px;
    }

    .timeline-item {
        padding-left: 3rem;
    }

    .timeline-dot {
        left: 15px;
    }

    .btn {
        width: 100%;
        margin: 1rem 0 0 0;
        text-align: center;
    }

    .btn-secondary {
        margin-left: 0;
    }
}

/* PRINT STYLES */
@media print {

    .no-print,
    header,
    canvas,
    .scroll-progress {
        display: none !important;
    }

    body {
        background-color: #fff !important;
        color: #000 !important;
        font-size: 12pt;
    }

    .container {
        max-width: 100%;
        padding: 0;
        margin: 0;
    }

    .hero {
        min-height: auto;
        padding-top: 0;
        display: block;
        border-bottom: 2px solid #000;
        padding-bottom: 2rem;
        margin-bottom: 2rem;
    }

    .hero h1 {
        font-size: 28pt;
        color: #000;
        background: none;
        -webkit-text-fill-color: #000;
        margin-bottom: 0.5rem;
    }

    .hero h2 {
        color: #444;
        font-size: 14pt;
        margin-bottom: 0;
    }

    .hero p {
        color: #000;
        font-size: 11pt;
        max-width: 100%;
    }

    section {
        padding: 1rem 0;
        page-break-inside: avoid;
    }

    .section-title {
        font-size: 16pt;
        margin-bottom: 1rem;
        border-bottom: 1px solid #ccc;
        display: block;
        width: 100%;
    }

    .section-title::after {
        display: none;
    }

    .timeline::before {
        display: none;
    }

    .timeline-item {
        padding-left: 0;
        margin-bottom: 2rem;
    }

    .timeline-dot {
        display: none;
    }

    .about-card,
    .skill-card,
    .contact-item {
        background: none;
        border: none;
        padding: 0;
        backdrop-filter: none;
    }

    .job-tags {
        display: none;
    }

    /* Simplified for print */

    .achievements {
        color: #000;
        margin-left: 1.5rem;
    }

    a {
        text-decoration: none;
        color: #000;
    }

    /* Ensure links are readable */
    a[href]::after {
        content: " (" attr(href) ")";
        font-size: 0.8rem;
    }
}