@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;700&display=swap');

body {
    font-family: 'Roboto', sans-serif;
    background: linear-gradient(to bottom, #1a1a1a, #2c2c2c); /* Градиент для Dota-атмосферы */
    color: #e0e0e0;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    width: 100%;
    padding: 20px;
    box-sizing: border-box;
    text-align: center;
}

h1, h2, h3, h4, h5 {
    color: #4CAF50;
    margin-bottom: 20px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5); /* Тень для текста */
}

.buttons-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
    margin: 20px 0;
}

.main-button, .form-button, button, .link-button {
    background: linear-gradient(to bottom, #4CAF50, #388E3C);
    color: white;
    border: none;
    padding: 12px 24px;
    font-size: 1.1em;
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.3s;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
    display: inline-flex;
    align-items: center;
    gap: 8px; /* Для иконок */
}

.main-button:hover, .form-button:hover, button:hover, .link-button:hover {
    transform: scale(1.05) rotate(1deg); /* Лёгкая анимация */
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.7);
}

.main-button {
    display: inline-block;
    text-decoration: none;
}

.buttons-container a.main-button:nth-child(3) { /* Discord синий */
    background: linear-gradient(to bottom, #7289DA, #5A6FB4);
}
.buttons-container a.main-button:nth-child(4) { /* Boosty оранжевый */
    background: linear-gradient(to bottom, #FFA726, #FB8C00);
}

input[type="text"], input[type="number"], select {
    background-color: #2c2c2c;
    color: #e0e0e0;
    border: 1px solid #444;
    padding: 10px;
    border-radius: 5px;
    width: 100%;
    margin-bottom: 15px;
    box-sizing: border-box;
    transition: border-color 0.3s, box-shadow 0.3s;
}

input[type="text"]:focus, input[type="number"]:focus, select:focus {
    border-color: #4CAF50;
    box-shadow: 0 0 8px rgba(76, 175, 80, 0.5); /* Glow эффект */
}

.teams {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 20px;
}

.team {
    flex: 1 1 45%;
    background: linear-gradient(to bottom, #2c2c2c, #1e1e1e);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
}

table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    overflow-x: auto;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

th, td {
    padding: 12px;
    text-align: center;
    border: 1px solid #444;
}

th {
    background: linear-gradient(to bottom, #333, #222);
    color: #4CAF50;
}

tr:nth-child(even) {
    background-color: #2c2c2c;
}

tr:hover {
    background-color: #3a3a3a;
    transition: background-color 0.3s;
}

#broadcast-log, #match-results {
    background: linear-gradient(to bottom, #2c2c2c, #1e1e1e);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
    max-height: 500px;
    overflow-y: auto;
    margin-top: 20px;
    animation: fadeIn 0.5s ease-in;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Стили для модалки */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.8); /* Затемнение фона */
    justify-content: center;
    align-items: center;
}

.modal-content {
    background: linear-gradient(to bottom, #1e1e1e, #2c2c2c);
    margin: auto;
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 8px 16px rgba(0,0,0,0.7);
    width: 80%;
    max-width: 800px;
    animation: modalFadeIn 0.3s;
}

.modal-title {
    color: #4CAF50;
    text-align: center;
    font-size: 1.5em;
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close:hover,
.close:focus {
    color: #fff;
    text-decoration: none;
}

@keyframes modalFadeIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

/* Responsive */
@media (max-width: 768px) {
    .teams { flex-direction: column; }
    .team { flex: 1 1 100%; }
    .main-button, .form-button { width: 100%; }
}

.snowflake {
    position: fixed;
    top: -10px;
    font-size: 1.2em;
    color: white;
    animation: fall 5s linear infinite;
    z-index: 1000;
}

@keyframes fall {
    0% {
        transform: translateY(-10px) translateX(0);
    }
    100% {
        transform: translateY(100vh) translateX(50px);
    }
}

.christmas-theme button,
.christmas-theme .link-button {
    background-color: #4caef5;
}

.christmas-theme button:hover,
.christmas-theme .link-button:hover {
    background-color: #3a92d4;
}

.garland {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100px;
    pointer-events: none;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.garland .light {
    width: 15px;
    height: 15px;
    background-color: red;
    border-radius: 50%;
    box-shadow: 0 0 15px red;
    animation: blink 1.5s infinite;
    position: relative;
}

.garland .light:nth-child(2) {
    background-color: green;
    box-shadow: 0 0 15px green;
    animation-delay: 0.3s;
}

.garland .light:nth-child(3) {
    background-color: blue;
    box-shadow: 0 0 15px blue;
    animation-delay: 0.6s;
}

.garland .light:nth-child(4) {
    background-color: yellow;
    box-shadow: 0 0 15px yellow;
    animation-delay: 0.9s;
}

.garland .light:nth-child(5) {
    background-color: pink;
    box-shadow: 0 0 15px pink;
    animation-delay: 1.2s;
}

@keyframes blink {
    0%, 100% {
        opacity: 0.8;
    }
    50% {
        opacity: 1;
    }
}

.christmas-only {
    display: flex;
    opacity: 0;
    transform: translateY(-20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.christmas-theme .christmas-only {
    opacity: 1;
    transform: translateY(0);
}

button, .link-button {
    transition: background-color 0.5s ease;
}


.main-button {
    display: inline-block; /* Для <a> чтобы они вели себя как кнопки */
    text-decoration: none; /* Убрать подчеркивание у ссылок */
}

/* Стили для логотипов в модальном окне */
.team-logo {
    width: 80px; /* Уменьшаем размер до 50x50px */
    height: 80px;
    vertical-align: middle;
    margin-right: 10px;
    border-radius: 5px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    object-fit: cover; /* Обрезает или масштабирует изображение, сохраняя пропорции */
}

.team-info {
    display: flex;
    align-items: center;
    margin: 10px 0;
    font-size: 1.2em;
    color: #4CAF50; /* Зеленый акцент */
}

.modal-content {
    background: linear-gradient(to bottom, #1e1e1e, #2c2c2c);
    margin: auto;
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.7);
    width: 80%;
    max-width: 800px;
    animation: modalFadeIn 0.3s;
    text-align: center; /* Центрирование текста */
}

.modal-title {
    color: #4CAF50;
    text-align: center;
    font-size: 1.5em;
    margin-bottom: 15px;
}