:root {
    --bg: #0a0d12;
    --bg-soft: #0f141b;
    --panel: #131a23;
    --panel-2: #171f2a;
    --text: #f5f7fa;
    --muted: #9aa6b5;
    --line: #263140;
    --accent: #66a8ff;
    --accent-2: #7fc7ff;
    --max-width: 1180px;
    --radius: 18px;
    --shadow: 0 24px 70px rgba(0, 0, 0, 0.22);
}

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

html {
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    background:
        radial-gradient(circle at top left, rgba(56, 115, 188, 0.12), transparent 34%),
        var(--bg);
    color: var(--text);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    opacity: 0.32;
    background-image: linear-gradient(rgba(255,255,255,0.012) 1px, transparent 1px),
                      linear-gradient(90deg, rgba(255,255,255,0.012) 1px, transparent 1px);
    background-size: 48px 48px;
    mask-image: linear-gradient(to bottom, black, transparent 70%);
}

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

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

.section-shell,
.nav-shell {
    width: min(calc(100% - 40px), var(--max-width));
    margin: 0 auto;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: blur(18px);
    background: rgba(10, 13, 18, 0.82);
    border-bottom: 1px solid rgba(255,255,255,0.06);
}

.nav-shell {
    min-height: 74px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 28px;
}

.brand {
    font-size: 1rem;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 26px;
}

.site-nav a {
    color: var(--muted);
    font-size: 0.94rem;
    font-weight: 600;
    transition: color 160ms ease, background 160ms ease, border-color 160ms ease;
}

.site-nav a:hover,
.site-nav a.active {
    color: var(--text);
}

.site-nav .nav-cta {
    padding: 9px 15px;
    border: 1px solid var(--line);
    border-radius: 999px;
    color: var(--text);
}

.site-nav .nav-cta:hover,
.site-nav .nav-cta.active {
    border-color: rgba(102,168,255,0.6);
    background: rgba(102,168,255,0.08);
}

.hero {
    min-height: 78vh;
    display: grid;
    grid-template-columns: 1.35fr 0.85fr;
    gap: 70px;
    align-items: center;
    padding-top: 96px;
    padding-bottom: 96px;
}

.eyebrow,
.project-type,
.contact-label,
.card-label {
    color: var(--accent-2);
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.hero h1,
.page-hero h1,
.contact-intro h1 {
    margin-top: 16px;
    font-size: clamp(3.2rem, 7vw, 6.5rem);
    line-height: 0.96;
    letter-spacing: -0.06em;
    max-width: 900px;
}

.hero-text,
.page-hero > p:last-child,
.contact-intro > p:last-child {
    margin-top: 28px;
    max-width: 720px;
    color: var(--muted);
    font-size: 1.15rem;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 34px;
}

.project-links {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    margin-top: 22px;
}

.small-button {
    min-height: 42px;
    padding: 0 16px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: rgba(255,255,255,0.035);
    color: var(--text);
    font-size: 0.88rem;
}

.small-button:hover {
    border-color: rgba(102, 168, 255, 0.6);
    background: rgba(102, 168, 255, 0.08);
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0 20px;
    border-radius: 12px;
    font-weight: 800;
    transition: transform 160ms ease, border-color 160ms ease, background 160ms ease;
}

.button:hover {
    transform: translateY(-2px);
}

.button.primary {
    background: var(--text);
    color: #0b0f14;
}

.button.secondary {
    border: 1px solid var(--line);
    background: rgba(255,255,255,0.02);
}

.skill-row,
.tag-list,
.plain-list {
    list-style: none;
}

.skill-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 34px;
}

.skill-row li,
.tag-list span {
    padding: 7px 10px;
    border: 1px solid var(--line);
    border-radius: 999px;
    color: #bdc8d6;
    background: rgba(255,255,255,0.02);
    font-size: 0.82rem;
    font-weight: 700;
}

.hero-card {
    position: relative;
    padding: 34px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: linear-gradient(180deg, rgba(255,255,255,0.035), rgba(255,255,255,0.018));
    box-shadow: var(--shadow);
    overflow: hidden;
}

.hero-card::after {
    content: "";
    position: absolute;
    width: 180px;
    height: 180px;
    right: -80px;
    top: -80px;
    border-radius: 50%;
    background: rgba(102,168,255,0.12);
    filter: blur(4px);
}

.hero-card-topline {
    width: 52px;
    height: 3px;
    border-radius: 999px;
    background: var(--accent);
    margin-bottom: 36px;
}

.hero-card h2 {
    margin-top: 12px;
    font-size: 1.9rem;
    line-height: 1.15;
    letter-spacing: -0.03em;
}

.hero-card p:not(.card-label) {
    color: var(--muted);
    margin-top: 18px;
}

.availability {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 28px;
    padding-top: 24px;
    border-top: 1px solid var(--line);
    color: #c7d1dc;
    font-size: 0.93rem;
}

.status-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: #57d58b;
    box-shadow: 0 0 16px rgba(87,213,139,0.5);
}

.section-block {
    padding-top: 110px;
    padding-bottom: 110px;
}

.section-heading {
    max-width: 720px;
    margin-bottom: 36px;
}

.section-heading h2,
.about-grid h2,
.cta-panel h2,
.case-study h2 {
    margin-top: 10px;
    font-size: clamp(2.1rem, 4vw, 3.6rem);
    line-height: 1.04;
    letter-spacing: -0.045em;
}

.section-heading > p:last-child {
    color: var(--muted);
    margin-top: 18px;
}

.split-heading {
    max-width: none;
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 30px;
}

.text-link {
    color: var(--accent-2);
    font-weight: 800;
}

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

.project-card {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    background: rgba(255,255,255,0.025);
}

.project-visual {
    min-height: 270px;
    display: flex;
    align-items: end;
    padding: 26px;
    position: relative;
    overflow: hidden;
}

.project-visual::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(to top, rgba(5,8,12,0.84), rgba(5,8,12,0.05)),
        linear-gradient(135deg, rgba(255,255,255,0.06), transparent 35%);
}

.project-visual span {
    position: relative;
    z-index: 1;
    font-size: 1.35rem;
    font-weight: 900;
}


.project-visual img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.project-video {
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border-radius: 16px;
    background: #000;
}

.project-video iframe {
    width: 100%;
    height: 100%;
    display: block;
    border: 0;
}


.visual-engine {
    background:
        radial-gradient(circle at 70% 28%, rgba(89,198,255,0.38), transparent 22%),
        linear-gradient(145deg, #15202c, #0b1016 55%, #102a37);
}

.project-content {
    padding: 28px;
}

.project-content h3 {
    margin-top: 8px;
    font-size: 1.65rem;
    letter-spacing: -0.03em;
}

.project-content p:not(.project-type) {
    color: var(--muted);
    margin-top: 12px;
}

.project-note {
    margin-top: 15px;
    font-size: 0.9rem;
    line-height: 1.6;
    color: #aeb7c6;
    font-style: italic;
}

.project-note strong {
    color: #ffffff;
    font-style: normal;
}

.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 22px 0;
}

.tech-section {
    border-top: 1px solid rgba(255,255,255,0.06);
}

.feature-grid,
.detail-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
}

.feature-card,
.detail-card {
    min-height: 230px;
    padding: 26px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: rgba(255,255,255,0.02);
}

.feature-number {
    color: var(--accent);
    font-weight: 900;
    font-size: 0.8rem;
}

.feature-card h3,
.detail-card h3 {
    margin-top: 28px;
    font-size: 1.15rem;
}

.feature-card p,
.detail-card p {
    margin-top: 12px;
    color: var(--muted);
    font-size: 0.95rem;
}

.about-grid {
    display: grid;
    grid-template-columns: 0.85fr 1.15fr;
    gap: 80px;
    align-items: start;
    border-top: 1px solid rgba(255,255,255,0.06);
}

.about-copy p {
    color: var(--muted);
    margin-bottom: 18px;
    font-size: 1.05rem;
}

.about-copy .text-link {
    display: inline-block;
    margin-top: 8px;
}

.cta-panel {
    margin-top: 40px;
    margin-bottom: 110px;
    padding: 42px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 40px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: linear-gradient(135deg, rgba(102,168,255,0.08), rgba(255,255,255,0.02));
}

.cta-panel h2 {
    max-width: 760px;
    font-size: clamp(1.8rem, 3vw, 3rem);
}

.page-hero {
    padding-top: 110px;
    padding-bottom: 20px;
}

.page-hero h1,
.contact-intro h1 {
    max-width: 980px;
    font-size: clamp(3.4rem, 7vw, 6rem);
}

.case-study {
    padding-top: 44px;
    padding-bottom: 110px;
}

.case-grid {
    display: grid;
    grid-template-columns: 1.3fr 0.7fr;
    gap: 70px;
    margin-bottom: 42px;
}

.case-grid h3 {
    font-size: 1.3rem;
    margin-bottom: 14px;
}

.case-grid p {
    color: var(--muted);
    margin-bottom: 16px;
}

.case-stats {
    border: 1px solid var(--line);
    border-radius: 16px;
    overflow: hidden;
}

.case-stats div {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    padding: 18px 20px;
    border-bottom: 1px solid var(--line);
}

.case-stats div:last-child {
    border-bottom: 0;
}

.case-stats span {
    color: var(--muted);
}

.case-stats strong {
    text-align: right;
}

.detail-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.divider-top {
    border-top: 1px solid rgba(255,255,255,0.06);
    padding-top: 110px;
}

.project-cta {
    margin-top: 0;
}

.resume-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 70px;
    padding-bottom: 110px;
}

.resume-sidebar {
    position: sticky;
    top: 110px;
    align-self: start;
}

.sidebar-block {
    padding: 22px 0;
    border-bottom: 1px solid var(--line);
}

.sidebar-block:first-child {
    padding-top: 0;
}

.sidebar-block h3 {
    margin-top: 8px;
    font-size: 1.08rem;
}

.sidebar-block p {
    color: var(--muted);
    margin-top: 8px;
}

.muted {
    opacity: 0.72;
}

.plain-list li {
    color: #c2ccd7;
    margin: 8px 0;
}

.compact-heading {
    margin-bottom: 12px;
}

.timeline-item {
    display: grid;
    grid-template-columns: 150px 1fr;
    gap: 34px;
    padding: 34px 0;
    border-bottom: 1px solid var(--line);
}

.timeline-meta {
    color: var(--muted);
    font-size: 0.9rem;
    padding-top: 5px;
}

.timeline-content h3 {
    font-size: 1.45rem;
    letter-spacing: -0.02em;
}

.company {
    color: var(--accent-2) !important;
    font-weight: 800;
    margin-top: 2px !important;
}

.timeline-content > p {
    color: var(--muted);
    margin-top: 12px;
}

.experience-list {
    margin-top: 18px;
    padding-left: 20px;
    color: #c1cad5;
}

.experience-list li {
    margin-bottom: 9px;
}

.contact-page {
    min-height: calc(100vh - 220px);
    display: grid;
    align-content: center;
    padding-top: 100px;
    padding-bottom: 120px;
}

.contact-intro {
    max-width: 800px;
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    margin-top: 58px;
}

.contact-card {
    min-height: 180px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: rgba(255,255,255,0.025);
    transition: transform 160ms ease, border-color 160ms ease, background 160ms ease;
}

.contact-card:hover {
    transform: translateY(-4px);
    border-color: rgba(102,168,255,0.55);
    background: rgba(102,168,255,0.05);
}

.contact-card strong {
    font-size: 1.1rem;
    word-break: break-word;
}

.contact-arrow {
    align-self: flex-end;
    color: var(--accent-2);
    font-size: 1.35rem;
}

.site-footer {
    border-top: 1px solid rgba(255,255,255,0.06);
    background: rgba(255,255,255,0.012);
}

.footer-grid {
    min-height: 150px;
    display: grid;
    grid-template-columns: 1fr auto auto;
    gap: 50px;
    align-items: center;
}

.footer-grid p {
    color: var(--muted);
    font-size: 0.9rem;
}

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

.footer-links a {
    color: #c1cad5;
    font-size: 0.92rem;
}

.footer-links a:hover {
    color: var(--text);
}

.copyright {
    white-space: nowrap;
}

@media (max-width: 980px) {
    .hero,
    .about-grid,
    .case-grid,
    .resume-layout {
        grid-template-columns: 1fr;
    }

    .hero {
        min-height: auto;
        gap: 40px;
    }

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

    .feature-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .resume-sidebar {
        position: static;
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
    }

    .sidebar-block {
        border: 1px solid var(--line);
        border-radius: 14px;
        padding: 20px !important;
    }

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

    .contact-card {
        min-height: 140px;
    }
}

@media (max-width: 760px) {
    .nav-shell {
        min-height: 68px;
    }

    .site-nav {
        gap: 14px;
    }

    .site-nav a:not(.nav-cta) {
        display: none;
    }

    .hero,
    .page-hero,
    .contact-page {
        padding-top: 76px;
    }

    .hero {
        padding-bottom: 72px;
    }

    .hero h1,
    .page-hero h1,
    .contact-intro h1 {
        font-size: clamp(3rem, 14vw, 4.8rem);
    }

    .project-grid,
    .detail-grid,
    .feature-grid {
        grid-template-columns: 1fr;
    }

    .split-heading,
    .cta-panel,
    .footer-grid {
        align-items: flex-start;
        flex-direction: column;
    }

    .split-heading {
        display: flex;
    }

    .timeline-item {
        grid-template-columns: 1fr;
        gap: 6px;
    }

    .resume-sidebar {
        grid-template-columns: 1fr;
    }

    .cta-panel {
        display: flex;
        padding: 28px;
    }

    .footer-grid {
        display: flex;
        min-height: auto;
        padding-top: 34px;
        padding-bottom: 34px;
        gap: 18px;
    }

    .footer-links {
        flex-wrap: wrap;
    }
}

@media (max-width: 480px) {
    .section-shell,
    .nav-shell {
        width: min(calc(100% - 28px), var(--max-width));
    }

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

    .button {
        width: 100%;
    }

    .section-block,
    .divider-top {
        padding-top: 78px;
        padding-bottom: 78px;
    }

    .case-study {
        padding-bottom: 78px;
    }
}

.project-wip {
    max-width: 1200px;
    margin: 80px auto;
    padding: 0 40px;
}

/* Project Header */
.project-header {
    margin-bottom: 30px;
}

.project-type {
    color: #f59e42;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 12px;
}

.project-header h2 {
    color: #ffffff;
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    font-weight: 700;
    margin-bottom: 20px;
    line-height: 1.2;
}

/* Technology Tags */
.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 10px;
}

.project-tags span {
    background: #252a35;
    color: #cdd3df;
    padding: 7px 14px;
    border: 1px solid #353c49;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 500;
}

/* Project Hero Image */
.project-hero {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: 10px;
    overflow: hidden;
    background: #101218;
    border: 1px solid #353c49;
    margin-bottom: 30px;
}

.project-hero img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform 0.3s ease;
}

.project-hero:hover img {
    transform: scale(1.02);
}

/* Work in Progress Badge */
.wip-badge {
    position: absolute;
    top: 20px;
    right: 20px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 15px;
    background: rgba(20, 23, 30, 0.92);
    color: #f59e42;
    border: 1px solid rgba(245, 158, 66, 0.45);
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    z-index: 2;
}

/* Small Status Indicator */
.wip-badge::before {
    content: "";
    width: 7px;
    height: 7px;
    background: #f59e42;
    border-radius: 50%;
    flex-shrink: 0;
}

/* Project Description */
.project-overview {
    max-width: 850px;
}

.project-overview p {
    color: #b8bfcc;
    font-size: 1rem;
    line-height: 1.8;
    margin-bottom: 18px;
}

.project-overview p:last-child {
    margin-bottom: 0;
}

.project-overview strong {
    color: #ffffff;
    font-weight: 600;
}

/* Tablet */
@media (max-width: 768px) {
    .project-wip {
        margin: 50px 20px;
        padding: 25px;
    }

    .project-wip .project-hero {
        margin-bottom: 24px;
    }

    .wip-badge {
        top: 12px;
        right: 12px;
        padding: 7px 10px;
        font-size: 0.65rem;
    }

    .project-overview p {
        font-size: 0.95rem;
        line-height: 1.7;
    }
}

/* Mobile */
@media (max-width: 480px) {
    .project-wip {
        margin: 35px 15px;
        padding: 20px;
    }

    .project-header h2 {
        font-size: 1.65rem;
    }

    .project-type {
        font-size: 0.7rem;
        letter-spacing: 1.3px;
    }

    .project-tags span {
        padding: 6px 10px;
        font-size: 0.75rem;
    }

    .project-hero {
        aspect-ratio: 4 / 3;
    }

    .project-wip .wip-badge {
        top: 10px;
        right: 10px;
    }
}

/* Accessibility: Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    .project-hero img {
        transition: none;
    }

    .project-hero:hover img {
        transform: none;
    }
}
