/* Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Open Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background-color: #1a1a1a;
    color: #333;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

/* Container Principal */
.quiz-container {
    width: 100%;
    max-width: 600px;
    position: relative;
}

/* Telas */
.quiz-screen {
    display: none;
    animation: fadeIn 0.5s ease;
}

.quiz-screen.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Card do Quiz */
.quiz-card {
    background-color: #fff;
    border-radius: 16px;
    padding: 40px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.result-card {
    text-align: center;
}

/* Logo */
.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 30px;
}

.logo img {
    height: 38px;
    width: auto;
    object-fit: contain;
}

/* Hero Image */
.hero-image {
    width: 100%;
    height: 200px;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 30px;
}

.hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Título */
.quiz-title {
    font-size: 32px;
    font-weight: 800;
    color: #333;
    text-align: center;
    margin-bottom: 20px;
}

/* CTA Box */
.cta-box {
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    border-radius: 12px;
    padding: 16px 24px;
    margin-bottom: 30px;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
}

.cta-text {
    font-size: 16px;
    font-weight: 700;
    color: #1a1a1a;
    text-align: center;
}

/* Instruções */
.instructions {
    margin-bottom: 30px;
}

.instructions-title {
    font-size: 18px;
    font-weight: 700;
    color: #333;
    margin-bottom: 16px;
}

.instructions-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.instructions-list li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    font-size: 14px;
    line-height: 1.6;
    color: #666;
}

.check-icon {
    flex-shrink: 0;
    margin-top: 2px;
}

/* Botão Iniciar */
.btn-start {
    width: 100%;
    padding: 18px 24px;
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    color: #1a1a1a;
    border: none;
    border-radius: 12px;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
}

.btn-start:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(245, 158, 11, 0.4);
}

/* Progress Section */
.progress-section {
    margin-bottom: 30px;
}

.progress-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.question-number {
    display: flex;
    align-items: center;
    gap: 12px;
}

.number-badge {
    width: 40px;
    height: 40px;
    background-color: #f3f4f6;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-weight: 800;
    color: #333;
}

.question-number .label,
.discount-indicator .label {
    font-size: 11px;
    color: #999;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: block;
}

.question-number .count {
    font-size: 14px;
    font-weight: 700;
    color: #333;
}

.discount-indicator {
    text-align: right;
}

.discount-value {
    display: block;
    font-size: 24px;
    font-weight: 800;
    color: #10b981;
}

/* Progress Bar */
.progress-bar {
    width: 100%;
    height: 8px;
    background-color: #e5e7eb;
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #10b981 0%, #059669 100%);
    width: 0%;
    transition: width 0.5s ease;
}

/* Question Container */
.question-container {
    margin-bottom: 30px;
}

.question-text {
    font-size: 20px;
    font-weight: 700;
    color: #333;
    line-height: 1.5;
    margin-bottom: 24px;
}

/* Answers List */
.answers-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.answer-option {
    width: 100%;
    padding: 16px 20px;
    background-color: #fff;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 500;
    color: #333;
    text-align: left;
    cursor: pointer;
    transition: all 0.3s ease;
}

.answer-option:hover {
    border-color: #d1d5db;
    background-color: #f9fafb;
}

.answer-option.selected {
    border-color: #10b981;
    background-color: #ecfdf5;
    font-weight: 600;
}

.answer-option.correct {
    border-color: #10b981;
    background-color: #d1fae5;
    position: relative;
}

.answer-option.correct::after {
    content: '✓';
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 24px;
    background-color: #10b981;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 700;
}

.answer-option.incorrect {
    border-color: #ef4444;
    background-color: #fee2e2;
    position: relative;
}

.answer-option.disabled {
    pointer-events: none;
    opacity: 0.6;
}

/* Botão Next */
.btn-next {
    width: 100%;
    padding: 16px 24px;
    background-color: #1a1a1a;
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.btn-next:hover:not(:disabled) {
    background-color: #333;
}

.btn-next:disabled {
    background-color: #d1d5db;
    color: #9ca3af;
    cursor: not-allowed;
}

/* Result Screen */
.result-title {
    font-size: 36px;
    font-weight: 800;
    color: #333;
    margin-bottom: 12px;
}

.result-subtitle {
    font-size: 16px;
    color: #666;
    margin-bottom: 20px;
}

.result-discount {
    font-size: 96px;
    font-weight: 900;
    color: #10b981;
    line-height: 1;
    margin-bottom: 20px;
}

.result-text {
    font-size: 20px;
    font-weight: 700;
    color: #333;
    margin-bottom: 12px;
}

.result-description {
    font-size: 14px;
    color: #666;
    margin-bottom: 30px;
    line-height: 1.6;
}

.btn-claim {
    width: 100%;
    padding: 18px 24px;
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    color: #1a1a1a;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    margin-bottom: 12px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
}

.btn-claim:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(245, 158, 11, 0.4);
}

.btn-retry {
    width: 100%;
    padding: 16px 24px;
    background-color: #fff;
    color: #333;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-retry:hover {
    border-color: #d1d5db;
    background-color: #f9fafb;
}

/* Modal */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.6);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 20px;
}

.modal-overlay.active {
    display: flex;
    animation: fadeIn 0.3s ease;
}

.modal {
    background-color: #fff;
    border-radius: 16px;
    padding: 40px;
    max-width: 460px;
    width: 100%;
    position: relative;
    text-align: center;
    animation: scaleIn 0.3s ease;
}

@keyframes scaleIn {
    from {
        transform: scale(0.9);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    color: #9ca3af;
    transition: color 0.3s ease;
}

.modal-close:hover {
    color: #333;
}

.modal-icon {
    margin-bottom: 20px;
}

.modal-title {
    font-size: 24px;
    font-weight: 700;
    color: #333;
    margin-bottom: 16px;
}

.modal-text {
    font-size: 15px;
    color: #666;
    line-height: 1.6;
    margin-bottom: 30px;
}

.btn-try-again {
    width: 100%;
    padding: 16px 24px;
    background-color: #1a1a1a;
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.btn-try-again:hover {
    background-color: #333;
}

/* Modal de Sucesso */
.modal-success {
    background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
    border: 3px solid #fbbf24;
    padding: 50px 40px;
}

.success-animation {
    position: relative;
    margin-bottom: 30px;
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.success-circle {
    animation: scaleIn 0.5s ease, pulse 2s ease infinite 1s;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.checkmark {
    stroke-dasharray: 70;
    stroke-dashoffset: 70;
    animation: drawCheck 0.8s ease-in-out 0.3s forwards;
}

@keyframes drawCheck {
    to {
        stroke-dashoffset: 0;
    }
}

/* Confetti Animation */
.confetti {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
}

.confetti-piece {
    position: absolute;
    width: 10px;
    height: 10px;
    background: #fbbf24;
    opacity: 0;
    animation: confettiFall 2s ease-out forwards;
}

.confetti-piece:nth-child(1) {
    left: 20%;
    background: #fbbf24;
    animation-delay: 0.1s;
}

.confetti-piece:nth-child(2) {
    left: 40%;
    background: #f59e0b;
    animation-delay: 0.2s;
    transform: rotate(45deg);
}

.confetti-piece:nth-child(3) {
    left: 60%;
    background: #fbbf24;
    animation-delay: 0.3s;
}

.confetti-piece:nth-child(4) {
    left: 80%;
    background: #f59e0b;
    animation-delay: 0.15s;
    transform: rotate(45deg);
}

.confetti-piece:nth-child(5) {
    left: 30%;
    background: #fbbf24;
    animation-delay: 0.25s;
}

.confetti-piece:nth-child(6) {
    left: 70%;
    background: #f59e0b;
    animation-delay: 0.35s;
    transform: rotate(45deg);
}

@keyframes confettiFall {
    0% {
        top: -10%;
        opacity: 1;
        transform: translateY(0) rotate(0deg);
    }
    100% {
        top: 100%;
        opacity: 0;
        transform: translateY(0) rotate(720deg);
    }
}

.modal-title-success {
    color: #f59e0b;
    font-size: 32px;
    margin-bottom: 16px;
}

.modal-text-success {
    font-size: 18px;
    color: #92400e;
    margin-bottom: 12px;
}

.modal-text-success strong {
    color: #f59e0b;
    font-size: 24px;
    font-weight: 800;
}

.modal-subtext {
    font-size: 14px;
    color: #78350f;
    margin-bottom: 30px;
}

.btn-success {
    width: 100%;
    padding: 18px 24px;
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
    color: #1a1a1a;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(245, 158, 11, 0.4);
}

.btn-success svg {
    flex-shrink: 0;
}

/* Responsive */
@media (max-width: 640px) {
    .logo img {
        height: 28px;
    }

    .quiz-card {
        padding: 30px 20px;
    }

    .quiz-title {
        font-size: 26px;
    }

    .question-text {
        font-size: 18px;
    }

    .result-title {
        font-size: 28px;
    }

    .result-discount {
        font-size: 72px;
    }

    .modal {
        padding: 30px 20px;
    }
    
    .modal-success {
        padding: 40px 20px;
    }
    
    .modal-title-success {
        font-size: 26px;
    }
    
    .modal-text-success strong {
        font-size: 20px;
    }

    .hero-image {
        height: 160px;
    }
}

@media (max-width: 480px) {
    .logo img {
        height: 22px;
    }

    body {
        padding: 10px;
    }

    .quiz-card {
        padding: 24px 16px;
    }

    .quiz-title {
        font-size: 22px;
    }

    .cta-text {
        font-size: 14px;
    }

    .question-text {
        font-size: 16px;
    }

    .answer-option {
        padding: 14px 16px;
        font-size: 14px;
    }

    .result-discount {
        font-size: 64px;
    }
    
    .modal-success {
        padding: 30px 16px;
    }
    
    .success-animation {
        height: 80px;
    }
    
    .success-circle svg {
        width: 60px;
        height: 60px;
    }
    
    .modal-title-success {
        font-size: 24px;
    }
    
    .modal-text-success {
        font-size: 16px;
    }
    
    .modal-text-success strong {
        font-size: 18px;
    }
    
    .modal-subtext {
        font-size: 13px;
    }
    
    .btn-success {
        padding: 16px 20px;
        font-size: 15px;
    }
}

