/* Reset e Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #2563eb;
    --primary-dark: #1d4ed8;
    --secondary-color: #64748b;
    --accent-color: #f59e0b;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --error-color: #ef4444;
    --background-color: #f8fafc;
    --surface-color: #ffffff;
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --border-color: #e2e8f0;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --border-radius: 8px;
    --border-radius-lg: 12px;
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

body {
    font-family: var(--font-family);
    background-color: var(--background-color);
    color: var(--text-primary);
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* LGPD Banner */
.lgpd-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--surface-color);
    border-top: 1px solid var(--border-color);
    box-shadow: var(--shadow-lg);
    z-index: 1000;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.lgpd-banner.show {
    transform: translateY(0);
}

.lgpd-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    gap: 20px;
    flex-wrap: wrap;
}

.lgpd-content p {
    flex: 1;
    min-width: 300px;
    margin: 0;
    font-size: 14px;
    color: var(--text-secondary);
}

.lgpd-content a {
    color: var(--primary-color);
    text-decoration: none;
}

.lgpd-content a:hover {
    text-decoration: underline;
}

.btn-accept, .btn-reject {
    padding: 8px 16px;
    border: none;
    border-radius: var(--border-radius);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-accept {
    background: var(--primary-color);
    color: white;
}

.btn-accept:hover {
    background: var(--primary-dark);
}

.btn-reject {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}

.btn-reject:hover {
    background: var(--background-color);
}

/* Header */
.header {
    background: var(--surface-color);
    border-bottom: 1px solid var(--border-color);
    padding: 20px 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo h1 {
    font-size: 28px;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 4px;
}

.logo p {
    color: var(--text-secondary);
    font-size: 14px;
}

/* Main Content */
.main {
    min-height: calc(100vh - 200px);
    padding: 40px 0;
}

.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); }
}

/* Step Header */
.step-header, .assessment-header, .results-header {
    text-align: center;
    margin-bottom: 40px;
}

.step-header h2, .assessment-header h2, .results-header h2 {
    font-size: 32px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.step-header p, .assessment-header p, .results-header p {
    font-size: 18px;
    color: var(--text-secondary);
}

/* Progress Bar */
.progress-container {
    margin-top: 30px;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: var(--border-color);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 12px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    width: 0%;
    transition: width 0.3s ease;
}

.progress-text {
    font-size: 14px;
    color: var(--text-secondary);
    font-weight: 500;
}

/* Lead Form */
.lead-form {
    max-width: 600px;
    margin: 0 auto;
    background: var(--surface-color);
    padding: 40px;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
}

.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 8px;
    font-size: 14px;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius);
    font-size: 16px;
    transition: all 0.2s ease;
    background: var(--surface-color);
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgb(37 99 235 / 0.1);
}

.form-group input.error,
.form-group select.error {
    border-color: var(--error-color);
}

.error-message {
    display: block;
    color: var(--error-color);
    font-size: 12px;
    margin-top: 4px;
    min-height: 16px;
}

/* Checkbox */
.checkbox-group {
    margin-bottom: 32px;
}

.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    cursor: pointer;
    font-size: 14px;
    line-height: 1.5;
}

.checkbox-label input[type="checkbox"] {
    display: none;
}

.checkmark {
    width: 20px;
    height: 20px;
    border: 2px solid var(--border-color);
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    flex-shrink: 0;
    margin-top: 2px;
}

.checkbox-label input[type="checkbox"]:checked + .checkmark {
    background: var(--primary-color);
    border-color: var(--primary-color);
}

.checkbox-label input[type="checkbox"]:checked + .checkmark::after {
    content: '✓';
    color: white;
    font-size: 12px;
    font-weight: bold;
}

/* Buttons */
.btn-primary, .btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 24px;
    border: none;
    border-radius: var(--border-radius);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    justify-content: center;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
}

.btn-primary:hover:not(:disabled) {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn-primary:disabled {
    background: var(--secondary-color);
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.btn-secondary {
    background: transparent;
    color: var(--text-primary);
    border: 2px solid var(--border-color);
}

.btn-secondary:hover:not(:disabled) {
    background: var(--background-color);
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.btn-secondary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Assessment */
.assessment-content {
    max-width: 800px;
    margin: 0 auto;
}

.question-container {
    background: var(--surface-color);
    padding: 40px;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
}

.question-header {
    margin-bottom: 40px;
    text-align: center;
}

.question-header h3 {
    font-size: 18px;
    color: var(--primary-color);
    font-weight: 600;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.question-header h4 {
    font-size: 24px;
    color: var(--text-primary);
    font-weight: 500;
    line-height: 1.4;
}

/* Rating Scale */
.rating-container {
    margin-bottom: 40px;
}

.rating-scale {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin: 0 auto;
    flex-wrap: nowrap; /* Garante que os botões não quebrem a linha */
    overflow-x: auto;  /* Adiciona rolagem horizontal em telas pequenas */
    padding-bottom: 10px; /* Evita que a barra de rolagem sobreponha os botões */
}

.rating-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px 12px;
    border: 2px solid var(--border-color);
    border-radius: var(--border-radius);
    cursor: pointer;
    transition: all 0.2s ease;
    background: var(--surface-color);
}

.rating-option:hover {
    border-color: var(--primary-color);
    background: rgb(37 99 235 / 0.05);
}

.rating-option input[type="radio"] {
    display: none;
}

.rating-option input[type="radio"]:checked + .rating-label {
    background: var(--primary-color);
    color: white;
}

.rating-option input[type="radio"]:checked {
    border-color: var(--primary-color);
    background: rgb(37 99 235 / 0.1);
}

.rating-label {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--background-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 18px;
    margin-bottom: 8px;
    transition: all 0.2s ease;
}

.rating-desc {
    font-size: 12px;
    color: var(--text-secondary);
    text-align: center;
    font-weight: 500;
}

/* Reduz o tamanho dos botões de resposta (movido de index.html) */
.rating-option {
    padding: 12px 8px;
    min-width: 90px;
    gap: 8px;
}

.rating-label {
    width: 32px;
    height: 32px;
    font-size: 1.1rem;
}

.rating-desc {
    font-size: 0.8rem;
}
/* Question Navigation */
.question-navigation {
    display: flex;
    justify-content: space-between;
    gap: 20px;
}

/* Results */
.results-content {
    max-width: 1000px;
    margin: 0 auto;
}

.overall-score {
    text-align: center;
    margin-bottom: 60px;
}

.score-circle {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    color: white;
    position: relative;
}

.score-circle::before {
    content: '';
    position: absolute;
    top: 10px;
    left: 10px;
    right: 10px;
    bottom: 10px;
    border-radius: 50%;
    background: var(--surface-color);
    z-index: 1;
}

.score-value {
    font-size: 48px;
    font-weight: 700;
    z-index: 2;
    position: relative;
}

.score-label {
    font-size: 14px;
    font-weight: 500;
    z-index: 2;
    position: relative;
    opacity: 0.8;
}

.score-classification {
    font-size: 24px;
    font-weight: 600;
    color: var(--text-primary);
}

.categories-scores {
    margin-bottom: 60px;
}

.categories-scores h3 {
    font-size: 28px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 30px;
    text-align: center;
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
}

.category-card {
    background: var(--surface-color);
    padding: 24px;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
    border-left: 4px solid var(--primary-color);
}

.category-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.category-name {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
}

.category-score {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary-color);
}

.category-classification {
    font-size: 14px;
    font-weight: 500;
    padding: 4px 12px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.classification-excellent {
    background: rgb(16 185 129 / 0.1);
    color: var(--success-color);
}

.classification-good {
    background: rgb(37 99 235 / 0.1);
    color: var(--primary-color);
}

.classification-regular {
    background: rgb(245 158 11 / 0.1);
    color: var(--warning-color);
}

.classification-weak {
    background: rgb(239 68 68 / 0.1);
    color: var(--error-color);
}

.classification-critical {
    background: rgb(107 114 128 / 0.1);
    color: var(--secondary-color);
}

.category-progress {
    width: 100%;
    height: 8px;
    background: var(--border-color);
    border-radius: 4px;
    overflow: hidden;
}

.category-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    transition: width 0.3s ease;
}

/* Recommendations */
.recommendations {
    margin-bottom: 40px;
}

.recommendations h3 {
    font-size: 28px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 30px;
    text-align: center;
}

.recommendations-content {
    background: var(--surface-color);
    padding: 30px;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
}

.recommendation-item {
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border-color);
}

.recommendation-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.recommendation-category {
    font-size: 18px;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 8px;
}

.recommendation-text {
    color: var(--text-secondary);
    line-height: 1.6;
}

/* Actions */
.actions {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

/* Footer */
.footer {
    background: var(--surface-color);
    border-top: 1px solid var(--border-color);
    padding: 30px 0;
    margin-top: 60px;
}

.footer .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.footer p {
    color: var(--text-secondary);
    font-size: 14px;
}

.footer-links {
    display: flex;
    gap: 24px;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.2s ease;
}

.footer-links a:hover {
    color: var(--primary-color);
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal.show {
    display: flex;
}

.modal-content {
    background: var(--surface-color);
    border-radius: var(--border-radius-lg);
    max-width: 600px;
    width: 100%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: var(--shadow-lg);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 30px;
    border-bottom: 1px solid var(--border-color);
}

.modal-header h3 {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
}

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    color: var(--text-primary);
}

.modal-body {
    padding: 30px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 0 16px;
    }
    
    .step-header h2, .assessment-header h2, .results-header h2 {
        font-size: 24px;
    }
    
    .step-header p, .assessment-header p, .results-header p {
        font-size: 16px;
    }
    
    .lead-form {
        padding: 24px;
    }
    
    .question-container {
        padding: 24px;
    }
    
    .question-header h4 {
        font-size: 20px;
    }
    
    .rating-scale {
        gap: 12px;
    }
    
    .rating-option {
        padding: 16px 8px;
    }
    
    .rating-label {
        width: 32px;
        height: 32px;
        font-size: 16px;
    }
    
    .rating-desc {
        font-size: 11px;
    }
    
    .question-navigation {
        flex-direction: column;
    }
    
    .score-circle {
        width: 150px;
        height: 150px;
    }
    
    .score-value {
        font-size: 36px;
    }
    
    .categories-grid {
        grid-template-columns: 1fr;
    }
    
    .actions {
        flex-direction: column;
    }
    
    .footer .container {
        flex-direction: column;
        text-align: center;
    }
    
    .lgpd-content {
        flex-direction: column;
        text-align: center;
    }
    
    .lgpd-content p {
        min-width: auto;
    }
}

@media (max-width: 480px) {
    .rating-scale {
        gap: 8px; /* Reduz o espaçamento em telas muito pequenas */
    }
}

/* Loading States */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid var(--border-color);
    border-top: 2px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Print Styles */
@media print {
    .header, .footer, .lgpd-banner, .actions {
        display: none;
    }
    
    .main {
        padding: 0;
    }
    
    .step {
        display: block !important;
    }
    
    .results-content {
        max-width: none;
    }
}
