/* ============================================================
   GIOELE ZORZI — PORTFOLIO 2026
   Design system: Ink Black / Arctic White / Blurple
   No frameworks. Hand-crafted.
   ============================================================ */

/* ---------- Fonts ---------- */
@font-face {
    font-family: "Nulshock";
    src: url("../fonts/nulshock-bd.woff2") format("woff2");
    font-weight: 700;
    font-display: swap;
}
@font-face {
    font-family: "Poppins";
    src: url("../fonts/poppins-light.woff2") format("woff2");
    font-weight: 300;
    font-display: swap;
}
@font-face {
    font-family: "Poppins";
    src: url("../fonts/poppins-regular.woff2") format("woff2");
    font-weight: 400;
    font-display: swap;
}
@font-face {
    font-family: "Poppins";
    src: url("../fonts/poppins-medium.woff2") format("woff2");
    font-weight: 500;
    font-display: swap;
}
@font-face {
    font-family: "Poppins";
    src: url("../fonts/poppins-semibold.woff2") format("woff2");
    font-weight: 600;
    font-display: swap;
}

/* ---------- Tokens ---------- */
:root {
    --ink: #070b12;
    --ink-2: #0a0f19;
    --ink-3: #0e1420;
    --white: #eceff8;
    --muted: rgba(236, 239, 248, 0.58);
    --faint: rgba(236, 239, 248, 0.35);
    --blurple: #3939ff;
    --blurple-bright: #6879ff;
    --blurple-soft: rgba(57, 57, 255, 0.14);
    --line: rgba(236, 239, 248, 0.08);
    --line-strong: rgba(236, 239, 248, 0.16);
    --radius: 20px;
    --radius-sm: 12px;
    --font-body: "Poppins", system-ui, -apple-system, sans-serif;
    --font-display: "Nulshock", "Poppins", sans-serif;
    --ease: cubic-bezier(0.22, 1, 0.36, 1);
    --container: 1200px;
    --gutter: clamp(20px, 4vw, 48px);
    --section-pad: clamp(88px, 12vw, 150px);
}

/* ---------- Reset ---------- */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}
html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}
body {
    background: var(--ink);
    color: var(--white);
    font-family: var(--font-body);
    font-weight: 300;
    font-size: 16px;
    line-height: 1.7;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}
img {
    max-width: 100%;
    display: block;
}
a {
    color: inherit;
    text-decoration: none;
}
button {
    font: inherit;
    color: inherit;
    background: none;
    border: 0;
    cursor: pointer;
}
::selection {
    background: var(--blurple);
    color: var(--white);
}

/* Accessibility */
.skip-link {
    position: absolute;
    left: -9999px;
    top: 0;
    z-index: 300;
    background: var(--blurple);
    color: #fff;
    padding: 10px 18px;
    border-radius: 0 0 12px 0;
}
.skip-link:focus {
    left: 0;
}
:focus-visible {
    outline: 2px solid var(--blurple-bright);
    outline-offset: 3px;
    border-radius: 4px;
}

/* ---------- Utility ---------- */
.container {
    width: 100%;
    max-width: var(--container);
    margin-inline: auto;
    padding-inline: var(--gutter);
}
.section {
    padding-block: var(--section-pad);
    position: relative;
}

/* Grain overlay */
.grain {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 90;
    opacity: 0.05;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* Kicker label:  // WORK 01 */
.kicker {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.28em;
    text-transform: uppercase;
    color: var(--muted);
}
.kicker::before {
    content: "//";
    color: var(--blurple-bright);
    letter-spacing: 0;
    font-weight: 600;
}

/* Display headings */
.display {
    font-family: var(--font-display);
    font-weight: 700;
    text-transform: uppercase;
    line-height: 1.08;
    letter-spacing: 0.01em;
}
h1.display {
    font-size: clamp(30px, 6.4vw, 76px);
}
h2.display {
    font-size: clamp(24px, 3.6vw, 44px);
}
h3.display {
    font-size: clamp(17px, 2vw, 24px);
    line-height: 1.25;
}
.section-head {
    margin-bottom: clamp(40px, 6vw, 72px);
}
.section-head .display {
    margin-top: 18px;
}
.section-head p {
    margin-top: 18px;
    max-width: 560px;
    color: var(--muted);
}
.accent {
    color: var(--blurple);
}

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 15px 30px;
    border-radius: 100px;
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    position: relative;
    transition:
        transform 0.45s var(--ease),
        box-shadow 0.45s var(--ease),
        background-color 0.45s var(--ease),
        border-color 0.45s var(--ease),
        color 0.45s var(--ease);
    will-change: transform;
}
.btn svg {
    width: 14px;
    height: 14px;
    transition: transform 0.45s var(--ease);
}
.btn:hover svg {
    transform: translateX(4px);
}
.btn-primary {
    background: var(--blurple);
    color: #fff;
    box-shadow: 0 0 0 rgba(57, 57, 255, 0);
}
.btn-primary:hover {
    transform: translateY(-2px);
    background: #4646ff;
    box-shadow:
        0 12px 34px rgba(57, 57, 255, 0.42),
        0 2px 10px rgba(57, 57, 255, 0.3);
}
.btn-ghost {
    border: 1px solid var(--line-strong);
    color: var(--white);
    background: rgba(236, 239, 248, 0.02);
}
.btn-ghost:hover {
    border-color: var(--blurple-bright);
    color: var(--blurple-bright);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(57, 57, 255, 0.15);
}

/* Text link with arrow */
.arrow-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--blurple-bright);
}
.arrow-link svg {
    width: 14px;
    height: 14px;
    transition: transform 0.4s var(--ease);
}
.arrow-link:hover svg {
    transform: translate(4px, -4px);
}

/* ---------- Nav ---------- */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 200;
    transition:
        background-color 0.5s ease,
        border-color 0.5s ease,
        backdrop-filter 0.5s ease;
    border-bottom: 1px solid transparent;
}
.nav.scrolled {
    background: rgba(7, 11, 18, 0.72);
    -webkit-backdrop-filter: blur(18px);
    backdrop-filter: blur(18px);
    border-bottom-color: var(--line);
}
.nav-inner {
    max-width: var(--container);
    margin-inline: auto;
    padding: 0 var(--gutter);
    height: 76px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}
.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: var(--font-display);
    font-size: 15px;
    letter-spacing: 0.06em;
    line-height: 1;
}
.logo-mark {
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    filter: drop-shadow(0 4px 14px rgba(57, 57, 255, 0.65))
        drop-shadow(0 0 4px rgba(57, 57, 255, 0.4));
    transition:
        transform 0.4s var(--ease),
        filter 0.4s var(--ease);
}
.logo:hover .logo-mark {
    transform: rotate(-8deg) scale(1.06);
    filter: drop-shadow(0 5px 20px rgba(57, 57, 255, 0.9))
        drop-shadow(0 0 8px rgba(57, 57, 255, 0.55));
}
.nav-links {
    display: flex;
    align-items: center;
    gap: 6px;
    list-style: none;
}
.nav-links a {
    display: block;
    padding: 9px 15px;
    font-size: 13px;
    font-weight: 400;
    color: var(--muted);
    border-radius: 100px;
    transition:
        color 0.3s ease,
        background-color 0.3s ease;
}
.nav-links a:hover {
    color: var(--white);
    background: rgba(236, 239, 248, 0.05);
}
.nav-links a.active {
    color: var(--white);
    background: rgba(57, 57, 255, 0.16);
}
.nav-cta {
    border: 1px solid var(--line-strong);
    border-radius: 100px;
    padding: 9px 20px;
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    transition:
        border-color 0.35s ease,
        background-color 0.35s ease,
        box-shadow 0.35s ease;
}
.nav-cta:hover {
    border-color: var(--blurple);
    background: var(--blurple);
    box-shadow: 0 6px 24px rgba(57, 57, 255, 0.4);
}

/* Burger */
.burger {
    display: none;
    width: 44px;
    height: 44px;
    position: relative;
    z-index: 220;
}
.burger span {
    position: absolute;
    left: 10px;
    right: 10px;
    height: 2px;
    background: var(--white);
    border-radius: 2px;
    transition:
        transform 0.45s var(--ease),
        opacity 0.3s ease,
        top 0.45s var(--ease);
}
.burger span:nth-child(1) {
    top: 16px;
}
.burger span:nth-child(2) {
    top: 22px;
}
.burger span:nth-child(3) {
    top: 28px;
}
body.menu-open .burger span:nth-child(1) {
    top: 22px;
    transform: rotate(45deg);
}
body.menu-open .burger span:nth-child(2) {
    opacity: 0;
}
body.menu-open .burger span:nth-child(3) {
    top: 22px;
    transform: rotate(-45deg);
}

/* Mobile menu */
.mobile-menu {
    position: fixed;
    inset: 0;
    z-index: 150;
    background: rgba(7, 11, 18, 0.92);
    -webkit-backdrop-filter: blur(24px);
    backdrop-filter: blur(24px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 0 clamp(28px, 8vw, 64px);
    opacity: 0;
    visibility: hidden;
    transition:
        opacity 0.45s ease,
        visibility 0.45s ease;
}
body.menu-open .mobile-menu {
    opacity: 1;
    visibility: visible;
}
.mobile-menu ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.mobile-menu a.mm-link {
    display: flex;
    align-items: baseline;
    gap: 16px;
    font-family: var(--font-display);
    font-size: clamp(24px, 7vw, 40px);
    text-transform: uppercase;
    padding: 10px 0;
    color: var(--white);
    opacity: 0;
    transform: translateY(24px);
    transition:
        opacity 0.5s var(--ease),
        transform 0.5s var(--ease),
        color 0.3s ease;
}
.mobile-menu a.mm-link:hover,
.mobile-menu a.mm-link.active {
    color: var(--blurple-bright);
}
.mobile-menu a.mm-link .idx {
    font-family: var(--font-body);
    font-size: 12px;
    font-weight: 500;
    color: var(--blurple-bright);
    letter-spacing: 0.2em;
}
body.menu-open .mobile-menu a.mm-link {
    opacity: 1;
    transform: translateY(0);
}
.mobile-menu .mm-footer {
    margin-top: 48px;
    font-size: 13px;
    color: var(--muted);
    opacity: 0;
    transition: opacity 0.5s ease 0.35s;
}
body.menu-open .mobile-menu .mm-footer {
    opacity: 1;
}
body.menu-open {
    overflow: hidden;
}

/* ---------- Hero ---------- */
.hero {
    position: relative;
    min-height: 100svh;
    display: flex;
    align-items: center;
    overflow: hidden;
}
.hero-canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}
.hero-glow {
    position: absolute;
    width: 70vmax;
    height: 70vmax;
    right: -22vmax;
    top: -26vmax;
    border-radius: 50%;
    background: radial-gradient(
        circle,
        rgba(57, 57, 255, 0.22) 0%,
        rgba(57, 57, 255, 0.06) 42%,
        transparent 68%
    );
    pointer-events: none;
}
.hero-fade {
    position: absolute;
    inset: auto 0 0 0;
    height: 32vh;
    background: linear-gradient(to bottom, transparent, var(--ink));
    pointer-events: none;
}
.hero-content {
    position: relative;
    z-index: 2;
    width: 100%;
}
.hero-title {
    margin-top: 26px;
    text-shadow: 0 4px 60px rgba(7, 11, 18, 0.8);
}
.hero-title .line {
    display: block;
    overflow: hidden;
}
.hero-title .line > span {
    display: inline-block;
    transform: translateY(110%);
    animation: rise 1.1s var(--ease) forwards;
}
.hero-title .line:nth-child(2) > span {
    animation-delay: 0.12s;
}
@keyframes rise {
    to {
        transform: translateY(0);
    }
}
.hero-sub {
    margin-top: 30px;
    max-width: 520px;
    font-size: clamp(15px, 1.6vw, 18px);
    color: var(--muted);
}
.hero-sub strong {
    color: var(--white);
    font-weight: 500;
}
.hero-actions {
    margin-top: 42px;
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
}
.hero-meta {
    margin-top: 56px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}
.chip {
    font-size: 11px;
    font-weight: 400;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--muted);
    border: 1px solid var(--line);
    background: rgba(236, 239, 248, 0.03);
    padding: 8px 16px;
    border-radius: 100px;
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
}
.fade-up {
    opacity: 0;
    transform: translateY(24px);
    animation: fadeUp 1s var(--ease) forwards;
}
@keyframes fadeUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
.d-1 {
    animation-delay: 0.25s;
}
.d-2 {
    animation-delay: 0.4s;
}
.d-3 {
    animation-delay: 0.55s;
}
.d-4 {
    animation-delay: 0.7s;
}

/* Scroll hint */
.scroll-hint {
    position: absolute;
    bottom: 34px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    font-size: 10px;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--faint);
}
.scroll-hint::after {
    content: "";
    width: 1px;
    height: 44px;
    background: linear-gradient(to bottom, var(--blurple-bright), transparent);
    animation: drip 2.2s ease-in-out infinite;
}
@keyframes drip {
    0% {
        transform: scaleY(0);
        transform-origin: top;
    }
    45% {
        transform: scaleY(1);
        transform-origin: top;
    }
    55% {
        transform: scaleY(1);
        transform-origin: bottom;
    }
    100% {
        transform: scaleY(0);
        transform-origin: bottom;
    }
}

/* Page hero (inner pages) */
.page-hero {
    position: relative;
    padding: calc(76px + clamp(70px, 11vw, 130px)) 0 clamp(40px, 6vw, 70px);
    overflow: hidden;
}
.page-hero .hero-canvas {
    opacity: 0.6;
}
.page-hero .hero-glow {
    width: 55vmax;
    height: 55vmax;
    top: -30vmax;
}
.page-hero p.lead {
    margin-top: 22px;
    max-width: 620px;
    color: var(--muted);
    font-size: clamp(15px, 1.6vw, 18px);
}

/* ---------- Statement ---------- */
.statement {
    font-size: clamp(22px, 3.4vw, 40px);
    line-height: 1.4;
    font-weight: 400;
    max-width: 1000px;
}
.statement .hl {
    color: var(--blurple-bright);
}
.statement-note {
    margin-top: 34px;
    max-width: 420px;
    color: var(--muted);
    font-size: 14px;
}

/* ---------- Stats ---------- */
.stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
}
.stat {
    padding: clamp(28px, 4vw, 48px) clamp(16px, 3vw, 40px);
    border-left: 1px solid var(--line);
}
.stat:first-child {
    border-left: 0;
}
.stat .num {
    font-family: var(--font-display);
    font-size: clamp(26px, 4vw, 48px);
    color: var(--white);
    line-height: 1;
}
.stat .num em {
    font-style: normal;
    color: var(--blurple);
}
.stat .lbl {
    margin-top: 12px;
    font-size: 11px;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--muted);
}

/* ---------- Cards / Work ---------- */
.card {
    position: relative;
    display: block;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: linear-gradient(
        160deg,
        rgba(236, 239, 248, 0.04),
        rgba(236, 239, 248, 0.01)
    );
    overflow: hidden;
    transition:
        transform 0.55s var(--ease),
        border-color 0.55s ease,
        box-shadow 0.55s var(--ease);
    will-change: transform;
}
.card:hover {
    transform: translateY(-6px);
    border-color: rgba(57, 57, 255, 0.5);
    box-shadow:
        0 24px 60px rgba(0, 0, 0, 0.5),
        0 0 0 1px rgba(57, 57, 255, 0.25),
        0 0 60px rgba(57, 57, 255, 0.12);
}
.card-media {
    position: relative;
    overflow: hidden;
    aspect-ratio: 3 / 2;
}
.card-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition:
        transform 0.9s var(--ease),
        filter 0.9s ease;
    filter: saturate(0.9);
}
.card:hover .card-media img {
    transform: scale(1.05);
    filter: saturate(1.05);
}
.card-media::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(7, 11, 18, 0.55), transparent 55%);
}
.card-body {
    padding: clamp(22px, 3vw, 34px);
    position: relative;
}
.card-num {
    position: absolute;
    top: 18px;
    right: 22px;
    font-family: var(--font-display);
    font-size: 13px;
    color: var(--faint);
    transition: color 0.4s ease;
}
.card:hover .card-num {
    color: var(--blurple-bright);
}
.card-body h3 {
    padding-right: 56px;
}
.card-body p {
    margin-top: 12px;
    color: var(--muted);
    font-size: 14px;
    max-width: 480px;
}
.card-body .arrow-link {
    margin-top: 20px;
}

/* Work grid: 1 feature + 2 half */
.work-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(18px, 2.5vw, 28px);
}
.work-grid .card.feature {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 1.15fr 1fr;
}
.work-grid .card.feature .card-media {
    aspect-ratio: auto;
    min-height: 320px;
    order: 2;
}
.work-grid .card.feature .card-media::after {
    background: linear-gradient(
        to right,
        rgba(7, 11, 18, 0.5),
        transparent 50%
    );
}
.work-grid .card.feature .card-body {
    order: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: clamp(28px, 4vw, 56px);
}

/* Tags */
.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.tag {
    font-size: 10px;
    font-weight: 500;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--blurple-bright);
    background: var(--blurple-soft);
    border: 1px solid rgba(57, 57, 255, 0.3);
    padding: 5px 12px;
    border-radius: 100px;
}

/* ---------- Project rows (alternating) ---------- */
.project {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(28px, 5vw, 72px);
    align-items: center;
    padding: clamp(44px, 7vw, 90px) 0;
    border-top: 1px solid var(--line);
}
.project:first-of-type {
    border-top: 0;
}
.project.flip .p-media {
    order: 2;
}
.p-media {
    position: relative;
}
.p-media .frame {
    position: relative;
    border-radius: var(--radius);
    overflow: hidden;
    border: 1px solid var(--line);
    background: var(--ink-2);
    cursor: zoom-in;
    transition:
        transform 0.6s var(--ease),
        border-color 0.5s ease,
        box-shadow 0.6s var(--ease);
}
.p-media .frame:hover {
    transform: translateY(-5px);
    border-color: rgba(57, 57, 255, 0.45);
    box-shadow:
        0 26px 60px rgba(0, 0, 0, 0.5),
        0 0 50px rgba(57, 57, 255, 0.1);
}
.p-media .frame img {
    width: 100%;
    transition: transform 0.9s var(--ease);
}
.p-media .frame:hover img {
    transform: scale(1.04);
}
.p-media .p-num {
    position: absolute;
    top: -26px;
    left: -8px;
    z-index: 2;
    font-family: var(--font-display);
    font-size: clamp(44px, 6vw, 72px);
    line-height: 1;
    color: transparent;
    -webkit-text-stroke: 1px rgba(236, 239, 248, 0.18);
    pointer-events: none;
}
.p-body .tags {
    margin-bottom: 18px;
}
.p-body h3 {
    margin-bottom: 16px;
}
.p-body .goal {
    color: var(--white);
    font-weight: 400;
    font-size: 15px;
    margin-bottom: 12px;
}
.p-body p {
    color: var(--muted);
    font-size: 15px;
}
.p-body p + p {
    margin-top: 12px;
}
.p-links {
    margin-top: 26px;
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    align-items: center;
}
.qr {
    width: 92px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--line);
    overflow: hidden;
}

/* ---------- About ---------- */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(32px, 6vw, 80px);
    align-items: center;
}
.about-photo {
    position: relative;
}
.about-photo img {
    width: min(100%, 460px);
    margin-inline: auto;
    filter: drop-shadow(0 30px 60px rgba(57, 57, 255, 0.15));
}
.about-photo::before {
    content: "";
    position: absolute;
    inset: 8%;
    background: radial-gradient(
        circle,
        rgba(57, 57, 255, 0.16),
        transparent 65%
    );
    z-index: -1;
}
.about-copy .statement {
    font-size: clamp(19px, 2.4vw, 28px);
}
.about-copy > p {
    margin-top: 20px;
    color: var(--muted);
}
.about-copy .btn,
.about-copy .arrow-link {
    margin-top: 30px;
}

/* Skill chips */
.skill-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 28px;
}

/* Timeline */
.timeline {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: clamp(18px, 2.5vw, 28px);
}
.tl-item {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: clamp(24px, 3vw, 36px);
    background: linear-gradient(160deg, rgba(236, 239, 248, 0.03), transparent);
    position: relative;
    overflow: hidden;
    transition:
        transform 0.5s var(--ease),
        border-color 0.5s ease;
}
.tl-item:hover {
    transform: translateY(-5px);
    border-color: rgba(57, 57, 255, 0.4);
}
.tl-item .flag {
    font-size: 26px;
    line-height: 1;
}
.tl-item h4 {
    margin-top: 16px;
    font-weight: 600;
    font-size: 17px;
}
.tl-item p {
    margin-top: 8px;
    color: var(--muted);
    font-size: 14px;
}
.tl-item .tl-num {
    position: absolute;
    right: 18px;
    top: 14px;
    font-family: var(--font-display);
    color: transparent;
    -webkit-text-stroke: 1px rgba(236, 239, 248, 0.15);
    font-size: 30px;
}

/* ---------- Marquee ---------- */
.marquee {
    border-block: 1px solid var(--line);
    padding: 20px 0;
    overflow: hidden;
    display: flex;
    user-select: none;
}
.marquee-track {
    display: flex;
    flex-shrink: 0;
    gap: 0;
    min-width: 100%;
    animation: scroll-x 30s linear infinite;
}
@keyframes scroll-x {
    to {
        transform: translateX(-100%);
    }
}
.marquee span {
    display: inline-flex;
    align-items: center;
    gap: 28px;
    padding-right: 28px;
    font-family: var(--font-display);
    font-size: clamp(13px, 1.6vw, 17px);
    text-transform: uppercase;
    color: var(--faint);
    white-space: nowrap;
}
.marquee span::after {
    content: "✦";
    color: var(--blurple-bright);
    font-size: 12px;
}

/* ---------- Gallery ---------- */
.masonry {
    columns: 3;
    column-gap: 18px;
}
.masonry a {
    display: block;
    margin-bottom: 18px;
    border-radius: var(--radius-sm);
    overflow: hidden;
    border: 1px solid var(--line);
    position: relative;
    cursor: zoom-in;
    transition:
        transform 0.5s var(--ease),
        border-color 0.4s ease,
        box-shadow 0.5s var(--ease);
}
.masonry a:hover {
    transform: translateY(-4px);
    border-color: rgba(57, 57, 255, 0.5);
    box-shadow: 0 18px 44px rgba(0, 0, 0, 0.5);
}
.masonry img {
    width: 100%;
    transition: transform 0.8s var(--ease);
}
.masonry a:hover img {
    transform: scale(1.04);
}

/* Category grid (photo & video) */
.cat-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: clamp(18px, 2.5vw, 28px);
}
.cat-card {
    position: relative;
    display: block;
    border-radius: var(--radius);
    overflow: hidden;
    border: 1px solid var(--line);
    aspect-ratio: 16 / 10;
    transition:
        transform 0.55s var(--ease),
        border-color 0.5s ease,
        box-shadow 0.55s var(--ease);
}
.cat-card:hover {
    transform: translateY(-6px);
    border-color: rgba(57, 57, 255, 0.5);
    box-shadow:
        0 24px 60px rgba(0, 0, 0, 0.55),
        0 0 50px rgba(57, 57, 255, 0.1);
}
.cat-card img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.9s var(--ease);
}
.cat-card:hover img {
    transform: scale(1.06);
}
.cat-card .cat-label {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: clamp(20px, 3vw, 32px);
    background: linear-gradient(to top, rgba(7, 11, 18, 0.82), transparent 60%);
}
.cat-card .cat-label h3 {
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.cat-card .cat-label h3 svg {
    width: 18px;
    height: 18px;
    color: var(--blurple-bright);
    transition: transform 0.4s var(--ease);
}
.cat-card:hover .cat-label h3 svg {
    transform: translate(4px, -4px);
}
.cat-card .cat-label p {
    margin-top: 6px;
    font-size: 13px;
    color: var(--muted);
}

/* ---------- Lightbox ---------- */
.lightbox {
    position: fixed;
    inset: 0;
    z-index: 300;
    background: rgba(7, 11, 18, 0.94);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition:
        opacity 0.35s ease,
        visibility 0.35s ease;
}
.lightbox.open {
    opacity: 1;
    visibility: visible;
}
.lightbox img {
    max-width: min(92vw, 1400px);
    max-height: 86vh;
    border-radius: var(--radius-sm);
    box-shadow: 0 30px 90px rgba(0, 0, 0, 0.7);
    transform: scale(0.96);
    transition: transform 0.35s var(--ease);
}
.lightbox.open img {
    transform: scale(1);
}
.lb-btn {
    position: absolute;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 1px solid var(--line-strong);
    background: rgba(236, 239, 248, 0.04);
    display: grid;
    place-items: center;
    color: var(--white);
    transition:
        border-color 0.3s ease,
        background-color 0.3s ease,
        transform 0.3s ease;
}
.lb-btn:hover {
    border-color: var(--blurple-bright);
    background: var(--blurple-soft);
    transform: scale(1.06);
}
.lb-btn svg {
    width: 18px;
    height: 18px;
}
.lb-close {
    top: 22px;
    right: 22px;
}
.lb-prev {
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
}
.lb-next {
    right: 18px;
    top: 50%;
    transform: translateY(-50%);
}
.lb-prev:hover,
.lb-next:hover {
    transform: translateY(-50%) scale(1.06);
}
.lb-count {
    position: absolute;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 12px;
    letter-spacing: 0.2em;
    color: var(--muted);
}

/* ---------- Forms ---------- */
.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}
.field {
    position: relative;
    grid-column: span 1;
}
.field.full {
    grid-column: 1 / -1;
}
.field input,
.field textarea {
    width: 100%;
    background: rgba(236, 239, 248, 0.03);
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    color: var(--white);
    font: inherit;
    font-size: 15px;
    padding: 24px 18px 12px;
    transition:
        border-color 0.35s ease,
        background-color 0.35s ease,
        box-shadow 0.35s ease;
}
.field textarea {
    min-height: 170px;
    resize: vertical;
}
.field label {
    position: absolute;
    left: 18px;
    top: 18px;
    font-size: 14px;
    color: var(--muted);
    pointer-events: none;
    transition:
        transform 0.3s var(--ease),
        font-size 0.3s ease,
        color 0.3s ease,
        top 0.3s ease;
}
.field input:focus,
.field textarea:focus {
    outline: none;
    border-color: var(--blurple);
    background: rgba(57, 57, 255, 0.05);
    box-shadow: 0 0 0 3px rgba(57, 57, 255, 0.15);
}
.field input:focus + label,
.field input:not(:placeholder-shown) + label,
.field textarea:focus + label,
.field textarea:not(:placeholder-shown) + label {
    top: 9px;
    font-size: 10.5px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--blurple-bright);
}
.checkbox {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    font-size: 13px;
    color: var(--muted);
    cursor: pointer;
}
.checkbox input {
    appearance: none;
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    flex: 0 0 20px;
    margin-top: 2px;
    border: 1px solid var(--line-strong);
    border-radius: 6px;
    background: rgba(236, 239, 248, 0.03);
    display: grid;
    place-items: center;
    cursor: pointer;
    transition:
        border-color 0.3s ease,
        background-color 0.3s ease;
}
.checkbox input::after {
    content: "";
    width: 10px;
    height: 6px;
    border-left: 2px solid #fff;
    border-bottom: 2px solid #fff;
    transform: rotate(-45deg) scale(0);
    transition: transform 0.25s var(--ease);
}
.checkbox input:checked {
    background: var(--blurple);
    border-color: var(--blurple);
}
.checkbox input:checked::after {
    transform: rotate(-45deg) scale(1) translate(1px, -1px);
}
.checkbox a {
    color: var(--blurple-bright);
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* Contact split */
.contact-grid {
    display: grid;
    grid-template-columns: 0.85fr 1.15fr;
    gap: clamp(36px, 6vw, 80px);
    align-items: start;
}
.contact-info .info-item {
    display: block;
    padding: 22px 0;
    border-bottom: 1px solid var(--line);
}
.contact-info .info-item .k {
    font-size: 11px;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--muted);
    margin-bottom: 6px;
}
.contact-info .info-item .v {
    font-size: clamp(16px, 1.8vw, 19px);
    font-weight: 400;
    color: var(--white);
    transition: color 0.3s ease;
}
a.info-item:hover .v {
    color: var(--blurple-bright);
}

/* ---------- CTA band ---------- */
.cta-band {
    position: relative;
    overflow: hidden;
    border-top: 1px solid var(--line);
}
.cta-band .container {
    padding-block: clamp(80px, 12vw, 150px);
    text-align: center;
    position: relative;
    z-index: 2;
}
.cta-band .display {
    font-size: clamp(26px, 5.4vw, 64px);
}
.cta-band .display .accent {
    display: block;
}
.cta-band p {
    margin: 22px auto 0;
    max-width: 440px;
    color: var(--muted);
}
.cta-band .btn {
    margin-top: 38px;
}
.cta-glow {
    position: absolute;
    left: 50%;
    bottom: -46vmax;
    transform: translateX(-50%);
    width: 90vmax;
    height: 66vmax;
    border-radius: 50%;
    background: radial-gradient(
        ellipse at center,
        rgba(57, 57, 255, 0.28) 0%,
        rgba(57, 57, 255, 0.07) 40%,
        transparent 66%
    );
    pointer-events: none;
}

/* ---------- Footer ---------- */
footer {
    border-top: 1px solid var(--line);
    padding: clamp(40px, 6vw, 64px) 0 34px;
    position: relative;
}
.footer-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 32px;
    align-items: flex-start;
}
.footer-brand p {
    margin-top: 14px;
    color: var(--muted);
    font-size: 13px;
    max-width: 300px;
}
.footer-col .k {
    font-size: 11px;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--faint);
    margin-bottom: 16px;
}
.footer-col ul {
    list-style: none;
}
.footer-col li + li {
    margin-top: 10px;
}
.footer-col a {
    font-size: 14px;
    color: var(--muted);
    transition: color 0.3s ease;
}
.footer-col a:hover {
    color: var(--blurple-bright);
}
.socials {
    display: flex;
    gap: 10px;
}
.socials a {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: 1px solid var(--line-strong);
    display: grid;
    place-items: center;
    color: var(--muted);
    transition:
        color 0.3s ease,
        border-color 0.3s ease,
        background-color 0.3s ease,
        transform 0.3s var(--ease);
}
.socials a:hover {
    color: #fff;
    border-color: var(--blurple);
    background: var(--blurple);
    transform: translateY(-3px);
    box-shadow: 0 8px 22px rgba(57, 57, 255, 0.35);
}
.socials svg {
    width: 17px;
    height: 17px;
}
.footer-bottom {
    margin-top: clamp(36px, 5vw, 56px);
    padding-top: 24px;
    border-top: 1px solid var(--line);
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: space-between;
    font-size: 12px;
    color: var(--faint);
}
.footer-bottom a:hover {
    color: var(--blurple-bright);
}

/* ---------- Reveal on scroll ---------- */
[data-reveal] {
    opacity: 0;
    transform: translateY(28px);
    transition:
        opacity 0.9s var(--ease),
        transform 0.9s var(--ease);
    transition-delay: var(--rd, 0s);
}
[data-reveal].in {
    opacity: 1;
    transform: none;
}

/* ---------- Simple page (thanks / privacy) ---------- */
.simple-hero {
    min-height: 82svh;
    display: flex;
    align-items: center;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.simple-hero .container {
    position: relative;
    z-index: 2;
}
.prose {
    max-width: 760px;
}
.prose h2 {
    font-weight: 600;
    font-size: 20px;
    margin: 36px 0 12px;
}
.prose p,
.prose li {
    color: var(--muted);
    font-size: 15px;
    margin-top: 10px;
}
.prose ul {
    padding-left: 20px;
}
.prose a {
    color: var(--blurple-bright);
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 980px) {
    .nav-links {
        display: none;
    }
    .nav-cta {
        display: none;
    }
    .burger {
        display: block;
    }
    .work-grid .card.feature {
        grid-template-columns: 1fr;
    }
    .work-grid .card.feature .card-media {
        order: 1;
        aspect-ratio: 3 / 2;
        min-height: 0;
    }
    .work-grid .card.feature .card-body {
        order: 2;
    }
    .masonry {
        columns: 2;
    }
    .contact-grid {
        grid-template-columns: 1fr;
    }
    .about-grid {
        grid-template-columns: 1fr;
    }
    .about-photo {
        order: -1;
    }
    .stats {
        grid-template-columns: 1fr 1fr;
    }
    .stat:nth-child(3) {
        border-left: 0;
    }
    .stat:nth-child(n + 3) {
        border-top: 1px solid var(--line);
    }
}
@media (max-width: 700px) {
    .work-grid {
        grid-template-columns: 1fr;
    }
    .project {
        grid-template-columns: 1fr;
        gap: 28px;
    }
    .project.flip .p-media {
        order: 0;
    }
    .cat-grid {
        grid-template-columns: 1fr;
    }
    .timeline {
        grid-template-columns: 1fr;
    }
    .form-grid {
        grid-template-columns: 1fr;
    }
    .field {
        grid-column: 1 / -1;
    }
    .masonry {
        columns: 1;
    }
    .qr {
        display: none; /* QR codes are for scanning from a second screen */
    }
    .lb-prev {
        left: 8px;
    }
    .lb-next {
        right: 8px;
    }
    .hero-meta {
        gap: 8px;
    }
}

/* ---------- Reduced motion ---------- */
@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;
    }
    [data-reveal] {
        opacity: 1;
        transform: none;
    }
    .hero-title .line > span {
        transform: none;
    }
    .fade-up {
        opacity: 1;
        transform: none;
    }
}

/* ============================================================
   Branded AI Assistant — no-screenshot project (chat mockup)
   ============================================================ */
.assist-demo {
  position: relative;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(160deg, rgba(236, 239, 248, 0.05), rgba(236, 239, 248, 0.01));
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.4);
  display: flex;
  flex-direction: column;
}
.assist-demo::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(120% 80% at 100% 0%, rgba(57, 57, 255, 0.16), transparent 60%);
  pointer-events: none;
}
.assist-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--line);
  position: relative;
  z-index: 1;
}
.assist-ava {
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: linear-gradient(160deg, rgba(236, 239, 248, 0.1), rgba(236, 239, 248, 0.02));
  border: 1px solid var(--line-strong);
  box-shadow: 0 4px 14px rgba(57, 57, 255, 0.25);
}
.assist-ava img {
  width: 22px;
  height: 22px;
  filter: drop-shadow(0 2px 6px rgba(57, 57, 255, 0.6));
}
.assist-id {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}
.assist-id b {
  font-weight: 600;
  font-size: 14px;
}
.assist-id span {
  font-size: 11px;
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.assist-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #39d98a;
  box-shadow: 0 0 0 0 rgba(57, 217, 138, 0.5);
  animation: assistLive 2s infinite;
}
@keyframes assistLive {
  0% { box-shadow: 0 0 0 0 rgba(57, 217, 138, 0.5); }
  70% { box-shadow: 0 0 0 6px rgba(57, 217, 138, 0); }
  100% { box-shadow: 0 0 0 0 rgba(57, 217, 138, 0); }
}
.assist-tagline {
  margin-left: auto;
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--blurple-bright);
}
.assist-msgs {
  padding: 20px 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: relative;
  z-index: 1;
  flex: 1;
}
.bubble {
  max-width: 84%;
  padding: 11px 15px;
  border-radius: 16px;
  font-size: 13.5px;
  line-height: 1.5;
}
.bubble.user {
  align-self: flex-end;
  background: var(--blurple);
  color: #fff;
  border-bottom-right-radius: 5px;
}
.bubble.bot {
  align-self: flex-start;
  background: rgba(236, 239, 248, 0.06);
  border: 1px solid var(--line);
  border-bottom-left-radius: 5px;
  color: var(--white);
}
.bubble.typing {
  display: inline-flex;
  gap: 4px;
  align-self: flex-start;
  padding: 15px 16px;
}
.bubble.typing i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--muted);
  animation: assistType 1.2s infinite;
}
.bubble.typing i:nth-child(2) { animation-delay: 0.15s; }
.bubble.typing i:nth-child(3) { animation-delay: 0.3s; }
@keyframes assistType {
  0%, 60%, 100% { opacity: 0.3; transform: translateY(0); }
  30% { opacity: 1; transform: translateY(-3px); }
}
.assist-input {
  margin-top: auto;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px 12px 16px;
  border-top: 1px solid var(--line);
  color: var(--faint);
  font-size: 13px;
  position: relative;
  z-index: 1;
}
.assist-input .send {
  margin-left: auto;
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  border-radius: 9px;
  background: var(--blurple);
  display: grid;
  place-items: center;
}
.assist-input .send svg {
  width: 14px;
  height: 14px;
  color: #fff;
}
/* Body callout pointing to the live widget */
.assist-note {
  color: var(--white);
  font-weight: 400;
  border-left: 2px solid var(--blurple);
  padding-left: 16px;
}
.assist-arrow {
  display: inline-block;
  color: var(--blurple-bright);
  font-weight: 600;
  animation: assistNudge 1.6s var(--ease) infinite;
}
@keyframes assistNudge {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(4px, 4px); }
}
.assist-live-chip {
  display: inline-flex;
  align-items: center;
  gap: 9px;
}

/* ============================================================
   3D logomark (homepage hero, desktop only) — soft-shaded SVG,
   gentle float + cursor tilt.
   ============================================================ */
.logo3d-wrap {
  display: none;
  position: absolute;
  top: 50%;
  right: calc(var(--gutter) - 10px);
  width: clamp(360px, 36vw, 560px);
  aspect-ratio: 1;
  z-index: 1;
  perspective: 1100px;
  opacity: 0;
  transform: translateY(-52%);
  /* float bob (translateY) lives here, layered under the centering offset */
  animation:
    logo3dIn 1.2s ease 0.5s forwards,
    logo3dFloat 6s ease-in-out 0.5s infinite;
}
@keyframes logo3dIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
@keyframes logo3dFloat {
  0%,
  100% {
    transform: translateY(calc(-52% - 11px));
  }
  50% {
    transform: translateY(calc(-52% + 11px));
  }
}
.logo3d-wrap::before {
  /* soft blurple halo behind the mark */
  content: "";
  position: absolute;
  inset: 4%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(57, 57, 255, 0.2), transparent 62%);
  pointer-events: none;
}
.logo3d-tilt {
  width: 100%;
  height: 100%;
  transform-style: preserve-3d;
  /* --rx/--ry set by JS from the cursor (3D transforms need a real element,
     not the <svg>, which browsers flatten) */
  transform: rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
  transition: transform 0.3s var(--ease);
  will-change: transform;
}
.logo3d {
  width: 100%;
  height: 100%;
  display: block;
  overflow: visible;
}
@media (min-width: 1200px) {
  .logo3d-wrap {
    display: block;
  }
}
@media (prefers-reduced-motion: reduce) {
  .logo3d-wrap {
    animation: logo3dIn 1.2s ease 0.5s forwards;
    transform: translateY(-52%);
  }
}
