/* Arquivo de Estilos Base - EdocBr Redesign */

/* Paleta de Cores Unificada (Baseada no Tailwind 'Emerald' e 'Teal') */
:root {
    --primary: #059669; /* emerald-600 */
    --primary-dark: #065F46; /* emerald-800 */
    --primary-light: #10B981; /* emerald-500 */
    --secondary: #0D9488; /* teal-600 */
    --background-light: #F0FDF4; /* emerald-50 */
    --text-dark: #1F2937; /* gray-800 */
    --text-light: #F9FAFB; /* gray-50 */
}

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

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--background-light);
}

/* Base para botões e formulários - A maioria será Tailwind, mas mantemos classes base */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 28px;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: 10px; /* Mais arredondado */
    transition: all 0.3s;
    cursor: pointer;
    border: none;
    box-shadow: 0 4px 12px rgba(5, 150, 105, 0.15);
}

.btn-primary {
    background: var(--primary);
    color: var(--text-light);
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(5, 150, 105, 0.25);
}

.btn-secondary {
    background: #6B7280;
    color: var(--text-light);
}

.btn-outline {
    background: transparent;
    color: var(--primary-dark);
    border: 2px solid var(--primary);
}

.btn-outline:hover {
    background: var(--primary);
    color: var(--text-light);
}

.btn-full {
    width: 100%;
}

/* Estilos para a página de Certificado/Formulário */
.certificado-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
}

.certificado-card {
    max-width: 600px;
    width: 100%;
    background: white;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.card-header-cert {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: white;
}

.logo-img {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    object-fit: contain;
    background: #fff;
}

.cert-title {
    padding: 32px 24px 24px;
    text-align: center;
}

.cert-title h2 {
    font-size: 1.5rem;
    color: var(--primary-dark);
}

/* Steps Indicator */
.steps-indicator {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 24px 24px;
}

.step {
    display: flex;
    align-items: center;
}

.step-number {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #E5E7EB; /* gray-200 */
    color: #9CA3AF; /* gray-400 */
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.95rem;
}

.step.active .step-number, .step.completed .step-number {
    background: var(--primary);
    color: white;
}

.step-line {
    width: 36px;
    height: 2px;
    background: #E5E7EB;
}

.step.completed .step-line {
    background: var(--primary);
}

/* Forms */
.step-content {
    padding: 24px;
}

.form-cert {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group label {
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text-dark);
}

.form-group input {
    padding: 12px 16px;
    border: 2px solid #E5E7EB;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.2s;
}

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

.form-help {
    font-size: 0.75rem;
    color: #6B7280;
    margin-top: 4px;
}

.radio-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.radio-label {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border: 2px solid #E5E7EB;
    border-radius: 8px;
    cursor: pointer;
    transition: border-color 0.2s, background-color 0.2s;
}

.radio-label:hover {
    border-color: var(--primary);
    background-color: var(--background-light);
}

.radio-label input[type="radio"]:checked + span {
    color: var(--primary-dark);
    font-weight: 700;
}

/* Data Display (Step 2 e 4) */
.data-box {
    background: #F9FAFB; /* gray-50 */
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
    border: 1px solid #E5E7EB; /* gray-200 */
}

.data-box h3 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--primary-light);
    color: var(--primary-dark);
}

.data-item {
    margin-bottom: 16px;
}

.data-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: #6B7280;
    margin-bottom: 4px;
}

.data-value {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--text-dark);
}

.data-value.highlight {
    color: var(--primary);
}

/* Step 4 - Confirmação Final */
.cert-data-group {
    display: grid;
    grid-template-columns: repeat(1, minmax(0, 1fr));
    gap: 12px;
}

@media (min-width: 640px) {
    .cert-data-group {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (min-width: 768px) {
    .cert-data-group {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

.cert-data-item {
    background: white;
    border: 1px solid #E5E7EB;
    border-radius: 8px;
    padding: 12px 16px;
}

.cert-data-item span {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    color: #6B7280;
    margin-bottom: 2px;
}

.cert-data-item strong {
    display: block;
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-dark);
    word-break: break-word;
}

/* Footer */
.card-footer-cert {
    background: #F9FAFB;
    padding: 20px 24px;
    text-align: center;
    border-top: 1px solid #E5E7EB;
    font-size: 0.85rem;
    color: #6B7280;
}

/* Responsividade para o formulário */
@media (max-width: 767px) {
    .steps-indicator {
        flex-wrap: wrap; /* Permite que os passos quebrem a linha */
        justify-content: space-between;
    }
    .step-line {
        width: 100%;
        margin: 8px 0; /* Espaçamento vertical para a linha */
    }
    .step {
        flex-direction: column;
        align-items: center;
        width: 30%; /* Para que 3 passos caibam na linha */
        text-align: center;
    }
    .step:last-child .step-line {
        display: none; /* Remove a linha do último passo em mobile */
    }
    .step-content {
        padding: 16px;
    }
    .form-cert {
        gap: 16px;
    }
    .form-group input {
        padding: 10px 14px;
    }
}

@media (max-width: 640px) {
    .form-cert .grid {
        gap: 12px;
    }
    .certificado-container {
        padding: 20px 10px;
    }
    .step-content {
        padding: 16px;
    }
    .data-box {
        padding: 16px;
    }
    .cert-data-item {
        padding: 10px 12px;
    }
}
