/* ============================================================
   CactusQuiz — стили главной страницы (/)
   ============================================================ */

* { box-sizing: border-box; }
body {
    margin: 0;
    font-family: system-ui, -apple-system, sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ВЕРХНЯЯ ШАПКА */
.top-header {
    background: #17241d;
    border-bottom: 1px solid #2e4739;
    padding: 0.8rem 1.8rem;
    display: flex;
    align-items: center;
}
.top-header .logo {
    font-size: 1.8rem;
    font-weight: 900;
    color: #ffffff;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* ИКОНКИ СОЦСЕТЕЙ В ШАПКЕ */
.social-links {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.social-links a, .footer-social a {
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    color: #a3c2b0; /* приглушённый цвет в тон темы */
    transition: color 0.25s ease, background 0.25s ease, transform 0.25s ease;
}
.social-links a {
    width: 38px;
    height: 38px;
}
.social-links a:hover, .footer-social a:hover {
    transform: translateY(-2px);
}
.social-links a.vk:hover, .footer-social a.vk:hover {
    color: #0077ff; /* фирменный VK */
    background: rgba(0, 119, 255, 0.12);
}
.social-links a.tg:hover, .footer-social a.tg:hover {
    color: #26a5e4; /* фирменный Telegram */
    background: rgba(38, 165, 228, 0.12);
}

/* ФУТЕР */
.site-footer {
    background: #17241d;
    border-top: 1px solid #2e4739;
    padding: 1rem 1.8rem;
}
.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}
.footer-copy {
    color: #7a9a86;
    font-size: 0.9rem;
}
.footer-social {
    display: flex;
    gap: 0.5rem;
}
.footer-social a {
    width: 36px;
    height: 36px;
}

/* ДВУХКОЛОНОЧНЫЙ МАКЕТ */
.layout-container {
    display: grid;
    grid-template-columns: 300px 1fr;
    flex: 1;
}

/* ЛЕВАЯ КОЛОНКА (СПИСОК КВИЗОВ) */
.sidebar {
    background: #1c2c23;
    padding: 1.4rem 1.2rem;
    border-right: 1px solid #2e4739;
}
.sidebar h3 {
    margin-top: 0;
    color: #f1c40f;
    font-size: 1.2rem;
    border-bottom: 2px solid #2e4739;
    padding-bottom: 0.6rem;
}
.quiz-list {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    margin-top: 1rem;
}
.quiz-item {
    background: #273d30;
    padding: 0.8rem 1rem;
    border-radius: 8px;
    font-weight: bold;
    font-size: 0.9rem;
    border-left: 4px solid #2ecc71;
    text-decoration: none;
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.2s ease;
}
.quiz-item:hover {
    background: #314d3d;
    border-left-color: #f39c12;
    transform: translateX(4px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

/* ПРАВАЯ ГЛАВНАЯ ЗОНА (HERO) */
.main-content {
    padding: 1.5rem 2rem;
    max-width: 900px;
    margin: 0 auto;
    width: 100%;
}

/* HERO: ЗАГОЛОВОК */
.hero-title h1 {
    margin: 0 0 1.5rem 0;
    font-size: 2rem;
    font-weight: 900;
    color: #ffffff;
}
.hero-subtitle {
    margin: 0 0 1.2rem 0;
    font-size: 1.15rem;
    color: #a3c2b0;
}

.hero-actions {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    margin-bottom: 1.5rem;
}

/* Главная кнопка — компактный вариант */
.btn-main-host {
    background: linear-gradient(135deg, #27ae60, #1e8449);
    color: white;
    text-decoration: none;
    padding: 1.1rem 1.5rem;
    border-radius: 14px;
    text-align: center;
    font-size: 1.6rem;
    font-weight: 900;
    box-shadow: 0 8px 20px rgba(39, 174, 96, 0.3);
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
    border: 2px solid #2ecc71;
}
.btn-main-host:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(39, 174, 96, 0.45);
    background: linear-gradient(135deg, #2ecc71, #219150);
}

/* Второстепенная кнопка — компактный вариант */
.btn-secondary-player {
    background: #253847;
    color: #ffffff;
    text-decoration: none;
    padding: 0.8rem 1.4rem;
    border-radius: 12px;
    text-align: center;
    font-size: 1.1rem;
    font-weight: bold;
    border: 2px solid #3e5c74;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
}
.btn-secondary-player:hover {
    background: #2e4557;
    border-color: #527999;
    transform: translateY(-2px);
}

/* НИЖНИЙ ИНФО-БЛОК: КАК ИГРАТЬ В 3 ШАГА */
.how-to-play {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-bottom: 2.5rem;
}
.how-to-play-title {
    grid-column: 1 / -1; /* на всю ширину сетки, над тремя карточками */
    margin: 0;
    font-size: 1.8rem;
    font-weight: 900;
    color: #f1c40f;
}
.step {
    display: flex;
    flex-direction: column;
    text-align: center;
    background: #1a2a20;
    border: 2px solid #2e4739;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 4px 14px rgba(0,0,0,0.2);
}
.step img {
    width: 100%;
    height: auto;
    display: block;
}
.step h3 {
    margin: 0.9rem 0 0.4rem 0;
    padding: 0 1.2rem;
    text-align: left;
    color: #f1c40f;
    font-size: 1.15rem;
    line-height: 1.3;
    min-height: 2.6em; /* место под 2 строки — текст во всех карточках стартует на одной высоте */
}
.step p {
    margin: 0;
    padding: 0 1.2rem 1.2rem;
    text-align: left;
    color: #d1e2d8;
    font-size: 0.95rem;
    line-height: 1.3rem;
}

/* ПОДРОБНЫЙ ТЕКСТ ВНИЗУ (СЕО) */
.seo-section {
    border-top: 1px solid #2e4739;
    padding-top: 2.5rem;
    margin-top: 1rem;
}
.seo-section h2 {
    font-size: 1.8rem;
    color: #f1c40f;
    margin: 0 0 1.2rem 0;
    display: flex;
    align-items: center;
    gap: 0.6rem;
}
.features-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}
.feature-item h4 {
    font-size: 1.15rem;
    margin: 0 0 0.4rem 0;
    color: #ffffff;
}
.feature-item p {
    font-size: 0.95rem;
    line-height: 1.5rem;
    color: #a3c2b0;
    margin: 0;
}

/* АДАПТИВНОСТЬ ДЛЯ МОБИЛЬНЫХ И МАЛЕНЬКИХ ЭКРАНОВ */
@media (max-width: 600px) {
    .top-header { padding: 0.6rem 1rem; }
    .top-header .logo { font-size: 1.3rem; }
    .social-links a { width: 32px; height: 32px; }
    .social-links a svg { width: 20px; height: 20px; }
}

@media (max-width: 900px) {
    .layout-container {
        grid-template-columns: 1fr;
    }
    .sidebar {
        border-right: none;
        border-bottom: 1px solid #2e4739;
    }
    .how-to-play, .features-grid {
        grid-template-columns: 1fr;
    }
    .btn-main-host {
        font-size: 1.4rem;
        padding: 1rem;
    }
}
