/* === БАЗОВЫЕ НАСТРОЙКИ === */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', system-ui, sans-serif;
    /* Сиреневый градиент возвращен! */
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* === ОБЪЕДИНЁННЫЙ ГРАДИЕНТНЫЙ БЛОК (Шапка + Hero) === */

.hero-header-combined {
    /* Делаем блок чуть темнее/прозрачнее, чтобы сливался с фоном или выделялся */
    background: rgba(255, 255, 255, 0.1); 
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 20px 40px 50px 40px;
    color: white;
    margin-bottom: 40px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Шапка внутри */
.hero-top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Стили для маленькой картинки в шапке */
.logo-img {
    height: 40px;
    width: auto;
    filter: brightness(0) invert(1); /* Делает картинку белой, если она цветная */
}

.header-controls {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.level-selector {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.2);
    padding: 8px 15px;
    border-radius: 10px;
}

.level-icon {
    font-size: 1.2rem;
}

.level-dropdown {
    border: none;
    background: transparent;
    font-family: inherit;
    font-size: 0.95rem;
    font-weight: 600;
    color: white;
    cursor: pointer;
    outline: none;
}

.level-dropdown option {
    color: #333;
}

.streak-counter {
    display: flex;
    align-items: center;
    gap: 5px;
    background: rgba(255, 255, 255, 0.2);
    padding: 8px 15px;
    border-radius: 10px;
    font-weight: 600;
}

.login-btn {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.4);
    padding: 8px 15px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.login-btn:hover {
    background: rgba(255, 255, 255, 0.4);
}

/* Контент Hero */
.hero-content {
    text-align: center;
    padding-top: 20px;
}

/* Стили для большой эмблемы */
.hero-emblem {
    margin-bottom: 20px;
}

.main-logo-img {
    height: 120px; /* Размер большой эмблемы */
    width: auto;
    filter: drop-shadow(0 5px 15px rgba(0,0,0,0.3));
}

.hero-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 10px;
    text-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.hero-subtitle {
    font-size: 1.2rem;
    margin-bottom: 30px;
    opacity: 0.9;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.btn-primary {
    background: white;
    color: #764ba2;
    padding: 15px 50px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1.2rem;
    text-decoration: none;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s, box-shadow 0.2s;
    display: inline-block;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

/* === МОДУЛИ === */

.section-title {
    text-align: center;
    font-size: 2rem;
    color: white; /* Заголовок теперь белый, т.к. фон сиреневый */
    margin-bottom: 30px;
    text-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

.modules-section {
    margin-bottom: 40px;
}

.modules-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 25px;
}

.module-card {
    background: rgba(255, 255, 255, 0.9); /* Полупрозрачные белые карточки */
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 30px;
    border: 1px solid rgba(255, 255, 255, 0.6);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s, box-shadow 0.3s;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.module-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.module-icon {
    width: 70px;
    height: 70px;
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    margin-bottom: 20px;
    color: white;
}

.blue   { background: linear-gradient(135deg, #667eea, #764ba2); }
.yellow { background: linear-gradient(135deg, #f6d365, #fda085); }
.red    { background: linear-gradient(135deg, #ff9a9e, #fecfef); }
.green  { background: linear-gradient(135deg, #84fab0, #8fd3f4); }
.orange { background: linear-gradient(135deg, #f093fb, #f5576c); }
.purple { background: linear-gradient(135deg, #4facfe, #00f2fe); }

.module-card h3 {
    font-size: 1.3rem;
    color: #1f2937;
    margin-bottom: 12px;
    font-weight: 700;
}

.module-card p {
    color: #6b7280;
    font-size: 0.95rem;
    margin-bottom: 20px;
    flex-grow: 1;
}

.module-btn {
    width: 100%;
    background: linear-gradient(90deg, #667eea, #764ba2);
    color: white;
    border: none;
    padding: 14px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: opacity 0.2s, transform 0.2s;
}

.module-btn:hover {
    opacity: 0.9;
    transform: scale(1.02);
}

.module-btn:disabled {
    background: #e5e7eb;
    cursor: not-allowed;
    opacity: 0.7;
}

/* === ПОДВАЛ === */

.footer {
    text-align: center;
    padding: 30px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 15px;
    margin-top: 40px;
    color: #4b5563;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 25px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

.footer-links a {
    color: #4b5563;
    text-decoration: none;
    font-weight: 500;
}

/* === АДАПТИВНОСТЬ === */

@media (max-width: 768px) {
    .hero-header-combined {
        padding: 20px;
    }
    
    .hero-top-bar {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
    }
    
    .header-controls {
        justify-content: center;
    }
    
    .hero-title {
        font-size: 1.8rem;
    }
    
    .main-logo-img {
        height: 80px;
    }
}