/* ═══════════════════════════════════════════════════════════════
   AEGYRIX.COM — Brutalist-Editorial Design System
   Conformant with aegyrix-suite/docs/design-tokens.md
     - Token vocabulary (surface / text / accent / semantic / structure)
     - Inter body + JetBrains Mono code (brand-guidelines.md)
     - data-brand='<product>' per-product accent overrides
     - WCAG 2.2 AA focus rings, prefers-reduced-motion honored
   ═══════════════════════════════════════════════════════════════ */

/* ── TOKENS ── */
:root {
    color-scheme: dark;

    /* ── Surface stack (suite vocabulary) ── */
    --bg:              #0a0a10;
    --surface:         #141420;
    --surface-raised:  #10101a;
    --surface-sunken:  #0d0d15;
    --border:          rgb(255 255 255 / 6%);
    --border-strong:   rgb(255 255 255 / 14%);

    /* Legacy aliases (kept for zero-regression migration; prefer suite names above) */
    --bg-card:    var(--surface);
    --bg-raised:  var(--surface-raised);

    /* ── Text ── */
    --text:         #e0e0e6;
    --text-muted:   #8888a0;
    --text-subtle:  #505068;
    --text-inverse: #0a0a10;

    /* Legacy alias */
    --text-dim:     var(--text-subtle);

    /* ── Accent (default: Aegyrix cyan; per-product override below) ── */
    --accent:         #00d4ff;
    --accent-hover:   #33dcff;
    --accent-active:  #00a8cc;
    --accent-fg:      #0a0a10;
    --accent-subtle:  rgb(0 212 255 / 9%);
    --accent-2:       #7b61ff;

    /* Legacy aliases */
    --accent-dim:     var(--accent-subtle);
    --accent-glow:    rgb(0 212 255 / 31%);
    --accent-2-glow:  rgb(123 97 255 / 25%);

    /* ── Semantic ── */
    --ok:      #34d399;
    --warn:    #fbbf24;
    --danger:  #f87171;
    --info:    #60a5fa;

    /* ── Structure ── */
    --radius-sm:   4px;
    --radius-md:   8px;
    --radius-lg:   12px;
    --radius-full: 9999px;

    --space-1:  4px;
    --space-2:  8px;
    --space-3:  12px;
    --space-4:  16px;
    --space-5:  20px;
    --space-6:  24px;
    --space-7:  32px;
    --space-8:  40px;
    --space-9:  48px;
    --space-10: 64px;
    --space-11: 80px;
    --space-12: 96px;

    --shadow-sm: 0 1px 2px rgb(0 0 0 / 40%);
    --shadow-md: 0 4px 12px rgb(0 0 0 / 50%);
    --shadow-lg: 0 12px 32px rgb(0 0 0 / 60%);

    /* ── Typography (brand-guidelines.md) ── */
    --font-sans: 'Inter', system-ui, -apple-system, Segoe UI, sans-serif;
    --font-mono: 'JetBrains Mono', ui-monospace, Menlo, Consolas, monospace;

    /* Legacy aliases */
    --sans: var(--font-sans);
    --mono: var(--font-mono);
    --white: #f4f4f8;

    --ease:   cubic-bezier(0.16, 1, 0.3, 1);
    --max-w:  1280px;
    --gutter: clamp(1.5rem, 4vw, 3rem);
}

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

/* ── Focus-visible: 2px accent ring, 2px offset (design-tokens.md) ── */
:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
    border-radius: var(--radius-sm);
}

/* ── RESET ── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

/* ── PARTICLE CANVAS ── */
#particleCanvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--sans);
    font-size: clamp(0.95rem, 1vw, 1.05rem);
    line-height: 1.65;
    color: var(--text);
    background: var(--bg);
    overflow-x: hidden;
    position: relative;
}

a {
    color: var(--accent);
    text-decoration: none;
    transition: opacity 0.2s;
}
a:hover { opacity: 0.8; }

::selection {
    background: var(--accent);
    color: var(--bg);
}

/* ── NAV ── */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem var(--gutter);
    background: rgb(10, 10, 16, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgb(255,255,255,0.06);
    transition: transform 0.4s var(--ease);
}

.nav--hidden { transform: translateY(-100%); }

.nav__logo {
    font-family: var(--mono);
    font-weight: 700;
    font-size: 0.85rem;
    letter-spacing: 0.15em;
    color: var(--white);
}

.nav__mark {
    color: var(--accent);
    margin-right: 0.25rem;
}

.nav__links {
    display: flex;
    gap: 2rem;
    font-family: var(--mono);
    font-size: 0.75rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.nav__links a {
    color: var(--text-muted);
    transition: color 0.2s;
}
.nav__links a:hover { color: var(--accent); opacity: 1; }

.nav__toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}
.nav__toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text);
    transition: transform 0.3s var(--ease), opacity 0.3s;
}

/* ── HERO ── */
.hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 8rem var(--gutter) 4rem;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -30%;
    left: -10%;
    width: 60%;
    height: 80%;
    background: radial-gradient(ellipse, var(--accent-glow) 0%, transparent 70%);
    filter: blur(100px);
    pointer-events: none;
    z-index: 0;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: -20%;
    right: -10%;
    width: 50%;
    height: 70%;
    background: radial-gradient(ellipse, var(--accent-2-glow) 0%, transparent 70%);
    filter: blur(120px);
    pointer-events: none;
    z-index: 0;
}

.hero__grid {
    display: grid;
    grid-template-columns: 1fr 0.4fr;
    gap: 4rem;
    align-items: center;
    max-width: var(--max-w);
    margin: 0 auto;
    width: 100%;
    position: relative;
    z-index: 1;
}

.hero__label {
    font-family: var(--mono);
    font-size: 0.75rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 1.5rem;
}

.hero__title {
    font-weight: 700;
    font-size: clamp(2.8rem, 6vw, 5.5rem);
    line-height: 1.05;
    color: var(--white);
    margin-bottom: 2rem;
}

.hero__line {
    display: block;
}

.hero__line.accent {
    color: var(--accent);
}

.blink {
    animation: blink 1s step-end infinite;
}

@keyframes blink {
    50% { opacity: 0; }
}

.hero__sub {
    font-size: clamp(1rem, 1.3vw, 1.2rem);
    color: var(--text-muted);
    max-width: 520px;
    line-height: 1.7;
}

.hero__visual {
    display: flex;
    justify-content: center;
    align-items: center;
}

.hero__glyph {
    width: clamp(180px, 20vw, 300px);
    aspect-ratio: 1;
    animation: rotate 30s linear infinite;
}

.hero__glyph svg {
    width: 100%;
    height: 100%;
}

@keyframes rotate {
    to { transform: rotate(360deg); }
}

.hero__scroll {
    position: absolute;
    bottom: 2rem;
    left: var(--gutter);
    display: flex;
    align-items: center;
    gap: 1rem;
    font-family: var(--mono);
    font-size: 0.65rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--text-dim);
    z-index: 1;
}

.hero__scroll-line {
    width: 60px;
    height: 1px;
    background: var(--text-dim);
    position: relative;
    overflow: hidden;
}
.hero__scroll-line::after {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    width: 20px;
    height: 1px;
    background: var(--accent);
    animation: scroll-line 2s ease-in-out infinite;
}

@keyframes scroll-line {
    0% { transform: translateX(-20px); }
    100% { transform: translateX(80px); }
}

/* ── STATS ── */
.stats {
    border-top: 1px solid rgb(255,255,255,0.06);
    border-bottom: 1px solid rgb(255,255,255,0.06);
    padding: 3rem var(--gutter);
    background: var(--bg-raised);
    position: relative;
    z-index: 1;
}

.stats__grid {
    max-width: var(--max-w);
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    text-align: center;
}

.stats__number {
    display: block;
    font-family: var(--mono);
    font-weight: 700;
    font-size: clamp(2rem, 3vw, 3rem);
    color: var(--accent);
    line-height: 1.1;
    text-shadow: 0 0 20px var(--accent-glow);
}

.stats__label {
    display: block;
    font-family: var(--mono);
    font-size: 0.7rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-top: 0.5rem;
}

/* ── PROJECTS ── */
.projects {
    padding: 8rem var(--gutter);
    max-width: var(--max-w);
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.projects__header {
    margin-bottom: 5rem;
}

.section-label {
    font-family: var(--mono);
    font-size: 0.7rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 0.75rem;
}

.section-title {
    font-size: clamp(2rem, 4vw, 3.5rem);
    font-weight: 700;
    color: var(--white);
}

/* Project cards — staggered offset */
.project {
    display: grid;
    grid-template-columns: 80px 1fr;
    gap: 2rem;
    padding: 3rem 0;
    border-top: 1px solid rgb(255,255,255,0.06);
    position: relative;
    transition: background 0.3s var(--ease);
}

.project:hover {
    background: linear-gradient(90deg, var(--accent-dim) 0%, transparent 60%);
}

.project:last-child {
    border-bottom: 1px solid rgb(255,255,255,0.06);
}

.project__index {
    font-family: var(--mono);
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-dim);
    padding-top: 0.25rem;
}

.project__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.tag {
    font-family: var(--mono);
    font-size: 0.65rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    padding: 0.3rem 0.7rem;
    border: 1px solid rgb(0, 212, 255, 0.15);
    border-radius: 2px;
    color: var(--text-muted);
    background: rgb(0, 212, 255, 0.05);
}

.project__name {
    font-size: clamp(1.6rem, 3vw, 2.4rem);
    font-weight: 700;
    color: var(--white);
    margin-bottom: 0.3rem;
    transition: color 0.2s;
}

.project:hover .project__name {
    color: var(--accent);
}

.project__tagline {
    font-family: var(--mono);
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 1.25rem;
}

.project__desc {
    color: var(--text);
    max-width: 640px;
    margin-bottom: 1.5rem;
    line-height: 1.75;
}

.project__features {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    font-family: var(--mono);
    font-size: 0.7rem;
    color: var(--text-muted);
    letter-spacing: 0.02em;
    margin-bottom: 0.75rem;
}

.project__features span::before {
    content: '→ ';
    color: var(--accent);
}

.project__platforms {
    font-family: var(--mono);
    font-size: 0.7rem;
    color: var(--text-dim);
    letter-spacing: 0.05em;
    margin-bottom: 1.5rem;
}

.project__links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

/* Featured project highlight */
.project--featured {
    padding-left: 2rem;
    border-left: 2px solid var(--accent);
    margin-left: -2rem;
    box-shadow: inset 4px 0 20px -10px var(--accent-glow);
}

/* Teaser */
.project--teaser .project__name {
    color: var(--text-muted);
    font-style: italic;
}

/* ── BUTTONS ── */
.btn {
    font-family: var(--mono);
    font-size: 0.7rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    padding: 0.65rem 1.4rem;
    border: 1px solid;
    border-radius: 2px;
    cursor: pointer;
    transition: all 0.25s var(--ease);
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.btn--primary {
    background: var(--accent);
    border-color: var(--accent);
    color: var(--bg);
    box-shadow: 0 0 16px var(--accent-glow);
}
.btn--primary:hover {
    background: transparent;
    color: var(--accent);
    box-shadow: 0 0 24px var(--accent-glow);
    opacity: 1;
}

.btn--ghost {
    background: transparent;
    border-color: rgb(255,255,255,0.12);
    color: var(--text-muted);
}
.btn--ghost:hover {
    border-color: var(--accent);
    color: var(--accent);
    opacity: 1;
}

/* ── ABOUT ── */
.about {
    padding: 8rem var(--gutter);
    background: var(--bg-raised);
    border-top: 1px solid rgb(255,255,255,0.05);
    position: relative;
    z-index: 1;
}

.about__grid {
    max-width: var(--max-w);
    margin: 0 auto;
    display: grid;
    grid-template-columns: 0.3fr 0.7fr;
    gap: 4rem;
}

.about__title {
    font-size: clamp(1.8rem, 3vw, 2.8rem);
    font-weight: 700;
    color: var(--white);
    margin-bottom: 1.5rem;
}

.about__content p {
    margin-bottom: 1.25rem;
    max-width: 600px;
    line-height: 1.8;
}

.about__content a {
    border-bottom: 1px solid var(--accent-dim);
    transition: border-color 0.2s;
}
.about__content a:hover {
    border-color: var(--accent);
    opacity: 1;
}

.about__founder {
    font-family: var(--mono);
    font-size: 0.8rem;
    color: var(--text-dim);
    margin-top: 0.5rem;
}

.about__content em {
    color: var(--accent);
    font-style: italic;
}

.about__brand {
    margin-top: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.about__brand-name {
    font-family: var(--mono);
    font-size: clamp(1.6rem, 2.5vw, 2rem);
    font-weight: 700;
    color: var(--white);
    letter-spacing: 0.15em;
}

.about__phonetic {
    font-family: var(--mono);
    font-size: clamp(1rem, 1.5vw, 1.2rem);
    font-weight: 700;
    color: var(--accent);
    letter-spacing: 0.04em;
}

.about__ipa {
    font-family: var(--mono);
    font-size: 0.8rem;
    color: var(--text-dim);
}

.about__pillars {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

/* ── PROJECT VERSION BADGE ── */
.project__version {
    font-family: var(--mono);
    font-size: 0.55em;
    font-weight: 400;
    color: var(--accent);
    background: var(--accent-dim);
    border: 1px solid rgb(0, 212, 255, 0.15);
    border-radius: 2px;
    padding: 0.15em 0.5em;
    margin-left: 0.5rem;
    vertical-align: middle;
    letter-spacing: 0.04em;
}

/* ── PROJECT STATUS BADGE ── */
.project__status {
    font-family: var(--mono);
    font-size: 0.45em;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding: 0.2em 0.6em;
    margin-left: 0.5rem;
    vertical-align: middle;
    border-radius: 2px;
    border: 1px solid;
}

.project__status--live {
    color: #00e676;
    background: rgb(0, 230, 118, 0.08);
    border-color: rgb(0, 230, 118, 0.2);
}

.project__status--dev {
    color: #ffd740;
    background: rgb(255, 215, 64, 0.08);
    border-color: rgb(255, 215, 64, 0.2);
}

/* ── LIGHTBOX ── */
.lightbox {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgb(5, 5, 10, 0.92);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s var(--ease), visibility 0.3s;
    cursor: zoom-out;
}

.lightbox.active {
    opacity: 1;
    visibility: visible;
}

.lightbox__img {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 4px;
    box-shadow: 0 8px 60px rgb(0, 0, 0, 0.6);
    transform: scale(0.92);
    transition: transform 0.3s var(--ease);
}

.lightbox.active .lightbox__img {
    transform: scale(1);
}

.lightbox__close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background: none;
    border: none;
    color: var(--white);
    font-size: 2rem;
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.2s;
    line-height: 1;
}

.lightbox__close:hover {
    opacity: 1;
}

.project__gallery-item {
    cursor: zoom-in;
}

/* ── PROJECT PREVIEW (Screenshot) ── */
.project__preview {
    margin: 1rem 0 1.25rem;
    border-radius: 3px;
    overflow: hidden;
    border: 1px solid rgb(255, 255, 255, 0.06);
    background: var(--bg);
    position: relative;
}

.project__preview--screenshot {
    max-width: 380px;
    box-shadow: 0 4px 20px rgb(0, 0, 0, 0.3);
}

.project__preview img {
    display: block;
    width: 100%;
    height: auto;
}

/* ── PROJECT GALLERY (compact scrollable thumbnails) ── */
.project__gallery {
    margin: 1.25rem 0 1.5rem;
    overflow: hidden;
    position: relative;
}

.project__gallery-track {
    display: flex;
    gap: 0.75rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: var(--accent-dim) transparent;
    padding-bottom: 0.5rem;
}

.project__gallery-track::-webkit-scrollbar {
    height: 3px;
}
.project__gallery-track::-webkit-scrollbar-track {
    background: transparent;
}
.project__gallery-track::-webkit-scrollbar-thumb {
    background: var(--accent-dim);
    border-radius: 2px;
}

.project__gallery-item {
    flex: 0 0 auto;
    width: 160px;
    scroll-snap-align: start;
    border-radius: 3px;
    overflow: hidden;
    border: 1px solid rgb(255, 255, 255, 0.06);
    background: var(--bg);
    box-shadow: 0 2px 12px rgb(0, 0, 0, 0.25);
    transition: border-color 0.25s var(--ease), transform 0.25s var(--ease);
}

.project__gallery-item:hover {
    border-color: rgb(0, 212, 255, 0.2);
    transform: translateY(-2px);
}

.project__gallery-item img {
    display: block;
    width: 100%;
    height: 200px;
    object-fit: cover;
    object-position: top;
}

.project__gallery-caption {
    display: block;
    font-family: var(--mono);
    font-size: 0.55rem;
    color: var(--text-dim);
    padding: 0.4rem 0.5rem;
    letter-spacing: 0.02em;
    border-top: 1px solid rgb(255, 255, 255, 0.04);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ── PROJECT MOCKUP (visual diagrams) ── */
.project__mockup {
    margin: 1rem 0 1.25rem;
    border-radius: 3px;
    border: 1px solid rgb(255, 255, 255, 0.06);
    background: var(--bg);
    overflow: hidden;
}

/* Sessyn: compact encryption flow diagram */
.project__mockup--sessyn {
    padding: 1.25rem 1rem;
    max-width: 520px;
}

.mockup-flow {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
}

.mockup-node {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.25rem;
    padding: 0.6rem 0.75rem;
    border: 1px solid rgb(0, 212, 255, 0.15);
    border-radius: 3px;
    background: var(--bg-raised);
    min-width: 80px;
    color: var(--accent);
}

.mockup-node svg {
    width: 18px;
    height: 18px;
}

.mockup-node span {
    font-family: var(--mono);
    font-size: 0.55rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    color: var(--white);
}

.mockup-node code {
    font-family: var(--mono);
    font-size: 0.5rem;
    color: var(--text-dim);
    text-align: center;
}

.mockup-node--server {
    border-color: rgb(0, 212, 255, 0.3);
    box-shadow: 0 0 10px var(--accent-glow);
}

.mockup-arrow {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
}

.mockup-arrow svg {
    width: 50px;
    height: 8px;
}

.mockup-arrow-label {
    font-family: var(--mono);
    font-size: 0.45rem;
    color: var(--accent);
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

/* Bcat: compact chat UI mockup */
.project__mockup--bcat {
    max-width: 400px;
    box-shadow: 0 4px 20px rgb(0, 0, 0, 0.3);
}

.mockup-chat__titlebar {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.75rem;
    background: var(--bg-raised);
    border-bottom: 1px solid rgb(255, 255, 255, 0.06);
    font-family: var(--mono);
    font-size: 0.6rem;
    color: var(--text-muted);
}

.mockup-chat__titlebar img {
    width: 14px;
    height: 14px;
}

.mockup-chat__model {
    margin-left: auto;
    font-size: 0.5rem;
    background: var(--accent-dim);
    padding: 0.1em 0.4em;
    border-radius: 2px;
    color: var(--accent);
}

.mockup-chat__messages {
    padding: 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.mockup-chat__msg {
    font-size: 0.7rem;
    line-height: 1.5;
    border-radius: 4px;
    padding: 0.5rem 0.7rem;
}

.mockup-chat__msg--user {
    background: rgb(0, 212, 255, 0.08);
    border: 1px solid rgb(0, 212, 255, 0.12);
    color: var(--text);
    align-self: flex-end;
    max-width: 85%;
}

.mockup-chat__msg--ai {
    background: var(--bg-raised);
    border: 1px solid rgb(255, 255, 255, 0.06);
    color: var(--text);
    max-width: 90%;
}

.mockup-chat__name {
    display: block;
    font-family: var(--mono);
    font-size: 0.55rem;
    font-weight: 700;
    color: #00e676;
    letter-spacing: 0.04em;
    margin-bottom: 0.2rem;
}

.mockup-chat__msg--ai strong {
    color: var(--white);
}

.mockup-chat__msg--ai em {
    color: var(--accent);
    font-style: italic;
}

/* TraceWaves: compact radar + workflow */
.project__mockup--tracewaves {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    padding: 1rem 1.25rem;
    max-width: 480px;
}

.mockup-radar {
    flex: 0 0 80px;
    width: 80px;
    height: 80px;
    animation: radar-pulse 3s ease-in-out infinite;
}

.mockup-radar img {
    width: 100%;
    height: 100%;
}

@keyframes radar-pulse {
    0%, 100% { opacity: 0.85; filter: drop-shadow(0 0 8px rgb(6, 214, 160, 0.2)); }
    50% { opacity: 1; filter: drop-shadow(0 0 20px rgb(6, 214, 160, 0.4)); }
}

.mockup-workflow {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    flex: 1;
}

.mockup-workflow__step {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.3rem 0.5rem;
    border: 1px solid rgb(6, 214, 160, 0.12);
    border-radius: 2px;
    background: var(--bg-raised);
    font-family: var(--mono);
    font-size: 0.6rem;
    color: var(--text-muted);
    transition: border-color 0.2s, color 0.2s;
}

.mockup-workflow__step:hover {
    border-color: rgb(6, 214, 160, 0.3);
    color: var(--white);
}

.mockup-workflow__num {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 14px;
    height: 14px;
    font-size: 0.5rem;
    font-weight: 700;
    color: var(--bg);
    background: #06d6a0;
    border-radius: 50%;
}

/* ── PROJECT LOGO (Icon) ── */
.project__logo {
    width: 48px;
    height: 48px;
    margin-bottom: 1rem;
    opacity: 0.85;
    transition: opacity 0.2s;
}

.project:hover .project__logo {
    opacity: 1;
}

.project__logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* ── PROJECT DESC (multiple paragraphs) ── */
.project__desc + .project__desc {
    margin-top: 0;
}

.project__desc code {
    font-family: var(--mono);
    font-size: 0.88em;
    color: var(--accent);
    background: var(--accent-dim);
    padding: 0.1em 0.35em;
    border-radius: 2px;
}

/* ── RELEASES (links to project changelogs) ── */
.releases {
    padding: 8rem var(--gutter);
    max-width: var(--max-w);
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.releases__header {
    margin-bottom: 3rem;
}

.releases__sub {
    font-family: var(--mono);
    font-size: 0.75rem;
    color: var(--text-dim);
    margin-top: 0.75rem;
}

.releases__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.5rem;
}

.releases__card {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 2rem;
    border: 1px solid rgb(255, 255, 255, 0.06);
    border-radius: 3px;
    background: var(--bg-raised);
    transition: border-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
    text-decoration: none;
}

.releases__card:hover {
    border-color: var(--accent);
    box-shadow: 0 0 20px var(--accent-glow);
    opacity: 1;
}

.releases__card-name {
    font-family: var(--mono);
    font-weight: 700;
    font-size: 1rem;
    color: var(--white);
    letter-spacing: 0.02em;
}

.releases__card-desc {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.5;
}

.releases__card-link {
    font-family: var(--mono);
    font-size: 0.7rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--accent);
    margin-top: 0.5rem;
}

/* ── FOOTER ── */
.footer {
    padding: 3rem var(--gutter);
    border-top: 1px solid rgb(255,255,255,0.05);
    position: relative;
    z-index: 1;
    background: var(--bg);
}

.footer__grid {
    max-width: var(--max-w);
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.footer__brand {
    font-family: var(--mono);
    font-weight: 700;
    font-size: 0.8rem;
    letter-spacing: 0.15em;
    color: var(--text-muted);
}

.footer__links {
    display: flex;
    gap: 1.5rem;
    font-family: var(--mono);
    font-size: 0.7rem;
}

.footer__links a {
    color: var(--text-dim);
    transition: color 0.2s;
}
.footer__links a:hover {
    color: var(--accent);
    opacity: 1;
}

.footer__copy {
    font-family: var(--mono);
    font-size: 0.65rem;
    color: var(--text-dim);
}

/* ── SCROLL REVEAL ── */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger children */
.project.reveal .project__body {
    opacity: 0;
    transform: translateX(20px);
    transition: opacity 0.6s var(--ease) 0.15s, transform 0.6s var(--ease) 0.15s;
}
.project.reveal.visible .project__body {
    opacity: 1;
    transform: translateX(0);
}

/* ── RESPONSIVE ── */
@media (max-width: 900px) {
    .hero__grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    .hero__visual { display: none; }
    .about__grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    .stats__grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .nav__links { display: none; }
    .nav__toggle { display: flex; }

    /* Mobile menu */
    .nav.open .nav__links {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--bg);
        padding: 1.5rem var(--gutter);
        border-bottom: 1px solid rgb(255,255,255,0.05);
        gap: 1rem;
    }

    .nav.open .nav__toggle span:first-child {
        transform: rotate(45deg) translate(3px, 3px);
    }
    .nav.open .nav__toggle span:last-child {
        transform: rotate(-45deg) translate(3px, -3px);
    }

    .project {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }
    .project__index {
        font-size: 0.65rem;
    }
    .project--featured {
        margin-left: 0;
        padding-left: 1.5rem;
    }
    .project__preview--screenshot {
        max-width: 100%;
    }
    .project__gallery-item {
        width: 130px;
    }
    .project__gallery-item img {
        height: 160px;
    }
    .project__mockup--sessyn {
        padding: 1rem 0.75rem;
    }
    .mockup-flow {
        flex-direction: column;
    }
    .mockup-arrow {
        transform: rotate(90deg);
    }
    .project__mockup--bcat {
        max-width: 100%;
    }
    .project__mockup--tracewaves {
        flex-direction: column;
        text-align: center;
        max-width: 100%;
    }
    .mockup-radar {
        flex: 0 0 60px;
        width: 60px;
        height: 60px;
    }
    .project__logo {
        width: 40px;
        height: 40px;
    }
    .footer__grid {
        flex-direction: column;
        align-items: flex-start;
    }
    .footer__links {
        flex-wrap: wrap;
        gap: 0.75rem;
    }
    .stats__grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }
}

/* ═══════════════════════════════════════════
   AEFUSIO MOCKUP + CONTACT SECTION (added 2026-04-24)
   ═══════════════════════════════════════════ */
.project__mockup--aefusio {
    background: linear-gradient(135deg, #1a1530 0%, #0f0f1a 100%);
    border: 1px solid var(--accent-dim);
}

.contact {
    padding: 6rem 2rem 7rem;
    position: relative;
    z-index: 2;
}
.contact__inner {
    max-width: 1100px;
    margin: 0 auto;
}
.contact__lede {
    color: var(--text-dim, #a0a0b0);
    font-size: 1.1rem;
    max-width: 620px;
    margin: 0.75rem 0 3rem;
    line-height: 1.6;
}
.contact__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
    margin-bottom: 2.5rem;
}
.contact__card {
    background: var(--bg-card);
    border: 1px solid var(--accent-dim);
    border-radius: 12px;
    padding: 1.75rem 1.5rem;
    transition: border-color 0.25s ease, transform 0.25s ease;
}
.contact__card:hover {
    border-color: var(--accent);
    transform: translateY(-2px);
}
.contact__label {
    font-family: var(--mono);
    font-size: 0.75rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--accent);
    margin: 0 0 0.75rem;
}
.contact__value {
    display: block;
    font-family: var(--sans);
    font-size: 1.05rem;
    color: #e8e8f0;
    text-decoration: none;
    line-height: 1.55;
    font-style: normal;
}
a.contact__value:hover {
    color: var(--accent);
}
.contact__value--addr {
    font-size: 0.95rem;
    color: #c0c0d0;
}
.contact__legal {
    font-family: var(--mono);
    font-size: 0.8rem;
    color: #70708a;
    letter-spacing: 0.02em;
    text-align: center;
    margin-top: 2rem;
}

@media (max-width: 780px) {
    .contact { padding: 4rem 1.25rem 5rem; }
    .contact__grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
}
