* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-primary);
    background-color: var(--bg-main);
    color: var(--text-dark);
    height: 100vh;
    overflow: hidden;
}

.app-container {
    display: flex;
    width: 100%;
    height: 100vh;
}

/* BARRA LATERAL */
.sidebar {
    width: 260px;
    background-color: var(--bg-sidebar);
    color: var(--text-light);
    display: flex;
    flex-direction: column;
    padding: 20px 0;
}

.brand {
    display: flex;
    align-items: center;
    padding: 0 20px 20px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.brand-logo {
    font-size: 24px;
    color: var(--color-warning);
    margin-right: 12px;
}

.brand-text h1 {
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 1px;
}

.brand-text span {
    font-size: 10px;
    color: var(--text-muted);
    display: block;
}

.menu {
    flex: 1;
    padding: 20px 0;
    overflow-y: auto;
}

.menu-category {
    display: block;
    padding: 15px 20px 5px 20px;
    font-size: 11px;
    text-transform: uppercase;
    color: var(--text-muted);
    font-weight: 600;
    letter-spacing: 0.5px;
}

.menu-item {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 14px;
    transition: all 0.2s ease;
}

.menu-item i {
    margin-right: 12px;
    width: 18px;
    text-align: center;
}

.menu-item:hover, .menu-item.active {
    background-color: var(--bg-sidebar-active);
    color: var(--text-light);
    border-left: 4px solid var(--color-success);
}

.sidebar-footer {
    padding: 0 20px;
}

.btn-logout {
    width: 100%;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--text-light);
    padding: 10px;
    border-radius: var(--border-radius);
    cursor: pointer;
    font-family: var(--font-primary);
    transition: background 0.2s;
}

.btn-logout:hover {
    background-color: var(--color-danger);
    border-color: var(--color-danger);
}

/* ÁREA DE CONTEÚDO PRINCIPAL */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

.main-header {
    background-color: var(--bg-sidebar);
    color: var(--text-light);
    height: 70px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 30px;
}

.page-title h2 {
    font-size: 20px;
    font-weight: 500;
}

.user-profile {
    display: flex;
    align-items: center;
    gap: 20px;
}

.status-indicator {
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.dot.online {
    width: 10px;
    height: 10px;
    background-color: var(--color-success);
    border-radius: 50%;
    display: inline-block;
}

.icon-notification {
    font-size: 18px;
    cursor: pointer;
    position: relative;
}

.user-info {
    text-align: right;
}

.user-name {
    display: block;
    font-size: 14px;
    font-weight: 500;
}

.user-role {
    display: block;
    font-size: 11px;
    color: var(--text-muted);
}

.user-avatar {
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--bg-sidebar-active);
}

.content-body {
    padding: 30px;
}
/* REGRAS GERAIS DE CARDS */
.card {
    background-color: var(--bg-card);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    padding: 24px;
    margin-bottom: 24px;
    border: 1px solid rgba(0, 0, 0, 0.03);
}

.card h3 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 16px;
    color: var(--bg-sidebar);
    display: flex;
    align-items: center;
    gap: 8px;
}

/* SEÇÃO DE CONSULTA RÁPIDA */
.search-label {
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 12px;
    font-weight: 500;
}

.search-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    border-bottom: 2px solid var(--bg-main);
    padding-bottom: 8px;
}

.tab-btn {
    background: none;
    border: none;
    padding: 8px 16px;
    font-family: var(--font-primary);
    font-size: 14px;
    font-weight: 500;
    color: var(--text-muted);
    cursor: pointer;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.tab-btn:hover {
    color: var(--bg-sidebar);
    background-color: rgba(0, 0, 0, 0.02);
}

.tab-btn.active {
    background-color: var(--bg-sidebar);
    color: var(--text-light);
}

.search-input-group {
    display: flex;
    gap: 12px;
}

.input-wrapper {
    position: relative;
    flex: 1;
}

.input-wrapper input {
    width: 100%;
    padding: 14px 16px 14px 42px;
    border: 1px solid #dcdfe6;
    border-radius: var(--border-radius);
    font-family: var(--font-primary);
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s;
}

.input-wrapper input:focus {
    border-color: var(--bg-sidebar-active);
}

.input-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 16px;
}

.btn-primary {
    background-color: #0b2240; /* Azul escuro igual ao botão consultar */
    color: var(--text-light);
    border: none;
    padding: 0 30px;
    border-radius: var(--border-radius);
    font-family: var(--font-primary);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: background 0.2s;
}

.btn-primary:hover {
    background-color: var(--bg-sidebar-active);
}

/* PAINEL DE RESULTADOS (LAYOUT EM DUAS COLUNAS) */
.results-container {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 24px;
    align-items: start;
}

/* CARDS DE PERFIL / CONDUTOR */
.profile-header {
    display: flex;
    align-items: center;
    gap: 20px;
    border-bottom: 1px solid #f0f2f5;
    padding-bottom: 20px;
    margin-bottom: 20px;
}

.driver-photo-wrapper {
    width: 75px;
    height: 75px;
    border-radius: 50%;
    overflow: hidden;
    border: 3px solid #eef1f6;
}

.driver-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.driver-main-info h4 {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-dark);
    margin: 4px 0;
}

.driver-contacts {
    font-size: 13px;
    color: var(--text-muted);
}

.badge {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.badge-success {
    background-color: rgba(46, 196, 182, 0.15);
    color: var(--color-success);
}

/* GRID DE DETALHES INTERNOS */
.profile-details-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
}

.detail-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.detail-label {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.detail-value {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-dark);
}

.text-success { color: var(--color-success); }
.text-danger { color: var(--color-danger); }

/* BARRA DE PROGRESSO DA PONTUAÇÃO */
.highlight-pontuacao {
    grid-column: span 1;
}

.score-wrapper {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.score-wrapper small {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 400;
}

.score-bar {
    width: 100%;
    height: 6px;
    background-color: #eef1f6;
    border-radius: 3px;
    overflow: hidden;
}

.score-progress {
    height: 100%;
    background-color: var(--color-success);
    border-radius: 3px;
}

/* BLOCO LATERAL DE AÇÕES */
.actions-description {
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 20px;
}

.actions-buttons-stack {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.btn-action-outline {
    width: 100%;
    background: none;
    border: 1px solid var(--bg-sidebar-active);
    color: var(--bg-sidebar-active);
    padding: 12px;
    border-radius: var(--border-radius);
    font-family: var(--font-primary);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.2s ease;
}

.btn-action-outline:hover {
    background-color: rgba(30, 61, 107, 0.05);
}

.btn-action-danger {
    width: 100%;
    background-color: var(--color-danger);
    border: none;
    color: var(--text-light);
    padding: 12px;
    border-radius: var(--border-radius);
    font-family: var(--font-primary);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: background 0.2s;
}

.btn-action-danger:hover {
    background-color: #bd1427;
}

/* Ocultar resultados por padrão antes da busca (Utility Class) */
.hidden {
    display: none !important;
}
/* ESTILOS ESPECÍFICOS DO DASHBOARD */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 24px;
}

.stat-card {
    background-color: var(--bg-card);
    padding: 20px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    display: flex;
    align-items: center;
    gap: 16px;
    border: 1px solid rgba(0, 0, 0, 0.02);
}

.stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.icon-blue { background-color: rgba(11, 34, 64, 0.1); color: var(--bg-sidebar); }
.icon-green { background-color: rgba(46, 196, 182, 0.1); color: var(--color-success); }
.icon-orange { background-color: rgba(255, 159, 28, 0.1); color: var(--color-warning); }

.stat-info {
    display: flex;
    flex-direction: column;
}

.stat-label {
    font-size: 13px;
    color: var(--text-muted);
    font-weight: 500;
}

.stat-number {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-dark);
}

/* LAYOUT DE PAINÉIS */
.dashboard-panels {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}

/* QUADRÍCULA DE AÇÕES (TILES) */
.actions-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.action-tile {
    background-color: var(--bg-main);
    border: 1px solid rgba(0, 0, 0, 0.05);
    padding: 20px;
    border-radius: var(--border-radius);
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    transition: all 0.2s ease;
}

.action-tile i {
    font-size: 24px;
}

.action-tile span {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-dark);
}

.action-tile:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    background-color: var(--text-light);
}

/* LISTA DE NOTIFICAÇÕES */
.notification-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.noti-item {
    display: flex;
    align-items: start;
    gap: 12px;
    padding: 12px;
    background-color: var(--bg-main);
    border-radius: 6px;
    border-left: 4px solid var(--text-muted);
}

.status-border-green { border-left-color: var(--color-success); }
.status-border-red { border-left-color: var(--color-danger); }

.noti-text p {
    font-size: 13px;
    color: var(--text-dark);
}

.noti-text span {
    font-size: 11px;
    color: var(--text-muted);
}

/* CORES UTILITY */
.text-blue { color: var(--bg-sidebar); }
.text-red { color: var(--color-danger); }
.text-orange { color: var(--color-warning); }

.view-section {
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(5px); }
    to { opacity: 1; transform: translateY(0); }
}
.form-input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #dcdfe6;
    border-radius: var(--border-radius);
    font-family: var(--font-primary);
    font-size: 14px;
    background-color: #fff;
    outline: none;
}
.form-input[readonly] {
    background-color: #f5f7fa;
    color: var(--text-muted);
    cursor: not-allowed;
}
.calc-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
    font-size: 14px;
}
.calc-row strong { font-weight: 600; }