:root {
    --green: #39ff88;
    --green-dark: #10b15a;
    --green-soft: #ecfff4;
    --green-glow: rgba(57, 255, 136, 0.26);
    --black: #070b08;
    --text: #121713;
    --muted: #66736b;
    --line: #dce8df;
    --white: #ffffff;
    --shadow: 0 28px 90px rgba(7, 11, 8, 0.12);
    --radius-xl: 34px;
    --max-width: 1280px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--text);
    background: radial-gradient(circle at 12% 8%, rgba(57, 255, 136, 0.13), transparent 30%), radial-gradient(circle at 88% 0%, rgba(16, 177, 90, 0.12), transparent 26%), linear-gradient(180deg, #f8fbf8 0%, #ffffff 42%, #f8fbf8 100%);
}

body.overlay-open {
    overflow: hidden;
}

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

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

button {
    font: inherit;
}

button,
a {
    -webkit-tap-highlight-color: transparent;
}

.page-shell {
    width: min(calc(100% - 32px), var(--max-width));
    margin: 0 auto;
    padding: 42px 0 70px;
}

.site-header {
    position: sticky;
    top: 18px;
    z-index: 100;
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: center;
    gap: 18px;
    width: min(100%, 760px);
    margin: 0 auto 22px;
    padding: 13px 14px;
    border: 1px solid rgba(12, 15, 13, 0.08);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.88);
    box-shadow: 0 14px 45px rgba(12, 15, 13, 0.09);
    backdrop-filter: blur(18px);
}

.brand {
    display: grid;
    place-items: center;
    width: 46px;
    height: 34px;
    border-radius: 10px;
    background: var(--green);
    color: #06130a;
    font-weight: 900;
    letter-spacing: -0.06em;
    box-shadow: 0 10px 20px var(--green-glow);
}

.nav-links {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 28px;
    color: #1f2822;
    font-size: 14px;
}

.nav-links a {
    transition: color 160ms ease, transform 160ms ease;
}

.nav-links a:hover {
    color: var(--green-dark);
    transform: translateY(-1px);
}

.nav-toggle {
    display: none;
    justify-self: end;
    position: relative;
    width: 42px;
    height: 38px;
    padding: 0;
    border: 1px solid rgba(12, 15, 13, 0.12);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.92);
    cursor: pointer;
}

.nav-toggle span {
    position: absolute;
    left: 50%;
    width: 19px;
    height: 2px;
    border-radius: 999px;
    background: var(--black);
    transform: translateX(-50%);
    transition: transform 180ms ease, opacity 180ms ease, top 180ms ease;
}

.nav-toggle span:nth-child(1) {
    top: 12px;
}

.nav-toggle span:nth-child(2) {
    top: 18px;
}

.nav-toggle span:nth-child(3) {
    top: 24px;
}

.nav-toggle.open span:nth-child(1) {
    top: 18px;
    transform: translateX(-50%) rotate(45deg);
}

.nav-toggle.open span:nth-child(2) {
    opacity: 0;
}

.nav-toggle.open span:nth-child(3) {
    top: 18px;
    transform: translateX(-50%) rotate(-45deg);
}

.section-card,
.card-shadow {
    border: 1px solid rgba(12, 15, 13, 0.08);
    border-radius: var(--radius-xl);
    background: rgba(255, 255, 255, 0.84);
    box-shadow: var(--shadow);
}

.primary-button,
.ghost-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0 20px;
    border-radius: 14px;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: -0.01em;
    cursor: pointer;
    transition: transform 180ms ease, background 180ms ease, box-shadow 180ms ease;
}

.primary-button {
    border: 0;
    color: #06130a;
    background: var(--green);
    box-shadow: 0 18px 35px var(--green-glow);
}

.primary-button:hover {
    background: #2ee86e;
    transform: translateY(-2px);
}

.ghost-button {
    color: var(--white);
    border: 1px solid rgba(255, 255, 255, 0.18);
    background: rgba(255, 255, 255, 0.08);
}

.ghost-button:hover {
    background: rgba(255, 255, 255, 0.14);
    transform: translateY(-2px);
}

.section-kicker,
.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    width: fit-content;
    padding: 7px 12px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--white);
    color: var(--black);
    font-size: 13px;
    font-weight: 800;
    box-shadow: 0 12px 30px rgba(12, 15, 13, 0.06);
}

.centered,
.section-kicker.centered {
    margin-inline: auto;
}

.section-intro {
    width: min(100%, 740px);
    margin: 18px auto 36px;
    color: var(--muted);
    font-size: 17px;
    line-height: 1.65;
}

code {
    padding: 3px 6px;
    border-radius: 7px;
    background: rgba(57, 255, 136, 0.12);
    color: #174524;
}

.hero {
    position: relative;
    overflow: hidden;
    color: var(--white);
    border: 1px solid rgba(57, 255, 136, 0.18);
    border-radius: var(--radius-xl);
    background: radial-gradient(circle at 50% 8%, rgba(57, 255, 136, 0.24), transparent 36%), radial-gradient(circle at 8% 92%, rgba(16, 177, 90, 0.22), transparent 30%), linear-gradient(145deg, #06120a 0%, #0b1710 42%, #101410 100%);
}

.hero::before,
.hero::after {
    content: "";
    position: absolute;
    border: 1px solid rgba(57, 255, 136, 0.2);
    pointer-events: none;
}

.hero::before {
    width: 520px;
    height: 330px;
    border-radius: 34px;
    transform: rotate(45deg);
}

.hero::after {
    width: 720px;
    height: 430px;
    border-radius: 44px;
    opacity: 0.4;
    transform: rotate(-45deg);
}

.hero-grid-lines {
    position: absolute;
    inset: 0;
    opacity: 0.18;
    background-image: linear-gradient(rgba(57, 255, 136, 0.18) 1px, transparent 1px), linear-gradient(90deg, rgba(57, 255, 136, 0.18) 1px, transparent 1px);
    background-size: 120px 120px;
    mask-image: radial-gradient(circle at center, black, transparent 70%);
}

.hero-showcase {
    min-height: 720px;
    display: grid;
    align-items: center;
    padding: clamp(38px, 6vw, 86px);
}

.hero-showcase-content {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
    align-items: center;
    gap: clamp(32px, 6vw, 86px);
}

.hero-copy-block {
    text-align: left;
}

.hero-copy-block h1 {
    max-width: 860px;
    margin: 0;
    color: var(--white);
    font-size: clamp(54px, 7vw, 104px);
    line-height: 0.94;
    letter-spacing: -0.08em;
}

.hero-copy {
    max-width: 690px;
    margin: 28px 0 0;
    color: rgba(255, 255, 255, 0.72);
    font-size: clamp(18px, 1.6vw, 24px);
    line-height: 1.55;
}

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

.hero-portrait-stack {
    position: relative;
    z-index: 3;
    display: grid;
    justify-items: center;
}

.hero-portrait-card {
    position: relative;
    width: min(100%, 430px);
    margin: 0;
    padding: 18px;
    overflow: hidden;
    border: 1px solid rgba(57, 255, 136, 0.28);
    border-radius: 38px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.06)), rgba(255, 255, 255, 0.08);
    box-shadow: 0 34px 100px rgba(57, 255, 136, 0.14), inset 0 1px 0 rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(18px);
}

.portrait-image-wrap {
    overflow: hidden;
    aspect-ratio: 4 / 5;
    border-radius: 30px;
    background: radial-gradient(circle at 50% 18%, rgba(57, 255, 136, 0.28), transparent 38%), linear-gradient(145deg, rgba(57, 255, 136, 0.18), rgba(255, 255, 255, 0.06));
}

.portrait-image-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
    transform: scale(1.03);
}

.hero-intro-badge {
    position: absolute;
    top: clamp(18px, 3vw, 32px);
    right: clamp(18px, 3vw, 32px);
    z-index: 5;
    display: grid;
    gap: 2px;
    min-width: 190px;
    margin: 0;
    padding: 13px 16px;
    border: 1px solid rgba(57, 255, 136, 0.32);
    border-radius: 20px;
    background: rgba(6, 18, 10, 0.72);
    color: var(--white);
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.28), 0 0 45px rgba(57, 255, 136, 0.12);
    backdrop-filter: blur(18px);
}

.hero-intro-badge span {
    color: var(--green);
    font-size: 13px;
    font-weight: 900;
    line-height: 1;
}

.hero-intro-badge strong {
    color: var(--white);
    font-size: clamp(17px, 1.7vw, 24px);
    font-weight: 900;
    line-height: 1.05;
    letter-spacing: -0.04em;
}

.hero-intro-badge::after {
    content: "";
    position: absolute;
    top: 14px;
    right: 14px;
    width: 9px;
    height: 9px;
    border-radius: 999px;
    background: var(--green);
    box-shadow: 0 0 18px rgba(57, 255, 136, 0.8);
}

.story-section {
    display: grid;
    grid-template-columns: minmax(280px, 0.92fr) 1.08fr;
    gap: clamp(32px, 6vw, 70px);
    align-items: center;
    padding: 110px 56px;
}

.story-image {
    overflow: hidden;
    background: var(--white);
}

.story-image img {
    width: 100%;
    height: 100%;
    min-height: 480px;
    object-fit: cover;
}

.story-copy h2,
.stack-section h2,
.projects-section h2,
.contact-copy h2 {
    margin: 18px 0 0;
    color: var(--black);
    font-size: clamp(36px, 5vw, 60px);
    line-height: 0.95;
    letter-spacing: -0.07em;
}

.story-copy h3 {
    margin: 5px 0 22px;
    color: var(--black);
    font-size: clamp(22px, 3vw, 34px);
    letter-spacing: -0.04em;
}

.story-copy p:not(.section-kicker),
.contact-copy p:not(.section-kicker) {
    color: var(--muted);
    font-size: 17px;
    line-height: 1.75;
}

.stack-section,
.projects-section {
    margin-top: 16px;
    padding: 100px 42px;
    text-align: center;
}

.stack-table {
    width: min(100%, 900px);
    margin: 0 auto;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: var(--white);
    box-shadow: 0 24px 70px rgba(8, 34, 17, 0.1);
    text-align: left;
}

.stack-row {
    display: grid;
    grid-template-columns: 170px 1fr;
    gap: 22px;
    padding: 22px 24px;
    border-top: 1px dashed var(--line);
}

.stack-row:first-child {
    border-top: 0;
}

.stack-heading {
    background: #f3faf5;
    color: var(--muted);
    font-size: 13px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.stack-category {
    color: var(--black);
    font-size: 18px;
    font-weight: 800;
    letter-spacing: -0.03em;
}

.chips,
.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
}

.chips span,
.project-tag {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 7px 11px;
    border: 1px solid rgba(57, 255, 136, 0.18);
    border-radius: 999px;
    background: rgba(57, 255, 136, 0.08);
    color: #174524;
    font-size: 13px;
    font-weight: 750;
}

.projects-section {
    padding-inline: clamp(18px, 4vw, 54px);
}

.project-list {
    display: flex;
    flex-direction: column;
    gap: clamp(28px, 4vw, 48px);
    text-align: left;
}

.project-card,
.project-card:nth-child(even) {
    display: grid;
    grid-template-columns: minmax(0, 1.08fr) minmax(380px, 0.92fr);
    gap: clamp(28px, 4vw, 56px);
    align-items: center;
    padding: clamp(20px, 3vw, 34px);
    border: 1px solid var(--line);
    border-radius: 34px;
    background: var(--white);
    box-shadow: 0 18px 54px rgba(8, 34, 17, 0.09);
}

.project-card .project-gallery {
    order: 0;
}

.project-card .project-content {
    order: 1;
}

.project-card:nth-child(even) .project-content {
    order: 0;
}

.project-card:nth-child(even) .project-gallery {
    order: 1;
}

.project-gallery {
    position: relative;
    display: grid;
    place-items: center;
    width: 100%;
    height: clamp(360px, 42vw, 560px);
    overflow: hidden;
    border-radius: 28px;
    cursor: zoom-in;
    background: radial-gradient(circle at center, rgba(57, 255, 136, 0.1), transparent 42%), linear-gradient(135deg, #07100a, #142019);
}

.project-gallery::after {
    content: "Click screenshot to expand";
    position: absolute;
    top: 16px;
    right: 16px;
    max-width: calc(100% - 32px);
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(7, 11, 8, 0.72);
    color: rgba(255, 255, 255, 0.88);
    font-size: 12px;
    font-weight: 800;
    white-space: nowrap;
    backdrop-filter: blur(12px);
    pointer-events: none;
}

.project-gallery img {
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    object-position: center;
    padding: clamp(10px, 1.6vw, 22px);
}

.gallery-control {
    position: absolute;
    top: 50%;
    z-index: 5;
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    border: 0;
    border-radius: 999px;
    background: rgba(7, 11, 8, 0.78);
    color: var(--white);
    cursor: pointer;
    font-size: 26px;
    backdrop-filter: blur(14px);
    transform: translateY(-50%);
    transition: background 180ms ease, transform 180ms ease;
}

.gallery-control:hover {
    background: var(--green-dark);
    transform: translateY(-50%) scale(1.04);
}

.gallery-control.prev {
    left: 16px;
}

.gallery-control.next {
    right: 16px;
}

.gallery-dots {
    position: absolute;
    left: 50%;
    bottom: 16px;
    z-index: 6;
    display: flex;
    gap: 7px;
    padding: 8px 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.72);
    backdrop-filter: blur(10px);
    transform: translateX(-50%);
}

.gallery-dots button {
    width: 8px;
    height: 8px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgba(12, 15, 13, 0.18);
    cursor: pointer;
}

.gallery-dots button.active {
    width: 22px;
    border-radius: 999px;
    background: var(--green-dark);
}

.project-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 100%;
    padding: clamp(10px, 2vw, 28px) 0;
}

.project-label {
    margin-bottom: 8px;
    color: var(--green-dark);
    font-size: 13px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.09em;
}

.project-title-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
}

.project-title-row h3 {
    max-width: 100%;
    margin: 0;
    color: var(--black);
    font-size: clamp(26px, 4vw, 38px);
    line-height: 1.02;
    letter-spacing: -0.06em;
}

.project-link {
    flex: 0 0 auto;
    margin-top: 4px;
    padding: 9px 12px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #f7fff9;
    color: var(--green-dark);
    font-size: 12px;
    font-weight: 900;
}

.project-description {
    max-width: 58ch;
    margin: 18px 0 20px;
    color: var(--muted);
    font-size: 16px;
    line-height: 1.7;
}

.contact-section {
    display: grid;
    grid-template-columns: minmax(0, 0.95fr) minmax(360px, 1.05fr);
    gap: clamp(32px, 5vw, 72px);
    align-items: start;
    margin-top: 18px;
    padding: clamp(34px, 6vw, 70px);
    background: radial-gradient(circle at 90% 10%, rgba(57, 255, 136, 0.16), transparent 34%), linear-gradient(145deg, rgba(255, 255, 255, 0.95), rgba(248, 255, 251, 0.9));
}

.contact-copy h2 {
    max-width: 760px;
}

.contact-copy p:not(.section-kicker) {
    max-width: 650px;
}

.contact-methods,
.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.form-status {
    display: none;
    margin: 0;
    padding: 13px 15px;
    border-radius: 14px;
    font-size: 14px;
    font-weight: 800;
    line-height: 1.5;
}

.form-status.show {
    display: block;
}

.form-status.success {
    border: 1px solid rgba(57, 255, 136, 0.28);
    background: rgba(57, 255, 136, 0.12);
    color: #08743b;
}

.form-status.error {
    border: 1px solid rgba(220, 38, 38, 0.18);
    background: rgba(220, 38, 38, 0.08);
    color: #991b1b;
}

.contact-methods {
    margin-top: 28px;
}

.contact-method {
    display: grid;
    gap: 5px;
    width: 100%;
    padding: 18px 20px;
    border: 1px solid rgba(57, 255, 136, 0.2);
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.78);
    color: var(--black);
    text-align: left;
    cursor: pointer;
    box-shadow: 0 18px 40px rgba(7, 11, 8, 0.06);
    transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.contact-method:hover {
    transform: translateY(-2px);
    border-color: rgba(57, 255, 136, 0.42);
    background: var(--white);
}

.contact-method span {
    color: var(--green-dark);
    font-size: 12px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.contact-method strong {
    font-size: 15px;
    letter-spacing: -0.03em;
    word-break: break-word;
}

.contact-form {
    display: grid;
    gap: 16px;
    padding: clamp(20px, 3vw, 30px);
    border: 1px solid rgba(12, 15, 13, 0.08);
    border-radius: 28px;
    background: var(--white);
    box-shadow: 0 24px 70px rgba(8, 34, 17, 0.1);
}

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

.contact-form label span {
    color: var(--black);
    font-size: 13px;
    font-weight: 900;
    letter-spacing: -0.01em;
}

.contact-form input,
.contact-form select,
.contact-form textarea {
    width: 100%;
    padding: 14px 15px;
    border: 1px solid var(--line);
    border-radius: 15px;
    outline: none;
    background: #f8fbf8;
    color: var(--black);
    font: inherit;
    font-size: 14px;
    transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease;
}

.contact-form textarea {
    min-height: 150px;
    resize: vertical;
}

.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
    border-color: rgba(57, 255, 136, 0.7);
    background: var(--white);
    box-shadow: 0 0 0 4px rgba(57, 255, 136, 0.12);
}

.contact-form .primary-button {
    width: fit-content;
    margin-top: 4px;
}

.form-note {
    margin: 0;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.6;
}

.hidden-field {
    display: none;
}

.gallery-overlay {
    position: fixed;
    inset: 0;
    z-index: 999;
    display: grid;
    place-items: center;
    padding: clamp(14px, 3vw, 36px);
    background: rgba(3, 7, 4, 0.92);
    backdrop-filter: blur(18px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 180ms ease;
}

.gallery-overlay.open {
    opacity: 1;
    pointer-events: auto;
}

.overlay-frame {
    display: grid;
    grid-template-rows: minmax(0, 1fr) auto;
    width: min(1180px, calc(100vw - 48px));
    height: min(86dvh, 780px);
    margin: 0;
    overflow: hidden;
    border: 1px solid rgba(57, 255, 136, 0.22);
    border-radius: 28px;
    background: #07100a;
    box-shadow: 0 34px 110px rgba(0, 0, 0, 0.55);
}

.overlay-frame img {
    align-self: center;
    justify-self: center;
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: 100%;
    min-width: 0;
    min-height: 0;
    padding: clamp(14px, 2vw, 28px);
    object-fit: contain;
    object-position: center;
    background: radial-gradient(circle at center, rgba(57, 255, 136, 0.08), transparent 42%), #07100a;
}

.overlay-frame figcaption {
    min-height: 84px;
    display: grid;
    grid-template-columns: 1fr auto auto;
    gap: 8px 16px;
    align-items: center;
    padding: 18px 22px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(255, 255, 255, 0.04);
    color: var(--white);
}

.overlay-frame figcaption span {
    grid-column: 1 / -1;
    color: var(--green);
    font-size: 12px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.12em;
}

.overlay-frame figcaption strong {
    font-size: 20px;
    letter-spacing: -0.03em;
}

.overlay-frame figcaption small {
    color: rgba(255, 255, 255, 0.66);
    font-size: 13px;
    font-weight: 800;
}

.overlay-project-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 0 16px;
    border: 1px solid rgba(57, 255, 136, 0.28);
    border-radius: 999px;
    background: rgba(57, 255, 136, 0.1);
    color: var(--green);
    font-size: 13px;
    font-weight: 900;
    white-space: nowrap;
    transition: background 180ms ease, transform 180ms ease;
}

.overlay-project-link:hover {
    background: rgba(57, 255, 136, 0.18);
    transform: translateY(-1px);
}

.overlay-project-link.is-hidden {
    display: none;
}

.overlay-close,
.overlay-arrow {
    position: fixed;
    display: grid;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.08);
    color: var(--white);
    cursor: pointer;
    backdrop-filter: blur(14px);
    transition: transform 180ms ease, background 180ms ease;
}

.overlay-close:hover,
.overlay-arrow:hover {
    background: var(--green-dark);
    transform: scale(1.04);
}

.overlay-close {
    top: 24px;
    right: 24px;
    width: 48px;
    height: 48px;
    border-radius: 999px;
    font-size: 30px;
    line-height: 1;
}

.overlay-arrow {
    top: 50%;
    width: 58px;
    height: 72px;
    border-radius: 20px;
    font-size: 46px;
}

.overlay-prev {
    left: 24px;
}

.overlay-next {
    right: 24px;
}

.toast {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 90;
    padding: 14px 18px;
    border: 1px solid rgba(57, 255, 136, 0.26);
    border-radius: 14px;
    background: var(--black);
    color: var(--white);
    font-size: 14px;
    font-weight: 800;
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.2);
    opacity: 0;
    pointer-events: none;
    transform: translateY(30px);
    transition: opacity 180ms ease, transform 180ms ease;
}

.toast.show {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 1050px) {
    .hero-showcase {
        padding: 48px 28px;
    }

    .hero-showcase-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-copy-block {
        order: 1;
        text-align: center;
    }

    .hero-copy,
    .section-intro {
        margin-left: auto;
        margin-right: auto;
    }

    .hero-actions {
        justify-content: center;
    }

    .hero-portrait-stack {
        order: 0;
    }

    .hero-portrait-card {
        width: min(100%, 360px);
    }

    .story-section,
    .project-card,
    .project-card:nth-child(even),
    .contact-section {
        grid-template-columns: 1fr;
    }

    .story-section,
    .stack-section,
    .projects-section,
    .contact-section {
        padding: 58px 22px;
    }

    .project-card .project-gallery,
    .project-card:nth-child(even) .project-gallery {
        order: 0;
    }

    .project-card .project-content,
    .project-card:nth-child(even) .project-content {
        order: 1;
    }

    .project-gallery {
        height: clamp(340px, 58vw, 520px);
    }

    .project-description {
        max-width: 70ch;
    }
}

@media (max-width: 760px) {
    .page-shell {
        width: min(calc(100% - 20px), var(--max-width));
        padding-top: 18px;
    }

    .site-header {
        top: 12px;
        grid-template-columns: auto auto;
        justify-content: space-between;
        width: 100%;
        padding: 12px;
        overflow: visible;
    }

    .nav-toggle {
        display: grid;
    }

    .nav-links {
        position: absolute;
        top: calc(100% + 10px);
        left: 0;
        right: 0;
        display: grid;
        grid-template-columns: 1fr;
        gap: 6px;
        width: 100%;
        padding: 10px;
        border: 1px solid rgba(12, 15, 13, 0.08);
        border-radius: 16px;
        background: rgba(255, 255, 255, 0.98);
        box-shadow: 0 18px 45px rgba(12, 15, 13, 0.14);
        backdrop-filter: blur(18px);
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        transform: translateY(-8px);
        transition: opacity 180ms ease, transform 180ms ease, visibility 180ms ease;
    }

    .nav-links.open {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transform: translateY(0);
    }

    .nav-links a {
        display: flex;
        align-items: center;
        min-height: 42px;
        padding: 0 14px;
        border-radius: 12px;
        font-size: 14px;
        font-weight: 800;
    }

    .nav-links a:hover {
        background: var(--green-soft);
        transform: none;
    }
}

@media (max-width: 700px) {
    .projects-section {
        padding-left: 14px;
        padding-right: 14px;
    }

    .project-card,
    .project-card:nth-child(even) {
        gap: 20px;
        padding: 14px;
        border-radius: 24px;
    }

    .project-gallery {
        height: auto;
        aspect-ratio: 16 / 11;
        border-radius: 20px;
    }

    .project-gallery img {
        padding: 8px;
    }

    .project-gallery::after {
        display: none;
    }

    .gallery-control {
        width: 42px;
        height: 42px;
        font-size: 22px;
    }

    .gallery-control.prev {
        left: 10px;
    }

    .gallery-control.next {
        right: 10px;
    }

    .gallery-dots {
        bottom: 10px;
        padding: 7px 9px;
    }

    .project-title-row {
        display: block;
    }

    .project-title-row h3 {
        font-size: clamp(28px, 10vw, 38px);
    }

    .project-link {
        display: inline-flex;
        margin-top: 12px;
    }

    .project-description {
        font-size: 15px;
        line-height: 1.65;
    }

    .overlay-frame {
        width: calc(100vw - 24px);
        height: 78dvh;
        border-radius: 22px;
    }

    .overlay-frame img {
        padding: 10px;
    }

    .overlay-frame figcaption {
        min-height: 76px;
        grid-template-columns: 1fr;
        padding: 14px 16px;
    }

    .overlay-project-link {
        width: 100%;
    }

    .overlay-frame figcaption small {
        justify-self: start;
    }

    .overlay-arrow {
        top: auto;
        bottom: 22px;
        width: 54px;
        height: 54px;
        border-radius: 999px;
        font-size: 34px;
    }

    .overlay-prev {
        left: 22px;
    }

    .overlay-next {
        right: 22px;
    }
}

@media (max-width: 620px) {
    .hero-showcase {
        min-height: auto;
        padding: 34px 18px 44px;
        border-radius: 28px;
    }

    .hero-showcase-content {
        gap: 28px;
    }

    .hero-copy-block h1 {
        font-size: clamp(42px, 13vw, 64px);
    }

    .hero-copy {
        font-size: 16px;
    }

    .hero-actions,
    .form-grid,
    .contact-methods {
        grid-template-columns: 1fr;
    }

    .hero-actions {
        display: grid;
        width: 100%;
    }

    .hero-actions .primary-button,
    .hero-actions .ghost-button,
    .contact-form .primary-button {
        width: 100%;
    }

    .hero-portrait-card {
        width: min(100%, 300px);
        padding: 12px;
        border-radius: 28px;
    }

    .portrait-image-wrap {
        border-radius: 22px;
    }

    .hero-intro-badge {
        top: 14px;
        left: 50%;
        right: auto;
        min-width: 210px;
        text-align: center;
        transform: translateX(-50%);
    }

    .hero-intro-badge::after {
        display: none;
    }

    .story-image img {
        min-height: 320px;
    }

    .stack-row {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .stack-heading {
        display: none;
    }

    .contact-section {
        padding: 34px 18px;
        border-radius: 28px;
    }

    .toast {
        left: 16px;
        right: 16px;
        text-align: center;
    }
}

@media (max-width: 460px) {
    .page-shell {
        width: min(calc(100% - 16px), var(--max-width));
    }

    .hero-portrait-card {
        width: min(100%, 280px);
    }

    .project-card,
    .project-card:nth-child(even) {
        padding: 12px;
    }

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

    .project-content {
        padding: 0;
    }

    .project-tags {
        gap: 8px;
    }

    .project-tag {
        font-size: 12px;
    }
}