/* CSS переменные цветов в стиле readaem */
:root {
    --background-color: #ffffff;
    --default-color: #3b5353;
    --heading-color: #193838;
    --accent-color: #00a19e;
    --surface-color: #ffffff;
    --contrast-color: #ffffff;
    --nav-color: #3b5353;
    --nav-hover-color: #00a19e;
    --light-bg: #f0f6f5;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    line-height: 1;
    background-color: var(--background-color);
    color: var(--default-color);
    padding: 10px;
}

article
{
    padding:20px;
}

/* Кнопка шестеренки */
.settings-toggle {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
    background: #007bff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 1000;
    border: none;
    color: white;
    font-size: 24px;
}

.settings-toggle:hover {
    transform: scale(1.1);
    background: #0056b3;
}

/* Панели */
.panel {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: white;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
    z-index: 999;
    transform: translateY(100%);
    padding: 20px;
    max-height: 80vh;
    overflow-y: auto;
    transition: all 0.3s ease;
}

.panel.active {
    transform: translateY(0);
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.panel-title {
    font-size: 1.5rem;
    font-weight: bold;
    display: flex;
    align-items: center;
    gap: 10px;
}

.back-btn, .close-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 5px;
    color: #666;
}

.back-btn:hover, .close-btn:hover {
    color: #000;
}

/* Прогресс-бары */
.progress-container {
    margin: 20px 10px;
}

.progress-label {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    font-size: 0.9rem;
    color: #666;
}

.progress-bar {
    width: 100%;
    height: 6px;
    background: #e0e0e0;
    border-radius: 3px;
    position: relative;
    cursor: pointer;
}

.progress-fill {
    height: 100%;
    background: #007bff;
    border-radius: 3px;
    position: relative;
}

.progress-thumb {
    position: absolute;
    right: -12px;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 24px;
    background: #007bff;
    border-radius: 50%;
    cursor: grab;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.progress-thumb:active {
    cursor: grabbing;
}

.progress-value {
    position: absolute;
    top: -30px;
    right: -12px;
    background: #333;
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    white-space: nowrap;
}

/* Иконки настроек */
.settings-icons {
    display: flex;
    gap: 20px;
    margin-top: 30px;
    justify-content: center;
}

.icon-btn {
    width: 60px;
    height: 60px;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.5rem;
    background: white;
}

.icon-btn:hover {
    border-color: #007bff;
    background: #f8f9fa;
}

/* Выпадающий список */
.select-container {
    margin: 20px 0;
}

.select-label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #333;
}

.font-select {
    width: 100%;
    padding: 12px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 1rem;
    background: white;
    cursor: pointer;
}

.font-select:focus {
    border-color: #007bff;
    outline: none;
}

/* Цветовая панель */
.color-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin: 20px 0;
}

.color-option {
    padding: 15px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    cursor: pointer;
    text-align: center;
    font-weight: bold;
}

.color-option:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.color-light-1 {
    background: #ffffff;
    color: #000000;
    border-color: #333;
}

.color-light-2 {
    background: #f8f9fa;
    color: #212529;
    border-color: #dee2e6;
}

.color-dark-1 {
    background: #1a1a1a;
    color: #ffffff;
    border-color: #404040;
}

.color-dark-2 {
    background: #2d3748;
    color: #e2e8f0;
    border-color: #4a5568;
}

/* Toast уведомления */
.toast {
    position: fixed;
    top: 20px;
    right: 20px;
    background: #333;
    color: white;
    padding: 12px 20px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 1100;
    transform: translateX(150%);
}

.toast.show {
    transform: translateX(0);
}

/* Оверлей */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 998;
    opacity: 0;
    visibility: hidden;
}

.overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Hero секция с градиентным фоном в стиле readaem */
.hero-section {
    background: linear-gradient(135deg, var(--accent-color), color-mix(in srgb, var(--accent-color), #6366f1 30%));
    color: white;
    position: relative;
    overflow: hidden;
    padding: 140px 0 60px;
}

.hero-section::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.1);
}

.hero-section .container {
    position: relative;
    z-index: 2;
}

.hero-section h1 {
    font-size: 3.5rem;
    font-weight: 300;
    line-height: 1.2;
    margin-bottom: 2rem;
    color: white;
}

.hero-section .lead {
    font-size: 1.25rem;
    line-height: 1.6;
    margin-bottom: 2rem;
}

/* Кнопки в hero секции */
.hero-section .btn-light {
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.3);
    color: white;
    backdrop-filter: blur(10px);
}

.hero-section .btn-light:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.5);
    color: white;
}

.hero-section .btn-outline-light {
    border: 2px solid rgba(255, 255, 255, 0.5);
    color: white;
    background: transparent;
}

.hero-section .btn-outline-light:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: white;
    color: white;
}

@media (max-width: 768px) {
    .hero-section {
        padding: 100px 0 40px;
    }

    .hero-section h1 {
        font-size: 2.5rem;
        margin-bottom: 1.5rem;
    }

    .hero-section .lead {
        font-size: 1.125rem;
    }
}

/* Панель уведомления о cookies */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #343a40;
    color: white;
    padding: 15px 0;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.3);
    z-index: 1050;
    border-top: 3px solid var(--accent-color);
}

.cookie-banner-text {
    font-size: 0.9rem;
    line-height: 1.4;
}

.cookie-banner-text strong {
    display: block;
    margin-bottom: 5px;
    font-size: 1rem;
}

.cookie-banner-text p {
    color: #e9ecef;
    font-size: 0.85rem;
}

.cookie-banner-text a {
    color: #ffc107;
    text-decoration: none;
}

.cookie-banner-text a:hover {
    text-decoration: underline;
    color: #fff3cd;
}

.cookie-banner .btn {
    font-size: 0.85rem;
    padding: 6px 12px;
    border-radius: 6px;
    font-weight: 500;
}

.cookie-banner .btn-success {
    background-color: var(--accent-color);
    border-color: var(--accent-color);
    transition: 0.3s;
}

.cookie-banner .btn-success:hover {
    background-color: color-mix(in srgb, var(--accent-color), #000 10%);
    border-color: color-mix(in srgb, var(--accent-color), #000 10%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 161, 158, 0.3);
}

/* Общие transition анимации для плавных эффектов */
a, button, .card, .btn, .nav-link, .icon-btn {
    transition: 0.3s ease;
}

/* Цвета заголовков */
h1, h2, h3, h4, h5, h6 {
    color: var(--heading-color);
}

/* Hover эффекты для карточек */
.card {
    transition: 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

/* Hover эффекты для кнопок */
.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* Цвета ссылок */
a {
    color: var(--accent-color);
    text-decoration: none;
}

a:hover {
    color: color-mix(in srgb, var(--accent-color), #000 10%);
    text-decoration: none;
}

/* Навигационные ссылки */
.nav-link:hover {
    color: var(--nav-hover-color) !important;
}

/* Секции с фоновыми цветами */
.bg-light {
    background-color: var(--light-bg) !important;
}

/* Адаптивность для мобильных устройств */
@media (max-width: 768px) {
    .cookie-banner .row {
        flex-direction: column;
        text-align: center;
    }

    .cookie-banner .col-lg-8,
    .cookie-banner .col-md-7 {
        margin-bottom: 10px;
    }

    .cookie-banner .col-lg-4,
    .cookie-banner .col-md-5 {
        text-align: center;
    }

    .cookie-banner-text {
        font-size: 0.85rem;
    }
}