:root {
    --green: #58cc02;
    --green-shadow: #46a302;
    --blue: #1cb0f6;
    --blue-shadow: #1899d6;
    --red: #ff4b4b;
    --gray: #e5e5e5;
    --text-dark: #3c3c3c;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f7f7f7;
    margin: 0;
    color: var(--text-dark);
}

.navbar {
    background: white;
    border-bottom: 2px solid var(--gray);
    padding: 15px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar .logo {
    font-size: 24px;
    font-weight: bold;
    color: var(--green);
    text-decoration: none;
}

.stats {
    display: flex;
    gap: 20px;
    font-weight: bold;
}

.container {
    max-width: 700px;
    margin: 40px auto;
    padding: 0 20px;
}

/* Card bài học */
.lesson-card {
    background: white;
    border: 2px solid var(--gray);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.btn-start {
    background: var(--green);
    color: white;
    border: none;
    border-bottom: 4px solid var(--green-shadow);
    padding: 10px 20px;
    border-radius: 12px;
    font-weight: bold;
    cursor: pointer;
    text-decoration: none;
}

.btn-start:active {
    transform: translateY(2px);
    border-bottom-width: 2px;
}

/* Giao diện Quiz */
.quiz-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 30px;
}

.progress-bar-container {
    flex-grow: 1;
    height: 16px;
    background-color: var(--gray);
    border-radius: 10px;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    width: 0%;
    background-color: var(--green);
    transition: width 0.3s;
}

.btn-option {
    display: block;
    width: 100%;
    padding: 15px;
    margin: 10px 0;
    border: 2px solid var(--gray);
    border-bottom: 4px solid var(--gray);
    border-radius: 12px;
    background: white;
    font-size: 16px;
    cursor: pointer;
    text-align: left;
}

.btn-option.selected {
    border-color: var(--blue);
    background: #ddf4ff;
}

.word-chip {
    display: inline-block;
    padding: 10px 15px;
    margin: 5px;
    border: 2px solid var(--gray);
    border-bottom: 4px solid var(--gray);
    border-radius: 12px;
    cursor: pointer;
    background: white;
    font-weight: bold;
}

.word-chip.used {
    opacity: 0.2;
    cursor: default;
}

.answer-box {
    min-height: 50px;
    border-bottom: 2px solid #ccc;
    margin-bottom: 20px;
    padding: 10px;
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.ai-box {
    background: #eef9ff;
    border: 1px solid var(--blue);
    border-radius: 12px;
    padding: 15px;
    margin-top: 15px;
    display: none;
}