/* Variáveis CSS */
:root {
    --primary-color: #1e40af;
    --secondary-color: #3b82f6;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --dark-color: #1f2937;
    --light-color: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;
    --border-radius: 0.5rem;
    --box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --transition: all 0.3s ease;
}

/* Reset e Configurações Globais */
* {
    box-sizing: border-box;
}

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

.main-content {
    padding-top: 80px;
    min-height: calc(100vh - 200px);
}

/* Customização do Bootstrap */
.bg-primary {
    background-color: var(--primary-color) !important;
}

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

.btn-primary:hover {
    background-color: var(--secondary-color);
    border-color: var(--secondary-color);
    transform: translateY(-1px);
}

.text-primary {
    color: var(--primary-color) !important;
}

/* Cards e Componentes */
.card {
    border: none;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    overflow: hidden;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.card-header {
    background-color: white;
    border-bottom: 2px solid var(--gray-100);
    font-weight: 600;
    color: var(--gray-800);
}

/* Navegação */
.navbar-brand img {
    /* Removido o filtro que estava causando problemas */
}

/* Logo do cabeçalho */
.logo-header {
    height: 50px;
    width: auto;
    transition: var(--transition);
    filter: none !important;
    max-width: 225px;
    background: rgba(0, 51, 102, 0.8); /* Fundo azul translúcido mais visível */
    border-radius: 10px;
    padding: 5px 10px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.logo-header:hover {
    transform: scale(1.05);
    background: rgba(0, 51, 102, 0.9);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.navbar-brand {
    padding: 0.5rem 0;
}

/* Responsividade do logo */
@media (max-width: 768px) {
    .logo-header {
        height: 45px;
        max-width: 190px;
        padding: 4px 8px;
        border-radius: 8px;
    }
    
    .navbar-brand {
        padding: 0.25rem 0;
    }
    
    /* Melhorar navbar mobile */
    .navbar-toggler {
        padding: 0.25rem 0.5rem;
        font-size: 1rem;
    }
    
    .navbar-nav .nav-link {
        padding: 0.5rem 0;
    }
}

@media (max-width: 576px) {
    .logo-header {
        height: 40px;
        max-width: 165px;
        padding: 3px 6px;
        border-radius: 6px;
    }
    
    .navbar-brand {
        padding: 0.25rem 0;
    }
    
    /* Melhorar espaçamento do navbar no mobile */
    .navbar-collapse {
        margin-top: 0.5rem;
    }
    
    /* Container mais responsivo */
    .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }
    
    /* Dropdown DETRAN responsivo */
    .detran-dropdown {
        max-width: 280px;
        left: -120px !important;
    }
}

/* Tela muito pequena (smartphones pequenos) */
@media (max-width: 375px) {
    .logo-header {
        height: 35px;
        max-width: 140px;
        padding: 3px 5px;
        border-radius: 5px;
    }
}

.navbar-dark .navbar-nav .nav-link {
    color: rgba(255, 255, 255, 0.9);
    transition: var(--transition);
}

.navbar-dark .navbar-nav .nav-link:hover {
    color: white;
    transform: translateY(-1px);
}

.dropdown-menu {
    border: none;
    box-shadow: var(--box-shadow);
    border-radius: var(--border-radius);
}

.dropdown-item:hover {
    background-color: var(--gray-100);
    color: var(--primary-color);
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    padding: 100px 0;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('../images/Logo_Symbol-adam-1.png') no-repeat center center;
    background-size: 200px;
    opacity: 0.1;
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

/* Features Section */
.features-section {
    padding: 80px 0;
}

.feature-card {
    text-align: center;
    padding: 2rem;
    height: 100%;
    border: 1px solid var(--gray-200);
    border-radius: var(--border-radius);
    transition: var(--transition);
}

.feature-card:hover {
    border-color: var(--primary-color);
    transform: translateY(-5px);
}

.feature-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    color: white;
    font-size: 2rem;
}

/* Services Grid */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    padding: 2rem 0;
}

.service-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    border: 1px solid var(--gray-200);
    transition: var(--transition);
    position: relative;
}

.service-card:hover {
    border-color: var(--primary-color);
    box-shadow: var(--box-shadow);
}

.service-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    padding: 0.25rem 0.5rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    font-weight: 600;
}

.badge-online {
    background-color: var(--success-color);
    color: white;
}

.badge-partial {
    background-color: var(--warning-color);
    color: white;
}

.service-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--gray-800);
    margin-bottom: 1rem;
}

.service-price {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.price-item {
    text-align: center;
}

.price-label {
    font-size: 0.875rem;
    color: var(--gray-500);
    margin-bottom: 0.25rem;
}

.price-value {
    font-weight: 600;
    color: var(--gray-800);
}

.service-steps {
    margin-top: 1rem;
}

.step-item {
    display: flex;
    align-items: center;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
}

.step-number {
    width: 20px;
    height: 20px;
    background-color: var(--primary-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    margin-right: 0.75rem;
    flex-shrink: 0;
}

/* Dashboard */
.dashboard-header {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 2rem 0;
    margin-bottom: 2rem;
}

.stat-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    text-align: center;
    border: 1px solid var(--gray-200);
    transition: var(--transition);
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--box-shadow);
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    color: white;
    font-size: 1.5rem;
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: var(--gray-800);
    margin-bottom: 0.5rem;
}

.stat-label {
    color: var(--gray-500);
    font-size: 0.875rem;
}

/* Process Timeline */
.timeline {
    position: relative;
    padding-left: 2rem;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 15px;
    top: 0;
    bottom: 0;
    width: 2px;
    background-color: var(--gray-300);
}

.timeline-item {
    position: relative;
    margin-bottom: 2rem;
}

.timeline-marker {
    position: absolute;
    left: -25px;
    top: 0;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.875rem;
    z-index: 1;
}

.timeline-marker.completed {
    background-color: var(--success-color);
}

.timeline-marker.current {
    background-color: var(--primary-color);
}

.timeline-marker.pending {
    background-color: var(--gray-400);
}

.timeline-content {
    background: white;
    border-radius: var(--border-radius);
    padding: 1rem;
    border: 1px solid var(--gray-200);
}

.timeline-title {
    font-weight: 600;
    color: var(--gray-800);
    margin-bottom: 0.5rem;
}

.timeline-description {
    color: var(--gray-600);
    font-size: 0.875rem;
}

/* Chat */
.chat-container {
    height: 500px;
    overflow-y: auto;
    border: 1px solid var(--gray-200);
    border-radius: var(--border-radius);
    padding: 1rem;
    background: white;
}

.message {
    margin-bottom: 1rem;
    display: flex;
}

.message.user {
    justify-content: flex-end;
}

.message.admin {
    justify-content: flex-start;
}

.message-content {
    max-width: 70%;
    padding: 0.75rem 1rem;
    border-radius: 1rem;
    font-size: 0.875rem;
}

.message.user .message-content {
    background-color: var(--primary-color);
    color: white;
    border-bottom-right-radius: 0.25rem;
}

.message.admin .message-content {
    background-color: var(--gray-100);
    color: var(--gray-800);
    border-bottom-left-radius: 0.25rem;
}

.message-time {
    font-size: 0.75rem;
    color: var(--gray-500);
    margin-top: 0.25rem;
}

/* Forms */
.form-control, .form-select {
    border: 1px solid var(--gray-300);
    border-radius: var(--border-radius);
    padding: 0.75rem;
    transition: var(--transition);
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(30, 64, 175, 0.25);
}

.form-label {
    font-weight: 500;
    color: var(--gray-700);
    margin-bottom: 0.5rem;
}

/* Admin Dashboard */
.admin-sidebar {
    background-color: var(--gray-800);
    min-height: calc(100vh - 80px);
    padding: 2rem 0;
}

.admin-nav-link {
    color: var(--gray-300);
    padding: 0.75rem 1.5rem;
    display: block;
    text-decoration: none;
    transition: var(--transition);
    border-left: 3px solid transparent;
}

.admin-nav-link:hover, .admin-nav-link.active {
    color: white;
    background-color: var(--gray-700);
    border-left-color: var(--primary-color);
}

/* Responsividade */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .main-content {
        padding-top: 70px;
    }
    
    .timeline {
        padding-left: 1.5rem;
    }
    
    .timeline-marker {
        left: -20px;
        width: 25px;
        height: 25px;
    }
    
    .message-content {
        max-width: 85%;
    }
}

@media (max-width: 576px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .feature-card {
        padding: 1.5rem;
    }
    
    .feature-icon {
        width: 60px;
        height: 60px;
        font-size: 1.5rem;
    }
    
    .stat-card {
        padding: 1rem;
    }
    
    .stat-icon {
        width: 50px;
        height: 50px;
        font-size: 1.25rem;
    }
}

/* Animações */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

/* Utilitários */
.bg-gradient-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
}

.text-gradient {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.shadow-lg {
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05) !important;
}

.border-primary {
    border-color: var(--primary-color) !important;
}

/* Loading Spinner */
.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid var(--gray-200);
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto;
}

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

/* DETRAN Dropdown Styles */
.detran-dropdown {
    min-width: 250px;
    max-height: 400px;
    overflow-y: auto;
    border: none;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    border-radius: 8px;
    padding: 8px 0;
    margin-top: 8px;
}

.detran-dropdown .dropdown-header {
    font-weight: 600;
    color: var(--primary-color);
    padding: 8px 16px;
    margin-bottom: 4px;
}

.detran-dropdown .dropdown-divider {
    margin: 4px 0;
    border-color: var(--gray-200);
}

.detran-dropdown .dropdown-item {
    padding: 8px 16px;
    display: flex;
    align-items: center;
    transition: all 0.2s ease;
    border: none;
    background: none;
}

.detran-dropdown .dropdown-item:hover {
    background-color: var(--gray-100);
    color: var(--primary-color);
    transform: translateX(4px);
}

.detran-dropdown .dropdown-item.active {
    background-color: var(--primary-color);
    color: white;
}

.detran-dropdown .dropdown-item.active:hover {
    background-color: var(--secondary-color);
    color: white;
    transform: translateX(4px);
}

#stateFlagIcon {
    display: inline-block;
    transition: transform 0.2s ease;
}

#detranSelector:hover #stateFlagIcon {
    transform: scale(1.1);
}

/* Scroll personalizado para o dropdown */
.detran-dropdown::-webkit-scrollbar {
    width: 6px;
}

.detran-dropdown::-webkit-scrollbar-track {
    background: var(--gray-100);
    border-radius: 3px;
}

.detran-dropdown::-webkit-scrollbar-thumb {
    background: var(--gray-400);
    border-radius: 3px;
}

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

/* Animação para o dropdown */
.dropdown-menu {
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    display: block;
    visibility: hidden;
}

.dropdown-menu.show {
    opacity: 1;
    transform: translateY(0);
    visibility: visible;
}

/* Garantir que o dropdown funcione corretamente */
.nav-item.dropdown {
    position: relative;
}

.dropdown-toggle::after {
    transition: transform 0.3s ease;
}

.dropdown-toggle[aria-expanded="true"]::after {
    transform: rotate(180deg);
} 