@font-face {
    font-family: 'Jora TYGRA';
    src:
        local('Jora TYGRA'),
        local('Jora TYGRA Regular'),
        local('JoraTYGRA'),
        local('JoraTYGRA Regular'),
        local('JoraTYGRA-Regular'),
        url('../../Jora TYGRA Regular.ttf') format('truetype'),
        url('/Jora TYGRA Regular.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'JoraTYGRA';
    src:
        local('JoraTYGRA'),
        local('JoraTYGRA Regular'),
        local('Jora TYGRA'),
        local('Jora TYGRA Regular'),
        local('JoraTYGRA-Regular'),
        url('../../Jora TYGRA Regular.ttf') format('truetype'),
        url('/Jora TYGRA Regular.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

/* Смена темы по звезде: снимок делает движок, без клона всего DOM */
@supports (view-transition-name: root) {
    html {
        view-transition-name: root;
    }

    ::view-transition-old(root),
    ::view-transition-new(root) {
        animation-duration: 0.52s;
        animation-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
    }
}

/* Декоративная звезда при смене темы: только transform/opacity (без filter на каждый кадр) */
.theme-reveal-star-layer {
    position: fixed;
    left: clamp(12px, 4vw, 48px);
    top: clamp(12px, 3vh, 36px);
    z-index: 10060;
    pointer-events: none;
    width: 72px;
    height: 72px;
    color: var(--color-red);
    animation: theme-reveal-star-spin 0.95s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    will-change: transform, opacity;
}

.theme-reveal-star-layer .theme-reveal-star-svg {
    display: block;
    width: 100%;
    height: 100%;
}

@keyframes theme-reveal-star-spin {
    from {
        transform: rotate(0deg) scale(1);
        opacity: 1;
    }

    to {
        transform: rotate(720deg) scale(2.15);
        opacity: 0;
    }
}

:root {
    --color-bg: #ffffff;
    /* Off-white, paper-like */
    --color-text: #111111;
    --color-red: #d91c1c;
    /* A slightly more pleasant, aggressive red */
    --border-color: #111111;
    --border-width: 3px;
    --border-solid: var(--border-width) solid var(--border-color);
}

.dark-theme {
    --color-bg: #050505;
    --color-text: #ffffff;
    --border-color: #333333;
}

.light-theme {
    --color-bg: #ffffff;
    --color-text: #111111;
    --border-color: #111111;
}

html {
    scrollbar-gutter: stable;
}

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

body {
    background-color: var(--color-bg);
    color: var(--color-text);
    font-family: 'Inter', sans-serif;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    padding: 0;
}

.page-wrapper {
    background-color: var(--color-bg);
    color: var(--color-text);
    min-height: 100vh;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.font-display {
    font-family: 'Jora TYGRA', 'JoraTYGRA', 'Bebas Neue', 'Impact', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.font-mono {
    font-family: 'JetBrains Mono', ui-monospace, monospace;
    font-variant-numeric: tabular-nums;
}

/* UTILITIES */
.text-red {
    color: var(--color-red);
}

.text-white {
    color: #fff;
}

.bg-dark {
    background-color: var(--color-text);
}

.red-bg {
    background-color: var(--color-red);
    color: white;
}

.black-bg {
    background-color: #000;
    color: white;
}

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

.mx-auto {
    margin-left: auto;
    margin-right: auto;
}

.max-w-lg {
    max-width: 800px;
}

.text-center {
    text-align: center;
}

.text-left {
    text-align: left;
}

.text-lg-soft {
    font-size: 1.25rem;
    line-height: 1.6;
    opacity: 0.9;
}

.p-lg {
    padding: 3rem;
}

.p-md {
    padding: 2rem;
}

.p-sm {
    padding: 1rem;
}

.mb-md {
    margin-bottom: 2rem;
}

.mb-sm {
    margin-bottom: 1rem;
}

.mt-sm {
    margin-top: 1rem;
}

.mt-md {
    margin-top: 2rem;
}

.mt-lg {
    margin-top: 4rem;
}

.pb-0 {
    padding-bottom: 0 !important;
}

/* ABOUT PAGE SPLIT LAYOUT (D&G Inspired) */
.split-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 80vh;
    border-bottom: var(--border-solid);
}

.split-section.order-reverse {
    grid-template-columns: 1fr 1fr;
}

.split-section.order-reverse .split-content {
    grid-column: 2;
    grid-row: 1;
}

.split-section.order-reverse .split-image {
    grid-column: 1;
    grid-row: 1;
}

.split-content {
    padding: 4rem;
}

.content-wrapper {
    max-width: 600px;
    width: 100%;
}

.split-image {
    position: relative;
    overflow: hidden;
    background-color: #111;
}

.split-image img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.border-right {
    border-right: var(--border-solid);
}

/* TYPOGRAPHY EXTRAS */
.neon-text-red {
    text-shadow: 0 0 10px rgba(217, 28, 28, 0.8), 0 0 20px rgba(217, 28, 28, 0.4);
}

.red-glow {
    color: var(--color-red);
    text-shadow: 0 0 15px var(--color-red), 0 0 30px var(--color-red);
}

.story-text {
    font-size: 1.15rem;
    line-height: 1.6;
}

.emotion-list {
    list-style: none;
    font-size: 1.25rem;
}

.emotion-list li {
    margin-bottom: 1rem;
    border-left: 2px solid var(--color-red);
    padding-left: 1rem;
}

.emotion-list li strong {
    color: var(--color-red);
    display: block;
    font-size: 1.5rem;
    font-family: 'Jora TYGRA', 'JoraTYGRA', 'Bebas Neue', 'Impact', sans-serif;
    letter-spacing: 1px;
}

.feature-item h3 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.feature-item p {
    font-size: 1.1rem;
    line-height: 1.5;
}

.why-try p {
    font-size: 1.25rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    padding-bottom: 1rem;
}

.crystal-btn {
    background: linear-gradient(135deg, #ff4d4d, var(--color-red), #990000);
    color: white;
    font-size: 2.5rem;
    padding: 1.5rem 3rem;
    border: 3px solid #ff9999;
    border-radius: 8px;
    cursor: pointer;
    box-shadow: 0 10px 20px rgba(217, 28, 28, 0.5), inset 0 2px 5px rgba(255, 255, 255, 0.5);
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
    transition: all 0.3s ease;
}

.crystal-btn:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 15px 30px rgba(217, 28, 28, 0.7), inset 0 2px 5px rgba(255, 255, 255, 0.8);
    border-color: #ffffff;
}

.crystal-btn:active {
    transform: translateY(2px);
    box-shadow: 0 5px 10px rgba(217, 28, 28, 0.5);
}

/* WRAPPER */
.page-wrapper {
    width: 100%;
    margin: 0;
    background-color: var(--color-bg);
}

.faq-question { font-size: 1.5rem; color: #fff; margin-bottom: 0.5rem; letter-spacing: 1px; }
.faq-answer { font-size: 1.1rem; color: #bbb; line-height: 1.6; margin-bottom: 0; }

/* --- EASTER EGG POPUP --- */
.easter-egg-popup { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%) scale(0.9); background: #0a0a0f; border: 2px solid #5522ff; padding: 2rem; z-index: 100000; display: none; text-align: center; box-shadow: 0 0 40px rgba(85, 34, 255, 0.4); border-radius: 8px; max-width: 400px; opacity: 0; transition: opacity 0.3s, transform 0.3s; }
.easter-egg-popup.active { display: block; opacity: 1; transform: translate(-50%, -50%) scale(1); }
.easter-egg-icon { font-size: 4rem; margin-bottom: 1rem; }
.easter-egg-popup h3 { color: #8855ff; font-size: 2rem; margin-bottom: 1rem; letter-spacing: 2px; }
.easter-egg-popup p { color: #ccc; line-height: 1.5; margin-bottom: 1.5rem; }
.easter-egg-popup button { background: #5522ff; color: #fff; border: none; padding: 0.5rem 2rem; font-size: 1.2rem; cursor: pointer; transition: background 0.3s; }
.easter-egg-popup button:hover { background: #7744ff; }

/* --- TRON CYBER AESTHETIC --- */
.cyber-modal { position: absolute; top: 0; left: 0; width: 100vw; height: 100vh; background: rgba(0, 5, 10, 0.9); z-index: 100000; display: flex; justify-content: center; align-items: center; opacity: 0; pointer-events: none; transition: opacity 0.4s ease; backdrop-filter: blur(15px); }
.cyber-modal.active { opacity: 1; pointer-events: auto; }
.cyber-modal-content { max-width: 500px; padding: 3rem; background: rgba(0, 15, 30, 0.85); border: 2px solid #0df; box-shadow: 0 0 30px rgba(0, 221, 255, 0.4), inset 0 0 20px rgba(0, 221, 255, 0.2); position: relative; text-align: center; transform: scale(0.9); transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); }
.cyber-modal.active .cyber-modal-content { transform: scale(1); }
.cyber-scanline { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(to bottom, transparent 50%, rgba(0, 221, 255, 0.05) 51%, transparent 51%); background-size: 100% 4px; pointer-events: none; z-index: 10; }
.cyber-header { font-family: 'JetBrains Mono', monospace; font-size: 1.8rem; color: #ff0044; margin-bottom: 1.5rem; text-shadow: 0 0 10px #ff0044; }
.cyber-blink { animation: blink 1s step-end infinite; }
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: 0; } }
.cyber-text { font-family: 'JetBrains Mono', monospace; font-size: 1rem; color: #0df; opacity: 0.8; margin-bottom: 2rem; line-height: 1.5; }
.cyber-input { background: rgba(0, 0, 0, 0.5); border: 1px solid #0df; color: #fff; font-family: 'JetBrains Mono', monospace; font-size: 2rem; padding: 1rem; text-align: center; width: 80%; letter-spacing: 15px; margin-bottom: 1rem; outline: none; transition: box-shadow 0.3s, border-color 0.3s; }
.cyber-input:focus { box-shadow: 0 0 15px rgba(0, 221, 255, 0.8); border-color: #fff; }
.cyber-error { color: #ff0044; font-family: 'JetBrains Mono', monospace; font-size: 0.9rem; margin-bottom: 1rem; text-shadow: 0 0 5px #ff0044; transition: opacity 0.3s; }
.cyber-btn { background: rgba(0, 221, 255, 0.1); border: 1px solid #0df; color: #0df; padding: 0.8rem 2rem; font-family: 'JetBrains Mono', monospace; font-size: 1.2rem; cursor: pointer; transition: all 0.3s; text-transform: uppercase; letter-spacing: 2px; position: relative; overflow: hidden; margin: 0.5rem; }
.cyber-btn:hover { background: #0df; color: #000; box-shadow: 0 0 20px #0df; }
.cyber-btn-secondary { border-color: #ff0044; color: #ff0044; }
.cyber-btn-secondary:hover { background: #ff0044; color: #000; box-shadow: 0 0 20px #ff0044; }
.cyber-board-overlay { background: rgba(0, 10, 20, 0.9); }
.cyber-panel { background: rgba(0, 15, 30, 0.8); border: 1px solid #0df; box-shadow: 0 0 30px rgba(0, 221, 255, 0.3); border-radius: 0; position: relative; }
.cyber-title { color: #0df; text-shadow: 0 0 15px #0df; border-bottom-color: #0df; }
.cyber-subtitle { color: #fff; margin-bottom: 0.5rem; margin-top: 1.5rem; text-shadow: 0 0 5px rgba(255, 255, 255, 0.5); }
.cyber-body { font-family: 'JetBrains Mono', monospace; color: #99ddee; line-height: 1.6; }
.cyber-title-glow { text-shadow: 0 0 20px currentColor, 0 0 40px currentColor; }
.cyber-mono { font-family: 'JetBrains Mono', monospace; letter-spacing: 3px; }
.cyber-glass { background: rgba(0, 10, 25, 0.7); backdrop-filter: blur(8px); border: 1px solid rgba(0, 221, 255, 0.3); box-shadow: inset 0 0 20px rgba(0, 221, 255, 0.1); }
.cyber-close { color: #0df; }
.cyber-close:hover { color: #fff; text-shadow: 0 0 10px #fff; }
.cyber-popup { background: rgba(0, 15, 30, 0.95); border-color: #ff0044; box-shadow: 0 0 40px rgba(255, 0, 68, 0.4); }

/* NAVBAR */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    height: 80px;
    border-bottom: var(--border-solid);
    position: sticky;
    top: 0;
    background-color: var(--color-bg);
    z-index: 100;
    box-sizing: border-box;
    contain: layout;
    transform: translateZ(0);
    backface-visibility: hidden;
}

.logo {
    font-size: 2.5rem;
    line-height: 1;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.logo-svg {
    height: 48px;
    width: 48px;
    min-width: 48px;
    min-height: 48px;
    color: var(--color-red);
    animation: rotateBurst 30s linear infinite;
    transition: transform 0.3s ease;
    will-change: transform;
}

@keyframes rotateBurst {
    from {
        transform: rotate(0deg);
    }

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

.logo-svg:hover {
    transform: scale(1.1) rotate(15deg);
    filter: drop-shadow(0px 0px 10px rgba(217, 28, 28, 0.6));
}

.nav-center {
    display: flex;
    gap: 2rem;
    font-size: 1.4rem;
}

.nav-center a {
    color: var(--color-text);
    text-decoration: none;
    position: relative;
    padding-bottom: 2px;
}

.nav-center a:hover,
.nav-center a.active {
    color: var(--color-red);
}

.nav-center a.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--color-red);
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    font-size: 1.4rem;
    min-height: 48px;
}

.nav-right a {
    color: var(--color-text);
    text-decoration: none;
}

.nav-right a:hover {
    color: var(--color-red);
}

.p-badge {
    padding: 0.2rem 1rem;
    border: 2px solid var(--color-text);
    font-family: 'Jora TYGRA', 'JoraTYGRA', 'Bebas Neue', 'Impact', sans-serif;
    text-transform: uppercase;
    display: inline-block;
}

.p-group {
    display: flex;
    align-items: center;
}

.p-group .p-badge:first-child {
    border-right-width: 1px;
}

.p-group .p-badge:last-child {
    border-left-width: 1px;
    margin-left: 0;
}

/* HERO SECTION */
.hero-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    border-bottom: var(--border-solid);
    background-image: linear-gradient(var(--border-color) 1px, transparent 1px), linear-gradient(90deg, var(--border-color) 1px, transparent 1px);
    background-size: 40px 40px;
    background-position: center;
    background-color: #e5e5e0;
    min-height: 80vh;
}

.hero-content {
    padding: 4rem 4rem 4rem clamp(2rem, 10vw, 10rem);
    background-color: var(--color-bg);
    border-right: var(--border-solid);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.border-left {
    border-left: var(--border-solid);
}

.huge-title {
    font-size: clamp(4rem, 8vw, 7rem);
    line-height: 0.9;
    letter-spacing: -1px;
}

.manifesto {
    font-size: 1.25rem;
    font-weight: 500;
    max-width: 600px;
    line-height: 1.6;
}

.btn-primary {
    align-self: flex-start;
    background-color: var(--color-red);
    color: white;
    font-size: 2rem;
    padding: 1rem 2rem;
    border: var(--border-solid);
    cursor: pointer;
    box-shadow: 6px 6px 0px var(--color-text);
    transition: transform 0.1s, box-shadow 0.1s;
}

.btn-primary:hover {
    transform: translate(2px, 2px);
    box-shadow: 4px 4px 0px var(--color-text);
}

.btn-primary:active {
    transform: translate(6px, 6px);
    box-shadow: 0px 0px 0px var(--color-text);
}

.product-cover-neon {
    background: #0a0a0a;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    font-family: 'JetBrains Mono', monospace;
    font-size: 3.5rem;
    font-weight: 700;
    color: #00ffcc;
    text-shadow: 0 0 20px #00ffcc, 0 0 40px rgba(0, 255, 204, 0.5);
}

.product-cover-neon::before {
    content: 'ТЕНЬ';
}

.hero-visual {
    background-color: var(--color-text);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    position: relative;
    overflow: hidden;
}

.hero-visual picture {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: block;
}

.hero-visual picture img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.highlight-box {
    border: var(--border-solid);
    border-color: var(--color-red);
    padding: 2rem;
    background: transparent;
    transform: rotate(-2deg);
    position: relative;
    z-index: 2;
}

.highlight-text {
    font-size: 5rem;
    color: #fff;
    line-height: 0.9;
    text-shadow: 4px 4px 0px var(--color-red);
}

/* STOREFRONT */
.storefront {
    background-color: var(--color-bg);
}

.store-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    border-bottom: var(--border-solid);
    padding-bottom: 1rem;
}

/* Full-width processes section: centered title, comfortable horizontal rhythm */
.storefront--processes {
    padding-left: clamp(0.75rem, 4vw, 3rem);
    padding-right: clamp(0.75rem, 4vw, 3rem);
    padding-top: 2.5rem;
    padding-bottom: 3rem;
}

.store-header--processes {
    justify-content: center;
    align-items: center;
    text-align: center;
    border-bottom: var(--border-solid);
}

.store-header--processes .section-title {
    width: 100%;
}

.section-title {
    font-size: 3rem;
    line-height: 1;
}

.filters {
    display: flex;
    gap: 0.5rem;
}

.filter-btn {
    background: transparent;
    border: 2px solid var(--color-text);
    font-size: 1.2rem;
    padding: 0.2rem 1rem;
    cursor: pointer;
}

.filter-btn:hover {
    background-color: #e0e0e0;
}

.filter-btn.active {
    background-color: var(--color-text);
    color: white;
}

/* PRODUCT GRID (Legacy) */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
}

/* 3D CAROUSEL CONTAINER (Spatial Tunnel) */
.carousel-container {
    position: relative;
    width: 100%;
    height: 700px;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: visible;
    /* Prevent card shadow/badge clipping */
    margin-top: 1rem;
    background: transparent;
    perspective: 1500px;
    /* crucial for the tunnel depth */
    transform-style: preserve-3d;
}

/* Processes: wider stage, uses viewport width for three visible lanes */
.carousel-container--processes {
    width: 100%;
    max-width: none;
    min-height: min(640px, 80vh);
    height: auto;
    margin-top: 1.5rem;
    margin-left: auto;
    margin-right: auto;
    perspective: 1100px;
    perspective-origin: 50% 42%;
    transform-style: preserve-3d;
}

.carousel-container .product-card {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 350px;
    height: auto;
    background: transparent;
    border: none;
    overflow: visible;
    transition: transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.6s ease, filter 0.6s ease;
    cursor: pointer;
    margin: 0;
    will-change: transform, opacity, filter, z-index;
}

.carousel-container--processes .product-card {
    width: min(300px, calc((100vw - 3rem) / 3 - 1rem));
    max-width: 300px;
    transform-style: preserve-3d;
    backface-visibility: hidden;
    transition: transform 0.9s cubic-bezier(0.175, 0.88, 0.32, 1.08), opacity 0.72s ease, filter 0.72s ease;
}

.carousel-container .product-card .card-inner {
    border: 3px solid var(--color-text);
    background: var(--color-bg);
    transition: border-color 0.3s, box-shadow 0.3s;
}

/* Active center card styling */
.carousel-container .product-card.active-card .card-inner {
    border-color: var(--color-red);
    box-shadow: 20px 20px 0px rgba(0, 0, 0, 1);
}

.carousel-container .product-card.active-card {
    cursor: default;
}

.carousel-container .product-card.active-card:hover {
    transform: translate(-50%, -50%) scale(1.17) translateY(-4px) !important;
}

.carousel-container--processes .product-card.active-card:hover {
    transform: translate(-50%, -50%) translate3d(0, -6px, 96px) rotateZ(0deg) scale(1.14) !important;
}

/* Hide descriptions and buttons on inactive cards for cleaner spatial Look */
.carousel-container .product-card:not(.active-card) .product-desc,
.carousel-container .product-card:not(.active-card) .btn-add,
.carousel-container .product-card:not(.active-card) .stock-status {
    display: none;
}

/* Re-layout product info inline for inactive cards */
.carousel-container .product-card:not(.active-card) .product-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
}

.carousel-container .product-card:not(.active-card) .price-row {
    margin: 0;
}

.carousel-container .product-card:not(.active-card) .product-title {
    font-size: 1.6rem;
    margin: 0;
}

/* Processes carousel: left/right "near" lanes stay readable (not only center) */
.carousel-container--processes .product-card.carousel-card--side .product-desc,
.carousel-container--processes .product-card.carousel-card--side .stock-status {
    display: block;
}

.carousel-container--processes .product-card.carousel-card--side .btn-add {
    display: block;
}

.carousel-container--processes .product-card.carousel-card--side .product-info {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    padding: 0.75rem 0.85rem 0.9rem;
}

.carousel-container--processes .product-card.carousel-card--side .product-title {
    font-size: 1.15rem;
    margin-bottom: 0.35rem;
}

.carousel-container--processes .product-card.carousel-card--side .product-process-list {
    font-size: 0.62rem !important;
}

.carousel-container--processes .product-card.carousel-card--side .card-inner {
    border-color: rgba(255, 255, 255, 0.35);
    box-shadow: 12px 12px 0 rgba(0, 0, 0, 0.85);
}

/* Far wings: compact strip */
.carousel-container--processes .product-card.carousel-card--far .product-desc,
.carousel-container--processes .product-card.carousel-card--far .product-process-list,
.carousel-container--processes .product-card.carousel-card--far .btn-add,
.carousel-container--processes .product-card.carousel-card--far .stock-status {
    display: none;
}

.carousel-container--processes .product-card.carousel-card--far .product-info {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.25rem;
}

.carousel-container--processes .product-card.carousel-card--far .product-title {
    font-size: 1.2rem;
    margin: 0;
}

.carousel-container--processes .product-card.carousel-card--far .card-inner {
    opacity: 0.92;
}

.product-card {
    border: none;
    background: transparent;
    display: flex;
    flex-direction: column;
    position: relative;
}

.product-card .card-inner {
    border: var(--border-solid);
    background: var(--color-bg);
    transition: box-shadow 0.2s, transform 0.2s;
}

.product-grid .product-card:hover .card-inner {
    transform: translateY(-4px);
    box-shadow: 8px 8px 0px rgba(0, 0, 0, 1);
}

.badge {
    position: absolute;
    top: 10px;
    left: -10px;
    font-size: 1.2rem;
    padding: 0.2rem 0.8rem;
    border: 2px solid var(--color-text);
    z-index: 10;
    box-shadow: 3px 3px 0px rgba(0, 0, 0, 1);
}

.product-image {
    height: 250px;
    background-color: #222;
    border-bottom: var(--border-solid);
    overflow: hidden;
    position: relative;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.product-card:hover .product-image img {
    transform: scale(1.05);
    /* Chromatic Aberration Glitch Effect */
    filter: drop-shadow(4px 0px 0px rgba(255, 0, 0, 0.7)) drop-shadow(-4px 0px 0px rgba(0, 255, 255, 0.7));
    mix-blend-mode: color-dodge;
}

.placeholder-dark {
    background: repeating-linear-gradient(45deg, #111, #111 10px, #222 10px, #222 20px);
}

.neon-text-red {
    color: var(--color-red);
    text-shadow: 0 0 10px rgba(217, 28, 28, 0.5), 0 0 20px rgba(217, 28, 28, 0.3), 0 0 30px rgba(217, 28, 28, 0.2);
}

.placeholder-noise {
    background: url('data:image/svg+xml;utf8,<svg viewBox="0 0 200 200" xmlns="http://www.w3.org/2000/svg"><filter id="noiseFilter"><feTurbulence type="fractalNoise" baseFrequency="0.65" numOctaves="3" stitchTiles="stitch"/></filter><rect width="100%" height="100%" filter="url(%23noiseFilter)"/></svg>') #333;
}

.placeholder-blur {
    background: radial-gradient(circle at center, #555, #000);
}

.placeholder-minimal {
    background-color: #eaeaea;
}

/* MVP Glitch effect to hide low res images */
.glitch-image {
    animation: glitch-anim 2s infinite linear alternate-reverse;
    filter: sepia(100%) hue-rotate(320deg) saturate(300%) contrast(150%) blur(1px);
    mix-blend-mode: screen;
}

@keyframes glitch-anim {
    0% {
        clip-path: inset(20% 0 80% 0);
        transform: translate(-2px, 2px);
    }

    10% {
        clip-path: inset(80% 0 5% 0);
    }

    20% {
        clip-path: inset(10% 0 60% 0);
    }

    30% {
        clip-path: inset(30% 0 10% 0);
        transform: translate(2px, -2px);
    }

    40% {
        clip-path: inset(50% 0 30% 0);
    }

    50% {
        clip-path: inset(15% 0 75% 0);
        transform: translate(-1px, 1px);
    }

    60% {
        clip-path: inset(90% 0 2% 0);
    }

    70% {
        clip-path: inset(5% 0 90% 0);
        transform: translate(1px, -1px);
    }

    80% {
        clip-path: inset(40% 0 20% 0);
    }

    90% {
        clip-path: inset(70% 0 10% 0);
    }

    100% {
        clip-path: inset(0% 0 100% 0);
    }
}

.glitch-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.glitch-wrapper::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(0deg,
            rgba(0, 0, 0, 0.15),
            rgba(0, 0, 0, 0.15) 1px,
            transparent 1px,
            transparent 2px);
    z-index: 2;
    pointer-events: none;
}

.product-info {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.product-title {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.product-desc {
    font-size: 0.95rem;
    color: #444;
    flex-grow: 1;
}

.price-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    border-top: 2px dashed #ccc;
    padding-top: 1rem;
}

.price {
    font-size: 2.5rem;
    line-height: 1;
}

.stock-status {
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
}

.btn-add {
    background-color: var(--color-bg);
    border: none;
    border-top: var(--border-solid);
    font-size: 1.5rem;
    padding: 1rem;
    cursor: pointer;
    transition: background-color 0.2s, color 0.2s;
    width: 100%;
}

.btn-add:hover {
    background-color: var(--color-text);
    color: white;
}

.red-add {
    background-color: var(--color-red);
    color: white;
}

/* --- INTERACTIVE PURE CSS EMOTION TREE BLOCK --- */
.emotion-tree-block {
    position: relative;
    width: 100%;
    height: 80vh;
    min-height: 600px;
    background-color: var(--color-bg);
    /* Cyberpunk Grid Background */
    background-image:
        linear-gradient(rgba(255, 0, 0, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 0, 0, 0.03) 1px, transparent 1px);
    background-size: 40px 40px;
    overflow: hidden;
    border-top: 2px solid var(--color-red);
    border-bottom: 2px solid var(--color-red);
    box-shadow: inset 0 0 100px rgba(0, 0, 0, 0.9);
}

/* Unified SVG that covers the entire block */
.tree-svg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

/* Pulsing glow for outer colored dots */
.tip-dot {
    animation: tip-pulse 2.5s ease-in-out infinite alternate;
}

@keyframes tip-pulse {
    from {
        opacity: 0.6;
    }

    to {
        opacity: 1;
    }
}

/* Animated dashed lines */
.cyber-line {
    stroke: rgba(200, 0, 0, 0.45);
    stroke-width: 0.3;
    stroke-dasharray: 3 2;
    animation: dash 20s linear infinite;
}

@keyframes dash {
    to {
        stroke-dashoffset: -100;
    }
}

/* Center label floats over the SVG circle */
.tree-center-label {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    z-index: 10;
    pointer-events: none;
}

.tree-center-label h2 {
    font-size: clamp(1.2rem, 2.5vw, 2.5rem);
    margin: 0;
    text-shadow: 0 0 20px var(--color-red), 0 0 50px rgba(255, 0, 0, 0.3);
    letter-spacing: 4px;
}

/* Emoji hover zones, centered on each SVG dot */
.tree-node {
    position: absolute;
    width: 60px;
    height: 60px;
    transform: translate(-50%, -50%);
    z-index: 5;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 2.2rem;
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.2));
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), filter 0.4s;
    background: radial-gradient(circle, rgba(10, 10, 10, 0.9) 10%, transparent 70%);
    border-radius: 50%;
}

.tree-node:hover {
    transform: translate(-50%, -50%) scale(1.4);
    filter: drop-shadow(0 0 20px rgba(255, 255, 255, 0.8));
    z-index: 20;
}

/* Old flower dots are replaced */
.node-flower {
    display: none;
}

/* === Node positions: left = cx/160*100%, top = cy/80*100% === */
/* SVG viewBox 160x80, dots at: euphoria(80,6) awe(140,10) serenity(155,40)
   rage(140,72) surprise(80,76) melancholy(20,72) anticipation(5,40)
   thrill(20,10) pride(36,25) */
.node-euphoria {
    left: 50%;
    top: 7.5%;
}

.node-awe {
    left: 87.5%;
    top: 12.5%;
}

.node-serenity {
    left: 96.9%;
    top: 50%;
}

.node-rage {
    left: 87.5%;
    top: 90%;
}

.node-surprise {
    left: 50%;
    top: 95%;
}

.node-melancholy {
    left: 12.5%;
    top: 90%;
}

.node-anticipation {
    left: 3.1%;
    top: 50%;
}

.node-thrill {
    left: 12.5%;
    top: 12.5%;
}

.node-pride {
    left: 22.5%;
    top: 31.25%;
}

/* === Emotion Popup (JS-driven, centered on tree block) === */
.emotion-popup {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.88);
    width: 440px;
    min-height: 260px;
    background: #050505;
    border-radius: 12px;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    z-index: 50;
    transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.165, 0.84, 0.44, 1), visibility 0.3s;
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.08),
        0 30px 80px rgba(0, 0, 0, 0.85);
}

.emotion-popup.visible {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translate(-50%, -50%) scale(1);
    animation: popup-enter 0.3s cubic-bezier(0.165, 0.84, 0.44, 1) forwards;
}

@keyframes popup-enter {
    from {
        transform: translate(-50%, -50%) scale(0.88);
        filter: blur(4px);
    }

    to {
        transform: translate(-50%, -50%) scale(1);
        filter: blur(0);
    }
}

.emotion-popup-bar {
    width: 100%;
    height: 4px;
    background: #fff;
    transition: background 0.2s, box-shadow 0.2s;
}

.emotion-popup-header {
    padding: 1.8rem 2rem 0.6rem;
    position: relative;
    overflow: hidden;
}

/* Atmospheric background glow */
.emotion-popup-header::after {
    content: '';
    position: absolute;
    width: 260px;
    height: 260px;
    border-radius: 50%;
    background: radial-gradient(circle, var(--nc, #fff) 0%, transparent 70%);
    opacity: 0.06;
    top: -80px;
    right: -60px;
    pointer-events: none;
}

.emotion-popup-title {
    font-size: 2.2rem;
    margin: 0 0 0.3rem;
    letter-spacing: 3px;
    position: relative;
    z-index: 2;
}

.emotion-popup-body {
    padding: 0.4rem 2rem 1.8rem;
}

.emotion-popup-desc {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.7;
    margin: 0;
}

.emotion-popup-tag {
    display: inline-block;
    margin-top: 1rem;
    font-size: 0.72rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    opacity: 0.5;
}



/* --- Cafe "Mr. Robot" Hacker Block Styling --- */
.cafe-hacker-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 45%;
    pointer-events: none;
    z-index: 2;
    background: repeating-linear-gradient(to bottom,
            transparent 0px,
            transparent 3px,
            rgba(0, 0, 0, 0.18) 3px,
            rgba(0, 0, 0, 0.18) 4px);
}

.cafe-status-line {
    position: absolute;
    top: calc(45% - 2rem);
    left: 0;
    width: 100%;
    padding: 0.4rem 1.5rem;
    font-family: 'Courier New', monospace;
    font-size: 0.75rem;
    color: rgba(255, 80, 80, 0.85);
    letter-spacing: 2px;
    background: linear-gradient(to right, rgba(0, 0, 0, 0.9), rgba(0, 0, 0, 0.5) 80%, transparent);
    z-index: 3;
}

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

@keyframes blink-cursor {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }
}

.red-add:hover {
    background-color: #a30000;
}

/* --- MINION EASTER EGG --- */
.type-text-easter-egg {
    opacity: 0;
    overflow: hidden;
    white-space: nowrap;
    border-right: 4px solid var(--color-red);
    width: 0;
    margin: 0 auto;
}

.dark-theme .type-text-easter-egg.active {
    opacity: 1;
    animation: typing 3s steps(20, end) forwards, blink-caret 0.75s step-end infinite;
}

@keyframes typing {
    from {
        width: 0;
    }

    to {
        width: 100%;
    }
}

@keyframes blink-caret {

    from,
    to {
        border-color: transparent;
    }

    50% {
        border-color: var(--color-red);
    }
}

/* FOOTER */
.footer {
    border-top: var(--border-solid);
    background-color: var(--color-text);
    color: white;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.text-lg {
    font-size: 4rem;
    line-height: 1;
}

.footer-links {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 1rem;
    font-size: 1.5rem;
}

.footer-links a {
    color: white;
    text-decoration: none;
}

.footer-links a:hover {
    color: var(--color-red);
    text-decoration: underline;
}

.footer-bottom {
    border-top: 1px solid #444;
    padding-top: 2rem;
    text-align: center;
    font-size: 1.2rem;
    color: #888;
}

/* RESPONSIVE */
@media (max-width: 900px) {
    .hero-section {
        grid-template-columns: 1fr;
    }

    .hero-content {
        border-right: none;
        border-bottom: var(--border-solid);
    }

    .hero-visual {
        min-height: 300px;
    }

    .store-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .store-header--processes {
        align-items: center;
        text-align: center;
    }

    .carousel-container--processes {
        min-height: min(620px, 78vh);
    }

    .split-section.reverse-mobile {
        display: flex;
        flex-direction: column;
    }

    .split-section.order-reverse .split-content,
    .split-section.order-reverse .split-image {
        grid-column: auto;
        grid-row: auto;
    }

    .split-image {
        min-height: 400px;
        border-left: none !important;
        border-right: none !important;
        border-top: var(--border-solid);
    }

    .huge-title {
        font-size: 3rem;
    }

    .split-content {
        padding: 2rem;
    }

    .crystal-btn {
        font-size: 1.5rem;
        padding: 1rem 1.5rem;
        width: 100%;
    }
}

/* BOUTIQUE 111 GRID LAYOUT */
.boutique-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    grid-gap: 1rem;
    padding: 1rem;
    background-color: #050505;
}

.b-item {
    position: relative;
    overflow: hidden;
    background-color: #111;
    min-height: 400px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.b-item img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.6;
    transition: opacity 0.4s ease, transform 4s ease;
}

.b-item:hover img {
    opacity: 0.8;
    transform: scale(1.05);
}

.b-overlay {
    position: relative;
    z-index: 2;
    padding: 3rem;
    color: white;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0) 100%);
}

.b-overlay-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80%;
    text-align: center;
    background: none;
    padding: 0;
}

/* Span classes for the grid */
.b-span-12 {
    grid-column: span 12;
}

.b-span-8 {
    grid-column: span 8;
}

.b-span-6 {
    grid-column: span 6;
}

.b-span-4 {
    grid-column: span 4;
}

.b-span-3 {
    grid-column: span 3;
}

/* Text variations for boutique layout */
.b-title {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    line-height: 1;
    text-transform: uppercase;
}

.b-subtitle {
    font-size: 1.5rem;
    color: var(--color-red);
    margin-bottom: 0.5rem;
}

.b-text {
    font-size: 1.1rem;
    line-height: 1.6;
    max-width: 600px;
    opacity: 0.9;
}

.b-text-center {
    margin-left: auto;
    margin-right: auto;
}

/* Specific heights */
.h-lg {
    min-height: 70vh;
}

.h-md {
    min-height: 50vh;
}

.h-sm {
    min-height: 40vh;
}

@media (max-width: 900px) {

    .b-span-8,
    .b-span-6,
    .b-span-4,
    .b-span-3 {
        grid-column: span 12;
    }

    .b-title {
        font-size: 2.5rem;
    }

    .b-item {
        min-height: 350px;
    }

    .h-lg,
    .h-md {
        min-height: 50vh;
    }
}

/* ========================================================================= */
/* PAGE TRANSITION / PRELOADER */
/* ========================================================================= */
#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: transparent;
    z-index: 99999;
    pointer-events: none;
    display: flex;
    justify-content: center;
    align-items: center;
}

.preloader-star {
    position: absolute;
    width: 80px;
    height: 80px;
    color: var(--color-red);
    /* раньше анимировали filter — дорого; интро теперь без этого пути */
    will-change: transform;
}

/* --- 3D EMOTION ROOM --- */
.emotion-philosophy-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(5, 5, 5, 0.95);
    z-index: 99999;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.8s ease;
    backdrop-filter: blur(10px);
}

.emotion-philosophy-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.close-btn {
    position: absolute;
    top: 100px;
    right: 3rem;
    background: transparent;
    border: none;
    color: white;
    font-size: 3rem;
    cursor: pointer;
    transition: color 0.3s, transform 0.3s;
    z-index: 100000;
}

.close-btn:hover {
    color: var(--color-red);
    transform: scale(1.1) rotate(90deg);
}

.philosophy-content {
    max-width: 800px;
    padding: 3rem;
    text-align: center;
    transform: translateY(30px);
    transition: transform 0.8s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.emotion-philosophy-overlay.active .philosophy-content {
    transform: translateY(0);
}

#phil-title {
    font-size: 4rem;
    margin-bottom: 0.5rem;
    letter-spacing: 5px;
}

#phil-subtitle {
    font-size: 1.5rem;
    color: #888;
    margin-bottom: 3rem;
    letter-spacing: 2px;
}

.phil-body-text {
    font-size: 1.25rem;
    line-height: 1.8;
    color: #ccc;
    text-align: left;
}

.phil-body-text p {
    margin-bottom: 1.5rem;
}

/* --- ARCHIVE & COLLECTION AESTHETICS --- */
.glass-panel {
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(15px) saturate(180%);
    -webkit-backdrop-filter: blur(15px) saturate(180%);
    border: 1px solid rgba(0, 0, 0, 0.05);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.02), 0 1px 3px rgba(0, 0, 0, 0.08);
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    padding: 2.5rem;
    position: relative;
    overflow: hidden;
    border-radius: 1px;
}

.glass-panel:hover {
    background: rgba(255, 255, 255, 0.6);
    border-color: rgba(0, 0, 0, 0.1);
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.system-card {
    border-left: 2px solid var(--color-red) !important;
}

.purchased-card {
    border-left: 2px solid #00f2ff !important;
}

.archive-section {
    padding: 8rem 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    background: radial-gradient(circle at center, #0f0f0f 0%, #050505 100%);
    color: white;
    min-height: 100vh;
}

.collection-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 40px;
    width: 100%;
    max-width: 1200px;
    margin-top: 4rem;
}

/*
 * Кнопка «Архив»: flex + текст в потоке (без ::before/::after) — иначе вертикальное выравнивание «плывёт».
 * eif-build: 20260411
 */
.nav-archive-btn {
    --archive-bg: #111111;
    --archive-fg: #ffffff;
    --archive-border: #111111;
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    padding: 0 20px;
    min-height: 48px;
    min-width: 160px;
    box-sizing: border-box;
    font-family: 'Jora TYGRA', 'JoraTYGRA', 'Bebas Neue', 'Impact', sans-serif;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.08em;
    border-radius: 12px;
    border: 1px solid var(--archive-border);
    background: var(--archive-bg);
    color: var(--archive-fg) !important;
    -webkit-text-fill-color: currentColor !important;
    white-space: nowrap;
    line-height: 1.4;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.65) inset, 0 6px 18px rgba(20, 18, 24, 0.08);
    transition:
        background-color 0.2s ease,
        border-color 0.2s ease,
        color 0.2s ease,
        box-shadow 0.2s ease,
        transform 0.2s ease,
        opacity 0.2s ease;
}

.page-wrapper.light-theme .nav-archive-btn,
.light-theme .nav-archive-btn,
html.light-theme .nav-archive-btn,
body.light-theme .nav-archive-btn {
    --archive-bg: #111111;
    --archive-fg: #ffffff;
    --archive-border: #111111;
}

.page-wrapper.dark-theme .nav-archive-btn,
.dark-theme .nav-archive-btn,
html.dark-theme .nav-archive-btn,
body.dark-theme .nav-archive-btn {
    --archive-bg: #ffffff;
    --archive-fg: #111111;
    --archive-border: #ffffff;
}

.nav-archive-btn:hover {
    color: var(--archive-fg) !important;
    -webkit-text-fill-color: currentColor !important;
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.18), 0 1px 0 rgba(255, 255, 255, 0.08) inset;
    transform: translateY(-1px);
}

.nav-archive-btn:active {
    transform: translateY(0);
    opacity: 0.96;
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.65) inset, 0 6px 18px rgba(20, 18, 24, 0.08);
}

.nav-archive-btn:focus-visible {
    outline: 2px solid #D91C1C;
    outline-offset: 2px;
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.18), 0 1px 0 rgba(255, 255, 255, 0.08) inset;
}

a.nav-archive-btn.archive-nav-dynamic {
    min-width: 160px;
    box-sizing: border-box;
}

@media (min-width: 769px) {
    .navbar {
        position: sticky;
    }

    .navbar .nav-center {
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
    }

    .navbar .nav-right {
        margin-left: auto;
    }
}

@media (min-width: 769px) and (hover: hover) and (pointer: fine) {
    a.nav-archive-btn.archive-nav-dynamic {
        inline-size: 56px;
        min-width: 56px;
        padding: 0 18px;
        justify-content: center;
        text-align: center;
        gap: 0;
        overflow: hidden;
        font-size: 0 !important;
        letter-spacing: 0 !important;
        color: transparent !important;
        -webkit-text-fill-color: transparent !important;
        transition:
            inline-size 0.28s cubic-bezier(0.22, 1, 0.36, 1),
            background-color 0.2s ease,
            border-color 0.2s ease,
            color 0.2s ease,
            box-shadow 0.2s ease,
            transform 0.2s ease,
            opacity 0.2s ease;
    }

    a.nav-archive-btn.archive-nav-dynamic::before {
        content: "";
        display: inline-block;
        flex: 0 0 16px;
        width: 16px;
        height: 16px;
        background-color: var(--archive-fg);
        -webkit-mask: url("../../images/logo-red.svg") center / contain no-repeat;
        mask: url("../../images/logo-red.svg") center / contain no-repeat;
    }

    a.nav-archive-btn.archive-nav-dynamic::after {
        content: none;
        display: none;
    }

    a.nav-archive-btn.archive-nav-dynamic:hover,
    a.nav-archive-btn.archive-nav-dynamic:focus-visible,
    .archive-site-header--bar a.nav-archive-btn.archive-nav-dynamic {
        inline-size: 176px;
        gap: 12px;
        font-size: 13px !important;
        letter-spacing: 0.08em !important;
        color: var(--archive-fg) !important;
        -webkit-text-fill-color: currentColor !important;
    }
}

/* Мобильная шапка: компактный бренд + CTA, ниже нав-таб */
@media (max-width: 768px) {
    body {
        padding-bottom: env(safe-area-inset-bottom, 0);
    }

    .navbar.site-nav,
    .navbar {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        grid-template-rows: minmax(56px, auto) auto !important;
        align-items: stretch !important;
        column-gap: 0 !important;
        row-gap: 0 !important;
        height: auto !important;
        padding-left: max(8px, env(safe-area-inset-left)) !important;
        padding-right: max(8px, env(safe-area-inset-right)) !important;
        padding-top: max(8px, env(safe-area-inset-top)) !important;
        padding-bottom: 0 !important;
    }

    /* Строка 1: бренд слева, главный CTA справа */
    .navbar .logo {
        grid-column: 1;
        grid-row: 1;
        font-size: 1.18rem !important;
        letter-spacing: 0.045em !important;
        gap: 10px !important;
        min-width: 0;
        justify-self: stretch;
        display: flex;
        justify-content: center;
        align-items: center;
        align-self: stretch;
        min-height: 56px !important;
        padding: 0 10px !important;
        border-right: var(--border-solid) !important;
        box-sizing: border-box !important;
        text-align: center !important;
    }

    .navbar .logo-svg {
        height: 28px !important;
        width: 28px !important;
        min-width: 28px !important;
        min-height: 28px !important;
    }

    .navbar .nav-right {
        grid-column: 2;
        grid-row: 1;
        margin-left: 0;
        justify-self: stretch;
        display: flex;
        justify-content: stretch;
        align-items: center;
        flex-shrink: 0;
        align-self: stretch;
        min-height: 56px !important;
        padding: 0 !important;
        box-sizing: border-box !important;
    }

    /* id="auth-controls" на части страниц (архив) — иначе #auth-controls { justify-content: flex-end } ломает 50/50 сетку */
    .navbar .nav-right#auth-controls {
        justify-content: stretch !important;
        align-items: center !important;
        width: 100% !important;
    }

    .navbar .nav-archive-btn,
    .navbar .nav-right .nav-archive-btn,
    .navbar .nav-right .p-badge {
        padding: 0 10px !important;
        font-size: 15px !important;
        line-height: 1.4 !important;
        white-space: nowrap;
        display: inline-flex !important;
        align-items: center;
        justify-content: center;
        text-align: center;
        min-height: 56px !important;
        min-width: 100% !important;
        max-width: none !important;
        box-sizing: border-box !important;
        border-radius: 0 !important;
        border-width: 0 !important;
        font-weight: 600 !important;
        letter-spacing: 0.09em !important;
        text-decoration: none !important;
        -webkit-tap-highlight-color: transparent;
        box-shadow: none !important;
    }

    .navbar .nav-right .p-badge {
        background: var(--color-text) !important;
        color: var(--color-bg) !important;
        border: 2px solid var(--color-text) !important;
    }

    .light-theme .navbar .nav-archive-btn,
    .light-theme .navbar .nav-right .nav-archive-btn,
    html.light-theme .navbar .nav-archive-btn {
        --archive-bg: #111111;
        --archive-fg: #ffffff;
    }

    .dark-theme .navbar .nav-archive-btn,
    .dark-theme .navbar .nav-right .nav-archive-btn,
    html.dark-theme .navbar .nav-archive-btn {
        --archive-bg: #111111;
        --archive-fg: #ffffff;
        --archive-border: #111111;
    }

    .navbar .nav-archive-btn.archive-nav-dynamic {
        inline-size: auto !important;
        min-width: 100% !important;
        max-width: none !important;
        width: 100%;
        height: 100%;
        overflow: visible;
        color: var(--archive-fg) !important;
        -webkit-text-fill-color: currentColor !important;
    }

    .navbar .nav-archive-btn.archive-nav-dynamic:active,
    .navbar .nav-archive-btn.archive-nav-dynamic:focus-visible {
        transform: none;
    }

    .navbar .nav-archive-btn.archive-nav-dynamic::before,
    .navbar .nav-archive-btn.archive-nav-dynamic::after {
        content: none !important;
        display: none !important;
    }

    /* Строка 2: мобильные табы */
    .navbar .nav-center {
        grid-column: 1 / -1;
        grid-row: 2;
        width: 100%;
        display: grid !important;
        grid-template-columns: 1fr 1fr 1fr;
        align-items: center;
        justify-items: center;
        gap: 0;
        border-top: var(--border-solid);
        padding: 0;
        margin: 0;
        position: static !important;
        left: auto !important;
        transform: none !important;
        max-width: none !important;
        box-sizing: border-box;
    }

    .navbar .nav-center a {
        font-size: 13px !important;
        letter-spacing: 0.05em !important;
        padding: 10px 4px !important;
        text-align: center;
        min-width: 0;
        width: 100%;
        min-height: 44px !important;
        border-radius: 0 !important;
        box-sizing: border-box !important;
        color: var(--color-text) !important;
    }

    .navbar .nav-center a.active {
        background: transparent;
        color: var(--color-red);
    }

    .navbar .nav-center a.active::after {
        display: block;
        width: 32px;
        left: 50%;
        transform: translateX(-50%);
        bottom: 4px;
        height: 2px;
    }

    .navbar .nav-center a + a {
        border-left: 1px solid color-mix(in srgb, var(--border-color) 100%, transparent);
    }
}

@media (max-width: 380px) {
    .navbar .nav-center a {
        font-size: 0.72rem;
        letter-spacing: 0.04em;
    }
}

/* MAPLIBRE CONTROLS */
.maplibregl-ctrl-bottom-left,
.maplibregl-ctrl-bottom-right {
    margin-bottom: calc(12px + env(safe-area-inset-bottom, 0px));
}

.maplibregl-ctrl-bottom-left {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
    margin-left: calc(12px + env(safe-area-inset-left, 0px));
}

.maplibregl-ctrl-bottom-right {
    margin-right: calc(12px + env(safe-area-inset-right, 0px));
}

.maplibregl-ctrl-bottom-left:empty,
.maplibregl-ctrl-bottom-right:empty {
    display: none;
}

.maplibregl-ctrl-group {
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 18px !important;
    background: rgba(8, 8, 10, 0.64) !important;
    box-shadow:
        0 12px 30px rgba(0, 0, 0, 0.24),
        0 0 0 1px rgba(255, 255, 255, 0.04) inset !important;
    backdrop-filter: blur(14px) saturate(140%);
    -webkit-backdrop-filter: blur(14px) saturate(140%);
}

.maplibregl-ctrl-group button {
    width: 42px;
    height: 42px;
    background: transparent !important;
}

.maplibregl-ctrl-group button + button {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.maplibregl-ctrl-group button .maplibregl-ctrl-icon {
    opacity: 0.82;
    filter: invert(1) grayscale(1);
}

.maplibregl-ctrl-group button:hover {
    background: rgba(255, 255, 255, 0.08) !important;
}

.maplibregl-ctrl-group button:hover .maplibregl-ctrl-icon {
    opacity: 1;
}

.maplibregl-ctrl-attrib {
    align-self: flex-start;
    margin: 0 !important;
    max-width: 168px;
    padding: 2px 7px !important;
    border-radius: 12px !important;
    background: rgba(8, 8, 10, 0.48) !important;
    color: rgba(255, 255, 255, 0.62) !important;
    box-shadow:
        0 10px 24px rgba(0, 0, 0, 0.18),
        0 0 0 1px rgba(255, 255, 255, 0.04) inset;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    opacity: 0.22;
    font-size: 10px !important;
    line-height: 1.2 !important;
    transition:
        opacity 0.18s ease,
        background-color 0.18s ease,
        color 0.18s ease,
        max-width 0.18s ease;
}

.maplibregl-ctrl-attrib:hover,
.maplibregl-ctrl-attrib:focus-within {
    opacity: 0.88;
}

.maplibregl-ctrl-attrib a {
    color: inherit !important;
}

.light-theme .maplibregl-ctrl-group,
html.light-theme .maplibregl-ctrl-group,
body.light-theme .maplibregl-ctrl-group {
    border-color: rgba(17, 17, 17, 0.08) !important;
    background: rgba(255, 255, 255, 0.72) !important;
    box-shadow:
        0 12px 30px rgba(17, 17, 17, 0.08),
        0 0 0 1px rgba(255, 255, 255, 0.3) inset !important;
}

.light-theme .maplibregl-ctrl-group button + button,
html.light-theme .maplibregl-ctrl-group button + button,
body.light-theme .maplibregl-ctrl-group button + button {
    border-top-color: rgba(17, 17, 17, 0.08);
}

.light-theme .maplibregl-ctrl-group button .maplibregl-ctrl-icon,
html.light-theme .maplibregl-ctrl-group button .maplibregl-ctrl-icon,
body.light-theme .maplibregl-ctrl-group button .maplibregl-ctrl-icon {
    filter: none;
}

.light-theme .maplibregl-ctrl-group button:hover,
html.light-theme .maplibregl-ctrl-group button:hover,
body.light-theme .maplibregl-ctrl-group button:hover {
    background: rgba(17, 17, 17, 0.06) !important;
}

.light-theme .maplibregl-ctrl-attrib,
html.light-theme .maplibregl-ctrl-attrib,
body.light-theme .maplibregl-ctrl-attrib {
    background: rgba(255, 255, 255, 0.76) !important;
    color: rgba(17, 17, 17, 0.58) !important;
    box-shadow:
        0 10px 24px rgba(17, 17, 17, 0.08),
        0 0 0 1px rgba(255, 255, 255, 0.35) inset;
}

@media (max-width: 768px) {
    .maplibregl-ctrl-group button {
        width: 40px;
        height: 40px;
    }

    .maplibregl-ctrl-attrib {
        max-width: 132px;
        opacity: 0.16;
    }
}