:root {
    --bg: #020617;          /* dark slate */
    --bg-alt: #020b1f;
    --card-bg: #0b1220;
    --accent: #0ea5e9;      /* sky blue */
    --accent-soft: #0369a1;
    --text: #e5e7eb;
    --text-muted: #9ca3af;
    --border-subtle: #1f2937;
    --radius-lg: 16px;
    --radius-md: 10px;
    --shadow-soft: 0 18px 45px rgba(15, 23, 42, 0.85);
}

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

html, body {
    margin: 0;
    padding: 0;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: radial-gradient(circle at top, #0b1220 0, #020617 45%, #000 100%);
    color: var(--text);
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
}

/* Layout helpers */
.section {
    max-width: 1100px;
    margin: 0 auto;
    padding: 4rem 1.5rem;
}

.section-alt {
    background: radial-gradient(circle at top, #020b1f 0, #020617 60%);
    border-top: 1px solid var(--border-subtle);
    border-bottom: 1px solid var(--border-subtle);
}

.section-header {
    max-width: 640px;
    margin: 0 auto 2.5rem auto;
    text-align: center;
}

.section-header h2 {
    font-size: 1.9rem;
    margin-bottom: 0.5rem;
}

.section-header p {
    margin: 0;
    color: var(--text-muted);
}

/* Header / Nav / Hero */
.site-header {
    border-bottom: 1px solid rgba(31, 41, 55, 0.7);
    padding: 0 1.5rem 2rem 1.5rem;
}

.nav {
    max-width: 1100px;
    margin: 0 auto;
    padding: 1.25rem 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 20;
    backdrop-filter: blur(16px);
    background: linear-gradient(to bottom, rgba(2, 6, 23, 0.9), rgba(2, 6, 23, 0.4));
}

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

.logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 999px;
    background: radial-gradient(circle at 0 0, #38bdf8, #0369a1);
    color: #0b1120;
    font-weight: 700;
    text-decoration: none;
    box-shadow: 0 12px 30px rgba(56, 189, 248, 0.35);
}

.logo-text {
    font-weight: 600;
    letter-spacing: 0.02em;
}

.nav-right {
    display: flex;
    gap: 1.25rem;
    font-size: 0.9rem;
}

.nav-right a {
    text-decoration: none;
    color: var(--text-muted);
    padding-bottom: 0.15rem;
    border-bottom: 1px solid transparent;
}

.nav-right a:hover {
    color: var(--text);
    border-bottom-color: var(--accent);
}

/* Hero */
.hero {
    max-width: 1100px;
    margin: 1.5rem auto 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 2.1fr) minmax(0, 1.4fr);
    gap: 2.5rem;
    align-items: center;
    padding-bottom: 2.5rem;
}

.hero-text h1 {
    font-size: clamp(2.2rem, 3vw, 2.8rem);
    margin: 0 0 0.75rem 0;
}

.hero-subtitle {
    margin: 0 0 1.5rem 0;
    color: var(--text-muted);
    line-height: 1.5;
    max-width: 560px;
}

.hero-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.3rem;
    border-radius: 999px;
    font-size: 0.9rem;
    text-decoration: none;
    cursor: pointer;
    border: 1px solid transparent;
    transition: transform 0.12s ease, box-shadow 0.12s ease, background 0.12s ease;
}

.btn.primary {
    background: radial-gradient(circle at 0 0, #38bdf8, #0369a1);
    box-shadow: 0 18px 45px rgba(8, 47, 73, 0.8);
    color: #0b1120;
    font-weight: 600;
}

.btn.primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 22px 60px rgba(8, 47, 73, 0.95);
}

.btn.secondary {
    border-color: rgba(148, 163, 184, 0.5);
    background: rgba(15, 23, 42, 0.7);
    color: var(--text);
}

.btn.secondary:hover {
    background: rgba(15, 23, 42, 0.9);
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1.25rem;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.hero-side {
    display: flex;
    justify-content: flex-end;
}

.hero-card {
    background: radial-gradient(circle at top left, rgba(56, 189, 248, 0.13), rgba(15, 23, 42, 0.98));
    border-radius: var(--radius-lg);
    padding: 1.4rem 1.4rem 1.2rem 1.4rem;
    box-shadow: var(--shadow-soft);
    max-width: 340px;
    border: 1px solid rgba(56, 189, 248, 0.25);
}

.hero-card h2 {
    font-size: 1.1rem;
    margin-top: 0;
}

.hero-card ul {
    padding-left: 1.15rem;
    margin: 0.5rem 0 1rem 0;
    color: var(--text-muted);
    font-size: 0.9rem;
    line-height: 1.4;
}

.hero-links {
    display: flex;
    gap: 0.75rem;
    font-size: 0.85rem;
}

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

/* Cards & grids */
.card {
    background: linear-gradient(to bottom right, rgba(15, 23, 42, 0.96), rgba(15, 23, 42, 0.98));
    border-radius: var(--radius-lg);
    padding: 1.4rem 1.5rem;
    border: 1px solid rgba(30, 64, 175, 0.5);
    box-shadow: 0 16px 40px rgba(15, 23, 42, 0.9);
}

.card h3 {
    margin-top: 0;
    margin-bottom: 0.6rem;
}

.card ul {
    padding-left: 1.15rem;
    margin: 0.25rem 0;
    color: var(--text-muted);
    font-size: 0.92rem;
    line-height: 1.5;
}

/* Skills grid */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1.25rem;
}

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

.project-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.project-tag {
    font-size: 0.8rem;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin: 0.1rem 0 0.7rem 0;
}

.project-points {
    padding-left: 1.1rem;
    margin: 0.75rem 0 1rem 0;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.project-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: auto;
    padding-top: 0.6rem;
    border-top: 1px dashed rgba(148, 163, 184, 0.5);
    font-size: 0.85rem;
}

.project-label {
    padding: 0.2rem 0.6rem;
    border-radius: 999px;
    background: rgba(56, 189, 248, 0.1);
    color: var(--accent);
    border: 1px solid rgba(56, 189, 248, 0.5);
}

.project-links a {
    text-decoration: none;
    font-size: 0.85rem;
    color: var(--accent);
}

/* Timeline (experience) */
.timeline {
    display: grid;
    gap: 1.5rem;
}

.timeline-item {
    border-left: 2px solid rgba(148, 163, 184, 0.5);
    padding-left: 1.2rem;
    position: relative;
}

.timeline-item::before {
    content: "";
    width: 10px;
    height: 10px;
    border-radius: 999px;
    background: var(--accent);
    border: 2px solid #0b1120;
    position: absolute;
    left: -6px;
    top: 0.45rem;
}

.timeline-meta {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 0.15rem;
    margin-bottom: 0.5rem;
}

.timeline ul {
    padding-left: 1rem;
    margin: 0;
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Certifications */
.certs-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.25rem;
}

/* Contact */
.contact-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.25rem;
}

.contact-list {
    list-style: none;
    padding-left: 0;
    margin: 0.5rem 0 0 0;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.contact-list li a {
    color: var(--accent);
    text-decoration: none;
}

.contact-list li a:hover {
    text-decoration: underline;
}

/* Footer */
.site-footer {
    border-top: 1px solid rgba(31, 41, 55, 0.7);
    padding: 1.25rem 1.5rem 1.75rem 1.5rem;
    text-align: center;
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* Responsive */
@media (max-width: 960px) {
    .hero {
        grid-template-columns: minmax(0, 1fr);
    }
    .hero-side {
        justify-content: flex-start;
    }
    .skills-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .projects-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .certs-grid,
    .contact-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (max-width: 640px) {
    .nav {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
    }
    .nav-right {
        flex-wrap: wrap;
        gap: 0.75rem;
    }
    .section {
        padding: 3rem 1.1rem;
    }
    .skills-grid,
    .projects-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}
