:root {
    --primary-color: #3498db;
    --secondary-color: #2c3e50;
    --accent-color: #e74c3c;
    --light-color: #ecf0f1;
    --dark-color: #2c3e50;
    --success-color: #2ecc71;
    --warning-color: #f39c12;
    --danger-color: #e74c3c;
    --sidebar-width: 280px;
    --topbar-height: 60px;
}

/* Layout Base */
body {
    font-family: 'Poppins', sans-serif;
    background-color: #f8f9fa;
    color: #333;
    line-height: 1.6;
}

.content-container {
    padding: 20px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.05);
    margin-bottom: 20px;
}

.page-title {
    color: var(--dark-color);
    font-weight: 600;
    font-size: 1.8rem;
    display: flex;
    align-items: center;
}

/* Sidebar */
.sidebar {
    background-color: var(--secondary-color);
    color: white;
    height: 100vh;
    position: sticky;
    top: 0;
    transition: all 0.3s;
    z-index: 1000;
    overflow-y: auto;
}

.sidebar .nav-link {
    color: rgba(0, 0, 0, 0.8);
    border-radius: 4px;
    margin-bottom: 5px;
    transition: all 0.3s;
    padding: 10px 15px;
    font-weight: 500;
}

.sidebar .nav-link:hover {
    color: rgb(121, 64, 64);
    background-color: rgba(255, 255, 255, 0.1);
}

.sidebar .nav-link.active {
    color: white;
    background-color: var(--primary-color);
    font-weight: 600;
}

.sidebar .nav-link i {
    width: 20px;
    text-align: center;
    margin-right: 10px;
}

.sidebar-footer {
    padding: 15px;
    text-align: center;
}

/* Navbar */
.navbar {
    box-shadow: 0 2px 10px rgba(241, 8, 8, 0.1);
    z-index: 1030;
    padding: 10px 0;
}

.navbar-brand img {
    transition: transform 0.3s;
}

.navbar-brand:hover img {
    transform: scale(1.05);
}

/* Cards */
.card {
    border: none;
    border-radius: 8px;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s, box-shadow 0.3s;
    margin-bottom: 20px;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.card:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.card-header {
    background-color: white;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    font-weight: 600;
    padding: 15px 20px;
}

.card-body {
    padding: 20px;
}

/* Tabelas */
.table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}

.table th {
    background-color: #f8f9fa;
    color: var(--dark-color);
    font-weight: 600;
    border-top: 1px solid #dee2e6;
    padding: 12px 15px;
}

.table td {
    padding: 12px 15px;
    vertical-align: middle;
    border-top: 1px solid #eee;
}

.table-hover tbody tr:hover {
    background-color: rgba(52, 152, 219, 0.05);
}

/* Formulários */
.form-control, .form-select {
    border-radius: 6px;
    padding: 10px 15px;
    border: 1px solid #ddd;
    transition: all 0.3s;
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.25rem rgba(52, 152, 219, 0.15);
}

.form-label {
    font-weight: 500;
    margin-bottom: 8px;
}

/* Botões */
.btn {
    border-radius: 6px;
    padding: 8px 16px;
    font-weight: 500;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn i {
    margin-right: 8px;
}

.btn-sm i {
    margin-right: 5px;
}

.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-primary:hover {
    background-color: #2980b9;
    border-color: #2980b9;
}

.btn-outline-primary {
    color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-outline-primary:hover {
    background-color: var(--primary-color);
    color: white;
}

/* Alertas */
.alert {
    border-radius: 6px;
    padding: 12px 16px;
    border: none;
}

.alert-dismissible .btn-close {
    padding: 0.75rem;
}

.alerts-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1100;
    width: 350px;
}

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.8);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

/* Breadcrumb */
.breadcrumb {
    background-color: transparent;
    padding: 0;
    margin-bottom: 20px;
}

.breadcrumb-item a {
    color: var(--primary-color);
    text-decoration: none;
}

/* Badges */
.badge {
    padding: 6px 10px;
    font-weight: 500;
    border-radius: 20px;
}

/* List Groups */
.list-group-item {
    padding: 12px 20px;
    border-color: rgba(0, 0, 0, 0.05);
}

.list-group-item:hover {
    background-color: rgba(0, 0, 0, 0.02);
}

/* Responsividade */
@media (max-width: 992px) {
    .sidebar {
        position: fixed;
        left: -100%;
        width: var(--sidebar-width);
        transition: left 0.3s;
    }
    
    .sidebar.active {
        left: 0;
    }
    
    main {
        margin-left: 0;
    }
    
    .page-title {
        font-size: 1.5rem;
    }
}

@media (max-width: 768px) {
    .content-container {
        padding: 15px;
    }
    
    .card-body {
        padding: 15px;
    }
    
    .table td, .table th {
        padding: 8px 10px;
    }
}

@media (max-width: 576px) {
    .page-title {
        font-size: 1.3rem;
    }
    
    .breadcrumb {
        font-size: 0.85rem;
    }
    
    .btn i {
        margin-right: 0;
    }
    
    .btn span {
        display: none;
    }
}

/* Animações */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.content-wrapper {
    animation: fadeIn 0.3s ease-out;
}

/* Página de Login */
.min-vh-100 {
    min-height: 100vh;
    display: flex;
    align-items: center;
}

/* Impressão */
@media print {
    body * {
        visibility: hidden;
    }
    
    .content-container, .content-container * {
        visibility: visible;
    }
    
    .content-container {
        position: absolute;
        left: 0;
        top: 0;
        width: 100%;
        box-shadow: none;
        border: none;
    }
    
    .no-print {
        display: none !important;
    }
    
    .card {
        border: none;
        box-shadow: none;
    }
    
    .table {
        page-break-inside: avoid;
    }
    
    h2, h3, h4, h5 {
        page-break-after: avoid;
    }
}