/* ============================================================
   OilFleet Pro — Main Stylesheet
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Syne:wght@400;600;700;800&family=DM+Sans:wght@300;400;500;600&display=swap');

:root {
  --primary:       #e85d04;
  --primary-dark:  #c44d00;
  --primary-light: #ff6b1a;
  --secondary:     #1a1a2e;
  --accent:        #f48c06;
  --surface:       #ffffff;
  --surface-2:     #f8f9fa;
  --border:        #e9ecef;
  --text:          #212529;
  --text-muted:    #6c757d;
  --success:       #2d9e6b;
  --danger:        #dc3545;
  --warning:       #ffc107;
  --info:          #0dcaf0;

  --sidebar-bg:    #0f0f1a;
  --sidebar-text:  rgba(255,255,255,0.75);
  --sidebar-active:#e85d04;
  --sidebar-hover: rgba(232,93,4,0.12);

  --radius:        10px;
  --radius-lg:     16px;
  --shadow-sm:     0 2px 8px rgba(0,0,0,.06);
  --shadow:        0 4px 20px rgba(0,0,0,.10);
  --shadow-lg:     0 8px 40px rgba(0,0,0,.15);

  --font-head:     'Syne', sans-serif;
  --font-body:     'DM Sans', sans-serif;
}

/* Dark mode */
[data-theme="dark"] {
  --surface:    #1e1e2e;
  --surface-2:  #2a2a3e;
  --border:     #3a3a52;
  --text:       #e4e4f0;
  --text-muted: #9898b2;
  --shadow-sm:  0 2px 8px rgba(0,0,0,.3);
  --shadow:     0 4px 20px rgba(0,0,0,.4);
}

*, *::before, *::after { box-sizing: border-box; }

body {
  font-family: var(--font-body);
  background: var(--surface-2);
  color: var(--text);
  font-size: 14.5px;
  line-height: 1.6;
  margin: 0;
  transition: background .3s, color .3s;
}

h1,h2,h3,h4,h5,h6,.navbar-brand,.sidebar-logo {
  font-family: var(--font-head);
}

/* ---- Layout ---- */

.wrapper {
  display: flex;
  min-height: 100vh;
}

/* ---- Sidebar ---- */

.sidebar {
  width: 260px;
  min-height: 100vh;
  background: var(--sidebar-bg);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  z-index: 1000;
  transition: transform .3s cubic-bezier(.4,0,.2,1);
  overflow-y: auto;
  overflow-x: hidden;
}

.sidebar-brand {
  padding: 24px 20px 20px;
  border-bottom: 1px solid rgba(255,255,255,.07);
  display: flex;
  align-items: center;
  gap: 12px;
}

.sidebar-brand .logo-icon {
  width: 40px; height: 40px;
  background: var(--primary);
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; flex-shrink: 0;
}

.sidebar-brand .brand-text {
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 18px;
  color: #fff;
  line-height: 1.2;
}

.sidebar-brand .brand-sub {
  font-size: 11px;
  color: rgba(255,255,255,.4);
  font-family: var(--font-body);
  font-weight: 400;
}

.sidebar-nav { padding: 16px 12px; flex: 1; }

.nav-section-title {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: rgba(255,255,255,.3);
  padding: 8px 8px 4px;
  margin-top: 12px;
}

.sidebar-nav .nav-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: 8px;
  color: var(--sidebar-text);
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 2px;
  transition: all .2s;
  text-decoration: none;
}

.sidebar-nav .nav-link i {
  font-size: 16px;
  width: 20px;
  text-align: center;
  flex-shrink: 0;
}

.sidebar-nav .nav-link:hover {
  background: var(--sidebar-hover);
  color: #fff;
}

.sidebar-nav .nav-link.active {
  background: var(--primary);
  color: #fff;
  font-weight: 600;
}

.sidebar-footer {
  padding: 16px;
  border-top: 1px solid rgba(255,255,255,.07);
}

.sidebar-footer .nav-link {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 12px;
  border-radius: 8px;
  color: rgba(255,255,255,.5);
  font-size: 13px;
  text-decoration: none;
  transition: all .2s;
}
.sidebar-footer .nav-link:hover { color: #fff; background: rgba(255,255,255,.08); }

/* ---- Main Content ---- */

.main-content {
  margin-left: 260px;
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  transition: margin-left .3s;
}

/* ---- Topbar ---- */

.topbar {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 0 24px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 999;
  box-shadow: var(--shadow-sm);
}

.topbar-left { display: flex; align-items: center; gap: 12px; }

.sidebar-toggle {
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 20px;
  cursor: pointer;
  padding: 6px;
  border-radius: 6px;
  transition: all .2s;
  display: none;
}
.sidebar-toggle:hover { background: var(--surface-2); color: var(--text); }

.page-title { font-size: 18px; font-weight: 700; color: var(--text); margin: 0; }

.topbar-right { display: flex; align-items: center; gap: 8px; }

/* Notification Bell */
.notif-btn {
  position: relative;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 10px;
  color: var(--text-muted);
  cursor: pointer;
  transition: all .2s;
  text-decoration: none;
  display: flex; align-items: center;
}
.notif-btn:hover { background: var(--primary); color: #fff; border-color: var(--primary); }

.notif-badge {
  position: absolute;
  top: -4px; right: -4px;
  background: var(--danger);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  border-radius: 50%;
  width: 18px; height: 18px;
  display: flex; align-items: center; justify-content: center;
  border: 2px solid var(--surface);
}

.user-menu {
  display: flex; align-items: center; gap: 8px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 6px 12px;
  cursor: pointer;
  text-decoration: none;
  color: var(--text);
  transition: all .2s;
}
.user-menu:hover { border-color: var(--primary); color: var(--primary); }
.user-avatar {
  width: 30px; height: 30px;
  background: var(--primary);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
}

/* ---- Page Content ---- */

.page-content {
  padding: 24px;
  flex: 1;
}

/* ---- Cards ---- */

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition: box-shadow .2s;
}
.card:hover { box-shadow: var(--shadow); }

.card-header {
  background: transparent;
  border-bottom: 1px solid var(--border);
  padding: 16px 20px;
  font-weight: 700;
  font-family: var(--font-head);
  font-size: 15px;
  display: flex; align-items: center; justify-content: space-between;
}

.card-body { padding: 20px; }

/* ---- Stat Cards ---- */

.stat-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  box-shadow: var(--shadow-sm);
  transition: all .25s;
}
.stat-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }

.stat-icon {
  width: 52px; height: 52px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 22px;
  flex-shrink: 0;
}

.stat-icon.orange { background: rgba(232,93,4,.12); color: var(--primary); }
.stat-icon.green  { background: rgba(45,158,107,.12); color: var(--success); }
.stat-icon.blue   { background: rgba(13,202,240,.12); color: var(--info); }
.stat-icon.red    { background: rgba(220,53,69,.12); color: var(--danger); }
.stat-icon.yellow { background: rgba(255,193,7,.12); color: var(--warning); }
.stat-icon.purple { background: rgba(111,66,193,.12); color: #6f42c1; }

.stat-value {
  font-family: var(--font-head);
  font-size: 28px;
  font-weight: 800;
  line-height: 1;
  color: var(--text);
}
.stat-label { font-size: 13px; color: var(--text-muted); margin-top: 2px; }

/* ---- Tables ---- */

.table { font-size: 14px; }
.table th {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 12px;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--text-muted);
  background: var(--surface-2);
  border-color: var(--border);
}
.table td { border-color: var(--border); vertical-align: middle; }
.table tbody tr:hover { background: rgba(232,93,4,.03); }

/* ---- Forms ---- */

.form-control, .form-select {
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-family: var(--font-body);
  font-size: 14px;
  padding: 9px 12px;
  background: var(--surface);
  color: var(--text);
  transition: border-color .2s, box-shadow .2s;
}
.form-control:focus, .form-select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(232,93,4,.12);
  background: var(--surface);
}

.form-label {
  font-weight: 600;
  font-size: 13px;
  color: var(--text);
  margin-bottom: 5px;
}

/* ---- Buttons ---- */

.btn {
  font-family: var(--font-body);
  font-weight: 600;
  border-radius: 8px;
  font-size: 14px;
  transition: all .2s;
}

.btn-primary {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}
.btn-primary:hover {
  background: var(--primary-dark);
  border-color: var(--primary-dark);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(232,93,4,.35);
}

.btn-outline-primary {
  border-color: var(--primary);
  color: var(--primary);
}
.btn-outline-primary:hover {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}

/* ---- Badges ---- */

.badge { font-family: var(--font-body); font-weight: 600; font-size: 11.5px; padding: 4px 9px; border-radius: 6px; }

/* ---- Notification Dropdown ---- */

.notif-dropdown {
  width: 360px;
  max-height: 480px;
  overflow-y: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  background: var(--surface);
  padding: 0;
}

.notif-item {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  transition: background .15s;
  display: flex; gap: 12px; align-items: flex-start;
}
.notif-item:hover { background: var(--surface-2); }
.notif-item.unread { background: rgba(232,93,4,.04); }
.notif-item .notif-icon {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: rgba(232,93,4,.1);
  display: flex; align-items: center; justify-content: center;
  color: var(--primary);
  flex-shrink: 0;
}
.notif-title { font-weight: 600; font-size: 13px; color: var(--text); }
.notif-msg { font-size: 12px; color: var(--text-muted); margin-top: 2px; }
.notif-time { font-size: 11px; color: var(--text-muted); margin-top: 3px; }

/* ---- Status Timeline ---- */

.status-timeline {
  display: flex;
  align-items: center;
  gap: 0;
  margin: 20px 0;
}
.timeline-step {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
}
.timeline-step:not(:last-child)::after {
  content: '';
  position: absolute;
  top: 16px;
  left: 50%;
  width: 100%;
  height: 2px;
  background: var(--border);
  z-index: 0;
}
.timeline-step.done:not(:last-child)::after { background: var(--primary); }
.timeline-dot {
  width: 32px; height: 32px;
  border-radius: 50%;
  border: 2px solid var(--border);
  background: var(--surface);
  display: flex; align-items: center; justify-content: center;
  font-size: 13px;
  color: var(--text-muted);
  z-index: 1;
  transition: all .3s;
}
.timeline-step.done .timeline-dot {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}
.timeline-step.current .timeline-dot {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
  box-shadow: 0 0 0 6px rgba(232,93,4,.2);
}
.timeline-label { font-size: 11px; font-weight: 600; color: var(--text-muted); margin-top: 6px; text-align: center; }
.timeline-step.done .timeline-label,
.timeline-step.current .timeline-label { color: var(--primary); }

/* ---- Public Pages ---- */

.public-header {
  background: linear-gradient(135deg, var(--secondary) 0%, #16213e 100%);
  padding: 80px 0 60px;
  position: relative;
  overflow: hidden;
}
.public-header::before {
  content: '';
  position: absolute;
  top: -50%; right: -10%;
  width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(232,93,4,.15) 0%, transparent 70%);
  border-radius: 50%;
}
.public-header h1 {
  font-size: 42px;
  font-weight: 800;
  color: #fff;
}
.public-header p { color: rgba(255,255,255,.7); font-size: 17px; }

.booking-card {
  background: var(--surface);
  border-radius: 20px;
  box-shadow: 0 20px 60px rgba(0,0,0,.12);
  overflow: hidden;
  margin-top: -40px;
}
.booking-card-header {
  background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
  padding: 24px 28px;
  color: #fff;
}
.booking-card-header h4 { font-weight: 800; margin: 0; font-size: 20px; }

.payment-card {
  background: linear-gradient(135deg, #0f0f1a 0%, #1a1a2e 100%);
  border-radius: var(--radius-lg);
  padding: 28px;
  color: #fff;
}
.payment-card h5 { font-weight: 800; color: var(--accent); }
.bank-detail { border-bottom: 1px solid rgba(255,255,255,.1); padding: 10px 0; }
.bank-detail .label { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: rgba(255,255,255,.4); }
.bank-detail .value { font-size: 15px; font-weight: 600; color: #fff; }

/* ---- Misc ---- */

.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
}
.page-header h2 {
  font-size: 22px;
  font-weight: 800;
  margin: 0;
  color: var(--text);
}

.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-muted);
}
.empty-state i { font-size: 48px; margin-bottom: 12px; opacity: .3; }
.empty-state p { font-size: 15px; }

/* ---- Login Pages ---- */

.auth-wrapper {
  min-height: 100vh;
  background: linear-gradient(135deg, #0f0f1a 0%, #1a1a2e 50%, #16213e 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  position: relative;
  overflow: hidden;
}
.auth-wrapper::before {
  content: '';
  position: absolute;
  top: -20%; left: -10%;
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(232,93,4,.2) 0%, transparent 70%);
  border-radius: 50%;
}
.auth-wrapper::after {
  content: '';
  position: absolute;
  bottom: -20%; right: -10%;
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(244,140,6,.15) 0%, transparent 70%);
  border-radius: 50%;
}
.auth-card {
  background: rgba(255,255,255,.05);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 20px;
  padding: 40px;
  width: 100%;
  max-width: 420px;
  position: relative;
  z-index: 1;
}
.auth-card .form-control {
  background: rgba(255,255,255,.07);
  border-color: rgba(255,255,255,.15);
  color: #fff;
}
.auth-card .form-control::placeholder { color: rgba(255,255,255,.4); }
.auth-card .form-control:focus {
  background: rgba(255,255,255,.1);
  border-color: var(--primary);
  color: #fff;
}
.auth-card .form-label { color: rgba(255,255,255,.8); }

/* ---- DataTables Override ---- */

.dataTables_wrapper .dataTables_filter input,
.dataTables_wrapper .dataTables_length select {
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: 5px 10px;
  color: var(--text);
  background: var(--surface);
}
.dataTables_wrapper .dataTables_paginate .paginate_button {
  border-radius: 6px !important;
  padding: 4px 10px !important;
}
.dataTables_wrapper .dataTables_paginate .paginate_button.current {
  background: var(--primary) !important;
  border-color: var(--primary) !important;
  color: #fff !important;
}

/* ---- Responsive ---- */

@media (max-width: 991.98px) {
  .sidebar {
    transform: translateX(-100%);
  }
  .sidebar.open {
    transform: translateX(0);
  }
  .main-content { margin-left: 0; }
  .sidebar-toggle { display: flex; }
  .stat-value { font-size: 22px; }
}

@media (max-width: 575.98px) {
  .page-content { padding: 16px; }
  .topbar { padding: 0 16px; }
}

/* ---- Print ---- */

@media print {
  .sidebar, .topbar, .btn, .no-print { display: none !important; }
  .main-content { margin-left: 0 !important; }
  .page-content { padding: 0 !important; }
}

/* ---- Animations ---- */

@keyframes slideInUp {
  from { transform: translateY(20px); opacity: 0; }
  to   { transform: translateY(0);    opacity: 1; }
}
.animate-in { animation: slideInUp .4s ease forwards; }

.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.5);
  z-index: 999;
}
.sidebar-overlay.show { display: block; }
