/* ===== Tour Operator SaaS – Design System (dérivé de TsaraKonta) ===== */
:root {
  --sidebar-width: 260px;
  --topbar-height: 56px;
  --primary: #0e7c86;
  --primary-dark: #0b6a72;
  --accent: #c62828;
  --sidebar-bg: #0f172a;
  --sidebar-text: #94a3b8;
  --sidebar-hover: rgba(255,255,255,0.08);
  --sidebar-active: rgba(14,124,134,0.35);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background: #f1f7f9;
  color: #1e293b;
}

/* ===== SIDEBAR ===== */
.sidebar {
  position: fixed;
  top: 0; left: 0;
  width: var(--sidebar-width);
  height: 100vh;
  background: var(--sidebar-bg);
  display: flex;
  flex-direction: column;
  z-index: 100;
  overflow-y: auto;
  transition: transform 0.25s ease;
}
.sidebar-brand {
  display: flex; align-items: center; gap: 10px;
  padding: 20px 18px 16px;
  border-bottom: 1px solid rgba(255,255,255,0.07);
}
.brand-icon { font-size: 1.6rem; }
.brand-name { color: #fff; font-size: 1.2rem; font-weight: 700; letter-spacing: -0.5px; }

.sidebar-company { padding: 12px 18px; border-bottom: 1px solid rgba(255,255,255,0.07); }
.sidebar-company .fw-semibold { color: #e2e8f0; font-size: 0.9rem; }
.badge-devise {
  display: inline-block; background: rgba(14,124,134,0.4); color: #99e6ec;
  border-radius: 4px; padding: 1px 6px; font-size: 0.72rem; font-weight: 600; margin-top: 2px;
}

.sidebar-nav { flex: 1; padding: 8px 10px; }
.nav-section {
  color: #475569; font-size: 0.68rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.08em; padding: 16px 8px 4px;
}
.nav-item {
  display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 8px;
  color: var(--sidebar-text); text-decoration: none; font-size: 0.875rem; font-weight: 500;
  transition: all 0.15s; margin-bottom: 2px;
}
.nav-item.sub { padding-left: 26px; font-size: 0.82rem; }
.nav-item.sa { color: #ef4444; }
.nav-item:hover { background: var(--sidebar-hover); color: #e2e8f0; }
.nav-item.active { background: var(--sidebar-active); color: #99e6ec; font-weight: 600; }
.nav-item i { font-size: 1rem; width: 18px; text-align: center; }

.sidebar-footer { padding: 14px 14px 16px; border-top: 1px solid rgba(255,255,255,0.07); }
.user-info { display: flex; align-items: center; gap: 10px; color: #cbd5e1; font-size: 0.85rem; margin-bottom: 8px; }
.user-info i { font-size: 1.5rem; color: #64748b; }

/* ===== MAIN CONTENT ===== */
.main-content { margin-left: var(--sidebar-width); min-height: 100vh; display: flex; flex-direction: column; }
.topbar { height: var(--topbar-height); background: #fff; border-bottom: 1px solid #e2e8f0; position: sticky; top: 0; z-index: 50; }
.page-content { flex: 1; padding: 24px; }
.page-header { margin-bottom: 24px; }

/* ===== AUTH ===== */
.auth-wrapper {
  min-height: 100vh;
  background: linear-gradient(135deg, #0f172a 0%, #0e7c86 100%);
  display: flex; align-items: center; justify-content: center; padding: 20px;
}
.auth-card { background: #fff; border-radius: 16px; padding: 40px 36px; width: 100%; max-width: 440px; box-shadow: 0 25px 50px rgba(0,0,0,0.3); }
.auth-logo { text-align: center; margin-bottom: 28px; }

/* ===== KPI Cards ===== */
.kpi-card { border-radius: 12px; padding: 20px; display: flex; align-items: center; gap: 16px; box-shadow: 0 1px 3px rgba(0,0,0,0.08); }
.kpi-blue { background: linear-gradient(135deg, #dbeafe, #bfdbfe); }
.kpi-green { background: linear-gradient(135deg, #dcfce7, #bbf7d0); }
.kpi-orange { background: linear-gradient(135deg, #fef3c7, #fde68a); }
.kpi-red { background: linear-gradient(135deg, #fee2e2, #fecaca); }
.kpi-teal { background: linear-gradient(135deg, #ccfbf1, #99f6e4); }
.kpi-icon { font-size: 2rem; opacity: 0.7; }
.kpi-value { font-size: 1.5rem; font-weight: 700; line-height: 1; }
.kpi-label { font-size: 0.8rem; color: #64748b; margin-top: 4px; }

/* ===== Hub cards ===== */
.hub-card {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: #fff; border-radius: 12px; padding: 28px 20px; text-align: center; text-decoration: none;
  color: #1e293b; box-shadow: 0 1px 3px rgba(0,0,0,0.08); transition: all 0.2s; border: 2px solid transparent; height: 100%;
}
.hub-card:hover { border-color: var(--primary); box-shadow: 0 4px 12px rgba(14,124,134,0.15); transform: translateY(-2px); color: var(--primary); }

/* ===== Tables ===== */
.table th { font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.04em; white-space: nowrap; }
.table td { font-size: 0.875rem; vertical-align: middle; }
.table-xs td, .table-xs th { padding: 0.25rem 0.4rem; font-size: 0.8rem; }

/* ===== Card / Buttons / Forms ===== */
.card { border-radius: 12px; }
.card-header { border-radius: 12px 12px 0 0 !important; padding: 14px 18px; font-size: 0.9rem; }
.btn { border-radius: 8px; }
.btn-primary { background: var(--primary); border-color: var(--primary); }
.btn-primary:hover { background: var(--primary-dark); border-color: var(--primary-dark); }
.btn-outline-primary { color: var(--primary); border-color: var(--primary); }
.btn-outline-primary:hover { background: var(--primary); border-color: var(--primary); }
.text-primary { color: var(--primary) !important; }
.form-section-title { font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--primary); border-bottom: 2px solid #d6eef0; padding-bottom: 4px; margin: 18px 0 12px; }
.form-label { font-size: 0.82rem; }
.readonly-field { background: #e3f0f4 !important; }
.status-badge { font-size: 0.72rem; }
.sticky-total { position: sticky; bottom: 0; background: #fff; border-top: 2px solid var(--primary); }

/* ===== Print ===== */
@media print {
  .sidebar, .topbar, button, .btn, .no-print { display: none !important; }
  .main-content { margin-left: 0 !important; }
  .page-content { padding: 0 !important; }
  .card { box-shadow: none !important; border: 1px solid #ddd !important; }
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
  .sidebar { transform: translateX(-100%); }
  .sidebar.open { transform: translateX(0); }
  .main-content { margin-left: 0; }
  .auth-card { padding: 28px 20px; }
}
