        @import url('https://fonts.googleapis.com/css2?family=Press+Start+2P&display=swap');

    * {
        box-sizing: border-box;
    }
    
    html, body {
        background: #000000 !important;
        color: #00ff00;
        font-family: 'IBM Plex Mono', 'Share Tech Mono', monospace;
        font-weight: 700;
        margin: 0;
        padding: 0;
        min-height: 100%;
        overflow-y: auto;
    }
    
    .slide-container {
        width: 100%;
        max-width: 1280px;
        min-height: 100vh;
        margin: 0 auto;
        position: relative;
        background: #000000;
        overflow-y: auto;
    }
    
    .terminal-border {
        border: 2px solid #00ff00;
        box-shadow: 0 0 3px rgba(0, 255, 0, 0.4), 
                    0 0 6px rgba(0, 255, 0, 0.3),
                    0 0 9px rgba(0, 255, 0, 0.2);
        animation: borderPulse 3s ease-in-out infinite;
    }
    
    @keyframes borderPulse {
        0%, 100% { 
            border-color: #00ff00;
            box-shadow: 0 0 3px rgba(0, 255, 0, 0.4), 
                       0 0 6px rgba(0, 255, 0, 0.3),
                       0 0 9px rgba(0, 255, 0, 0.2);
        }
        50% { 
            border-color: #33ff33;
            box-shadow: 0 0 5px rgba(0, 255, 0, 0.6), 
                       0 0 10px rgba(0, 255, 0, 0.4),
                       0 0 15px rgba(0, 255, 0, 0.3);
        }
    }
    
    /* Убираем свечение с верхней плашки */
    .glow-text {
        /* text-shadow: 0 0 2px #00ff00, 0 0 4px #00ff00, 0 0 6px #00ff00; */
        /* animation: pixelGlow 2s ease-in-out infinite alternate; */
    }
    
    .pixel-text {
        font-family: 'Share Tech Mono', monospace;  /* Тонкий шрифт */
        image-rendering: pixelated;
        color: #ffffff;
        font-weight: 300;  /* Тонкий */
    }
    
    .pixel-text-title {
        font-family: 'Press Start 2P', cursive;
        color: #ffffff;
        font-size: 48px;
        letter-spacing: 4px;
        text-shadow: 0 0 4px rgba(255, 255, 255, 0.8), 
                     0 0 8px rgba(0, 255, 0, 0.6), 
                     0 0 16px rgba(0, 255, 0, 0.4),
                     0 0 24px rgba(0, 255, 0, 0.2);
        text-transform: uppercase;
        image-rendering: pixelated;
        animation: titlePulse 3s ease-in-out infinite;
    }
    
    @keyframes titlePulse {
        0%, 100% { 
            text-shadow: 0 0 4px rgba(255, 255, 255, 0.8), 
                        0 0 8px rgba(0, 255, 0, 0.6), 
                        0 0 16px rgba(0, 255, 0, 0.4),
                        0 0 24px rgba(0, 255, 0, 0.2);
        }
        50% { 
            text-shadow: 0 0 6px rgba(255, 255, 255, 1), 
                        0 0 12px rgba(0, 255, 0, 0.8), 
                        0 0 24px rgba(0, 255, 0, 0.6),
                        0 0 36px rgba(0, 255, 0, 0.4);
        }
    }
    
.pixel-text-sm {
    font-family: 'Share Tech Mono', monospace;
    color: #00ff00;
    font-size: 12px;
    letter-spacing: 1px;
}

.symbol-strip {
    font-family: 'Share Tech Mono', monospace;
    color: #00ff00;
    text-shadow: 0 0 4px #0f0, 0 0 6px #0f0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: inline-block;
    max-width: 100%;
}

    .logo-subtitle {
        font-family: 'IBM Plex Mono', 'Share Tech Mono', monospace;
        font-weight: 700;
        color: #00ff00;
        font-size: 14px;
        text-shadow: 0 0 2px #00ff00, 0 0 4px #00ff00;
    }

    #titleContainer {
        margin-top: 2rem;
    }
    
    .pixel-text-xs {
        font-family: 'IBM Plex Mono', 'Share Tech Mono', monospace;
        font-weight: 700;
        color: #66ff66;
        font-size: 10px;
        text-shadow: 0 0 2px rgba(102, 255, 102, 0.8), 
                     0 0 4px rgba(102, 255, 102, 0.6),
                     0 0 6px rgba(102, 255, 102, 0.4);
        animation: subtlePulse 4s ease-in-out infinite;
    }
    
    @keyframes subtlePulse {
        0%, 100% { 
            text-shadow: 0 0 2px rgba(102, 255, 102, 0.8), 
                        0 0 4px rgba(102, 255, 102, 0.6),
                        0 0 6px rgba(102, 255, 102, 0.4);
        }
        50% { 
            text-shadow: 0 0 3px rgba(102, 255, 102, 1), 
                        0 0 6px rgba(102, 255, 102, 0.8),
                        0 0 9px rgba(102, 255, 102, 0.6);
        }
    }
    
    .scanlines {
        background: linear-gradient(transparent 50%, rgba(0, 255, 0, 0.03) 50%);
        background-size: 100% 4px;
        animation: scanlines 0.1s linear infinite;
    }
    
    @keyframes scanlines {
        0% { background-position: 0 0; }
        100% { background-position: 0 4px; }
    }
    
    @keyframes blink {
        0%, 50% { opacity: 1; }
        51%, 100% { opacity: 0; }
    }
    
    .blink {
        animation: blink 1s infinite;
    }
    
    /* Зеленые квадратные метеоры с шлейфом */
    .matrix-char {
        position: absolute;
        width: 2px;
        height: 2px;
        background: #00ff00;
        animation: meteorFall 6s linear infinite;
        opacity: 0.9;
        box-shadow: 0 0 1px #00ff00, 
                    0 0 2px #00ff00;
    }
    
    .matrix-char::before {
        content: '';
        position: absolute;
        width: 1px;
        height: 8px;
        background: linear-gradient(to bottom, #00ff00, transparent);
        left: 0.5px;
        top: -8px;
        opacity: 0.6;
    }
    
    @keyframes meteorFall {
        0% { 
            transform: translateY(-100vh) translateX(-40px) rotate(25deg); 
            opacity: 0;
        }
        5% { opacity: 0.9; }
        95% { opacity: 0.8; }
        100% { 
            transform: translateY(100vh) translateX(40px) rotate(25deg); 
            opacity: 0;
        }
    }
    
    .logo-container {
        background: #000000;
        border: 2px solid #00ff00;
        /* Pixelated halo using layered square shadows */
        box-shadow:
            0 0 0 2px #00FF00,
            0 0 0 4px #00CC00,
            0 0 0 6px #009900;
    }
    
    .enlarged-logo {
        max-width: 100%;
        max-height: 100%;
        object-fit: contain;
        filter: drop-shadow(0 0 8px rgba(0, 255, 0, 0.4));
        image-rendering: pixelated;
    }
    
    .console-button {
        background: #000000;
        border: 3px solid #00ff00;
        color: #ffffff;
        padding: 12px 24px;
        text-decoration: none;
        display: inline-block;
        transition: all 0.2s ease;
        position: relative;
        overflow: hidden;
        font-family: 'Share Tech Mono', monospace;
        font-size: 14px;
        font-weight: 300;
        letter-spacing: 2px;
        box-shadow: 0 0 4px rgba(0, 255, 0, 0.6), 
                    0 0 8px rgba(0, 255, 0, 0.4),
                    0 0 12px rgba(0, 255, 0, 0.2);
        text-shadow: 0 0 2px #ffffff, 0 0 4px #ffffff;
        animation: buttonGlow 2.5s ease-in-out infinite alternate;
    }
    
    @keyframes buttonGlow {
        0% { 
            box-shadow: 0 0 4px rgba(0, 255, 0, 0.6), 
                       0 0 8px rgba(0, 255, 0, 0.4),
                       0 0 12px rgba(0, 255, 0, 0.2);
            border-color: #00ff00;
        }
        100% { 
            box-shadow: 0 0 6px rgba(0, 255, 0, 0.8), 
                       0 0 12px rgba(0, 255, 0, 0.6),
                       0 0 18px rgba(0, 255, 0, 0.4);
            border-color: #44ff44;
        }
    }
    
    .console-button:hover {
        background: #001100;
        color: #00ff00;
        box-shadow: 0 0 8px rgba(0, 255, 0, 1), 
                    0 0 16px rgba(0, 255, 0, 0.8),
                    0 0 24px rgba(0, 255, 0, 0.6);
        text-shadow: 0 0 3px #00ff00, 0 0 6px #00ff00;
    }
    
    .console-button:active {
        background: #002200;
        transform: scale(0.95);
    }
    
    .pixel-particle {
        position: fixed;
        width: 2px;
        height: 2px;
        background: #00ff00;
        pointer-events: none;
        z-index: 10000;
        box-shadow: 0 0 2px #00ff00;
    }

    .social-spark {
        position: fixed;
        width: 2px;
        height: 2px;
        background: #FFA500;
        box-shadow: 0 0 2px #FFA500;
        pointer-events: none;
        z-index: 1001;
        opacity: 0.9;
        animation: sparkBurst 1.2s ease-out forwards;
    }

    @keyframes sparkBurst {
        0% { transform: translate(0,0); opacity: 1; }
        100% { transform: translate(var(--dx), var(--dy)); opacity: 0; }
    }
    
    @keyframes pixelExplode {
        0% {
            transform: translate(0, 0) scale(1);
            opacity: 1;
        }
        100% {
            transform: translate(var(--dx), var(--dy)) scale(0);
            opacity: 0;
        }
    }
    
    /* Светлячки, летящие от кнопок вверх */
    .button-firefly {
        position: fixed;
        width: 3px;
        height: 3px;
        background: #00ff00;
        pointer-events: none;
        z-index: 1002;
        box-shadow: 0 0 3px #00ff00, 
                    0 0 6px #00ff00,
                    0 1px 0 rgba(0, 255, 0, 0.4),
                    1px 0 0 rgba(0, 255, 0, 0.4),
                    0 -1px 0 rgba(0, 255, 0, 0.4),
                    -1px 0 0 rgba(0, 255, 0, 0.4);
        animation: fireflyGlow 1.5s ease-in-out infinite;
    }
    
    @keyframes fireflyUpward {
        0% {
            transform: translate(0, 0) scale(1);
            opacity: 1;
        }
        100% {
            transform: translate(var(--dx), var(--dy)) scale(0.3);
            opacity: 0;
        }
    }
    
    
    /* Floating pixel elements */
    .floating-pixels {
        position: absolute;
        width: 2px;
        height: 2px;
        background: #00ff00;
        opacity: 0.7;
        pointer-events: none;
        z-index: 997;
        animation: pixelFloat 8s ease-in-out infinite;
    }
    
    @keyframes pixelFloat {
        0%, 100% {
            transform: translateY(0px) translateX(0px);
            opacity: 0.7;
        }
        25% {
            transform: translateY(-20px) translateX(10px);
            opacity: 1;
        }
        50% {
            transform: translateY(-10px) translateX(-15px);
            opacity: 0.8;
        }
        75% {
            transform: translateY(-30px) translateX(5px);
            opacity: 0.9;
        }
    }
    
    /* Зеленые квадратные светлячки */
    .firefly {
        position: absolute;
        width: 2px;
        height: 2px;
        background: #00ff00;
        box-shadow: 0 0 2px #00ff00, 
                    0 0 4px #00ff00,
                    0 1px 0 rgba(0, 255, 0, 0.4),
                    1px 0 0 rgba(0, 255, 0, 0.4),
                    0 -1px 0 rgba(0, 255, 0, 0.4),
                    -1px 0 0 rgba(0, 255, 0, 0.4);
        opacity: 0;
        pointer-events: none;
        z-index: 998;
    }
    
    @keyframes fireflyFloat {
        0% {
            transform: translate(0, 0);
            opacity: 0;
        }
        10% {
            opacity: 1;
        }
        90% {
            opacity: 1;
        }
        100% {
            transform: translate(var(--fly-x), var(--fly-y));
            opacity: 0;
        }
    }
    
    /* Scrolling text horizon effect */
    .scrolling-text {
        position: absolute;
        bottom: 0;
        left: 0;
        right: 0;
        height: 200px;
        overflow: hidden;
        pointer-events: none;
        z-index: 1;
    }
    
    .scroll-line {
        position: absolute;
        width: 200%;
        white-space: nowrap;
        font-family: 'Press Start 2P', cursive;
        font-size: 12px;
        color: #00ff00;
        opacity: 0.3;
        animation: scrollHorizontal 10s linear infinite;
    }
    
    @keyframes scrollHorizontal {
        0% { transform: translateX(100%); }
        100% { transform: translateX(-100%); }
    }
    
    @keyframes fireflyGlow {
        0%, 100% {
            box-shadow: 0 0 2px #00ff00, 0 0 4px #00ff00;
            background: #00ff00;
        }
        50% {
            box-shadow: 0 0 4px #00ff00, 0 0 8px #00ff00, 0 0 12px #44ff44;
            background: #44ff44;
        }
    }

    
    /* Мобильная адаптация */
    @media (max-width: 768px) {
        .pixel-text-title {
            font-size: 28px;
            letter-spacing: 2px;
            margin-bottom: 1.5rem;
        }
        
        .console-button {
            padding: 16px 32px;
            font-size: 16px;
            margin-bottom: 16px;
            min-height: 50px;
            touch-action: manipulation;
        }
        
        .enlarged-logo {
            transform: none;
        }
        
        .w-48 {
            width: 10rem;
        }
        
        .h-48 {
            height: 10rem;
        }
        
        
        .terminal-border {
            margin: 0.75rem;
        }
        
        .p-4 {
            padding: 1rem;
        }
        
        .gap-6 {
            gap: 1rem;
        }
        
        .mb-8 {
            margin-bottom: 1.5rem;
        }
        
        .mb-12 {
            margin-bottom: 2rem;
        }
        
        .space-x-8 > * + * {
            margin-left: 1rem;
        }
        
        .lg\:w-3\/4 {
            width: 100%;
        }
        
        .lg\:w-1\/4 {
            width: 100%;
            margin-top: 1rem;
        }
        
        .pixel-text-xs {
            font-size: 9px;
        }
        
        .scroll-line {
            font-size: 8px;
        }
        
        /* Терминальная загрузка на мобилке */
        #terminal-loading {
            padding: 1rem;
        }
        
        #terminal-loading div[style*="font-size: 32px"] {
            font-size: 24px !important;
        }
        
        #terminal-output {
            font-size: 10px !important;
            height: 150px !important;
        }

    }
    
    @media (max-width: 480px) {
        .pixel-text-title {
            font-size: 24px;
            letter-spacing: 1px;
        }
        
        .console-button {
            padding: 14px 28px;
            font-size: 14px;
            width: 100%;
            max-width: 200px;
        }
        
        .enlarged-logo {
            transform: none;
        }
        
        .w-48 {
            width: 8rem;
        }
        
        .h-48 {
            height: 8rem;
        }
        
        .grid-cols-4 {
            grid-template-columns: repeat(4, minmax(0, 1fr));
            gap: 0.5rem;
        }
        
        .max-w-xs {
            max-width: 16rem;
        }
        
        .terminal-border {
            margin: 0.5rem;
            padding: 0.5rem;
        }
        
        .text-xs {
            font-size: 0.65rem;
        }
        
        #terminal-loading div[style*="font-size: 24px"] {
            font-size: 20px !important;
        }
    }

    /* SOCIAL container position */
    #socialContainer {
        position: fixed;
        bottom: 20px;
        right: 20px;
        z-index: 9998;
    }

    @media (max-width: 640px) {
        #socialContainer {
            bottom: 10px;
            right: 10px;
        }
    }

    /* SOCIAL button styling */
    #socialToggle {
        position: relative;
        z-index: 10;
        background-color: black;
        color: #FFA500;
        font-family: monospace;
        font-weight: bold;
        padding: 10px 16px;
        border: 2px dashed #FFA500;
        cursor: pointer;
        box-shadow: none;
        text-shadow: none;
    }

    .terminal-activate {
        animation: none;
    }

    /* Pixel frame glow + random vibration */
    .pxl-frame {
        position: relative;
        z-index: 1;
    }

    .pxl-frame::before,
    .pxl-frame::after,
    .pxl-frame .glow-3 {
        content: "";
        position: absolute;
        pointer-events: none;
        image-rendering: pixelated;
        border: 2px solid;
        border-radius: 0;
        z-index: -1;
        animation: pxl-flicker 2.5s infinite steps(1, end);
    }

    .pxl-frame::before {
        top: -2px; left: -2px; right: -2px; bottom: -2px;
        border-color: rgba(255, 165, 0, 0.70);
        animation-delay: 0s;
    }

    .pxl-frame::after {
        top: -4px; left: -4px; right: -4px; bottom: -4px;
        border-color: rgba(255, 165, 0, 0.40);
        animation-delay: 0.2s;
    }

    .pxl-frame .glow-3 {
        top: -6px; left: -6px; right: -6px; bottom: -6px;
        border-color: rgba(255, 165, 0, 0.20);
        position: absolute;
        animation-delay: 0.4s;
    }

    @keyframes pxl-flicker {
        0%   { opacity: 1;     }
        33%  { opacity: 0.9;   }
        66%  { opacity: 0.95;  }
        100% { opacity: 1;     }
    }

    /* SOCIAL panel styling */
    #socialPanel {
        display: none;
        position: absolute;
        bottom: calc(100% + 10px);
        right: 0;
        background-color: black;
        border: 1px solid #FFA500;
        padding: 12px;
        z-index: 20;
        opacity: 0;
        transform: scale(0.8);
        transform-origin: bottom right;
        transition: all 0.4s ease;
    }

    #socialPanel.visible {
        display: block;
        opacity: 1;
        transform: scale(1);
        animation: terminalExpand 0.5s ease-out forwards;
    }

    #socialPanel a {
        display: block;
        color: #FFA500;
        font-family: monospace;
        text-decoration: none;
        margin-bottom: 8px;
    }

    /* PORTAL panel styling */
    #portalPanel {
        display: none;
        position: fixed;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        width: 300px;
        height: 200px;
        background-color: black;
        border: 2px solid #00ff00;
        font-family: monospace;
        color: #00ff00;
        padding: 20px;
        z-index: 9999;
    }

    /* Flash line when opening manifesto */
    #portalFlash {
        position: fixed;
        top: 50%;
        left: 50%;
        height: 2px;
        background: #00ffff;
        width: 0;
        transform: translate(-50%, -50%);
        pointer-events: none;
        z-index: 10001;
        display: none;
    }

    #portalPanel.visible {
        display: block;
    }

    .visible {
        transform: scale(1);
        opacity: 1;
        transition: transform 0.7s ease, opacity 0.7s ease;
    }


    /* Manifesto overlay panel */
    #manifestoPanel {
        transform-origin: top center;
        position: fixed;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%) scaleY(0);
        background: #000;
        padding: 16px;
        box-sizing: border-box;
        border: 12px solid transparent;
        border-image: repeating-linear-gradient(45deg, #b200ff 0, #b200ff 30px, transparent 30px, transparent 60px) 24;
        font-family: 'IBM Plex Mono', 'Share Tech Mono', monospace;
        font-weight: 700;
        z-index: 10000;
        display: flex;
        justify-content: center;
        align-items: center;
        transition: transform 0.2s ease, opacity 0.2s ease;
        opacity: 0;
        pointer-events: none;
        max-width: calc(100vw - 40px);
        max-height: calc(100vh - 40px);
        overflow: auto;
        /* Улучшенное отображение контента */
        flex-direction: column;
        /* Адаптивные ограничения */
        min-width: auto;
        min-height: auto;
    }

    #manifestoPanel.visible {
        transform: translate(-50%, -50%) scaleY(1);
        opacity: 1;
        pointer-events: auto;
    }



    .manifesto-arrow {
        position: absolute;
        top: 50%;
        font-size: 18px;
        color: #00ff00;
        font-family: 'IBM Plex Mono', 'Share Tech Mono', monospace;
        font-weight: 700;
        transform: translateY(-50%);
        cursor: pointer;
        opacity: 0;
        transition: opacity 0.2s ease;
    }
    .manifesto-arrow-left { left: 18px; }
    .manifesto-arrow-right { right: 50px; }

    .manifesto-close {
        position: absolute;
        top: 8px;
        right: 8px;
        width: 20px;
        height: 20px;
        font-size: 16px;
        line-height: 20px;
        text-align: center;
        background: #1a001a;
        color: #00ff00;
        font-family: 'IBM Plex Mono', 'Share Tech Mono', monospace;
        font-weight: 700;
        cursor: pointer;
        opacity: 0;
        transition: opacity 0.2s ease;
    }

    #manifestoPanel .child-visible {
        opacity: 1;
    }

    .manifesto-close:hover {
        box-shadow: 0 0 4px #b200ff;
    }

    .manifesto-arrow:hover {
        text-shadow: 0 0 4px #00d9ff;
    }

    @keyframes terminalExpand {
        0% { transform: scale(0.8); opacity: 0; }
        100% { transform: scale(1); opacity: 1; }
    }

.ata-glyph-line,
.ata-glyph-square {
    font-family: monospace;
    font-size: 24px;
    color: #00ff00;
    background: #000000;
    display: inline-block;
    padding: 4px 12px;
}
.ata-glyph-line {
    letter-spacing: 8px;
}
.ata-glyph-square {
    line-height: 1.2;
    white-space: pre;
    margin-top: 8px;
}

@keyframes borderPulseBlue {
    0%, 100% {
        border-color: #00d9ff;
        box-shadow: 0 0 3px rgba(0, 217, 255, 0.5),
                    0 0 6px rgba(0, 217, 255, 0.3),
                    0 0 9px rgba(0, 217, 255, 0.2);
    }
    50% {
        border-color: #80eaff;
        box-shadow: 0 0 5px rgba(0, 217, 255, 0.7),
                    0 0 10px rgba(0, 217, 255, 0.5),
                    0 0 15px rgba(0, 217, 255, 0.3);
    }
}


/* Manifesto reveal sequence styles */
.reveal-sequence {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}
.manifesto-loader {
    width: 80%;
    height: 8px;
    border: 1px solid #00ff00;
    background: #002200;
    margin-bottom: 6px;
    overflow: hidden;
}
.manifesto-loader-fill {
    width: 0%;
    height: 100%;
    background: #00ff00;
    transition: width 0.3s linear;
}
.manifesto-loader-text {
    font-family: 'IBM Plex Mono', 'Share Tech Mono', monospace;
    font-weight: 700;
    color: #00ff00;
    font-size: 12px;
    margin-bottom: 4px;
}
.image-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8px;
    box-sizing: border-box;
    /* Улучшенное отображение для десктопа */
    min-height: 0;
    flex: 1;
    /* Адаптивные ограничения */
    overflow: auto;
    max-width: 100%;
    max-height: 100%;
}
#manifestoImage {
    width: auto;
    height: auto;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    display: none;
    margin: auto;
    image-rendering: pixelated;
    box-sizing: border-box;
    /* Улучшенное отображение для десктопа */
    object-position: center;
}
.pixel-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    display: none;
    grid-template-columns: repeat(20, 1fr);
    grid-template-rows: repeat(20, 1fr);
}
.pixel-block {
    background: #000;
    opacity: 1;
    transition: opacity 0.2s linear;
}

#manifestoText {
    display: none;
    white-space: pre-wrap;
    color: #00ff00;
    text-align: justify;
    text-justify: inter-word;
    font-family: 'IBM Plex Mono', 'Share Tech Mono', monospace;
    font-weight: 700;
    max-width: 100%;
    max-height: 100%;
    overflow: auto;
    margin: auto;
    padding: 4px;
    box-sizing: border-box;
    word-break: break-word;
    line-height: 1.2;
}

.crt-char {
    opacity: 0;
    animation: crtBlink 0.2s steps(1) forwards;
}

.crt-cursor {
    display: inline-block;
    color: #00ff00;
    animation: blinkCursor 0.7s steps(1, end) infinite;
}

.manifesto-indicator {
    position: absolute;
    bottom: 8px;
    left: 50%;
    transform: translateX(-50%);
    font-family: 'IBM Plex Mono', 'Share Tech Mono', monospace;
    font-weight: 700;
    color: #00ff00;
    font-size: 12px;
}

@keyframes crtBlink {
    0% { opacity: 0; }
    50% { opacity: 1; }
    100% { opacity: 1; }
}

@keyframes blinkCursor {
    0%, 50% { opacity: 1; }
    50.1%, 100% { opacity: 0; }
}

@media (min-width: 601px) and (max-width: 1024px) {
    /* Slightly larger manifesto panel for tablets */
    #manifestoPanel {
        max-width: calc(100vw - 40px);
        max-height: calc(100vh - 40px);
        margin: auto;
        box-sizing: border-box;
    }
    #manifestoImage {
        width: auto;
        max-width: 90%;
        height: auto;
        display: block;
        margin: auto;
    }
}

@media (orientation: landscape) and (min-width: 768px) and (max-width: 1024px) {
    #manifestoPanel {
        max-width: calc(100vw - 40px);
        max-height: calc(100vh - 40px);
    }
}

@media (max-width: 600px) {
    #manifestoPanel {
        width: 90vw;
        height: 90vh;
        margin: auto;
        box-sizing: border-box;
        overflow: hidden;
    }
    #manifestoImage {
        width: 95%;
        height: auto;
        max-width: none;
        display: block;
        margin: auto;
    }
    #manifestoText {
        font-size: 14px;
        overflow-y: auto;
        width: 95%;
        margin: auto;
    }
}

@media (min-width: 1025px) {
    #manifestoPanel {
        max-width: calc(100vw - 80px);
        max-height: calc(100vh - 80px);
        margin: auto;
        /* Улучшенное позиционирование для десктопа */
        display: flex;
        align-items: center;
        justify-content: center;
        /* Адаптивный overflow */
        overflow: auto;
    }
    #manifestoImage {
        max-width: 90%;
        max-height: 90%;
        width: auto;
        height: auto;
        display: block;
        margin: auto;
        object-fit: contain;
        object-position: center;
        /* Адаптивные ограничения */
        min-width: auto;
        min-height: auto;
    }
}

/* Desktop manual modal adjustments */
@media (min-width: 1024px) {
    .manual-modal {
        position: fixed;
        inset: 0;
        display: grid;
        place-items: center;
        padding: 32px;
    }
    
    /* Дополнительные стили для больших экранов */
    @media (min-width: 1440px) {
        #manifestoPanel {
            max-width: calc(100vw - 100px);
            max-height: calc(100vh - 100px);
        }
        #manifestoImage {
            max-width: 90%;
            max-height: 90%;
        }
    }
        background: rgba(0, 0, 0, .6);
        overflow: auto;
        z-index: 1000;
    }

    .manual-modal * {
        overflow: visible;
    }

    .manual-wrap {
        box-sizing: border-box;
        width: auto !important;
        height: auto !important;
        display: flex;
        align-items: center;
        justify-content: center;
        overflow: visible;
        background-color: #000;
        background-size: contain !important;
        background-position: center;
        background-repeat: no-repeat;
    }

    .manual-wrap,
    .manual-wrap * {
        transform: none !important;
    }

    .manual-wrap img,
    .manual-wrap video,
    .manual-wrap canvas {
        display: block;
        width: auto !important;
        height: auto !important;
        object-fit: contain !important;
    }

    .manual-modal .manual-close,
    .manual-modal .manual-prev,
    .manual-modal .manual-next,
    .manual-modal .close,
    .manual-modal .prev,
    .manual-modal .next,
    .manual-modal [data-action="close"],
    .manual-modal [data-action="previous"],
    .manual-modal [data-action="next"] {
        position: relative;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        padding: 24px;
        margin: -24px;
        z-index: 1;
    }

    .manual-modal .manual-close:focus-visible,
    .manual-modal .manual-prev:focus-visible,
    .manual-modal .manual-next:focus-visible,
    .manual-modal .close:focus-visible,
    .manual-modal .prev:focus-visible,
    .manual-modal .next:focus-visible,
    .manual-modal [data-action="close"]:focus-visible,
    .manual-modal [data-action="previous"]:focus-visible,
    .manual-modal [data-action="next"]:focus-visible {
        outline: 2px solid #fff;
        outline-offset: 2px;
    }
}
