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

/* Global */
:root {
    color-scheme: dark;
    --bg: #05070d;
    --bg-secondary: #0d111a;
    --card: #111827;
    --card-strong: #0f172a;
    --text: #e2e8f0;
    --muted: #94a3b8;
    --accent: #7c3aed;
    --accent-strong: #a855f7;
    --border: rgba(148, 163, 184, 0.2);
}

body {
    font-family: 'Inter', 'Segoe UI', Tahoma, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.7;
    min-height: 100vh;
    scroll-behavior: smooth;
    position: relative;
}

.grid-overlay {
    position: fixed;
    inset: 0;
    background-image: linear-gradient(rgba(255,255,255,0.02) 1px, transparent 1px),
                      linear-gradient(90deg, rgba(255,255,255,0.02) 1px, transparent 1px);
    background-size: 60px 60px;
    pointer-events: none;
    z-index: 0;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
    position: relative;
    z-index: 1;
}

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

a {
    color: inherit;
}

/* Navbar */
.navbar {
    position: sticky;
    top: 0;
    z-index: 10;
    background: rgba(5, 7, 13, 0.85);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
}

.nav-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.5rem;
    gap: 2rem;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.logo span {
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    background: linear-gradient(120deg, var(--accent), var(--accent-strong));
    font-weight: 700;
}

.logo p {
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.75rem;
}

.nav-links {
    display: flex;
    gap: 1rem;
    font-weight: 500;
    color: var(--muted);
}

.nav-links a {
    text-decoration: none;
    transition: color 0.2s ease;
}

.nav-links a:hover {
    color: #fff;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    border-radius: 999px;
    padding: 0.85rem 1.6rem;
    font-weight: 600;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    border: 1px solid transparent;
}

.btn.primary {
    background: linear-gradient(120deg, var(--accent), var(--accent-strong));
    box-shadow: 0 10px 30px rgba(124, 58, 237, 0.4);
}

.btn.secondary {
    border-color: var(--border);
    background: rgba(255, 255, 255, 0.05);
}

.btn.ghost {
    border-color: transparent;
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
}

.btn.large {
    padding: 1rem 2rem;
    font-size: 1rem;
}

.btn:hover {
    transform: translateY(-2px);
}

.btn[aria-disabled="true"] {
    opacity: 0.4;
    cursor: not-allowed;
    pointer-events: none;
}

/* Hero */
.hero {
    padding: 6rem 0 4rem;
    position: relative;
}

.hero-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 3rem;
    align-items: center;
}

.hero-copy h1 {
    font-size: clamp(2.5rem, 5vw, 3.8rem);
    font-weight: 700;
    line-height: 1.2;
}

.hero-copy h1 span {
    display: block;
    background: linear-gradient(120deg, var(--accent), #34d399);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-kicker {
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 3px;
    font-size: 0.75rem;
    margin-bottom: 1rem;
}

.hero-description {
    color: var(--muted);
    margin: 1.5rem 0 1rem;
    max-width: 540px;
}

.hero-mini-text {
    color: var(--muted);
    font-size: 0.95rem;
    font-style: italic;
    margin-bottom: 2rem;
    max-width: 540px;
}

.hero-ctas {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.hero-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 1.2rem;
    margin-top: 2.5rem;
}

.hero-stats h3 {
    font-size: 2rem;
    font-weight: 700;
}

.hero-stats p {
    color: var(--muted);
}

.hero-card {
    background: radial-gradient(circle at top, rgba(124,58,237,0.35), rgba(5,7,13,0.8));
    padding: 2rem;
    border-radius: 24px;
    border: 1px solid var(--border);
    position: relative;
    text-align: center;
    animation: float 5s ease-in-out infinite;
}

.profile-ring {
    width: 220px;
    height: 220px;
    border-radius: 50%;
    border: 1px dashed rgba(255,255,255,0.2);
    margin: 0 auto;
    display: grid;
    place-items: center;
    position: relative;
}

.profile-img {
    width: 200px;
    height: 200px;
    object-fit: cover;
    border-radius: 50%;
    border: 4px solid rgba(255,255,255,0.2);
    position: relative;
    z-index: 1;
}

.hero-card-info {
    margin-top: 1.5rem;
}

.hero-role {
    color: var(--muted);
    letter-spacing: 1px;
    text-transform: uppercase;
    font-size: 0.8rem;
}

.hero-tech {
    display: flex;
    gap: 0.6rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 0.8rem;
}

.hero-tech span {
    padding: 0.35rem 0.9rem;
    border-radius: 999px;
    background: rgba(255,255,255,0.08);
    font-size: 0.85rem;
}

/* Sections */
.section {
    padding: 5rem 0;
    border-bottom: 1px solid rgba(255,255,255,0.04);
}

.section-header {
    margin-bottom: 2.5rem;
}

.section-header.compact {
    margin-bottom: 1rem;
}

.kicker {
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 3px;
    font-size: 0.75rem;
    margin-bottom: 0.5rem;
}

.section h2 {
    font-size: clamp(1.8rem, 4vw, 2.6rem);
}

/* Stack */
.stack-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.5rem;
}

.stack-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 2rem;
    position: relative;
    overflow: hidden;
    transition: transform 0.3s ease, border 0.3s ease;
}

.stack-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at top, rgba(124,58,237,0.3), transparent 60%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.stack-card:hover {
    transform: translateY(-6px);
    border-color: rgba(124,58,237,0.6);
}

.stack-card:hover::after {
    opacity: 1;
}

.stack-icon {
    width: 56px;
    height: 56px;
    border-radius: 16px;
    background: rgba(124, 58, 237, 0.15);
    display: grid;
    place-items: center;
    color: var(--accent-strong);
    font-size: 1.4rem;
    margin-bottom: 1.5rem;
}

.stack-card h3 {
    margin-bottom: 0.5rem;
}

.stack-card p {
    color: var(--muted);
    margin-bottom: 1rem;
}

.tags {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.tags span {
    font-size: 0.85rem;
    padding: 0.3rem 0.8rem;
    border-radius: 999px;
    background: rgba(255,255,255,0.08);
}

/* Timeline */
.timeline-card {
    background: var(--card-strong);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 2rem;
    position: relative;
    overflow: hidden;
}

.timeline-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, rgba(124,58,237,0.15), transparent);
    opacity: 0.6;
}

.timeline-card > * {
    position: relative;
    z-index: 1;
}

.timeline-header {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 0.5rem;
}

.timeline-header span {
    color: var(--muted);
}

.timeline-reference {
    color: var(--muted);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.timeline ul {
    list-style: none;
    display: grid;
    gap: 0.8rem;
}

.timeline li {
    padding-left: 1.5rem;
    position: relative;
    color: var(--muted);
}

.timeline li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.6rem;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 10px rgba(124,58,237,0.6);
}

/* Projects */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.5rem;
}

.project-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    min-height: 320px;
    transition: transform 0.3s ease, border 0.3s ease;
}

.project-card:hover {
    transform: translateY(-8px);
    border-color: rgba(52, 211, 153, 0.5);
}

.project-badge {
    display: inline-flex;
    padding: 0.3rem 0.9rem;
    border-radius: 999px;
    background: rgba(52, 211, 153, 0.1);
    color: #34d399;
    font-size: 0.85rem;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.project-card p {
    color: var(--muted);
}

.project-card ul {
    list-style: none;
    color: var(--muted);
    display: grid;
    gap: 0.5rem;
}

.project-card ul li {
    position: relative;
    padding-left: 1rem;
}

.project-card ul li::before {
    content: "•";
    position: absolute;
    left: 0;
    color: #34d399;
}

.project-links {
    margin-top: auto;
    display: flex;
    gap: 1rem;
}

.project-links .link {
    text-decoration: none;
    color: var(--text);
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.project-links .link::after {
    content: "↗";
    font-size: 0.9rem;
    transition: transform 0.2s ease;
}

.project-links .link:hover::after {
    transform: translate(2px, -2px);
}

/* Education & Skills */
.education-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 2rem;
    align-items: start;
}

.education-card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 1.5rem;
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    align-items: center;
}

.education-card span {
    color: var(--muted);
}

.skills-pill-group {
    display: flex;
    gap: 0.7rem;
    flex-wrap: wrap;
}

.skills-pill-group span {
    padding: 0.4rem 1rem;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: rgba(255,255,255,0.04);
    font-size: 0.9rem;
}

/* Contact */
.contact-section {
    border-bottom: none;
}

.contact-card {
    background: radial-gradient(circle at top left, rgba(124,58,237,0.25), rgba(5,7,13,0.9));
    border: 1px solid rgba(124,58,237,0.4);
    border-radius: 32px;
    padding: 3rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 2rem;
    align-items: center;
}

.contact-description {
    color: var(--muted);
    margin: 1rem 0 1.5rem;
}

.contact-links {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.contact-links a {
    text-decoration: none;
    color: var(--text);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.contact-actions {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: center;
    text-align: center;
}

.contact-socials {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}

.contact-socials a {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(255,255,255,0.08);
    border: 1px solid var(--border);
    display: grid;
    place-items: center;
    font-size: 1.3rem;
    text-decoration: none;
    transition: all 0.3s ease;
}

.contact-socials a:hover {
    background: var(--accent);
    border-color: var(--accent);
    transform: translateY(-3px);
}

.btn.xl {
    padding: 1.2rem 2.5rem;
    font-size: 1.1rem;
}

.contact-availability {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--muted);
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

.contact-availability i {
    color: #34d399;
    font-size: 0.6rem;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

/* Footer */
.footer {
    padding: 2.5rem 0;
    border-top: 1px solid rgba(255,255,255,0.06);
    background: rgba(0,0,0,0.4);
    margin-top: 2rem;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.footer-links {
    display: flex;
    gap: 1rem;
    color: var(--muted);
    font-size: 0.9rem;
}

/* Animations */
@keyframes float {
    0% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
    100% { transform: translateY(0); }
}

/* Responsive */
@media (max-width: 900px) {
    .nav-links {
        display: none;
    }

    .hero-stats {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 640px) {
    .hero-stats {
        grid-template-columns: 1fr;
    }

    .contact-card {
        padding: 2rem;
    }

    .nav-content {
        padding: 1rem;
    }

    .hero {
        padding-top: 5rem;
    }
}

