/* Global Styles */
:root {
    --primary: #667eea;
    --secondary: #764ba2;
    --success: #28a745;
    --info: #17a2b8;
    --warning: #ffc107;
    --danger: #dc3545;
    --light: #f8f9fa;
    --dark: #343a40;
    --gray: #6c757d;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f5f7fb;
    overflow-x: hidden;
}

/* Sidebar Styles */
.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    width: 250px;
    background: linear-gradient(180deg, var(--primary), var(--secondary));
    color: white;
    padding: 20px 0;
    box-shadow: 3px 0 10px rgba(0,0,0,0.1);
    z-index: 1000;
    transition: all 0.3s ease;
}

.sidebar.collapsed {
    width: 70px;
}

.sidebar .logo {
    text-align: center;
    padding: 0 20px 20px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    margin-bottom: 20px;
}

.sidebar .logo h4 {
    margin: 0;
    font-weight: 600;
    font-size: 1.2rem;
}

.sidebar .logo i {
    margin-right: 10px;
}

.sidebar .nav-link {
    color: rgba(255,255,255,0.8);
    padding: 12px 20px;
    margin: 5px 10px;
    border-radius: 8px;
    transition: all 0.3s;
    display: flex;
    align-items: center;
}

.sidebar .nav-link i {
    margin-right: 12px;
    width: 20px;
    text-align: center;
}

.sidebar .nav-link:hover, .sidebar .nav-link.active {
    background: rgba(255,255,255,0.1);
    color: white;
    transform: translateX(5px);
}

.sidebar .nav-link span {
    transition: opacity 0.3s;
}

.sidebar.collapsed .nav-link span {
    opacity: 0;
    width: 0;
    overflow: hidden;
}

/* Main Content Styles */
.main-content {
    margin-left: 270px;
    padding: 20px;
    transition: margin-left 0.3s ease;
}

.main-content.expanded {
    margin-left: 90px;
}

.header {
    background: white;
    padding: 15px 20px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header h3 {
    margin: 0;
    color: #333;
}

.header h3 i {
    margin-right: 10px;
    color: var(--primary);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.user-info span {
    display: flex;
    align-items: center;
    gap: 5px;
    color: #666;
}

/* Card Styles */
.card {
    border: none;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-bottom: 20px;
    transition: transform 0.3s, box-shadow 0.3s;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
}

.card-header {
    border-radius: 10px 10px 0 0 !important;
    padding: 15px 20px;
    font-weight: 600;
}

.card-header i {
    margin-right: 8px;
}

.card-body {
    padding: 20px;
}

/* Button Styles */
.btn {
    border-radius: 8px;
    padding: 8px 16px;
    font-weight: 500;
    transition: all 0.3s;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border: none;
}

.btn-primary:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

.btn-success {
    background: linear-gradient(135deg, var(--success), #20c997);
    border: none;
}

.btn-success:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

.btn-info {
    background: linear-gradient(135deg, var(--info), var(--primary));
    border: none;
}

.btn-info:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

/* Stat Card Styles */
.stat-card {
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    padding: 20px;
    margin-bottom: 20px;
    transition: transform 0.3s;
    position: relative;
    overflow: hidden;
}

.stat-card:hover {
    transform: translateY(-5px);
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 5px;
    height: 100%;
    background: linear-gradient(to bottom, var(--primary), var(--secondary));
}

.stat-card h5 {
    margin: 0 0 10px 0;
    color: #666;
    font-size: 0.9rem;
}

.stat-card h2 {
    margin: 0;
    font-weight: 700;
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    position: absolute;
    top: 20px;
    right: 20px;
}

/* Form Styles */
.form-control {
    border-radius: 8px;
    padding: 10px 15px;
    border: 1px solid #e1e5eb;
    transition: all 0.3s;
}

.form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.25);
}

.form-label {
    font-weight: 500;
    color: #495057;
    margin-bottom: 8px;
}

.input-group-text {
    border-radius: 8px 0 0 8px;
}

/* Table Styles */
.table {
    margin-bottom: 0;
}

.table th {
    background-color: var(--primary);
    color: white;
    border: none;
    font-weight: 600;
}

.table-hover tbody tr:hover {
    background-color: rgba(102, 126, 234, 0.05);
}

/* Alert Styles */
.alert {
    border-radius: 8px;
    border: none;
}

.alert-success {
    background-color: #d4edda;
    color: #155724;
}

.alert-danger {
    background-color: #f8d7da;
    color: #721c24;
}

.alert-info {
    background-color: #d1ecf1;
    color: #0c5460;
}

/* Modal Styles */
.modal-content {
    border-radius: 10px;
    border: none;
}

.modal-header {
    border-radius: 10px 10px 0 0;
    padding: 15px 20px;
}

/* Responsive Styles */
@media (max-width: 992px) {
    .sidebar {
        width: 70px;
    }
    
    .sidebar .logo h4, .sidebar .nav-link span {
        display: none;
    }
    
    .sidebar .logo, .sidebar .nav-link {
        justify-content: center;
        text-align: center;
    }
    
    .main-content {
        margin-left: 90px;
    }
    
    .user-info span:not(:first-child) {
        display: none;
    }
}

@media (max-width: 768px) {
    .sidebar {
        width: 0;
        overflow: hidden;
        transform: translateX(-100%);
    }
    
    .sidebar.active {
        width: 250px;
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 20px;
    }
    
    .main-content.expanded {
        margin-left: 20px;
    }
    
    .header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .user-info {
        align-self: flex-end;
    }
    
    .row > [class*="col-"] {
        margin-bottom: 15px;
    }
    
    /* Mobile bottom navigation */
    .bottom-nav {
        display: block;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        background: white;
        box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
        z-index: 1000;
        padding: 10px 0;
        border-top: 1px solid #eee;
    }
    
    .bottom-nav .nav-item {
        flex: 1;
        text-align: center;
    }
    
    .bottom-nav .nav-link {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 8px;
        color: #6c757d;
        font-size: 0.75rem;
    }
    
    .bottom-nav .nav-link i {
        font-size: 1.2rem;
        margin-bottom: 4px;
    }
    
    .bottom-nav .nav-link.active {
        color: var(--primary);
    }
    
    .main-content {
        padding-bottom: 80px; /* Increased space for bottom nav */
    }
}

/* Toggle Button for Mobile */
.sidebar-toggle {
    display: none;
    position: fixed;
    top: 20px;
    left: 20px;
    z-index: 1001;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 5px;
    padding: 8px 12px;
}

@media (max-width: 768px) {
    .sidebar-toggle {
        display: block;
    }
}

/* Animation Classes */
.fade-in {
    animation: fadeIn 0.5s ease-in;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Quantity Input Styles for Ticket Form */
.quantity-input {
    width: 100%;
    text-align: center;
    font-size: 1.5rem;
    border: 2px solid #dee2e6;
    border-radius: 8px;
    padding: 10px;
    font-weight: bold;
}

.quantity-btn {
    width: 50px;
    height: 50px;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
}

/* Print Styles */
@media print {
    .sidebar, .header, .btn, .modal-footer, .bottom-nav {
        display: none !important;
    }
    
    .main-content {
        margin-left: 0 !important;
        padding: 0 !important;
    }
    
    body {
        background: white;
    }
}

/* Background Color Classes */
.bg-primary-light { background: linear-gradient(135deg, #007bff, #667eea); color: white; }
.bg-success-light { background: linear-gradient(135deg, #28a745, #20c997); color: white; }
.bg-info-light { background: linear-gradient(135deg, #17a2b8, #667eea); color: white; }
.bg-warning-light { background: linear-gradient(135deg, #ffc107, #fd7e14); color: white; }
.bg-warning-light.text-dark { color: #333 !important; }