/* Estilos gerais do quiz */
.wild-quiz {
    background: var(--e-global-color-background, #fff);
    border-radius: 12px;
    box-shadow: 0 0 15px rgba(0,0,0,0.08);
    max-width: 600px;
    margin: 40px auto;
    font-family: var(--e-global-typography-primary-font-family, sans-serif);
    color: var(--e-global-color-text, #222);
    transition: all 0.3s ease;
}

.question-block {
    margin-bottom: 25px;
    background: #ffffff;
    border: 1px solid #eee;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    padding: 15px;
}

.question-title {
    color: var(--e-global-color-input-text, #222);
    font-size: var(--e-global-typography-text-font-size, 18px);
    font-weight: 600;
    margin-bottom: 10px;
}

.response-msg {
    margin-top: 6px;
    font-size: 14px;
    font-style: italic;
    color: var(--e-global-color-danger, #f2622e); /* Para mensagens de erro */
}

#quiz-result {
    margin-top: 30px;
    background: var(--e-global-color-secondary, #f9f9f9);
    color: var(--e-global-color-text, #222);
    border-radius: 10px;
    box-shadow: inset 0 0 5px rgba(0,0,0,0.05);
}

/* Aplicar cor dinâmica ao resultado e reward, sobrescrito inline pelo PHP se existir */
#result-text, #final-reward {
    color: black!important;
    background: var(--woq-result-bg-color, #f2f2f2) !important;
    border-radius: 7px;
    padding: 12px 15px;
    font-weight: bold;
    margin-bottom: 18px;
    font-size: 1.1em;
    text-align: center;
}

#user-form input,
#user-form button {
    display: block;
    margin: 12px 0;
    padding: 12px 16px;
    width: 100%;
    max-width: 450px;
    border-radius: 6px;
    border: 1px solid var(--e-global-color-border, #ccc);
    font-size: var(--e-global-typography-text-font-size, 16px);
    color: black!important;
    background: var(--woq-input-bg-color, #fff);
}

#user-form input:focus {
    border-color: var(--e-global-color-primary, #bf2a2a);
    outline: none;
}

/* BOTÕES PRINCIPAIS DO QUIZ - Estilo base, cor será sobrescrita inline pelo PHP */
#user-form button,
#submit-quiz,
.wild-quiz .quiz-submit-btn,
.wild-quiz .elementor-button {
    background-color: var(--e-global-color-primary, #bf2a2a); /* Fallback */
    color: #fff;
    border: none;
    cursor: pointer;
    font-weight: bold;
    border-radius: 6px;
    text-transform: uppercase;
    padding: 12px 22px;
    transition: background 0.3s, color 0.3s;
    font-size: 16px;
    margin-top: 10px;
}
#user-form button:hover,
#submit-quiz:hover,
.wild-quiz .quiz-submit-btn:hover,
.wild-quiz .elementor-button:hover {
    background-color: var(--e-global-color-accent, #f2622e);
}

/* Botão do call to action (ex: Google Review) - estilo base, cor é inline */
.wild-cta button,
#cta-message button,
#google-review {
    background-color: var(--e-global-color-primary, #008ec2);
    color: #fff;
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    font-weight: bold;
    cursor: pointer;
    margin-top: 15px;
    transition: background 0.3s, color 0.3s;
}
.wild-cta button:hover,
#cta-message button:hover,
#google-review:hover {
    filter: brightness(0.92);
}

/* Call to action bloco */
#cta-message {
    margin-top: 25px;
    border-radius: 10px;
    background: var(--e-global-color-background, #fff);
    text-align: center;
    border: 1px solid var(--e-global-color-border, #ddd);
    color: black!important;
}

#cta-message h3 {
    margin-bottom: 10px;
    font-size: var(--e-global-typography-primary-font-size, 22px);
    color: black!important;
}

#cta-message p {
    font-size: var(--e-global-typography-text-font-size, 16px);
    color: black!important;
}

#final-reward {
    margin-top: 20px;
    font-size: 18px;
    font-weight: bold;
    text-align: center;
}

#final-reward p {
    color: black!important;
    background-color: var(--e-global-color-secondary, #f9f9f9);
    padding: 10px;
    border-radius: 6px;
}

#final-reward p strong {
    color: black!important;
}

#social-share-icons {
    margin: 20px 0;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 15px;
}

#social-share-icons a img {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    transition: transform 0.3s ease, filter 0.3s ease;
    filter: brightness(0) saturate(100%) sepia(100%) hue-rotate(0deg);
}

#social-share-icons a img:hover {
    transform: scale(1.15);
    filter: brightness(0) saturate(100%) sepia(100%) hue-rotate(0deg) contrast(150%);
}

.wild-cta {
    background-color: var(--e-global-color-secondary, #f9f9f9);
    color: black!important;
    padding: 25px 20px;
    border-radius: 16px;
    text-align: center;
    margin-top: 40px;
}

.wild-cta h3 {
    font-size: var(--e-global-typography-primary-font-size, 22px);
    font-weight: bold;
    color: black!important;
    margin-bottom: 10px;
}

.wild-cta a {
    background: var(--e-global-color-background, #fff);
    color: black!important;
    padding: 10px 20px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 600;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    margin: 6px;
    display: inline-block;
    transition: background-color 0.3s ease, color 0.3s;
}

/* YouTube Button Style */
.wild-cta a.woq-youtube,
.woq-youtube {
    color: #FF0000 !important;
    border-color: #FF0000 !important;
}
.wild-cta a.woq-youtube i,
.woq-youtube i {
    color: #FF0000 !important;
    margin-right: 7px;
}
.wild-cta a.woq-youtube:hover,
.woq-youtube:hover {
    background: #FF0000 !important;
    color: #fff !important;
}

.wild-cta a:hover {
    background-color: var(--e-global-color-accent, #f2622e);
    color: black !important;
}

.wild-cta a[title] {
    font-size: 14px;
    padding: 8px 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    border: 1px solid var(--e-global-color-border, #ccc);
}

/* Spinner para feedback visual */
.spinner {
    display: inline-block;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255,255,255,0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
    vertical-align: middle;
    margin-right: 8px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Acessibilidade e UX extra */
#user-form input[disabled],
#user-form button[disabled],
#submit-quiz[disabled] {
    background: #e9ecef !important;
    color: #aaa !important;
    cursor: not-allowed;
    opacity: 0.8;
    border-color: #e2e2e2 !important;
}

@media (max-width: 700px) {
    .wild-quiz {
        padding: 10px;
        margin: 10px 0;
    }
    #user-form input,
    #user-form button {
        font-size: 15px;
        padding: 10px 12px;
        max-width: 100%;
    }
    .question-block {
        padding: 8px;
    }
}