/* ==========================================
   BORDIR POS - Professional Stylesheet
   Modern & Advanced Design
   ========================================== */

   @import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

   * {
       margin: 0;
       padding: 0;
       box-sizing: border-box;
   }
   
   :root {
       --primary: #6366f1;
       --primary-dark: #4f46e5;
       --primary-light: #818cf8;
       --secondary: #10b981;
       --danger: #ef4444;
       --warning: #f59e0b;
       --info: #3b82f6;
       --dark: #0f172a;
       --dark-800: #1e293b;
       --dark-700: #334155;
       --light: #f8fafc;
       --border: #e2e8f0;
       --text: #1e293b;
       --text-light: #64748b;
       --success: #10b981;
       --purple: #a855f7;
       --pink: #ec4899;
       
       --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
       --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
       --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
       --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
       --shadow-xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
   }
   
   body {
       font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
       background: var(--light);
       color: var(--text);
       line-height: 1.6;
       -webkit-font-smoothing: antialiased;
   }
   
   /* ==========================================
      LOGIN PAGE - PREMIUM DESIGN
      ========================================== */
   .login-container {
       min-height: 100vh;
       display: flex;
       align-items: center;
       justify-content: center;
       background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
       padding: 20px;
       position: relative;
       overflow: hidden;
   }
   
   .login-container::before {
       content: '';
       position: absolute;
       top: -50%;
       right: -50%;
       width: 100%;
       height: 100%;
       background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
       animation: float 20s ease-in-out infinite;
   }
   
   @keyframes float {
       0%, 100% { transform: translate(0, 0) rotate(0deg); }
       33% { transform: translate(30px, -30px) rotate(120deg); }
       66% { transform: translate(-30px, 30px) rotate(240deg); }
   }
   
   .login-box {
       background: rgba(255, 255, 255, 0.95);
       backdrop-filter: blur(20px);
       border-radius: 24px;
       box-shadow: var(--shadow-xl);
       width: 100%;
       max-width: 480px;
       padding: 48px;
       animation: slideUp 0.6s cubic-bezier(0.4, 0, 0.2, 1);
       position: relative;
       z-index: 1;
   }
   
   @keyframes slideUp {
       from {
           opacity: 0;
           transform: translateY(40px) scale(0.95);
       }
       to {
           opacity: 1;
           transform: translateY(0) scale(1);
       }
   }
   
   .login-header {
       text-align: center;
       margin-bottom: 32px;
   }
   
   .login-header i {
       width: 72px;
       height: 72px;
       display: flex;
       align-items: center;
       justify-content: center;
       margin: 0 auto 16px;
       background: linear-gradient(135deg, var(--primary), var(--primary-dark));
       color: white;
       border-radius: 20px;
       box-shadow: var(--shadow-lg);
   }
   
   .login-header h1 {
       color: var(--dark);
       font-size: 32px;
       font-weight: 800;
       margin-bottom: 8px;
       letter-spacing: -0.5px;
   }
   
   .login-header p {
       color: var(--text-light);
       font-size: 14px;
       font-weight: 500;
   }
   
   /* ==========================================
      FORMS - MODERN DESIGN
      ========================================== */
   .form-group {
       margin-bottom: 20px;
   }
   
   .form-group label {
       display: block;
       margin-bottom: 8px;
       color: var(--text);
       font-weight: 600;
       font-size: 14px;
   }
   
   .form-control {
       width: 100%;
       padding: 14px 16px;
       border: 2px solid var(--border);
       border-radius: 12px;
       font-size: 14px;
       font-weight: 500;
       transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
       background: white;
   }
   
   .form-control:focus {
       outline: none;
       border-color: var(--primary);
       box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
       transform: translateY(-1px);
   }
   
   .form-control::placeholder {
       color: var(--text-light);
   }
   
   textarea.form-control {
       resize: vertical;
       min-height: 80px;
   }
   
   /* ==========================================
      BUTTONS - PREMIUM
      ========================================== */
   .btn {
       padding: 14px 24px;
       border: none;
       border-radius: 12px;
       font-size: 14px;
       font-weight: 700;
       cursor: pointer;
       transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
       text-decoration: none;
       display: inline-flex;
       align-items: center;
       justify-content: center;
       gap: 8px;
       position: relative;
       overflow: hidden;
   }
   
   .btn::before {
       content: '';
       position: absolute;
       top: 50%;
       left: 50%;
       width: 0;
       height: 0;
       border-radius: 50%;
       background: rgba(255, 255, 255, 0.2);
       transform: translate(-50%, -50%);
       transition: width 0.6s, height 0.6s;
   }
   
   .btn:hover::before {
       width: 300px;
       height: 300px;
   }
   
   .btn i {
       position: relative;
       z-index: 1;
   }
   
   .btn span {
       position: relative;
       z-index: 1;
   }
   
   .btn-primary {
       background: linear-gradient(135deg, var(--primary), var(--primary-dark));
       color: white;
       box-shadow: var(--shadow-lg);
   }
   
   .btn-primary:hover {
       transform: translateY(-2px);
       box-shadow: 0 20px 30px -10px rgba(99, 102, 241, 0.4);
   }
   
   .btn-success {
       background: linear-gradient(135deg, var(--success), #059669);
       color: white;
       box-shadow: var(--shadow-lg);
   }
   
   .btn-success:hover {
       transform: translateY(-2px);
       box-shadow: 0 20px 30px -10px rgba(16, 185, 129, 0.4);
   }
   
   .btn-danger {
       background: linear-gradient(135deg, var(--danger), #dc2626);
       color: white;
       box-shadow: var(--shadow-lg);
   }
   
   .btn-danger:hover {
       transform: translateY(-2px);
       box-shadow: 0 20px 30px -10px rgba(239, 68, 68, 0.4);
   }
   
   .btn-warning {
       background: linear-gradient(135deg, var(--warning), #d97706);
       color: white;
       box-shadow: var(--shadow-lg);
   }
   
   .btn-warning:hover {
       transform: translateY(-2px);
       box-shadow: 0 20px 30px -10px rgba(245, 158, 11, 0.4);
   }
   
   .btn-info {
       background: linear-gradient(135deg, var(--info), #2563eb);
       color: white;
       box-shadow: var(--shadow-lg);
   }
   
   .btn-info:hover {
       transform: translateY(-2px);
       box-shadow: 0 20px 30px -10px rgba(59, 130, 246, 0.4);
   }
   
   .btn-sm {
       padding: 8px 16px;
       font-size: 13px;
   }
   
   /* ==========================================
      DASHBOARD LAYOUT - MODERN
      ========================================== */
   .dashboard-wrapper {
       display: flex;
       min-height: 100vh;
       background: #f1f5f9;
   }
   
   .sidebar {
       width: 280px;
       background: var(--dark);
       color: white;
       position: fixed;
       height: 100vh;
       overflow-y: auto;
       z-index: 1000;
       box-shadow: var(--shadow-xl);
   }
   
   .sidebar::-webkit-scrollbar {
       width: 6px;
   }
   
   .sidebar::-webkit-scrollbar-thumb {
       background: rgba(255, 255, 255, 0.2);
       border-radius: 3px;
   }
   
   .sidebar-header {
       padding: 32px 24px;
       border-bottom: 1px solid rgba(255,255,255,0.1);
       background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(168, 85, 247, 0.1));
   }
   
   .sidebar-header h2 {
       font-size: 22px;
       font-weight: 800;
       margin-bottom: 4px;
       letter-spacing: -0.5px;
       background: linear-gradient(135deg, #fff, #e0e7ff);
       -webkit-background-clip: text;
       -webkit-text-fill-color: transparent;
   }
   
   .sidebar-header p {
       font-size: 12px;
       color: rgba(255,255,255,0.6);
       font-weight: 500;
   }
   
   .sidebar-menu {
       padding: 24px 0;
   }
   
   .menu-item {
       display: flex;
       align-items: center;
       padding: 16px 24px;
       color: rgba(255,255,255,0.7);
       text-decoration: none;
       transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
       border-left: 3px solid transparent;
       font-weight: 600;
       font-size: 14px;
   }
   
   .menu-item:hover {
       background: rgba(99, 102, 241, 0.1);
       color: white;
       padding-left: 28px;
   }
   
   .menu-item.active {
       background: linear-gradient(90deg, rgba(99, 102, 241, 0.2), transparent);
       color: white;
       border-left-color: var(--primary);
   }
   
   .menu-item i {
       margin-right: 14px;
       font-size: 18px;
       width: 24px;
       text-align: center;
   }
   
   .main-content {
       flex: 1;
       margin-left: 280px;
       background: #f1f5f9;
       min-height: 100vh;
   }
   
   .topbar {
       background: white;
       padding: 20px 32px;
       box-shadow: var(--shadow);
       display: flex;
       justify-content: space-between;
       align-items: center;
       position: sticky;
       top: 0;
       z-index: 100;
       backdrop-filter: blur(10px);
   }
   
   .topbar-left h1 {
       font-size: 28px;
       font-weight: 800;
       color: var(--dark);
       letter-spacing: -0.5px;
   }
   
   .topbar-right {
       display: flex;
       align-items: center;
       gap: 24px;
   }
   
   .user-info {
       display: flex;
       align-items: center;
       gap: 14px;
       padding: 8px 16px;
       background: var(--light);
       border-radius: 12px;
       transition: all 0.3s;
   }
   
   .user-info:hover {
       background: var(--border);
   }
   
   .user-avatar {
       width: 44px;
       height: 44px;
       border-radius: 12px;
       background: linear-gradient(135deg, var(--primary), var(--purple));
       color: white;
       display: flex;
       align-items: center;
       justify-content: center;
       font-weight: 700;
       font-size: 16px;
       box-shadow: var(--shadow-md);
   }
   
   .content-area {
       padding: 32px;
   }
   
   /* ==========================================
      CARDS & STATS - PREMIUM
      ========================================== */
   .stats-grid {
       display: grid;
       grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
       gap: 24px;
       margin-bottom: 32px;
   }
   
   .stat-card {
       background: white;
       border-radius: 16px;
       padding: 28px;
       box-shadow: var(--shadow);
       border: 1px solid var(--border);
       transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
       position: relative;
       overflow: hidden;
   }
   
   .stat-card::before {
       content: '';
       position: absolute;
       top: 0;
       left: 0;
       width: 100%;
       height: 4px;
       background: linear-gradient(90deg, var(--primary), var(--primary-light));
   }
   
   .stat-card.success::before {
       background: linear-gradient(90deg, var(--success), #34d399);
   }
   
   .stat-card.warning::before {
       background: linear-gradient(90deg, var(--warning), #fbbf24);
   }
   
   .stat-card.danger::before {
       background: linear-gradient(90deg, var(--danger), #f87171);
   }
   
   .stat-card:hover {
       transform: translateY(-4px);
       box-shadow: var(--shadow-lg);
   }
   
   .stat-header {
       display: flex;
       justify-content: space-between;
       align-items: flex-start;
       margin-bottom: 16px;
   }
   
   .stat-icon {
       width: 56px;
       height: 56px;
       border-radius: 14px;
       display: flex;
       align-items: center;
       justify-content: center;
       font-size: 26px;
       box-shadow: var(--shadow-md);
   }
   
   .stat-icon.primary {
       background: linear-gradient(135deg, var(--primary), var(--primary-dark));
       color: white;
   }
   
   .stat-icon.success {
       background: linear-gradient(135deg, var(--success), #059669);
       color: white;
   }
   
   .stat-icon.warning {
       background: linear-gradient(135deg, var(--warning), #d97706);
       color: white;
   }
   
   .stat-icon.danger {
       background: linear-gradient(135deg, var(--danger), #dc2626);
       color: white;
   }
   
   .stat-value {
       font-size: 32px;
       font-weight: 800;
       color: var(--dark);
       margin-bottom: 4px;
       letter-spacing: -1px;
   }
   
   .stat-label {
       color: var(--text-light);
       font-size: 14px;
       font-weight: 600;
   }
   
   /* ==========================================
      TABLE - MODERN
      ========================================== */
   .card {
       background: white;
       border-radius: 16px;
       box-shadow: var(--shadow);
       margin-bottom: 24px;
       border: 1px solid var(--border);
       overflow: hidden;
   }
   
   .card-header {
       padding: 24px 28px;
       border-bottom: 1px solid var(--border);
       display: flex;
       justify-content: space-between;
       align-items: center;
       background: linear-gradient(135deg, rgba(99, 102, 241, 0.02), rgba(168, 85, 247, 0.02));
   }
   
   .card-header h3 {
       font-size: 18px;
       font-weight: 700;
       color: var(--dark);
       display: flex;
       align-items: center;
       gap: 10px;
   }
   
   .card-body {
       padding: 28px;
   }
   
   .table-responsive {
       overflow-x: auto;
   }
   
   table {
       width: 100%;
       border-collapse: separate;
       border-spacing: 0;
   }
   
   table thead {
       background: var(--light);
   }
   
   table thead th {
       padding: 16px;
       text-align: left;
       font-size: 12px;
       font-weight: 700;
       color: var(--text);
       text-transform: uppercase;
       letter-spacing: 0.8px;
       border-bottom: 2px solid var(--border);
   }
   
   table tbody tr {
       transition: all 0.2s;
       border-bottom: 1px solid var(--border);
   }
   
   table tbody tr:hover {
       background: rgba(99, 102, 241, 0.02);
   }
   
   table tbody td {
       padding: 16px;
       font-size: 14px;
       font-weight: 500;
   }
   
   .badge {
       padding: 6px 14px;
       border-radius: 8px;
       font-size: 12px;
       font-weight: 700;
       display: inline-block;
       letter-spacing: 0.3px;
   }
   
   .badge-success {
       background: linear-gradient(135deg, rgba(16, 185, 129, 0.15), rgba(5, 150, 105, 0.15));
       color: var(--success);
   }
   
   .badge-warning {
       background: linear-gradient(135deg, rgba(245, 158, 11, 0.15), rgba(217, 119, 6, 0.15));
       color: var(--warning);
   }
   
   .badge-danger {
       background: linear-gradient(135deg, rgba(239, 68, 68, 0.15), rgba(220, 38, 38, 0.15));
       color: var(--danger);
   }
   
   .badge-info {
       background: linear-gradient(135deg, rgba(59, 130, 246, 0.15), rgba(37, 99, 235, 0.15));
       color: var(--info);
   }
   
   .badge-primary {
       background: linear-gradient(135deg, rgba(99, 102, 241, 0.15), rgba(79, 70, 229, 0.15));
       color: var(--primary);
   }
   
   /* ==========================================
      ALERTS - MODERN
      ========================================== */
   .alert {
       padding: 16px 20px;
       border-radius: 12px;
       margin-bottom: 20px;
       display: flex;
       align-items: center;
       gap: 14px;
       font-weight: 600;
       box-shadow: var(--shadow);
   }
   
   .alert-success {
       background: linear-gradient(135deg, rgba(16, 185, 129, 0.1), rgba(5, 150, 105, 0.05));
       color: var(--success);
       border: 2px solid rgba(16, 185, 129, 0.3);
   }
   
   .alert-danger {
       background: linear-gradient(135deg, rgba(239, 68, 68, 0.1), rgba(220, 38, 38, 0.05));
       color: var(--danger);
       border: 2px solid rgba(239, 68, 68, 0.3);
   }
   
   .alert-warning {
       background: linear-gradient(135deg, rgba(245, 158, 11, 0.1), rgba(217, 119, 6, 0.05));
       color: var(--warning);
       border: 2px solid rgba(245, 158, 11, 0.3);
   }
   
   .alert-info {
       background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(37, 99, 235, 0.05));
       color: var(--info);
       border: 2px solid rgba(59, 130, 246, 0.3);
   }
   
   /* ==========================================
      FORM ADVANCED
      ========================================== */
   .form-row {
       display: grid;
       grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
       gap: 20px;
       margin-bottom: 20px;
   }
   
   select.form-control {
       appearance: none;
       background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%236366f1' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
       background-repeat: no-repeat;
       background-position: right 16px center;
       padding-right: 40px;
   }
   
   /* ==========================================
      MODAL - Proper Z-Index
      ========================================== */
   .modal {
       display: none;
       position: fixed;
       top: 0;
       left: 0;
       width: 100%;
       height: 100%;
       background: rgba(0,0,0,0.5);
       z-index: 10000;
       align-items: center;
       justify-content: center;
       overflow-y: auto;
   }
   
   .modal.show {
       display: flex;
   }
   
   .modal-content {
       background: white;
       border-radius: 12px;
       max-width: 600px;
       width: 90%;
       max-height: 90vh;
       overflow-y: auto;
       animation: modalSlide 0.3s ease;
       position: relative;
       margin: auto;
   }
   
   @keyframes modalSlide {
       from {
           opacity: 0;
           transform: translateY(-50px);
       }
       to {
           opacity: 1;
           transform: translateY(0);
       }
   }
   
   /* Image Preview */
   .image-preview {
       max-width: 100%;
       max-height: 400px;
       border-radius: 8px;
       margin-top: 12px;
       display: block;
       margin-left: auto;
       margin-right: auto;
   }
   
   /* ==========================================
      RESPONSIVE
      ========================================== */
   @media (max-width: 768px) {
       .sidebar {
           margin-left: -280px;
       }
       
       .main-content {
           margin-left: 0;
       }
       
       .stats-grid {
           grid-template-columns: 1fr;
       }
       
       .form-row {
           grid-template-columns: 1fr;
       }
       
       .topbar {
           padding: 16px 20px;
       }
       
       .content-area {
           padding: 20px;
       }
       
       .login-box {
           padding: 32px 24px;
       }
       
       .modal-content {
           width: 95%;
           max-height: 95vh;
       }
   }
   
   /* ==========================================
      UTILITIES
      ========================================== */
   .text-center { text-align: center; }
   .text-right { text-align: right; }
   .mt-3 { margin-top: 16px; }
   .mb-3 { margin-bottom: 16px; }
   .d-flex { display: flex; }
   .justify-between { justify-content: space-between; }
   .align-center { align-items: center; }
   .gap-2 { gap: 12px; }