:root {
    --bg: #0a0a0f;
    --text-primary: #f0f0f5;
    --text-muted: #6b7280;
    --accent: #6c63ff;
    --accent-glow: rgba(108, 99, 255, 0.3);
    --highlight-bg: rgba(108, 99, 255, 0.15);
    --nav-height: 64px;
    --radius: 12px;
    --squircle: squircle(corner-radius 12px);
}

html {
    scroll-behavior: smooth;
    color-scheme: dark;
}

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

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

body {
    min-height: 100vh;
    color: var(--text-primary);
    background-color: var(--bg);
    font-family: 'Lucida Sans', 'Lucida Sans Regular', 'Lucida Grande',
                 'Lucida Sans Unicode', Geneva, Verdana, sans-serif;
}

/* ── Scrollbar ── */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: rgba(108, 99, 255, 0.4);
    border-radius: 99px;
}
::-webkit-scrollbar-thumb:hover {
    background: rgba(108, 99, 255, 0.7);
}

/* Firefox */
* {
    scrollbar-width: thin;
    scrollbar-color: rgba(108, 99, 255, 0.4) transparent;
}

/* ── Lightbox ── */
.lightbox {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 200;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.lightbox.is-open {
    display: flex;
}

.lightbox__img {
    max-width: 90vw;
    max-height: 85vh;
    border-radius: var(--radius);
    corner-shape: var(--squircle);
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.7);
    object-fit: contain;
}

.lightbox__figure {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    max-width: 90vw;
}

.lightbox__caption {
    font-size: 0.85rem;
    color: var(--text-muted);
    text-align: center;
    letter-spacing: 0.03em;
}

.lightbox__close {
    position: fixed;
    top: 1.25rem;
    right: 1.5rem;
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 2rem;
    line-height: 1;
    cursor: pointer;
    transition: color 0.2s ease;
    padding: 0.25rem 0.5rem;
}

.lightbox__close:hover {
    color: var(--text-primary);
}


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

a:hover {
    opacity: 0.75;
    text-decoration: underline;
    text-decoration-color: var(--accent);
}

a:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
    border-radius: var(--radius);
    corner-shape: var(--squircle);
}

/* ── Highlight (covers typo .highligh too) ── */
.highlight, .highligh {
    color: var(--accent);
    text-shadow: 0 0 30px var(--accent-glow);
    background: var(--highlight-bg);
    padding: 0 0.15em;
    border-radius: 4px;
    corner-shape: var(--squircle);
}

/* ── Navbar ── */
.navbar {
    position: absolute;
    top: 0;
    left: 2rem;
    right: 2rem;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 1.5rem;
    height: var(--nav-height);
    margin-top: 75px;
    border-radius: 999px;
    background: transparent;
    border: 1px solid transparent;
    transition: background 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                border-color 0.4s cubic-bezier(0.4, 0, 0.2, 1),
                box-shadow   0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.navbar.is-scrolled {
    position: fixed;
    top: 0;
    margin-top: 25px;
    background: rgba(10, 10, 15, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-color: rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.5),
                inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.nav-logo {
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    color: var(--text-primary);
    z-index: 1;
    flex-shrink: 0;
}

/* hamburger button — desktop hidden */
.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.25rem;
    z-index: 1;
}

.nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                opacity   0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-close { display: none; }

/* ── Nav links container — relative so indicator can position inside ── */
.nav-links__container {
    position: relative;
    display: flex;
    align-items: center;
}

.nav-links__list {
    list-style: none;
    display: flex;
    gap: 0;
    position: relative;
}

.nav-link__item {
    position: relative;
}

.nav-link__link {
    display: block;
    padding: 0.4em 1em;
    text-decoration: none;
    font-size: 0.82rem;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    transition: color 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    z-index: 1;
    white-space: nowrap;
}

.nav-link__link:hover {
    color: var(--text-primary);
    text-decoration: none;
    opacity: 1;
}

.nav-link__link.active {
    color: var(--text-primary);
}

/* ── Sliding pill indicator ── */
.nav-indicator {
    position: absolute;
    top: 50%;
    left: 0;
    height: 28px;
    border-radius: 999px;
    background: rgba(108, 99, 255, 0.18);
    border: 1px solid rgba(108, 99, 255, 0.3);
    transform: translateY(-50%) translateX(0);
    transition: width     0.35s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.35s cubic-bezier(0.4, 0, 0.2, 1),
                opacity   0.25s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0;
    pointer-events: none;
    z-index: 0;
}

/* ── Mobile nav ── */
@media (max-width: 600px) {

    /* Bar */
    .navbar {
        position: fixed;
        top: 0; left: 0; right: 0;
        margin: 0;
        border-radius: 0;
        height: var(--nav-height);
        background: var(--bg);
        border: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.07);
        padding: 0 1.25rem;
        transition: none;
        z-index: 450;
    }

    .navbar.is-scrolled {
        position: fixed;
        margin-top: 0;
        border-radius: 0;
        background: var(--bg);
        box-shadow: none;
        backdrop-filter: none;
    }

    /* Hide desktop indicator */
    .nav-indicator { display: none; }

    /* Show hamburger */
    .nav-toggle {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 5px;
        width: 44px;
        height: 44px;
        padding: 0;
        background: none;
        border: none;
        cursor: pointer;
        z-index: 500;
        position: relative;
    }

    .nav-toggle span {
        display: block;
        width: 22px;
        height: 2px;
        background: var(--text-primary);
        border-radius: 2px;
        transform-origin: center;
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                    opacity   0.2s cubic-bezier(0.4, 0, 0.2, 1),
                    width     0.3s cubic-bezier(0.4, 0, 0.2, 1);
    }

    /* Hamburger → X */
    .nav-toggle.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
    .nav-toggle.is-open span:nth-child(2) { opacity: 0; width: 0; }
    .nav-toggle.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

    /* Fullscreen overlay */
    .nav-links__container {
        position: fixed;
        top: var(--nav-height);
        left: 0; right: 0; bottom: 0;
        z-index: 400;
        display: flex;
        flex-direction: column;
        align-items: stretch;
        justify-content: center;
        padding: 2rem 1.5rem;
        background: var(--bg);
        transform: translateX(100%);
        opacity: 0;
        pointer-events: none;
        transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1),
                    opacity   0.3s  cubic-bezier(0.4, 0, 0.2, 1);
    }

    .nav-links__container.is-open {
        transform: translateX(0);
        opacity: 1;
        pointer-events: all;
    }

    .nav-close { display: none; }

    /* Links */
    .nav-links__list {
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        width: 100%;
        padding: 0;
    }

    .nav-link__item {
        border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    }

    .nav-link__item:first-child {
        border-top: 1px solid rgba(255, 255, 255, 0.06);
    }

    .nav-link__link {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 1rem 0.25rem;
        font-size: 1.05rem;
        letter-spacing: 0.06em;
        color: var(--text-muted);
        transition: color 0.25s cubic-bezier(0.4, 0, 0.2, 1),
                    padding-left 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .nav-link__link::after {
        content: "→";
        font-size: 0.85rem;
        color: var(--accent);
        opacity: 0;
        transform: translateX(-6px);
        transition: opacity   0.25s cubic-bezier(0.4, 0, 0.2, 1),
                    transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .nav-link__link:hover,
    .nav-link__link.active {
        color: var(--text-primary);
        padding-left: 0.5rem;
        text-decoration: none;
        opacity: 1;
    }

    .nav-link__link:hover::after,
    .nav-link__link.active::after {
        opacity: 1;
        transform: translateX(0);
    }
}


/* ── Section shared ── */
.section-indicator {
    display: inline-block;
    font-size: 0.75rem;
    letter-spacing: 0.12em;
    color: var(--accent);
    opacity: 0.6;
    margin-bottom: 1rem;
}

section[id] {
    scroll-margin-top: 77px;
}

/* ── Hero ── */
.section__hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: calc(var(--nav-height) + 2rem) 2rem 2rem;
}

.section__hero h1 {
    font-size: clamp(2.5rem, 8vw, 6rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1.1;
    margin-bottom: 1rem;
}

.domain-subtitle {
    font-size: clamp(0.85rem, 2vw, 1rem);
    font-weight: 400;
    color: var(--text-muted);
    letter-spacing: 0.15em;
    text-transform: lowercase;
}

/* ── About ── */
.section__about {
    max-width: 720px;
    margin: 0 auto;
    padding: 5rem 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.section__about h2 {
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 1.25rem;
}

.section__about p {
    font-size: clamp(1rem, 2vw, 1.15rem);
    line-height: 1.8;
    color: var(--text-muted);
}

/* ── Stack ── */
.section__stack {
    max-width: 720px;
    margin: 0 auto;
    padding: 5rem 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.section__stack h2 {
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 1.5rem;
}

.section__stack ul {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.section__stack li {
    font-size: 0.9rem;
    padding: 0.4em 0.9em;
    border-radius: var(--radius);
    corner-shape: var(--squircle);
    background: var(--highlight-bg);
    color: var(--accent);
    border: 1px solid rgba(108, 99, 255, 0.2);
    letter-spacing: 0.03em;
}

.section__stack li.note {
    background: transparent;
    border-color: transparent;
    color: var(--text-muted);
    font-style: italic;
}

/* ── Availability ── */
.section__availability {
    max-width: 720px;
    margin: 0 auto;
    padding: 5rem 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.section__availability h2 {
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 1.25rem;
}

.section__availability p {
    font-size: clamp(1rem, 2vw, 1.15rem);
    line-height: 1.8;
    color: var(--text-muted);
}

/* ── Contact ── */
.section__contact {
    max-width: 720px;
    margin: 0 auto;
    padding: 5rem 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.section__contact h2 {
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 1.5rem;
}

.contact-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.contact-list li {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.contact-label {
    font-size: 0.8rem;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    min-width: 90px;
    text-transform: uppercase;
}

.email-canvas {
    display: block;
    image-rendering: crisp-edges;
}

/* ── Projects ── */
.section__projects {
    max-width: 720px;
    margin: 0 auto;
    padding: 5rem 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.section__projects h2 {
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 1.5rem;
}

.projects-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.project-card {
    padding: 1.25rem 1.5rem;
    border-radius: var(--radius);
    corner-shape: var(--squircle);
    border: 1px solid rgba(108, 99, 255, 0.2);
    background: var(--highlight-bg);
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    overflow: hidden;
}

.project-card__img {
    width: calc(100% + 3rem);
    margin: -1.25rem -1.5rem 0.75rem;
    height: 180px;
    object-fit: cover;
    object-position: top;
    border-bottom: 1px solid rgba(108, 99, 255, 0.15);
    display: block;
}

.project-card__header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.project-card__name {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: 0.02em;
}

.project-card__desc {
    font-size: 0.9rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.project-card__links {
    display: flex;
    gap: 1rem;
    margin-top: 0.25rem;
}

.project-card__links a {
    font-size: 0.8rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    padding: 0.25em 0.7em;
    border-radius: var(--radius);
    corner-shape: var(--squircle);
    border: 1px solid rgba(108, 99, 255, 0.35);
    color: var(--accent);
    text-decoration: none;
    transition: background 0.2s ease, opacity 0.2s ease;
}

.project-card__links a:hover {
    background: rgba(108, 99, 255, 0.15);
    opacity: 1;
    text-decoration: none;
}

.project-card--more {
    background: transparent;
    border-color: transparent;
    color: var(--text-muted);
    font-style: italic;
    font-size: 0.9rem;
    padding-left: 0.25rem;
}

/* ── Skills ── */
.section__skills {
    max-width: 720px;
    margin: 0 auto;
    padding: 5rem 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.section__skills h2 {
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 1.5rem;
}

.skills-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.95rem;
}

.skills-table th {
    text-align: left;
    font-size: 0.75rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-muted);
    padding: 0.5rem 1rem 0.75rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.skills-table td {
    padding: 0.75rem 1rem;
    color: var(--text-primary);
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.skills-table tbody tr:hover td {
    background: rgba(108, 99, 255, 0.05);
}

.level {
    display: inline-block;
    font-size: 0.75rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    padding: 0.2em 0.65em;
    border-radius: var(--radius);
    corner-shape: var(--squircle);
    font-weight: 600;
}

.level--expert       { background: rgba(108, 99, 255, 0.2); color: #a89fff; border: 1px solid rgba(108,99,255,0.35); }
.level--advanced     { background: rgba(34, 197, 94, 0.12); color: #4ade80; border: 1px solid rgba(34,197,94,0.3); }
.level--intermediate { background: rgba(234, 179, 8, 0.12); color: #facc15; border: 1px solid rgba(234,179,8,0.3); }
.level--beginner     { background: rgba(239, 68, 68, 0.12); color: #f87171; border: 1px solid rgba(239,68,68,0.3); }


/* ── Skills filters ── */
.skills-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.25rem;
}

.skills-filter {
    background: transparent;
    border: 1px solid rgba(108, 99, 255, 0.25);
    color: var(--text-muted);
    font-family: inherit;
    font-size: 0.78rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    padding: 0.3em 0.8em;
    border-radius: var(--radius);
    corner-shape: var(--squircle);
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.skills-filter:hover {
    color: var(--text-primary);
    border-color: rgba(108, 99, 255, 0.5);
}

.skills-filter.is-active {
    background: rgba(108, 99, 255, 0.2);
    color: var(--accent);
    border-color: rgba(108, 99, 255, 0.5);
}

.skills-table tr.is-hidden {
    display: none;
}

/* ── Wettbewerbe ── */
.section__wettbewerbe {
    max-width: 720px;
    margin: 0 auto;
    padding: 5rem 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.section__wettbewerbe h2 {
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 1.5rem;
}

.competition-list {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.competition__item {
    padding: 1.25rem 1.5rem;
    border-radius: var(--radius);
    corner-shape: var(--squircle);
    border: 1px solid rgba(108, 99, 255, 0.2);
    background: var(--highlight-bg);
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-areas:
        "meta    img"
        "title   img"
        "level   img"
        "stages  img"
        "awards  img";
    column-gap: 1.25rem;
    row-gap: 0.5rem;
    align-items: start;
}

.competition__meta   { grid-area: meta; }
.competition__item > h3 { grid-area: title; }
.competition__item > .competition__level { grid-area: level; }
.competition__stages { grid-area: stages; }
.competition__item > .competition__awards { grid-area: awards; }

.competition__meta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.competition__category {
    font-size: 0.75rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--accent);
    opacity: 0.8;
}

.competition__date {
    font-size: 0.75rem;
    color: var(--text-muted);
    letter-spacing: 0.04em;
}

.competition__item > h3 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.4;
}

.competition__level {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.competition__awards {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.25rem;
}

.competition__awards li {
    font-size: 0.78rem;
    padding: 0.2em 0.7em;
    border-radius: var(--radius);
    corner-shape: var(--squircle);
    background: rgba(34, 197, 94, 0.1);
    color: #4ade80;
    border: 1px solid rgba(34, 197, 94, 0.25);
    letter-spacing: 0.03em;
}

.competition__stages {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-top: 0.25rem;
    padding-left: 1rem;
    border-left: 2px solid rgba(108, 99, 255, 0.2);
}

.competition__stage {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

/* ── Competition image ── */
.competition__img {
    grid-area: img;
    grid-row: 1 / -1;
    width: 160px;
    height: 100%;
    max-height: 200px;
    object-fit: cover;
    border-radius: var(--radius);
    corner-shape: var(--squircle);
    border: 1px solid rgba(108, 99, 255, 0.15);
    align-self: stretch;
}

@media (max-width: 520px) {
    .competition__item {
        grid-template-columns: 1fr;
        grid-template-areas:
            "img"
            "meta"
            "title"
            "level"
            "stages"
            "awards";
    }
    .competition__img--desktop { display: none; }
    .competition__img--mobile  { display: block; }
}

@media (min-width: 521px) {
    .competition__img--mobile  { display: none; }
    .competition__img--desktop { display: block; }
}

/* ── Mobile ── */
@media (max-width: 600px) {

    /* Nav: shrink gaps and font so links don't overflow */
    .navbar {
        padding: 0 1rem;
    }
    .nav-links__list {
        gap: 1rem;
    }
    .nav-link__link {
        font-size: 0.75rem;
        letter-spacing: 0.04em;
    }

    /* Sections: reduce vertical padding */
    .section__about,
    .section__stack,
    .section__projects,
    .section__skills,
    .section__wettbewerbe,
    .section__availability,
    .section__contact {
        padding: 3rem 1.25rem;
    }

    /* Footer */
    .footer {
        margin: 2rem 1rem 1rem;
        padding: 0.75rem 1rem;
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    /* Skills table: hide category column on small screens */
    .skills-table th:nth-child(2),
    .skills-table td:nth-child(2) {
        display: none;
    }
    .skills-table th,
    .skills-table td {
        padding: 0.6rem 0.5rem;
    }

    /* Contact: allow wrapping */
    .contact-list li {
        flex-wrap: wrap;
        gap: 0.5rem;
    }
    .contact-label {
        min-width: unset;
        width: 100%;
    }

    /* Competition image on mobile: full width, natural ratio, no grid bleed */
    .competition__img--mobile {
        grid-area: img;
        width: 100%;
        height: auto;
        max-height: none;
        object-fit: cover;
        border-radius: var(--radius);
        border: 1px solid rgba(108, 99, 255, 0.15);
    }

    /* Project card image: reduce height on small screens */
    .project-card__img {
        height: 130px;
    }
}

/* ── Error page ── */
.section__error {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 2rem;
    gap: 0.75rem;
}

.error__code {
    font-size: clamp(5rem, 20vw, 10rem);
    font-weight: 700;
    color: var(--accent);
    opacity: 0.3;
    line-height: 1;
    letter-spacing: -0.04em;
}

.error__title {
    font-size: clamp(1.4rem, 4vw, 2rem);
    font-weight: 700;
}

.error__desc {
    color: var(--text-muted);
    font-size: 1rem;
    max-width: 400px;
    line-height: 1.7;
}

.error__back {
    margin-top: 1rem;
    font-size: 0.9rem;
    letter-spacing: 0.05em;
}

/* ── Imprint ── */
.imprint-block {
    margin-bottom: 2rem;
}

.imprint-block h3 {
    font-size: 0.8rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--accent);
    opacity: 0.8;
    margin-bottom: 0.6rem;
}

.imprint-block p {
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.8;
    margin-bottom: 0.5rem;
}

.imprint-block strong {
    color: var(--text-primary);
    font-weight: 600;
}


/* ── Footer ── */
.footer {
    max-width: 720px;
    margin: 5rem auto 2rem;
    border-radius: var(--radius);
    border: 1px solid rgba(255, 255, 255, 0.07);
    overflow: hidden;
}

.footer__inner {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr;
    gap: 0;
}

.footer__section {
    padding: 1.75rem 1.5rem;
    border-right: 1px solid rgba(255, 255, 255, 0.07);
}

.footer__section:last-child {
    border-right: none;
}

.footer__logo {
    display: block;
    font-size: 0.95rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.footer__tagline {
    font-size: 0.8rem;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 1rem;
}

.footer__copy {
    font-size: 0.72rem;
    color: var(--text-muted);
    letter-spacing: 0.02em;
}

.footer__copy a {
    color: var(--text-muted);
    transition: color 0.2s cubic-bezier(0.4,0,0.2,1);
}

.footer__copy a:hover {
    color: var(--text-primary);
    text-decoration: none;
    opacity: 1;
}

.footer__heading {
    font-size: 0.65rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--text-muted);
    opacity: 0.6;
    margin-bottom: 0.75rem;
    font-weight: 600;
}

.footer__nav {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.footer__nav a {
    font-size: 0.82rem;
    color: var(--text-muted);
    text-decoration: none;
    letter-spacing: 0.03em;
    transition: color 0.2s cubic-bezier(0.4,0,0.2,1);
}

.footer__nav a:hover {
    color: var(--text-primary);
    text-decoration: none;
    opacity: 1;
}

.footer__bar {
    padding: 0.75rem 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.07);
    font-size: 0.68rem;
    color: var(--text-muted);
    opacity: 0.5;
    letter-spacing: 0.04em;
}


/* ── Lang switcher (dropdown) ── */
.lang-switcher {
    position: relative;
    display: block;
    width: 100%;
}

.lang-switcher__btn {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5em;
    width: 100%;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 8px;
    color: var(--text-muted);
    font-family: inherit;
    font-size: 0.82rem;
    letter-spacing: 0.04em;
    padding: 0.5em 0.85em;
    cursor: pointer;
    outline: none;
    transition: color        0.2s cubic-bezier(0.4,0,0.2,1),
                border-color 0.2s cubic-bezier(0.4,0,0.2,1),
                background   0.2s cubic-bezier(0.4,0,0.2,1);
}

.lang-switcher__btn:hover {
    color: var(--text-primary);
    border-color: rgba(108,99,255,0.4);
    background: rgba(108,99,255,0.06);
}

.lang-switcher__arrow {
    flex-shrink: 0;
    transition: transform 0.22s cubic-bezier(0.4,0,0.2,1);
}

.lang-switcher.is-open .lang-switcher__arrow {
    transform: rotate(180deg);
}

/* Desktop: dropdown (below button) */
.lang-switcher__menu {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    right: 0;
    list-style: none;
    margin: 0;
    padding: 0.3rem;
    background: #111118;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 10px;
    opacity: 0;
    transform: translateY(-6px);
    pointer-events: none;
    transition: opacity   0.18s cubic-bezier(0.4,0,0.2,1),
                transform 0.18s cubic-bezier(0.4,0,0.2,1);
    z-index: 999;
}

.lang-switcher.is-open .lang-switcher__menu {
    opacity: 1;
    transform: translateY(0);
    pointer-events: all;
}

.lang-switcher__option {
    padding: 0.5em 0.75em;
    font-size: 0.82rem;
    letter-spacing: 0.04em;
    color: var(--text-muted);
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease;
}

.lang-switcher__option:hover {
    background: rgba(108,99,255,0.12);
    color: var(--text-primary);
}

.lang-switcher__option.is-active {
    color: var(--accent);
    background: rgba(108,99,255,0.15);
}

/* Mobile: hide desktop dropdown, show popover instead */
@media (max-width: 600px) {
    .lang-switcher__menu { display: none; }
}

@media (min-width: 601px) {
    .lang-popover { display: none !important; }
}

/* ── Lang popover (mobile only) ── */
.lang-popover {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 600;
}

.lang-popover.is-open {
    display: block;
}

.lang-popover__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.lang-popover__sheet {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    background: #111118;
    border-top: 1px solid rgba(255,255,255,0.1);
    border-radius: 16px 16px 0 0;
    padding: 1.5rem 1.5rem 2.5rem;
    transform: translateY(100%);
    transition: transform 0.3s cubic-bezier(0.4,0,0.2,1);
}

.lang-popover.is-open .lang-popover__sheet {
    transform: translateY(0);
}

.lang-popover__title {
    font-size: 0.7rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.lang-popover__list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.lang-popover__option {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    border-radius: 10px;
    cursor: pointer;
    transition: background 0.15s ease;
}

.lang-popover__option span:first-child {
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    color: var(--text-primary);
    min-width: 2rem;
}

.lang-popover__option span:last-of-type {
    font-size: 0.9rem;
    color: var(--text-muted);
    flex: 1;
}

.lang-popover__option svg {
    color: var(--accent);
    margin-left: auto;
}

.lang-popover__option:hover {
    background: rgba(255,255,255,0.05);
}

.lang-popover__option.is-active {
    background: rgba(108,99,255,0.1);
}

.lang-popover__option.is-active span:last-of-type {
    color: var(--text-primary);
}

/* Footer mobile */
@media (max-width: 600px) {
    .footer {
        margin: 3rem 1rem 1rem;
    }
    .footer__inner {
        grid-template-columns: 1fr;
    }
    .footer__section {
        border-right: none;
        border-bottom: 1px solid rgba(255,255,255,0.07);
    }
    .footer__section:last-child {
        border-bottom: none;
    }
}
