/* ============ БАЗА ============ */
* { margin: 0; padding: 0; }
*, *::before, *::after { box-sizing: border-box; }

body {
    font-family: "Amatic SC", sans-serif;
    font-weight: 400;
    font-style: normal;
    font-size: 25px;
    color: #fff;
    line-height: 1.6;
    background-color: #000;
}

.page { overflow: hidden; }

.container {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 10px;
}

/* ============ HEADER ============ */
.header {
    width: 100%;
    position: absolute;
    top: 0; left: 0; right: 0;
    z-index: 1000;
    background-color: #000;
}
.header.fixed {
    padding: 5px 0;
    background-color: #000;
    box-shadow: 0 5px 10px rgba(0,0,0,.3);
    position: fixed;
    transform: translate3d(0,0,0);
}
.header.active { background-color: #000; }

.header__inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.header__logo {
    font-size: 50px;
    font-weight: 700;
    color: #fff;
}

/* ============ NAV ============ */
nav {
    font-size: 28px;
    text-transform: uppercase;
}
nav.active { display: block; }

header nav ul { list-style: none; }
header nav ul li { display: inline-block; }
header nav ul li a {
    vertical-align: top;
    color: #fff;
    margin: 0 5px;
    text-decoration: none;
}
header nav ul li:not(.active):not(.btn) a:hover { color: #ef5414; }
header nav ul li.btn a {
    background: #ef5414;
    padding: 5px 10px;
    border-radius: 15px;
    transition: all 500ms ease;
}
header nav ul li.btn a:hover { background: #33691e; }
header nav ul li.active a { color: #ef5414; }

/* ============ BURGER ============ */
.nav-toggle {
    width: 30px;
    padding: 10px 0;
    display: none;
    font-size: 0;
    color: transparent;
    border: 0;
    background: none;
    cursor: pointer;
    position: absolute;
    top: 29px; right: 29px;
    z-index: 1;
}
.nav-toggle__item {
    display: block;
    width: 100%;
    height: 3px;
    background-color: #fff;
    position: absolute;
    top: 0; right: 0; bottom: 0; left: 0;
    margin: auto;
}
.nav-toggle__item::before,
.nav-toggle__item::after {
    content: "";
    width: 100%;
    height: 3px;
    background-color: #fff;
    position: absolute;
    left: 0;
    z-index: 1;
}
.nav-toggle__item::before { top: -8px; }
.nav-toggle__item::after  { bottom: -8px; }
.nav-toggle.active .nav-toggle__item { background: none; }
.nav-toggle.active .nav-toggle__item::before {
    transform-origin: left top;
    transform: rotate(45deg) translateX(-3px);
}
.nav-toggle.active .nav-toggle__item::after {
    transform-origin: left bottom;
    transform: rotate(-45deg) translateX(-3px);
}

/* ============ INTRO ============ */
.intro {
    width: auto;
    height: 100vh;
    background: url("/assets/img/intro_3840.jpg") center/cover no-repeat;
    position: relative;
    min-height: 600px;
}
.intro--info { padding-top: 20%; text-align: center; }
.intro--info h1 { font-size: 50px; font-weight: 700; }
.intro--info p { font-weight: 500; line-height: 170%; margin: 30px 0; }
.intro--info .btn {
    background: #ef5414;
    font-family: "Amatic SC", sans-serif;
    color: #fff;
    font-size: 40px;
    font-weight: 700;
    padding: 5px 10px;
    border: 0;
    border-radius: 15px;
    transition: all 500ms ease;
}
.intro--info .btn:hover { cursor: pointer; transform: scale(1.1); }

/* ============ ИНФО-СЕКЦИЯ ============ */
.info { background-color: #000; padding-top: 30px; }
.info img { width: 200px; }
.info h1 { margin: 0 auto; font-size: 50px; text-align: center; }
.info h3 { font-size: 25px; }
.info .info1,
.info .info2 {
    display: flex;
    justify-content: center;
    gap: 10%;
    width: 100%;
    padding-top: 35px;
}
.info .info1 h3,
.info .info2 h3 {
    display: block;
    text-align: center;
    margin-top: 10%;
}

/* ============ START ============ */
.start {
    background: url("/assets/img/start_3840.jpg") center/cover no-repeat;
    width: auto;
    padding: 5% 0;
}
.start .start1 {
    display: flex;
    justify-content: space-evenly;
    width: 100%;
    padding: 30px 0;
}
.start img { width: 150px; }
.start h1 { font-size: 50px; text-align: center; }
.start h3 { font-size: 25px; text-align: center; }
.start .start1 a {
    display: block;
    margin-top: 10%;
    padding: 3px 7px;
    font-size: 30px;
    font-weight: 700;
    color: #fff;
    background-color: rgba(239,84,20,0.5);
    border-radius: 15px;
    text-align: center;
    text-decoration: none;
    transition: all 0.5s ease;
}
.start .start1 a:hover { background-color: #ef5414; }

/* ============ НОВОСТИ / ПРЕМИУМ СЕТКИ ============ */
h1 { text-align: center; margin-bottom: 40px; }

.news-grid,
.prem-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
}
.news-card,
.prem-card {
    position: relative;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    width: 350px;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    padding-bottom: 60px;
}
.news-card img,
.prem-card img {
    width: 40%;
    height: auto;
    display: block;
    margin: 0 auto;
}
.news-content,
.prem-content { padding: 15px; }
.news-content h2,
.prem-content h2 { margin-top: 0; text-align: center; }
.news-content p,
.prem-content p { font-size: 25px; font-weight: 700; }

.read-more-btn {
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    padding: 3px 10px;
    background-color: rgba(239,84,20,0.8);
    color: white;
    border: none;
    border-radius: 15px;
    cursor: pointer;
    font-family: "Amatic SC", sans-serif;
    font-size: 35px;
    transition: all 0.5s ease;
}
.read-more-btn:hover { background-color: #ef5414; }

/* ============ INFO CARDS (info.php) ============ */
.info-grid1,
.info-grid2,
.info-grid3,
.info-grid4,
.info-grid5,
.info-grid6 {
    display: flex;
    justify-content: space-between;
    width: 100%;
    gap: 20px;
    margin-top: 20px;
}
.info-grid1 { margin-top: 100px; }
.info-card {
    position: relative;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    flex: 1 1 0;
    margin-bottom: 20px;
}
.info-card img {
    width: 10%;
    height: auto;
    display: block;
    margin: 0 auto;
}
.info-content { padding: 15px; }
.info-content h2 { margin-top: 0; text-align: center; }
.info-content p { font-size: 25px; font-weight: 700; }

/* ============ МОДАЛЬНЫЕ ОКНА ============ */
.modal {
    display: none; /* Скрыто по умолчанию, JS будет менять на flex */
    position: fixed; 
    z-index: 1000; 
    left: 0;
    top: 0;
    width: 100%; 
    height: 100%; 
    overflow: auto; 
    background-color: rgba(0,0,0,0.5); 
    /* Добавляем Flexbox для центрирования */
    align-items: center;
    justify-content: center;
}
.modal-content {
    background-color: #fff;
    padding: 20px;
    border-radius: 8px;
    width: 90%; /* Чуть уже, чтобы на телефонах были отступы */
    max-width: 500px;
    position: relative;
    text-align: center; /* Текст по центру */
    color: black;
    /* Убрали margin: 10% auto, теперь центрированием занимается .modal */
}
.modal img {
    width: 30%;
    height: auto;
    display: block;
    margin: 0 auto;
}
.modal form {
    display: flex;
    flex-direction: column;
    gap: 5px;
}
.modal .btn {
    padding: 3px 10px;
    background-color: rgba(239,84,20,0.8);
    color: white;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-family: "Amatic SC", sans-serif;
    font-size: 30px;
    transition: all 0.5s ease;
}
.modal .btn:hover { background-color: #ef5414; }
input[type="text"],
input[type="email"],
input[type="password"] {
    width: 100%;
    padding: 10px;
    margin-top: 5px;
    border: 1px solid #ccc;
    border-radius: 4px;
}
.close {
    color: #aaa;
    position: absolute;
    top: 10px; right: 20px;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}
.close:hover { color: black; }

/* ============ РЕГИСТРАЦИЯ ============ */
.back {
    width: auto;
    min-height: 100vh;
    overflow: hidden;
    background: url("/assets/img/reg2.jpg") center/cover no-repeat;
    position: relative;
    min-height: 600px;
}
.form-container {
    color: black;
    max-width: 400px;
    margin: 150px auto;
    background: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 0 20px rgba(0,0,0,0.1);
}
.form-container h2 { text-align: center; margin-bottom: 20px; }
.user label { margin-top: 15px; font-weight: 700; display: block; }
.error { color: red; font-size: 0.9em; margin-top: 5px; }
input[type="checkbox"] { display: inline-block; margin-right: 5px; }
.terms label { font-weight: 400; font-size: 20px; }
.terms label a { color: #ef5414; }
.form-container button {
    font-family: "Amatic SC", sans-serif;
    width: 100%;
    padding: 10px;
    background-color: rgba(239,84,20,0.8);
    color: white;
    border: none;
    border-radius: 10px;
    margin-top: 20px;
    font-size: 30px;
    cursor: pointer;
}
.form-container button:hover { background-color: #ef5414; }

/* ============ FOOTER ============ */
.down {
    clear: both;
    background-color: #000;
    padding-bottom: 1%;
}
.down .blocks,
.down nav {
    display: flex;
    align-items: center;
}
.down .blocks { justify-content: center; }
.down nav {
    justify-content: center;
    margin: 10px 0;
    text-transform: uppercase;
}
.down nav ul { list-style: none; padding-left: 0; }
.down nav ul li { display: inline-flex; }
.down nav ul li a {
    color: #fff;
    margin: 0 15px;
    text-decoration: none;
}
.down nav ul li.active a,
.down nav ul li:not(.active):not(.btn) a:hover { color: #ef5414; }
.down p { text-align: center; margin: 10px 0; }
.down .social-icons {
    display: flex;
    justify-content: center;
    margin-top: 10px;
}
.down .social-icons a { margin: 0 10px; }
.down .social-icons img {
    width: 40px;
    border-radius: 10px;
    transition: .5s transform;
}
.down .social-icons a:hover img { transform: scale(1.2); }
.down .down--logo {
    font-size: 50px;
    font-weight: 700;
    color: #fff;
    margin: 20px 0;
}





/* ============ АДАПТИВ ============ */
@media (min-width: 2560px) {
    .container { max-width: 2000px; padding-top: 5px; }
    .header nav { font-size: 50px; }
    .header__logo { font-size: 100px; }
    .news-card, .prem-card { width: 500px; }
    .news-card h2, .prem-card h2 { font-size: 70px; }
    .news-card p, .prem-card p { font-size: 40px; }
    .read-more-btn { font-size: 50px; }
    .modal-content { margin: 20% auto; max-width: 1000px; }
    .modal-content h2 { font-size: 70px; }
    .modal-content p { font-size: 45px; }
    .down .down--logo { font-size: 100px; }
    .down nav { font-size: 50px; }
    .down .social-icons img { width: 80px; }
    .down p { font-size: 50px; }
}

@media (min-width: 992px) and (max-width: 1199px) {
    .header nav { font-size: 28px; }
    .header__logo { font-size: 50px; }
}

@media (min-width: 481px) and (max-width: 767px) {
    .nav {
        display: none;
        width: 40%;
        position: absolute;
        top: 100%; right: 0;
        padding-bottom: 20px;
        background-color: #000;
        border-radius: 10px;
    }
    .nav li {
        display: block;
        font-size: 28px;
        text-align: center;
        margin: 0;
        padding: 5px 20px;
    }
    .nav-toggle { display: block; }
    .intro { min-height: 470px; }
    .intro--info { padding-top: 50%; }
    .info1, .info2 { flex-wrap: wrap; }
    .start { padding: 10% 0; }
    .start .start1 { flex-wrap: wrap; }
    .start h1 { font-size: 50px; }
    .start img { width: 120px; }
    .start .start1 a { font-size: 25px; }
    .down .menu, .down--logo { display: none; }
}

@media (max-width: 480px) {
    .header__logo { font-size: 45px; }
    .nav {
        display: none;
        width: 50%;
        position: absolute;
        top: 100%; right: 0;
        padding-bottom: 20px;
        background-color: #000;
        border-radius: 10px;
    }
    .nav li {
        display: block;
        font-size: 28px;
        text-align: center;
        margin: 0;
        padding: 5px 20px;
    }
    .nav-toggle { display: block; }
    .intro--info { padding-top: 60%; }
    .intro--info h1 { font-size: 35px; }
    .intro--info p { font-size: 25px; }
    .intro--info .btn { font-size: 25px; padding: 5px 10px; }
    .info h1 { font-size: 40px; }
    .info img { width: 150px; }
    .info h3 { font-size: 20px; padding-bottom: 30px; }
    .info1, .info2 { flex-wrap: wrap; }
    .start { padding: 10% 0; }
    .start .start1 { flex-wrap: wrap; }
    .start h1 { font-size: 50px; }
    .start img { width: 120px; }
    .start .start1 a { font-size: 25px; }
    .down .menu, .down--logo { display: none; }
}

/* ============ ЛИЧНЫЙ КАБИНЕТ ============ */
.account-section {
    padding-top: 120px;
    min-height: 80vh;
    padding-bottom: 50px;
}

.account-wrapper {
    max-width: 1000px; /* Увеличиваем ширину, чтобы 2 карточки влезли */
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr; /* Две колонки одинаковой ширины */
    gap: 30px; /* Расстояние между карточками */
}

/* Делаем так, чтобы блок "Вход в игру" всегда занимал обе колонки */
.full-width-card {
    grid-column: 1 / -1;
}

.account-card {
    background: #fff;
    color: #000;
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.account-card h2, 
.account-card h3 {
    text-align: center;
    margin-bottom: 20px;
    font-size: 35px;
}

.account-info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    font-size: 22px;
}

.account-info-grid p {
    margin: 0;
    padding: 10px;
    background: #f4f4f4;
    border-radius: 6px;
}

.account-actions {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 10px;
}

.btn-game {
    display: inline-block;
    padding: 10px 25px;
    background-color: #ef5414;
    color: #fff;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 700;
    font-size: 28px;
    transition: all 0.3s ease;
    text-align: center;
}

.btn-game:hover {
    background-color: #c94510;
    transform: scale(1.05);
}

.btn-logout {
    background-color: #333;
}
.btn-logout:hover {
    background-color: #111;
}

.download-text {
    text-align: center;
    font-size: 22px;
    margin-bottom: 20px;
}

/* Адаптив для кабинета */
@media (max-width: 768px) {
    .account-info-grid {
        grid-template-columns: 1fr;
    }
    .account-section {
        padding-top: 90px;
    }
    .account-wrapper {
        grid-template-columns: 1fr; /* На телефонах одна колонка */
    }
}

.account-card form input {
    font-family: "Amatic SC", sans-serif;
    font-size: 22px;
    width: 100%;
}

.account-card form label {
    font-weight: 700;
    margin-top: 5px;
}
.account-card button.btn-game {
    font-family: "Amatic SC", sans-serif;
    font-size: 30px;
    font-weight: 700;
}

/* Модальное окно смены пароля */
#passwordModal .modal-content {
    text-align: left;
    padding: 30px;
    max-width: 450px;
}

#passwordModal h2 {
    text-align: center;
    margin-bottom: 20px;
}

#passwordModal form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

#passwordModal input {
    font-family: "Amatic SC", sans-serif;
    font-size: 22px;
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    margin-top: 5px;
}

#passwordModal button.btn-game {
    font-family: "Amatic SC", sans-serif;
    font-size: 30px;
    margin-top: 15px;
    border: none;
    cursor: pointer;
}

#passwordModal .error-msg {
    background: #f8d7da;
    color: #721c24;
    padding: 10px;
    border-radius: 6px;
    margin-bottom: 15px;
    text-align: center;
}

#passwordModal .success-msg {
    background: #d4edda;
    color: #155724;
    padding: 10px;
    border-radius: 6px;
    margin-bottom: 15px;
    text-align: center;
}