/* ===== Base ===== */
:root {
    color-scheme: dark;
    --bg: #0b1120;
    --surface: #111a2d;
    --surface-raised: #162137;
    --border: #26344c;
    --text: #edf3ff;
    --muted: #a4b2c9;
    --accent: #8bafff;
    --green: #8de0bc;
    --radius: 18px;
    --container: 1080px;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}
html {
    scroll-behavior: smooth;
    scroll-padding-top: 90px;
}
body {
    margin: 0;
    background:
        radial-gradient(
            ellipse at 85% 0%,
            rgba(66, 104, 184, 0.15),
            transparent 34rem
        ),
        var(--bg);
    color: var(--text);
    font-family:
        "Inter",
        system-ui,
        -apple-system,
        sans-serif;
    font-size: 16px;
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}
a {
    color: inherit;
    text-decoration: none;
}
a:focus-visible {
    outline: 3px solid var(--accent);
    outline-offset: 5px;
    border-radius: 4px;
}
.container {
    width: min(var(--container), calc(100% - 48px));
    margin-inline: auto;
}
h1,
h2,
h3,
p {
    margin-top: 0;
}

/* ===== Header ===== */
.site-header {
    position: sticky;
    top: 0;
    z-index: 10;
    background: rgba(11, 17, 32, 0.88);
    border-bottom: 1px solid rgba(38, 52, 76, 0.8);
    backdrop-filter: blur(16px);
}
.nav {
    min-height: 76px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}
.brand {
    font-size: 1rem;
    font-weight: 800;
    letter-spacing: -0.04em;
}
.brand span {
    color: var(--accent);
}
.nav-links {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 28px;
}
.nav-links a {
    color: var(--muted);
    font-size: 0.9rem;
    transition: color 180ms ease;
}
.nav-links a:hover {
    color: var(--text);
}

/* ===== Hero ===== */
.hero {
    padding-block: 112px 96px;
    max-width: 850px;
}
.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--green);
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}
.eyebrow::before {
    content: "";
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: currentColor;
}
h1 {
    max-width: 820px;
    margin-block: 24px;
    font-size: clamp(2.8rem, 7vw, 5.3rem);
    line-height: 1.06;
    letter-spacing: -0.075em;
}
.gradient-text {
    color: var(--accent);
    background: linear-gradient(100deg, #a8c4ff, #7b9fff 65%, #b8a6ff);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}
.hero-copy {
    max-width: 660px;
    color: var(--muted);
    font-size: clamp(1.05rem, 2vw, 1.2rem);
    line-height: 1.85;
}
.hero-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 14px;
    margin-top: 32px;
}
.button {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    min-height: 48px;
    padding: 12px 19px;
    border: 1px solid var(--border);
    border-radius: 10px;
    font-size: 0.92rem;
    font-weight: 600;
    transition:
        transform 180ms ease,
        background 180ms ease,
        border-color 180ms ease;
}
.button:hover {
    transform: translateY(-2px);
}
.button-primary {
    color: #0b1120;
    background: var(--accent);
    border-color: var(--accent);
}
.button-primary:hover {
    background: #b0c8ff;
}
.button-secondary {
    color: var(--text);
    background: rgba(17, 26, 45, 0.6);
}
.button-secondary:hover {
    border-color: #506789;
    background: var(--surface-raised);
}

/* ===== Sections ===== */
.section {
    padding-block: 38px 54px;
}
.section-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 28px;
}
.section-kicker {
    display: block;
    margin-bottom: 8px;
    color: var(--accent);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}
h2 {
    margin-bottom: 0;
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    line-height: 1.2;
    letter-spacing: -0.055em;
}
.section-intro {
    max-width: 540px;
    margin: 12px 0 0;
    color: var(--muted);
}

/* ===== Project cards ===== */
.project-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
}
.project-card {
    min-width: 0;
    overflow: hidden;
    background: linear-gradient(
        145deg,
        rgba(22, 33, 55, 0.92),
        rgba(17, 26, 45, 0.96)
    );
    border: 1px solid var(--border);
    border-radius: var(--radius);
    transition:
        transform 200ms ease,
        border-color 200ms ease;
}
.project-card:hover {
    transform: translateY(-4px);
    border-color: #455b7e;
}
.project-visual {
    min-height: 220px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 28px;
    overflow: hidden;
    border-bottom: 1px solid var(--border);
}
.visual-corporate {
    background:
        radial-gradient(
            circle at 80% 15%,
            rgba(123, 159, 255, 0.22),
            transparent 40%
        ),
        #111a2d;
}
.visual-dashboard {
    background:
        radial-gradient(
            circle at 20% 80%,
            rgba(141, 224, 188, 0.13),
            transparent 42%
        ),
        #101a2b;
}
.mock-window {
    width: 100%;
    max-width: 390px;
    overflow: hidden;
    background: #0b1120;
    border: 1px solid #33435d;
    border-radius: 12px;
    box-shadow: 0 18px 48px rgba(0, 0, 0, 0.25);
}
.mock-toolbar {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 11px 13px;
    border-bottom: 1px solid #26344c;
}
.mock-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #64748b;
}
.mock-content {
    padding: 20px;
}
.mock-label {
    color: var(--accent);
    font-size: 0.66rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}
.mock-title {
    margin: 7px 0 14px;
    font-size: 1.25rem;
    font-weight: 800;
    letter-spacing: -0.05em;
}
.mock-lines {
    display: grid;
    gap: 7px;
}
.mock-line {
    height: 5px;
    border-radius: 6px;
    background: #26344c;
}
.mock-line.short {
    width: 58%;
}
.mock-panels {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-top: 18px;
}
.mock-panel {
    min-height: 34px;
    background: #192943;
    border: 1px solid #2d4161;
    border-radius: 6px;
}
.chart-preview {
    display: flex;
    align-items: end;
    justify-content: center;
    gap: 10px;
    height: 94px;
    padding: 14px;
    margin-top: 14px;
    border: 1px solid #26344c;
    border-radius: 8px;
    background: #111a2d;
}
.chart-bar {
    width: 11%;
    max-width: 24px;
    border-radius: 4px 4px 0 0;
    background: linear-gradient(to top, #547ee1, #8bafff);
}
.bar-1 {
    height: 35%;
}
.bar-2 {
    height: 60%;
}
.bar-3 {
    height: 45%;
}
.bar-4 {
    height: 82%;
}
.bar-5 {
    height: 66%;
}
.bar-6 {
    height: 94%;
}
.bar-7 {
    height: 72%;
}
.project-body {
    padding: 24px;
}
.project-type {
    color: var(--green);
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}
.project-body h3 {
    margin: 8px 0;
    font-size: 1.3rem;
    letter-spacing: -0.035em;
}
.project-body p {
    min-height: 56px;
    margin-bottom: 18px;
    color: var(--muted);
    font-size: 0.93rem;
}
.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 22px;
}
.tag {
    padding: 5px 9px;
    color: #c7d5ed;
    background: rgba(139, 175, 255, 0.08);
    border: 1px solid rgba(139, 175, 255, 0.15);
    border-radius: 6px;
    font-size: 0.75rem;
}
.project-links {
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
}
.text-link {
    color: var(--accent);
    font-size: 0.9rem;
    font-weight: 600;
}
.text-link:hover {
    color: #c0d3ff;
}

/* ===== About and skills ===== */
.about-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 24px;
    align-items: start;
}
.about-copy,
.focus-card {
    padding: 28px;
    background: rgba(17, 26, 45, 0.72);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}
.about-copy p {
    color: var(--muted);
}
.about-copy p:last-child {
    margin-bottom: 0;
}
.focus-card h3 {
    margin-bottom: 16px;
    font-size: 1.05rem;
}
.focus-list {
    display: grid;
    gap: 15px;
    margin: 0;
    padding: 0;
    list-style: none;
}
.focus-list li {
    display: flex;
    align-items: start;
    gap: 11px;
    color: var(--muted);
    font-size: 0.92rem;
}
.focus-list li::before {
    content: "↗";
    color: var(--green);
    font-weight: 700;
}
.skills {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}
.skill-group {
    padding: 22px;
    background: rgba(17, 26, 45, 0.72);
    border: 1px solid var(--border);
    border-radius: 14px;
}
.skill-group h3 {
    margin-bottom: 12px;
    font-size: 0.98rem;
}
.skill-group p {
    margin-bottom: 0;
    color: var(--muted);
    font-size: 0.9rem;
}
.history-note {
    padding: 24px 26px;
    background: rgba(17, 26, 45, 0.5);
    border: 1px solid var(--border);
    border-left: 3px solid #627ca8;
    border-radius: 12px;
}
.history-note h3 {
    margin-bottom: 8px;
    font-size: 1.05rem;
}
.history-note p {
    margin-bottom: 0;
    color: var(--muted);
    font-size: 0.93rem;
}

/* ===== Contact and footer ===== */
.contact-panel {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 28px;
    padding: clamp(26px, 5vw, 48px);
    background:
        radial-gradient(
            ellipse at 100% 0%,
            rgba(94, 143, 255, 0.15),
            transparent 60%
        ),
        var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}
.contact-panel h2 {
    margin-bottom: 12px;
}
.contact-panel p {
    max-width: 560px;
    margin-bottom: 0;
    color: var(--muted);
}
.footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding-block: 32px;
    margin-top: 30px;
    border-top: 1px solid var(--border);
    color: var(--muted);
    font-size: 0.85rem;
}
.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}
.footer-links a:hover {
    color: var(--text);
}

/* ===== Responsive ===== */
@media (max-width: 760px) {
    .hero {
        padding-block: 82px 70px;
    }
    .project-grid,
    .about-grid {
        grid-template-columns: 1fr;
    }
    .skills {
        grid-template-columns: 1fr;
    }
    .project-body p {
        min-height: 0;
    }
    .contact-panel {
        align-items: center;
        flex-direction: column;
        text-align: center;
    }
    .contact-panel .button {
        align-self: center;
    }
}
@media (max-width: 520px) {
    .container {
        width: min(100% - 32px, var(--container));
    }
    .nav {
        min-height: 70px;
        align-items: center;
        flex-direction: column;
        justify-content: center;
        gap: 8px;
        padding-block: 12px;
    }
    .nav-links {
        justify-content: center;
        gap: 18px;
    }
    .hero {
        padding-block: 65px 55px;
        text-align: center;
    }
    .hero .eyebrow {
        justify-content: center;
    }
    h1 {
        font-size: clamp(2.5rem, 12vw, 3.6rem);
    }
    .hero-actions {
        justify-content: center;
        align-items: center;
    }
    .hero-actions .button {
        min-width: 190px;
    }
    .section {
        padding-block: 28px 42px;
    }
    .section-heading {
        align-items: flex-start;
        flex-direction: column;
    }
    .project-visual {
        min-height: 190px;
        padding: 20px;
    }
    .project-body,
    .about-copy,
    .focus-card {
        padding: 21px;
    }
    .contact-panel {
        align-items: center;
        text-align: center;
    }
    .contact-panel .button {
        align-self: center;
    }
    .footer {
        align-items: center;
        flex-direction: column;
        text-align: center;
    }
    .footer-links {
        justify-content: center;
    }
}
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }
}
