/* ================================================
   ESTILOS GLOBAIS DO QUESTIONÁRIO OCEA
   ================================================ */

:root {
    --primary-color: #2C5F2D;
    --secondary-color: #97BC62;
    --accent-color: #FFB81C;
    --neutral-bg: #F7F4EF;
    --text-dark: #2c2c2c;
    --brown-detail: #8B7355;
}

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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--neutral-bg);
    color: var(--text-dark);
    line-height: 1.6;
}

/* ================================================
   HEADER
   ================================================ */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: #007c8c;
    padding: 0.75rem 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    z-index: 1000;
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Logo styles moved to /css/header-home.css */

.user-greeting {
    color: white;
    font-size: 0.95rem;
    margin-right: 1rem;
}

.btn-logout {
    background: var(--accent-color);
    color: white;
    border: none;
    padding: 6px 16px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-logout:hover {
    background: var(--primary-color);
}

/* ================================================
   IMAGEM DE CAPA - ALTURA REDUZIDA
   ================================================ */
.cover-image {
    width: 100%;
    height: 180px; /* Reduzido de 400px */
    object-fit: cover;
    object-position: center;
    margin-top: 60px;
}

@media (min-width: 1024px) {
    .cover-image {
        height: 220px; /* Reduzido de 500px */
    }
}

/* ================================================
   BARRA DE PROGRESSO - MAIS FINA
   ================================================ */
.progress-container {
    background: white;
    padding: 1.5rem 0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.progress-wrapper {
    position: relative;
    height: 12px; /* Reduzido de 30px */
    background: #e9ecef;
    border-radius: 10px;
    overflow: visible;
}

.progress-bar-custom {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    border-radius: 10px;
    transition: width 0.3s ease;
    position: relative;
}

.progress-thumb {
    position: absolute;
    right: -15px;
    top: 50%;
    transform: translateY(-50%);
    width: 40px; /* Reduzido de 50px */
    height: 40px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 0.75rem;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

/* ================================================
   SEÇÃO DO QUESTIONÁRIO
   ================================================ */
.questionnaire-section {
    max-width: 900px;
    margin: 2rem auto;
    padding: 0 1rem;
}

.section-title {
    color: var(--primary-color);
    font-size: 1.8rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.section-description {
    color: #666;
    margin-bottom: 2rem;
    font-size: 1rem;
}

/* ================================================
   BLOCOS DE PERGUNTAS - ESPAÇAMENTO REDUZIDO
   ================================================ */
.question-block {
    background: white;
    padding: 1.5rem; /* Reduzido de 2rem */
    border-radius: 15px;
    margin-bottom: 1rem; /* Reduzido de 2rem */
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

/* REMOVER O NÚMERO DA PERGUNTA */
.question-number {
    display: none; /* OCULTAR "PERGUNTA X DE Y" */
}

.question-text {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 1.25rem;
}

/* ================================================
   RADIO BUTTONS
   ================================================ */
.radio-group {
    display: flex;
    flex-direction: column;
    gap: 0.75rem; /* Reduzido de 1rem */
}

.radio-option {
    background: var(--neutral-bg);
    border: 3px solid transparent;
    border-radius: 12px;
    padding: 0.875rem 1.25rem; /* Reduzido */
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 0.875rem;
}

.radio-option:hover {
    border-color: var(--secondary-color);
    transform: translateX(5px);
}

.radio-option.selected {
    border-color: var(--primary-color);
    background: #e8f5e9;
}

.radio-option input[type="radio"] {
    width: 20px;
    height: 20px;
    accent-color: var(--primary-color);
}

.radio-option label {
    cursor: pointer;
    flex: 1;
    font-size: 0.95rem;
}

/* ================================================
   RANGE SLIDER - COM DEGRADÊ E MARCADORES
   ================================================ */
.slider-container {
    padding: 1rem 0;
}

.slider-wrapper {
    position: relative;
    margin: 2rem 0;
}

.slider-labels {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
    font-size: 0.85rem;
    color: #666;
}

/* Marcadores de 0 a 10 com traços */
.slider-markers {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0;
    padding: 0 12px;
    position: relative;
}

.slider-markers span {
    font-size: 0.75rem;
    color: #666;
    font-weight: 500;
    width: 20px;
    text-align: center;
    position: relative;
    padding-bottom: 0.5rem;
}

/* Traços verticais acima de cada número */
.slider-markers span::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 2px;
    height: 8px;
    background-color: #999;
}

input[type="range"] {
    width: 100%;
    height: 10px;
    border-radius: 5px;
    /* Degradê de vermelho → amarelo → verde */
    background: linear-gradient(to right,
        #D9534F 0%,    /* Vermelho no 0 */
        #F0AD4E 50%,   /* Amarelo no 5 */
        #5CB85C 100%   /* Verde no 10 */
    );
    outline: none;
    -webkit-appearance: none;
}

input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
    box-shadow: 0 2px 5px rgba(0,0,0,0.3);
    border: 3px solid white;
}

input[type="range"]::-moz-range-thumb {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
    box-shadow: 0 2px 5px rgba(0,0,0,0.3);
    border: 3px solid white;
}

.slider-value {
    display: none; /* Ocultar o valor numérico abaixo do slider */
}

/* ================================================
   CHECKBOXES
   ================================================ */
.checkbox-group {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem; /* Reduzido */
}

.checkbox-option {
    background: var(--neutral-bg);
    border: 3px solid transparent;
    border-radius: 12px;
    padding: 0.75rem 1rem; /* Reduzido */
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 0.625rem;
}

.checkbox-option:hover {
    border-color: var(--secondary-color);
}

.checkbox-option.selected {
    border-color: var(--primary-color);
    background: #e8f5e9;
}

.checkbox-option input[type="checkbox"] {
    width: 20px;
    height: 20px;
    accent-color: var(--primary-color);
}

.checkbox-option label {
    cursor: pointer;
    font-size: 0.9rem;
}

/* ================================================
   BOTÕES DE NAVEGAÇÃO
   ================================================ */
.navigation-buttons {
    display: flex;
    justify-content: space-between;
    margin: 2.5rem 0; /* Reduzido */
    gap: 1rem;
}

.btn-navigation {
    padding: 0.875rem 2.5rem; /* Reduzido */
    font-size: 1rem;
    font-weight: bold;
    border-radius: 30px;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-prev {
    background: #6c757d;
    color: white;
}

.btn-prev:hover {
    background: #5a6268;
    transform: translateX(-5px);
}

.btn-next {
    background: var(--primary-color);
    color: white;
}

.btn-next:hover {
    background: var(--secondary-color);
    transform: translateX(5px);
}

.btn-next:disabled,
.btn-finish:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
}

.btn-finish {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    box-shadow: 0 5px 15px rgba(44, 95, 45, 0.3);
}

.btn-finish:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(44, 95, 45, 0.4);
}

/* ================================================
   FORMULARIO TABELA (estilo intro)
   ================================================ */
.form-table {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.form-row {
    display: flex;
    border-bottom: 1px solid #e9ecef;
    transition: background 0.2s;
}

.form-row:last-child {
    border-bottom: none;
}

.form-row:hover {
    background: #f8f9fa;
}

.form-row.error {
    background: #fff5f5;
    border-left: 4px solid #D9534F;
}

.form-label-col {
    flex: 0 0 35%;
    padding: 1.5rem;
    background: #f8f9fa;
    font-weight: 600;
    color: var(--text-dark);
    display: flex;
    align-items: center;
    border-right: 1px solid #e9ecef;
}

.form-input-col {
    flex: 1;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.form-input-col input,
.form-input-col select {
    width: 100%;
    max-width: 400px;
    padding: 0.75rem 1rem;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s;
}

.form-input-col input.invalid {
    border-color: #D9534F;
}

.form-input-col input:focus,
.form-input-col select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(44, 95, 45, 0.1);
}

.error-message {
    color: #D9534F;
    font-size: 0.85rem;
    margin-top: 0.5rem;
    display: none;
}

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

.radio-inline {
    display: flex;
    gap: 2rem;
}

.radio-inline label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    font-weight: normal;
}

.radio-inline input[type="radio"] {
    width: 20px;
    height: 20px;
    accent-color: var(--primary-color);
}

/* IMC Display */
.imc-display {
    margin-top: 1.5rem;
    padding: 1.25rem;
    background: linear-gradient(135deg, #e8f5e9 0%, #c8e6c9 100%);
    border-radius: 12px;
    border-left: 4px solid var(--primary-color);
}

.imc-display h4 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.imc-value {
    font-size: 2rem;
    font-weight: bold;
    color: var(--primary-color);
}

.imc-category {
    font-size: 1rem;
    color: #666;
}

/* ================================================
   CARDS DE OBJETIVOS (conforme imagem do usuario)
   ================================================ */
.objectives-section {
    margin-top: 2rem;
}

.objectives-section h3 {
    color: var(--primary-color);
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
}

.objectives-section .help-text {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}

/* Grid de cards principais - 2 colunas */
.objectives-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.objective-card {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    padding: 1.25rem;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
}

.objective-card:hover {
    border-color: var(--secondary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.objective-card.selected {
    border-color: var(--primary-color);
    background: #e8f5e9;
}

.objective-card input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.objective-card .card-title {
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
    line-height: 1.3;
}

.objective-card .card-description {
    font-size: 0.9rem;
    color: #666;
    line-height: 1.4;
}

/* Cards secundarios - menores, 3 colunas */
.secondary-objectives {
    margin-top: 1.5rem;
}

.secondary-objectives h4 {
    color: #666;
    font-size: 1rem;
    margin-bottom: 1rem;
    font-weight: 600;
}

.secondary-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
}

.secondary-card {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 10px;
    padding: 0.875rem 1rem;
    cursor: pointer;
    transition: all 0.3s;
    text-align: center;
    position: relative;
}

.secondary-card:hover {
    border-color: var(--secondary-color);
}

.secondary-card.selected {
    border-color: var(--primary-color);
    background: #e8f5e9;
}

.secondary-card input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.secondary-card .card-title {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-dark);
}

/* Campo "Outro" */
.outro-field {
    margin-top: 1rem;
    display: none;
}

.outro-field.show {
    display: block;
}

.outro-field input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 1rem;
}

.outro-field input:focus {
    outline: none;
    border-color: var(--primary-color);
}

/* ================================================
   TEXTAREA
   ================================================ */
.form-textarea {
    width: 100%;
    min-height: 120px;
    padding: 1rem;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    font-size: 1rem;
    font-family: inherit;
    resize: vertical;
    transition: all 0.3s;
}

.form-textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(44, 95, 45, 0.1);
}

/* ================================================
   RESPONSIVIDADE
   ================================================ */
@media (max-width: 768px) {
    .section-title {
        font-size: 1.4rem;
    }

    .question-block {
        padding: 1.25rem;
    }

    .navigation-buttons {
        flex-direction: column;
    }

    .btn-navigation {
        width: 100%;
        justify-content: center;
    }

    .cover-image {
        height: 150px;
    }

    .form-row {
        flex-direction: column;
    }

    .form-label-col {
        flex: 1;
        border-right: none;
        border-bottom: 1px solid #e9ecef;
    }

    .form-input-col input {
        max-width: 100%;
    }

    .objectives-grid {
        grid-template-columns: 1fr;
    }

    .secondary-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

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