:root {
    --bg: #020617;
    --bg-soft: #0f172a;
    --surface: rgba(15, 23, 42, 0.78);
    --surface-solid: #111827;
    --text: #f8fafc;
    --muted: #94a3b8;
    --border: rgba(148, 163, 184, 0.16);

    --primary: #38bdf8;
    --primary-2: #22c55e;
    --accent: #f59e0b;

    --gradient: linear-gradient(135deg, #38bdf8, #22c55e, #f59e0b);
    --shadow: 0 24px 70px rgba(0, 0, 0, 0.35);

    --radius-xl: 32px;
    --radius-lg: 24px;
    --radius-md: 18px;
}

[data-theme="light"] {
    --bg: #f8fafc;
    --bg-soft: #eef6ff;
    --surface: rgba(255, 255, 255, 0.86);
    --surface-solid: #ffffff;
    --text: #0f172a;
    --muted: #64748b;
    --border: rgba(15, 23, 42, 0.1);
    --shadow: 0 24px 70px rgba(15, 23, 42, 0.12);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: "Inter", sans-serif;
    background: var(--bg);
    color: var(--text);
    overflow-x: hidden;
}

a {
    color: inherit;
}

.container {
    width: min(1120px, calc(100% - 32px));
    margin: 0 auto;
}

.portfolio-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 18px 0;
    transition: 0.25s ease;
}

.portfolio-header.is-scrolled {
    background: rgba(2, 6, 23, 0.78);
    backdrop-filter: blur(18px);
    border-bottom: 1px solid var(--border);
    padding: 12px 0;
}

[data-theme="light"] .portfolio-header.is-scrolled {
    background: rgba(255, 255, 255, 0.82);
}

.portfolio-nav {
    width: min(1120px, calc(100% - 32px));
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.brand-mark {
    width: 46px;
    height: 46px;
    border-radius: 16px;
    background: var(--gradient);
    color: #020617;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    box-shadow: 0 12px 34px rgba(56, 189, 248, 0.22);
}

.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.brand-text strong {
    font-weight: 900;
}

.brand-text small {
    color: var(--muted);
    font-size: 0.76rem;
    font-weight: 700;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-menu a,
.theme-toggle {
    border: 0;
    background: transparent;
    color: var(--muted);
    text-decoration: none;
    font-weight: 800;
    font-size: 0.92rem;
    padding: 10px 14px;
    border-radius: 999px;
    transition: 0.2s ease;
}

.nav-menu a:hover,
.theme-toggle:hover {
    color: var(--text);
    background: rgba(148, 163, 184, 0.12);
}

.nav-menu .nav-cta {
    background: var(--gradient);
    color: #020617;
    box-shadow: 0 12px 28px rgba(34, 197, 94, 0.18);
}

.nav-toggle {
    display: none;
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text);
    width: 44px;
    height: 44px;
    border-radius: 14px;
    font-size: 1.55rem;
}

.hero-section {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 140px 0 80px;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 20% 20%, rgba(56, 189, 248, 0.18), transparent 36%),
        radial-gradient(circle at 90% 15%, rgba(34, 197, 94, 0.13), transparent 32%),
        radial-gradient(circle at 50% 90%, rgba(245, 158, 11, 0.13), transparent 36%);
    pointer-events: none;
}

.hero-grid {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    align-items: center;
    gap: 56px;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 14px;
    border-radius: 999px;
    background: rgba(56, 189, 248, 0.09);
    border: 1px solid var(--border);
    color: var(--primary);
    font-weight: 900;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.hero-content h1,
.section-head h2,
.contact-card h2 {
    font-family: "Plus Jakarta Sans", sans-serif;
    letter-spacing: -0.055em;
}

.hero-content h1 {
    margin: 22px 0;
    font-size: clamp(2.7rem, 6vw, 5.45rem);
    line-height: 0.98;
    font-weight: 900;
}

.hero-content h1 span,
.sas-gradient-text {
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-content p {
    max-width: 680px;
    color: var(--muted);
    font-size: 1.08rem;
    line-height: 1.85;
}

.hero-actions,
.contact-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 30px;
}

.btn-primary,
.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    border-radius: 999px;
    padding: 14px 22px;
    font-weight: 900;
    text-decoration: none;
    transition: 0.22s ease;
}

.btn-primary {
    background: var(--gradient);
    color: #020617;
    box-shadow: 0 16px 40px rgba(56, 189, 248, 0.2);
}

.btn-secondary {
    background: var(--surface);
    border: 1px solid var(--border);
    color: var(--text);
}

.btn-primary:hover,
.btn-secondary:hover {
    transform: translateY(-3px);
}

.hero-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin-top: 40px;
}

.hero-stats div {
    min-width: 130px;
    padding: 18px;
    border-radius: var(--radius-md);
    background: var(--surface);
    border: 1px solid var(--border);
}

.hero-stats strong {
    display: block;
    font-size: 1.65rem;
    font-weight: 900;
}

.hero-stats span {
    display: block;
    color: var(--muted);
    font-size: 0.84rem;
    font-weight: 700;
    margin-top: 4px;
}

.hero-card {
    display: flex;
    justify-content: center;
}

.profile-card {
    width: min(390px, 100%);
    border-radius: var(--radius-xl);
    background: var(--surface);
    border: 1px solid var(--border);
    padding: 32px;
    box-shadow: var(--shadow);
    backdrop-filter: blur(18px);
}

.profile-avatar {
    width: 110px;
    height: 110px;
    border-radius: 32px;
    background: var(--gradient);
    color: #020617;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.4rem;
    font-weight: 900;
    margin-bottom: 24px;
}

.profile-card h2 {
    margin: 0;
    font-size: 1.75rem;
    font-weight: 900;
}

.profile-card p {
    color: var(--muted);
    margin: 8px 0 20px;
}

.profile-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.profile-tags span,
.skill-list span {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 8px 12px;
    background: rgba(148, 163, 184, 0.1);
    border: 1px solid var(--border);
    color: var(--muted);
    font-size: 0.84rem;
    font-weight: 800;
}

.profile-panel {
    margin-top: 24px;
    border-radius: var(--radius-md);
    padding: 18px;
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.18);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.profile-panel small {
    display: block;
    color: var(--muted);
    font-weight: 800;
}

.profile-panel strong {
    display: block;
    margin-top: 4px;
}

.profile-panel i {
    color: #22c55e;
    font-size: 1.5rem;
}

.section {
    padding: 96px 0;
}

.section-soft {
    background:
        linear-gradient(180deg, transparent, rgba(148, 163, 184, 0.045), transparent);
}

.section-head {
    max-width: 760px;
    margin-bottom: 46px;
}

.section-head h2,
.contact-card h2 {
    font-size: clamp(2rem, 4vw, 3.45rem);
    line-height: 1.08;
    margin: 18px 0 14px;
    font-weight: 900;
}

.section-head p,
.contact-card p {
    color: var(--muted);
    line-height: 1.85;
    font-size: 1.03rem;
}

.about-grid,
.project-grid,
.service-grid {
    display: grid;
    gap: 22px;
}

.about-grid {
    grid-template-columns: repeat(3, 1fr);
}

.project-grid {
    grid-template-columns: repeat(3, 1fr);
}

.service-grid {
    grid-template-columns: repeat(4, 1fr);
}

.about-card,
.project-card,
.service-card,
.contact-card {
    border-radius: var(--radius-lg);
    background: var(--surface);
    border: 1px solid var(--border);
    box-shadow: 0 14px 38px rgba(0, 0, 0, 0.12);
}

.about-card,
.service-card {
    padding: 28px;
}

.about-card h3,
.project-card h3,
.service-card h3 {
    margin: 0 0 12px;
    font-weight: 900;
}

.about-card p,
.project-card p,
.service-card p {
    color: var(--muted);
    line-height: 1.78;
    margin: 0;
}

.skill-list {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.project-card {
    padding: 28px;
    transition: 0.22s ease;
}

.project-card:hover,
.service-card:hover,
.about-card:hover {
    transform: translateY(-6px);
    border-color: rgba(56, 189, 248, 0.26);
}

.project-icon,
.service-card i {
    width: 56px;
    height: 56px;
    border-radius: 18px;
    background: rgba(56, 189, 248, 0.1);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.55rem;
    margin-bottom: 18px;
}

.project-tag {
    display: inline-flex;
    margin-bottom: 12px;
    font-size: 0.72rem;
    font-weight: 900;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.project-card a,
.project-note {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 20px;
    color: var(--primary);
    font-weight: 900;
    text-decoration: none;
}

.service-card i {
    margin-bottom: 18px;
}

.contact-section {
    padding: 90px 0;
}

.contact-card {
    padding: clamp(32px, 6vw, 64px);
    text-align: center;
    background:
        radial-gradient(circle at 20% 20%, rgba(56, 189, 248, 0.14), transparent 30%),
        radial-gradient(circle at 80% 80%, rgba(34, 197, 94, 0.13), transparent 34%),
        var(--surface);
}

.contact-card .eyebrow,
.contact-actions {
    justify-content: center;
}

.portfolio-footer {
    border-top: 1px solid var(--border);
    padding: 64px 0 26px;
    background: var(--bg-soft);
}

.footer-grid,
.footer-bottom {
    width: min(1120px, calc(100% - 32px));
    margin: 0 auto;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 0.7fr 1fr;
    gap: 36px;
}

.footer-brand h3 {
    margin: 0;
    font-weight: 900;
}

.footer-brand p,
.footer-desc {
    color: var(--muted);
}

.footer-desc {
    max-width: 470px;
    line-height: 1.8;
}

.footer-grid h4 {
    margin: 0 0 16px;
}

.footer-grid a {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--muted);
    text-decoration: none;
    font-weight: 700;
    margin-bottom: 12px;
}

.footer-grid a:hover {
    color: var(--primary);
}

.footer-bottom {
    margin-top: 44px;
    padding-top: 24px;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    gap: 18px;
    flex-wrap: wrap;
    color: var(--muted);
    font-size: 0.9rem;
}

.footer-bottom a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 900;
}

@media (max-width: 960px) {
    .nav-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .nav-menu {
        position: absolute;
        top: 74px;
        left: 16px;
        right: 16px;
        display: none;
        flex-direction: column;
        align-items: stretch;
        background: var(--surface-solid);
        border: 1px solid var(--border);
        border-radius: 24px;
        padding: 16px;
        box-shadow: var(--shadow);
    }

    .nav-menu.show {
        display: flex;
    }

    .nav-menu a,
    .theme-toggle {
        width: 100%;
        text-align: left;
    }

    .hero-grid,
    .about-grid,
    .project-grid,
    .service-grid,
    .footer-grid {
        grid-template-columns: 1fr;
    }

    .hero-section {
        padding-top: 120px;
    }
}

@media (max-width: 560px) {
    .hero-actions,
    .contact-actions {
        flex-direction: column;
    }

    .btn-primary,
    .btn-secondary {
        width: 100%;
    }

    .hero-stats {
        display: grid;
        grid-template-columns: 1fr;
    }

    .section {
        padding: 72px 0;
    }

    .profile-card {
        padding: 24px;
    }
}