/* Umumiy sozlamalar */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

body {
    min-height: 100vh;
    background: linear-gradient(135deg, #0a8f3c, #055a26);
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px; /* Mobil ekranlarda chetidan joy qolishi uchun */
    color: white;
}

/* Konteyner - barcha qurilmalar uchun moslashuvchan */
.app {
    width: 100%;
    max-width: 600px; /* Planshetlar uchun kengroq qildik */
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 24px;
    padding: 30px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.2);
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Progress Bar */
.top {
    width: 100%;
}

#counter {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    font-weight: 500;
    opacity: 0.9;
    text-align: right;
}

.progress {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    overflow: hidden;
}

#bar {
    height: 100%;
    width: 0%;
    background: #4ade80; /* Och yashil chiroyli rang */
    transition: width 0.4s ease-out;
}

/* Card qismi */
.card {
    display: flex;
    flex-direction: column;
}

#title {
    font-size: 18px;
    text-transform: uppercase;
    letter-spacing: 1px;
    opacity: 0.7;
    margin-bottom: 10px;
}

#question {
    font-size: 24px;
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 25px;
}

/* Javoblar tugmalari */
.answers {
    display: grid;
    grid-template-columns: 1fr; /* Default bir ustunli */
    gap: 12px;
}

.answers button {
    padding: 16px 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.05);
    color: white;
    font-size: 16px;
    text-align: left;
    cursor: pointer;
    transition: all 0.2s ease;
}

.answers button:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateX(5px);
}

.answers button.active {
    background: white;
    color: #055a26;
    font-weight: 700;
    border-color: white;
}

/* Next tugmasi */
#nextBtn {
    margin-top: 30px;
    padding: 16px;
    border: none;
    border-radius: 14px;
    background: #ffffff;
    color: #055a26;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.2s, background 0.2s;
}

#nextBtn:hover {
    background: #f0f0f0;
    transform: translateY(-2px);
}

#nextBtn:active {
    transform: translateY(0);
}

/* Natija qismi */
.result {
    text-align: center;
    padding: 40px 20px;
}

.hidden {
    display: none !important;
}

/* Restart tugmasi - natija oynasida chiqadi */
.restart {
    background-color: #4ade80; /* Jonliroq yashil */
    color: #11571f !important;
    text-decoration: none !important;
    padding: 14px 30px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 16px;
    width: fit-content;
    cursor: pointer;
    border: none;
    display: block;
    margin: 25px auto 0 auto;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(74, 222, 128, 0.3);
}

.restart:hover {
    background-color: #ffffff;
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(255, 255, 255, 0.2);
}

.restart:active {
    transform: scale(0.98);
}

/* Natija oynasi ichidagi matnlar uchun qo'shimcha stil */
.result h2 {
    font-size: 28px;
    margin-bottom: 10px;
}

.result p {
    font-size: 18px;
    opacity: 0.9;
    line-height: 1.5;
}

/* RESPONSIVE (Moslashuvchanlik) */

/* Planshetlar uchun (600px dan kattaroq) */
@media (min-width: 600px) {
    .app {
        padding: 40px;
    }
    
    #question {
        font-size: 28px;
    }

    /* Agar javoblar qisqa bo'lsa, 2 ustunli qilish mumkin */
    /* .answers { grid-template-columns: 1fr 1fr; } */
}

/* Kichik mobil telefonlar uchun */
@media (max-width: 400px) {
    .app {
        padding: 20px;
        border-radius: 15px;
    }

    #question {
        font-size: 20px;
    }

    .answers button {
        padding: 12px 15px;
        font-size: 15px;
    }
}