/* ═══════════════════════════════════════════════════════════ */
/*  KO'ZI OJIZLAR UCHUN MAXSUS PANEL (Accessibility Toolbar)  */
/* ═══════════════════════════════════════════════════════════ */

/* ═══ Toggle Button (Floating Eye) — HIDDEN, now in top bar ═══ */
.accessibility-toggle {
    display: none !important;
}

/* ═══ Accessibility Panel ═══ */
.accessibility-panel {
    position: fixed;
    top: 0;
    right: -420px;
    width: 400px;
    height: 100vh;
    background: #1a1f36;
    border-left: 2px solid rgba(0, 102, 204, 0.3);
    z-index: 10000;
    overflow-y: auto;
    transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: -10px 0 40px rgba(0, 0, 0, 0.5);
}

.accessibility-panel.open {
    right: 0;
}

.accessibility-panel-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.accessibility-panel-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Panel Header */
.a11y-panel-header {
    background: linear-gradient(135deg, #0066cc, #0ea5e9);
    padding: 20px 25px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 2;
}

.a11y-panel-header h3 {
    color: #fff;
    font-family: 'Inter', sans-serif;
    font-size: 16px;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: none;
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
}

.a11y-panel-header h3 i {
    font-size: 20px;
}

.a11y-panel-close {
    background: rgba(255,255,255,0.15);
    border: 1px solid rgba(255,255,255,0.2);
    color: #fff;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.a11y-panel-close:hover {
    background: rgba(255,255,255,0.3);
    transform: rotate(90deg);
}

/* Panel Body */
.a11y-panel-body {
    padding: 20px 25px;
}

/* Section Groups */
.a11y-group {
    margin-bottom: 25px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 12px;
    padding: 18px;
}

.a11y-group-title {
    color: #8bb4e7;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.a11y-group-title i {
    font-size: 13px;
    color: #0ea5e9;
}

/* ═══ Font Size Controls ═══ */
.a11y-font-controls {
    display: flex;
    align-items: center;
    gap: 10px;
}

.a11y-font-btn {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    border: 1px solid rgba(0, 102, 204, 0.3);
    background: rgba(0, 102, 204, 0.1);
    color: #8bb4e7;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.25s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Inter', sans-serif;
}

.a11y-font-btn:hover {
    background: rgba(0, 102, 204, 0.25);
    color: #fff;
    border-color: #0ea5e9;
    transform: scale(1.05);
}

.a11y-font-btn:active {
    transform: scale(0.95);
}

.a11y-font-size-display {
    flex: 1;
    text-align: center;
    color: #fff;
    font-size: 22px;
    font-weight: 700;
    font-family: 'Orbitron', 'Inter', sans-serif;
    background: rgba(0, 102, 204, 0.08);
    border-radius: 10px;
    padding: 10px 0;
    border: 1px solid rgba(0, 102, 204, 0.15);
}

.a11y-font-size-display span {
    font-size: 11px;
    color: #8bb4e7;
    display: block;
    margin-top: 2px;
    font-family: 'Inter', sans-serif;
    font-weight: 400;
}

/* ═══ Color Theme Buttons ═══ */
.a11y-color-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 8px;
}

.a11y-color-btn {
    width: 100%;
    aspect-ratio: 1;
    border-radius: 10px;
    cursor: pointer;
    position: relative;
    transition: all 0.25s ease;
    border: 2px solid transparent;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.a11y-color-btn span {
    font-size: 8px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.a11y-color-btn:hover {
    transform: scale(1.08);
}

.a11y-color-btn.active {
    border-color: #0ea5e9;
    box-shadow: 0 0 12px rgba(14, 165, 233, 0.4);
}

.a11y-color-btn.active::after {
    content: '✓';
    position: absolute;
    top: -4px;
    right: -4px;
    width: 18px;
    height: 18px;
    background: #0ea5e9;
    color: #fff;
    font-size: 10px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Color scheme buttons */
.a11y-color-btn[data-scheme="white"] {
    background: #ffffff;
    color: #333;
    border-color: #ddd;
}
.a11y-color-btn[data-scheme="dark"] {
    background: #1a1a2e;
    color: #e0e0e0;
    border-color: #333;
}
.a11y-color-btn[data-scheme="blue"] {
    background: #1a237e;
    color: #bbdefb;
    border-color: #283593;
}
.a11y-color-btn[data-scheme="beige"] {
    background: #f5e6ca;
    color: #5d4037;
    border-color: #d7ccc8;
}
.a11y-color-btn[data-scheme="green"] {
    background: #1b5e20;
    color: #c8e6c9;
    border-color: #2e7d32;
}

.a11y-color-btn i {
    font-size: 16px;
}

/* ═══ Image Controls ═══ */
.a11y-image-controls {
    display: flex;
    gap: 8px;
}

.a11y-img-btn {
    flex: 1;
    padding: 12px 8px;
    border-radius: 10px;
    border: 1px solid rgba(255,255,255,0.1);
    background: rgba(255,255,255,0.04);
    color: #8bb4e7;
    cursor: pointer;
    transition: all 0.25s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.a11y-img-btn i {
    font-size: 18px;
}

.a11y-img-btn:hover {
    background: rgba(0, 102, 204, 0.15);
    border-color: rgba(0, 102, 204, 0.3);
    color: #fff;
}

.a11y-img-btn.active {
    background: rgba(0, 102, 204, 0.2);
    border-color: #0ea5e9;
    color: #0ea5e9;
}

/* ═══ Speech Synthesis ═══ */
.a11y-speech-btn {
    width: 100%;
    padding: 14px;
    border-radius: 10px;
    border: 1px solid rgba(0, 255, 200, 0.2);
    background: linear-gradient(135deg, rgba(0, 255, 200, 0.08), rgba(0, 102, 204, 0.08));
    color: #8bb4e7;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 13px;
    font-weight: 600;
    font-family: 'Inter', sans-serif;
}

.a11y-speech-btn i {
    font-size: 18px;
    color: #00ffc8;
}

.a11y-speech-btn:hover {
    background: linear-gradient(135deg, rgba(0, 255, 200, 0.15), rgba(0, 102, 204, 0.15));
    border-color: rgba(0, 255, 200, 0.4);
    color: #fff;
}

.a11y-speech-btn.speaking {
    background: linear-gradient(135deg, rgba(220, 38, 38, 0.15), rgba(239, 68, 68, 0.1));
    border-color: rgba(220, 38, 38, 0.3);
    color: #ef4444;
    animation: speaking-pulse 1.5s ease-in-out infinite;
}

.a11y-speech-btn.speaking i {
    color: #ef4444;
}

@keyframes speaking-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(220, 38, 38, 0.2); }
    50% { box-shadow: 0 0 0 8px rgba(220, 38, 38, 0); }
}

/* ═══ Reset Button ═══ */
.a11y-reset-btn {
    width: 100%;
    padding: 14px;
    border-radius: 10px;
    border: 1px solid rgba(255, 165, 0, 0.25);
    background: rgba(255, 165, 0, 0.08);
    color: #ffa500;
    cursor: pointer;
    transition: all 0.25s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 13px;
    font-weight: 600;
    font-family: 'Inter', sans-serif;
}

.a11y-reset-btn i {
    font-size: 16px;
}

.a11y-reset-btn:hover {
    background: rgba(255, 165, 0, 0.15);
    border-color: rgba(255, 165, 0, 0.4);
    color: #ffbb33;
}

/* ═══ ACCESSIBILITY THEME OVERRIDES ═══ */
/* Panel o'ziga ta'sir qilmasligi uchun :not() ishlatamiz */

/* White (High Contrast Light) */
body.a11y-scheme-white {
    background-color: #ffffff !important;
    color: #000000 !important;
}

body.a11y-scheme-white :not(.accessibility-panel):not(.accessibility-panel *):not(.accessibility-toggle):not(.accessibility-panel-overlay):not(.top-utility-bar):not(.top-utility-bar *):not(.top-search-overlay):not(.top-search-overlay *) {
    color: #000000 !important;
    border-color: #999 !important;
}

body.a11y-scheme-white .jarvis-navbar,
body.a11y-scheme-white .jarvis-footer {
    background: #f0f0f0 !important;
    border-color: #ccc !important;
}

body.a11y-scheme-white .omni-wrapper {
    background: #ffffff !important;
    border-color: #ccc !important;
}

body.a11y-scheme-white main a {
    color: #0000cc !important;
}

body.a11y-scheme-white .omni-glass-card,
body.a11y-scheme-white .section-card,
body.a11y-scheme-white .event-card,
body.a11y-scheme-white .announcement-item,
body.a11y-scheme-white .media-card,
body.a11y-scheme-white .faq-item {
    background: #f8f8f8 !important;
    border-color: #ccc !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1) !important;
}

/* Dark (High Contrast Dark) */
body.a11y-scheme-dark {
    background-color: #0a0a0a !important;
    color: #ffffff !important;
}

body.a11y-scheme-dark :not(.accessibility-panel):not(.accessibility-panel *):not(.accessibility-toggle):not(.accessibility-panel-overlay):not(.top-utility-bar):not(.top-utility-bar *):not(.top-search-overlay):not(.top-search-overlay *) {
    color: #ffffff !important;
    border-color: #444 !important;
}

body.a11y-scheme-dark .jarvis-navbar,
body.a11y-scheme-dark .jarvis-footer {
    background: #111 !important;
}

body.a11y-scheme-dark .omni-wrapper {
    background: #0a0a0a !important;
}

body.a11y-scheme-dark main a {
    color: #4dd0ff !important;
}

body.a11y-scheme-dark .omni-glass-card,
body.a11y-scheme-dark .section-card,
body.a11y-scheme-dark .event-card,
body.a11y-scheme-dark .announcement-item,
body.a11y-scheme-dark .media-card,
body.a11y-scheme-dark .faq-item {
    background: #1a1a1a !important;
    border-color: #444 !important;
}

/* Blue */
body.a11y-scheme-blue {
    background-color: #0d1b4a !important;
    color: #bbdefb !important;
}

body.a11y-scheme-blue :not(.accessibility-panel):not(.accessibility-panel *):not(.accessibility-toggle):not(.accessibility-panel-overlay):not(.top-utility-bar):not(.top-utility-bar *):not(.top-search-overlay):not(.top-search-overlay *) {
    color: #bbdefb !important;
    border-color: #1a3a8a !important;
}

body.a11y-scheme-blue .jarvis-navbar,
body.a11y-scheme-blue .jarvis-footer {
    background: #0a1540 !important;
}

body.a11y-scheme-blue .omni-wrapper {
    background: #0d1b4a !important;
}

body.a11y-scheme-blue main a {
    color: #64b5f6 !important;
}

body.a11y-scheme-blue .omni-glass-card,
body.a11y-scheme-blue .section-card,
body.a11y-scheme-blue .event-card,
body.a11y-scheme-blue .announcement-item,
body.a11y-scheme-blue .media-card,
body.a11y-scheme-blue .faq-item {
    background: #0f2060 !important;
    border-color: #1a3a8a !important;
}

/* Beige (Eye-friendly) */
body.a11y-scheme-beige {
    background-color: #f5e6ca !important;
    color: #3e2723 !important;
}

body.a11y-scheme-beige :not(.accessibility-panel):not(.accessibility-panel *):not(.accessibility-toggle):not(.accessibility-panel-overlay):not(.top-utility-bar):not(.top-utility-bar *):not(.top-search-overlay):not(.top-search-overlay *) {
    color: #3e2723 !important;
    border-color: #c8a882 !important;
}

body.a11y-scheme-beige .jarvis-navbar,
body.a11y-scheme-beige .jarvis-footer {
    background: #e8d5b0 !important;
}

body.a11y-scheme-beige .omni-wrapper {
    background: #f5e6ca !important;
}

body.a11y-scheme-beige main a {
    color: #1565c0 !important;
}

body.a11y-scheme-beige .omni-glass-card,
body.a11y-scheme-beige .section-card,
body.a11y-scheme-beige .event-card,
body.a11y-scheme-beige .announcement-item,
body.a11y-scheme-beige .media-card,
body.a11y-scheme-beige .faq-item {
    background: #eedcba !important;
    border-color: #c8a882 !important;
}

/* Green */
body.a11y-scheme-green {
    background-color: #0d2b0d !important;
    color: #c8e6c9 !important;
}

body.a11y-scheme-green :not(.accessibility-panel):not(.accessibility-panel *):not(.accessibility-toggle):not(.accessibility-panel-overlay):not(.top-utility-bar):not(.top-utility-bar *):not(.top-search-overlay):not(.top-search-overlay *) {
    color: #c8e6c9 !important;
    border-color: #2e7d32 !important;
}

body.a11y-scheme-green .jarvis-navbar,
body.a11y-scheme-green .jarvis-footer {
    background: #0a200a !important;
}

body.a11y-scheme-green .omni-wrapper {
    background: #0d2b0d !important;
}

body.a11y-scheme-green main a {
    color: #81c784 !important;
}

body.a11y-scheme-green .omni-glass-card,
body.a11y-scheme-green .section-card,
body.a11y-scheme-green .event-card,
body.a11y-scheme-green .announcement-item,
body.a11y-scheme-green .media-card,
body.a11y-scheme-green .faq-item {
    background: #133413 !important;
    border-color: #2e7d32 !important;
}

/* ═══ Font Size Multipliers ═══ */
body.a11y-font-sm { font-size: 14px !important; }

body.a11y-font-md { font-size: 16px !important; }

body.a11y-font-lg { font-size: 18px !important; }

body.a11y-font-xl { font-size: 20px !important; }

body.a11y-font-xxl { font-size: 24px !important; }

/* ═══ Image Visibility ═══ */
body.a11y-images-hidden img:not(.accessibility-panel img),
body.a11y-images-hidden video,
body.a11y-images-hidden svg:not(.accessibility-panel svg),
body.a11y-images-hidden [style*="background-image"]:not(.accessibility-panel *) {
    visibility: hidden !important;
}

body.a11y-images-grayscale img:not(.accessibility-panel img),
body.a11y-images-grayscale video {
    filter: grayscale(100%) !important;
}

/* ═══ Responsive ═══ */
@media (max-width: 480px) {
    .accessibility-panel {
        width: 100%;
        right: -100%;
    }

    .accessibility-toggle {
        width: 44px;
        height: 44px;
        font-size: 18px;
        top: 80px;
        right: 10px;
    }
}

/* ═══ Panel scrollbar ═══ */
.accessibility-panel::-webkit-scrollbar {
    width: 4px;
}

.accessibility-panel::-webkit-scrollbar-track {
    background: rgba(255,255,255,0.03);
}

.accessibility-panel::-webkit-scrollbar-thumb {
    background: rgba(0, 102, 204, 0.3);
    border-radius: 4px;
}

