* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Montserrat', sans-serif;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.container {
    max-width: 800px;
    width: 100%;
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.1);
    overflow: hidden;
    position: relative;
}

/* Faixa branca com a marca — a logo é verde/amarela, então pede fundo claro. */
.brand-bar {
    background: #fff;
    padding: 14px 24px 8px;
    text-align: center;
    border-bottom: 1px solid #eef1f4;
}

.brand-bar a {
    display: inline-block;
    line-height: 0;
}

.logo {
    height: 96px;
    width: auto;
    max-width: 100%;
}

.header {
    background: linear-gradient(135deg, #2ecc71 0%, #27ae60 100%);
    color: white;
    padding: 26px 30px;
    text-align: center;
}

.header h1 {
    font-size: 23px;
    font-weight: 700;
    margin-bottom: 6px;
    letter-spacing: -0.2px;
}

.header p {
    font-size: 14px;
    opacity: 0.92;
}

/* Progresso com texto: a barra sozinha não diz em que etapa a pessoa está. */
.progress-wrap {
    background: #fff;
    border-bottom: 1px solid #eef1f4;
}

.progress-info {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 12px;
    padding: 12px 30px 10px;
    font-size: 13px;
}

.progress-etapa {
    font-weight: 700;
    color: #27ae60;
    white-space: nowrap;
}

.progress-nome {
    color: #7f8c8d;
    text-align: right;
}

.progress-bar {
    height: 6px;
    background: #e0e0e0;
    position: relative;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #2ecc71, #27ae60);
    width: 0%;
    transition: width 0.5s ease;
}

.content {
    padding: 40px 30px;
    min-height: 400px;
}

.step {
    display: none;
    animation: fadeIn 0.5s ease;
}

.step.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.form-group {
    margin-bottom: 25px;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #333;
    font-size: 14px;
}

input, select {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    font-family: 'Montserrat', sans-serif;
    transition: all 0.3s ease;
}

input:focus, select:focus {
    outline: none;
    border-color: #2ecc71;
    box-shadow: 0 0 0 3px rgba(46, 204, 113, 0.1);
}

input.error, select.error {
    border-color: #e74c3c;
}

.error-message {
    color: #e74c3c;
    font-size: 12px;
    margin-top: 5px;
    display: none;
}

.error-message.show {
    display: block;
}

.two-columns {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

@media (max-width: 600px) {
    .two-columns {
        grid-template-columns: 1fr;
    }
}

.module-section {
    margin-bottom: 30px;
}

.module-title {
    background: linear-gradient(135deg, #2ecc71 0%, #27ae60 100%);
    color: white;
    padding: 15px 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-weight: 600;
    font-size: 16px;
}

.question-item {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 15px;
    border: 2px solid transparent;
    transition: all 0.3s ease;
}

.question-item:hover {
    border-color: #cdeedd;
    box-shadow: 0 4px 14px rgba(0,0,0,0.06);
}

/* Já respondida: fica claro o que falta preencher. */
.question-item.respondida {
    background: #fff;
    border-color: #d8f0e3;
}

.question-text {
    margin-bottom: 16px;
    color: #333;
    font-size: 15px;
    line-height: 1.6;
}

.radio-group {
    display: flex;
    gap: 15px;
    justify-content: center;
}

.radio-option {
    flex: 1;
    position: relative;
}

.radio-option input[type="radio"] {
    display: none;
}

.radio-label {
    display: block;
    padding: 15px 10px;
    text-align: center;
    border: 2px solid #ddd;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.radio-label .score-number {
    font-size: 24px;
    font-weight: 700;
    display: block;
    margin-bottom: 5px;
}

.radio-label .score-desc {
    font-size: 12px;
    font-weight: 600;
    opacity: 0.85;
    display: block;
    line-height: 1.25;
}

.radio-label:hover {
    border-color: #2ecc71;
}

.radio-option input[type="radio"]:checked + .radio-label {
    box-shadow: 0 6px 16px rgba(0,0,0,0.16);
}

/* Foco visível pelo teclado (acessibilidade). */
.radio-option input[type="radio"]:focus-visible + .radio-label {
    outline: 3px solid #2ecc7155;
    outline-offset: 2px;
}

.radio-option:nth-child(1) input[type="radio"]:checked + .radio-label {
    background: #e74c3c;
    color: white;
    border-color: #e74c3c;
}

.radio-option:nth-child(2) input[type="radio"]:checked + .radio-label {
    background: #f39c12;
    color: white;
    border-color: #f39c12;
}

.radio-option:nth-child(3) input[type="radio"]:checked + .radio-label {
    background: #2ecc71;
    color: white;
    border-color: #2ecc71;
}

.btn-container {
    display: flex;
    gap: 15px;
    margin-top: 30px;
}

.btn {
    flex: 1;
    padding: 15px 30px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Montserrat', sans-serif;
}

.btn-primary {
    background: linear-gradient(135deg, #2ecc71 0%, #27ae60 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(46, 204, 113, 0.3);
}

.btn-secondary {
    background: #95a5a6;
    color: white;
}

.btn-secondary:hover {
    background: #7f8c8d;
}

.btn-pdf {
    background: #e74c3c;
    color: white;
}

.btn-pdf:hover {
    background: #c0392b;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(231, 76, 60, 0.3);
}

.btn-restart {
    background: #3498db;
    color: white;
}

.btn-restart:hover {
    background: #2980b9;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(52, 152, 219, 0.3);
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.loading {
    display: none;
    text-align: center;
    padding: 50px;
}

.loading.show {
    display: block;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 5px solid #f3f3f3;
    border-top: 5px solid #2ecc71;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

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

.status-message {
    padding: 15px;
    border-radius: 8px;
    margin: 20px 0;
    text-align: center;
    font-weight: 500;
}

.status-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.status-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.status-warning {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeeba;
}

.result-container {
    text-align: center;
    padding: 30px;
}

.score-display {
    width: 200px;
    height: 200px;
    margin: 0 auto 30px;
    position: relative;
}

.score-circle {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: conic-gradient(#2ecc71 0deg, #2ecc71 var(--score-deg), #e0e0e0 var(--score-deg));
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.score-inner {
    width: 160px;
    height: 160px;
    border-radius: 50%;
    background: white;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.score-value {
    font-size: 48px;
    font-weight: 700;
    color: #333;
}

.score-label {
    font-size: 14px;
    color: #666;
    margin-top: 5px;
}

.result-grade {
    padding: 15px 30px;
    border-radius: 10px;
    display: inline-block;
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 20px;
    color: white;
}

.grade-alert { background: #e74c3c; }
.grade-stable { background: #f39c12; }
.grade-active { background: #3498db; }
.grade-proactive { background: #2ecc71; }

.module-results {
    margin: 30px 0;
    text-align: left;
}

.module-result-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    margin-bottom: 10px;
}

.module-name {
    font-weight: 500;
    color: #333;
}

.module-score {
    font-weight: 700;
    color: #2ecc71;
}

.analysis-section {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 15px;
    margin: 30px 0;
    text-align: left;
}

.analysis-title {
    font-size: 18px;
    font-weight: 700;
    color: #333;
    margin-bottom: 15px;
    text-align: center;
}

.analysis-text {
    color: #666;
    line-height: 1.8;
    text-align: justify;
    margin-bottom: 20px;
}

.recommendations {
    margin-top: 20px;
}

.recommendations h3 {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin-bottom: 15px;
}

.recommendation-item {
    padding: 12px;
    background: white;
    border-left: 3px solid #2ecc71;
    margin-bottom: 10px;
    border-radius: 5px;
}

.recommendation-item strong {
    color: #2ecc71;
    font-size: 14px;
}

.cta-section {
    background: #fff3cd;
    border: 2px solid #ffc107;
    border-radius: 15px;
    padding: 25px;
    margin: 30px 0;
    text-align: center;
}

.cta-question {
    font-size: 18px;
    font-weight: 600;
    color: #856404;
    margin-bottom: 20px;
}

.whatsapp-btn {
    background: #25d366;
    color: white;
    padding: 20px 40px;
    border-radius: 50px;
    font-size: 18px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    animation: pulse 2s infinite;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7);
    }
    70% {
        box-shadow: 0 0 0 20px rgba(37, 211, 102, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0);
    }
}

.whatsapp-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 10px 30px rgba(37, 211, 102, 0.4);
}

.alert {
    padding: 15px;
    background: #fff3cd;
    border: 1px solid #ffc107;
    border-radius: 8px;
    color: #856404;
    margin-bottom: 20px;
    display: none;
}

.alert.show {
    display: block;
}

.action-buttons {
    display: flex;
    gap: 15px;
    margin-top: 30px;
    flex-wrap: wrap;
}

@media (max-width: 600px) {
    .action-buttons {
        flex-direction: column;
    }
    
    .action-buttons .btn {
        width: 100%;
    }
}

/* ==========================================================================
   Página de abertura (index.html)
   ========================================================================== */

.abertura {
    padding: 40px 30px 44px;
}

.abertura .chamada {
    text-align: center;
    margin-bottom: 34px;
}

.abertura h2 {
    font-size: 26px;
    line-height: 1.3;
    color: #2c3e50;
    margin-bottom: 14px;
    letter-spacing: -0.3px;
}

.abertura .linha-fina {
    font-size: 16px;
    line-height: 1.65;
    color: #5a6b7a;
    max-width: 620px;
    margin: 0 auto;
}

.abertura .linha-fina b {
    color: #27ae60;
}

.numeros {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    margin: 30px 0 34px;
}

.numero-card {
    background: #f8f9fa;
    border: 1px solid #eef1f4;
    border-radius: 12px;
    padding: 18px 12px;
    text-align: center;
}

.numero-card .valor {
    display: block;
    font-size: 30px;
    font-weight: 800;
    color: #27ae60;
    line-height: 1.1;
}

.numero-card .rotulo {
    font-size: 12px;
    color: #7f8c8d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.secao {
    margin-bottom: 34px;
}

.secao h3 {
    font-size: 17px;
    color: #2c3e50;
    margin-bottom: 16px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f0f3f5;
}

.passos {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.passo {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 20px 18px;
    border: 1px solid #eef1f4;
}

.passo .bolinha {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: linear-gradient(135deg, #2ecc71, #27ae60);
    color: #fff;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 12px;
}

.passo h4 {
    font-size: 15px;
    color: #2c3e50;
    margin-bottom: 6px;
}

.passo p {
    font-size: 13.5px;
    color: #7f8c8d;
    line-height: 1.55;
}

.lista-areas {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px 18px;
}

.lista-areas li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 14px;
    color: #4a5a68;
    line-height: 1.5;
    padding: 7px 0;
    border-bottom: 1px dashed #eef1f4;
}

.lista-areas .n {
    flex: 0 0 24px;
    height: 24px;
    border-radius: 6px;
    background: #2ecc711a;
    color: #27ae60;
    font-size: 12px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.graus {
    display: grid;
    gap: 10px;
}

.grau-linha {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 13px 16px;
    border-radius: 10px;
    background: #f8f9fa;
    border-left: 5px solid;
}

.grau-linha .faixa {
    font-weight: 700;
    font-size: 14px;
    flex: 0 0 78px;
}

.grau-linha .nome {
    font-weight: 700;
    font-size: 14px;
    flex: 0 0 130px;
}

.grau-linha .desc {
    font-size: 13.5px;
    color: #7f8c8d;
    line-height: 1.45;
}

.aviso-lgpd {
    background: #f8f9fa;
    border: 1px solid #eef1f4;
    border-radius: 10px;
    padding: 16px 18px;
    font-size: 13px;
    color: #7f8c8d;
    line-height: 1.6;
}

.aviso-lgpd a {
    color: #27ae60;
}

.cta-abertura {
    text-align: center;
    margin: 34px 0 10px;
}

.cta-abertura .btn {
    display: block;
    max-width: 340px;
    margin: 0 auto;
    font-size: 17px;
    padding: 17px 30px;
    text-align: center;
    text-decoration: none;
    box-shadow: 0 8px 20px rgba(46, 204, 113, 0.28);
}

.cta-abertura .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 26px rgba(46, 204, 113, 0.35);
}

.cta-abertura .tempo {
    display: block;
    margin-top: 12px;
    font-size: 13px;
    color: #7f8c8d;
}

.rodape-abertura {
    text-align: center;
    padding: 20px 30px 26px;
    border-top: 1px solid #eef1f4;
    font-size: 12.5px;
    color: #95a5a6;
}

.rodape-abertura a {
    color: #7f8c8d;
    margin: 0 6px;
}

/* ---------- Celular ---------- */
@media (max-width: 640px) {
    body {
        padding: 0;
        align-items: flex-start;
    }

    .container {
        border-radius: 0;
        min-height: 100vh;
    }

    .brand-bar {
        padding: 18px 16px 14px;
    }

    .logo {
        height: 72px;
    }

    .header {
        padding: 20px 18px;
    }

    .header h1 {
        font-size: 19px;
    }

    .progress-info {
        padding: 10px 18px 8px;
        font-size: 12px;
    }

    .content,
    .abertura {
        padding: 26px 18px 32px;
    }

    .abertura h2 {
        font-size: 21px;
    }

    .abertura .linha-fina {
        font-size: 15px;
    }

    .numeros,
    .passos,
    .lista-areas {
        grid-template-columns: 1fr;
    }

    .numeros {
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
    }

    .numero-card .valor {
        font-size: 24px;
    }

    .grau-linha {
        flex-wrap: wrap;
        gap: 4px 12px;
    }

    .grau-linha .faixa,
    .grau-linha .nome {
        flex: none;
    }

    .radio-group {
        gap: 8px;
    }

    .radio-label {
        padding: 13px 6px;
    }

    .radio-label .score-number {
        font-size: 20px;
    }

    .radio-label .score-desc {
        font-size: 11px;
    }

    .btn-container {
        flex-direction: column-reverse;
    }
}
