body {
    font-family: 'Poppins', sans-serif;
    margin: 0;
    padding: 20px;
    background: linear-gradient(135deg, #ffecd2 0%, #ffb6c1 50%, #ff9999 100%);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    color: #333;
}

.container {
    background: #fffaf0;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    max-width: 700px;
    width: 100%;
    text-align: center;
}

.profile-setup {
    animation: fadeIn 0.5s ease-in;
}

.profile-title {
    color: #4b0082;
    font-weight: 700;
    margin-bottom: 10px;
}

.profile-subtitle {
    color: #666;
    margin-bottom: 20px;
}

.profile-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.profile-input, .profile-select {
    padding: 12px;
    font-size: 16px;
    border-radius: 8px;
    border: 1px solid #ccc;
    outline: none;
    transition: border-color 0.3s;
}

.profile-input:focus, .profile-select:focus {
    border-color: #ff6f61;
}

.title {
    color: #4b0082;
    font-weight: 700;
    margin-bottom: 10px;
}

.subtitle {
    color: #666;
    margin-bottom: 20px;
}

.profile-stats {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 20px;
}

.stats-text {
    color: #333;
    font-size: 16px;
}

.badges {
    margin: 10px 0;
    font-size: 14px;
    color: #d97706;
}

.badge {
    display: inline-block;
    background: linear-gradient(135deg, #fef3c7, #fed7aa);
    padding: 5px 10px;
    margin: 5px;
    border-radius: 15px;
    font-weight: 600;
    color: #d97706;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.status {
    padding: 10px;
    border-radius: 8px;
    font-style: italic;
    margin-bottom: 20px;
    transition: background 0.3s, color 0.3s;
    background: #f3e8ff;
    color: #6b21a8;
}

.topic-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 20px;
}

.topic-select, .custom-topic-input, .question-number-select, .timer-settings-select {
    padding: 12px;
    font-size: 16px;
    border-radius: 8px;
    border: 1px solid #ccc;
    outline: none;
    transition: border-color 0.3s;
}

.topic-select:focus, .custom-topic-input:focus, .question-number-select:focus, .timer-settings-select:focus {
    border-color: #ff6f61;
}

.question-number-container, .timer-settings-container {
    margin-bottom: 20px;
}

.question-number-label, .timer-settings-label {
    color: #333;
    margin-right: 10px;
    font-size: 16px;
}

.timer-toggle-label {
    color: #333;
    font-size: 16px;
    margin-left: 15px;
}

.btn {
    padding: 12px 24px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 8px;
    border: none;
    background: #ff6f61;
    color: white;
    cursor: pointer;
    transition: background 0.3s, transform 0.1s;
}

.btn:hover {
    background: #f85149;
    transform: scale(1.05);
}

.btn:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
}

.btn-small {
    padding: 8px 16px;
    font-size: 14px;
}

.btn-lifeline {
    padding: 8px 16px;
    font-size: 14px;
    background: #ffb300;
    margin: 0 5px;
}

.btn-lifeline:disabled {
    background: #ccc;
}

.btn-next {
    margin-top: 20px;
}

.btn-share, .btn-save, .btn-remove {
    background: #55acee;
    margin: 10px 5px;
}

.btn-remove {
    background: #ff4d4f;
}

.btn-remove:hover {
    background: #e63946;
}

.quiz-frame {
    margin-top: 20px;
    padding: 20px;
    border-radius: 10px;
    background: #fef5e7;
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.05);
}

.question-text {
    color: #4b0082;
    font-weight: 600;
    margin-bottom: 15px;
}

.timer {
    font-size: 16px;
    color: #ff4d4f;
    font-weight: bold;
    margin-bottom: 15px;
}

#timeLeft {
    color: #ff4d4f;
}

.lifelines {
    margin-bottom: 15px;
}

.options-grid {
    display: grid;
    gap: 10px;
    margin-bottom: 15px;
}

.options-grid label {
    display: flex;
    align-items: center;
    padding: 12px;
    background: #fff;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    cursor: pointer;
    transition: border-color 0.3s, background 0.3s;
}

.options-grid label:hover {
    border-color: #ff6f61;
}

.options-grid input[type="radio"] {
    margin-right: 10px;
}

.options-grid .correct {
    background: #d4f4e2;
    border-color: #34c759;
}

.options-grid .incorrect {
    background: #ffe8e6;
    border-color: #ff4d4f;
}

.answer-feedback {
    font-size: 16px;
    font-weight: 600;
    margin-top: 10px;
}

.answer-feedback.correct {
    color: #34c759;
}

.answer-feedback.incorrect {
    color: #ff4d4f;
}

.additional-info {
    font-style: italic;
    color: #666;
    margin-top: 10px;
}

.result-box {
    margin-top: 20px;
    padding: 20px;
    background: #fff1f2;
    border-radius: 10px;
    font-size: 18px;
    color: #4b0082;
}

.status.correct {
    background: #d4f4e2;
    color: #15803d;
}

.status.incorrect {
    background: #ffe8e6;
    color: #b91c1c;
}

.status.topic-selected {
    background: #ffe4e6;
    color: #e11d48;
}

.spinner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    margin-top: 20px;
}

.loader {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #ff6f61;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.confetti-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1000;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
