/* dashboard.css - Estilos do Dashboard */

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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f5f5f5;
    display: flex;
    min-height: 100vh;
}

/* ========== SIDEBAR ========== */
.sidebar {
    width: 260px;
    background: linear-gradient(180deg, #667eea 0%, #764ba2 100%);
    color: white;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
    box-shadow: 2px 0 10px rgba(0,0,0,0.1);
    z-index: 1000;
    transition: transform 0.3s ease;
}

.sidebar-header {
    padding: 25px 20px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.sidebar-header h1 {
    font-size: 20px;
    margin-bottom: 5px;
}

.sidebar-header p {
    font-size: 12px;
    opacity: 0.8;
}

.user-profile {
    padding: 20px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.user-profile .name {
    font-weight: 600;
    margin-bottom: 5px;
    font-size: 14px;
}

.user-profile .badge {
    background: rgba(255,255,255,0.2);
    padding: 3px 10px;
    border-radius: 15px;
    font-size: 11px;
    text-transform: uppercase;
    display: inline-block;
}

.menu {
    padding: 20px 0;
}

.menu-item {
    padding: 12px 20px;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 12px;
    border-left: 3px solid transparent;
    font-size: 14px;
}

.menu-item:hover {
    background: rgba(255,255,255,0.1);
}

.menu-item.active {
    background: rgba(255,255,255,0.15);
    border-left-color: white;
}

.menu-item span:first-child {
    font-size: 18px;
    width: 20px;
}

.btn-logout-sidebar {
    margin: 20px;
    padding: 10px;
    background: rgba(255,255,255,0.2);
    border: none;
    color: white;
    border-radius: 5px;
    cursor: pointer;
    width: calc(100% - 40px);
    transition: all 0.3s;
    font-size: 14px;
}

.btn-logout-sidebar:hover {
    background: rgba(255,255,255,0.3);
}

/* ========== HAMBURGER MENU ========== */
.hamburger {
    display: none;
    position: fixed;
    top: 20px;
    left: 20px;
    z-index: 1001;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    color: white;
    padding: 10px 15px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

.overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 999;
}

/* ========== MAIN CONTENT ========== */
.main-content {
    margin-left: 260px;
    flex: 1;
    padding: 30px;
    width: calc(100% - 260px);
}

.top-bar {
    background: white;
    padding: 20px 30px;
    border-radius: 10px;
    margin-bottom: 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.top-bar h2 {
    color: #333;
    font-size: 24px;
}

/* ========== SECTIONS ========== */
.section {
    display: none;
}

.section.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========== CARDS ========== */
.card {
    background: white;
    border-radius: 10px;
    padding: 25px;
    margin-bottom: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.card h3 {
    color: #333;
    margin-bottom: 20px;
    font-size: 18px;
}

.welcome-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 40px;
    border-radius: 10px;
    text-align: center;
    margin-bottom: 30px;
}

.welcome-card h2 {
    font-size: 28px;
    margin-bottom: 10px;
}

.welcome-card p {
    font-size: 16px;
    opacity: 0.9;
}

/* ========== STATS GRID ========== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.stat-card h4 {
    font-size: 13px;
    opacity: 0.9;
    margin-bottom: 10px;
    font-weight: 500;
}

.stat-card .number {
    font-size: 36px;
    font-weight: bold;
}

/* ========== FORMS ========== */
.token-form {
    display: grid;
    gap: 15px;
    max-width: 500px;
}

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

label {
    color: #333;
    font-weight: 600;
    margin-bottom: 5px;
    font-size: 14px;
}

input, select {
    padding: 12px;
    border: 2px solid #e0e0e0;
    border-radius: 5px;
    font-size: 14px;
    transition: all 0.3s;
}

input:focus, select:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

/* ========== BUTTONS ========== */
.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s;
    font-size: 14px;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.3);
}

.btn-small {
    padding: 5px 12px;
    font-size: 11px;
    border-radius: 3px;
    border: none;
    cursor: pointer;
    margin-right: 5px;
    transition: all 0.3s;
    white-space: nowrap;
}

.btn-toggle {
    background: #ffc107;
    color: #000;
}

.btn-toggle:hover {
    background: #e0a800;
}

.btn-delete {
    background: #dc3545;
    color: white;
}

.btn-delete:hover {
    background: #c82333;
}

/* ========== TABLES ========== */
.table-container {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

table {
    width: 100%;
    border-collapse: collapse;
    min-width: 800px;
}

th, td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

th {
    background: #f8f9fa;
    font-weight: 600;
    color: #333;
    font-size: 13px;
    white-space: nowrap;
}

td {
    font-size: 14px;
}

td code {
    background: #f8f9fa;
    padding: 2px 6px;
    border-radius: 3px;
    font-family: 'Courier New', monospace;
}

/* ========== BADGES ========== */
.status-badge {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    display: inline-block;
    white-space: nowrap;
}

.status-ativo {
    background: #d4edda;
    color: #155724;
}

.status-inativo {
    background: #f8d7da;
    color: #721c24;
}

.tipo-administrador {
    background: #cce5ff;
    color: #004085;
}

.tipo-atendente {
    background: #d1ecf1;
    color: #0c5460;
}

/* ========== ALERTS ========== */
.alert {
    padding: 12px 15px;
    border-radius: 5px;
    margin-bottom: 20px;
    display: none;
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* ========== TOKEN DISPLAY ========== */
.token-display {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 5px;
    font-family: 'Courier New', monospace;
    font-size: 28px;
    font-weight: bold;
    text-align: center;
    margin-top: 15px;
    border: 2px dashed #667eea;
    letter-spacing: 4px;
}

.token-info {
    background: #e7f3ff;
    padding: 15px;
    border-radius: 5px;
    margin-top: 15px;
    border-left: 4px solid #667eea;
}

.token-info p {
    margin: 5px 0;
    font-size: 14px;
    color: #333;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
    }
    
    .sidebar.active {
        transform: translateX(0);
    }
    
    .hamburger {
        display: block;
    }
    
    .overlay.active {
        display: block;
    }
    
    .main-content {
        margin-left: 0;
        width: 100%;
        padding: 80px 15px 20px;
    }
    
    .top-bar {
        padding: 15px 20px;
    }
    
    .top-bar h2 {
        font-size: 20px;
    }
    
    .card {
        padding: 20px;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .stat-card {
        padding: 20px;
    }
    
    .stat-card .number {
        font-size: 28px;
    }
    
    .welcome-card {
        padding: 30px 20px;
    }
    
    .welcome-card h2 {
        font-size: 22px;
    }
    
    .welcome-card p {
        font-size: 14px;
    }
    
    .token-display {
        font-size: 20px;
        padding: 15px;
        letter-spacing: 2px;
    }
    
    table {
        font-size: 12px;
    }
    
    th, td {
        padding: 8px;
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .token-form {
        max-width: 100%;
    }
}
.status-atendida { background-color: #e6ffe6; }
.status-nao { background-color: #ffe6e6; }
.status-agendada { background-color: #fff0e6; }

.status-buttons button {
    border: none;
    padding: 4px 8px;
    margin: 2px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
}
.status-buttons button:hover { opacity: 0.8; }
/* === NOVO ESTILO DE CARDS DE INFORMAÇÕES === */

.card-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.info-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 3px 8px rgba(0,0,0,0.1);
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: all 0.3s ease;
    border-top: 4px solid transparent;
}

.info-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 6px 14px rgba(0,0,0,0.15);
}

.info-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.info-header h3 {
    font-size: 18px;
    color: #333;
}

.info-status {
    font-size: 12px;
    font-weight: 600;
    background: #e0e0e0;
    color: #333;
    border-radius: 10px;
    padding: 3px 10px;
}

.info-body {
    font-size: 14px;
    color: #555;
    margin-bottom: 12px;
}

.info-body p {
    margin-bottom: 4px;
}

.info-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.status-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.btn-status {
    border: none;
    border-radius: 5px;
    padding: 6px 10px;
    font-size: 12px;
    cursor: pointer;
    color: white;
    transition: all 0.3s;
}

.btn-status.atendida { background: #28a745; }
.btn-status.nao { background: #dc3545; }
.btn-status.agendada { background: #ff9800; }

.btn-status:hover { opacity: 0.9; }

.status-atendida {
    border-top-color: #28a745;
    background: #f0fff0;
}

.status-nao {
    border-top-color: #dc3545;
    background: #fff5f5;
}

.status-agendada {
    border-top-color: #ff9800;
    background: #fff8e6;
}
