/**
 * Sistema de Gestion IT - Estilos Personalizados
 */

/* Variables */
:root {
    --primary-color: #0d6efd;
    --dark-color: #212529;
    --light-bg: #f8f9fa;
}

/* General */
html, body {
    height: 100%;
}

body {
    display: flex;
    flex-direction: column;
    background-color: var(--light-bg);
}

main {
    flex: 1;
}

/* Login Page */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.login-card {
    width: 100%;
    max-width: 400px;
    border: none;
    border-radius: 1rem;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

.login-card .card-header {
    background: var(--dark-color);
    color: white;
    border-radius: 1rem 1rem 0 0 !important;
    padding: 1.5rem;
    text-align: center;
}

.login-card .card-body {
    padding: 2rem;
}

/* Cards */
.card {
    border: none;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    margin-bottom: 1.5rem;
}

.card-header {
    background-color: white;
    border-bottom: 1px solid rgba(0, 0, 0, 0.125);
    font-weight: 600;
}

/* Dashboard Stats */
.stat-card {
    border-left: 4px solid var(--primary-color);
}

.stat-card.success { border-left-color: #198754; }
.stat-card.warning { border-left-color: #ffc107; }
.stat-card.danger { border-left-color: #dc3545; }
.stat-card.info { border-left-color: #0dcaf0; }

.stat-card .stat-icon {
    font-size: 2.5rem;
    opacity: 0.3;
}

.stat-card .stat-number {
    font-size: 2rem;
    font-weight: 700;
}

/* Tables */
.table-responsive {
    border-radius: 0.5rem;
}

.table th {
    background-color: var(--light-bg);
    font-weight: 600;
    white-space: nowrap;
}

.table-hover tbody tr:hover {
    background-color: rgba(13, 110, 253, 0.05);
}

/* Action Buttons */
.btn-actions {
    white-space: nowrap;
}

.btn-actions .btn {
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
}

/* Sidebar for mobile */
@media (max-width: 991.98px) {
    .navbar-collapse {
        background-color: var(--dark-color);
        padding: 1rem;
        margin-top: 0.5rem;
        border-radius: 0.5rem;
    }
}

/* Forms */
.form-label {
    font-weight: 500;
}

.required::after {
    content: ' *';
    color: #dc3545;
}

/* Password toggle */
.password-toggle {
    cursor: pointer;
}

/* Badges */
.badge {
    font-weight: 500;
}

/* Page Header */
.page-header {
    margin-bottom: 1.5rem;
}

.page-header h1 {
    font-size: 1.75rem;
    font-weight: 600;
    margin-bottom: 0;
}

/* Alerts */
.alert {
    border: none;
    border-radius: 0.5rem;
}

/* Loading Spinner */
.spinner-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    display: none;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 3rem;
    color: #6c757d;
}

.empty-state i {
    font-size: 4rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

/* Expiration alerts */
.expiration-danger {
    color: #dc3545;
    font-weight: 600;
}

.expiration-warning {
    color: #ffc107;
    font-weight: 600;
}

/* Profile */
.profile-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 2rem;
    border-radius: 0.5rem 0.5rem 0 0;
    text-align: center;
}

.profile-avatar {
    width: 100px;
    height: 100px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    font-size: 2.5rem;
    color: #667eea;
}

/* Code viewer */
.code-block {
    background: #2d2d2d;
    color: #f8f8f2;
    padding: 1rem;
    border-radius: 0.5rem;
    font-family: 'Consolas', 'Monaco', monospace;
    font-size: 0.875rem;
    overflow-x: auto;
}

/* Mobile adjustments */
@media (max-width: 576px) {
    .page-header {
        flex-direction: column;
        align-items: flex-start !important;
        gap: 1rem;
    }

    .btn-actions .btn {
        padding: 0.5rem 0.75rem;
    }

    .stat-card .stat-number {
        font-size: 1.5rem;
    }
}
