:root {
    --bg: #0b1220;
    --bg-elevated: #111a2e;
    --surface: rgba(26, 36, 64, 0.92);
    --surface-strong: #1a2440;
    --surface-soft: #162038;
    --text: #e6edf6;
    --muted: #94a3b8;
    --muted-strong: #cbd5e1;
    --accent: #3b82f6;
    --accent-strong: #2563eb;
    --accent-soft: rgba(59, 130, 246, 0.14);
    --line: rgba(148, 163, 184, 0.18);
    --line-strong: rgba(148, 163, 184, 0.28);
    --shadow: 0 18px 42px rgba(0, 0, 0, 0.26);
    --radius-sm: 0.9rem;
    --radius-md: 1.25rem;
    --radius-lg: 1.75rem;
    --radius-xl: 2.25rem;
    --container: min(72rem, calc(100% - 2rem));
    --header-height: 5rem;
    --transition: 180ms ease;
    --font-sans: Inter, "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, "Helvetica Neue", sans-serif;
}

/* Base */
*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-width: 20rem;
    font-family: var(--font-sans);
    color: var(--text);
    background:
        radial-gradient(circle at top right, rgba(59, 130, 246, 0.18), transparent 28rem),
        radial-gradient(circle at bottom left, rgba(99, 102, 241, 0.10), transparent 24rem),
        linear-gradient(180deg, #0c1322 0%, #0b1220 52%, #080e1c 100%);
    line-height: 1.65;
}

body.is-locked {
    overflow: hidden;
}

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

a {
    color: inherit;
}

button {
    font: inherit;
}

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

:focus-visible {
    outline: 0.2rem solid rgba(59, 130, 246, 0.9);
    outline-offset: 0.2rem;
}

::selection {
    background: rgba(59, 130, 246, 0.24);
    color: var(--text);
}

.skip-link {
    position: absolute;
    top: -3rem;
    left: 1rem;
    z-index: 2000;
    padding: 0.7rem 1rem;
    border-radius: 999px;
    background: var(--text);
    color: #0b1220;
    text-decoration: none;
    transition: top var(--transition);
}

.skip-link:focus {
    top: 1rem;
}

.container {
    width: var(--container);
    margin: 0 auto;
}

.section {
    padding: clamp(2rem, 4vw, 3.5rem) 0;
    scroll-margin-top: calc(var(--header-height) + 1.5rem);
}

.surface-card {
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    background: linear-gradient(180deg, rgba(20, 31, 24, 0.96), rgba(13, 21, 17, 0.96));
    box-shadow: var(--shadow);
}

.eyebrow {
    margin: 0 0 0.9rem;
    color: var(--accent);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.section-heading {
    max-width: 42rem;
    margin-bottom: 1.75rem;
}

.section-heading h2 {
    margin: 0 0 0.9rem;
    font-size: clamp(2rem, 4vw, 3rem);
    line-height: 1.1;
}

.section-heading p:last-child {
    margin: 0;
    color: var(--muted);
    font-size: 1.02rem;
}

.section-heading--compact {
    margin-top: 4rem;
}

.chip-list,
.trust-chips,
.badge-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.7rem;
    padding: 0;
    margin: 0;
    list-style: none;
}

.chip-list li,
.trust-chips li,
.badge-list span {
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.03);
    color: var(--muted-strong);
    padding: 0.45rem 0.8rem;
    font-size: 0.88rem;
    line-height: 1.2;
}

/* Header */
.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(18px);
    background: rgba(8, 17, 13, 0.72);
    border-bottom: 1px solid var(--line);
}

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

.logo {
    color: var(--text);
    text-decoration: none;
    font-size: 1.35rem;
    font-weight: 800;
    letter-spacing: -0.04em;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-left: auto;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 1.4rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-links a {
    color: var(--muted);
    text-decoration: none;
    font-weight: 500;
    transition: color var(--transition);
}

.nav-links a:hover,
.nav-links a:focus-visible {
    color: var(--text);
}

.nav-toggle {
    display: none;
    border: 1px solid var(--line);
    border-radius: 0.95rem;
    background: rgba(255, 255, 255, 0.03);
    padding: 0.8rem;
    color: var(--text);
    cursor: pointer;
}

.nav-toggle span {
    display: block;
    width: 1.15rem;
    height: 0.12rem;
    margin: 0.22rem 0;
    border-radius: 999px;
    background: currentColor;
    transition: transform var(--transition), opacity var(--transition);
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
    transform: translateY(0.34rem) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] span:nth-child(2) {
    opacity: 0;
}

.nav-toggle[aria-expanded="true"] span:nth-child(3) {
    transform: translateY(-0.34rem) rotate(-45deg);
}

/* Buttons */
.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    min-height: 3rem;
    padding: 0.8rem 1.2rem;
    border-radius: 999px;
    border: 1px solid transparent;
    text-decoration: none;
    font-weight: 700;
    transition:
        background-color var(--transition),
        color var(--transition),
        border-color var(--transition),
        transform var(--transition);
    cursor: pointer;
}

.button:hover {
    transform: translateY(-0.05rem);
}

.button--primary {
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-strong) 100%);
    color: #ffffff;
}

.button--primary:hover,
.button--primary:focus-visible {
    background: linear-gradient(135deg, #60a5fa 0%, #3b82f6 100%);
}

.button--secondary {
    border-color: var(--line-strong);
    background: rgba(255, 255, 255, 0.02);
    color: var(--text);
}

.button--secondary:hover,
.button--secondary:focus-visible {
    border-color: rgba(59, 130, 246, 0.52);
    background: rgba(59, 130, 246, 0.08);
}

.button--ghost {
    border-color: transparent;
    background: rgba(255, 255, 255, 0.06);
    color: var(--muted-strong);
}

.button--ghost:hover,
.button--ghost:focus-visible {
    background: rgba(255, 255, 255, 0.1);
}

.button--static {
    cursor: default;
    pointer-events: none;
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--line);
    color: var(--muted-strong);
}

.button--small {
    min-height: 2.75rem;
    padding-inline: 1rem;
}

/* Hero */
.hero {
    padding-top: clamp(2.5rem, 5vw, 4rem);
}

.hero__grid {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(18rem, 0.85fr);
    gap: clamp(1.5rem, 4vw, 3rem);
    align-items: start;
}

.hero__content h1 {
    margin: 0 0 1rem;
    font-size: clamp(2.6rem, 7vw, 4.8rem);
    line-height: 1.05;
    letter-spacing: -0.04em;
}

.hero__lead {
    margin: 0 0 1rem;
    color: var(--muted-strong);
    font-size: clamp(1.1rem, 2.6vw, 1.4rem);
}

.hero__supporting {
    margin: 0;
    max-width: 40rem;
    color: var(--muted);
    font-size: 1.02rem;
}

.hero__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.85rem;
    margin: 2rem 0 1.5rem;
}

.trust-chips li {
    background: rgba(255, 255, 255, 0.05);
}

.hero__sidebar {
    display: grid;
    gap: 1rem;
}

.hero-outcomes {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
    margin-top: 1.5rem;
}

.hero-outcome-card {
    padding: 1.35rem;
}

.hero-outcome-card__label,
.proof-spotlight__label,
.project-detail__label,
.proof-link {
    color: var(--accent);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.hero-outcome-card h3 {
    margin: 0.45rem 0 0.55rem;
    font-size: 1.12rem;
    line-height: 1.25;
}

.hero-outcome-card p:last-child {
    margin: 0;
    color: var(--muted);
}

.profile-panel {
    padding: 0.75rem;
}

.profile-panel__image {
    width: 100%;
    height: auto;
    aspect-ratio: 1;
    border-radius: calc(var(--radius-lg) - 0.45rem);
    object-fit: cover;
    object-position: center top;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.profile-panel__body {
    padding: 0.85rem 0.15rem 0.15rem;
}

.profile-panel__name {
    font-weight: 800;
    font-size: 1.15rem;
}

.profile-panel__role {
    margin: 0.2rem 0 0.55rem;
    color: var(--accent);
    font-weight: 700;
    font-size: 0.92rem;
    line-height: 1.3;
}

.profile-panel__list,
.quick-proof__list,
.experience-list,
.project-points,
.case-study__copy section ul {
    margin: 0;
    padding-left: 1.15rem;
    color: var(--muted);
}

.profile-panel__list li + li,
.quick-proof__list li + li,
.experience-list li + li,
.project-points li + li,
.case-study__copy section ul li + li {
    margin-top: 0.5rem;
}

.profile-panel__list li + li {
    margin-top: 0.3rem;
}

.profile-panel__list {
    line-height: 1.45;
}

.quick-proof {
    padding: 1.25rem 1.35rem;
    background: linear-gradient(180deg, rgba(21, 35, 28, 0.97), rgba(13, 22, 18, 0.97));
}

.quick-proof__label {
    margin: 0 0 0.85rem;
    font-weight: 700;
    color: var(--muted-strong);
}

/* About */
.about-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) minmax(18rem, 0.75fr);
    gap: 1.5rem;
}

.about-copy {
    padding: 1.7rem;
}

.about-copy p {
    margin: 0;
    color: var(--muted-strong);
}

.about-copy p + p {
    margin-top: 1rem;
}

.about-copy__heading {
    margin: 1.6rem 0 0.7rem;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--accent);
}

/* Achievements: hero stat block + supporting list */
.achievements {
    margin-top: 0.65rem;
    display: grid;
    grid-template-columns: 13rem 1fr;
    gap: 1.5rem;
    align-items: start;
}

.achievements__stat {
    width: 13rem;
    aspect-ratio: 1 / 1;          /* perfect square */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 1rem;
    border-radius: 1.1rem;
    background:
        radial-gradient(circle at 30% 25%, rgba(59, 130, 246, 0.26), transparent 60%),
        linear-gradient(160deg, rgba(59, 130, 246, 0.14), rgba(59, 130, 246, 0.03));
    border: 1px solid rgba(59, 130, 246, 0.32);
    text-align: center;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.04),
        0 14px 32px rgba(59, 130, 246, 0.08);
    align-self: start;             /* card sticks to the top of the row */
}

.achievements__stat-number {
    font-size: clamp(3.2rem, 6vw, 4.4rem);   /* bigger to fill the square */
    font-weight: 800;
    color: var(--accent);
    line-height: 1;
    letter-spacing: -0.02em;
    display: inline-flex;
    align-items: baseline;
}

.achievements__stat-plus {
    font-size: 0.62em;
    margin-left: 0.1em;
    color: var(--accent);
    opacity: 0.85;
}

.achievements__stat-label {
    margin-top: 0.55rem;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--muted-strong);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.achievements__list {
    margin: 0;
    padding: 0;
    list-style: none;
    display: grid;
    gap: 0.65rem;
    align-self: center;
}

.achievements__list li {
    position: relative;
    padding-left: 1.5rem;
    color: var(--text);
    line-height: 1.55;
}

.achievements__list li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.55rem;
    width: 0.5rem;
    height: 0.5rem;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.18);
}

.achievements__list li strong {
    color: var(--accent);
    font-weight: 700;
}

@media (max-width: 36rem) {
    .achievements {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    .achievements__stat {
        justify-self: center;       /* center the square in its row */
        width: 11rem;               /* slightly smaller on mobile */
    }
}

/* Apps grid -- card per app: logo + name + downloads */
.apps-grid {
    margin-top: 1.6rem;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    gap: 1.1rem 0.85rem;
    align-items: start;     /* don't stretch short cards to match tall neighbours */
}

.apps-grid a {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    text-decoration: none;
    color: inherit;
    gap: 0.35rem;
    line-height: 1.25;
    transition:
        transform 280ms var(--ease-out);
}

.apps-grid a:hover,
.apps-grid a:focus-visible {
    transform: translateY(-6px) scale(1.06);
    z-index: 2;
    position: relative;
}

.apps-grid a:hover img,
.apps-grid a:focus-visible img {
    box-shadow:
        0 18px 36px rgba(0, 0, 0, 0.45),
        0 0 28px rgba(59, 130, 246, 0.30);
    border-color: rgba(59, 130, 246, 0.55);
}

.apps-grid img {
    width: 64px;
    height: 64px;
    aspect-ratio: 1 / 1;
    border-radius: 22%;
    object-fit: cover;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.04);
    display: block;
    transition:
        box-shadow 280ms ease,
        border-color 280ms ease;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.22);
}

.apps-grid__name {
    margin-top: 0.45rem;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text);
    line-height: 1.2;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    word-break: break-word;
}

.apps-grid__dl {
    font-size: 0.68rem;
    font-weight: 600;
    color: var(--accent);
    letter-spacing: 0.01em;
    opacity: 0.85;
}

.apps-grid__dl::after {
    content: " downloads";
    color: var(--muted);
    font-weight: 500;
    opacity: 0.7;
}

@media (max-width: 56rem) {
    .apps-grid {
        grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
        gap: 0.7rem;
    }
}

@media (max-width: 36rem) {
    .apps-grid {
        grid-template-columns: repeat(auto-fill, minmax(64px, 1fr));
        gap: 0.55rem;
    }
}


.about-sidebar {
    display: grid;
    gap: 1rem;
}

.info-card {
    padding: 1.5rem;
}

.info-card__label,
.contact-card__label {
    margin: 0 0 0.65rem;
    color: var(--accent);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.info-card h3,
.trust-card h3,
.service-card h3,
.skill-card h3,
.github-card h3,
.contact-card h3 {
    margin: 0 0 0.55rem;
    font-size: 1.15rem;
}

.info-card p,
.trust-card p,
.service-card p,
.skill-card p,
.contact-card p {
    margin: 0;
    color: var(--muted);
}

.info-card p + p,
.trust-card p + p,
.contact-card p + p {
    margin-top: 0.4rem;
}

.info-card--subtle {
    background: linear-gradient(180deg, rgba(19, 30, 24, 0.92), rgba(12, 18, 15, 0.92));
}

.info-list {
    margin: 0;
    padding-left: 1.15rem;
    color: var(--muted);
}

.info-list li + li {
    margin-top: 0.5rem;
}

/* Skills and services */
.skills-grid,
.services-grid,
.contact-grid,
.secondary-projects,
.trust-grid {
    display: grid;
    gap: 1rem;
}

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

.services-grid {
    grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
}

.skill-card,
.service-card {
    padding: 1.5rem;
}

.skill-card p {
    margin-bottom: 1rem;
}

/* Experience */
.experience-card {
    padding: 1.5rem;
}

.experience-card + .experience-card {
    margin-top: 1.2rem;
}

.experience-card__header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 0.85rem;
    padding-bottom: 0.7rem;
    border-bottom: 1px solid var(--line);
}

.experience-card__role {
    margin: 0 0 0.2rem;
    color: var(--accent);
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: 0.01em;
    line-height: 1.25;
}

.experience-card__brand {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    min-width: 0;
}

.experience-card__logo {
    width: 64px;
    height: 64px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.04);
    flex-shrink: 0;
    object-fit: cover;
    object-position: center;
    border: 1px solid var(--line);
}

/* For wide / non-square logos that get cropped under "cover" -- fit fully with letterboxing */
.experience-card__logo--contain {
    object-fit: contain;
    padding: 3px;
    background: rgba(255, 255, 255, 0.06);
}

/* Solid white backdrop -- for logos with dark artwork on transparent bg that need contrast */
.experience-card__logo--bg-white {
    background: #ffffff;
    border-color: rgba(0, 0, 0, 0.08);
}

.experience-card h3 a {
    color: inherit;
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: color var(--transition), border-color var(--transition);
}

.experience-card h3 a:hover {
    color: var(--accent);
    border-bottom-color: var(--accent);
    text-shadow: 0 0 16px rgba(59, 130, 246, 0.45);
}

.info-list a {
    color: inherit;
    text-decoration: none;
    border-bottom: 1px dashed var(--line-strong);
    transition: color var(--transition), border-color var(--transition);
}

.info-list a:hover {
    color: var(--accent);
    border-bottom: 1px solid var(--accent);
}

/* Certifications list -- 2-line rows, full-row clickable, hover lift */
.cert-list {
    margin: 0.5rem 0 0;
    padding: 0;
    list-style: none;
    display: grid;
    gap: 0.4rem;
}

.cert-list li {
    margin: 0;
}

.cert-link {
    display: flex;
    flex-direction: column;
    gap: 0.18rem;
    padding: 0.6rem 0.85rem;
    border-radius: 0.55rem;
    text-decoration: none;
    color: inherit;
    background: rgba(255, 255, 255, 0.015);
    border: 1px solid var(--line);
    transition:
        background-color 200ms ease,
        border-color 200ms ease,
        transform 200ms var(--ease-out);
}

.cert-link:hover {
    background: rgba(59, 130, 246, 0.10);
    border-color: rgba(59, 130, 246, 0.60);
    transform: translateY(-3px) scale(1.012);
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.22);
}

.cert-link .cert-name {
    color: var(--text);
    font-weight: 600;
    font-size: 0.95rem;
    line-height: 1.3;
}

.cert-link .cert-meta {
    color: var(--muted);
    font-size: 0.82rem;
    letter-spacing: 0.01em;
}

.cert-link--static {
    cursor: default;
}

.cert-link--static:hover {
    background: rgba(255, 255, 255, 0.015);
    border-color: var(--line);
    transform: none;
}

.project-card__brand {
    display: flex;
    align-items: center;
    gap: 1.1rem;
    margin: 0.5rem 0 0.3rem;
}

.project-card__brand h3 {
    margin: 0;
    flex: 1;
    min-width: 0;
}

.project-card__logo {
    width: 64px;
    height: 64px;
    border-radius: 22%;
    flex-shrink: 0;
    object-fit: cover;
    object-position: center;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--line);
}

.info-card__logo {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    object-fit: cover;
    object-position: center;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--line);
    margin-bottom: 0.85rem;
    display: block;
}

/* Letterbox modifier for non-square info-card logos (so they don't get cropped) */
.info-card__logo--contain {
    object-fit: contain;
    padding: 4px;
    background: rgba(255, 255, 255, 0.06);
}

/* Solid white backdrop -- for logos that need light contrast */
.info-card__logo--bg-white {
    background: #ffffff;
    border-color: rgba(0, 0, 0, 0.08);
}

.experience-card h3 {
    margin: 0;
    font-size: 1.4rem;
    line-height: 1.25;
}

.experience-card__date {
    margin: 0;
    color: var(--muted);
    font-weight: 600;
    white-space: nowrap;
}

.experience-card__summary {
    margin: 0 0 0.7rem;
    color: var(--muted-strong);
    line-height: 1.4;
}

.experience-card .experience-list {
    margin-top: 0.2rem;
    line-height: 1.35;
}

.experience-card .experience-list li {
    line-height: 1.35;
}

.experience-card .experience-list li + li {
    margin-top: 0.25rem;
}

.experience-list li:empty,
.chip-list li:empty {
    display: none;
}

.experience-card--compact {
    max-width: 100%;
}

/* Projects */
.featured-projects {
    display: grid;
    gap: 1.4rem;
    align-items: stretch;   /* every card in a row matches the tallest */
}

@media (min-width: 720px) {
    .featured-projects {
        grid-template-columns: 1fr 1fr;
        gap: 1.6rem;
    }
    /* First (flagship) card spans full width to keep it prominent */
    .featured-projects > .project-card:first-child {
        grid-column: 1 / -1;
    }
}

/* Make each project card a flex column so the action row sticks to the bottom,
   keeping CTA buttons perfectly aligned across the row. */
.project-card,
.project-card__content {
    display: flex;
    flex-direction: column;
}

.project-card__content {
    flex: 1;
    min-width: 0;
}

.project-actions {
    margin-top: auto;
}

.project-card {
    overflow: clip;
}

.project-card--featured {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 0.95fr);
}

.project-card--featured:nth-child(even) .project-card__media {
    order: 2;
}

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

.project-card__media,
.project-card__cover {
    min-height: 100%;
    background: #0a120e;
}

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

.project-card__content {
    padding: 1.6rem;
}

/* Cards without a media column should span the full card width */
.project-card--featured > .project-card__content:only-child {
    grid-column: 1 / -1;
}

.project-card__meta {
    display: grid;
    gap: 0.8rem;
    margin-bottom: 1rem;
}

.project-role {
    margin: 0;
    color: var(--accent);
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.project-card__content h3 {
    margin: 0 0 0.85rem;
    font-size: clamp(1.55rem, 2.2vw, 2rem);
    line-height: 1.12;
}

.project-card__content h3 span {
    display: block;
    margin-top: 0.25rem;
    color: var(--muted);
    font-size: 0.95rem;
    font-weight: 600;
}

.project-card__content > p {
    margin: 0 0 1rem;
    color: var(--muted-strong);
}

.project-summary {
    font-size: 1rem;
}

.project-points {
    margin-bottom: 1rem;
}

.project-detail-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.85rem;
    margin-bottom: 1rem;
}

.project-detail {
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.03);
    padding: 0.95rem 1rem;
}

.project-detail p {
    margin: 0;
}

.project-detail__label {
    margin-bottom: 0.45rem !important;
}

.project-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.25rem;
}

.secondary-projects {
    grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
}

.project-card--secondary {
    display: grid;
    grid-template-rows: auto 1fr;
}

.project-card__media--secondary {
    aspect-ratio: 16 / 11;
}

.project-card__media--secondary img {
    object-position: center top;
}

.project-card__cover {
    display: grid;
    align-content: end;
    gap: 0.45rem;
    padding: 1.35rem;
    aspect-ratio: 16 / 11;
}

.project-card__cover--flowcus {
    background:
        radial-gradient(circle at top right, rgba(59, 130, 246, 0.25), transparent 40%),
        linear-gradient(160deg, #0d1813 0%, #15261d 55%, #0e1612 100%);
}

.project-card__cover-label {
    margin: 0;
    color: var(--accent);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.project-card__cover h3,
.project-card__cover p {
    margin: 0;
}

.project-card__cover h3 {
    font-size: 1.45rem;
}

.project-card__cover p {
    color: var(--muted);
}

/* Proof */
.proof-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
    gap: 1rem;
}

.proof-spotlight {
    overflow: clip;
}

.proof-spotlight__image {
    width: 100%;
    height: auto;
    aspect-ratio: 1330 / 804;
    object-fit: cover;
}

.proof-spotlight__body {
    padding: 1.5rem;
}

.proof-spotlight__body h3 {
    margin: 0.45rem 0 0.6rem;
    font-size: 1.35rem;
}

.proof-spotlight__body p {
    margin-bottom: 1rem;
    color: var(--muted);
}

.proof-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

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

.trust-card {
    padding: 1.35rem;
}

.github-avatar {
    width: 4.5rem;
    height: 4.5rem;
    margin-bottom: 1rem;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid var(--line-strong);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.22);
}

.github-handle {
    margin-bottom: 0.45rem !important;
    color: var(--muted-strong) !important;
    font-weight: 700;
}

.proof-link {
    display: inline-flex;
    align-items: center;
    margin-top: 0.9rem;
    text-decoration: none;
}

.proof-link:hover,
.proof-link:focus-visible {
    color: var(--text);
}

.proof-subsection {
    margin-top: 2rem;
}

.proof-subsection__heading {
    max-width: 52rem;
    margin-bottom: 1.5rem;
}

.github-showcase {
    overflow: clip;
}

.github-showcase__content {
    padding: 1.5rem 1.5rem 1rem;
}

.github-showcase__content h3 {
    margin: 0 0 0.55rem;
    font-size: 1.5rem;
}

.github-showcase__content p {
    margin: 0 0 1rem;
    color: var(--muted);
    max-width: 44rem;
}

.github-showcase__image {
    width: 100%;
    height: auto;
    border-top: 1px solid var(--line);
    object-fit: cover;
}

/* Contact */
.section--contact {
    padding-bottom: clamp(2rem, 4vw, 3.5rem);
}

.contact-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 1.5rem;
    padding: 1.8rem;
    margin-bottom: 1rem;
}

.contact-panel__intro h2 {
    margin: 0 0 0.85rem;
    font-size: clamp(2rem, 4vw, 3rem);
    line-height: 1.08;
}

.contact-panel__intro p:last-child {
    margin: 0;
    color: var(--muted);
    max-width: 40rem;
}

.contact-panel__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    justify-content: flex-end;
    align-content: start;
}

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

.contact-card {
    padding: 1.35rem;
}

.contact-card a {
    display: inline-block;
    margin-bottom: 0.7rem;
    color: var(--muted-strong);
    font-weight: 700;
    text-decoration: none;
    word-break: break-word;
}

.contact-card a:hover,
.contact-card a:focus-visible {
    color: var(--text);
}

.contact-card--secondary {
    background: linear-gradient(180deg, rgba(17, 25, 21, 0.94), rgba(13, 19, 16, 0.94));
}

/* Footer */
.site-footer {
    border-top: 1px solid var(--line);
    background: rgba(4, 10, 7, 0.65);
}

.site-footer .container {
    padding: 1.6rem 0;
}

.site-footer p {
    margin: 0;
    color: var(--muted);
    text-align: center;
}

/* Dialog */
.project-dialog {
    width: min(72rem, calc(100% - 1.5rem));
    padding: 0;
    border: none;
    background: transparent;
    color: var(--text);
}

.project-dialog::backdrop {
    background: rgba(3, 9, 7, 0.82);
    backdrop-filter: blur(8px);
}

.project-dialog__panel {
    position: relative;
    max-height: calc(100vh - 2rem);
    overflow: auto;
    border: 1px solid rgba(212, 229, 218, 0.12);
    border-radius: var(--radius-xl);
    background: linear-gradient(180deg, rgba(14, 23, 18, 0.98), rgba(9, 15, 12, 0.98));
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45);
}

.project-dialog__close {
    position: sticky;
    top: 1rem;
    z-index: 2;
    margin: 1rem 1rem 0 auto;
    display: block;
    border: 1px solid var(--line-strong);
    border-radius: 999px;
    background: rgba(9, 15, 12, 0.92);
    color: var(--text);
    padding: 0.65rem 0.95rem;
    cursor: pointer;
}

.project-dialog__body {
    padding: clamp(1rem, 3vw, 2rem);
}

.case-study__header {
    padding-right: 4.25rem;
    margin-bottom: 1.5rem;
}

.case-study__header h2 {
    margin: 0 0 0.35rem;
    font-size: clamp(1.9rem, 4vw, 2.8rem);
    line-height: 1.1;
}

.case-study__header p:last-child {
    margin: 0;
    color: var(--muted);
}

.case-study__layout {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
    gap: 1.25rem;
}

.case-study__copy {
    display: grid;
    gap: 1rem;
}

.case-study__copy section {
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.03);
    padding: 1rem;
}

.case-study__copy section h3 {
    margin: 0 0 0.55rem;
    font-size: 1rem;
}

.case-study__copy section p {
    margin: 0;
    color: var(--muted);
}

.case-study__media {
    display: grid;
    gap: 1rem;
}

.case-study__media figure {
    margin: 0;
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    overflow: clip;
    background: rgba(255, 255, 255, 0.03);
}

.case-study__media img {
    width: 100%;
    height: auto;
}

.case-study__media figcaption {
    padding: 0.85rem 1rem 1rem;
    color: var(--muted);
    font-size: 0.92rem;
}

/* ============================================================================
   Animations
   ============================================================================ */

/* Easing variables for consistency */
:root {
    --ease-out: cubic-bezier(0.22, 0.61, 0.36, 1);
    --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
}

/* Scroll reveal */
[data-reveal] {
    opacity: 0;
    transform: translateY(1.4rem);
    transition:
        opacity 480ms var(--ease-out),
        transform 480ms var(--ease-out);
}

[data-reveal].is-visible {
    opacity: 1;
    transform: translateY(0);
    /* Release any compositor layer the transform created -- avoids GPU layers
       hanging around for every revealed element and slowing the scroll. */
    will-change: auto;
}

/* Hero content: cascade child blocks slightly after the container fades in.
   Only fires once (on first reveal) -- not while scrolling past again. */
.hero__content.is-visible > * {
    animation: rise-in 520ms var(--ease-out) both;
}
.hero__content.is-visible > *:nth-child(1) { animation-delay: 40ms; }
.hero__content.is-visible > *:nth-child(2) { animation-delay: 110ms; }
.hero__content.is-visible > *:nth-child(3) { animation-delay: 180ms; }
.hero__content.is-visible > *:nth-child(4) { animation-delay: 250ms; }
.hero__content.is-visible > *:nth-child(5) { animation-delay: 320ms; }
.hero__content.is-visible > *:nth-child(6) { animation-delay: 390ms; }

@keyframes rise-in {
    from { opacity: 0; transform: translateY(0.9rem); }
    to   { opacity: 1; transform: translateY(0); }
}

/* Achievements: animate stat block and stagger supporting bullets */
.about-copy .achievements__stat {
    opacity: 0;
    transform: scale(0.92);
    transition:
        opacity 600ms var(--ease-out),
        transform 600ms var(--ease-out);
}

.about-copy.is-visible .achievements__stat {
    opacity: 1;
    transform: scale(1);
    transition-delay: 120ms;
}

.about-copy .achievements__list li {
    opacity: 0;
    transform: translateY(0.4rem);
    transition:
        opacity 460ms var(--ease-out),
        transform 460ms var(--ease-out);
}

.about-copy.is-visible .achievements__list li {
    opacity: 1;
    transform: translateY(0);
}

.about-copy.is-visible .achievements__list li:nth-child(1) { transition-delay: 240ms; }
.about-copy.is-visible .achievements__list li:nth-child(2) { transition-delay: 320ms; }
.about-copy.is-visible .achievements__list li:nth-child(3) { transition-delay: 400ms; }
.about-copy.is-visible .achievements__list li:nth-child(4) { transition-delay: 480ms; }
.about-copy.is-visible .achievements__list li:nth-child(5) { transition-delay: 560ms; }

/* Project cards: alternating slide entrance (lighter -- no scale, no child cascade) */
.featured-projects .project-card[data-reveal] {
    transform: translateX(-1.5rem) translateY(0.8rem);
    transition:
        opacity 520ms var(--ease-out),
        transform 520ms var(--ease-out);
}

.featured-projects .project-card[data-reveal]:nth-child(even) {
    transform: translateX(1.5rem) translateY(0.8rem);
}

.featured-projects .project-card[data-reveal].is-visible {
    transform: translateX(0) translateY(0);
}

/* Card hover lift */
.surface-card.project-card,
.surface-card.skill-card,
.surface-card.service-card,
.surface-card.experience-card,
.surface-card.contact-card,
.surface-card.info-card,
.surface-card.profile-panel,
.surface-card.trust-card {
    transition:
        transform 260ms var(--ease-out),
        border-color 260ms ease,
        box-shadow 260ms ease,
        background-color 260ms ease;
}

.surface-card.project-card:hover,
.surface-card.skill-card:hover,
.surface-card.service-card:hover,
.surface-card.experience-card:hover,
.surface-card.contact-card:hover,
.surface-card.info-card:hover,
.surface-card.trust-card:hover {
    transform: translateY(-14px) scale(1.018);
    border-color: rgba(59, 130, 246, 0.75);
    box-shadow:
        0 36px 64px rgba(0, 0, 0, 0.50),
        0 0 0 1px rgba(59, 130, 246, 0.50),
        0 0 60px rgba(59, 130, 246, 0.28),
        0 0 120px rgba(99, 102, 241, 0.18);
}

.surface-card.profile-panel:hover {
    transform: translateY(-6px) scale(1.01);
    box-shadow:
        0 32px 56px rgba(0, 0, 0, 0.42),
        0 0 36px rgba(59, 130, 246, 0.10);
}

/* Profile photo zoom on card hover */
.profile-panel__image {
    transition: transform 420ms var(--ease-out);
}

.profile-panel:hover .profile-panel__image {
    transform: scale(1.06);
}

/* Logos zoom on card hover */
.experience-card__logo,
.project-card__logo,
.info-card__logo {
    transition: transform 320ms var(--ease-out);
}

.experience-card:hover .experience-card__logo,
.project-card:hover .project-card__logo,
.info-card:hover .info-card__logo {
    transform: scale(1.15) rotate(-2deg);
}

/* Chip hover (skills, trust, badges) -- pronounced */
.chip-list li,
.trust-chips li,
.badge-list span {
    transition:
        background-color 220ms ease,
        border-color 220ms ease,
        color 220ms ease,
        transform 220ms var(--ease-out),
        box-shadow 220ms ease;
}

.chip-list li:hover,
.trust-chips li:hover,
.badge-list span:hover {
    background: rgba(59, 130, 246, 0.18);
    border-color: rgba(59, 130, 246, 0.65);
    color: var(--text);
    transform: translateY(-3px) scale(1.04);
    box-shadow: 0 6px 14px rgba(59, 130, 246, 0.20);
}

/* Button micro-interactions: stronger lift + scale + glow */
.button {
    transition:
        background-color 240ms ease,
        background 240ms ease,
        border-color 240ms ease,
        color 240ms ease,
        transform 240ms var(--ease-out),
        box-shadow 240ms ease;
}

.button:hover {
    transform: translateY(-4px) scale(1.03);
}

.button--primary:hover,
.button--primary:focus-visible {
    box-shadow: 0 14px 30px rgba(59, 130, 246, 0.42);
}

.button--secondary:hover,
.button--ghost:hover {
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.30);
    border-color: rgba(59, 130, 246, 0.50);
}

/* Nav link underline animation */
.nav-links a {
    position: relative;
    transition: color 200ms ease;
}

.nav-links a::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -0.35rem;
    height: 2px;
    background: var(--accent);
    border-radius: 999px;
    transform: scaleX(0);
    transform-origin: left center;
    transition: transform 280ms var(--ease-out);
}

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

.nav-links a:hover::after,
.nav-links a:focus-visible::after {
    transform: scaleX(1);
}

/* In-page anchor link external pulse on click (subtle) */
a[href^="http"] {
    transition: color 180ms ease;
}

/* Responsive */
@media (max-width: 70rem) {
    .skills-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .contact-grid,
    .trust-grid,
    .proof-list,
    .hero-outcomes {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 60rem) {
    .hero__grid,
    .about-grid,
    .proof-layout,
    .contact-panel,
    .case-study__layout {
        grid-template-columns: 1fr;
    }

    .project-card--featured {
        grid-template-columns: 1fr;
    }

    .project-card--featured:nth-child(even) .project-card__media,
    .project-card--featured:nth-child(even) .project-card__content {
        order: initial;
    }

    .contact-panel__actions {
        justify-content: flex-start;
    }

    .experience-card__header {
        flex-direction: column;
    }

    .experience-card__date {
        white-space: normal;
    }

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

    /* Hero: text stays first (source order), image card stacks below, centred and capped */
    .hero__grid {
        gap: 1.5rem;
    }

    .hero__sidebar {
        max-width: 22rem;
        width: 100%;
        margin-left: auto;
        margin-right: auto;
    }
}

@media (max-width: 56rem) {
    .nav-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .nav-menu {
        position: absolute;
        top: calc(100% + 0.75rem);
        right: 1rem;
        left: 1rem;
        display: none;
        flex-direction: column;
        align-items: stretch;
        padding: 1rem;
        border: 1px solid var(--line);
        border-radius: var(--radius-lg);
        background: rgba(9, 15, 12, 0.97);
        box-shadow: var(--shadow);
    }

    .nav-menu.is-open {
        display: flex;
    }

    .nav-links {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.9rem;
    }

    .nav-cta {
        width: 100%;
    }
}

@media (max-width: 42rem) {
    .hero__actions,
    .project-actions,
    .contact-panel__actions {
        flex-direction: column;
    }

    .hero__actions .button,
    .project-actions .button,
    .contact-panel__actions .button {
        width: 100%;
    }

    .skills-grid,
    .services-grid,
    .contact-grid,
    .secondary-projects,
    .trust-grid,
    .proof-list,
    .hero-outcomes {
        grid-template-columns: 1fr;
    }

    .project-card__content,
    .about-copy,
    .experience-card,
    .skill-card,
    .service-card,
    .github-card__body,
    .contact-panel,
    .contact-card,
    .trust-card,
    .info-card {
        padding: 1.25rem;
    }

    .project-dialog__body {
        padding: 0.9rem;
    }

    .case-study__header {
        padding-right: 3.5rem;
    }

    .project-dialog__close {
        top: 0.8rem;
        margin-right: 0.8rem;
    }

    .hero__content h1 {
        font-size: clamp(2.2rem, 8vw, 3.2rem);
        line-height: 1.05;
    }

    .hero__sidebar {
        max-width: 18rem;
    }

    /* Hero buttons already stack via existing rule; ensure trust-chips wrap nicely */
    .trust-chips {
        gap: 0.5rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }

    [data-reveal] {
        opacity: 1;
        transform: none;
    }

    .button:hover,
    .surface-card:hover,
    .chip-list li:hover,
    .trust-chips li:hover,
    .badge-list span:hover,
    .profile-panel:hover .profile-panel__image,
    .experience-card:hover .experience-card__logo,
    .project-card:hover .project-card__logo,
    .info-card:hover .info-card__logo,
    .apps-grid a:hover,
    .cert-link:hover {
        transform: none;
        animation: none;
        box-shadow: none;
        text-shadow: none;
    }

    .hero__content.is-visible > *,
    .about-copy.is-visible .achievements__stat,
    .about-copy.is-visible .achievements__list li {
        opacity: 1;
        transform: none;
        animation: none;
        transition: none;
    }

    .featured-projects .project-card[data-reveal],
    .featured-projects .project-card[data-reveal]:nth-child(even) {
        transform: none;
    }

    .nav-links a::after {
        transition: none;
    }
}

/* ============================================================================
   Hero glow blob -- animated gradient behind the profile photo
   ============================================================================ */
.profile-panel {
    position: relative;
    isolation: isolate;
}

.profile-panel::before {
    content: "";
    position: absolute;
    inset: -18% -12% -18% -12%;
    z-index: -1;
    background:
        radial-gradient(circle at 30% 30%, rgba(59, 130, 246, 0.45), transparent 55%),
        radial-gradient(circle at 70% 70%, rgba(99, 102, 241, 0.32), transparent 55%);
    filter: blur(48px);
    opacity: 0.85;
    animation: hero-glow-drift 14s ease-in-out infinite alternate;
    pointer-events: none;
}

@keyframes hero-glow-drift {
    0%   { transform: translate(0, 0)    scale(1);    opacity: 0.85; }
    50%  { transform: translate(-2%, 2%) scale(1.08); opacity: 1;    }
    100% { transform: translate(2%, -2%) scale(1.04); opacity: 0.9;  }
}

@media (prefers-reduced-motion: reduce) {
    .profile-panel::before {
        animation: none;
    }
}

/* ============================================================================
   Scroll progress bar -- thin accent strip at very top of viewport
   ============================================================================ */
#scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    width: 0%;
    background: linear-gradient(90deg, #3b82f6, #6366f1, #818cf8);
    box-shadow: 0 0 10px rgba(59, 130, 246, 0.6);
    z-index: 9999;
    transition: width 90ms linear;
    pointer-events: none;
}

/* === Certifications grid + lightbox =========================== */
.cert-grid {
    list-style: none;
    padding: 0;
    margin: 1rem 0 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 0.75rem;
}
.cert-grid li { display: flex; }
.cert-card {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    padding: 0.6rem;
    background: rgba(15, 23, 42, 0.55);
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 12px;
    color: inherit;
    text-align: left;
    cursor: pointer;
    font: inherit;
    transition: transform 200ms ease, border-color 200ms ease, background 200ms ease, box-shadow 200ms ease;
}
.cert-card:hover, .cert-card:focus-visible {
    transform: translateY(-3px);
    border-color: rgba(59, 130, 246, 0.55);
    background: rgba(30, 41, 59, 0.7);
    box-shadow: 0 18px 38px -22px rgba(59, 130, 246, 0.55);
    outline: none;
}
.cert-card__img {
    width: 100%;
    height: 110px;
    object-fit: cover;
    object-position: top center;
    border-radius: 8px;
    background: #0b1220;
    display: block;
}
.cert-card__name {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text);
    line-height: 1.25;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.cert-card__meta {
    font-size: 0.72rem;
    color: var(--muted);
}
.cert-card--static {
    cursor: default;
    opacity: 0.85;
}
.cert-card--static:hover {
    transform: none;
    box-shadow: none;
}
.cert-card__placeholder {
    width: 100%;
    height: 110px;
    border-radius: 8px;
    background: rgba(15, 23, 42, 0.4);
    border: 1px dashed rgba(148, 163, 184, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--muted);
    font-size: 0.7rem;
}

.cert-lightbox {
    position: fixed;
    inset: 0;
    z-index: 9000;
    background: radial-gradient(ellipse at center, rgba(15, 23, 42, 0.94), rgba(2, 6, 23, 0.97));
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(1rem, 4vh, 3rem) clamp(1rem, 4vw, 3rem);
    opacity: 0;
    animation: cert-lightbox-in 220ms cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.cert-lightbox[hidden] { display: none; }
@keyframes cert-lightbox-in {
    from { opacity: 0; }
    to { opacity: 1; }
}
@keyframes cert-image-in {
    from { opacity: 0; transform: scale(0.94); }
    to { opacity: 1; transform: scale(1); }
}

.cert-lightbox__close {
    position: absolute;
    top: 1.25rem;
    right: 1.25rem;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(15, 23, 42, 0.7);
    color: #e6edf6;
    border: 1px solid rgba(148, 163, 184, 0.25);
    font-size: 1.5rem;
    font-weight: 300;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(8px);
    transition: transform 200ms ease, background 200ms ease, border-color 200ms ease;
}
.cert-lightbox__close:hover {
    background: rgba(30, 41, 59, 0.9);
    border-color: #3b82f6;
    transform: rotate(90deg);
}
.cert-lightbox__close:focus-visible {
    outline: 2px solid #3b82f6;
    outline-offset: 3px;
}

.cert-lightbox__img-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    animation: cert-image-in 320ms cubic-bezier(0.16, 1, 0.3, 1) 60ms backwards;
}
.cert-lightbox__img {
    max-width: min(95vw, 1200px);
    max-height: calc(100vh - 160px);
    border-radius: 14px;
    box-shadow: 0 40px 80px -20px rgba(0, 0, 0, 0.75), 0 0 0 1px rgba(255, 255, 255, 0.05);
    background: #fff;
    object-fit: contain;
    display: block;
}

.cert-lightbox__footer {
    position: absolute;
    bottom: clamp(1rem, 3vh, 2rem);
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.6rem;
    text-align: center;
    max-width: 90vw;
}
.cert-lightbox__title {
    color: #f1f5f9;
    font-size: 1.05rem;
    font-weight: 600;
    letter-spacing: -0.01em;
    line-height: 1.3;
}
.cert-lightbox__verify {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: #fff;
    font-size: 0.85rem;
    font-weight: 500;
    text-decoration: none;
    background: linear-gradient(135deg, #3b82f6, #6366f1);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    transition: transform 200ms ease, box-shadow 200ms ease;
    box-shadow: 0 8px 16px -4px rgba(59, 130, 246, 0.4);
}
.cert-lightbox__verify:hover {
    transform: translateY(-1px);
    box-shadow: 0 12px 20px -4px rgba(59, 130, 246, 0.5);
}
.cert-lightbox__verify:focus-visible {
    outline: 2px solid #fff;
    outline-offset: 2px;
}
.cert-lightbox__verify[hidden] { display: none; }

@media (max-width: 600px) {
    .cert-lightbox__close { top: 0.75rem; right: 0.75rem; width: 40px; height: 40px; }
    .cert-lightbox__title { font-size: 0.95rem; }
}
