/* ==========================================================================
   WHITE FALCON TRAVELS - ADMIN PANEL MODERN DASHBOARD STYLES
   ========================================================================== */

:root {
  --adm-bg: #f1f5f9;
  --adm-sidebar: #0b2545;
  --adm-sidebar-active: #00487c;
  --adm-primary: #0284c7;
  --adm-primary-hover: #0369a1;
  --adm-accent: #ff6b35;
  --adm-success: #10b981;
  --adm-warning: #f59e0b;
  --adm-danger: #ef4444;
  --adm-card: #ffffff;
  --adm-text: #1e293b;
  --adm-muted: #64748b;
  --adm-border: #e2e8f0;
  --adm-font: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

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

body {
  font-family: var(--adm-font);
  background: var(--adm-bg);
  color: var(--adm-text);
  line-height: 1.5;
  min-height: 100vh;
}

a {
  color: inherit;
  text-decoration: none;
}

/* Layout */
.admin-layout {
  display: flex;
  min-height: 100vh;
}

/* Sidebar */
.admin-sidebar {
  width: 260px;
  background: var(--adm-sidebar);
  color: #ffffff;
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 100;
  transition: transform 0.3s ease;
}

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

.sidebar-brand img {
  height: 38px;
  width: auto;
  object-fit: contain;
}

.sidebar-brand span {
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.5px;
  color: #ffffff;
}

.sidebar-menu {
  padding: 16px 12px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
  overflow-y: auto;
}

.sidebar-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: rgba(255, 255, 255, 0.45);
  padding: 12px 14px 4px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 16px;
  border-radius: 8px;
  color: #cbd5e1;
  font-size: 0.92rem;
  font-weight: 500;
  transition: all 0.2s;
}

.nav-item svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.nav-item:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
}

.nav-item.active {
  background: var(--adm-primary);
  color: #ffffff;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(2, 132, 199, 0.35);
}

.sidebar-footer {
  padding: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.user-snippet {
  font-size: 0.85rem;
  line-height: 1.3;
}

.user-name {
  font-weight: 600;
  color: #ffffff;
}

.user-role {
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.75rem;
}

/* Main Content Area */
.admin-main {
  flex: 1;
  margin-left: 260px;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.admin-topbar {
  background: #ffffff;
  border-bottom: 1px solid var(--adm-border);
  padding: 16px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 90;
}

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

.topbar-title {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--adm-text);
}

.mobile-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
  border-radius: 6px;
}

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

.admin-body {
  padding: 28px;
  flex: 1;
}

/* Metric Cards Grid */
.metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin-bottom: 28px;
}

.metric-card {
  background: #ffffff;
  border-radius: 12px;
  padding: 22px;
  border: 1px solid var(--adm-border);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
  display: flex;
  align-items: center;
  gap: 16px;
  transition: transform 0.2s, box-shadow 0.2s;
}

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

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

.metric-icon.blue { background: #e0f2fe; color: #0284c7; }
.metric-icon.orange { background: #ffedd5; color: #ea580c; }
.metric-icon.green { background: #dcfce7; color: #16a34a; }
.metric-icon.purple { background: #f3e8ff; color: #9333ea; }

.metric-info .metric-val {
  font-size: 1.7rem;
  font-weight: 800;
  color: var(--adm-text);
  line-height: 1.2;
}

.metric-info .metric-label {
  font-size: 0.85rem;
  color: var(--adm-muted);
  font-weight: 500;
}

/* Data Tables & Cards */
.admin-card {
  background: #ffffff;
  border-radius: 12px;
  border: 1px solid var(--adm-border);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
  overflow: hidden;
  margin-bottom: 28px;
}

.admin-card-header {
  padding: 20px 24px;
  border-bottom: 1px solid var(--adm-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.admin-card-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--adm-text);
}

.admin-table-wrap {
  width: 100%;
  overflow-x: auto;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.9rem;
}

.admin-table th {
  background: #f8fafc;
  padding: 12px 18px;
  font-weight: 600;
  color: #475569;
  border-bottom: 1px solid var(--adm-border);
  white-space: nowrap;
}

.admin-table td {
  padding: 14px 18px;
  border-bottom: 1px solid var(--adm-border);
  vertical-align: middle;
}

.admin-table tr:hover {
  background: #f8fafc;
}

.pkg-thumb-sm {
  width: 54px;
  height: 42px;
  border-radius: 6px;
  object-fit: cover;
  box-shadow: 0 1px 4px rgba(0,0,0,0.1);
}

/* Status Badges */
.badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: capitalize;
}

.badge-new { background: #e0f2fe; color: #0369a1; }
.badge-contacted { background: #fef3c7; color: #b45309; }
.badge-follow { background: #ede9fe; color: #6d28d9; }
.badge-converted { background: #dcfce7; color: #15803d; }
.badge-cancelled { background: #fee2e2; color: #b91c1c; }
.badge-active { background: #dcfce7; color: #15803d; }
.badge-draft { background: #f1f5f9; color: #64748b; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 18px;
  border-radius: 8px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.2s;
}

.btn-primary {
  background: var(--adm-primary);
  color: #ffffff;
}

.btn-primary:hover {
  background: var(--adm-primary-hover);
}

.btn-accent {
  background: var(--adm-accent);
  color: #ffffff;
}

.btn-accent:hover {
  background: #ea580c;
}

.btn-outline {
  background: transparent;
  border-color: var(--adm-border);
  color: var(--adm-text);
}

.btn-outline:hover {
  background: #f8fafc;
}

.btn-sm {
  padding: 6px 12px;
  font-size: 0.8rem;
}

.btn-danger {
  background: #fee2e2;
  color: #b91c1c;
  border-color: #fca5a5;
}

.btn-danger:hover {
  background: #fca5a5;
  color: #7f1d1d;
}

/* Forms */
.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 16px;
}

.form-group.col-full {
  grid-column: 1 / -1;
}

.form-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: #334155;
}

.form-control {
  width: 100%;
  padding: 10px 14px;
  border-radius: 8px;
  border: 1px solid var(--adm-border);
  font-size: 0.9rem;
  font-family: inherit;
  transition: border-color 0.2s, box-shadow 0.2s;
  background: #ffffff;
}

.form-control:focus {
  outline: none;
  border-color: var(--adm-primary);
  box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.15);
}

textarea.form-control {
  min-height: 90px;
  resize: vertical;
}

/* Responsive */
@media (max-width: 900px) {
  .admin-sidebar {
    transform: translateX(-100%);
  }
  .admin-sidebar.show {
    transform: translateX(0);
  }
  .admin-main {
    margin-left: 0;
  }
  .mobile-toggle {
    display: inline-flex;
  }
  .admin-body {
    padding: 18px 14px;
  }
}
