*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
    font-family: 'Inter', 'Segoe UI', sans-serif;
    /* ✅ INVERTIDO: fundo branco */
    background: #ffffff;
    min-height: 100vh;
    color: #333;
    line-height: 1.6;
}

/* ── Telas ── */
.screen { display: none; min-height: 100vh; }
.screen.active { display: block; }

.container { max-width: 900px; margin: 0 auto; padding: 30px 20px; }

/* ══════════════════════════════════
   TELA INICIAL — fundo branco, elementos azuis
══════════════════════════════════ */
.home-wrapper {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    background: #ffffff;
}

/* Logo */
.home-logo { margin-bottom: 40px; }
.logo-img {
    height: 64px;
    width: auto;
    display: block;
}

/* Hero */
.home-hero { text-align: center; margin-bottom: 48px; }
.home-hero h1 {
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    font-weight: 700;
    /* ✅ INVERTIDO: texto azul escuro */
    color: #3d3d8f;
    line-height: 1.2;
    margin-bottom: 14px;
}
.home-hero h1 .highlight { color: #667eea; }
.home-hero p {
    font-size: 1rem;
    color: #666;
    font-weight: 400;
    max-width: 420px;
    margin: 0 auto;
}

/* Cards */
.cards-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 20px;
    width: 100%;
    max-width: 620px;
}

.card {
    /* ✅ INVERTIDO: card azul com texto branco */
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 16px;
    padding: 28px 24px;
    text-align: center;
    cursor: pointer;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    box-shadow: 0 4px 24px rgba(102, 126, 234, 0.25);
    position: relative;
    border: none;
}
.card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 32px rgba(102, 126, 234, 0.4);
}

.card-badge {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    /* ✅ badge branco translúcido */
    color: rgba(255,255,255,0.9);
    background: rgba(255,255,255,0.2);
    padding: 3px 10px;
    border-radius: 99px;
    margin-bottom: 16px;
}

.card-icon { font-size: 2.4rem; margin-bottom: 12px; }

.card h3 {
    font-size: 1.25rem;
    /* ✅ branco */
    color: #ffffff;
    margin-bottom: 8px;
    font-weight: 700;
}
.card p {
    /* ✅ branco semi-transparente */
    color: rgba(255,255,255,0.8);
    margin-bottom: 20px;
    font-size: 0.88rem;
    line-height: 1.5;
}

.btn-card {
    /* ✅ botão branco com texto azul */
    background: #ffffff;
    color: #667eea;
    border: none;
    padding: 10px 24px;
    border-radius: 99px;
    font-size: 0.9rem;
    font-weight: 700;
    cursor: pointer;
    transition: opacity 0.2s, transform 0.2s;
    font-family: inherit;
}
.btn-card:hover { opacity: 0.9; transform: scale(1.03); }

.home-footer {
    margin-top: 32px;
    font-size: 0.78rem;
    color: #aaa;
    text-align: center;
}

/* ══════════════════════════════════
   TELA FORMULÁRIO — fundo gradiente azul (mantido)
══════════════════════════════════ */
#form-screen {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}
#obrigado-screen {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.question {
    background: white;
    border-radius: 20px;
    padding: 40px;
    margin: 30px auto;
    max-width: 800px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    animation: fadeIn 0.4s ease;
}
.question h2 { color: #667eea; font-size: 1.8rem; margin-bottom: 30px; text-align: center; font-weight: 700; }
.question h3 { color: #667eea; font-size: 1.4rem; margin-bottom: 20px; font-weight: 700; }
.question label { display: block; margin-bottom: 8px; font-weight: 600; color: #333; font-size: 1rem; }
.question input,
.question select,
.question textarea {
    width: 100%; padding: 15px; margin-bottom: 20px;
    border: 2px solid #e0e0e0; border-radius: 10px;
    font-size: 1rem; transition: all 0.3s ease;
    font-family: inherit; background: white;
}
.question input:focus,
.question select:focus,
.question textarea:focus {
    outline: none; border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102,126,234,0.1);
}
.question input.error, .question select.error { border-color: #ff6b6b; background: #fff5f5; }
.question small { display: block; margin-top: -15px; margin-bottom: 15px; color: #666; font-size: 0.9rem; }
.error-message { color: #ff6b6b; font-size: 0.9rem; margin-top: 6px; margin-bottom: 20px; font-weight: 600; display: block; }

/* ── Botões de opção ── */
.options { display: flex; gap: 15px; margin: 30px 0; flex-wrap: wrap; justify-content: center; }
.option-btn {
    flex: 1; min-width: 150px; padding: 20px 30px;
    border: 3px solid #e0e0e0; background: white;
    border-radius: 15px; font-size: 1.1rem; font-weight: 600;
    cursor: pointer; transition: all 0.3s ease; color: #333; font-family: inherit;
}
.option-btn:hover { border-color: #667eea; background: #f8f9ff; transform: translateY(-2px); }
.option-btn.selected {
    border-color: #667eea;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white; box-shadow: 0 5px 15px rgba(102,126,234,0.3);
}

/* ── Botões de ação ── */
.btn-group { display: flex; gap: 15px; margin-top: 30px; justify-content: center; flex-wrap: wrap; }
.btn-primary, .btn-secondary {
    padding: 18px 50px; border: none; border-radius: 50px;
    font-size: 1.1rem; font-weight: 600; cursor: pointer;
    transition: all 0.3s ease; font-family: inherit;
}
.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white; box-shadow: 0 5px 15px rgba(102,126,234,0.3);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(102,126,234,0.4); }
.btn-primary:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }
.btn-secondary { background: white; color: #667eea; border: 2px solid #667eea; }
.btn-secondary:hover { background: #f8f9ff; transform: translateY(-2px); }

.btn-back {
    background: rgba(255,255,255,0.15); color: white;
    border: 2px solid rgba(255,255,255,0.4);
    padding: 10px 22px; border-radius: 50px;
    font-size: 0.95rem; font-weight: 600; cursor: pointer;
    transition: all 0.3s ease; margin-bottom: 20px; font-family: inherit;
}
.btn-back:hover { background: rgba(255,255,255,0.25); transform: translateX(-3px); }

/* ── Progresso ── */
.progress-info { text-align: center; color: white; font-weight: 600; font-size: 1rem; margin-bottom: 12px; }
.progress-bar {
    width: 100%; max-width: 800px; height: 8px;
    background: rgba(255,255,255,0.25); border-radius: 10px;
    overflow: hidden; margin: 0 auto 36px;
}
.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #51cf66 0%, #37b24d 100%);
    border-radius: 10px; transition: width 0.5s ease;
}

/* ── Obrigado ── */
.obrigado-content {
    background: white; border-radius: 20px; padding: 60px 40px;
    max-width: 700px; margin: 80px auto; text-align: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}
.success-icon { font-size: 5rem; margin-bottom: 30px; }
.obrigado-content h2 { color: #3d3d8f; font-size: 2.2rem; margin-bottom: 20px; font-weight: 700; }
.obrigado-content p { color: #666; font-size: 1.1rem; line-height: 1.8; margin-bottom: 15px; }

/* ── Listas ── */
ul { list-style: none; padding: 0; }
li {
    padding: 10px; margin-bottom: 8px; background: #f0f0f0;
    border-radius: 8px; display: flex; justify-content: space-between; align-items: center;
}
li button {
    background: #ff6b6b; color: white; border: none;
    border-radius: 4px; padding: 5px 10px; cursor: pointer; font-size: 0.9rem;
}

/* ── Inputs numéricos ── */
input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
input[type="number"] { -moz-appearance: textfield; }

/* ── Select ── */
select {
    appearance: none; -webkit-appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23667eea' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat; background-position: right 15px center;
    background-size: 20px; padding-right: 45px; cursor: pointer;
}

/* ── Botão Voltar dentro do card ── */
.btn-back-inline {
    display: inline-flex; align-items: center; gap: 6px;
    background: none; color: #667eea; border: none; padding: 0;
    font-size: 0.9rem; font-weight: 600; cursor: pointer;
    transition: all 0.2s ease; margin-bottom: 20px;
    font-family: inherit; opacity: 0.75;
}
.btn-back-inline:hover { opacity: 1; transform: translateX(-3px); }

/* ── Logo dentro do card ── */
.card-logo { text-align: center; margin-bottom: 16px; }
.card-logo-img { height: 44px; width: auto; max-width: 200px; display: inline-block; object-fit: contain; }

/* ── Telas obrigado centralizadas ── */
#obrigado-screen.active,
#obrigado-analise-screen.active { display: flex !important; }
#obrigado-screen, #obrigado-analise-screen {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh; align-items: center; justify-content: center;
}

/* ── Animações ── */
@keyframes fadeIn { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }
@keyframes pulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.1); } }

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: #f1f1f1; }
::-webkit-scrollbar-thumb { background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); border-radius: 10px; }

/* ── Responsivo ── */
@media (max-width: 768px) {
    .cards-container { grid-template-columns: 1fr; gap: 16px; max-width: 360px; }
    .card { padding: 24px 20px; }
    .logo-img { height: 48px; }
    .question { padding: 25px; margin: 20px auto; }
    .question h2 { font-size: 1.4rem; }
    .options { flex-direction: column; }
    .option-btn { min-width: 100%; }
    .btn-group { flex-direction: column; }
    .btn-primary, .btn-secondary { width: 100%; }
    .obrigado-content { padding: 40px 25px; margin: 40px auto; }
}
@media (max-width: 480px) {
    .question { padding: 20px; }
    .btn-primary, .btn-secondary, .btn-back { padding: 14px 28px; font-size: 0.95rem; }
}
