:root {
    --bg: #030305;
    --surface: #0a0a0c;
    --surface-elevated: #121218;
    --border: rgba(255, 255, 255, 0.06);
    --text: #f1f1f4;
    --text-muted: #6b6b7c;
    --accent: #00f0ff;
    --accent-dim: rgba(0, 240, 255, 0.08);
    --accent-glow: rgba(0, 240, 255, 0.4);
    --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
    --font-mono: "SF Mono", "Monaco", "Inconsolata", monospace;
}

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

body {
    background-color: var(--bg);
    color: var(--text);
    font-family: var(--font-sans);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

.spotlight {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    background: radial-gradient(600px circle at var(--x, 50%) var(--y, 50%),
            rgba(0, 240, 255, 0.06),
            transparent 40%);
    z-index: 0;
}

body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 60px 60px;
    z-index: 0;
    pointer-events: none;
}

nav {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 1.5rem 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 100;
    background: linear-gradient(to bottom, var(--bg) 50%, transparent);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid transparent;
    transition: border-color 0.3s;
}

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

.logo {
    font-family: var(--font-mono);
    font-weight: 700;
    font-size: 1.1rem;
    background: linear-gradient(135deg, var(--text) 0%, var(--accent) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-decoration: none;
    position: relative;
    letter-spacing: -0.5px;
    z-index: 102;
}

.nav-links {
    display: flex;
    gap: 2.5rem;
    list-style: none;
}

.nav-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.85rem;
    font-family: var(--font-mono);
    transition: all 0.2s;
    position: relative;
    font-weight: 500;
}

.nav-links a:hover {
    color: var(--accent);
}

.nav-links a::before {
    content: "0" counter(item) ".";
    color: var(--accent);
    margin-right: 0.3rem;
    font-size: 0.75rem;
    opacity: 0.7;
}

.nav-links li {
    counter-increment: item;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: var(--text);
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 102;
    position: relative;
    width: 40px;
    height: 40px;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    transition: all 0.3s;
}

.mobile-menu-btn:hover {
    background: var(--surface-elevated);
}

.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(3, 3, 5, 0.95);
    backdrop-filter: blur(20px);
    z-index: 101;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

.mobile-menu-overlay.active {
    opacity: 1;
    pointer-events: all;
}

.mobile-nav-links {
    list-style: none;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.mobile-nav-links a {
    color: var(--text);
    text-decoration: none;
    font-family: var(--font-mono);
    font-size: 1.5rem;
    display: block;
    padding: 1rem;
    transition: all 0.3s;
    position: relative;
}

.mobile-nav-links a::before {
    content: "0" counter(item) ".";
    color: var(--accent);
    margin-right: 0.5rem;
    font-size: 0.9rem;
    opacity: 0.7;
}

.mobile-nav-links li {
    counter-increment: item;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease;
}

.mobile-menu-overlay.active .mobile-nav-links li {
    opacity: 1;
    transform: translateY(0);
}

.mobile-menu-overlay.active .mobile-nav-links li:nth-child(1) {
    transition-delay: 0.1s;
}

.mobile-menu-overlay.active .mobile-nav-links li:nth-child(2) {
    transition-delay: 0.2s;
}

.mobile-menu-overlay.active .mobile-nav-links li:nth-child(3) {
    transition-delay: 0.3s;
}
.mobile-menu-overlay.active .mobile-nav-links li:nth-child(4) {
    transition-delay: 0.4s;
}

.mobile-nav-links a:hover {
    color: var(--accent);
    transform: scale(1.05);
}

main {
    position: relative;
    z-index: 2;
}

section {
    padding: 6rem 5%;
    max-width: 1200px;
    margin: 0 auto;
}

.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    width: 100%;
}

.hero-text {
    position: relative;
    z-index: 2;
}

.hero-intro {
    font-family: var(--font-mono);
    color: var(--accent);
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
    opacity: 0;
    animation: fadeInUp 0.8s 0.2s forwards;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.hero-intro::before {
    content: "";
    display: inline-block;
    width: 40px;
    height: 1px;
    background: var(--accent);
    animation: expandLine 1s 1s forwards;
    transform: scaleX(0);
    transform-origin: left;
}

@keyframes expandLine {
    to {
        transform: scaleX(1);
    }
}

.hero h1 {
    font-size: clamp(3rem, 6vw, 5.5rem);
    font-weight: 800;
    line-height: 1.05;
    margin-bottom: 1.5rem;
    letter-spacing: -3px;
    opacity: 0;
    animation: fadeInUp 0.8s 0.4s forwards;
}

.hero h1 .name {
    display: block;
    background: linear-gradient(135deg, #fff 0%, #888 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero h1 .role {
    display: block;
    color: var(--text-muted);
    font-size: 0.6em;
    margin-top: 0.5rem;
    font-weight: 500;
    letter-spacing: -1px;
}

.hero-description {
    max-width: 540px;
    color: var(--text-muted);
    font-size: 1.25rem;
    line-height: 1.7;
    margin-bottom: 2.5rem;
    opacity: 0;
    min-height: 3.5em;
}

.cursor {
    display: inline-block;
    width: 3px;
    height: 1.2em;
    background: var(--accent);
    margin-left: 0.2rem;
    animation: blink 1s infinite;
    vertical-align: middle;
}

@keyframes blink {

    0%,
    50% {
        opacity: 1;
    }

    51%,
    100% {
        opacity: 0;
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-cta {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--bg);
    background: var(--accent);
    font-family: var(--font-mono);
    font-size: 0.9rem;
    text-decoration: none;
    padding: 1rem 2rem;
    border-radius: 4px;
    font-weight: 600;
    transition: all 0.3s;
    opacity: 0;
    animation: fadeInUp 0.8s 1.2s forwards;
    box-shadow: 0 0 20px rgba(0, 240, 255, 0.2);
    position: relative;
    overflow: hidden;
}

.hero-cta::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s;
}

.hero-cta:hover::before {
    left: 100%;
}

.hero-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 30px rgba(0, 240, 255, 0.4);
}

.hero-visual {
    position: relative;
    height: 500px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.code-window {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    width: 100%;
    max-width: 480px;
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    opacity: 0;
    animation: fadeInUp 1s 0.8s forwards;
    transform: perspective(1000px) rotateY(-5deg) rotateX(5deg);
    transition: transform 0.3s;
}

.code-window:hover {
    transform: perspective(1000px) rotateY(0) rotateX(0);
}

.window-header {
    background: rgba(255, 255, 255, 0.03);
    padding: 0.75rem 1rem;
    display: flex;
    gap: 0.5rem;
    border-bottom: 1px solid var(--border);
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--text-muted);
}

.dot:nth-child(1) {
    background: #ff5f57;
}

.dot:nth-child(2) {
    background: #febc2e;
}

.dot:nth-child(3) {
    background: #28c840;
}

.code-content {
    padding: 1.5rem;
    font-family: var(--font-mono);
    font-size: 0.85rem;
    line-height: 1.8;
}

.code-line {
    display: flex;
    gap: 1rem;
    color: var(--text-muted);
}

.line-num {
    color: var(--text-muted);
    opacity: 0.4;
    min-width: 1.5rem;
    text-align: right;
}

.code-text {
    color: var(--text);
}

.code-keyword {
    color: #ff79c6;
}

.code-string {
    color: #f1fa8c;
}

.code-func {
    color: #8be9fd;
}

.code-comment {
    color: #6272a4;
    font-style: italic;
}

.typing-code {
    overflow: hidden;
    white-space: nowrap;
    border-right: 2px solid var(--accent);
    animation: typing 3s steps(40) 1.5s forwards, blink-caret 0.75s step-end infinite;
    width: 0;
}

@keyframes typing {
    from {
        width: 0
    }

    to {
        width: 100%
    }
}

@keyframes blink-caret {
    50% {
        border-color: transparent
    }
}

.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: 0.75rem;
    opacity: 0;
    animation: fadeIn 1s 2s forwards;
    cursor: pointer;
    text-decoration: none;
}

@keyframes fadeIn {
    to {
        opacity: 1;
    }
}

.scroll-arrow {
    width: 20px;
    height: 30px;
    border: 2px solid var(--text-muted);
    border-radius: 10px;
    position: relative;
}

.scroll-arrow::before {
    content: "";
    position: absolute;
    top: 6px;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 6px;
    background: var(--accent);
    border-radius: 2px;
    animation: scrollMouse 2s infinite;
}

@keyframes scrollMouse {
    0% {
        top: 6px;
        opacity: 1;
    }

    100% {
        top: 18px;
        opacity: 0;
    }
}

.section-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 3rem;
    font-family: var(--font-mono);
    font-size: 0.9rem;
    color: var(--text-muted);
}

.section-header::after {
    content: "";
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, var(--border), transparent);
    max-width: 300px;
}

.section-header span {
    color: var(--accent);
    font-weight: 600;
}

.repos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 1.5rem;
}

.repo-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1.75rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.repo-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, var(--accent), transparent);
    opacity: 0;
    transition: opacity 0.3s;
}

.repo-card:hover {
    transform: translateY(-5px);
    border-color: rgba(0, 240, 255, 0.2);
    box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.6), 0 0 20px rgba(0, 240, 255, 0.05);
}

.repo-card:hover::before {
    opacity: 1;
}

.repo-icon {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    opacity: 0.8;
}

.repo-name {
    font-family: var(--font-mono);
    font-size: 1.1rem;
    color: var(--text);
    margin-bottom: 0.75rem;
    font-weight: 600;
}

.repo-desc {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.repo-meta {
    display: flex;
    gap: 1.5rem;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text-muted);
}

.repo-meta span {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.repo-meta span a {
    color: var(--accent-glow);
    text-decoration: none;
    font-style: italic;
}

.repo-meta span a::after {
    display: block;
    content: '';
    background-color: var(--accent-dim);
    width: 0%;
    height: 1px;
    transition: width 100ms ease-in;
}

.repo-meta span a:hover {
    color: var(--accent);
}

.repo-meta span a:hover::after {
    width: 100%;
    background-color: var(--accent);
}

.lang-color {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
}

.loading {
    grid-column: 1 / -1;
    text-align: center;
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: 0.9rem;
    padding: 4rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--surface-elevated);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: start;
}

.about-text p {
    color: var(--text-muted);
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 1.5rem;
}

.stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-top: 3rem;
}

.stat {
    border-left: 2px solid var(--border);
    padding-left: 1.5rem;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--accent);
    font-family: var(--font-mono);
    display: block;
    margin-bottom: 0.25rem;
}

.stat-label {
    font-size: 0.85rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.skills-terminal {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 2rem;
    font-family: var(--font-mono);
    font-size: 0.9rem;
}

.terminal-line {
    margin-bottom: 0.5rem;
    color: var(--text-muted);
}

.terminal-cmd {
    color: var(--accent);
}

.terminal-output {
    color: var(--text);
    margin-bottom: 1rem;
    padding-left: 1rem;
    line-height: 1.8;
}

.tech-badge {
    display: inline-block;
    background: var(--surface-elevated);
    border: 1px solid var(--border);
    padding: 0.2rem 0.6rem;
    border-radius: 4px;
    margin: 0.2rem;
    font-size: 0.8rem;
    color: var(--accent);
    transition: all 0.2s;
}

.tech-badge:hover {
    border-color: var(--accent);
    background: var(--accent-dim);
    transform: translateY(-2px);
}

.typing-cursor {
    display: inline-block;
    width: 8px;
    height: 16px;
    background: var(--accent);
    animation: blink 1s infinite;
    vertical-align: middle;
    margin-left: 4px;
}

.collab-section {
    margin-top: 4rem;
}

.collab-container {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 4rem;
    position: relative;
    overflow: hidden;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.collab-container::before {
    content: "";
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, var(--accent-dim) 0%, transparent 70%);
    opacity: 0.5;
    pointer-events: none;
}

.collab-header {
    position: relative;
    z-index: 1;
    margin-bottom: 3rem;
}

.collab-header h2 {
    font-size: clamp(1.5rem, 4vw, 2.5rem);
    font-weight: 700;
    margin-bottom: 1rem;
    letter-spacing: -1px;
}

.collab-header p {
    color: var(--text-muted);
    font-size: 1.1rem;
    max-width: 500px;
    margin: 0 auto;
}

.contact-options {
    position: relative;
    z-index: 1;
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}

.contact-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    border-radius: 12px;
    font-family: var(--font-mono);
    font-weight: 600;
    font-size: 1rem;
    text-decoration: none;
    transition: all 0.3s;
    min-width: 160px;
    justify-content: center;
}

.contact-btn i {
    font-size: 1.3rem;
}

.contact-btn.whatsapp {
    background: #25D366;
    color: #fff;
}

.contact-btn.whatsapp:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(37, 211, 102, 0.4);
}

.contact-btn.email {
    background: var(--surface-elevated);
    color: var(--text);
    border: 1px solid var(--border);
}

.contact-btn.email:hover {
    border-color: var(--accent);
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0, 240, 255, 0.2);
}

.contact-btn.linkedin {
    background: #0A66C2;
    color: #fff;
}

.contact-btn.linkedin:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(10, 102, 194, 0.4);
}

.contact-note {
    position: relative;
    z-index: 1;
    color: var(--text-muted);
    font-size: 1rem;
}

.stack-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 1rem;
    margin-top: 2rem;
}

.stack-item {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 1.5rem 1rem;
    text-align: center;
    transition: all 0.3s;
    cursor: default;
}

.stack-item:hover {
    border-color: var(--accent);
    transform: translateY(-3px);
    background: var(--surface-elevated);
}

.stack-icon {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.stack-name {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text);
    font-weight: 600;
}

footer {
    padding: 3rem 5%;
    text-align: center;
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: 0.8rem;
    border-top: 1px solid var(--border);
    margin-top: 6rem;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 1.5rem;
}

.social-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 1.25rem;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid var(--border);
}

.social-links a:hover {
    color: var(--accent);
    border-color: var(--accent);
    transform: translateY(-3px);
}

@media (max-width: 968px) {
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 3rem;
    }

    .hero-text {
        order: 1;
    }

    .hero-visual {
        order: 2;
        height: auto;
    }

    .code-window {
        max-width: 100%;
        transform: none;
    }

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

    .hero h1 .name {
        font-size: 0.9em;
    }

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

    .stats {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .stat {
        border-left: none;
        border-top: 2px solid var(--border);
        padding-left: 0;
        padding-top: 1.5rem;
    }

    .stack-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 640px) {
    .nav-links {
        display: none;
    }

    .mobile-menu-btn {
        display: flex;
    }

    .hero h1 {
        letter-spacing: -2px;
    }

    .hero-description {
        font-size: 1.1rem;
    }

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

    .collab-container {
        padding: 2rem 1.5rem;
    }

    section {
        padding: 4rem 5%;
    }

    .code-content {
        font-size: 0.75rem;
        padding: 1rem;
    }

    .stack-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }

    .stack-item {
        padding: 1rem 0.5rem;
    }
}

.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: all 0.8s ease;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg);
}

::-webkit-scrollbar-thumb {
    background: var(--surface-elevated);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--border);
}