* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: #f2f7ff;
    font-family: "Oxanium", "Segoe UI", sans-serif;
    background:
        radial-gradient(circle at 12% -8%, rgba(92, 247, 255, 0.22), transparent 35%),
        radial-gradient(circle at 82% 10%, rgba(139, 255, 90, 0.24), transparent 34%),
        linear-gradient(145deg, rgba(17, 17, 31, 0.85), rgba(26, 23, 51, 0.85) 48%, rgba(21, 42, 67, 0.85)),
        url('unnamed.jpg') center / cover fixed;
    background-blend-mode: screen, screen, overlay, normal;
    min-height: 100vh;
    overflow-x: hidden;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    opacity: 0.22;
    background-image:
        linear-gradient(transparent 96%, rgba(255, 255, 255, 0.16) 97%),
        linear-gradient(90deg, transparent 96%, rgba(255, 255, 255, 0.12) 97%);
    background-size: 100% 8px, 8px 100%;
}

body::after {
    content: "";
    position: fixed;
    width: 380px;
    height: 380px;
    right: -120px;
    bottom: -120px;
    border-radius: 50%;
    z-index: -1;
    background: radial-gradient(circle, rgba(255, 172, 77, 0.26), rgba(255, 172, 77, 0));
    animation: floatOrb 8s ease-in-out infinite;
}

.wrap {
    width: min(1120px, calc(100% - 2.2rem));
    margin-inline: auto;
}

.topbar {
    position: sticky;
    top: 0;
    z-index: 40;
    backdrop-filter: blur(8px);
    background: rgba(10, 17, 33, 0.76);
    border-bottom: 1px solid rgba(92, 247, 255, 0.28);
}

.topbar-inner {
    min-height: 72px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
    padding: 0.85rem 0;
}

.level-links {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.level-links a {
    text-decoration: none;
    color: #d6e9ff;
    border: 1px solid rgba(139, 255, 90, 0.3);
    border-radius: 7px;
    padding: 0.34rem 0.55rem;
    font-family: "Press Start 2P", monospace;
    font-size: 0.56rem;
    letter-spacing: 0.02em;
    background: rgba(13, 25, 44, 0.76);
    transition: 220ms ease;
}

.level-links a:hover {
    border-color: rgba(92, 247, 255, 0.62);
    background: rgba(92, 247, 255, 0.12);
    transform: translateY(-2px);
}

.identity {
    font-family: "Press Start 2P", monospace;
    font-size: clamp(0.68rem, 1.8vw, 0.9rem);
    letter-spacing: 0.03em;
    color: #5cf7ff;
    text-shadow: 0 0 10px rgba(92, 247, 255, 0.4);
}

.contact-links {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.contact-links a {
    text-decoration: none;
    color: #f2f7ff;
    border: 1px solid rgba(92, 247, 255, 0.34);
    border-radius: 999px;
    padding: 0.43rem 0.82rem;
    font-size: 0.82rem;
    background: rgba(255, 255, 255, 0.03);
    transition: 220ms ease;
}

.contact-links a:hover {
    transform: translateY(-2px);
    color: #081022;
    border-color: transparent;
    background: linear-gradient(120deg, #5cf7ff, #8bff5a);
    box-shadow: 0 8px 20px rgba(92, 247, 255, 0.22);
}

section {
    padding: 5rem 0;
}

.hero {
    padding-top: 3.5rem;
    min-height: calc(100vh - 72px);
    display: grid;
    align-items: center;
}

.hero-grid {
    display: grid;
    grid-template-columns: 0.95fr 1.15fr;
    gap: 2.4rem;
    align-items: center;
}

.frame {
    position: relative;
    background: linear-gradient(160deg, rgba(15, 29, 55, 0.8), rgba(17, 34, 61, 0.5));
    border: 1px solid rgba(92, 247, 255, 0.34);
    border-radius: 18px;
    padding: 0.85rem;
    box-shadow: 0 20px 45px rgba(4, 9, 20, 0.55);
}

.frame::before {
    content: "";
    position: absolute;
    inset: 10px;
    border-radius: 12px;
    border: 1px solid rgba(139, 255, 90, 0.35);
    pointer-events: none;
}

.profile-photo {
    width: 100%;
    aspect-ratio: 4 / 5;
    border-radius: 12px;
    object-fit: cover;
    display: block;
    filter: contrast(1.04) saturate(1.06);
}

.hero-copy {
    position: relative;
    overflow: hidden;
    background: rgba(20, 30, 52, 0.8);
    border: 1px solid rgba(92, 247, 255, 0.28);
    border-radius: 18px;
    padding: 1.8rem;
    box-shadow: 0 20px 45px rgba(4, 9, 20, 0.55);
}

.hero-copy::after {
    content: "";
    position: absolute;
    width: 220px;
    height: 220px;
    right: -80px;
    top: -90px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 172, 77, 0.28), rgba(255, 172, 77, 0));
}

.kicker {
    margin: 0;
    font-family: "Press Start 2P", monospace;
    font-size: clamp(0.56rem, 1.8vw, 0.64rem);
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #8bff5a;
}

h1,
h2,
h3 {
    margin: 0;
    font-family: "Oxanium", "Segoe UI", sans-serif;
    line-height: 1.15;
}

h1 {
    margin-top: 1rem;
    font-size: clamp(2rem, 4vw, 3.3rem);
    letter-spacing: 0.02em;
}

.hero-subtitle {
    margin: 0.55rem 0 0.35rem;
    color: #d9f1ff;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.01em;
}

h2 {
    font-size: clamp(1.6rem, 2.8vw, 2.1rem);
    color: #5cf7ff;
    text-shadow: 0 0 10px rgba(92, 247, 255, 0.2);
}

.lead {
    margin: 1rem 0 1.5rem;
    color: #b8c6de;
    font-size: 1.03rem;
    line-height: 1.75;
    max-width: 62ch;
}

.mindset {
    margin: 0.95rem 0 0.35rem;
    color: #ffac4d;
    font-size: 1.05rem;
    line-height: 1.5;
}

.player-hud {
    margin: 0.95rem 0 0.2rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.hud-pill {
    border: 1px solid rgba(92, 247, 255, 0.34);
    border-radius: 999px;
    padding: 0.3rem 0.66rem;
    font-size: 0.74rem;
    color: #dcf4ff;
    background: rgba(10, 26, 48, 0.74);
}

.hero-actions {
    display: flex;
    gap: 0.8rem;
    flex-wrap: wrap;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.76rem 1.22rem;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.9rem;
    transition: 200ms ease;
    border: 1px solid transparent;
}

.btn-primary {
    background: linear-gradient(120deg, #5cf7ff, #65d7ff 50%, #8bff5a);
    color: #06111f;
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    color: #f2f7ff;
    border-color: rgba(139, 255, 90, 0.35);
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.3);
}

.panel {
    background: rgba(11, 19, 36, 0.94);
    border: 1px solid rgba(92, 247, 255, 0.24);
    border-radius: 18px;
    box-shadow: 0 20px 45px rgba(4, 9, 20, 0.55);
    padding: 1.8rem;
}

.section-head {
    display: flex;
    justify-content: space-between;
    align-items: end;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1.4rem;
}

.section-head p {
    flex: 1 1 320px;
    margin: 0;
    color: #b8c6de;
    max-width: 66ch;
    line-height: 1.7;
}

.resume-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
    align-items: stretch;
}

.resume-item {
    border: 1px solid rgba(92, 247, 255, 0.2);
    border-radius: 14px;
    background: rgba(22, 37, 62, 0.72);
    padding: 1.1rem;
    transition: 220ms ease;
}

.resume-item:hover {
    transform: translateY(-4px);
    border-color: rgba(139, 255, 90, 0.45);
    box-shadow: 0 12px 28px rgba(3, 9, 21, 0.45);
}

.resume-item h3 {
    color: #ffac4d;
    font-size: 1.15rem;
    margin-bottom: 0.42rem;
}

.resume-item p,
.resume-item li {
    color: #b8c6de;
    line-height: 1.7;
}

.resume-item p,
.resume-item ul {
    margin: 0;
}

.resume-item ul {
    margin: 0;
    padding-left: 1.1rem;
}

.arcade-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.arcade-card {
    border: 1px solid rgba(92, 247, 255, 0.24);
    border-radius: 14px;
    background:
        radial-gradient(circle at top right, rgba(139, 255, 90, 0.1), transparent 45%),
        rgba(15, 31, 56, 0.82);
    padding: 1rem;
}

.arcade-card h3 {
    color: #8bff5a;
    font-size: 1.08rem;
}

.arcade-card p {
    margin: 0.45rem 0 0;
    color: #b8c6de;
    line-height: 1.6;
}

.arcade-scoreboard {
    margin-top: 0.72rem;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.5rem;
}

.arcade-scoreboard span {
    border: 1px solid rgba(92, 247, 255, 0.26);
    border-radius: 8px;
    background: rgba(8, 19, 35, 0.74);
    padding: 0.44rem;
    text-align: center;
    font-size: 0.78rem;
    color: #cde2ff;
}

.arcade-scoreboard strong {
    color: #ffffff;
    font-size: 0.92rem;
}

.arcade-actions {
    margin-top: 0.75rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
}

.arcade-button {
    border: 1px solid rgba(92, 247, 255, 0.4);
    border-radius: 8px;
    background: rgba(92, 247, 255, 0.1);
    color: #d8fbff;
    padding: 0.5rem 0.72rem;
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
    transition: 180ms ease;
}

.arcade-button:hover {
    transform: translateY(-2px);
    border-color: rgba(139, 255, 90, 0.55);
    background: rgba(139, 255, 90, 0.13);
    color: #e7ffd8;
}

.arcade-button-primary {
    background: linear-gradient(120deg, rgba(92, 247, 255, 0.32), rgba(139, 255, 90, 0.3));
}

.arcade-status {
    margin-top: 0.62rem;
    border-top: 1px dashed rgba(92, 247, 255, 0.3);
    padding-top: 0.62rem;
    min-height: 2rem;
    color: #f2fdc8;
    font-size: 0.86rem;
}

.snake-canvas {
    width: 100%;
    max-width: 320px;
    aspect-ratio: 1 / 1;
    margin-top: 0.8rem;
    border-radius: 10px;
    border: 1px solid rgba(92, 247, 255, 0.35);
    background: #09121f;
    box-shadow: inset 0 0 0 1px rgba(139, 255, 90, 0.08);
}

.snake-pad {
    margin-top: 0.7rem;
    max-width: 220px;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-template-areas:
        ". up ."
        "left down right";
    gap: 0.45rem;
}

.snake-up {
    grid-area: up;
}

.snake-left {
    grid-area: left;
}

.snake-down {
    grid-area: down;
}

.snake-right {
    grid-area: right;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1rem;
}

.certificates-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
}

.certificate-card {
    border: 1px solid rgba(92, 247, 255, 0.26);
    border-radius: 14px;
    overflow: hidden;
    background: rgba(18, 34, 60, 0.8);
    transition: 220ms ease;
}

.certificate-card:hover {
    transform: translateY(-4px);
    border-color: rgba(139, 255, 90, 0.5);
}

.certificate-card[data-images] {
    cursor: zoom-in;
}

.certificate-card[data-images]:focus-visible {
    outline: 2px solid rgba(92, 247, 255, 0.9);
    outline-offset: 3px;
}

.certificate-image {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    display: block;
}

.certificate-label {
    margin: 0;
    padding: 0.75rem 0.9rem;
    color: #b8c6de;
    font-size: 0.9rem;
    line-height: 1.4;
    border-top: 1px solid rgba(92, 247, 255, 0.2);
}

.certificate-card-text {
    display: flex;
    align-items: stretch;
}

.certificate-text-body {
    width: 100%;
    min-height: 100%;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0.3rem;
}

.certificate-text-body h3 {
    margin: 0;
    font-size: 1.05rem;
    color: #5cf7ff;
}

.certificate-text-body p {
    margin: 0;
    color: #ffac4d;
    font-weight: 700;
}

.project-card {
    border: 1px solid rgba(92, 247, 255, 0.26);
    border-radius: 14px;
    overflow: hidden;
    background: rgba(18, 34, 60, 0.8);
    display: grid;
    grid-template-rows: 215px auto;
    transition: 220ms ease;
}

.project-card:hover {
    transform: translateY(-4px);
    border-color: rgba(139, 255, 90, 0.5);
}

.project-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.project-body {
    padding: 1rem;
}

.project-body h3 {
    font-size: 1.13rem;
    margin-bottom: 0.35rem;
    color: #5cf7ff;
}

.project-body p {
    margin: 0;
    color: #b8c6de;
    line-height: 1.68;
}

.project-actions {
    margin-top: 0.72rem;
}

.project-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(92, 247, 255, 0.48);
    background: rgba(92, 247, 255, 0.1);
    color: #d8fbff;
    border-radius: 8px;
    padding: 0.38rem 0.68rem;
    font-size: 0.77rem;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
}

.project-link:hover {
    border-color: rgba(139, 255, 90, 0.55);
    background: rgba(139, 255, 90, 0.12);
    color: #e7ffd8;
}

.tags {
    margin-top: 0.8rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.tag {
    font-size: 0.72rem;
    border: 1px solid rgba(255, 172, 77, 0.45);
    background: rgba(255, 172, 77, 0.12);
    color: #ffd8ad;
    border-radius: 999px;
    padding: 0.2rem 0.56rem;
}

.project-note {
    margin: 1.1rem 0 0;
    color: #bfd0e8;
    background: rgba(18, 32, 57, 0.82);
    border: 1px solid rgba(92, 247, 255, 0.24);
    border-radius: 12px;
    padding: 0.9rem 1rem;
    line-height: 1.65;
}

.project-disclaimer {
    margin-bottom: 1rem;
    border: 1px solid rgba(255, 172, 77, 0.45);
    border-radius: 12px;
    background:
        radial-gradient(circle at 92% 18%, rgba(255, 172, 77, 0.14), transparent 40%),
        rgba(21, 34, 58, 0.9);
    padding: 0.95rem 1rem;
    box-shadow: 0 10px 24px rgba(8, 13, 28, 0.35);
}

.project-disclaimer h3 {
    margin: 0;
    color: #ffd8ad;
    font-size: 1.04rem;
    text-shadow: 0 0 10px rgba(255, 172, 77, 0.2);
}

.project-disclaimer p {
    margin: 0.55rem 0 0;
    color: #e9f3ff;
    line-height: 1.62;
}

.project-disclaimer ul {
    margin: 0.55rem 0 0;
    padding-left: 1.12rem;
    color: #c9d9f4;
}

.project-disclaimer li {
    margin: 0.35rem 0;
    line-height: 1.65;
}

.project-disclaimer strong {
    color: #ffe5c3;
}

.gallery-modal {
    position: fixed;
    inset: 0;
    z-index: 120;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(4, 8, 18, 0.9);
    padding: 1.2rem;
}

.gallery-modal.is-open {
    display: flex;
}

.gallery-image {
    width: min(980px, calc(100vw - 8rem));
    max-height: calc(100vh - 10rem);
    object-fit: contain;
    border-radius: 10px;
    border: 1px solid rgba(92, 247, 255, 0.4);
    box-shadow: 0 24px 45px rgba(0, 0, 0, 0.45);
}

.gallery-image.slide-in {
    animation: gallerySlideIn 280ms ease;
}

.gallery-caption {
    position: fixed;
    bottom: 3.3rem;
    left: 50%;
    transform: translateX(-50%);
    margin: 0;
    width: min(920px, calc(100vw - 2.4rem));
    text-align: center;
    padding: 0.48rem 0.8rem;
    border-radius: 8px;
    background: rgba(16, 30, 56, 0.88);
    border: 1px solid rgba(92, 247, 255, 0.35);
    color: #cde3ff;
    font-size: 0.84rem;
    line-height: 1.45;
}

.gallery-close,
.gallery-nav {
    position: fixed;
    border: 1px solid rgba(92, 247, 255, 0.4);
    background: rgba(16, 30, 56, 0.88);
    color: #d8fbff;
    border-radius: 8px;
    padding: 0.45rem 0.7rem;
    font-size: 0.82rem;
    cursor: pointer;
}

.gallery-close {
    top: 1.2rem;
    right: 1.2rem;
}

.gallery-prev {
    left: 1.2rem;
}

.gallery-next {
    right: 1.2rem;
}

.gallery-counter {
    position: fixed;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    margin: 0;
    padding: 0.4rem 0.7rem;
    border-radius: 8px;
    background: rgba(16, 30, 56, 0.88);
    border: 1px solid rgba(92, 247, 255, 0.4);
    color: #d8fbff;
    font-size: 0.8rem;
}

footer {
    padding: 2.2rem 0;
    text-align: center;
    color: #b7c8e2;
    font-size: 0.93rem;
}

.reveal {
    opacity: 0;
    transform: translateY(22px);
    animation: reveal 700ms ease forwards;
}

.delay-1 {
    animation-delay: 140ms;
}

.delay-2 {
    animation-delay: 280ms;
}

.delay-3 {
    animation-delay: 420ms;
}

@keyframes reveal {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes gallerySlideIn {
    from {
        opacity: 0;
        transform: translateX(18px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes floatOrb {
    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-18px);
    }
}

@media (max-width: 920px) {
    .hero {
        min-height: auto;
    }

    .hero-grid,
    .arcade-grid,
    .resume-grid,
    .projects-grid {
        grid-template-columns: 1fr;
    }

    .topbar-inner {
        justify-content: center;
    }

    .level-links,
    .contact-links {
        justify-content: center;
    }

    section {
        padding: 4rem 0;
    }

    .section-head {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.55rem;
        margin-bottom: 1rem;
    }

    .section-head p {
        flex: 1 1 auto;
        max-width: 100%;
        font-size: 0.98rem;
        line-height: 1.62;
    }

    .hero-copy,
    .panel {
        padding: 1.35rem;
    }

    .gallery-image {
        width: calc(100vw - 2.2rem);
        max-height: calc(100vh - 13rem);
    }

    .gallery-caption {
        width: calc(100vw - 2.2rem);
        bottom: 5.8rem;
    }

    .gallery-prev,
    .gallery-next {
        bottom: 3.8rem;
        top: auto;
    }
}

@media (max-width: 768px) {
    .topbar {
        position: static;
        backdrop-filter: blur(5px);
    }

    .topbar-inner {
        min-height: auto;
        gap: 0.55rem;
        padding: 0.65rem 0;
    }

    .identity {
        width: 100%;
        text-align: center;
        font-size: 0.74rem;
    }

    .level-links {
        gap: 0.35rem;
    }

    .level-links a {
        padding: 0.32rem 0.48rem;
        font-size: 0.52rem;
    }

    .contact-links a {
        padding: 0.36rem 0.72rem;
        font-size: 0.74rem;
    }

    section {
        padding: 3.3rem 0;
    }

    .hero {
        padding-top: 1.2rem;
    }

    .project-card {
        grid-template-rows: auto auto;
    }

    .project-image {
        display: block;
        height: auto;
        aspect-ratio: 16 / 9;
    }

    .project-body {
        border-top: 1px solid rgba(92, 247, 255, 0.18);
        background: linear-gradient(180deg, rgba(10, 20, 38, 0.96), rgba(13, 24, 42, 0.96));
    }

    .project-body {
        padding: 1.2rem 1rem;
    }

    .project-body h3 {
        font-size: 1rem;
        margin-bottom: 0.5rem;
    }

    .project-body p {
        font-size: 0.95rem;
        line-height: 1.6;
    }

    .project-link {
        padding: 0.45rem 0.75rem;
        font-size: 0.8rem;
    }

    .tags {
        margin-top: 0.9rem;
        gap: 0.35rem;
    }

    .tag {
        font-size: 0.7rem;
        padding: 0.25rem 0.5rem;
    }
}

@media (max-width: 480px) {
    .project-image {
        aspect-ratio: 4 / 3;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .project-body {
        padding: 1rem 0.9rem;
    }

    .project-body h3 {
        font-size: 0.95rem;
        margin-bottom: 0.4rem;
    }

    .project-body p {
        font-size: 0.9rem;
        line-height: 1.55;
    }

    .project-link {
        padding: 0.4rem 0.65rem;
        font-size: 0.75rem;
    }

    .tags {
        margin-top: 0.8rem;
        gap: 0.3rem;
    }

    .tag {
        font-size: 0.65rem;
        padding: 0.2rem 0.45rem;
    }

    .project-disclaimer {
        padding: 0.85rem 0.9rem;
    }

    .project-disclaimer h3 {
        font-size: 0.95rem;
    }

    .project-disclaimer ul {
        margin: 0.5rem 0 0;
        padding-left: 1rem;
        font-size: 0.9rem;
    }
}

@media (max-width: 600px) {
    .project-card[data-images] .project-body h3,
    .project-card[data-images] .project-body p,
    .project-card[data-images] .project-body .tags {
        display: none;
    }

    .project-card[data-images] .project-actions {
        margin-top: 0;
    }

    .project-card[data-images] .project-link {
        border-color: transparent;
        background: linear-gradient(120deg, #5cf7ff, #65d7ff 45%, #8bff5a);
        color: #06111f;
        font-weight: 800;
        box-shadow: 0 10px 22px rgba(92, 247, 255, 0.28);
    }

    .project-card[data-images] .project-link:hover {
        transform: translateY(-1px);
        background: linear-gradient(120deg, #8bff5a, #5cf7ff 55%, #77e8ff);
        color: #04111d;
        box-shadow: 0 12px 24px rgba(139, 255, 90, 0.28);
    }
}

