/* Settings Component Styles - Использует стили из global.css */

/* Основной контейнер настроек */
.settings-dropdown {
    position: relative;
    display: inline-block;
}

/* Контент настроек (скрыт в header, используется как шаблон) */
.settings-content {
    display: none;
}

/* Заголовки секций */
.settings-section-title {

    font-family: var(--sans-secondary);
    font-size: var(--lg);
    font-weight: var(--rg);
    color: var(--white);
    opacity: 0.9;
    text-transform: uppercase;
    letter-spacing: 0.5px;
 
}

/* Элементы настроек */
.settings-item {
    display: flex;
    align-items: center;
    padding: var(--xs) var(--sm);
    background: rgba(0, 13, 12, 0.85);
    border: none;
    border-radius: 6px;
    color: var(--white);
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease, transform 0.2s ease;
    font-family: var(--sans-secondary);
    min-height: 36px;
    opacity: 0.9;
    width: 100%;
    border: 1px solid #00ecff1a;
    font-size: var(--md);
    justify-content: center;
    text-transform: uppercase;
    font-weight: var(--sb);
    text-align: center;
        font-size: var(--lg);
}

.settings-item:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    opacity: 1;
    transform: translateY(-2px);
}

.settings-item:active {
    transform: translateY(0);
}

.settings-item.active {
    background: rgba(255, 204, 0, 0.2);
    border-color: rgba(255, 204, 0, 0.4);
    color: var(--yellow);
}

.settings-item i {
    opacity: 0.8;
    font-size: 16px;
    width: 20px;
    text-align: center;
    transition: transform 0.3s ease;
}

.settings-item:hover i {
    transform: scale(1.1);
}

.settings-item span {
flex: 1;
  white-space: nowrap;
  text-transform: uppercase;
  font-family: var(--secondary);
    font-size: var(--md);
  font-weight: var(--sb);
}

.settings-item.is-disabled,
.settings-item:disabled {
    cursor: not-allowed;
    opacity: 0.45;
    pointer-events: none;
}

.settings-item.is-loading {
    opacity: 0.6;
    pointer-events: none;
    position: relative;
}

.settings-hint {
    margin-top: 6px;
    font-family: var(--sans-secondary);
    font-size: var(--sm);
    line-height: 1.4;
    color: rgba(255, 255, 255, 0.75);
    opacity: 0.85;
}

@media (min-width: 300px) and (max-width: 576px) {
    .settings-item span {
    font-size: var(--lg);
}

.video-preview-play-button {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
    min-height: 32px !important;
    max-width: 32px !important;
    max-height: 32px !important;
}

.settings-section-title {
    font-size: var(--lg);
}

.settings-item {
        font-size: var(--lg);
}
}
@media (min-width: 577px) and (max-width: 768px) {
        .settings-item span {
    font-size: var(--lg);
}


.settings-section-title {
    font-size: var(--lg);
}
.settings-item {
        font-size: var(--lg);
}

.video-preview-play-button {
    width: 32px;
    height: 32px;
}
}

@media (min-width: 769px) and (max-width: 1024px){
        .settings-item span {
    font-size: var(--lg);
}
.settings-item {
        font-size: var(--lg);
}
.settings-section-title {
    font-size: var(--lg);
}

.video-preview-play-button {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
    min-height: 32px !important;
    max-width: 32px !important;
    max-height: 32px !important;
}
.settings-item {
        font-size: var(--lg);
}

.video-preview-play-button {
    width: 64px;
    height: 64px;
}


}


@media (min-width: 1025px) {
        .settings-item span {
    font-size: var(--md);
}
.settings-section-title {
    font-size: var(--md);
}
.settings-item {
        font-size: var(--md);
}

.video-preview-play-button {
    width: 64px !important;
    height: 64px !important;
}


}

/* Кнопки сброса */
.reset-btn {
    background: rgba(255, 0, 0, 0.1) !important;
    border-color: rgba(255, 0, 0, 0.3) !important;
}

.reset-btn:hover {
    background: rgba(255, 0, 0, 0.2) !important;
    border-color: rgba(255, 0, 0, 0.5) !important;
}

.reset-btn:hover i {
    transform: rotate(180deg) scale(1.1);
}

/* Анимации для специфичных кнопок */
.font-size-btn[data-action="increase"]:hover i {
    transform: scale(1.3);
}

.font-size-btn[data-action="decrease"]:hover i {
    transform: scale(0.9);
}

.line-height-btn:hover i {
    transform: scaleY(1.2);
}

.bookmark-btn:hover i {
    animation: bookmark-bounce 0.5s ease;
}

@keyframes bookmark-bounce {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.2) translateY(-2px); }
}

/* Сетка языков */
.language-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--xs);
}

.language-option {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--xs);
    background: rgba(255, 255, 255, 0.05);
    border: none;
    border-radius: 4px;
    color: var(--white);
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: var(--sans-primary);
    font-size: 12px;
    text-align: center;
    opacity: 0.8;
}

.language-option:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    opacity: 1;
}

.language-option.active {
    background: rgba(0, 181, 194, 0.2);
    border-color: rgba(0, 181, 194, 0.4);
    color: var(--turquoise);
}

/* Уведомления */
.settings-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: rgba(0, 0, 0, 0.9);
    color: var(--white);
    padding: var(--sm) var(--lg);
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    font-family: var(--sans-primary);
    font-size: var(--sm);
    opacity: 0;
    transform: translateX(100%);
    transition: all 0.3s ease;
    z-index: 10000;
    backdrop-filter: blur(10px);
}

.settings-notification.show {
    opacity: 1;
    transform: translateX(0);
}

/* Адаптивность */
@media (max-width: 768px) {
    .settings-card {
        width: 100vw;
    }

    .settings-notification {
        left: 20px;
        right: 20px;
        text-align: center;
    }
}

.language-option.active {
    background-color: var(--primary);
    border-color: var(--primary);
    color: var(--text-primary);
    background: rgba(255, 204, 0, 0.2);
  border-color: rgba(255, 204, 0, 0.4);
  color: var(--yellow);
}

/* Mobile Settings Modal */
.settings-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    display: none;
}

.settings-modal.mobile {
    display: flex;
    flex-direction: column;
}

.settings-modal.open {
    opacity: 1;
    visibility: visible;
}

.settings-modal-header {
    background: rgba(20, 20, 25, 0.95);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding: var(--lg);
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
}

.settings-modal-header h2 {
    color: rgba(255, 255, 255, 0.9);
    font-size: var(--lg);
    margin: 0;
}

.settings-modal-close {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    font-size: var(--lg);
    cursor: pointer;
    padding: var(--xs);
    border-radius: 6px;
    transition: all 0.3s;
}

.settings-modal-close:hover {
    color: rgba(255, 255, 255, 1);
    background-color: rgba(255, 255, 255, 0.1);
}

.settings-modal-body {
    background: rgba(15, 15, 20, 0.95);
    flex: 1;
    overflow-y: auto;
    padding: var(--lg);
}

/* Mobile adjustments */
.language-grid.mobile {
    grid-template-columns: repeat(2, 1fr);
}

.language-option.mobile {
    padding: var(--sm);
    font-size: var(--sm);
}

.settings-item.mobile {
    padding: var(--sm) var(--md);

}

/* Bookmark notification */
.bookmark-notification {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(20, 20, 25, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    padding: var(--sm) var(--md);
    color: rgba(255, 255, 255, 0.9);
    font-size: var(--sm);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 3000;
    backdrop-filter: blur(10px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
}

.bookmark-notification.show {
    opacity: 1;
    visibility: visible;
}

/* Font switching animation */
.font-switching {
    transition: font-family 0.3s ease;
}

/* Mobile settings trigger styles */
.mobile-settings-trigger {
    background: transparent;
    border: none;
    outline: none;
    padding: 0;
    margin: 0;
}

.settings-trigger {
    background: transparent;
    border: none;
    outline: none;
    padding: 0;
    margin: 0;
}

/* Web-only class: show only on desktop */
.web-only {
    display: none;
}

@media (min-width: 1025px) {
    .web-only {
        display: block;
    }
}

/* Позиция и стили кнопки настроек для веба */
@media (min-width: 1025px) {
    .settings-dropdown.web-only {
        display: inline-block !important;
        position: static !important;
        width: 0 !important;
        height: 0 !important;
        overflow: visible !important;
    }

    .settings-trigger {
        position: fixed !important;
        bottom: 24px !important;
        right: 24px !important;
        width: 32px !important;
        height: 32px !important;
        min-width: 32px !important;
        min-height: 32px !important;
        max-width: 32px !important;
        max-height: 32px !important;
        background: #ffffff0f !important;
        border-radius: var(--hg) !important;
        backdrop-filter: blur(8px) !important;
        -webkit-backdrop-filter: blur(8px) !important;
        border: 1px solid #ffffff1c !important;
        color: #ffffff80 !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        cursor: pointer !important;
        transition: background 0.3s ease, color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease !important;
        z-index: 10000 !important;
        transform: none !important;
        will-change: auto !important;
        pointer-events: auto !important;
    }

    /* Отключаем магнитный эффект для кнопки настроек */
    .settings-trigger.magnetic {
        will-change: auto !important;
        pointer-events: auto !important;
    }

    .settings-trigger i {
        font-size: 16px !important;
        line-height: 1 !important;
        pointer-events: none !important;
        transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
    }

    .settings-trigger:hover {
        background: rgba(255, 255, 255, 0.18) !important;
        color: var(--white) !important;
        border-color: rgba(255, 255, 255, 0.35) !important;
        box-shadow:
            0 0 16px 3px rgba(255, 255, 255, 0.25),
            0 4px 12px rgba(0, 0, 0, 0.2) !important;
        transform: translateZ(0) scale(1.08) translateY(-1px) !important;
    }

    .settings-trigger:hover i {
        transform: scale(1.1) rotate(90deg) !important;
    }

    .settings-trigger:active {
        background: rgba(255, 255, 255, 0.22) !important;
        color: var(--white) !important;
        border-color: rgba(255, 255, 255, 0.4) !important;
        box-shadow:
            0 0 20px 4px rgba(255, 255, 255, 0.35),
            inset 0 2px 4px rgba(0, 0, 0, 0.1) !important;
        transform: translateZ(0) scale(0.96) translateY(0) !important;
    }
}

/* Hide settings on mobile by default, show only when trigger exists */
@media (max-width: 768px) {
    .settings-dropdown {
        display: none;
    }
    
    .mobile-settings-trigger {
        display: block;
    }
    
    .settings-modal.mobile {
        display: flex;
    }
}

/* Планшеты: показываем мобильную кнопку настроек */
@media (min-width: 769px) and (max-width: 1024px) {
    .settings-dropdown {
        display: none;
    }
    
    .mobile-settings-trigger {
        display: block !important;
        pointer-events: auto !important;
        cursor: pointer !important;
        z-index: 1000 !important;
        position: relative !important;
    }
    
    .settings-modal.mobile {
        display: flex;
    }
    
    .settings-modal {
        display: none !important;
    }
}

/* Десктоп: скрываем мобильную кнопку, показываем обычную */
@media (min-width: 1025px) {
    .settings-modal {
        display: none !important;
    }
    
    .mobile-settings-trigger {
        display: none;
    }
}
