/* ===== VARIÁVEIS GLOBAIS ===== */
:root {
    --primary: #10B981;
    --primary-dark: #059669;
    --primary-light: #D1FAE5;
    --secondary: #6366F1;
    --danger: #EF4444;
    --danger-dark: #DC2626;
    --warning: #F59E0B;
    --success: #10B981;
    --dark: #1F2937;
    --gray-900: #111827;
    --gray-800: #1F2937;
    --gray-700: #374151;
    --gray-600: #4B5563;
    --gray-500: #6B7280;
    --gray-400: #9CA3AF;
    --gray-300: #D1D5DB;
    --gray-200: #E5E7EB;
    --gray-100: #F3F4F6;
    --gray-50: #F9FAFB;
    --white: #FFFFFF;

    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);

    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-2xl: 1.5rem;
    --radius-full: 9999px;

    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 300ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 500ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-bounce: 500ms cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* ===== RESET E ESTILOS BASE ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

*::before,
*::after {
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #F8FAFC;
    min-height: 100vh;
    padding: 24px;
    color: var(--gray-900);
    line-height: 1.5;
    position: relative;
    overflow-x: hidden;
}

/* ===== CONTAINER PRINCIPAL ===== */
.container {
    max-width: 1280px;
    margin: 0 auto;
    background: var(--white);
    border-radius: 32px;
    box-shadow: var(--shadow-2xl);
    overflow: hidden;
    position: relative;
    z-index: 10;
}

/* ===== HEADER MODERNO ===== */
.header-moderno {
    background: var(--white);
    padding: 24px 40px;
    border-bottom: 1px solid var(--gray-200);
    position: relative;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    z-index: 2;
}

.logo-wrapper {
    display: flex;
    align-items: center;
    gap: 16px;
}

.logo-animated {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-lg);
}

.logo-icon {
    font-size: 24px;
    color: white;
}

.logo-text h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 2px;
}

.logo-subtitle {
    font-size: 0.85rem;
    color: var(--gray-500);
    font-weight: 400;
}

/* ===== MAIN ===== */
main {
    padding: 40px;
    background: var(--white);
}

/* ===== FORMULÁRIO ===== */
.form-elegante {
    max-width: 1000px;
    margin: 0 auto;
}

/* ===== CARDS ===== */
.form-card {
    background: var(--white);
    border-radius: 24px;
    padding: 32px;
    margin-bottom: 24px;
    border: 1px solid var(--gray-200);
    transition: all var(--transition-base);
    position: relative;
}

.form-card:hover {
    border-color: var(--gray-300);
}

/* ===== CARD HEADER SUPER CLEAN ===== */
.card-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
}

.header-icon {
    width: 36px;
    height: 36px;
    background: var(--gray-50);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    color: var(--primary);
}

.card-header h2 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--gray-800);
    flex: 1;
    margin: 0;
}

/* ===== BADGES ===== */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 500;
    letter-spacing: 0.3px;
}

.badge-primary {
    background: var(--primary-light);
    color: var(--primary-dark);
}

.badge-warning {
    background: #FEF3C7;
    color: var(--warning);
}

/* ===== GRID ===== */
.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

/* ===== INPUT WRAPPER ===== */
.input-wrapper {
    position: relative;
    margin-bottom: 4px;
}

.input-wrapper label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    color: var(--gray-700);
    font-size: 0.85rem;
    transition: color var(--transition-fast);
}

.input-wrapper .required {
    color: var(--danger);
    margin-left: 2px;
}

/* ===== INPUTS MODERNOS ===== */
.input-moderno,
.textarea-moderno {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--gray-300);
    border-radius: 14px;
    font-size: 0.95rem;
    transition: all 0.2s ease;
    background: var(--white);
    color: var(--gray-900);
    font-family: inherit;
}

.input-moderno:focus,
.textarea-moderno:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px var(--primary-light);
}

.input-moderno:hover:not(:focus) {
    border-color: var(--gray-400);
}

.input-moderno.readonly,
.input-moderno:read-only {
    background: var(--gray-50);
    border-color: var(--gray-200);
    color: var(--gray-600);
    cursor: not-allowed;
}

/* ===== SELECT MODERNO ===== */
.select-moderno {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--gray-300);
    border-radius: 14px;
    font-size: 0.95rem;
    background-color: var(--white);
    color: var(--gray-900);
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236B7280' 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 16px center;
    background-size: 16px;
    padding-right: 44px;
    transition: all 0.2s ease;
}

.select-moderno:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px var(--primary-light);
}

.select-moderno:hover {
    border-color: var(--gray-400);
}

/* ===== TEXTAREA ===== */
.textarea-moderno {
    resize: vertical;
    min-height: 80px;
}

/* ===== FULL WIDTH ===== */
.full-width {
    grid-column: 1 / -1;
}

/* ===== SMALL TEXT ===== */
.small-text {
    font-size: 0.75rem;
    color: var(--gray-500);
    margin-top: 4px;
    font-weight: 400;
}

/* ===== CEP GROUP ===== */
.cep-group {
    display: flex;
    align-items: center;
    gap: 8px;
    position: relative;
}

.loading-cep {
    display: none;
    width: 20px;
    height: 20px;
    border: 2px solid var(--gray-200);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ===== UPLOAD CARDS ===== */
.upload-grid-clean {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
    margin-top: 16px;
}

.upload-card-clean {
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    padding: 16px 12px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--gray-600);
}

.upload-card-clean:hover {
    background: var(--white);
    border-color: var(--primary);
    color: var(--primary);
    box-shadow: var(--shadow-sm);
}

/* ===== CARDS DE RESPONSÁVEL/TERCEIRO ===== */
.responsavel-card,
.terceiro-card,
.transporte-card {
    background: var(--gray-50);
    border-radius: 20px;
    padding: 24px;
    margin-bottom: 20px;
    border: 1px solid var(--gray-200);
    position: relative;
    transition: all var(--transition-base);
}

.responsavel-card:hover,
.terceiro-card:hover,
.transporte-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
}

.responsavel-card h3,
.terceiro-card h3,
.transporte-card h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--gray-800);
    margin-bottom: 20px;
    padding-right: 40px;
}

/* ===== BOTÃO REMOVER ===== */
.btn-remover {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    background: var(--white);
    border: 1px solid var(--gray-300);
    border-radius: 50%;
    color: var(--gray-500);
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.btn-remover:hover {
    background: var(--danger);
    border-color: var(--danger);
    color: var(--white);
    transform: rotate(90deg);
}

/* ===== BOTÕES PRINCIPAIS ===== */
.btn-nav {
    padding: 12px 28px;
    border: none;
    border-radius: 50px;
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-prev {
    background: var(--white);
    border: 1px solid var(--gray-300);
    color: var(--gray-600);
}

.btn-prev:hover:not(:disabled) {
    background: var(--gray-50);
    border-color: var(--gray-400);
    color: var(--gray-900);
}

.btn-next {
    background: var(--primary);
    color: white;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.2);
}

.btn-next:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.btn-save {
    background: var(--secondary);
    color: white;
    box-shadow: 0 2px 8px rgba(99, 102, 241, 0.2);
}

.btn-save:hover {
    background: #4F46E5;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.btn-add {
    background: var(--white);
    border: 1px dashed var(--primary);
    border-radius: 50px;
    padding: 12px 24px;
    color: var(--primary);
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-add:hover {
    background: var(--primary-light);
    border-style: solid;
}

.btn-add span {
    font-size: 1.2rem;
}

/* ===== BOTÕES CLEAN ===== */
.btn-clean {
    background: var(--white);
    color: var(--gray-700);
    border: 1px solid var(--gray-300);
    border-radius: 30px;
    padding: 8px 18px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    box-shadow: var(--shadow-sm);
}

.btn-clean:hover {
    background: var(--gray-50);
    border-color: var(--gray-400);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

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

.btn-clean.primary:hover {
    background: var(--primary-dark);
}

.btn-clean.danger {
    background: var(--white);
    border-color: var(--danger);
    color: var(--danger);
}

.btn-clean.danger:hover {
    background: var(--danger);
    color: white;
}

/* ===== BOTÕES CARD ===== */
.btn-card {
    padding: 8px 16px;
    border: none;
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-view {
    background: var(--gray-100);
    color: var(--gray-700);
}

.btn-view:hover {
    background: var(--gray-200);
}

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

.btn-edit:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.2);
}

/* ===== BOTÕES MODAL ===== */
.modal-btn {
    padding: 10px 24px;
    border: none;
    border-radius: 30px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

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

.modal-btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.2);
}

.modal-btn-secondary {
    background: var(--gray-100);
    color: var(--gray-700);
}

.modal-btn-secondary:hover {
    background: var(--gray-200);
}

.modal-btn-danger {
    background: var(--danger);
    color: white;
}

.modal-btn-danger:hover {
    background: #DC2626;
}

/* ===== CAMERA SECTION ===== */
.camera-section {
    margin-top: 20px;
    border: 1px solid var(--gray-200);
    border-radius: 16px;
    padding: 20px;
    background: var(--white);
}

.section-label {
    display: block;
    margin-bottom: 12px;
    font-weight: 500;
    color: var(--gray-700);
    font-size: 0.9rem;
}

.camera-preview {
    width: 100%;
    max-width: 320px;
    height: auto;
    border-radius: 16px;
    margin: 16px auto;
    display: none;
    box-shadow: var(--shadow-lg);
    border: 2px solid var(--white);
}

.camera-preview.active {
    display: block;
}

.camera-controls {
    display: flex;
    gap: 8px;
    margin-top: 12px;
    flex-wrap: wrap;
    justify-content: center;
}

.foto-capturada {
    max-width: 100px;
    max-height: 100px;
    border-radius: 12px;
    margin: 12px auto;
    border: 2px solid var(--primary);
    box-shadow: var(--shadow-md);
    display: none;
}

.foto-capturada.active {
    display: block;
}

/* ===== FORM ACTIONS ===== */
.navigation-buttons {
    display: flex;
    justify-content: space-between;
    margin-top: 32px;
    padding-top: 24px;
    border-top: 1px solid var(--gray-200);
}

/* ===== AUTORIZAÇÕES ===== */
.autorizacao-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: var(--gray-50);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.autorizacao-item:hover {
    background: var(--white);
    border-color: var(--gray-200);
}

.autorizacao-item input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: var(--primary);
}

/* ===== REVIEW SECTION ===== */
.review-section {
    background: var(--gray-50);
    border-radius: 20px;
    padding: 24px;
}

.review-icon {
    font-size: 3rem;
    margin-bottom: 16px;
}

.review-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 8px;
}

.review-text {
    color: var(--gray-600);
    margin-bottom: 24px;
}

.summary-card {
    background: var(--white);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 16px;
    border: 1px solid var(--gray-200);
    position: relative;
}

.summary-card h4 {
    color: var(--gray-800);
    margin-bottom: 16px;
    font-size: 1rem;
    font-weight: 600;
}

.summary-item {
    display: flex;
    margin-bottom: 8px;
    padding-bottom: 8px;
    border-bottom: 1px dashed var(--gray-200);
}

.summary-label {
    flex: 0 0 120px;
    font-weight: 500;
    color: var(--gray-600);
    font-size: 0.9rem;
}

.summary-value {
    flex: 1;
    color: var(--gray-900);
    font-size: 0.9rem;
}

.photo-thumbnail {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    object-fit: cover;
    border: 1px solid var(--gray-200);
}

.edit-button {
    position: absolute;
    top: 15px;
    right: 15px;
    background: var(--gray-100);
    border: 1px solid var(--gray-200);
    border-radius: 20px;
    padding: 5px 12px;
    font-size: 0.8rem;
    color: var(--gray-600);
    cursor: pointer;
    transition: all 0.2s ease;
}

.edit-button:hover {
    background: var(--primary);
    color: var(--white);
    border-color: var(--primary);
}

/* ===== STEP INDICATOR ===== */
.step-indicator {
    display: flex;
    justify-content: space-between;
    margin-bottom: 30px;
    padding: 16px 24px;
    background: var(--white);
    border-radius: 50px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--gray-200);
}

.step-item {
    flex: 1;
    text-align: center;
    position: relative;
    cursor: pointer;
}

.step-item:not(:last-child)::after {
    content: '';
    position: absolute;
    top: 20px;
    right: -20%;
    width: 40%;
    height: 2px;
    background: var(--gray-200);
    z-index: 0;
}

.step-item.completed:not(:last-child)::after {
    background: var(--primary);
}

.step-circle {
    width: 40px;
    height: 40px;
    background: var(--white);
    border: 2px solid var(--gray-300);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 8px;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--gray-500);
    position: relative;
    z-index: 2;
    transition: all 0.2s ease;
}

.step-item.active .step-circle {
    border-color: var(--primary);
    background: var(--primary);
    color: white;
}

.step-item.completed .step-circle {
    border-color: var(--primary);
    background: var(--primary);
    color: white;
}

.step-item.completed .step-circle::after {
    content: '✓';
    font-size: 1.2rem;
}

.step-item.completed .step-circle span {
    display: none;
}

.step-label {
    font-weight: 500;
    color: var(--gray-600);
    font-size: 0.85rem;
}

.step-item.active .step-label {
    color: var(--primary);
}

/* ===== STEP CONTENT ===== */
.step-content {
    display: none;
    animation: fadeIn 0.3s ease;
}

.step-content.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(5px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== NOTIFICAÇÕES FLUTUANTES ===== */
.notificacao-flutuante {
    position: fixed;
    top: 30px;
    right: 30px;
    min-width: 300px;
    max-width: 400px;
    background: var(--white);
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    z-index: 99999;
    animation: slideIn 0.3s ease forwards;
    overflow: hidden;
}

.notificacao-flutuante.success {
    border-left: 4px solid var(--primary);
}

.notificacao-flutuante.error {
    border-left: 4px solid var(--danger);
}

.notificacao-flutuante.warning {
    border-left: 4px solid var(--warning);
}

.notificacao-conteudo {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
}

.notificacao-icone {
    font-size: 1.3rem;
    line-height: 1;
}

.notificacao-texto {
    font-size: 0.95rem;
    color: var(--gray-900);
    font-weight: 500;
    flex: 1;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(100%) translateY(-20px);
    }

    to {
        opacity: 1;
        transform: translateX(0) translateY(0);
    }
}

@keyframes slideOut {
    from {
        opacity: 1;
        transform: translateX(0) translateY(0);
    }

    to {
        opacity: 0;
        transform: translateX(100%) translateY(-20px);
    }
}

/* ===== MODAL ===== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-container {
    background: var(--white);
    border-radius: 24px;
    max-width: 550px;
    width: 92%;
    max-height: 90vh;
    overflow: hidden;
    box-shadow: var(--shadow-2xl);
    transform: translateY(30px);
    transition: all 0.3s ease;
}

.modal-overlay.active .modal-container {
    transform: translateY(0);
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid var(--gray-200);
}

.modal-header h3 {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--gray-900);
    margin: 0;
}

.modal-close {
    width: 36px;
    height: 36px;
    background: var(--gray-100);
    border: 1px solid var(--gray-300);
    border-radius: 50%;
    color: var(--gray-600);
    font-size: 1.2rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    background: var(--danger);
    border-color: var(--danger);
    color: white;
    transform: rotate(90deg);
}

.modal-content {
    padding: 24px;
    max-height: calc(90vh - 140px);
    overflow-y: auto;
}

.modal-content::-webkit-scrollbar {
    width: 8px;
}

.modal-content::-webkit-scrollbar-track {
    background: var(--gray-100);
    border-radius: 10px;
}

.modal-content::-webkit-scrollbar-thumb {
    background: var(--gray-400);
    border-radius: 10px;
}

.modal-content::-webkit-scrollbar-thumb:hover {
    background: var(--gray-500);
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    padding: 20px 24px;
    border-top: 1px solid var(--gray-200);
}

/* ===== SEARCH ===== */
.search-container {
    max-width: 800px;
    margin: 0 auto 40px;
    padding: 20px;
    background: var(--white);
    border-radius: 60px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 1px solid var(--gray-200);
}

.search-box {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 4px 4px 4px 20px;
    background: var(--gray-50);
    border-radius: 50px;
}

.search-box i {
    color: var(--gray-400);
    font-size: 1.2rem;
}

.search-box input {
    flex: 1;
    border: none;
    background: transparent;
    padding: 14px 0;
    font-size: 1rem;
    color: var(--gray-900);
    outline: none;
}

.search-box input::placeholder {
    color: var(--gray-400);
}

.search-box button {
    background: var(--primary);
    color: white;
    border: none;
    padding: 12px 32px;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.search-box button:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.2);
}

.filters-bar {
    display: flex;
    gap: 12px;
    margin-top: 15px;
    flex-wrap: wrap;
}

.filter-select {
    padding: 10px 20px;
    border: 1px solid var(--gray-300);
    border-radius: 30px;
    background: var(--white);
    color: var(--gray-700);
    font-size: 0.9rem;
    cursor: pointer;
    outline: none;
}

.filter-select:hover {
    border-color: var(--primary);
}

/* ===== RESULTS ===== */
.results-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 24px;
    padding: 20px 0;
}

.aluno-card {
    background: var(--white);
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    border: 1px solid var(--gray-200);
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
}

.aluno-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    border-color: var(--primary);
}

/* ===== CARD HEADER DOS RESULTADOS (CORRIGIDO - SEM VERDE) ===== */
.aluno-card .card-header {
    background: var(--white);
    padding: 25px 20px 15px;
    text-align: center;
    position: relative;
    border-bottom: 1px solid var(--gray-200);
    margin-bottom: 0;
}

.aluno-card .foto-aluno {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    border: 3px solid var(--gray-200);
    margin: 0 auto 12px;
    object-fit: cover;
    background: var(--gray-50);
    transition: all 0.2s ease;
    box-shadow: var(--shadow-md);
}

.aluno-card:hover .foto-aluno {
    border-color: var(--primary);
    transform: scale(1.02);
}

.aluno-card .status-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: var(--gray-100);
    color: var(--gray-600);
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 500;
    border: 1px solid var(--gray-200);
    backdrop-filter: none;
}

.aluno-card h3 {
    color: var(--gray-900);
    font-size: 1.1rem;
    margin: 5px 0 2px;
}

.aluno-card p {
    color: var(--gray-600);
    font-size: 0.85rem;
    margin: 0;
}

.card-body {
    padding: 20px;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 15px;
    padding: 8px 12px;
    background: var(--gray-50);
    border-radius: 12px;
}

.info-icon {
    width: 32px;
    height: 32px;
    background: var(--white);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-size: 1rem;
}

.info-content {
    flex: 1;
}

.info-label {
    font-size: 0.7rem;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.info-value {
    font-weight: 600;
    color: var(--gray-900);
    font-size: 0.9rem;
}

.documentos-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 10px;
}

.doc-tag {
    background: var(--primary-light);
    color: var(--primary-dark);
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.doc-tag:hover {
    background: var(--primary);
    color: white;
}

.card-footer {
    padding: 15px 20px;
    border-top: 1px solid var(--gray-200);
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.no-results {
    text-align: center;
    padding: 60px 20px;
    background: var(--white);
    border-radius: 20px;
    border: 2px dashed var(--gray-300);
}

.no-results i {
    font-size: 4rem;
    color: var(--gray-400);
    margin-bottom: 20px;
}

.no-results h3 {
    color: var(--gray-900);
    margin-bottom: 10px;
}

.no-results p {
    color: var(--gray-600);
}

.loading-spinner {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 3px solid var(--gray-200);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

/* ===== DETALHES MODAL ===== */
.modal-detalhes {
    max-width: 800px;
    width: 90%;
}

.detalhes-grid {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 20px;
    margin-bottom: 20px;
}

.detalhes-foto {
    text-align: center;
}

.detalhes-foto img {
    width: 100%;
    max-width: 200px;
    border-radius: 20px;
    border: 4px solid var(--primary);
}

.detalhes-info {
    background: var(--gray-50);
    border-radius: 16px;
    padding: 20px;
}

.info-row {
    display: flex;
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px dashed var(--gray-300);
}

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

.info-row-label {
    flex: 0 0 120px;
    font-weight: 600;
    color: var(--gray-600);
}

.info-row-value {
    flex: 1;
    color: var(--gray-900);
}

/* ===== TABS ===== */
.tab-buttons {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    border-bottom: 2px solid var(--gray-200);
    padding-bottom: 10px;
    flex-wrap: wrap;
}

.tab-button {
    padding: 8px 20px;
    border: none;
    background: none;
    cursor: pointer;
    font-weight: 600;
    color: var(--gray-600);
    border-radius: 30px;
    transition: all 0.2s ease;
}

.tab-button:hover {
    background: var(--gray-100);
}

.tab-button.active {
    background: var(--primary);
    color: white;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* ===== UTILITÁRIOS ===== */
.text-center {
    text-align: center;
}

.text-left {
    text-align: left;
}

.text-right {
    text-align: right;
}

.mt-1 {
    margin-top: 4px;
}

.mt-2 {
    margin-top: 8px;
}

.mt-3 {
    margin-top: 12px;
}

.mt-4 {
    margin-top: 16px;
}

.mt-5 {
    margin-top: 20px;
}

.mt-6 {
    margin-top: 24px;
}

.mb-1 {
    margin-bottom: 4px;
}

.mb-2 {
    margin-bottom: 8px;
}

.mb-3 {
    margin-bottom: 12px;
}

.mb-4 {
    margin-bottom: 16px;
}

.mb-5 {
    margin-bottom: 20px;
}

.mb-6 {
    margin-bottom: 24px;
}

.p-1 {
    padding: 4px;
}

.p-2 {
    padding: 8px;
}

.p-3 {
    padding: 12px;
}

.p-4 {
    padding: 16px;
}

.p-5 {
    padding: 20px;
}

.p-6 {
    padding: 24px;
}

.hidden {
    display: none;
}

.visible {
    display: block;
}

.invisible {
    visibility: hidden;
}

.flex {
    display: flex;
}

.flex-col {
    flex-direction: column;
}

.items-center {
    align-items: center;
}

.justify-center {
    justify-content: center;
}

.justify-between {
    justify-content: space-between;
}

.gap-1 {
    gap: 4px;
}

.gap-2 {
    gap: 8px;
}

.gap-3 {
    gap: 12px;
}

.gap-4 {
    gap: 16px;
}

.gap-5 {
    gap: 20px;
}

.gap-6 {
    gap: 24px;
}

.w-full {
    width: 100%;
}

.h-full {
    height: 100%;
}

.rounded-sm {
    border-radius: var(--radius-sm);
}

.rounded-md {
    border-radius: var(--radius-md);
}

.rounded-lg {
    border-radius: var(--radius-lg);
}

.rounded-xl {
    border-radius: var(--radius-xl);
}

.rounded-full {
    border-radius: var(--radius-full);
}

.shadow-sm {
    box-shadow: var(--shadow-sm);
}

.shadow-md {
    box-shadow: var(--shadow-md);
}

.shadow-lg {
    box-shadow: var(--shadow-lg);
}

.shadow-xl {
    box-shadow: var(--shadow-xl);
}

.shadow-2xl {
    box-shadow: var(--shadow-2xl);
}

/* ===== RESPONSIVIDADE ===== */
@media (max-width: 1024px) {
    body {
        padding: 16px;
    }

    .header-progress {
        display: none;
    }

    .header-content {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }
}

@media (max-width: 768px) {
    body {
        padding: 12px;
    }

    main {
        padding: 20px;
    }

    .form-card {
        padding: 20px;
    }

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

    .navigation-buttons {
        flex-direction: column-reverse;
        gap: 12px;
    }

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

    .camera-controls {
        flex-direction: column;
    }

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

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

    .results-container {
        grid-template-columns: 1fr;
    }

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

    .tab-button {
        width: 100%;
        text-align: center;
    }

    .modal-footer {
        flex-direction: column;
    }

    .modal-btn {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .logo-wrapper {
        flex-direction: column;
        text-align: center;
    }

    .card-header {
        flex-wrap: wrap;
    }

    .badge {
        width: 100%;
        text-align: center;
    }

    .search-box {
        flex-direction: column;
        padding: 20px;
    }

    .search-box button {
        width: 100%;
    }

    .filters-bar {
        flex-direction: column;
    }

    .filter-select {
        width: 100%;
    }
}