:root {
    --bg: #f3f6ff;
    --bg-soft: #e9f0ff;
    --surface: rgba(255, 255, 255, 0.72);
    --surface-border: rgba(255, 255, 255, 0.65);
    --text: #172239;
    --muted: #4c5f84;
    --heading: #0e1830;
    --accent: #4f75ff;
    --accent-strong: #2f54da;
    --shadow: 0 20px 52px rgba(38, 55, 115, 0.15);
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
}

body {
    font-family: Inter, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background: radial-gradient(1300px 780px at 5% -5%, #dce8ff 0%, transparent 60%),
        radial-gradient(1000px 620px at 108% 8%, #dff7ff 0%, transparent 55%),
        linear-gradient(165deg, var(--bg) 0%, var(--bg-soft) 100%);
    color: var(--text);
    line-height: 1.68;
    transition: background 0.35s ease, color 0.35s ease;
    min-height: 100vh;
}

.background-glow {
    position: fixed;
    inset: 0;
    background: radial-gradient(circle at 16% 20%, rgba(91, 128, 255, 0.22), transparent 38%),
        radial-gradient(circle at 82% 14%, rgba(86, 202, 255, 0.16), transparent 35%);
    pointer-events: none;
    z-index: -1;
}

.resume-shell {
    width: min(1020px, calc(100% - 2rem));
    margin: 3.4rem auto 2rem;
    display: grid;
    gap: 1.15rem;
}

.glass-card {
    background: var(--surface);
    border: 1px solid var(--surface-border);
    border-radius: 20px;
    box-shadow: var(--shadow);
    backdrop-filter: blur(13px);
    -webkit-backdrop-filter: blur(13px);
    padding: 1.5rem 1.4rem;
    transition: transform 0.22s ease, box-shadow 0.22s ease, background 0.3s ease;
}

.glass-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 24px 58px rgba(38, 55, 115, 0.18);
}

.hero {
    padding: 2rem 1.8rem;
}

.eyebrow {
    margin: 0;
    font-size: 0.82rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--accent-strong);
    font-weight: 700;
}

h1,
h2,
h3 {
    color: var(--heading);
    line-height: 1.2;
}

h1 {
    margin: 0.45rem 0 0.65rem;
    font-size: clamp(2rem, 4.2vw, 3rem);
    letter-spacing: -0.02em;
}

h2 {
    margin: 0 0 0.9rem;
    font-size: clamp(1.2rem, 2.6vw, 1.5rem);
    border-bottom: 1px solid rgba(53, 88, 215, 0.18);
    padding-bottom: 0.55rem;
}

h3 {
    margin: 0;
    font-size: clamp(1.03rem, 2vw, 1.2rem);
}

p {
    margin: 0;
}

.summary {
    max-width: 72ch;
    color: var(--muted);
    font-size: 1.03rem;
}

.hero-actions {
    margin-top: 1.15rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.62rem;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    border: 1px solid transparent;
    padding: 0.56rem 0.9rem;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.92rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

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

.btn-pill {
    border-color: rgba(79, 117, 255, 0.24);
    background: rgba(79, 117, 255, 0.12);
    color: #24396f;
    box-shadow: none;
}

.btn-pill:hover {
    background: rgba(79, 117, 255, 0.2);
    color: #1f3263;
}

.hero-meta {
    margin: 1rem 0 0;
    padding: 0;
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 0.52rem;
}

.hero-meta li {
    background: rgba(79, 117, 255, 0.12);
    border: 1px solid rgba(79, 117, 255, 0.24);
    color: #24396f;
    border-radius: 999px;
    padding: 0.35rem 0.78rem;
    font-size: 0.91rem;
    font-weight: 550;
}

.featured-card {
    border: 1px solid rgba(79, 117, 255, 0.24);
}

.project-card {
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(86, 113, 210, 0.2);
    border-radius: 16px;
    padding: 1.05rem;
}

.project-head {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 0.55rem;
    margin-bottom: 0.45rem;
}

.project-head h3 {
    margin: 0;
}

.project-tag {
    border-radius: 999px;
    padding: 0.2rem 0.58rem;
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 700;
    color: #23366a;
    border: 1px solid rgba(59, 88, 191, 0.25);
    background: rgba(79, 117, 255, 0.12);
}

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

.project-highlights {
    margin: 0.78rem 0 0;
    padding-left: 1.35rem;
    list-style: disc;
}

.project-highlights li {
    margin: 0.34rem 0;
    color: #23366a;
}

.project-links {
    margin-top: 0.9rem;
}

.project-links .btn-pill {
    display: inline-flex;
    border-color: rgba(79, 117, 255, 0.24);
    background: rgba(79, 117, 255, 0.12);
    color: #24396f;
    text-decoration: none;
}

ul {
    margin: 0;
    padding: 0;
}

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

.role-card {
    list-style: none;
    background: rgba(255, 255, 255, 0.67);
    border: 1px solid rgba(86, 113, 210, 0.16);
    border-radius: 14px;
    padding: 1rem;
}

.role-header {
    margin-bottom: 0.58rem;
}

.role-header p {
    margin-top: 0.28rem;
    color: var(--muted);
    font-weight: 520;
}

.experience-details {
    margin: 0.25rem 0 0;
    padding-left: 1.2rem;
}

.experience-details li {
    margin: 0.35rem 0;
    color: #273347;
}

.compact-list li {
    margin: 0.2rem 0;
}

.skills-list {
    list-style: none;
    display: grid;
    gap: 0.72rem;
}

.skills-list li {
    background: rgba(255, 255, 255, 0.58);
    border: 1px solid rgba(86, 113, 210, 0.14);
    border-radius: 12px;
    padding: 0.72rem 0.88rem;
}

a {
    color: var(--accent-strong);
    text-decoration-thickness: 0.08em;
    text-underline-offset: 0.14em;
}

a:hover {
    color: #253c9d;
}

.footer-card {
    text-align: center;
    color: var(--muted);
    font-size: 0.92rem;
}

.theme-toggle {
    position: fixed;
    top: 16px;
    right: 18px;
    width: 3.2rem;
    height: 3.2rem;
    border-radius: 999px;
    border: 1px solid rgba(86, 113, 210, 0.22);
    background: rgba(255, 255, 255, 0.78);
    color: #1c2a4d;
    box-shadow: 0 10px 30px rgba(30, 42, 78, 0.2);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.theme-toggle:hover {
    transform: translateY(-1px);
}

.theme-toggle__expand {
    width: 66%;
    height: 66%;
    transition: transform 0.35s ease, fill 0.35s ease;
}

body.dark-mode {
    --bg: #090d1b;
    --bg-soft: #151c31;
    --surface: rgba(20, 27, 46, 0.68);
    --surface-border: rgba(116, 138, 214, 0.25);
    --text: #dce6ff;
    --muted: #a6b8e4;
    --heading: #f4f7ff;
    --accent: #8eb0ff;
    --accent-strong: #a9c1ff;
    --shadow: 0 22px 60px rgba(0, 0, 0, 0.45);
}

body.dark-mode .background-glow {
    background: radial-gradient(circle at 15% 20%, rgba(66, 92, 184, 0.22), transparent 35%),
        radial-gradient(circle at 85% 15%, rgba(55, 112, 170, 0.2), transparent 33%);
}

body.dark-mode .theme-toggle {
    background: rgba(18, 24, 39, 0.85);
    border-color: rgba(167, 189, 255, 0.4);
    color: #f5dc6a;
}

body.dark-mode .theme-toggle__expand {
    transform: rotate(180deg);
    fill: #f5dc6a;
}

body.dark-mode .role-card,
body.dark-mode .skills-list li,
body.dark-mode .project-card,
body.dark-mode .btn-pill {
    background: rgba(15, 22, 38, 0.7);
    border-color: rgba(130, 155, 242, 0.25);
}

body.dark-mode .project-links .btn-pill {
    background: rgba(126, 156, 255, 0.18);
    border-color: rgba(163, 187, 255, 0.35);
    color: #dbe7ff;
}

body.dark-mode .hero-meta li,
body.dark-mode .project-tag {
    background: rgba(126, 156, 255, 0.18);
    border-color: rgba(163, 187, 255, 0.35);
    color: #dbe7ff;
}

body.dark-mode .project-highlights li {
    color: #dbe7ff;
}

body.dark-mode .experience-details li {
    color: #ccd9f7;
}

@media (max-width: 760px) {
    .resume-shell {
        width: min(1000px, calc(100% - 1.15rem));
        margin-top: 4.5rem;
    }

    .glass-card,
    .hero {
        padding: 1.15rem 1rem;
        border-radius: 16px;
    }

    .theme-toggle {
        top: 10px;
        right: 10px;
        width: 2.95rem;
        height: 2.95rem;
    }

    .hero-meta,
    .hero-actions {
        gap: 0.45rem;
    }

    .hero-meta li,
    .hero-actions .btn {
        width: 100%;
        text-align: center;
    }

    .project-head {
        align-items: flex-start;
        flex-direction: column;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation: none !important;
        transition: none !important;
        scroll-behavior: auto !important;
    }
}
