/* ========================================
   Bruno Sanches - Modern Portfolio
   ======================================== */

:root {
    --primary: #6366f1;
    --primary-light: #818cf8;
    --primary-dark: #4f46e5;
    --bg: #0f0f13;
    --bg-alt: #16161d;
    --bg-card: #1c1c27;
    --bg-card-hover: #22222f;
    --text: #e4e4e7;
    --text-muted: #a1a1aa;
    --text-dim: #71717a;
    --border: #27272a;
    --gradient: linear-gradient(135deg, var(--primary), #a855f7);
    --radius: 12px;
    --radius-sm: 8px;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ========================================
   Navbar
   ======================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(15, 15, 19, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid transparent;
    transition: var(--transition);
}

.navbar.scrolled {
    border-bottom-color: var(--border);
}

.nav-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 72px;
}

.nav-logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text);
    text-decoration: none;
    letter-spacing: -0.5px;
}

.nav-logo .dot {
    color: var(--primary);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 8px;
}

.nav-link {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    padding: 8px 16px;
    border-radius: 8px;
    transition: var(--transition);
}

.nav-link:hover,
.nav-link.active {
    color: var(--text);
    background: rgba(99, 102, 241, 0.1);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
}

.nav-toggle span {
    width: 24px;
    height: 2px;
    background: var(--text);
    border-radius: 2px;
    transition: var(--transition);
}

/* ========================================
   Hero Section
   ======================================== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    padding: 120px 24px 80px;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.08) 0%, transparent 70%);
    pointer-events: none;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -10%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(168, 85, 247, 0.06) 0%, transparent 70%);
    pointer-events: none;
}

.hero-content {
    max-width: 1100px;
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.hero-greeting {
    font-size: 1rem;
    font-weight: 500;
    color: var(--primary-light);
    margin-bottom: 12px;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.hero-name {
    font-size: clamp(2.5rem, 5vw, 3.75rem);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -1.5px;
    margin-bottom: 16px;
}

.highlight {
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-role {
    font-size: 1.125rem;
    color: var(--text-muted);
    font-weight: 500;
    margin-bottom: 20px;
}

.hero-description {
    color: var(--text-dim);
    font-size: 0.95rem;
    max-width: 480px;
    margin-bottom: 32px;
}

.hero-actions {
    display: flex;
    gap: 16px;
    margin-bottom: 40px;
}

.btn {
    display: inline-flex;
    align-items: center;
    padding: 12px 28px;
    border-radius: 10px;
    font-size: 0.875rem;
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition);
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: var(--gradient);
    color: white;
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 30px rgba(99, 102, 241, 0.4);
}

.btn-outline {
    background: transparent;
    color: var(--text);
    border: 1px solid var(--border);
}

.btn-outline:hover {
    border-color: var(--primary);
    color: var(--primary-light);
}

.hero-social {
    display: flex;
    gap: 16px;
}

.hero-social a {
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    background: var(--bg-card);
    color: var(--text-muted);
    text-decoration: none;
    font-size: 1rem;
    transition: var(--transition);
    border: 1px solid var(--border);
}

.hero-social a:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    transform: translateY(-2px);
}

.hero-image {
    display: flex;
    justify-content: center;
}

.hero-image-wrapper {
    width: 360px;
    height: 360px;
    border-radius: 50%;
    overflow: hidden;
    border: 3px solid var(--border);
    position: relative;
    box-shadow: 0 0 60px rgba(99, 102, 241, 0.15);
}

.hero-image-wrapper::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), transparent);
}

.hero-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: var(--text-dim);
    font-size: 0.75rem;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.scroll-line {
    width: 1px;
    height: 40px;
    background: var(--border);
    position: relative;
    overflow: hidden;
}

.scroll-line::after {
    content: '';
    position: absolute;
    top: -100%;
    left: 0;
    width: 100%;
    height: 50%;
    background: var(--primary);
    animation: scrollDown 1.5s ease-in-out infinite;
}

@keyframes scrollDown {
    0% { top: -50%; }
    100% { top: 100%; }
}

/* ========================================
   Sections
   ======================================== */
.section {
    padding: 100px 0;
}

.section-alt {
    background: var(--bg-alt);
}

.section-title {
    font-size: 2rem;
    font-weight: 700;
    letter-spacing: -0.5px;
    margin-bottom: 60px;
    text-align: center;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 40px;
    height: 3px;
    background: var(--gradient);
    border-radius: 2px;
    margin: 16px auto 0;
}

/* ========================================
   About Section
   ======================================== */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    align-items: start;
}

.info-cards {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.info-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    background: var(--bg-card);
    border-radius: var(--radius);
    border: 1px solid var(--border);
    transition: var(--transition);
}

.info-card:hover {
    border-color: var(--primary);
    transform: translateX(4px);
}

.info-card i {
    font-size: 1.1rem;
    color: var(--primary-light);
    width: 20px;
    text-align: center;
}

.info-label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 2px;
}

.info-value {
    font-size: 0.9rem;
    font-weight: 500;
}

.about-values h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 24px;
}

.values-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 20px;
}

.tag {
    padding: 8px 20px;
    background: rgba(99, 102, 241, 0.1);
    color: var(--primary-light);
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 500;
    border: 1px solid rgba(99, 102, 241, 0.2);
    transition: var(--transition);
}

.tag:hover {
    background: rgba(99, 102, 241, 0.2);
    transform: translateY(-2px);
}

.values-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-bottom: 20px;
}

.value-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 20px 12px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    transition: var(--transition);
}

.value-card:hover {
    border-color: var(--primary);
    transform: translateY(-4px);
    box-shadow: 0 8px 30px rgba(99, 102, 241, 0.15);
}

.value-card i {
    font-size: 1.4rem;
    color: var(--primary-light);
}

.value-card span {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text);
    text-align: center;
}

.values-note {
    color: var(--text-dim);
    font-size: 0.9rem;
    font-style: italic;
}

.values-note i {
    color: #ef4444;
}

/* ========================================
   Skills Section
   ======================================== */
.skills-category {
    margin-bottom: 60px;
}

.skills-category:last-child {
    margin-bottom: 0;
}

.skills-subtitle {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 28px;
    text-align: center;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.skills-grid-small {
    grid-template-columns: repeat(3, 1fr);
    max-width: 800px;
    margin: 0 auto;
}

.skill-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    text-align: center;
    transition: var(--transition);
}

.skill-card:hover {
    border-color: var(--primary);
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
}

.skill-icon {
    font-size: 2rem;
    color: var(--primary-light);
    margin-bottom: 12px;
}

.skill-card h4 {
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.skill-card p {
    font-size: 0.75rem;
    color: var(--text-dim);
    line-height: 1.5;
    margin-bottom: 16px;
}

.skill-bar {
    width: 100%;
    height: 4px;
    background: var(--border);
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: 8px;
}

.skill-fill {
    height: 100%;
    width: 0;
    background: var(--gradient);
    border-radius: 2px;
    transition: width 1s ease-out;
}

.skill-fill.animated {
    width: var(--skill-level);
}

.skill-percent {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--primary-light);
    font-family: 'JetBrains Mono', monospace;
}

.skill-card-mini {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    text-align: center;
    transition: var(--transition);
}

.skill-card-mini:hover {
    border-color: var(--primary);
    transform: translateY(-4px);
}

.skill-card-mini i {
    font-size: 1.5rem;
    color: var(--primary-light);
    margin-bottom: 12px;
    display: block;
}

.skill-card-mini h4 {
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 16px;
}

/* ========================================
   Timeline (Education & Experience)
   ======================================== */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--border);
}

.timeline-item {
    position: relative;
    padding-left: 40px;
    padding-bottom: 40px;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.timeline-item.visible {
    opacity: 1;
    transform: translateY(0);
}

.timeline-item:last-child {
    padding-bottom: 0;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -5px;
    top: 6px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--bg);
    border: 2px solid var(--primary);
}

.timeline-date {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--primary-light);
    font-family: 'JetBrains Mono', monospace;
    margin-bottom: 8px;
}

.timeline-content {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    transition: var(--transition);
}

.timeline-content:hover {
    border-color: rgba(99, 102, 241, 0.3);
}

.timeline-content h4 {
    font-size: 1.05rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.timeline-badge {
    display: inline-block;
    padding: 3px 12px;
    background: rgba(99, 102, 241, 0.1);
    color: var(--primary-light);
    border-radius: 50px;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.timeline-badge-active {
    background: rgba(34, 197, 94, 0.15);
    color: #4ade80;
}

.timeline-subtitle {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.timeline-content p {
    font-size: 0.85rem;
    color: var(--text-dim);
}

.timeline-list {
    list-style: none;
    margin-top: 8px;
}

.timeline-list li {
    font-size: 0.85rem;
    color: var(--text-dim);
    padding: 3px 0;
    padding-left: 16px;
    position: relative;
}

.timeline-list li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 12px;
    width: 6px;
    height: 1px;
    background: var(--primary);
}

/* ========================================
   Contact Section
   ======================================== */
.contact-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-bottom: 48px;
}

.contact-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 32px;
    text-align: center;
    transition: var(--transition);
}

.contact-card:hover {
    border-color: var(--primary);
    transform: translateY(-4px);
}

.contact-icon {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(99, 102, 241, 0.1);
    border-radius: 14px;
    margin: 0 auto 16px;
    font-size: 1.25rem;
    color: var(--primary-light);
}

.contact-card h4 {
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.contact-card p {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.contact-card a {
    color: var(--primary-light);
    text-decoration: none;
    transition: var(--transition);
}

.contact-card a:hover {
    color: var(--text);
}

.contact-social {
    display: flex;
    justify-content: center;
    gap: 16px;
}

.contact-social a {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: var(--bg-card);
    color: var(--text-muted);
    text-decoration: none;
    font-size: 1.1rem;
    border: 1px solid var(--border);
    transition: var(--transition);
}

.contact-social a:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    transform: translateY(-3px);
}

/* ========================================
   Footer
   ======================================== */
.footer {
    padding: 40px 0;
    border-top: 1px solid var(--border);
    text-align: center;
}

.footer-text {
    font-size: 1rem;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.heart {
    color: var(--primary-light);
}

.footer-copyright {
    font-size: 0.75rem;
    color: var(--text-dim);
}

/* ========================================
   Animations
   ======================================== */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ========================================
   Responsive
   ======================================== */
@media (max-width: 1024px) {
    .skills-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .nav-toggle {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        top: 72px;
        left: 0;
        right: 0;
        background: var(--bg);
        border-bottom: 1px solid var(--border);
        flex-direction: column;
        padding: 16px 24px;
        transform: translateY(-100%);
        opacity: 0;
        pointer-events: none;
        transition: var(--transition);
    }

    .nav-menu.open {
        transform: translateY(0);
        opacity: 1;
        pointer-events: all;
    }

    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 40px;
    }

    .hero-text {
        order: 2;
    }

    .hero-image {
        order: 1;
    }

    .hero-image-wrapper {
        width: 240px;
        height: 240px;
    }

    .hero-description {
        margin-left: auto;
        margin-right: auto;
    }

    .hero-actions {
        justify-content: center;
    }

    .hero-social {
        justify-content: center;
    }

    .about-grid {
        grid-template-columns: 1fr;
    }

    .skills-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .skills-grid-small {
        grid-template-columns: repeat(2, 1fr);
    }

    .values-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .contact-grid {
        grid-template-columns: 1fr;
        max-width: 400px;
        margin: 0 auto 48px;
    }

    .timeline::before {
        left: 0;
    }

    .section {
        padding: 70px 0;
    }

    .section-title {
        font-size: 1.75rem;
        margin-bottom: 40px;
    }
}

@media (max-width: 480px) {
    .skills-grid {
        grid-template-columns: 1fr;
    }

    .skills-grid-small {
        grid-template-columns: 1fr;
    }

    .hero-name {
        font-size: 2rem;
    }

    .hero-actions {
        flex-direction: column;
        align-items: center;
    }
}
