:root {
    --primary-color: #007bff;
    --secondary-color: #6c757d;
    --success-color: #28a745;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --light-color: #f8f9fa;
    --dark-color: #343a40;
    --border-radius: 8px;
    --box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --card-primary: #4e73df;
    --card-success: #1cc88a;
    --card-warning: #f6c23e;
    --card-info: #36b9cc;
}

/* Dashboard Stats - Versão Atualizada */
.dashboard-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    padding: 20px;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    border-left: 4px solid var(--card-primary);
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.stat-card.total {
    border-left-color: var(--card-primary);
}

.stat-card.approved {
    border-left-color: var(--card-success);
}

.stat-card.pending {
    border-left-color: var(--card-warning);
}

.stat-card.month {
    border-left-color: var(--card-info);
}

.stat-card .stat-icon {
    font-size: 2rem;
    color: rgba(0,0,0,0.15);
    position: absolute;
    right: 20px;
    top: 20px;
}

.stat-card .stat-content {
    position: relative;
    z-index: 1;
}

.stat-card .stat-title {
    color: var(--secondary-color);
    font-size: 0.9rem;
    text-transform: uppercase;
    font-weight: 600;
    margin-bottom: 5px;
}

.stat-card .stat-value {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--dark-color);
    margin: 0;
}

.stat-card .stat-change {
    font-size: 0.8rem;
    margin-top: 5px;
    display: flex;
    align-items: center;
}

.stat-card .stat-change.positive {
    color: var(--success-color);
}

.stat-card .stat-change.negative {
    color: var(--danger-color);
}

/* Responsividade */
@media (max-width: 768px) {
    .dashboard-stats {
        grid-template-columns: 1fr;
    }
    
    .stat-card {
        padding: 15px;
    }
    
    .stat-card .stat-value {
        font-size: 1.5rem;
    }
}

/* Adicione estas classes para os ícones específicos */
.stat-card .fa-plane-departure {
    color: rgba(78, 115, 223, 0.2);
}

.stat-card .fa-check-circle {
    color: rgba(28, 200, 138, 0.2);
}

.stat-card .fa-clock {
    color: rgba(246, 194, 62, 0.2);
}

.stat-card .fa-calendar-alt {
    color: rgba(54, 185, 204, 0.2);
}

/* Travel Request Form Styling */
.step-indicator {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    margin-bottom: 30px;
    position: relative;
}

.step-indicator::before {
    content: '';
    position: absolute;
    top: 20px;
    left: 0;
    right: 0;
    height: 2px;
    background: #e9ecef;
    z-index: 1;
}

.step {
    position: relative;
    z-index: 2;
    text-align: center;
    width: 33.33%;
}

.step-number {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #e9ecef;
    color: #6c757d;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 10px;
    font-weight: bold;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.step.active .step-number {
    background-color: var(--primary-color);
    color: white;
    box-shadow: 0 0 0 5px rgba(0, 123, 255, 0.2);
}

.step.completed .step-number {
    background-color: var(--success-color);
    color: white;
}

.step-title {
    font-size: 0.9rem;
    color: #6c757d;
    font-weight: 500;
}

.step.active .step-title {
    color: var(--primary-color);
    font-weight: 600;
}

/* Fix for responsive layout */
@media (max-width: 768px) {
    .step-indicator {
        flex-direction: row;
        align-items: center;
        flex-wrap: wrap;
    }
    
    .step-indicator::before {
        display: block;
    }
    
    .step {
        width: 33.33%;
        margin-bottom: 15px;
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    
    .step-number {
        margin: 0 auto 10px;
    }
}

.form-section {
    background-color: #fff;
    border-radius: var(--border-radius);
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.form-section h4 {
    color: var(--primary-color);
    border-bottom: 2px solid #f0f0f0;
    padding-bottom: 10px;
    margin-bottom: 20px;
    font-weight: 600;
}

.form-section h5 {
    color: #495057;
    font-weight: 600;
    margin-top: 25px;
    margin-bottom: 15px;
    font-size: 1.1rem;
}

.declaration-box {
    max-height: 200px;
    overflow-y: auto;
    background-color: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: var(--border-radius);
    padding: 15px;
    font-size: 0.9rem;
}

.trecho-item {
    border-left: 4px solid var(--primary-color);
    transition: all 0.3s ease;
}

.trecho-item:hover {
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.trecho-item .card-title {
    color: var(--primary-color);
    font-weight: 600;
}

#diarias_info {
    background: linear-gradient(to right, #f8f9fa, #e9ecef);
    border-radius: var(--border-radius);
    transition: all 0.3s ease;
}

#diarias_info:hover {
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

#diarias_info .card-title {
    color: var(--primary-color);
    font-weight: 600;
}

#diaria_total {
    font-size: 1.2rem;
    color: var(--primary-color);
}

/* Custom Form Controls */
.form-control {
    border-radius: var(--border-radius);
    border: 1px solid #ced4da;
    padding: 12px 15px;
    transition: all 0.3s ease;
    min-height: 42px;
    line-height: 1.5;
    font-size: 14px;
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

select.form-control {
    padding: 12px 35px 12px 15px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='8' viewBox='0 0 8 8'%3E%3Cpath fill='%23343a40' d='M2.5 0L1 1.5 3.5 4 1 6.5 2.5 8l4-4-4-4z' transform='rotate(90 4 4)'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 15px center;
    background-size: 8px 8px;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    min-width: 200px;
    width: 100%;
    min-height: 42px;
    line-height: 1.5;
    font-size: 14px;
    overflow: visible;
    text-overflow: clip;
}

/* Garantir que as opções de todos os selects tenham largura adequada */
select.form-control option {
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
    padding: 8px 12px;
    line-height: 1.4;
}

/* Garantir que colunas com selects tenham largura suficiente */
.form-group:has(select) {
    min-width: 250px;
    flex: 0 0 auto;
}

/* Fallback para navegadores que não suportam :has() - aplicar a todas as colunas md-4 */
.col-md-4 {
    min-width: 250px;
    flex: 0 0 auto;
}

/* Ajustes específicos para inputs de data e texto */
input.form-control {
    min-height: 42px;
    line-height: 1.5;
    font-size: 14px;
    padding: 12px 15px;
}

/* Ajustes para textarea */
textarea.form-control {
    min-height: 80px;
    line-height: 1.5;
    font-size: 14px;
    padding: 12px 15px;
    resize: vertical;
}

.btn {
    border-radius: var(--border-radius);
    padding: 10px 20px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-primary:hover {
    background-color: #0069d9;
    border-color: #0062cc;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.btn-secondary {
    background-color: var(--secondary-color);
    border-color: var(--secondary-color);
}

.btn-secondary:hover {
    background-color: #5a6268;
    border-color: #545b62;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.form-check-input {
    margin-top: 0.3rem;
}

.form-check-label {
    margin-bottom: 0;
    margin-left: 5px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .step-indicator {
        flex-direction: column;
        align-items: center;
    }
    
    .step-indicator::before {
        display: none;
    }
    
    .step {
        width: 100%;
        margin-bottom: 15px;
        display: flex;
        align-items: center;
    }
    
    .step-number {
        margin: 0 15px 0 0;
    }
    
    .form-section {
        padding: 15px;
    }
}

/* Navbar Styling */
.navbar {
    background-color: var(--primary-color);
    padding: 0.8rem 1rem;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.navbar-brand img {
    max-height: 40px;
}

/* Garantindo que os links sejam visíveis */
.navbar .navbar-nav .nav-link {
    color: white !important; /* Forçando cor branca para os links */
    font-weight: 500;
    padding: 0.5rem 1rem;
    transition: all 0.3s ease;
}

.navbar .navbar-nav .nav-link:hover,
.navbar .navbar-nav .nav-link:focus {
    color: #ffffff !important;
    background-color: rgba(255,255,255,0.2);
    background-color: rgba(255,255,255,0.1);
    border-radius: var(--border-radius);
}

.navbar .navbar-nav .active > .nav-link {
    color: #ffffff !important;
    background-color: rgba(255,255,255,0.15);
    border-radius: var(--border-radius);
    font-weight: 600;
}

/* Page Title Styling */
.page-title {
    padding-bottom: 15px;
    border-bottom: 1px solid #eaeaea;
}

.page-title h2 {
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.page-title h2 i {
    margin-right: 10px;
}

.page-title p {
    font-size: 1rem;
    margin-bottom: 0;
}

/* Estilos adicionais para a barra de navegação */
.navbar-dark {
    background-color: #0056b3 !important;
}

.navbar .navbar-toggler {
    border-color: rgba(255, 255, 255, 0.5);
}

.navbar .navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='30' height='30' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(255, 255, 255, 0.85)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* Destaque para o item ativo do menu */
.navbar .nav-item.active .nav-link {
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
}

/* Ajustes para o botão de notificações */
.notification-badge {
    position: absolute;
    top: 0;
    right: 0;
    background-color: #dc3545;
    color: white;
    border-radius: 50%;
    padding: 0.2rem 0.5rem;
    font-size: 0.75rem;
}

/* Estilos para o dropdown de notificações */
.notifications-dropdown {
    min-width: 300px;
    padding: 0;
}

.notifications-content {
    max-height: 300px;
    overflow-y: auto;
}

/* Estilos para controles de pernoites */
#edit_pernoites_manual .form-control-sm {
    margin-top: 5px;
    font-size: 0.875rem;
}

.form-check-inline {
    margin-bottom: 8px;
}

.form-check-label {
    font-size: 0.875rem;
    color: #6c757d;
}

#edit_pernoites_display {
    font-weight: bold;
    color: #495057;
}