body{
    margin:0;
    background:#181818;
    color:#fff;
    font-family:Arial,sans-serif;
}

.box{
    max-width:420px;
    margin:30px auto;
    background:#222;
    padding:20px;
    border-radius:12px;
}

input{
    width:100%;
    box-sizing:border-box;
    padding:12px;
    margin:8px 0;
    border:none;
    border-radius:8px;
}

button{
    width:100%;
    padding:12px;
    background:#2f80ed;
    color:#fff;
    border:none;
    border-radius:8px;
    font-size:16px;
    cursor:pointer;
}

button:hover{
    background:#1669d8;
}

.error{
    background:#8b1e1e;
    padding:10px;
    border-radius:8px;
    margin-bottom:10px;
}

a{
    color:#66b3ff;
    text-decoration:none;
}

.good{

background:#2ecc71;

margin-bottom:15px;

}

.evil{

background:#c0392b;

}

.menu{

display:block;

background:#2f80ed;

padding:14px;

margin:8px 0;

text-align:center;

color:#fff;

text-decoration:none;

border-radius:10px;

font-size:18px;

}

.menu:hover{

background:#1565c0;

}
body.home{

background:#101010;

color:white;

}

.home-box{

max-width:460px;

margin:20px auto;

padding:20px;

}

.subtitle{

text-align:center;

font-size:18px;

margin:20px 0;

color:#ccc;

}

.banner{

background:#222;

padding:20px;

border-radius:12px;

line-height:32px;

margin-bottom:20px;

}

.big-btn{

display:block;

background:#f39c12;

padding:18px;

text-align:center;

font-size:22px;

color:white;

text-decoration:none;

border-radius:12px;

margin-bottom:15px;

font-weight:bold;

}

.big-btn:hover{

background:#d68910;

}

.news{

margin-top:25px;

background:#222;

padding:15px;

border-radius:12px;

}

.news-item{

padding:10px 0;

border-bottom:1px solid #333;

}

.news-item:last-child{

border-bottom:none;

}

.footer{

text-align:center;

margin-top:20px;

color:#777;

font-size:13px;

}

.hp{

height:22px;

background:#444;

border-radius:12px;

overflow:hidden;

margin-bottom:15px;

}

.hpfill{

height:100%;

background:#27ae60;

}

.monster{

background:#e74c3c;

}

.item{

background:#333;

padding:15px;

margin:10px 0;


border-radius:10px;

}
.common{
    color:#ffffff;
}

.uncommon{
    color:#4caf50;
}

.rare{
    color:#2196f3;
}

.epic{
    color:#9c27b0;
}

.legendary{
    color:#ff9800;
    font-weight:bold;
}

.green{

background:#2ecc71;

}

.red{

background:#e74c3c;

}

/* =========================
   БАЗА (десктоп)
========================= */

body{
    margin:0;
    padding:0;
}

/* контейнеры */
.box{
    width:95%;
    max-width:900px;
    margin:20px auto;
}

/* карточки */
.card, .block, .item{
    box-sizing:border-box;
}

/* кнопки */
a, button{
    font-size:14px;
}

/* =========================
   ПЛАНШЕТЫ
========================= */

@media (max-width: 768px){

    .box{
        width:95%;
        margin:10px auto;
    }

    h1,h2,h3{
        font-size:18px;
    }

    .item{
        padding:8px;
    }

    a, button{
        font-size:13px;
        padding:8px;
    }
}

/* =========================
   ТЕЛЕФОНЫ
========================= */

@media (max-width: 480px){

    body{
        font-size:14px;
    }

    .box{
        width:100%;
        margin:0;
        padding:10px;
    }

    .card, .block, .item{
        border-radius:8px;
        padding:10px;
    }

    h1,h2,h3{
        font-size:16px;
    }

    /* кнопки на всю ширину */
    a, button{
        width:100%;
        display:block;
        font-size:14px;
        padding:10px;
    }

    /* инвентарь — вертикальный вид */
    .item{
        margin-bottom:10px;
    }

}

/* =========================
   ОЧЕНЬ МАЛЕНЬКИЕ ЭКРАНЫ
========================= */

@media (max-width: 360px){

    body{
        font-size:13px;
    }

    h2{
        font-size:15px;
    }

    a, button{
        font-size:13px;
        padding:9px;
    }
}
body{
    padding-bottom:70px; /* место под меню */
}

/* =========================
   НИЖНЯЯ ПАНЕЛЬ
========================= */

.mobile-bar{
    position:fixed;
    bottom:0;
    left:0;
    width:100%;
    height:60px;
    background:#1a1a1a;
    display:flex;
    justify-content:space-around;
    align-items:center;
    border-top:1px solid #333;
    z-index:9999;
}

/* кнопки меню */
.mobile-bar a{
    color:#fff;
    text-decoration:none;
    font-size:22px;
    flex:1;
    text-align:center;
    padding:10px 0;
}

/* активный эффект */
.mobile-bar a:active{
    background:#333;
}

/* =========================
   КАРТОЧКИ КАК В ИГРЕ
========================= */

.card, .block, .item{
    border-radius:12px;
    background:#222;
    box-shadow:0 0 10px rgba(0,0,0,0.3);
}

/* =========================
   КНОПКИ КАК В RPG
========================= */

a, button{
    border-radius:10px;
    font-weight:bold;
}

/* зелёная кнопка (основная) */
.green{
    background:#2ecc71 !important;
}

/* красная */
.red{
    background:#e74c3c !important;
}

/* синяя */
.blue{
    background:#3498db !important;
}

/* =========================
   МОБИЛЬНАЯ АДАПТАЦИЯ
========================= */

@media (max-width: 480px){

    .item{
        font-size:14px;
    }

    .mobile-bar a{
        font-size:20px;
    }
}

/* =========================
   ОБЩИЙ ФОН ИГРЫ
========================= */

body{
    background:#0f0f0f;
    color:#fff;
    font-family:Arial;
    margin:0;
    padding:0;
}

/* =========================
   КАРТОЧКИ
========================= */

.card{
    background:#1c1c1c;
    margin:10px;
    padding:12px;
    border-radius:14px;
    box-shadow:0 0 10px rgba(0,0,0,0.4);
}

/* =========================
   HP БАР
========================= */

.bar{
    width:100%;
    height:14px;
    background:#333;
    border-radius:10px;
    overflow:hidden;
    margin-top:5px;
}

.hp{
    height:100%;
    background:#e74c3c;
    transition:0.3s;
}

/* =========================
   КНОПКИ БОЯ
========================= */

.actions{
    position:fixed;
    bottom:70px;
    width:100%;
    display:flex;
    gap:6px;
    padding:8px;
    box-sizing:border-box;
}

.actions button{
    flex:1;
    padding:14px;
    border:none;
    border-radius:12px;
    color:#fff;
    font-weight:bold;
    font-size:14px;
}

.atk{background:#e74c3c;}
.skill{background:#9b59b6;}
.heal{background:#2ecc71;}

/* =========================
   ЛОГ БОЯ
========================= */

.log{
    font-size:12px;
    color:#aaa;
    height:120px;
    overflow:auto;
}

/* =========================
   ТЕКСТЫ
========================= */

h2,h3{
    margin:5px 0;
}

