/* style.css — основные стили для TOCH.KA */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

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

:root {
    --dark-bg-1: #0F0F12;
    --dark-bg-2: #141418;
    --terracotta: #C97C5D;
    --sage-green: #A0B29C;
    --glass-bg: rgba(255, 255, 255, 0.08);
    --glass-border: rgba(255, 255, 255, 0.1);
    --text-color: white;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

@media (min-width: 769px) {
    html {
        scroll-snap-type: y mandatory;
    }
}

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background: var(--dark-bg-1);
    color: var(--text-color);
    min-height: 100vh;
    width: 100%;
}

/* Логотип (фиксированный) — одинаковый на всех устройствах */
.logo {
    position: fixed;
    top: 2rem;
    left: 2rem;
    font-weight: 700;
    font-size: 2rem;
    z-index: 200;
    background: linear-gradient(135deg, var(--terracotta), var(--sage-green));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    cursor: pointer;
    text-decoration: none;
    /* Фиксация для предотвращения сдвига */
    transform: translateZ(0);
    will-change: transform;
}

.logo span {
    color: var(--terracotta);
    -webkit-text-fill-color: initial;
    background: none;
}

/* Гамбургер (фиксированный) — одинаковый на всех устройствах */
.hamburger {
    position: fixed;
    top: 2rem;
    right: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 20px;
    cursor: pointer;
    z-index: 200;
    /* Фиксация для предотвращения сдвига */
    transform: translateZ(0);
    will-change: transform;
}

.hamburger span {
    width: 100%;
    height: 2px;
    background: var(--text-color);
    transition: all 0.3s ease;
    transform-origin: left;
}

.hamburger.active span:first-child {
    transform: rotate(45deg) translate(2px, -2px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:last-child {
    transform: rotate(-45deg) translate(2px, 2px);
}

/* ========================================
   АДАПТИВНАЯ ВЕРСТКА — Mobile First
   ======================================== */

/* Mobile: до 576px */
@media (max-width: 576px) {
    /* Логотип и бургер компактнее */
    .logo {
        font-size: 1.5rem;
        top: 1.5rem;
        left: 1.5rem;
    }
    .hamburger {
        top: 1.5rem;
        right: 1.5rem;
        width: 26px;
        height: 18px;
    }
    
    /* Меню на всю ширину */
    .menu-overlay {
        width: 100%;
        max-width: 320px;
        justify-content: flex-start;
        padding-top: 6rem;
        padding-left: 1.5rem;
        padding-right: 1.5rem;
    }
    .menu-links {
        padding: 0;
    }
    .menu-links a {
        font-size: 1rem;
        padding: 0.6rem 0.75rem;
    }
    .lang-switcher {
        padding: 1rem;
        margin-top: 1.5rem;
    }
    .lang-btn {
        padding: 0.35rem 0.75rem;
        font-size: 0.8rem;
        min-width: 44px;
    }
    
    /* Секции */
    .section {
        padding: 6rem 1.5rem 2rem;
    }
    .section h2 {
        font-size: 1.75rem;
    }
    .section p {
        font-size: 1rem;
    }
    
    /* Карточки в одну колонку */
    .tech-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    .tech-card {
        padding: 1.25rem;
    }
    .tech-card h3 {
        font-size: 1.2rem;
    }
    .tech-icon {
        font-size: 2rem;
    }
}

/* Tablet: 577px — 991px */
@media (min-width: 577px) and (max-width: 991px) {
    .logo {
        font-size: 1.75rem;
    }
    
    .menu-overlay {
        max-width: 340px;
        padding: 2rem;
        padding-top: 5rem;
    }
    .menu-links a {
        font-size: 1.05rem;
    }
    
    .section {
        padding: 5rem 2rem;
    }
    .section h2 {
        font-size: 2.25rem;
    }
    .section p {
        font-size: 1.1rem;
    }
    
    /* Карточки 2 в ряд */
    .tech-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.25rem;
    }
    .tech-card {
        padding: 1.5rem;
    }
}

/* Desktop: 992px — 1199px */
@media (min-width: 992px) and (max-width: 1199px) {
    .section h2 {
        font-size: 2.5rem;
    }
    
    .tech-card {
        padding: 1rem;
    }
    .tech-card h3 {
        font-size: 1rem;
    }
    .tech-card p {
        font-size: 0.8rem;
    }
    .tech-icon {
        font-size: 1.75rem;
    }
}

/* Large Desktop: 1200px+ */
@media (min-width: 1200px) {
    .section-content {
        max-width: 1200px;
    }
    .section h2 {
        font-size: 3rem;
    }
    .section p {
        font-size: 1.25rem;
    }
    
    .tech-card {
        padding: 1.25rem;
    }
    .tech-card h3 {
        font-size: 1.1rem;
    }
    .tech-card p {
        font-size: 0.85rem;
    }
}

/* Меню-оверлей */
.menu-overlay {
    position: fixed;
    top: 0;
    right: 0;
    width: 85%;
    max-width: 360px;
    height: 100%;
    height: 100dvh;
    background: rgba(15, 15, 18, 0.98);
    backdrop-filter: blur(20px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.77, 0, 0.175, 1);
    z-index: 150;
    padding: 2rem;
}

.menu-overlay.active {
    transform: translateX(0);
}

/* Затемнение фона при открытом меню */
.menu-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    height: 100dvh;
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s ease, visibility 0.4s ease;
    z-index: 140;
}

.menu-backdrop.active {
    opacity: 1;
    visibility: visible;
}

.menu-links {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    text-align: left;
    width: 100%;
    padding: 0 1rem;
}

.menu-links a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: 400;
    letter-spacing: 0.5px;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    transition: all 0.25s ease;
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.menu-links a::before {
    content: '';
    width: 4px;
    height: 4px;
    background: var(--terracotta);
    border-radius: 50%;
    opacity: 0;
    transition: opacity 0.25s ease;
}

.menu-links a:hover {
    color: var(--text-color);
    background: rgba(201, 124, 93, 0.1);
    transform: translateX(4px);
}

.menu-links a:hover::before {
    opacity: 1;
}

.lang-switcher {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-top: 2rem;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    border: 1px solid var(--glass-border);
}

.lang-row {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
}

.lang-btn {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.6);
    padding: 0.4rem 1rem;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.2s ease;
    min-width: 50px;
}

.lang-btn:hover {
    border-color: rgba(201, 124, 93, 0.5);
    color: rgba(255, 255, 255, 0.9);
}

.lang-btn.active {
    background: var(--terracotta);
    border-color: var(--terracotta);
    color: white;
}

.company-info {
    position: absolute;
    bottom: 1.5rem;
    left: 0;
    right: 0;
    text-align: center;
    color: rgba(255,255,255,0.4);
    font-size: 0.8rem;
    letter-spacing: 0.5px;
    font-weight: 300;
}

/* Секции-слайды */
.section {
    min-height: 100vh;
    min-height: 100dvh;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6rem 1.5rem 2rem;
    position: relative;
    overflow: hidden;
    box-sizing: border-box;
}

@media (min-width: 769px) {
    .section {
        padding: 4rem 2rem;
        scroll-snap-align: start;
        scroll-snap-stop: always;
    }
}

.section-content {
    max-width: 800px;
    text-align: center;
    position: relative;
    z-index: 10;
}

.section h2 {
    font-size: clamp(1.5rem, 5vw, 3rem);
    margin-bottom: 1rem;
    background: linear-gradient(135deg, var(--terracotta), var(--sage-green));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.section p {
    font-size: clamp(0.9rem, 2.5vw, 1.2rem);
    color: rgba(255,255,255,0.8);
    margin-bottom: 2rem;
}

/* Контейнеры для эффектов */
.particle-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 5;
}

.particle {
    position: absolute;
    width: 6px;
    height: 6px;
    background: var(--terracotta);
    border-radius: 50%;
    box-shadow: 0 0 15px var(--terracotta);
    /* Ограничиваем позиционирование */
    max-left: calc(100% - 6px);
    max-top: calc(100% - 6px);
}

.mosaic-piece {
    position: absolute;
    width: 50px;
    height: 50px;
    background: var(--terracotta);
    opacity: 0.2;
    border-radius: 10px;
    transform-origin: center;
    filter: blur(2px);
    /* Ограничиваем позиционирование */
    max-left: calc(100% - 50px);
    max-top: calc(100% - 50px);
}

/* ===== НОВЫЕ СТИЛИ ДЛЯ КАРТОЧЕК ТЕХНОЛОГИЙ ===== */
.tech-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
    width: 100%;
    max-width: 100%;
}

/* Гарантия что grid не выходит за пределы */
.tech-grid > * {
    min-width: 0;
}

/* Desktop: 3 карточки в ряд (шире для многоязычности) */
@media (min-width: 992px) {
    .tech-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 1.5rem;
    }
}

.tech-card {
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 1.8rem 1.5rem;
    transition: transform 0.3s ease, border-color 0.3s ease;
    text-align: left;
    opacity: 0;
    transform: translateY(30px);
    will-change: transform, opacity;
}

.tech-card.visible {
    opacity: 1;
    transform: translateY(0);
}

.tech-card:hover {
    transform: translateY(-6px) scale(1.02);
    border-color: var(--terracotta);
}

.tech-icon {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--terracotta);
}

.tech-card h3 {
    font-size: 1.4rem;
    margin-bottom: 0.5rem;
    color: var(--text-color);
    font-weight: 600;
}

.tech-card p {
    font-size: 0.95rem;
    color: rgba(255,255,255,0.7);
    line-height: 1.5;
}

/* ===== КНОПКИ НАВИГАЦИИ (GLASSMORPHISM) ===== */
.nav-arrows {
    position: fixed;
    right: 2rem;
    bottom: 2rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    z-index: 100;
}

.nav-arrow {
    width: 50px;
    height: 50px;
    border: 1px solid var(--glass-border);
    border-radius: 50%;
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: var(--text-color);
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nav-arrow:hover {
    background: rgba(201, 124, 93, 0.3);
    border-color: var(--terracotta);
    transform: scale(1.1);
}

.nav-arrow:active {
    transform: scale(0.95);
}

.nav-arrow:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.nav-arrow:disabled:hover {
    background: var(--glass-bg);
    border-color: var(--glass-border);
    transform: none;
}

@media (max-width: 768px) {
    .nav-arrows {
        right: 1rem;
        bottom: 1rem;
    }
    
    .nav-arrow {
        width: 44px;
        height: 44px;
        font-size: 1rem;
    }
}

/* ===== АСИММЕТРИЧНЫЙ GRID ДЛЯ БЕЗОПАСНОСТИ ===== */
.security-content {
    max-width: 1100px;
    width: 100%;
}

.security-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    grid-template-rows: auto auto;
    gap: 1rem;
    margin-top: 1.5rem;
}

.security-card {
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 1.25rem;
    text-align: left;
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.security-card:hover {
    transform: translateY(-4px);
    border-color: var(--terracotta);
}

.security-card-large {
    grid-row: span 1;
}

.security-card-wide {
    grid-column: span 3;
}

.security-icon {
    font-size: 1.75rem;
    color: var(--terracotta);
    margin-bottom: 0.75rem;
}

.security-card h3 {
    font-size: 1.1rem;
    margin-bottom: 0.75rem;
    color: var(--text-color);
}

.security-problem-wrapper {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
    padding: 0.5rem 0.75rem;
    background: rgba(255, 100, 100, 0.1);
    border-radius: 8px;
    border-left: 3px solid rgba(255, 100, 100, 0.5);
}

.security-problem-icon {
    font-size: 0.9rem;
}

.security-problem-text {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.6);
}

.security-toggle-wrapper {
    position: relative;
    margin-bottom: 0.5rem;
}

.security-toggle-btn {
    width: 100%;
    padding: 0.5rem 0.75rem;
    background: rgba(255, 100, 100, 0.1);
    border: 1px solid rgba(255, 100, 100, 0.3);
    border-radius: 8px;
    color: rgba(255,255,255,0.7);
    font-size: 0.8rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: all 0.3s ease;
    position: relative;
    z-index: 10;
}

.security-toggle-btn:hover {
    background: rgba(255, 100, 100, 0.2);
}

.security-toggle-btn i {
    transition: transform 0.3s ease;
}

.security-toggle-btn.active i {
    transform: rotate(180deg);
}

.security-problem-collapsible {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 0.25rem;
    padding: 0.75rem;
    font-size: 0.8rem;
    color: rgba(255,255,255,0.8);
    background: rgba(30, 30, 35, 0.98);
    border: 1px solid rgba(255, 100, 100, 0.3);
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    display: none;
    z-index: 100;
}

.security-problem-collapsible.show {
    display: block;
    animation: fadeInDropdown 0.2s ease;
}

@keyframes fadeInDropdown {
    from { opacity: 0; transform: translateY(-5px); }
    to { opacity: 1; transform: translateY(0); }
}

.security-solution {
    font-size: 0.9rem;
    color: rgba(255,255,255,0.9);
    line-height: 1.4;
}

.security-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

/* ===== ВАРИАНТ 1: Сетка с иконками ===== */
.tech-grid-v1 {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0.75rem;
}

.tech-block-v1 {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 0.75rem 0.5rem;
    background: rgba(255,255,255,0.03);
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,0.05);
    transition: all 0.3s ease;
}

.tech-block-v1:hover {
    background: rgba(255,255,255,0.08);
    border-color: var(--terracotta);
    transform: translateY(-2px);
}

.tech-block-icon {
    font-size: 1.25rem;
    color: var(--terracotta);
    margin-bottom: 0.4rem;
}

.tech-block-title {
    font-size: 0.7rem;
    color: rgba(255,255,255,0.6);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 0.5rem;
}

.tech-pills-v1 {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.25rem;
}

.tech-pills-v1 span {
    font-size: 0.65rem;
    padding: 0.2rem 0.4rem;
    background: rgba(201, 124, 93, 0.15);
    border: 1px solid rgba(201, 124, 93, 0.3);
    border-radius: 10px;
    color: rgba(255,255,255,0.85);
    white-space: nowrap;
}

.tech-block-standards {
    grid-column: span 1;
}

/* Tablet: 3 + 2 */
@media (max-width: 991px) {
    .tech-grid-v1 {
        grid-template-columns: repeat(3, 1fr);
    }
    .tech-block-standards {
        grid-column: span 3;
    }
    .tech-block-standards .tech-pills-v1 {
        justify-content: center;
    }
}

/* Mobile: 2 + 2 + 1 */
@media (max-width: 576px) {
    .tech-grid-v1 {
        grid-template-columns: repeat(2, 1fr);
    }
    .tech-block-standards {
        grid-column: span 2;
    }
}

/* Эффекты для Варианта 1 */
.tech-block-v1:nth-child(2) {
    border: 2px solid #7cfc00;
    box-shadow: 0 0 15px rgba(124, 252, 0, 0.3);
}

.tech-block-v1:nth-child(3) {
    border: 2px solid var(--terracotta);
    animation: pulseRed 1s ease-in-out infinite;
}

@keyframes pulseRed {
    0%, 100% {
        border-color: var(--terracotta);
        box-shadow: 0 0 10px rgba(201, 124, 93, 0.3);
    }
    50% {
        border-color: #ff3333;
        box-shadow: 0 0 20px rgba(255, 51, 51, 0.5);
    }
}

/* ===== БАНКИНГ СЕКЦИЯ V4 — 4 КАРТОЧКИ + ВЫРОВНЕННЫЙ НИЗ ===== */
.banking-content {
    max-width: 1100px;
    width: 100%;
    position: relative;
}

.banking-v4 {
    position: relative;
    margin-top: 2rem;
}

/* Фоновый пульсирующий банк */
.banking-hub-bg-v4 {
    position: absolute;
    right: -120px;
    top: -60px;
    width: 450px;
    height: 450px;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 0;
    opacity: 0.3;
    pointer-events: none;
}

.hub-core-bg-v4 {
    position: relative;
    z-index: 10;
    width: 200px;
    height: 200px;
    background: linear-gradient(135deg, var(--terracotta), #8b4513);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 100px rgba(201, 124, 93, 0.5);
    animation: hubPulseBgV4 5s ease-in-out infinite;
}

.hub-core-bg-v4 i {
    font-size: 4.5rem;
}

@keyframes hubPulseBgV4 {
    0%, 100% { transform: scale(1); box-shadow: 0 0 100px rgba(201, 124, 93, 0.5); }
    50% { transform: scale(1.1); box-shadow: 0 0 150px rgba(201, 124, 93, 0.7); }
}

.hub-ring-bg-v4 {
    position: absolute;
    border: 3px solid rgba(201, 124, 93, 0.25);
    border-radius: 50%;
    animation: ringExpandBgV4 5s ease-out infinite;
}

.ring-bg-v4-1 { width: 280px; height: 280px; animation-delay: 0s; }
.ring-bg-v4-2 { width: 350px; height: 350px; animation-delay: 1.25s; }
.ring-bg-v4-3 { width: 420px; height: 420px; animation-delay: 2.5s; }
.ring-bg-v4-4 { width: 490px; height: 490px; animation-delay: 3.75s; }

@keyframes ringExpandBgV4 {
    0% { transform: scale(0.6); opacity: 0.5; }
    100% { transform: scale(1.4); opacity: 0; }
}

/* Верхний ряд: 4 карточки */
.banking-top-v4 {
    display: grid;
    grid-template-columns: 3fr 1fr;
    gap: 1.5rem;
    align-items: start;
}

/* Левая часть: 3 карточки + BaaS */
.banking-left-v4 {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* 3 карточки потоков */
.flow-cards-v4 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

/* 3 карточки потоков */
.flow-cards-v4 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.flow-card-v4 {
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 1rem;
    transition: all 0.3s ease;
}

.flow-card-v4:hover {
    border-color: var(--terracotta);
    transform: translateY(-3px);
}

.flow-card-v4:nth-child(2) {
    border-color: rgba(201, 124, 93, 0.4);
}

.flow-icon-v4 {
    font-size: 1.5rem;
    color: var(--terracotta);
    margin-bottom: 0.5rem;
}

.flow-card-v4:nth-child(2) .flow-icon-v4 i {
    animation: gearSpin 4s linear infinite;
}

.flow-card-v4 h3 {
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
    color: var(--text-color);
}

.flow-list-v4 {
    list-style: none;
    padding: 0;
    margin: 0;
}

.flow-list-v4 li {
    font-size: 0.78rem;
    color: rgba(255,255,255,0.7);
    padding: 0.2rem 0;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    line-height: 1.3;
}

.flow-list-v4 li:last-child {
    border-bottom: none;
}

/* BaaS в стиле горизонтальных полос */
.baas-rows-v4 {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 0.75rem;
    flex: 1;
}

.baas-header-v4 {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding-bottom: 0.4rem;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    margin-bottom: 0.2rem;
}

.baas-header-v4 i {
    font-size: 1.1rem;
    color: var(--terracotta);
}

.baas-header-v4 span {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-color);
}

.baas-row-v4 {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.4rem 0.6rem;
    background: rgba(255,255,255,0.03);
    border-radius: 8px;
    border-left: 2px solid var(--terracotta);
}

.baas-row-icon-v4 {
    font-size: 0.9rem;
    color: var(--terracotta);
    width: 20px;
    text-align: center;
    flex-shrink: 0;
}

.baas-row-title-v4 {
    font-size: 0.75rem;
    color: rgba(255,255,255,0.9);
    font-weight: 500;
    min-width: 110px;
    flex-shrink: 0;
}

.baas-row-pills-v4 {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
    flex: 1;
}

.baas-row-pills-v4 span {
    font-size: 0.65rem;
    padding: 0.1rem 0.4rem;
    background: rgba(201, 124, 93, 0.15);
    border-radius: 6px;
    color: rgba(255,255,255,0.85);
}

/* Правая часть: Безопасные сделки (выше) + Управление ликвидностью */
.banking-right-v4 {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    height: 100%;
}

.escrow-card-v4 {
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 1rem;
    transition: all 0.3s ease;
}

.escrow-card-v4:hover {
    border-color: var(--terracotta);
}

.escrow-icon-v4 {
    font-size: 1.5rem;
    color: var(--terracotta);
    margin-bottom: 0.5rem;
}

.escrow-card-v4 h4 {
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
    color: var(--text-color);
}

.escrow-list-v4 {
    list-style: none;
    padding: 0;
    margin: 0;
}

.escrow-list-v4 li {
    font-size: 0.75rem;
    color: rgba(255,255,255,0.7);
    padding: 0.25rem 0;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    line-height: 1.3;
}

.escrow-list-v4 li:last-child {
    border-bottom: none;
}

.escrow-list-v4 li strong {
    color: var(--terracotta);
}

.liquidity-card-v4 {
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 1rem;
    transition: all 0.3s ease;
}

.liquidity-card-v4:hover {
    border-color: var(--terracotta);
}

.liquidity-icon-v4 {
    font-size: 1.5rem;
    color: var(--terracotta);
    margin-bottom: 0.5rem;
}

.liquidity-card-v4 h4 {
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
    color: var(--text-color);
}

.liquidity-list-v4 {
    list-style: none;
    padding: 0;
    margin: 0;
}

.liquidity-list-v4 li {
    font-size: 0.75rem;
    color: rgba(255,255,255,0.7);
    padding: 0.25rem 0;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    line-height: 1.3;
}

.liquidity-list-v4 li:last-child {
    border-bottom: none;
}

.liquidity-list-v4 li strong {
    color: var(--terracotta);
}

/* Compliance под всеми */
.compliance-v4 {
    margin-top: 1.5rem;
    background: rgba(201, 124, 93, 0.08);
    border: 1px solid rgba(201, 124, 93, 0.2);
    border-radius: 12px;
    padding: 1.25rem;
}

.compliance-label-v4 {
    font-size: 1rem;
    color: var(--text-color);
    font-weight: 500;
    margin-bottom: 1rem;
    display: block;
}

.compliance-content-v4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

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

.compliance-subtitle {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.5);
    font-weight: 500;
}

.compliance-tags-v4 {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.compliance-tags-v4 span {
    font-size: 0.75rem;
    padding: 0.2rem 0.5rem;
    background: rgba(201, 124, 93, 0.15);
    border: 1px solid rgba(201, 124, 93, 0.25);
    border-radius: 12px;
    color: rgba(255,255,255,0.9);
}

/* Левая колонка с карточками */
.banking-left-v3 {
    display: flex;
    flex-direction: column;
}

/* Карточки потоков */
.flow-cards-v3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.flow-card-v3 {
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 1rem;
    transition: all 0.3s ease;
}

.flow-card-v3:hover {
    border-color: var(--terracotta);
    transform: translateY(-3px);
}

.flow-card-v3:nth-child(2) {
    border-color: rgba(201, 124, 93, 0.4);
}

.flow-icon-v3 {
    font-size: 1.5rem;
    color: var(--terracotta);
    margin-bottom: 0.5rem;
}

.flow-card-v3:nth-child(2) .flow-icon-v3 i {
    animation: gearSpin 4s linear infinite;
}

.flow-card-v3 h3 {
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
    color: var(--text-color);
}

.flow-list-v3 {
    list-style: none;
    padding: 0;
    margin: 0;
}

.flow-list-v3 li {
    font-size: 0.78rem;
    color: rgba(255,255,255,0.7);
    padding: 0.2rem 0;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    line-height: 1.3;
}

.flow-list-v3 li:last-child {
    border-bottom: none;
}

/* Правая колонка — вертикальные карточки */
.banking-right-v3 {
    display: flex;
    flex-direction: column;
}

.vertical-cards-v3 {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    height: 100%;
}

.v-card-v3 {
    flex: 1;
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
}

.v-card-v3:hover {
    border-color: var(--terracotta);
}

.v-icon-v3 {
    font-size: 1.75rem;
    color: var(--terracotta);
    margin-bottom: 0.75rem;
}

.v-card-v3 h4 {
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
    color: var(--text-color);
}

.v-card-v3 p {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.65);
    line-height: 1.4;
    flex: 1;
}

/* Нижний ряд — выровненный */
.banking-bottom-v3 {
    position: relative;
    z-index: 1;
    margin-top: 1.5rem;
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 1.5rem;
    align-items: stretch;
}

/* BaaS карточка расширенная */
.baas-card-v3 {
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
}

.baas-header-v3 {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.baas-icon-v3 {
    font-size: 1.75rem;
    color: var(--terracotta);
}

.baas-header-v3 h3 {
    font-size: 1.1rem;
    color: var(--text-color);
}

.baas-grid-v3 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    flex: 1;
}

.baas-item {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.8rem;
    color: rgba(255,255,255,0.75);
    line-height: 1.3;
}

.baas-item i {
    color: var(--terracotta);
    font-size: 0.9rem;
    margin-top: 0.15rem;
    flex-shrink: 0;
}

.baas-item strong {
    color: var(--terracotta);
}

/* Compliance */
.compliance-v3 {
    background: rgba(201, 124, 93, 0.08);
    border: 1px solid rgba(201, 124, 93, 0.2);
    border-radius: 12px;
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.compliance-label-v3 {
    font-size: 0.9rem;
    color: rgba(255,255,255,0.6);
    font-weight: 500;
}

.compliance-tags-v3 {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.compliance-tags-v3 span {
    font-size: 0.75rem;
    padding: 0.2rem 0.6rem;
    background: rgba(201, 124, 93, 0.15);
    border: 1px solid rgba(201, 124, 93, 0.25);
    border-radius: 15px;
    color: rgba(255,255,255,0.9);
}

/* Старые стили — удалить */
.banking-hub-compact {
    position: relative;
    width: 160px;
    height: 160px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

.hub-core {
    position: relative;
    z-index: 10;
    width: 85px;
    height: 85px;
    background: linear-gradient(135deg, var(--terracotta), #8b4513);
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 40px rgba(201, 124, 93, 0.4);
}

.hub-core i {
    font-size: 1.75rem;
    margin-bottom: 0.15rem;
}

.hub-core span {
    font-size: 0.65rem;
    font-weight: bold;
    letter-spacing: 1px;
}

.ring-1 { width: 120px; height: 120px; animation-delay: 0s; }
.ring-2 { width: 145px; height: 145px; animation-delay: 1.5s; }

@keyframes hubPulse {
    0%, 100% { transform: scale(1); box-shadow: 0 0 40px rgba(201, 124, 93, 0.4); }
    50% { transform: scale(1.05); box-shadow: 0 0 60px rgba(201, 124, 93, 0.6); }
}

.hub-ring {
    position: absolute;
    border: 2px solid rgba(201, 124, 93, 0.3);
    border-radius: 50%;
    animation: ringExpand 3s ease-out infinite;
}

@keyframes ringExpand {
    0% { transform: scale(0.8); opacity: 0.8; }
    100% { transform: scale(1.2); opacity: 0; }
}

/* Платежные потоки */
.flow-cards {
    grid-area: flows;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.flow-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 1rem 1.25rem;
    transition: all 0.3s ease;
}

.flow-card:hover {
    border-color: var(--terracotta);
}

.flow-arrow {
    position: relative;
    width: 50px;
    height: 50px;
    background: rgba(201, 124, 93, 0.15);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    color: var(--terracotta);
    overflow: hidden;
}

.flow-particles {
    position: absolute;
    inset: 0;
    background: radial-gradient(circle, rgba(201, 124, 93, 0.3) 0%, transparent 70%);
}

/* Анимация только для центрального узла */
.hub-core {
    animation: hubPulse 3s ease-in-out infinite;
}

/* Компактные карточки потоков */
.flow-cards-compact {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.flow-card-compact {
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 1rem;
    text-align: center;
    transition: all 0.3s ease;
}

.flow-card-compact:hover {
    border-color: var(--terracotta);
    transform: translateY(-3px);
}

.flow-card-compact:nth-child(2) {
    border-color: rgba(201, 124, 93, 0.5);
}

.flow-icon-compact {
    font-size: 1.5rem;
    color: var(--terracotta);
    margin-bottom: 0.5rem;
}

.flow-card-compact:nth-child(2) .flow-icon-compact i {
    animation: gearSpin 4s linear infinite;
}

@keyframes gearSpin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.flow-card-compact h3 {
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
    color: var(--text-color);
}

.flow-list {
    list-style: none;
    padding: 0;
    margin: 0;
    text-align: left;
}

.flow-list li {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.7);
    padding: 0.2rem 0;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.flow-list li:last-child {
    border-bottom: none;
}

/* BaaS карточка на всю ширину */
.baas-card-full {
    display: flex;
    align-items: flex-start;
    gap: 1.25rem;
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 1.25rem;
}

.baas-icon-compact {
    font-size: 2.5rem;
    color: var(--terracotta);
    flex-shrink: 0;
}

.baas-content h3 {
    font-size: 1.1rem;
    margin-bottom: 0.75rem;
    color: var(--text-color);
}

.baas-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem 1.5rem;
}

.baas-list li {
    font-size: 0.85rem;
    color: rgba(255,255,255,0.75);
    line-height: 1.4;
}

.baas-list li strong {
    color: var(--terracotta);
}

/* Compliance на всю ширину */
.compliance-fullwidth {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    background: rgba(201, 124, 93, 0.08);
    border: 1px solid rgba(201, 124, 93, 0.2);
    border-radius: 12px;
    padding: 1rem 1.5rem;
}

.compliance-label {
    font-size: 0.9rem;
    color: rgba(255,255,255,0.6);
    font-weight: 500;
    white-space: nowrap;
}

.compliance-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.compliance-tags span {
    font-size: 0.8rem;
    padding: 0.3rem 0.75rem;
    background: rgba(201, 124, 93, 0.15);
    border: 1px solid rgba(201, 124, 93, 0.25);
    border-radius: 20px;
    color: rgba(255,255,255,0.9);
}

.flow-content {
    flex: 1;
}

.flow-icon {
    font-size: 1.25rem;
    color: var(--terracotta);
    margin-bottom: 0.25rem;
}

.flow-content h3 {
    font-size: 1rem;
    margin-bottom: 0.5rem;
    color: var(--text-color);
}

.flow-content ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.flow-content li {
    font-size: 0.85rem;
    color: rgba(255,255,255,0.7);
    padding: 0.15rem 0;
}

/* BaaS карточка */
.baas-sidebar {
    grid-area: baas;
}

.baas-card {
    position: relative;
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 1.5rem;
    overflow: hidden;
}

/* Убрано вращение — статичный градиент */
.baas-glow {
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: conic-gradient(from 45deg, transparent, rgba(201, 124, 93, 0.3), transparent 50%);
    opacity: 0.2;
}

/* Убрана анимация вращения */

.baas-card > * {
    position: relative;
    z-index: 1;
}

.baas-icon {
    font-size: 2rem;
    color: var(--terracotta);
    margin-bottom: 1rem;
}

.baas-card h3 {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    color: var(--text-color);
}

.baas-card p {
    font-size: 0.85rem;
    color: rgba(255,255,255,0.7);
    padding: 0.3rem 0;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.baas-api {
    margin-top: 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.baas-api > span {
    font-size: 0.8rem;
    font-weight: bold;
    color: var(--terracotta);
    padding: 0.25rem 0.75rem;
    background: rgba(201, 124, 93, 0.15);
    border-radius: 6px;
}

.api-dots {
    display: flex;
    gap: 0.25rem;
}

.api-dots span {
    width: 6px;
    height: 6px;
    background: var(--terracotta);
    border-radius: 50%;
}

.api-dots span:nth-child(2) { animation-delay: 0.2s; }
.api-dots span:nth-child(3) { animation-delay: 0.4s; }

/* Убрана анимация точек API */

/* Tablet */
@media (max-width: 991px) {
    .banking-top-v4 {
        grid-template-columns: 1fr;
    }
    
    .banking-right-v4 {
        flex-direction: row;
    }
    
    .escrow-card-v4,
    .liquidity-card-v4 {
        flex: 1;
    }
    
    .baas-grid-v4 {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .compliance-content-v4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Mobile */
@media (max-width: 576px) {
    .flow-cards-v4 {
        grid-template-columns: 1fr;
    }
    
    .banking-right-v4 {
        flex-direction: column;
    }
    
    .baas-grid-v4 {
        grid-template-columns: 1fr;
    }
    
    .compliance-content-v4 {
        grid-template-columns: 1fr;
    }
}

/* ===== ЭФФЕКТ МАТРИЦЫ ДЛЯ ТЕХНОЛОГИЙ ===== */
.matrix-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
    opacity: 0.15;
}

/* Световые шары под матрицей */
.matrix-glow-balls {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.glow-ball {
    position: absolute;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(201, 124, 93, 0.4) 0%, rgba(201, 124, 93, 0.1) 40%, transparent 70%);
    filter: blur(60px);
    animation: glowBallPulse 8s ease-in-out infinite;
}

.ball-1 {
    width: 400px;
    height: 400px;
    top: 10%;
    left: 10%;
    animation-delay: 0s;
}

.ball-2 {
    width: 300px;
    height: 300px;
    top: 50%;
    right: 15%;
    animation-delay: 2.5s;
}

.ball-3 {
    width: 350px;
    height: 350px;
    bottom: 10%;
    left: 40%;
    animation-delay: 5s;
}

@keyframes glowBallPulse {
    0%, 100% {
        transform: scale(1);
        opacity: 0.6;
    }
    50% {
        transform: scale(1.2);
        opacity: 0.9;
    }
}

/* ===== ЛЕТЯЩИЕ ЗВЁЗДЫ НА ФОНЕ БАНКИНГА ===== */
.shooting-stars-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 6;
    overflow: hidden;
}

/* Метеор с яркой головой и тусклеющим следом позади */
.meteor {
    position: absolute;
    width: 6px;
    height: 6px;
    top: var(--top);
    left: -400px;
    animation: meteorFall 3s linear infinite;
    animation-delay: var(--delay);
}

/* Яркая голова метеора (спереди) */
.meteor::before {
    content: '';
    position: absolute;
    width: 6px;
    height: 6px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.9) 0%, rgba(201, 124, 93, 0.8) 50%, transparent 100%);
    border-radius: 50%;
    box-shadow: 0 0 10px rgba(201, 124, 93, 0.8), 0 0 20px rgba(201, 124, 93, 0.4);
    left: 0;
    top: 0;
}

/* Тусклеющий след позади точки */
.meteor::after {
    content: '';
    position: absolute;
    width: 250px;
    height: 2px;
    background: linear-gradient(90deg, rgba(255, 200, 150, 0.4) 0%, rgba(201, 124, 93, 0.2) 30%, rgba(201, 124, 93, 0.05) 70%, transparent 100%);
    right: 6px;
    top: 2px;
    filter: blur(0.5px);
}

@keyframes meteorFall {
    0% {
        left: -400px;
        top: var(--top);
        opacity: 0;
    }
    5% {
        opacity: 1;
    }
    95% {
        opacity: 1;
    }
    100% {
        left: calc(100% + 100px);
        top: calc(var(--top) + 150px);
        opacity: 0;
    }
}

/* Улучшенные пульсирующие частицы - единый стиль для Banking и Projects */
#particlesBanking .particle,
#particlesProjects .particle {
    width: 5px;
    height: 5px;
    background: rgba(201, 124, 93, 0.8);
    border-radius: 50%;
    box-shadow: 0 0 20px 5px rgba(201, 124, 93, 0.5);
    filter: blur(1px);
}

.security-tag {
    background: rgba(201, 124, 93, 0.2);
    border: 1px solid var(--terracotta);
    border-radius: 20px;
    padding: 0.3rem 0.8rem;
    font-size: 0.8rem;
    color: var(--terracotta);
}

/* Tablet: 2 колонки */
@media (max-width: 991px) {
    .security-grid {
        grid-template-columns: 1fr 1fr;
        grid-template-rows: auto;
    }
    
    .security-card-large {
        grid-row: span 1;
        grid-column: span 2;
    }
    
    .security-card-wide {
        grid-column: span 2;
    }
}

/* Mobile: 1 колонка */
@media (max-width: 576px) {
    .security-grid {
        grid-template-columns: 1fr;
    }
    
    .security-card-large,
    .security-card-wide {
        grid-column: span 1;
    }
    
    .security-card {
        padding: 1rem;
    }
    
    .security-card h3 {
        font-size: 1rem;
    }
    
    .security-solution {
        font-size: 0.85rem;
    }
}

/* ===== QR-КОД С КАСТОМНЫМ ДИЗАЙНОМ ===== */
.qr-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    margin-top: 2rem;
}

.qr-wrapper {
    position: relative;
    width: 180px;
    height: 180px;
    border-radius: 24px;
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    padding: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.qr-wrapper:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(201, 124, 93, 0.2);
}

#qrCanvas {
    width: 100%;
    height: 100%;
    display: block;
    border: 3px solid var(--terracotta);
    /* Убираем скругление углов у самого QR-кода для чёткости */
}

.qr-logo {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 44px;
    height: 44px;
    background: var(--terracotta);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 16px rgba(201, 124, 93, 0.5);
}

.qr-logo span {
    font-size: 0.45rem;
    font-weight: 700;
    color: white;
    -webkit-text-fill-color: white;
    line-height: 1;
}

.qr-logo .dot {
    color: rgba(255, 255, 255, 0.8);
    -webkit-text-fill-color: rgba(255, 255, 255, 0.8);
}

.qr-label {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.6);
    letter-spacing: 2px;
    font-weight: 500;
}

/* Пульсация QR-кода */
@keyframes qrPulse {
    0%, 100% {
        box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    }
    50% {
        box-shadow: 0 8px 32px rgba(201, 124, 93, 0.25);
    }
}

.qr-wrapper {
    animation: qrPulse 3s ease-in-out infinite;
}

/* Glow эффект при наведении */
.qr-wrapper::before {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: 24px;
    background: linear-gradient(135deg, var(--terracotta), var(--sage-green));
    opacity: 0;
    z-index: -1;
    transition: opacity 0.3s ease;
}

.qr-wrapper:hover::before {
    opacity: 0.3;
}

/* ===== HERO СЕКЦИЯ ===== */
.hero-content {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

#hero-line1 {
    font-size: clamp(2rem, 6vw, 4rem);
    font-weight: 700;
    background: linear-gradient(135deg, var(--terracotta), var(--sage-green));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 1rem;
}

#hero-line2,
#hero-line3 {
    font-size: clamp(1rem, 2.5vw, 1.5rem);
    color: rgba(255, 255, 255, 0.9);
    text-transform: lowercase;
    letter-spacing: 0.05em;
    margin: 0;
}

/* ===== СЕКЦИЯ ПРОЕКТОВ ===== */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.25rem;
    margin-top: 2.5rem;
    width: 100%;
    max-width: 1200px;
}

.project-card {
    position: relative;
    background: rgba(20, 20, 24, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 1.5rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: visible;
    opacity: 1 !important;
    z-index: 1;
}

.project-card:hover {
    z-index: 10;
}

.project-card:hover {
    transform: translateY(-6px) scale(1.02);
    border-color: var(--terracotta);
    box-shadow: 0 12px 40px rgba(201, 124, 93, 0.15);
}

.project-icon {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--terracotta);
    transition: transform 0.3s ease;
}

.project-card:hover .project-icon {
    transform: scale(1.1) rotate(5deg);
}

.project-icon svg {
    width: 1.5em;
    height: 1.5em;
    display: inline-block;
    vertical-align: middle;
    fill: currentColor;
}

.project-card h3 {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 0.5rem;
    line-height: 1.3;
}

.project-card p {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.6);
    line-height: 1.4;
    margin: 0;
}

/* Бабл с деталями проекта - ДЕСКТОП (сбоку) */
.project-bubble {
    position: absolute;
    top: 50%;
    left: calc(100% + 12px);
    transform: translateY(-50%) scale(0.9);
    width: 260px;
    background: rgba(20, 20, 24, 0.98);
    backdrop-filter: blur(20px);
    border: 1px solid var(--terracotta);
    border-radius: 16px;
    padding: 1.25rem;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    pointer-events: none;
}

/* Для карточек в правой колонке - бабл слева */
.project-card:nth-child(4n) .project-bubble,
.project-card:nth-child(4n-1) .project-bubble {
    left: auto;
    right: calc(100% + 12px);
}

.project-card:hover .project-bubble,
.project-bubble.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(-50%) scale(1);
}

/* Стрелка бабла - слева */
.project-bubble::after {
    content: '';
    position: absolute;
    top: 50%;
    left: -16px;
    transform: translateY(-50%);
    border: 8px solid transparent;
    border-right-color: var(--terracotta);
}

/* Стрелка для правых карточек - справа */
.project-card:nth-child(4n) .project-bubble::after,
.project-card:nth-child(4n-1) .project-bubble::after {
    left: auto;
    right: -16px;
    border-right-color: transparent;
    border-left-color: var(--terracotta);
}

.project-bubble h4 {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--terracotta);
    margin-bottom: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.project-bubble-section {
    margin-bottom: 0.75rem;
}

.project-bubble-section:last-child {
    margin-bottom: 0;
}

.project-bubble-section h5 {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--sage-green);
    margin-bottom: 0.25rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.project-bubble-section p {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.4;
    margin: 0;
}

/* Адаптивность проектов */
@media (max-width: 1200px) {
    .projects-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .projects-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }
    
    /* Бабл для мобильных - внизу карточки (по умолчанию) */
    .project-bubble {
        position: absolute;
        top: calc(100% + 12px);
        left: 50%;
        right: auto;
        transform: translateX(-50%) scale(0.9);
        width: 280px;
    }
    
    /* Сброс позиционирования для всех карточек */
    .project-card:nth-child(4n) .project-bubble,
    .project-card:nth-child(4n-1) .project-bubble {
        left: 50%;
        right: auto;
    }
    
    .project-card:hover .project-bubble,
    .project-bubble.active {
        transform: translateX(-50%) scale(1);
    }
    
    /* Стрелка вверх для мобильных (по умолчанию) */
    .project-bubble::after {
        top: -16px;
        left: 50%;
        right: auto;
        transform: translateX(-50%);
        border: 8px solid transparent;
        border-bottom-color: var(--terracotta);
        border-right-color: transparent;
        border-left-color: transparent;
    }
    
    /* Сброс стрелок для правых карточек */
    .project-card:nth-child(4n) .project-bubble::after,
    .project-card:nth-child(4n-1) .project-bubble::after {
        left: 50%;
        right: auto;
        border-right-color: transparent;
        border-left-color: transparent;
        border-bottom-color: var(--terracotta);
    }
    
    /* Нижние две карточки (15 и 16) - бабл открывается вверх */
    .project-card:nth-child(15) .project-bubble,
    .project-card:nth-child(16) .project-bubble {
        top: auto;
        bottom: calc(100% + 12px);
        transform: translateX(-50%) scale(0.9);
    }
    
    .project-card:nth-child(15):hover .project-bubble,
    .project-card:nth-child(15) .project-bubble.active,
    .project-card:nth-child(16):hover .project-bubble,
    .project-card:nth-child(16) .project-bubble.active {
        transform: translateX(-50%) scale(1);
    }
    
    /* Стрелка вниз для нижних карточек */
    .project-card:nth-child(15) .project-bubble::after,
    .project-card:nth-child(16) .project-bubble::after {
        top: auto;
        bottom: -16px;
        border: 8px solid transparent;
        border-top-color: var(--terracotta);
        border-bottom-color: transparent;
    }
}

@media (max-width: 480px) {
    .projects-grid {
        grid-template-columns: 1fr;
    }
}

/* ===== ЭФФЕКТ БИТЫХ ПИКСЕЛЕЙ ДЛЯ FOOTER ===== */
.dead-pixels-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
    overflow: hidden;
}

.dead-pixel {
    position: absolute;
    width: 2px;
    height: 2px;
    background: rgba(201, 124, 93, 0.6);
    border-radius: 0;
    opacity: 0;
    animation: deadPixelFlicker 4s ease-in-out infinite;
}

@keyframes deadPixelFlicker {
    0%, 100% {
        opacity: 0;
        transform: scale(0.5);
    }
    10% {
        opacity: 0.8;
        transform: scale(1);
    }
    20% {
        opacity: 0.3;
    }
    30% {
        opacity: 0.9;
    }
    40% {
        opacity: 0.2;
    }
    50% {
        opacity: 0.7;
    }
    60% {
        opacity: 0.1;
    }
    70% {
        opacity: 0.6;
    }
    80% {
        opacity: 0.4;
    }
    90% {
        opacity: 0.8;
    }
}

