
:root {
    --bg: #0e0e11;
    --card: #1a1a22;
    --accent: #e63946;
    --text: #f1f1f1;
    --muted: #9aa0a6;
}

* { box-sizing: border-box; }

html, body {
    height: 100%;
    margin: 0;
    padding: 0;
    background: radial-gradient(circle at top, #1c1c28, var(--bg));
    color: var(--text);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Контент будет центрироваться */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 40px 20px 5px 20px;
    
}

/* Шапка */
header {
    text-align: center;
    margin-bottom: 40px; /* увеличенный отступ от шапки до плеера */
}

header h1 {
    margin: 0;
    font-size: 2rem;
    letter-spacing: 2px;
}

header h1 span {
    color: var(--accent);
}

#time {
    margin-top: 10px;
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--accent);
}

#listeners {
    margin-top: 6px;
    font-size: 1.5rem;
    font-weight: 500;
    color: var(--muted);
}

/* Плеер */
.player-card {
    background: var(--card);
    padding: 20px 30px;
    border-radius: 16px;
    box-shadow: 0 15px 30px rgba(0,0,0,0.5);
    text-align: center;
    width: 90%;
    max-width: 450px; /* уменьшенный блок */
    margin-bottom: 40px;
}

.player-card h2 {
    margin: 0 0 12px;
    font-weight: 500;
    color: var(--muted);
    font-size: 1.5rem;
}

audio {
    width: 100%;
    margin-bottom: 15px;
}


/* Кнопки */

.player-actions {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}


.btn {
    display: inline-block;
    padding: 8px 19px; /* меньше кнопки */
    border-radius: 10px;
    background: var(--accent);
    color: var(--bg);
    text-decoration: none;
    font-weight: bold;
    font-size: 0.9rem;
    transition: background 0.3s, color 0.3s, transform 0.2s;
}

.btn:hover {
    background: #ff5c5c;
    color: #fff;
    transform: translateY(-2px);
}

/* Футер всегда внизу */
footer {
    font-size: 0.9rem;
    color: var(--muted);
    text-align: center;
    position: relative;
    width: 100%;
    padding: 10px 10px;
    <!-- margin-bottom: 80px; -->
    background: var(--bg);
}

/* Футер */

.chat-card {
    background: var(--card);
    padding: 20px 30px;
    border-radius: 16px;
    box-shadow: 0 15px 30px rgba(0,0,0,0.5);
    width: 90%;
    max-width: 450px;
    margin-bottom: 40px;
}

.chat-card h2 {
    margin: 0 0 12px;
    font-weight: 500;
    color: var(--muted);
    font-size: 1.5rem;
    text-align: center;
}

.chat-messages {
    max-height: 250px;
    overflow-y: auto;
    background: #111118;
    padding: 10px;
    border-radius: 10px;
    margin-bottom: 10px;
    font-size: 0.95rem;
}

.chat-messages div {
    margin-bottom: 6px;
}

.chat-form {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.chat-form input[type="text"] {
    flex: 1 1 auto;
    padding: 6px 10px;
    border-radius: 8px;
    border: none;
    font-size: 0.9rem;
}

.chat-form button {
    padding: 6px 12px;
    border-radius: 8px;
    background: var(--accent);
    color: var(--bg);
    font-weight: bold;
    font-size: 0.9rem;
    cursor: pointer;
    transition: background 0.3s;
}

.chat-form button:hover {
    background: #ff5c5c;
    color: #fff;
}


/* Адаптив для мобильных */
@media (max-width: 480px) {
    header h1 {
        font-size: 1.3rem;
    }

    #time, #listeners {
        font-size: 1.2rem;
    }

    .player-card {
        width: 90%;
        padding: 30px 40px;
    }

    .player-card h2 {
        font-size: 1.5rem;
    }

    .btn {
        padding: 6px 10px;
        font-size: 0.85rem;
    }

    .player-actions {
        flex-direction: column;
        gap: 10px;
    }
}


.stats-block {
    margin-top: 5px;
    font-size: 1.3rem;
    color: var(--muted);
}

.stats-block div {
    margin: 4px 0;
}

/* Кнопка вызова меню */
#side-menu-button {
    position: fixed;
    top: 10px;
    left: 10px;
    width: 40px;
    height: 40px;
    background: var(--accent);
    color: var(--bg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    border-radius: 8px;
    cursor: pointer;
    z-index: 9999;
    transition: background 0.3s;
}
#side-menu-button:hover {
    background: #ff5c5c;
}

/* Боковое меню */
#side-menu {
    position: fixed;
    top: 0;
    left: -200px; /* скрыто за экраном */
    width: 200px;
    height: 100%;
    background: var(--card);
    padding: 60px 10px 10px 10px;
    box-shadow: 2px 0 10px rgba(0,0,0,0.5);
    display: flex;
    flex-direction: column;
    gap: 10px;
    transition: left 0.3s ease;
    z-index: 9998;
}

/* Кнопки меню */
.menu-btn {
    display: block;
    padding: 10px 15px;
    background: var(--accent);
    color: var(--bg);
    text-decoration: none;
    border-radius: 8px;
    text-align: center;
    font-weight: bold;
    transition: background 0.3s;
}
.menu-btn:hover {
    background: #ff5c5c;
}

/* Класс для открытия меню */
#side-menu.open {
    left: 0;
}
