:root {
    --bg-1: #170a2f;
    --bg-2: #2b0f4f;
    --surface: rgba(112, 63, 160, 0.22);
    --surface-strong: rgba(138, 88, 197, 0.22);
    --border: rgba(183, 144, 255, 0.2);
    --text: #f4efff;
    --muted: #b9acd6;
    --primary: #8ea0ff;
    --secondary: #9d59ff;
    --accent: #4da3ff;
    --success: #091225;
    --shadow: 0 20px 45px rgba(5, 7, 20, 0.35);
    --radius: 24px;
    --container: 1180px;
    --header-h: 78px;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at top left, rgba(135, 80, 220, 0.22), transparent 28%),
        radial-gradient(circle at top right, rgba(77, 163, 255, 0.12), transparent 22%),
        linear-gradient(90deg, #2d1150 0%, #241041 44%, #0d1230 100%);
    overflow-x: hidden;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background: radial-gradient(circle at center, rgba(255, 255, 255, 0.04), transparent 45%);
    opacity: 0.65;
    z-index: -2;
}

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

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

.container {
    width: min(var(--container), calc(100% - 32px));
    margin: 0 auto;
}

.section {
    padding: 110px 0 28px;
    scroll-margin-top: calc(var(--header-h) + 18px);
}

.section-title {
    text-align: center;
    font-size: clamp(2rem, 4vw, 3rem);
    line-height: 1.1;
    color: var(--primary);
    margin-bottom: 18px;
    font-weight: 800;
}

.section-lead {
    max-width: 760px;
    margin: 0 auto 48px;
    text-align: center;
    color: var(--muted);
    font-size: 1rem;
    line-height: 1.8;
}

header {
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(18px);
    background: rgba(21, 10, 42, 0.84);
    border-bottom: 1px solid rgba(177, 144, 255, 0.12);
}

.nav {
    min-height: var(--header-h);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.brand {
    font-size: 2rem;
    font-weight: 800;
    letter-spacing: 0.02em;
    color: var(--primary);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 32px;
    list-style: none;
}

.nav-links a {
    font-weight: 600;
    color: rgba(255, 255, 255, 0.92);
    transition: color .25s ease;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--accent);
}

.menu-btn {
    display: none;
    width: 48px;
    height: 48px;
    border-radius: 14px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.05);
    color: white;
    font-size: 1.4rem;
    cursor: pointer;
}

.hero {
    padding: 72px 0 40px;
    min-height: calc(100vh - var(--header-h));
    display: grid;
    align-items: center;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 40px;
    align-items: center;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 999px;
    color: var(--muted);
    margin-bottom: 22px;
    font-size: 0.95rem;
}

.hero h1 {
    font-size: clamp(2.6rem, 6vw, 5.3rem);
    line-height: 1.03;
    margin-bottom: 16px;
    font-weight: 800;
    letter-spacing: -0.03em;
}

.hero h1 span {
    color: var(--primary);
}

.hero p {
    max-width: 640px;
    color: var(--muted);
    line-height: 1.9;
    font-size: 1.04rem;
    margin-bottom: 28px;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-bottom: 28px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 52px;
    padding: 0 22px;
    border-radius: 14px;
    border: 1px solid transparent;
    font-weight: 700;
    transition: transform .22s ease, box-shadow .22s ease, background .22s ease;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25);
}

.btn-primary {
    background: linear-gradient(90deg, #4780e6 0%, #9f56ff 100%);
    color: white;
}

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

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
}

.chip {
    padding: 10px 14px;
    border-radius: 999px;
    color: var(--primary);
    border: 1px solid rgba(115, 155, 255, 0.28);
    background: rgba(68, 126, 255, 0.07);
    font-size: 0.92rem;
    font-weight: 600;
}

.hero-card {
    padding: 28px;
    background: linear-gradient(180deg, rgba(23, 28, 64, 0.92), rgba(33, 20, 68, 0.78));
    border: 1px solid var(--border);
    border-radius: 28px;
    box-shadow: var(--shadow);
    position: relative;
    overflow: hidden;
}

.hero-card::after {
    content: "";
    position: absolute;
    inset: auto -40px -40px auto;
    width: 180px;
    height: 180px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(157, 89, 255, 0.18), transparent 70%);
}

.code-window {
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(6, 10, 24, 0.74);
    border-radius: 20px;
    padding: 20px;
    position: relative;
    z-index: 1;
}

.dots {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
}

.dots span {
    width: 11px;
    height: 11px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.25);
}

.code-window pre {
    white-space: pre-wrap;
    color: #a6ffd1;
    line-height: 1.75;
    font-size: 0.95rem;
    font-family: Consolas, Monaco, monospace;
}

.stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-top: 34px;
}

.stat {
    text-align: center;
    padding: 14px;
}

.stat strong {
    display: block;
    font-size: clamp(2rem, 4vw, 3.6rem);
    color: var(--primary);
    line-height: 1;
    margin-bottom: 10px;
}

.stat:nth-child(2) strong {
    color: #bc7cff;
}

.stat:nth-child(3) strong {
    color: #ff9d46;
}

.stat span {
    color: var(--muted);
    font-size: 1.05rem;
}

.about-card,
.experience-card,
.contact-wrap,
.project-card {
    background: linear-gradient(180deg, rgba(101, 58, 150, 0.25), rgba(51, 35, 91, 0.3));
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.about-card {
    max-width: 980px;
    margin: 0 auto;
    padding: 34px;
}

.about-card p {
    color: #e6def8;
    line-height: 1.9;
    font-size: 1.05rem;
    margin-bottom: 20px;
}

.about-contact {
    display: flex;
    flex-wrap: wrap;
    gap: 18px 28px;
    margin-top: 26px;
    color: var(--text);
}

.about-contact span {
    color: var(--muted);
    font-weight: 500;
}

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

.skill-box {
    padding: 22px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.skill-box h3 {
    font-size: 1.1rem;
    margin-bottom: 14px;
    color: white;
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.skill-tags span {
    padding: 9px 12px;
    border-radius: 999px;
    border: 1px solid rgba(115, 155, 255, 0.28);
    color: var(--primary);
    background: rgba(68, 126, 255, 0.07);
    font-size: 0.9rem;
    font-weight: 600;
}

/* .projects-grid {
      display: grid;
      grid-template-columns: repeat(3, minmax(0, 1fr));
      gap: 24px;
    } */
.projects-grid {
    grid-template-columns: 1fr;
    max-width: 900px;
    margin: 0 auto;
}

.project-card {
    overflow: hidden;
    transition: transform .25s ease, box-shadow .25s ease;
}

.project-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 24px 45px rgba(0, 0, 0, 0.28);
}

.project-image {
    position: relative;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    border-radius: 10px;
    background: linear-gradient(135deg, rgba(116, 86, 201, 0.45), rgba(30, 26, 69, 0.45));
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.project-body {
    padding: 22px;
}

.project-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
}

.project-top h3 {
    font-size: 1.35rem;
    line-height: 1.2;
}

.project-top .tag {
    background: rgba(89, 110, 255, 0.18);
    color: var(--primary);
    border: 1px solid rgba(89, 110, 255, 0.18);
    padding: 8px 12px;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 700;
    white-space: nowrap;
}

.project-desc {
    color: var(--muted);
    line-height: 1.75;
    font-size: 0.96rem;
    min-height: 82px;
    margin-bottom: 18px;
}

.platforms {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 18px;
}

.platform {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #f5f3ff;
    font-size: 0.88rem;
    font-weight: 600;
}

.project-links {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.project-link {
    padding: 11px 14px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.04);
    color: white;
    font-weight: 600;
    font-size: 0.92rem;
}

.experience-list {
    display: grid;
    gap: 22px;
}

.experience-card {
    padding: 28px;
}

.experience-head {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 20px;
}

.experience-head h3 {
    font-size: 1.6rem;
    margin-bottom: 6px;
}

.experience-head h4 {
    color: var(--accent);
    font-size: 1.12rem;
    margin-bottom: 4px;
}

.experience-head p,
.experience-meta {
    color: var(--muted);
}

.experience-meta {
    text-align: right;
    min-width: 170px;
}

.pill {
    display: inline-flex;
    margin-top: 10px;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.95);
    color: #1d2040;
    font-weight: 700;
    font-size: 0.88rem;
}

.experience-points {
    display: grid;
    gap: 14px;
    padding-left: 18px;
    color: #efe8ff;
    line-height: 1.75;
}

.contact-wrap {
    display: grid;
    grid-template-columns: 0.95fr 1.05fr;
    gap: 34px;
    padding: 34px;
}

.contact-info h3,
.contact-form h3 {
    font-size: 2rem;
    margin-bottom: 20px;
}

.contact-info p {
    color: var(--muted);
    line-height: 1.9;
    margin-bottom: 26px;
    max-width: 520px;
}

.contact-list {
    display: grid;
    gap: 16px;
    margin-bottom: 26px;
}

.contact-list a,
.contact-list span {
    color: #efe8ff;
    font-size: 1.05rem;
    font-weight: 500;
}

.socials {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.socials a {
    padding: 11px 14px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.04);
    color: white;
    font-weight: 600;
}

.contact-form form {
    display: grid;
    gap: 16px;
}

.field {
    display: grid;
    gap: 8px;
}

.field label {
    font-weight: 600;
    color: #f5eeff;
}

.field input,
.field textarea {
    width: 100%;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.08);
    color: white;
    border-radius: 14px;
    padding: 15px 16px;
    font: inherit;
    outline: none;
}

.field input::placeholder,
.field textarea::placeholder {
    color: #a69cc0;
}

.field input:focus,
.field textarea:focus {
    border-color: rgba(120, 162, 255, 0.45);
    box-shadow: 0 0 0 3px rgba(120, 162, 255, 0.12);
}

.contact-form button {
    border: 0;
    cursor: pointer;
}

footer {
    border-top: 1px solid rgba(177, 144, 255, 0.12);
    margin-top: 60px;
    padding: 26px 0 34px;
}

.footer-inner {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    align-items: center;
    color: var(--muted);
    flex-wrap: wrap;
}

.footer-links {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
}

.footer-links a:hover {
    color: white;
}

.project-card.new-layout {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 24px;
    align-items: center;
    padding: 24px;
    width: 100%;
}

/* SLIDER */
.project-slider {
    height: 500px;
    overflow: hidden;
    border-radius: 22px;
    position: relative;
    perspective: 1000px;
    /* enables depth */
}

/* PARALLAX BACKGROUND */
.project-slider::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 50% 50%, rgba(0, 255, 200, 0.15), transparent 70%);
    z-index: 0;
    transform: translateZ(-50px) scale(1.2);
}

/* SLIDES */
.slides {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    will-change: transform;
}

.slides img {
    width: 100%;
    height: 500px;
    object-fit: contain;
    flex-shrink: 0;

    /* subtle depth */
    transform: scale(0.96);
    transition: transform 0.4s ease;
}

.slides {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.slides img {
    width: 100%;
    height: 500px;
    object-fit: contain;
    flex-shrink: 0;
}

/* .lazy-img {
    filter: blur(10px);
    transform: scale(1.05);
    transition: filter 0.4s ease, transform 0.4s ease;
}

.lazy-img.loaded {
    filter: blur(0);
    transform: scale(1);
} */

/* RESPONSIVE */
@media (max-width: 820px) {
    .project-card.new-layout {
        grid-template-columns: 1fr;
    }

    .project-slider {
        height: 300px;
    }

    .slides img {
        height: 300px;
    }
}

@media (max-width: 1080px) {

    .hero-grid,
    .contact-wrap,
    .projects-grid {
        grid-template-columns: 1fr 1fr;
    }

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

    .hero-card {
        max-width: 760px;
    }
}

@media (max-width: 820px) {
    .nav {
        min-height: auto;
        padding: 14px 0;
        flex-wrap: wrap;
    }

    .menu-btn {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .nav-links {
        width: 100%;
        display: none;
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
        padding: 18px;
        border-radius: 18px;
        background: rgba(255, 255, 255, 0.04);
        border: 1px solid rgba(255, 255, 255, 0.08);
    }

    .nav-links.show {
        display: flex;
    }

    .stats,
    .skills-grid,
    .projects-grid,
    .contact-wrap {
        grid-template-columns: 1fr;
    }

    .experience-head {
        flex-direction: column;
    }

    .experience-meta {
        text-align: left;
    }

    .project-slider {
        height: 500px;
        overflow: hidden;
        border-radius: 20px;
        position: relative;
    }

    .slides {
        display: flex;
        flex-direction: column;
    }

    .slides img {
        width: 100%;
        height: 500px;
        object-fit: contain;
        flex-shrink: 0;
    }
}


@media (max-width: 560px) {
    .container {
        width: min(100% - 20px, var(--container));
    }

    .hero {
        padding-top: 42px;
    }

    .section {
        padding-top: 88px;
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    .section-title {
        font-size: 2.15rem;
    }

    .about-card,
    .experience-card,
    .contact-wrap,
    .project-body,
    .hero-card {
        padding: 20px;
    }

    .project-desc {
        min-height: auto;
    }

    .hero-actions .btn {
        width: 100%;
    }

    .footer-inner {
        flex-direction: column;
        align-items: flex-start;
    }
}