:root {
    --page: #f5f5f7;
    --page-2: #ffffff;
    --ink: #111827;
    --muted: #5f6673;
    --soft: #8b95a5;
    --line: rgba(17, 24, 39, 0.1);
    --line-strong: rgba(17, 24, 39, 0.18);
    --card: rgba(255, 255, 255, 0.78);
    --card-solid: #ffffff;
    --blue: #0071e3;
    --blue-dark: #005bb8;
    --green: #0f9f6e;
    --violet: #6e5cff;
    --shadow-sm: 0 10px 28px rgba(17, 24, 39, 0.08);
    --shadow-lg: 0 30px 90px rgba(17, 24, 39, 0.14);
    --radius: 18px;
    --radius-lg: 32px;
    --shell: 1180px;
    --header-height: 76px;
    --font: "Inter", -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", sans-serif;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    color: var(--ink);
    background:
        radial-gradient(circle at 20% 4%, rgba(0, 113, 227, 0.16), transparent 27rem),
        radial-gradient(circle at 85% 14%, rgba(110, 92, 255, 0.14), transparent 25rem),
        linear-gradient(180deg, #fbfbfd 0%, #f5f5f7 44%, #ffffff 100%);
    font-family: var(--font);
    line-height: 1.55;
    text-rendering: optimizeLegibility;
}

body.nav-open {
    overflow: hidden;
}

button,
input,
textarea {
    font: inherit;
}

button {
    border: 0;
}

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

a:hover {
    color: var(--blue);
}

:focus-visible {
    outline: 3px solid rgba(0, 113, 227, 0.72);
    outline-offset: 4px;
}

.skip-link {
    position: fixed;
    top: 1rem;
    left: 1rem;
    z-index: 100;
    transform: translateY(-160%);
    border-radius: 999px;
    background: var(--ink);
    color: #fff;
    padding: 0.75rem 1rem;
    font-weight: 800;
}

.skip-link:focus {
    transform: translateY(0);
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.shell {
    width: min(var(--shell), calc(100% - 2rem));
    margin: 0 auto;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 30;
    min-height: var(--header-height);
    border-bottom: 1px solid transparent;
    background: rgba(245, 245, 247, 0.72);
    backdrop-filter: saturate(180%) blur(22px);
    transition: border-color 180ms ease, background 180ms ease, box-shadow 180ms ease;
}

.site-header.is-scrolled {
    border-bottom-color: var(--line);
    background: rgba(255, 255, 255, 0.84);
    box-shadow: 0 8px 28px rgba(17, 24, 39, 0.04);
}

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

.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    min-width: 0;
}

.brand-mark {
    display: grid;
    place-items: center;
    width: 2.55rem;
    height: 2.55rem;
    border-radius: 50%;
    background: #111827;
    color: #fff;
    font-weight: 900;
    letter-spacing: -0.04em;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25), var(--shadow-sm);
}

.brand-copy {
    display: grid;
    line-height: 1.15;
}

.brand-copy strong {
    font-size: 0.98rem;
    letter-spacing: -0.02em;
}

.brand-copy small {
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 600;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 0.2rem;
}

.nav-menu a {
    border-radius: 999px;
    color: rgba(17, 24, 39, 0.72);
    font-size: 0.9rem;
    font-weight: 700;
    padding: 0.65rem 0.85rem;
}

.nav-menu a:hover,
.nav-menu a.is-active {
    color: var(--ink);
    background: rgba(17, 24, 39, 0.06);
}

.nav-menu .nav-resume {
    margin-left: 0.45rem;
    background: var(--blue);
    color: #fff;
    box-shadow: 0 10px 26px rgba(0, 113, 227, 0.24);
    padding-inline: 1rem;
}

.nav-menu .nav-resume:hover {
    background: var(--blue-dark);
    color: #fff;
}

.nav-toggle {
    display: none;
    width: 2.65rem;
    height: 2.65rem;
    border-radius: 50%;
    background: rgba(17, 24, 39, 0.07);
    color: var(--ink);
    cursor: pointer;
    place-items: center;
}

.nav-toggle span:not(.sr-only) {
    width: 1.2rem;
    height: 2px;
    border-radius: 999px;
    background: currentColor;
}

.section {
    padding: clamp(4rem, 8vw, 7rem) 0;
}

.hero {
    display: grid;
    align-items: center;
    min-height: calc(100vh - var(--header-height));
    padding: clamp(4.5rem, 8vw, 7rem) 0;
}

.hero-grid,
.story-grid,
.split-grid,
.contact-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(320px, 0.78fr);
    align-items: center;
    gap: clamp(2rem, 6vw, 5.5rem);
}

.eyebrow {
    color: var(--blue);
    font-size: 0.78rem;
    font-weight: 900;
    letter-spacing: 0.15em;
    margin: 0 0 1rem;
    text-transform: uppercase;
}

h1,
h2,
h3,
p {
    margin-top: 0;
}

h1 {
    max-width: 8ch;
    font-size: clamp(4.6rem, 11vw, 9.6rem);
    line-height: 0.88;
    letter-spacing: -0.075em;
    margin-bottom: 1.25rem;
}

h2 {
    max-width: 13ch;
    font-size: clamp(2.55rem, 6vw, 5.4rem);
    line-height: 0.94;
    letter-spacing: -0.065em;
    margin-bottom: 1rem;
}

h3 {
    font-size: clamp(1.25rem, 2vw, 1.65rem);
    line-height: 1.1;
    letter-spacing: -0.04em;
    margin-bottom: 0.7rem;
}

.hero-title {
    max-width: 18ch;
    color: var(--ink);
    font-size: clamp(1.75rem, 3vw, 2.8rem);
    font-weight: 900;
    letter-spacing: -0.055em;
    line-height: 1.04;
    margin-bottom: 1.1rem;
}

.hero-lede,
.section-heading p,
.story-copy p,
.project-card p,
.timeline-card p,
.education-grid p,
.contact-card p,
.form-note {
    color: var(--muted);
}

.hero-lede,
.section-heading p,
.story-copy p {
    max-width: 62ch;
    font-size: clamp(1.05rem, 1.55vw, 1.22rem);
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.85rem;
    margin-top: 2rem;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    min-height: 3rem;
    border-radius: 999px;
    cursor: pointer;
    font-weight: 800;
    letter-spacing: -0.01em;
    padding: 0.85rem 1.2rem;
    transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease, color 180ms ease;
}

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

.btn-primary {
    background: var(--blue);
    color: #fff;
    box-shadow: 0 16px 36px rgba(0, 113, 227, 0.24);
}

.btn-primary:hover {
    background: var(--blue-dark);
    color: #fff;
}

.btn-xl {
    min-height: 3.8rem;
    padding: 1.05rem 1.45rem;
    font-size: 1.05rem;
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.72);
    color: var(--ink);
    border: 1px solid var(--line);
    box-shadow: 0 10px 26px rgba(17, 24, 39, 0.06);
}

.availability-card {
    display: inline-flex;
    align-items: center;
    gap: 0.7rem;
    max-width: 42rem;
    margin-top: 1.2rem;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.72);
    color: var(--muted);
    padding: 0.72rem 1rem;
    box-shadow: var(--shadow-sm);
    font-weight: 700;
}

.status-dot {
    width: 0.62rem;
    height: 0.62rem;
    flex: 0 0 auto;
    border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 0 0.35rem rgba(15, 159, 110, 0.13);
}

.profile-showcase {
    position: relative;
    display: grid;
    gap: 1rem;
}

.profile-showcase::before {
    content: "";
    position: absolute;
    inset: -2.5rem -1rem auto auto;
    width: 17rem;
    height: 17rem;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(0, 113, 227, 0.24), transparent 67%);
    filter: blur(8px);
    z-index: -1;
}

.portrait-card,
.mini-dashboard,
.signature-note,
.metrics-grid,
.hackathon-card,
.project-card,
.timeline-card,
.skill-cloud,
.cert-card,
.education-grid,
.contact-card {
    border: 1px solid rgba(255, 255, 255, 0.76);
    background: var(--card);
    backdrop-filter: blur(24px);
    box-shadow: var(--shadow-lg);
}

.portrait-card {
    overflow: hidden;
    border-radius: var(--radius-lg);
    padding: clamp(1.2rem, 3vw, 2rem);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.86), rgba(255, 255, 255, 0.64)),
        radial-gradient(circle at 20% 0%, rgba(0, 113, 227, 0.14), transparent 20rem);
}

.portrait-media {
    position: relative;
    display: grid;
    place-items: center;
    min-height: 19rem;
    border-radius: 26px;
    background:
        radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.92), transparent 19%),
        radial-gradient(circle at 70% 65%, rgba(110, 92, 255, 0.42), transparent 28%),
        linear-gradient(135deg, #dcecff, #ffffff 38%, #d8f7ef);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8), 0 24px 70px rgba(0, 113, 227, 0.13);
    overflow: hidden;
}

.portrait-media::before {
    content: "";
    position: absolute;
    inset: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.74);
    border-radius: 22px;
    pointer-events: none;
}

.portrait-media img {
    width: min(58%, 13rem);
    aspect-ratio: 4 / 5;
    border: 8px solid rgba(255, 255, 255, 0.72);
    border-radius: 28px;
    object-fit: cover;
    object-position: center top;
    box-shadow: 0 28px 70px rgba(17, 24, 39, 0.2);
}

.portrait-glass-note {
    position: absolute;
    right: 1rem;
    bottom: 1rem;
    max-width: 14rem;
    border: 1px solid rgba(255, 255, 255, 0.58);
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.64);
    backdrop-filter: blur(18px);
    box-shadow: var(--shadow-sm);
    padding: 0.85rem;
}

.portrait-glass-note span {
    color: var(--soft);
    display: block;
    font-size: 0.68rem;
    font-weight: 900;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.portrait-glass-note strong {
    display: block;
    font-size: 1rem;
    letter-spacing: -0.03em;
    line-height: 1.1;
    margin-top: 0.25rem;
}

.portrait-copy {
    display: grid;
    gap: 0.4rem;
    margin-top: 1.1rem;
}

.portrait-copy span,
.mini-dashboard span,
.project-type,
.timeline-date,
.education-grid span,
.cert-card span {
    color: var(--soft);
    font-size: 0.76rem;
    font-weight: 900;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.portrait-copy strong {
    font-size: clamp(1.3rem, 3vw, 1.85rem);
    line-height: 1.08;
    letter-spacing: -0.05em;
}

.mini-dashboard {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1px;
    overflow: hidden;
    border-radius: 24px;
    background: rgba(17, 24, 39, 0.08);
}

.mini-dashboard div {
    background: rgba(255, 255, 255, 0.78);
    padding: 1rem;
}

.mini-dashboard strong {
    display: block;
    font-size: 0.96rem;
    line-height: 1.2;
    margin-top: 0.35rem;
}

.signature-note {
    border-radius: 24px;
    padding: 1.2rem;
}

.signature-note p {
    color: var(--muted);
    font-size: 1.05rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    margin: 0;
}

.story-section,
.experience-section,
.credentials-section {
    background: rgba(255, 255, 255, 0.62);
    border-block: 1px solid rgba(17, 24, 39, 0.06);
}

.story-copy {
    justify-self: end;
}

.story-pills,
.skill-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 0.7rem;
}

.story-pills {
    margin-top: 1.4rem;
}

.human-notes {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.8rem;
    margin-top: 1rem;
}

.human-notes article {
    border: 1px solid var(--line);
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.76);
    box-shadow: var(--shadow-sm);
    padding: 1rem;
}

.human-notes strong {
    display: block;
    letter-spacing: -0.03em;
    margin-bottom: 0.35rem;
}

.human-notes p {
    font-size: 0.95rem;
    margin: 0;
}

.story-pills span,
.skill-cloud span {
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.82);
    color: var(--ink);
    font-weight: 800;
    padding: 0.68rem 0.92rem;
    box-shadow: 0 8px 22px rgba(17, 24, 39, 0.05);
}

.metrics-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: rgba(17, 24, 39, 0.08);
}

.metrics-grid div {
    background: rgba(255, 255, 255, 0.8);
    padding: clamp(1.1rem, 3vw, 1.6rem);
}

.metrics-grid strong {
    display: block;
    color: var(--ink);
    font-size: clamp(2rem, 4vw, 3.2rem);
    line-height: 1;
    letter-spacing: -0.06em;
}

.metrics-grid span {
    color: var(--muted);
    display: block;
    font-weight: 700;
    margin-top: 0.55rem;
}

.hackathon-section {
    padding-top: clamp(3rem, 6vw, 5rem);
}

.hackathon-gallery {
    display: grid;
    grid-template-columns: minmax(0, 1.14fr) minmax(320px, 0.86fr);
    gap: 1rem;
    align-items: stretch;
}

.hackathon-card {
    position: relative;
    display: grid;
    min-height: 100%;
    overflow: hidden;
    border-radius: 36px;
    margin: 0;
    background: var(--card-solid);
}

.hackathon-card img {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 27rem;
    object-fit: cover;
    filter: saturate(1.04) contrast(1.02);
    transition: transform 500ms ease, filter 500ms ease;
}

.hackathon-card.large img {
    min-height: 34rem;
}

.hackathon-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 34%, rgba(4, 8, 18, 0.78) 100%);
    pointer-events: none;
}

.hackathon-card:hover img {
    transform: scale(1.035);
    filter: saturate(1.1) contrast(1.04);
}

.hackathon-card figcaption {
    position: absolute;
    left: clamp(1rem, 3vw, 1.5rem);
    right: clamp(1rem, 3vw, 1.5rem);
    bottom: clamp(1rem, 3vw, 1.5rem);
    z-index: 1;
    color: #fff;
}

.hackathon-card figcaption span {
    display: inline-flex;
    width: fit-content;
    border: 1px solid rgba(255, 255, 255, 0.34);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(14px);
    color: rgba(255, 255, 255, 0.86);
    font-size: 0.74rem;
    font-weight: 900;
    letter-spacing: 0.11em;
    margin-bottom: 0.85rem;
    padding: 0.45rem 0.7rem;
    text-transform: uppercase;
}

.hackathon-card figcaption strong {
    display: block;
    max-width: 16ch;
    font-size: clamp(1.7rem, 4vw, 3.2rem);
    line-height: 0.98;
    letter-spacing: -0.065em;
}

.hackathon-card figcaption p {
    color: rgba(255, 255, 255, 0.78);
    font-weight: 650;
    max-width: 34rem;
    margin: 0.8rem 0 0;
}

.section-heading {
    margin-bottom: 2rem;
}

.section-heading.centered {
    display: grid;
    justify-items: center;
    text-align: center;
}

.section-heading.centered h2,
.section-heading.centered p {
    max-width: 780px;
}

.project-feature-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.08fr) minmax(280px, 0.92fr);
    gap: 1rem;
}

.project-card {
    display: grid;
    align-content: start;
    min-height: 100%;
    border-radius: var(--radius-lg);
    padding: clamp(1.15rem, 3vw, 1.7rem);
}

.project-card.primary-card {
    grid-row: span 2;
}

.project-visual {
    position: relative;
    min-height: 12rem;
    overflow: hidden;
    border-radius: 24px;
    background: #f5f5f7;
    margin-bottom: 1.2rem;
}

.primary-card .project-visual {
    min-height: 18rem;
}

.scanner-visual {
    background:
        linear-gradient(90deg, rgba(255, 255, 255, 0.75) 1px, transparent 1px),
        linear-gradient(180deg, rgba(255, 255, 255, 0.75) 1px, transparent 1px),
        linear-gradient(135deg, #0f172a, #0071e3);
    background-size: 34px 34px, 34px 34px, auto;
}

.scanner-visual span {
    position: absolute;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.88);
}

.scanner-visual span:nth-child(1) {
    inset: 24% auto auto 18%;
    width: 7rem;
    height: 7rem;
}

.scanner-visual span:nth-child(2) {
    inset: auto 16% 18% auto;
    width: 10rem;
    height: 10rem;
    background: rgba(167, 243, 208, 0.92);
}

.scanner-visual span:nth-child(3) {
    inset: 18% 15% auto auto;
    width: 4.2rem;
    height: 4.2rem;
    background: rgba(255, 255, 255, 0.7);
}

.vpn-visual,
.infra-visual,
.social-visual {
    background: linear-gradient(135deg, #ffffff, #dcecff);
}

.vpn-visual span,
.infra-visual span,
.social-visual span {
    position: absolute;
    border-radius: 24px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.vpn-visual span:nth-child(1) {
    width: 8rem;
    height: 8rem;
    left: 16%;
    top: 17%;
}

.vpn-visual span:nth-child(2) {
    width: 6rem;
    height: 6rem;
    right: 17%;
    bottom: 17%;
    background: var(--blue);
}

.infra-visual span:nth-child(1) {
    width: 70%;
    height: 2.6rem;
    left: 15%;
    top: 20%;
}

.infra-visual span:nth-child(2) {
    width: 56%;
    height: 2.6rem;
    left: 22%;
    top: 46%;
}

.infra-visual span:nth-child(3) {
    width: 42%;
    height: 2.6rem;
    left: 29%;
    top: 72%;
}

.social-visual span {
    width: 5rem;
    height: 5rem;
}

.social-visual span:nth-child(1) {
    left: 15%;
    top: 24%;
    background: #fff;
}

.social-visual span:nth-child(2) {
    left: 40%;
    top: 18%;
    background: #e8f3ff;
}

.social-visual span:nth-child(3) {
    right: 15%;
    bottom: 20%;
    background: #e6fff6;
}

.clean-list {
    display: grid;
    gap: 0.55rem;
    list-style: none;
    padding: 0;
    margin: 1rem 0;
}

.clean-list li {
    position: relative;
    color: var(--muted);
    padding-left: 1.1rem;
}

.clean-list li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.72em;
    width: 0.38rem;
    height: 0.38rem;
    border-radius: 50%;
    background: var(--blue);
}

.text-link {
    color: var(--blue);
    font-weight: 900;
    margin-top: auto;
}

.timeline-card {
    border-radius: var(--radius-lg);
    padding: clamp(1.2rem, 4vw, 2rem);
}

.meta {
    color: var(--soft);
    font-weight: 800;
}

.skill-cloud {
    justify-content: center;
    border-radius: var(--radius-lg);
    padding: clamp(1.2rem, 4vw, 2rem);
}

.cert-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.cert-card {
    display: grid;
    min-height: 12rem;
    border-radius: 24px;
    padding: 1.25rem;
    transition: transform 180ms ease, box-shadow 180ms ease;
}

.cert-card:hover {
    color: var(--ink);
    transform: translateY(-5px);
    box-shadow: 0 34px 90px rgba(17, 24, 39, 0.16);
}

.cert-card strong {
    font-size: 1.15rem;
    line-height: 1.15;
    letter-spacing: -0.035em;
}

.cert-card small {
    align-self: end;
    color: var(--muted);
    font-weight: 800;
    margin-top: 1rem;
}

.education-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1px;
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: rgba(17, 24, 39, 0.08);
}

.education-grid article {
    background: rgba(255, 255, 255, 0.82);
    padding: clamp(1.1rem, 3vw, 1.6rem);
}

.contact-section {
    padding-bottom: clamp(5rem, 8vw, 8rem);
}

.contact-card {
    align-items: start;
    border-radius: 36px;
    padding: clamp(1.2rem, 4vw, 2.4rem);
}

.social-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.7rem;
    margin-top: 1.4rem;
}

.social-row a {
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.74);
    color: var(--ink);
    font-weight: 800;
    padding: 0.68rem 0.95rem;
}

.social-row a:hover {
    border-color: rgba(0, 113, 227, 0.28);
    color: var(--blue);
}

.contact-form {
    display: grid;
    gap: 1rem;
    width: 100%;
}

.contact-form label {
    display: grid;
    gap: 0.42rem;
}

.contact-form span {
    color: var(--muted);
    font-size: 0.86rem;
    font-weight: 800;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.84);
    color: var(--ink);
    padding: 0.95rem 1rem;
    resize: vertical;
}

.contact-form input:focus,
.contact-form textarea:focus {
    border-color: rgba(0, 113, 227, 0.55);
    outline: 0;
    box-shadow: 0 0 0 4px rgba(0, 113, 227, 0.08);
}

.form-note {
    margin: 0;
    font-size: 0.9rem;
}

.form-note a {
    color: var(--blue);
    font-weight: 800;
}

.site-footer {
    border-top: 1px solid var(--line);
    color: var(--muted);
    padding: 1.5rem 0;
}

.footer-grid {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.footer-grid p {
    margin: 0;
}

.footer-grid a {
    color: var(--blue);
    font-weight: 900;
}

.js .reveal {
    opacity: 0;
    transform: translateY(20px) scale(0.985);
    transition: opacity 700ms ease, transform 700ms ease;
}

.js .reveal.is-visible {
    opacity: 1;
    transform: translateY(0) scale(1);
}

@media (max-width: 1020px) {
    .hero-grid,
    .story-grid,
    .split-grid,
    .contact-card,
    .project-feature-grid,
    .hackathon-gallery,
    .cert-grid,
    .education-grid {
        grid-template-columns: 1fr;
    }

    .hero {
        min-height: auto;
    }

    .story-copy {
        justify-self: start;
    }

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

    .project-card.primary-card {
        grid-row: auto;
    }
}

@media (max-width: 780px) {
    :root {
        --header-height: 70px;
    }

    .shell {
        width: min(100% - 1.2rem, var(--shell));
    }

    .brand-copy small {
        display: none;
    }

    .nav-toggle {
        display: grid;
    }

    .nav-menu {
        position: fixed;
        inset: var(--header-height) 0 auto 0;
        display: grid;
        gap: 0.15rem;
        max-height: calc(100vh - var(--header-height));
        overflow: auto;
        border-bottom: 1px solid var(--line);
        background: rgba(255, 255, 255, 0.96);
        padding: 0.7rem;
        transform: translateY(-120%);
        transition: transform 220ms ease;
    }

    body.nav-open .nav-menu {
        transform: translateY(0);
    }

    .nav-menu a,
    .nav-menu .nav-resume {
        margin-left: 0;
        border-radius: 18px;
        padding: 1rem;
    }

    .hero-actions,
    .footer-grid {
        align-items: stretch;
        flex-direction: column;
    }

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

    .availability-card {
        align-items: flex-start;
        border-radius: 20px;
    }

    .mini-dashboard,
    .metrics-grid {
        grid-template-columns: 1fr;
    }

    .portrait-media {
        min-height: 15rem;
    }

    .human-notes {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 500px) {
    h1 {
        font-size: 4.2rem;
    }

    h2 {
        font-size: 2.55rem;
    }

    .hero-title {
        font-size: 1.55rem;
    }

    .project-visual,
    .primary-card .project-visual {
        min-height: 11.5rem;
    }

    .hackathon-card img,
    .hackathon-card.large img {
        min-height: 23rem;
    }

    .hackathon-card figcaption strong {
        font-size: 1.75rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
    }

    .js .reveal {
        opacity: 1;
        transform: none;
    }
}
