/* Сброс и базовые стили */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Roboto', sans-serif;
}

body {
    background-color: #0f0f1a;
    color: #f0f0f0;
    line-height: 1.6;
    padding: 10px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    background-color: #1a1a2e;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

/* Шапка с баннером и аватаром */
.header {
    position: relative;
}

.banner {
    width: 100%;
    height: 300px;
    overflow: hidden;
}

#banner-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile {
    display: flex;
    align-items: center;
    padding: 0 40px 30px;
    margin-top: -75px; /* Сдвигаем вверх, чтобы аватар налезал на баннер */
}

.avatar-container {
    margin-right: 30px;
    z-index: 2;
}

.avatar {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    border: 5px solid #1a1a2e;
    object-fit: cover;
    background-color: #333;
}

.profile-info {
    flex-grow: 1;
}

.channel-name {
    font-size: 2.5rem;
    margin-bottom: 10px;
    color: #ffffff;
}

.subs-count {
    font-size: 1.1rem;
    color: #aaa;
    margin-bottom: 15px;
}

.subs-count i {
    color: #9147ff; /* Фиолетовый, как у Twitch */
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: #333;
    border-radius: 50%;
    color: white;
    font-size: 1.2rem;
    text-decoration: none;
    transition: all 0.3s ease;
}

.social-link:hover {
    transform: translateY(-3px);
    background-color: #9147ff;
}

/* Вкладки */
.tabs {
    display: flex;
    background-color: #252547;
    border-bottom: 2px solid #0f0f1a;
}

.tab-btn {
    flex: 1;
    padding: 18px;
    background: none;
    border: none;
    color: #ccc;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.tab-btn:hover {
    background-color: #333366;
    color: white;
}

.tab-btn.active {
    background-color: #0f0f1a;
    color: #9147ff;
    font-weight: bold;
    border-bottom: 3px solid #9147ff;
}

/* Контент вкладок */
.content {
    padding: 40px;
    min-height: 500px;
}

.tab-content {
    display: none;
    animation: fadeIn 0.5s;
}

.tab-content.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.tab-content h2 {
    margin-bottom: 25px;
    color: #ffffff;
    border-bottom: 2px solid #333366;
    padding-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Сетка видео */
.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
}

.video-item {
    background-color: #252547;
    border-radius: 10px;
    overflow: hidden;
    transition: transform 0.3s;
}

.video-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(145, 71, 255, 0.3);
}

.video-item a {
    text-decoration: none;
    color: inherit;
    display: block;
}

.video-item img {
    width: 100%;
    height: 180px;
    object-fit: cover;
}

.video-item h3 {
    padding: 15px 15px 5px;
    font-size: 1.1rem;
    color: #f0f0f0;
}

.video-date {
    padding: 0 15px 15px;
    color: #aaa;
    font-size: 0.9rem;
}

/* Стили для вкладки стримов */
.stream-info p {
    margin-bottom: 20px;
    font-size: 1.1rem;
}

.stream-embed {
    margin: 25px 0;
    position: relative;
    padding-bottom: 56.25%; /* Соотношение сторон 16:9 */
    height: 0;
    overflow: hidden;
    max-width: 100%;
    background: #000;
    border-radius: 10px;
}

.stream-embed iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

.schedule {
    background-color: #252547;
    padding: 20px;
    border-radius: 10px;
    margin-top: 30px;
}

.schedule h3 {
    margin-bottom: 15px;
    color: #9147ff;
}

.schedule ul {
    list-style-type: none;
}

.schedule li {
    padding: 8px 0;
    border-bottom: 1px dashed #444;
}

/* Стили для "О канале" */
.about-content {
    background-color: #252547;
    padding: 25px;
    border-radius: 10px;
}

.about-content p, .about-content ul {
    margin-bottom: 15px;
}

.about-content h3 {
    color: #9147ff;
    margin-top: 25px;
    margin-bottom: 10px;
}

.about-content a {
    color: #6ea0ff;
    text-decoration: none;
}

.about-content a:hover {
    text-decoration: underline;
}

.about-content ul {
    padding-left: 20px;
}

.about-content li {
    margin-bottom: 8px;
}

/* Футер */
.footer {
    text-align: center;
    padding: 25px;
    background-color: #0f0f1a;
    color: #777;
    font-size: 0.9rem;
    border-top: 1px solid #333;
}

.footer p {
    margin-bottom: 5px;
}

/* Адаптивность */
@media (max-width: 768px) {
    .profile {
        flex-direction: column;
        text-align: center;
        margin-top: -60px;
        padding-bottom: 20px;
    }

    .avatar-container {
        margin-right: 0;
        margin-bottom: 15px;
    }

    .avatar {
        width: 120px;
        height: 120px;
    }

    .channel-name {
        font-size: 2rem;
    }

    .tabs {
        flex-direction: column;
    }

    .video-grid {
        grid-template-columns: 1fr;
    }

    .content {
        padding: 25px;
    }
}

/* Стили для вкладки стримов */
#streams-tab .video-grid {
    margin-bottom: 40px;
    border-bottom: 2px solid #3a3a3a;
    padding-bottom: 30px;
}

/* Бейдж для стримов */
.stream-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: linear-gradient(135deg, #ff0000, #ff6b6b);
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: bold;
    display: flex;
    align-items: center;
    gap: 5px;
    z-index: 2;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
}

.stream-badge i {
    font-size: 10px;
}

/* Сообщение об отсутствии контента */
.no-content {
    text-align: center;
    padding: 40px;
    color: #888;
    grid-column: 1 / -1;
}

.no-content i {
    font-size: 48px;
    margin-bottom: 20px;
    color: #555;
}

.no-content p {
    margin: 10px 0;
}

/* Информация о видео под миниатюрой */
.video-info {
    padding: 15px;
}

.video-info h3 {
    margin-bottom: 8px;
    line-height: 1.3;
}

.video-date {
    color: #aaa;
    font-size: 14px;
    margin-top: 5px;
}

.video-link {
    display: block;
    text-decoration: none;
    color: inherit;
    height: 100%;
    background: #2a2a2a;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
}

.video-link:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(255, 0, 0, 0.2);
}

/* Адаптивность для вкладки стримов */
@media (max-width: 768px) {
    #streams-tab .video-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }

    .stream-badge {
        font-size: 10px;
        padding: 3px 8px;
    }
}