:root {
    --bg: #f4f6fb;
    --surface: #ffffff;
    --surface-alt: #eef1f8;
    --text: #111827;
    --muted: #4b5563;
    --accent: #2563eb;
    --accent-dark: #1e3aaf;
    --accent-soft: rgba(37, 99, 235, 0.15);
    --border: rgba(15, 23, 42, 0.08);
}

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

html {
    scroll-behavior: smooth;
}

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

img {
    display: block;
    max-width: 100%;
    height: auto;
}

a {
    color: inherit;
    text-decoration: none;
}

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

.container {
    width: min(1100px, 92vw);
    margin: 0 auto;
}

/* Navigation */
.navbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    box-shadow: 0 4px 20px rgba(15, 23, 42, 0.05);
}

.navbar .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.2rem 0;
}

.nav-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 600;
    color: var(--text);
}

.logo {
    height: 48px;
    width: auto;
}

.nav-menu {
    list-style: none;
    display: flex;
    gap: 1.75rem;
    font-weight: 500;
}

.nav-menu a {
    color: var(--muted);
    transition: color 0.2s ease;
}

.nav-menu a:hover,
.nav-menu a:focus {
    color: var(--accent);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 0.35rem;
    background: transparent;
    border: none;
    cursor: pointer;
}

.nav-toggle span {
    width: 1.75rem;
    height: 2px;
    background: var(--text);
    border-radius: 999px;
    display: block;
}

/* Hero */
.hero {
    position: relative;
    padding: 6rem 0 5rem;
    min-height: 85vh;
    background: radial-gradient(circle at 20% 20%, rgba(99, 102, 241, 0.25), transparent 55%),
                radial-gradient(circle at 80% 30%, rgba(139, 92, 246, 0.18), transparent 60%),
                linear-gradient(135deg, #0b1120, #111827 65%, #1e293b);
    color: #f8fbff;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.35) 0%, rgba(15, 23, 42, 0.65) 100%);
    z-index: 1;
}

.hero-canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

.hero-grid {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1.05fr);
    gap: 3.5rem;
    align-items: center;
}

.eyebrow {
    display: inline-block;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-size: 0.8rem;
    font-weight: 600;
    color: rgba(248, 251, 255, 0.75);
    margin-bottom: 1.25rem;
}

.hero-intro h1 {
    font-size: clamp(2.8rem, 4vw, 3.8rem);
    line-height: 1.1;
    font-weight: 700;
    margin-bottom: 1.2rem;
}

.hero-subtitle {
    font-size: 1.05rem;
    max-width: 560px;
    color: rgba(248, 251, 255, 0.85);
}

.hero-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin: 1.75rem 0;
}

.tag {
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    padding: 0.45rem 0.75rem;
    border-radius: 999px;
    background: rgba(37, 99, 235, 0.18);
    color: #dbeafe;
    border: 1px solid rgba(59, 130, 246, 0.35);
}

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

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    padding: 0.75rem 1.6rem;
    border-radius: 12px;
    font-weight: 600;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
    cursor: pointer;
}

.btn-primary {
    background: #f8fbff;
    color: var(--accent);
    box-shadow: 0 18px 35px -22px rgba(148, 191, 255, 0.9);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 22px 40px -20px rgba(148, 191, 255, 0.95);
}

.btn-secondary {
    border: 1.5px solid rgba(248, 251, 255, 0.5);
    color: #f8fbff;
    background: transparent;
}

.btn-secondary:hover {
    background: rgba(248, 251, 255, 0.08);
    transform: translateY(-2px);
}

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

.profile-card {
    backdrop-filter: blur(16px);
    background: rgba(15, 23, 42, 0.55);
    border: 1px solid rgba(148, 163, 184, 0.25);
    border-radius: 22px;
    padding: 2.6rem;
    max-width: 420px;
    width: 100%;
    box-shadow: 0 30px 60px -35px rgba(15, 23, 42, 0.8);
}

.profile-photo {
    width: 100%;
    max-width: 420px;
    height: 340px;
    object-fit: cover;
    object-position: top center;
    border-radius: 18px;
    margin: 0 auto 1.5rem;
    border: 3px solid rgba(248, 251, 255, 0.25);
}

.profile-stats {
    list-style: none;
    display: grid;
    gap: 1.1rem;
    color: rgba(248, 251, 255, 0.95);
    font-size: 1rem;
}

.profile-stats span {
    display: block;
    font-weight: 600;
}

.profile-stats small {
    display: block;
    margin-top: 0.35rem;
    color: rgba(248, 251, 255, 0.65);
    font-size: 0.8rem;
}

/* Sections */
.section {
    padding: 5rem 0;
}

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

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

.section-header h2 {
    font-size: clamp(2rem, 3vw, 2.4rem);
    margin-bottom: 0.75rem;
    color: var(--text);
}

.section-header p {
    color: var(--muted);
    font-size: 1rem;
}

/* About */
.about-wrapper {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 2.75rem;
    align-items: start;
}

.about-summary {
    background: var(--surface);
    border-radius: 24px;
    padding: 2.25rem;
    box-shadow: 0 24px 60px -45px rgba(15, 23, 42, 0.45);
    border: 1px solid var(--border);
}

.about-summary p + p {
    margin-top: 1.2rem;
}

.about-details {
    display: grid;
    gap: 2rem;
}

.about-details h3 {
    font-size: 1.05rem;
    margin-bottom: 1rem;
    color: var(--text);
}

.timeline {
    list-style: none;
    border-left: 2px solid rgba(37, 99, 235, 0.25);
    padding-left: 1.25rem;
    display: grid;
    gap: 1.25rem;
}

.timeline-title {
    font-weight: 600;
    color: var(--text);
}

.timeline-subtitle {
    font-size: 0.9rem;
    color: var(--muted);
}

.achievement-list {
    list-style: none;
    display: grid;
    gap: 0.75rem;
    color: var(--muted);
}

.achievement-list li::before {
    content: '•';
    color: var(--accent);
    margin-right: 0.5rem;
}

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

.research-card {
    padding: 2rem;
    border-radius: 18px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: #f8fbff;
    box-shadow: 0 22px 60px -50px rgba(15, 23, 42, 0.9);
    background: rgba(148, 163, 184, 0.15);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.research-card h3 {
    font-size: 1.2rem;
    margin-bottom: 0.75rem;
}

.research-card p {
    font-size: 0.95rem;
    color: rgba(248, 251, 255, 0.85);
}

.research-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 28px 70px -48px rgba(30, 58, 138, 0.95);
}

.research-card:nth-child(1) {
    background: linear-gradient(145deg, rgba(129, 140, 248, 0.35), rgba(59, 130, 246, 0.28));
}

.research-card:nth-child(2) {
    background: linear-gradient(145deg, rgba(45, 212, 191, 0.3), rgba(14, 165, 233, 0.28));
}

.research-card:nth-child(3) {
    background: linear-gradient(145deg, rgba(251, 191, 36, 0.3), rgba(249, 115, 22, 0.28));
}

.research-card:nth-child(4) {
    background: linear-gradient(145deg, rgba(56, 189, 248, 0.32), rgba(59, 130, 246, 0.3));
}

/* Cards */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 1.8rem;
}

.info-card {
    background: var(--surface);
    border-radius: 18px;
    padding: 2rem;
    border: 1px solid var(--border);
    box-shadow: 0 20px 45px -40px rgba(15, 23, 42, 0.4);
    display: flex;
    flex-direction: column;
    gap: 1.1rem;
}

.info-card h3 {
    font-size: 1.25rem;
    color: var(--text);
}

.info-card p {
    color: var(--muted);
    font-size: 0.95rem;
}

.card-tag {
    align-self: flex-start;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    padding: 0.35rem 0.75rem;
    border-radius: 999px;
    background: var(--accent-soft);
    color: var(--accent);
}

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

.project-card {
    background: var(--surface);
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid var(--border);
    box-shadow: 0 28px 60px -48px rgba(15, 23, 42, 0.45);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.project-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.project-body {
    padding: 1.8rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.project-body p {
    color: var(--muted);
    font-size: 0.96rem;
}

.project-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
    color: var(--muted);
}

.project-date {
    font-weight: 600;
}

.btn-link {
    color: var(--accent);
    font-weight: 600;
}

/* Gallery */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.8rem;
}

.gallery-card {
    position: relative;
    border-radius: 22px;
    overflow: hidden;
    min-height: 220px;
    border: 1px solid rgba(255, 255, 255, 0.35);
    box-shadow: 0 24px 55px -50px rgba(15, 23, 42, 0.55);
}

.gallery-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.gallery-card:hover img {
    transform: scale(1.05);
}

.gallery-label {
    position: absolute;
    inset: auto 0 0 0;
    padding: 1.5rem;
    background: linear-gradient(180deg, rgba(15, 23, 42, 0) 0%, rgba(15, 23, 42, 0.6) 70%, rgba(15, 23, 42, 0.8) 100%);
    color: #f8fbff;
}

.gallery-label h3 {
    font-size: 1.1rem;
    margin-bottom: 0.35rem;
}

.gallery-label p {
    font-size: 0.9rem;
    color: rgba(248, 251, 255, 0.8);
}

/* Contact */
.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2.5rem;
}

.contact-card {
    background: var(--surface);
    border-radius: 18px;
    padding: 1.8rem;
    border: 1px solid var(--border);
    text-align: center;
    box-shadow: 0 22px 50px -48px rgba(15, 23, 42, 0.45);
}

.contact-card i {
    font-size: 1.8rem;
    color: var(--accent);
    margin-bottom: 0.9rem;
}

.contact-card a {
    color: var(--accent);
    font-weight: 600;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 1rem;
}

.social-links a {
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--surface);
    border: 1px solid var(--border);
    color: var(--accent);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.social-links a:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 24px -18px rgba(37, 99, 235, 0.6);
}

/* Footer */
.footer {
    background: #0b1120;
    color: rgba(226, 232, 240, 0.85);
    padding: 2.5rem 0;
    text-align: center;
    font-size: 0.9rem;
}

.footer-links a {
    color: rgba(148, 191, 255, 0.9);
    margin-left: 0.5rem;
}

.footer-links a:hover {
    color: #f8fbff;
}

/* Responsive */
@media (max-width: 1024px) {
    .hero-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

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

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

    .profile-card {
        margin-top: 2.5rem;
        max-width: 360px;
        padding: 2.2rem;
    }

    .profile-photo {
        height: 300px;
    }

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

@media (max-width: 768px) {
    .navbar .container {
        padding: 1rem 0;
    }

    .nav-toggle {
        display: flex;
    }

    .nav-menu {
        position: absolute;
        top: calc(100% + 0.75rem);
        right: 1.5rem;
        flex-direction: column;
        gap: 1rem;
        background: var(--surface);
        border-radius: 16px;
        padding: 1.25rem 1.5rem;
        box-shadow: 0 20px 50px -35px rgba(15, 23, 42, 0.3);
        border: 1px solid var(--border);
        opacity: 0;
        pointer-events: none;
        transform: translateY(-10px);
        transition: opacity 0.2s ease, transform 0.2s ease;
    }

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

    .hero {
        padding: 5rem 0 4rem;
    }

    .about-summary {
        padding: 1.75rem;
    }

    .card-grid,
    .project-grid,
    .gallery-grid,
    .contact-grid {
        gap: 1.5rem;
    }
}

@media (max-width: 540px) {
    .hero-intro h1 {
        font-size: 2.4rem;
    }

    .hero-subtitle {
        font-size: 0.98rem;
    }

    .btn {
        width: 100%;
    }

    .profile-card {
        padding: 1.6rem;
        max-width: 320px;
    }

    .profile-photo {
        height: 260px;
    }

    .section {
        padding: 4rem 0;
    }

    .gallery-card {
        min-height: 200px;
    }
}
