/* /local/templates/main/css/special-view.css */

/* Кнопка включения версии для слабовидящих */
.special-view-btn {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    background: #fff;
    border: 2px solid #333;
    padding: 10px 20px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    border-radius: 5px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.special-view-btn:hover {
    background: #f0f0f0;
}

/* Панель настроек */
.special-view-panel {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 10000;
    justify-content: center;
    align-items: center;
}

.special-view-panel.active {
    display: flex;
}

.special-view-content {
    background: #fff;
    padding: 30px;
    border-radius: 10px;
    max-width: 600px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
}

.special-view-close {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 24px;
    cursor: pointer;
    background: none;
    border: none;
    padding: 5px 10px;
}

.special-view-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 25px;
    text-align: center;
}

.special-view-group {
    margin-bottom: 25px;
}

.special-view-group-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 10px;
}

.special-view-options {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.special-view-option {
    flex: 1;
    min-width: 120px;
    padding: 12px 15px;
    border: 2px solid #ddd;
    background: #fff;
    cursor: pointer;
    text-align: center;
    border-radius: 5px;
    transition: all 0.3s ease;
    font-size: 14px;
}

.special-view-option:hover {
    border-color: #333;
}

.special-view-option.active {
    background: #333;
    color: #fff;
    border-color: #333;
}

.special-view-apply {
    width: 100%;
    padding: 15px;
    background: #3e5cc5;
    color: #fff;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    margin-bottom: 10px;
}

.special-view-apply:hover {
    background: #218838;
}

.special-view-reset {
    width: 100%;
    padding: 15px;
    background: #dc3545;
    color: #fff;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 10px;
}

.special-view-reset:hover {
    background: #c82333;
}

/* Применение настроек */

/* Размеры шрифта */
body.special-font-normal {
    /* Обычный размер - без изменений */
}

body.special-font-large * {
    font-size: 120% !important;
    line-height: 1.5 !important;
}

body.special-font-xlarge * {
    font-size: 150% !important;
    line-height: 1.6 !important;
}

/* Цветовые схемы */
body.special-color-white {
    /* Обычная схема - без изменений */
}

body.special-color-black {
    background: #000 !important;
}

body.special-color-black * {
    background: #000 !important;
    color: #fff !important;
    border-color: #fff !important;
}

body.special-color-black a {
    color: #fff !important;
    text-decoration: underline !important;
}

body.special-color-blue {
    background: #9DD1FF !important;
}

body.special-color-blue * {
    background: #9DD1FF !important;
    color: #063462 !important;
    border-color: #063462 !important;
}

body.special-color-blue a {
    color: #063462 !important;
    text-decoration: underline !important;
}

body.special-color-beige {
    background: #F7F3D6 !important;
}

body.special-color-beige * {
    background: #F7F3D6 !important;
    color: #4D4B43 !important;
    border-color: #4D4B43 !important;
}

body.special-color-beige a {
    color: #4D4B43 !important;
    text-decoration: underline !important;
}

/* Межбуквенный интервал */
body.special-spacing-normal * {
    letter-spacing: normal !important;
}

body.special-spacing-medium * {
    letter-spacing: 2px !important;
}

body.special-spacing-large * {
    letter-spacing: 4px !important;
}

/* Изображения */
body.special-images-hide img {
    display: none !important;
}

body.special-images-hide video {
    display: none !important;
}

body.special-images-hide .special-view-btn {
    display: block !important;
}

/* Исключения для панели настроек */
.special-view-panel,
.special-view-panel *,
.special-view-content,
.special-view-content * {
    background: #fff !important;
    color: #333 !important;
    font-size: 14px !important;
    line-height: 1.5 !important;
    letter-spacing: normal !important;
}

.special-view-title {
    font-size: 24px !important;
}

.special-view-group-title {
    font-size: 16px !important;
}

.special-view-option.active {
    background: #333 !important;
    color: #fff !important;
}

.special-view-reset {
    font-size: 16px !important;
    background: #dc3545 !important;
    color: #fff !important;
}

.special-view-apply {
    font-size: 16px !important;
    background: #28a745 !important;
    color: #fff !important;
}

/* Адаптивность */
@media (max-width: 768px) {
    .special-view-btn {
        top: 10px;
        right: 10px;
        padding: 8px 15px;
        font-size: 12px;
    }
    
    .special-view-content {
        padding: 20px;
    }
    
    .special-view-option {
        min-width: 100px;
        padding: 10px;
        font-size: 12px;
    }
}