/* Globalne style */
:root {
    --primary: #2c62ee;
    --primary-dark: #1d4ed8;
    --secondary: #64748b;
    --success: #10b981;
    --info: #3b82f6;
    --warning: #f59e0b;
    --danger: #ef4444;
    --light: #f8fafc;
    --dark: #1e293b;
    --body-bg: #f1f5f9;
    --card-bg: #ffffff;
    --border-color: #e2e8f0;
    --text-primary: #334155;
    --text-secondary: #64748b;
    --text-muted: #94a3b8;
}

body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    font-family: 'Roboto', sans-serif;
    color: var(--text-primary);
    background-color: var(--body-bg);
}

h1, h2, h3, h4, h5, h6, .navbar-brand {
    font-family: 'Poppins', sans-serif;
    font-weight: 600;
}

main {
    flex: 1;
}

/* Bootstrap overrides */
.btn-primary {
    background-color: var(--primary);
    border-color: var(--primary);
}

.btn-primary:hover, .btn-primary:focus {
    background-color: var(--primary-dark);
    border-color: var(--primary-dark);
}

.text-primary {
    color: var(--primary) !important;
}

.bg-primary {
    background-color: var(--primary) !important;
}

.bg-success {
    background-color: var(--success) !important;
}

.bg-info {
    background-color: var(--info) !important;
}

.bg-warning {
    background-color: var(--warning) !important;
}

.bg-danger {
    background-color: var(--danger) !important;
}

/* Niestandardowe kolory */
.bg-primary-light {
    background-color: rgba(44, 98, 238, 0.1);
}

.bg-success-light {
    background-color: rgba(16, 185, 129, 0.1);
}

.bg-info-light {
    background-color: rgba(59, 130, 246, 0.1);
}

.bg-warning-light {
    background-color: rgba(245, 158, 11, 0.1);
}

.bg-danger-light {
    background-color: rgba(239, 68, 68, 0.1);
}

/* Menu i nawigacja */
.navbar {
    background-color: var(--card-bg);
    border-bottom: 1px solid var(--border-color);
}

.navbar .nav-link {
    padding: 0.75rem 1rem;
    color: var(--text-primary);
    transition: all 0.2s ease;
}

.navbar .nav-link:hover {
    color: var(--primary);
}

.navbar-brand {
    font-weight: 700;
    color: var(--text-primary);
}

.dropdown-menu {
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
}

.dropdown-item {
    padding: 0.6rem 1.2rem;
}

.dropdown-item:hover {
    background-color: var(--bg-primary-light);
}

/* Karty */
.card {
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    border-radius: 0.75rem;
    border: 1px solid var(--border-color);
    overflow: hidden;
    background-color: var(--card-bg);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.card-header {
    background-color: rgba(0, 0, 0, 0.02);
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 1.25rem;
}

.card-body {
    padding: 1.5rem;
}

/* Tabele */
.table {
    border-color: var(--border-color);
}

.table th {
    background-color: rgba(0, 0, 0, 0.02);
    font-weight: 500;
    color: var(--text-primary);
    border-bottom-width: 1px;
}

.table td {
    color: var(--text-secondary);
    vertical-align: middle;
}

.table-hover tbody tr:hover {
    background-color: rgba(0, 0, 0, 0.02);
}

/* Formularze */
.form-label {
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.form-control {
    border-radius: 0.5rem;
    border: 1px solid var(--border-color);
    padding: 0.6rem 1rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 0.2rem rgba(44, 98, 238, 0.2);
}

/* Przyciski akcji */
.btn {
    border-radius: 0.5rem;
    padding: 0.6rem 1.2rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.btn-action {
    width: 2.5rem;
    height: 2.5rem;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.5rem;
}

.btn-sm {
    border-radius: 0.4rem;
    padding: 0.4rem 0.8rem;
}

/* Odznaki statusów */
.badge {
    padding: 0.5rem 0.75rem;
    font-weight: 500;
    border-radius: 0.4rem;
}

.badge-status-active {
    background-color: var(--success);
}

.badge-status-inactive {
    background-color: var(--danger);
}

.badge-status-pending {
    background-color: var(--warning);
}

/* Alerty */
.alert {
    border-radius: 0.75rem;
    padding: 1rem 1.25rem;
    border: none;
}

.alert-primary {
    background-color: rgba(44, 98, 238, 0.1);
    color: var(--primary-dark);
}

.alert-success {
    background-color: rgba(16, 185, 129, 0.1);
    color: #065f46;
}

.alert-info {
    background-color: rgba(59, 130, 246, 0.1);
    color: #1e40af;
}

.alert-warning {
    background-color: rgba(245, 158, 11, 0.1);
    color: #92400e;
}

.alert-danger {
    background-color: rgba(239, 68, 68, 0.1);
    color: #b91c1c;
}

/* Animacje */
.fade-in {
    animation: fadeIn 0.5s;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Listy */
.list-group-item {
    border-color: var(--border-color);
    padding: 0.75rem 1.25rem;
}

.list-group-item-action:hover {
    background-color: rgba(0, 0, 0, 0.02);
}

/* Paginacja */
.pagination {
    margin-bottom: 0;
}

.page-link {
    border-color: var(--border-color);
    color: var(--text-primary);
    padding: 0.5rem 0.75rem;
}

.page-item.active .page-link {
    background-color: var(--primary);
    border-color: var(--primary);
}

/* Awatary i ikony */
.avatar-circle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
}

.icon-shape {
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Responsywność */
@media (max-width: 768px) {
    .card-responsive {
        margin-bottom: 1.5rem;
    }
    
    .table-responsive {
        font-size: 0.9rem;
    }

    .card-body {
        padding: 1.25rem;
    }
    
    h1 {
        font-size: 1.75rem;
    }
    
    .btn {
        padding: 0.5rem 1rem;
    }
    
    .container-fluid {
        padding-left: 1rem;
        padding-right: 1rem;
    }
    
    .navbar .navbar-brand {
        font-size: 1.1rem;
    }
    
    .dropdown-menu {
        font-size: 0.9rem;
    }
    
    /* Responsywne przyciski akcji w nagłówkach */
    .d-flex.flex-wrap.gap-2 {
        gap: 0.5rem !important;
    }
    
    .d-flex.flex-wrap.gap-2 .btn {
        font-size: 0.875rem;
        padding: 0.4rem 0.8rem;
    }
    
    /* Responsywne filtry przycisków */
    .btn-group.d-flex .btn-sm {
        font-size: 0.75rem;
        padding: 0.25rem 0.5rem;
    }
    
    .d-flex.flex-wrap.gap-1 .btn-sm {
        font-size: 0.75rem;
        padding: 0.25rem 0.5rem;
        margin-bottom: 0.25rem;
    }
}

@media (max-width: 576px) {
    .card-body {
        padding: 1rem;
    }
    
    .container-fluid {
        padding-left: 0.75rem;
        padding-right: 0.75rem;
    }
    
    h1 {
        font-size: 1.5rem;
    }
    
    .table th, .table td {
        padding: 0.5rem 0.25rem;
        font-size: 0.85rem;
    }
    
    .btn {
        padding: 0.4rem 0.8rem;
        font-size: 0.875rem;
    }
    
    .badge {
        padding: 0.3rem 0.5rem;
        font-size: 0.75rem;
    }
    
    .navbar {
        padding: 0.5rem 1rem;
    }
    
    .alert {
        padding: 0.75rem 1rem;
    }
    
    .card-header {
        padding: 0.75rem 1rem;
    }
    
    /* Na małych ekranach przyciski akcji układają się w kolumnie */
    .d-flex.flex-wrap.gap-2 {
        flex-direction: column;
        gap: 0.25rem !important;
    }
    
    .d-flex.flex-wrap.gap-2 .btn {
        width: 100%;
        justify-content: center;
    }
    
    /* Filtry na małych ekranach */
    .btn-group.d-flex .btn-sm {
        font-size: 0.7rem;
        padding: 0.2rem 0.4rem;
    }
    
    .d-flex.flex-wrap.gap-1 .btn-sm {
        font-size: 0.7rem;
        padding: 0.2rem 0.4rem;
    }
} 

/* Dodatkowe style dla lepszego wyglądu */
.shadow-sm {
    box-shadow: 0 .125rem .25rem rgba(0, 0, 0, .075) !important;
}

.border-0 {
    border: 0 !important;
}

.rounded-pill {
    border-radius: 50rem !important;
}

/* Filtry przycisków */
.btn-group .btn-sm {
    border-radius: 0.25rem;
    transition: all 0.2s ease;
}

.btn-group .btn-sm:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.d-flex.flex-wrap.gap-1 .btn-sm {
    border-radius: 0.25rem;
    transition: all 0.2s ease;
    margin: 0.125rem;
}

.d-flex.flex-wrap.gap-1 .btn-sm:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Poprawki dla input-group */
.input-group > .form-control:not(:last-child) {
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
}

.input-group > .form-control:not(:first-child) {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
}

/* Style dla 404 i błędów */
.min-vh-100 {
    min-height: 100vh !important;
}

/* Style dla kart powitalnych */
.bg-gradient {
    position: relative;
    overflow: hidden;
}

.bg-gradient::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(44, 98, 238, 0.03) 0%, rgba(16, 185, 129, 0.03) 100%);
    z-index: 1;
}

.bg-gradient .card-body {
    position: relative;
    z-index: 2;
}

.bg-gradient:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

/* Animacja dla ikon w kartach powitalnych */
.bg-gradient .bi-person-circle {
    transition: all 0.3s ease;
}

.bg-gradient:hover .bi-person-circle {
    transform: scale(1.1);
    color: var(--primary) !important;
}

/* Dashboard Design System - Common Styles */

/* Global Background */
body {
    background: #f7f8fc !important;
}

/* Dashboard Cards - Rectangular with Colored Headers */
.dashboard-card {
    background: white;
    border: 1px solid #e3e6f0;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0,0,0,0.12);
    transition: all 0.2s ease;
}

.dashboard-card:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.dashboard-card-header {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid rgba(255,255,255,0.2);
}

.dashboard-card-body {
    padding: 1.25rem;
    background: white;
}

/* Blue Color Palette */
.bg-primary {
    background: linear-gradient(135deg, #4e73df 0%, #224abe 100%) !important;
}

.bg-info {
    background: linear-gradient(135deg, #36b9cc 0%, #2c9faf 100%) !important;
}

.bg-success {
    background: linear-gradient(135deg, #1cc88a 0%, #17a673 100%) !important;
}

.bg-warning {
    background: linear-gradient(135deg, #f6c23e 0%, #dda20a 100%) !important;
}

.bg-secondary {
    background: linear-gradient(135deg, #858796 0%, #60616f 100%) !important;
}

/* Card Header - Blue like in reference image */
.bg-card-header {
    background: linear-gradient(135deg, #5a9fd4 0%, #4a8bc2 100%) !important;
}

/* Chart Blue Color from Reference */
.text-chart-blue {
    color: #5a9fd4 !important;
}

/* Status Badges */
.status-badge {
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-warning {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeaa7;
}

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

.status-info {
    background: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

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

/* User Avatar */
.user-avatar {
    width: 28px;
    height: 28px;
    background: #f8f9fc;
    border: 1px solid #e3e6f0;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6c757d;
    font-size: 0.75rem;
}

/* Table Styling */
.dashboard-table {
    font-size: 0.85rem;
}

.dashboard-table thead tr {
    background: #f8f9fc;
}

.dashboard-table th {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #5a5c69 !important;
    border-bottom: 1px solid #e3e6f0;
    padding: 0.75rem;
}

.table-row {
    transition: background-color 0.15s ease;
    border-bottom: 1px solid #f3f3f3;
}

.table-row:hover {
    background-color: #f8f9fc !important;
}

/* Buttons */
.btn {
    border-radius: 4px;
    font-weight: 500;
    font-size: 0.8rem;
    padding: 0.5rem 1rem;
    transition: all 0.15s ease;
}

.btn-primary {
    background: linear-gradient(135deg, #4e73df 0%, #224abe 100%);
    border: none;
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #224abe 0%, #1e3a8a 100%);
    transform: translateY(-1px);
}

.btn-warning {
    background: linear-gradient(135deg, #f6c23e 0%, #dda20a 100%);
    border: none;
    color: white;
}

.btn-warning:hover {
    background: linear-gradient(135deg, #dda20a 0%, #b8860b 100%);
    transform: translateY(-1px);
}

.btn-success {
    background: linear-gradient(135deg, #1cc88a 0%, #17a673 100%);
    border: none;
    color: white;
}

.btn-outline-primary {
    color: #4e73df;
    border-color: #4e73df;
    background: transparent;
}

.btn-outline-primary:hover {
    background: #4e73df;
    border-color: #4e73df;
    color: white;
}

.btn-outline-secondary {
    color: #858796;
    border-color: #d1d3e2;
    background: transparent;
}

.btn-outline-secondary:hover {
    background: #858796;
    border-color: #858796;
    color: white;
}

.btn-outline-light {
    color: white;
    border-color: rgba(255,255,255,0.8);
    background: transparent;
}

.btn-outline-light:hover {
    background: rgba(255,255,255,0.2);
    border-color: white;
    color: white;
}

/* Form Controls */
.form-control {
    border-radius: 4px;
    border: 1px solid #d1d3e2;
    transition: all 0.15s ease;
    font-size: 0.85rem;
}

.form-control:focus {
    box-shadow: 0 0 0 2px rgba(78, 115, 223, 0.25);
    border-color: #4e73df;
}

.form-select {
    border-radius: 4px;
    border: 1px solid #d1d3e2;
    font-size: 0.85rem;
}

.form-select:focus {
    box-shadow: 0 0 0 2px rgba(78, 115, 223, 0.25);
    border-color: #4e73df;
}

/* Text Colors */
.text-dark {
    color: #2c3e50 !important;
}

.text-muted {
    color: #6c757d !important;
}

.text-primary {
    color: #4e73df !important;
}

.text-info {
    color: #36b9cc !important;
}

.text-success {
    color: #1cc88a !important;
}

.text-warning {
    color: #f6c23e !important;
}

/* Alert styling for consistency */
.alert {
    border-radius: 4px;
    border: 1px solid transparent;
}

/* Page Headers */
.page-header {
    background: white;
    border: 1px solid #e3e6f0;
    border-radius: 6px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.12);
}

.page-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 0.5rem;
}

.page-subtitle {
    color: #6c757d;
    font-size: 0.9rem;
}

/* Search and Filter Bars */
.search-bar {
    background: white;
    border: 1px solid #e3e6f0;
    border-radius: 6px;
    padding: 1rem;
    margin-bottom: 1rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

/* Responsive */
@media (max-width: 768px) {
    .dashboard-card-body {
        padding: 1rem;
    }
    
    .dashboard-card-header {
        padding: 0.75rem 1rem;
    }
    
    .btn {
        font-size: 0.75rem;
        padding: 0.375rem 0.75rem;
    }
    
    .dashboard-table th,
    .dashboard-table td {
        padding: 0.5rem;
        font-size: 0.8rem;
    }
}

@media (max-width: 576px) {
    .page-header {
        padding: 1rem;
    }
    
    .page-title {
        font-size: 1.375rem;
    }
}

/* Timeline Styles */
.timeline {
    position: relative;
    padding: 0;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 8px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: #dee2e6;
}

.timeline-item {
    position: relative;
    padding-left: 2rem;
    padding-bottom: 1rem;
    margin-bottom: 0.5rem;
}

.timeline-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
}

.timeline-marker {
    position: absolute;
    left: 0;
    top: 4px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 2px solid white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.timeline-content {
    padding: 0.5rem 0;
}

.timeline-content .small {
    font-size: 0.8rem;
    line-height: 1.2;
}

.timeline-content .fw-medium {
    font-size: 0.9rem;
    line-height: 1.3;
} 