:root {
    --bg: #0c1116;
    --surface: #141b23;
    --surface-hover: #182129;
    --border: #26313d;
    --text: #dbe4ee;
    --muted: #93a1b3;
    --accent: #5ccfe6;
    --accent-soft: rgba(92, 207, 230, 0.12);
    --mono: ui-monospace, "SF Mono", "Cascadia Code", "JetBrains Mono", Menlo, Consolas, monospace;
    --max-width: 880px;
    --nav-height: 64px;
}

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

html {
    scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
}

body {
    background: var(--bg);
    color: var(--text);
    font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 16px;
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
}

::selection {
    background: var(--accent);
    color: var(--bg);
}

a {
    color: var(--accent);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

a:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
    border-radius: 4px;
}

/* ===================== Nav ===================== */

.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: rgba(12, 17, 22, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
}

.nav-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 24px;
    height: var(--nav-height);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-brand {
    font-weight: 700;
    font-size: 1.05rem;
    color: var(--text);
    letter-spacing: 0.01em;
}

.nav-brand:hover {
    color: var(--accent);
    text-decoration: none;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 28px;
}

.nav-links a {
    color: var(--muted);
    font-size: 0.92rem;
    font-weight: 500;
}

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

.nav-links .nav-resume {
    color: var(--accent);
    border: 1px solid var(--accent);
    border-radius: 8px;
    padding: 6px 14px;
    transition: background 0.15s ease;
}

.nav-links .nav-resume:hover {
    background: var(--accent-soft);
}

/* ===================== Layout ===================== */

main {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 24px;
}

section {
    padding: 72px 0 24px;
    scroll-margin-top: var(--nav-height);
}

h2 {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 0.01em;
    margin-bottom: 40px;
    display: flex;
    align-items: baseline;
    gap: 12px;
}

.section-num {
    font-family: var(--mono);
    font-size: 1rem;
    font-weight: 500;
    color: var(--accent);
}

.section-num::after {
    content: ".";
}

/* ===================== Hero ===================== */

.hero {
    min-height: 92vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding-top: var(--nav-height);
}

.hero-kicker {
    font-family: var(--mono);
    color: var(--accent);
    font-size: 0.95rem;
    margin-bottom: 20px;
}

.hero-name {
    font-size: clamp(2.75rem, 8vw, 4.5rem);
    font-weight: 800;
    line-height: 1.05;
    letter-spacing: -0.02em;
}

.hero-role {
    font-size: clamp(1.25rem, 4vw, 1.9rem);
    font-weight: 700;
    color: var(--muted);
    letter-spacing: -0.01em;
    margin-top: 8px;
}

.hero-meta {
    font-family: var(--mono);
    font-size: 0.85rem;
    color: var(--muted);
    margin-top: 22px;
}

.hero-tagline {
    max-width: 620px;
    margin-top: 18px;
    color: var(--muted);
    font-size: 1.05rem;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 36px;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text);
    font-size: 0.92rem;
    font-weight: 500;
    transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease;
}

.btn:hover {
    border-color: var(--accent);
    color: var(--accent);
    text-decoration: none;
}

.btn-primary {
    border-color: var(--accent);
    color: var(--accent);
}

.btn-primary:hover {
    background: var(--accent-soft);
}

/* ===================== Experience ===================== */

.entry {
    padding: 22px 24px;
    border: 1px solid transparent;
    border-radius: 12px;
    margin: 0 -24px 12px;
    transition: background 0.15s ease, border-color 0.15s ease;
}

.entry:hover {
    background: var(--surface);
    border-color: var(--border);
}

.entry-head {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 16px;
    margin-bottom: 12px;
}

.entry h3 {
    font-size: 1.08rem;
    font-weight: 600;
}

.entry-org {
    color: var(--accent);
    font-size: 0.95rem;
    font-weight: 500;
    margin-top: 2px;
}

.entry-date {
    font-family: var(--mono);
    font-size: 0.8rem;
    color: var(--muted);
    white-space: nowrap;
    flex-shrink: 0;
}

.entry ul {
    list-style: none;
}

.entry li {
    position: relative;
    padding-left: 20px;
    margin-bottom: 8px;
    color: var(--muted);
    font-size: 0.95rem;
}

.entry li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.62em;
    width: 6px;
    height: 6px;
    border-radius: 2px;
    background: var(--accent);
}

.entry-education {
    margin-top: 32px;
}

.entry-education .entry-head {
    margin-bottom: 0;
}

/* ===================== Cards (Projects & Skills) ===================== */

.card-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
}

.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    transition: transform 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}

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

.card-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.card h3 {
    font-size: 1.05rem;
    font-weight: 600;
}

.card-link {
    color: var(--muted);
    display: inline-flex;
    transition: color 0.15s ease;
}

.card-link:hover {
    color: var(--accent);
}

.card p {
    color: var(--muted);
    font-size: 0.93rem;
    flex-grow: 1;
}

.inline-link {
    font-weight: 500;
    white-space: nowrap;
}

.tags {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 16px;
}

.tags li {
    font-family: var(--mono);
    font-size: 0.72rem;
    color: var(--accent);
    background: var(--accent-soft);
    border-radius: 6px;
    padding: 3px 9px;
}

.skill-card h3 {
    color: var(--accent);
    font-size: 0.95rem;
    margin-bottom: 10px;
}

.skill-card p {
    font-size: 0.9rem;
}

/* ===================== Footer ===================== */

footer {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 64px 24px 48px;
    text-align: center;
    color: var(--muted);
    font-size: 0.85rem;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 24px;
    margin-bottom: 14px;
}

.footer-links a {
    color: var(--muted);
    font-weight: 500;
}

.footer-links a:hover {
    color: var(--accent);
    text-decoration: none;
}

/* ===================== Responsive ===================== */

@media (max-width: 720px) {
    .nav-links {
        gap: 18px;
    }

    .nav-links a {
        font-size: 0.85rem;
    }

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

    .entry-head {
        flex-direction: column;
        gap: 4px;
    }

    .entry {
        padding: 18px 16px;
        margin: 0 -16px 10px;
    }

    .hero {
        min-height: auto;
        padding-bottom: 48px;
    }
}

@media (max-width: 480px) {
    .nav-links a:not(.nav-resume) {
        display: none;
    }
}
