/* ═══════════════════════════════════════════════════════════
   Carib Live Platform Hub — Luxury Obsidian Design System
   Matches Main Admin Luxury & Dark Glassmorphic Theme
   ═══════════════════════════════════════════════════════════ */

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

:root {
  --plat-bg:          #020617;
  --plat-canvas:      radial-gradient(circle at top left, #1e3a8a 0, #1d4ed8 15%, transparent 50%), radial-gradient(circle at bottom right, #4c1d95 0, #020617 55%), #020617;
  --plat-card-bg:     radial-gradient(circle at top left, rgba(248, 250, 252, 0.08), rgba(15, 23, 42, 0.95));
  --plat-card-header: rgba(15, 23, 42, 0.85);
  --plat-border:      1px solid rgba(148, 163, 184, 0.18);
  --plat-border-color:rgba(148, 163, 184, 0.18);
  --plat-border-glow: rgba(99, 102, 241, 0.35);
  
  --plat-primary:     #38BDF8;
  --plat-primary-grad:linear-gradient(135deg, #38BDF8, #6366F1);
  --plat-purple:      #8B5CF6;
  --plat-cyan:        #06B6D4;
  --plat-green:       #10B981;
  --plat-amber:       #F59E0B;
  --plat-red:         #EF4444;

  --plat-text-main:   #F8FAFC;
  --plat-text-muted:  #94A3B8;
  --plat-text-dark:   #64748B;
  
  --plat-shadow:      0 20px 50px rgba(0, 0, 0, 0.6);
  --nav-h:            64px;
}

html, body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  color: var(--plat-text-main);
  background: var(--plat-canvas);
  background-color: var(--plat-bg);
  background-attachment: fixed;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* ── Left-Hand Sidebar ───────────────────────────────────── */
.plat-sidebar {
  position: fixed; top: 0; left: 0; width: 260px; height: 100vh;
  background: rgba(15, 23, 42, 0.96);
  border-right: var(--plat-border);
  z-index: 1050; display: flex; flex-direction: column;
  overflow-y: auto; box-shadow: 4px 0 30px rgba(0,0,0,0.5);
  transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  backdrop-filter: blur(20px);
}
.plat-sidebar__logo {
  padding: 20px;
  border-bottom: var(--plat-border);
  display: flex; align-items: center; gap: 12px;
  text-decoration: none;
}
.plat-sidebar__logo-icon {
  width: 40px; height: 40px; border-radius: 10px;
  background: var(--plat-primary-grad);
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 17px; font-weight: 800;
  box-shadow: 0 4px 14px rgba(56,189,248,0.4);
}
.plat-sidebar__logo-title {
  font-family: 'Outfit', sans-serif;
  font-size: 16px; font-weight: 700; color: #F8FAFC; line-height: 1.2;
}
.plat-sidebar__logo-sub {
  font-size: 11px; color: var(--plat-text-muted); text-transform: uppercase; letter-spacing: 0.06em;
}
.plat-sidebar__nav { padding: 16px 12px; flex: 1; display: flex; flex-direction: column; gap: 4px; }
.plat-sidebar__section {
  font-size: 10.5px; font-weight: 700; color: #64748B;
  text-transform: uppercase; letter-spacing: 0.08em;
  padding: 12px 12px 4px;
}
.plat-nav-item {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 14px; border-radius: 10px;
  font-size: 13.5px; font-weight: 500; color: var(--plat-text-muted);
  text-decoration: none; transition: all 0.2s ease;
}
.plat-nav-item i { width: 18px; font-size: 14px; text-align: center; color: #64748B; transition: color 0.2s; }
.plat-nav-item:hover { background: rgba(255,255,255,0.06); color: #F8FAFC; transform: translateX(2px); }
.plat-nav-item:hover i { color: var(--plat-primary); }
.plat-nav-item.active {
  background: linear-gradient(135deg, rgba(56,189,248,0.2), rgba(99,102,241,0.25));
  border: 1px solid rgba(56,189,248,0.35);
  color: #F8FAFC; font-weight: 600;
}
.plat-nav-item.active i { color: var(--plat-primary); }

.plat-sidebar__footer {
  padding: 16px; border-top: var(--plat-border);
  display: flex; align-items: center; justify-content: space-between;
}
.plat-sidebar__user {
  display: flex; align-items: center; gap: 10px; font-size: 13px; color: #CBD5E1; font-weight: 600;
}
.plat-sidebar__logout {
  color: #EF4444; font-size: 15px; text-decoration: none; padding: 6px 8px;
  border-radius: 8px; transition: background 0.2s;
}
.plat-sidebar__logout:hover { background: rgba(239,68,68,0.15); }

/* ── Content Top Bar ──────────────────────────────────────── */
.plat-topbar {
  margin-left: 260px;
  height: var(--nav-h);
  background: rgba(15, 23, 42, 0.85);
  border-bottom: var(--plat-border);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 32px;
  position: sticky; top: 0; z-index: 100;
  backdrop-filter: blur(16px);
}
.plat-topbar__title {
  font-size: 14px; font-weight: 600; color: #F8FAFC;
  display: flex; align-items: center; gap: 10px;
}
.plat-badge-pill {
  font-size: 10.5px; font-weight: 800; color: var(--plat-primary);
  background: rgba(56,189,248,0.12); border: 1px solid rgba(56,189,248,0.3);
  padding: 3px 8px; border-radius: 8px; letter-spacing: 0.06em;
}

/* ── Page Wrapper ─────────────────────────────────────────── */
.plat-page {
  margin-left: 260px;
  padding: 32px 36px 64px;
  max-width: 1440px;
}

/* ── Page Header ──────────────────────────────────────────── */
.plat-page-header {
  display: flex; align-items: flex-start; justify-content: space-between;
  margin-bottom: 30px; gap: 16px;
}
.plat-page-header__title {
  font-family: 'Outfit', sans-serif;
  font-size: 26px; font-weight: 800; color: #F8FAFC; line-height: 1.2;
  letter-spacing: -0.02em;
}
.plat-page-header__sub {
  font-size: 13.5px; color: var(--plat-text-muted); margin-top: 4px;
}

/* ── Cards ────────────────────────────────────────────────── */
.plat-card {
  background: var(--plat-card-bg);
  border: var(--plat-border);
  border-radius: 16px;
  backdrop-filter: blur(16px);
  box-shadow: var(--plat-shadow);
  color: var(--plat-text-main);
  overflow: hidden;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.plat-card:hover {
  border-color: rgba(99,102,241,0.3);
}

/* ── Buttons ──────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 9px 18px; border-radius: 10px; font-size: 13.5px; font-weight: 600;
  text-decoration: none; cursor: pointer; border: 1px solid transparent;
  transition: all 0.2s ease;
}
.btn-primary {
  background: var(--plat-primary-grad);
  color: #FFF; box-shadow: 0 4px 14px rgba(56,189,248,0.35);
}
.btn-primary:hover {
  filter: brightness(1.1); transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(56,189,248,0.5);
  color: #FFF;
}
.btn-outline {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.15);
  color: var(--plat-text-main);
}
.btn-outline:hover {
  background: rgba(255,255,255,0.08);
  border-color: rgba(255,255,255,0.25);
  color: #FFF;
}
.btn-danger {
  background: rgba(239,68,68,0.15);
  border: 1px solid rgba(239,68,68,0.35);
  color: #F87171;
}
.btn-danger:hover {
  background: #EF4444; color: #FFF;
}
.btn-sm { padding: 6px 12px; font-size: 12.5px; border-radius: 8px; }

/* ── Form Inputs ──────────────────────────────────────────── */
.plat-input, .plat-select {
  width: 100%;
  padding: 10px 14px;
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 10px;
  color: #FFF;
  font-size: 13.5px;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.plat-input:focus, .plat-select:focus {
  border-color: var(--plat-primary);
  box-shadow: 0 0 0 3px rgba(56,189,248,0.2);
}
.plat-select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%2394A3B8' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 36px;
}

/* ── Badges ───────────────────────────────────────────────── */
.plat-badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 10px; border-radius: 8px; font-size: 11.5px; font-weight: 700;
}
.plat-badge.active {
  background: rgba(16,185,129,0.15); color: #34D399;
  border: 1px solid rgba(16,185,129,0.3);
}
.plat-badge.suspended, .plat-badge.inactive {
  background: rgba(239,68,68,0.15); color: #F87171;
  border: 1px solid rgba(239,68,68,0.3);
}
.plat-badge.trial {
  background: rgba(245,158,11,0.15); color: #FBBF24;
  border: 1px solid rgba(245,158,11,0.3);
}

/* ── Tables ───────────────────────────────────────────────── */
.plat-table {
  width: 100%; border-collapse: collapse; text-align: left;
}
.plat-table th {
  padding: 12px 18px; font-size: 11.5px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.05em;
  color: var(--plat-text-muted);
  border-bottom: var(--plat-border);
  background: rgba(15, 23, 42, 0.4);
}
.plat-table td {
  padding: 16px 18px; border-bottom: 1px solid rgba(255,255,255,0.04);
  font-size: 13.5px; vertical-align: middle;
}
.plat-table tr:hover td {
  background: rgba(255,255,255,0.02);
}

/* ── Alerts ───────────────────────────────────────────────── */
.plat-alert {
  padding: 14px 18px; border-radius: 12px; margin-bottom: 20px;
  display: flex; align-items: center; gap: 10px; font-size: 13.5px; font-weight: 500;
}
.plat-alert.success {
  background: rgba(16,185,129,0.15); border: 1px solid rgba(16,185,129,0.3); color: #34D399;
}
.plat-alert.error {
  background: rgba(239,68,68,0.15); border: 1px solid rgba(239,68,68,0.3); color: #F87171;
}

/* ── Modal Dialog ─────────────────────────────────────────── */
.plat-modal-backdrop {
  position: fixed; inset: 0; background: rgba(0,0,0,0.8);
  backdrop-filter: blur(12px); z-index: 2000;
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
}
.plat-modal {
  background: rgba(15, 23, 42, 0.98);
  border: 1px solid rgba(99,102,241,0.3);
  border-radius: 20px;
  width: 100%; max-width: 820px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 25px 60px rgba(0,0,0,0.8);
  color: #FFF;
}
.plat-modal-head {
  padding: 20px 24px; border-bottom: var(--plat-border);
  display: flex; align-items: center; justify-content: space-between;
}
.plat-modal-body { padding: 24px; }
.plat-modal-foot {
  padding: 16px 24px; border-top: var(--plat-border);
  display: flex; align-items: center; justify-content: flex-end; gap: 12px;
}

/* ── Responsive ───────────────────────────────────────────── */
@media (max-width: 991.98px) {
  .plat-sidebar { transform: translateX(-100%); }
  .plat-sidebar.sidebar-open { transform: translateX(0); }
  .plat-topbar { margin-left: 0; }
  .plat-page { margin-left: 0 !important; padding: 20px 16px !important; }
}

/* ── Platform Login & Setup Screens ────────────────────────── */
.plat-login-wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 30px 16px;
  background: radial-gradient(circle at top right, rgba(99, 102, 241, 0.25) 0%, transparent 50%),
              radial-gradient(circle at bottom left, rgba(6, 182, 212, 0.2) 0%, transparent 50%),
              #020617;
}
.plat-login-card {
  width: 100%;
  max-width: 480px;
  background: rgba(15, 23, 42, 0.94);
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 20px;
  padding: 36px 32px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.7), 0 0 35px rgba(99, 102, 241, 0.15);
  backdrop-filter: blur(20px);
  color: #F8FAFC;
}
.plat-login-logo {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 24px;
}
.plat-login-logo__dot {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: linear-gradient(135deg, #0284C7, #6366F1);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(2, 132, 199, 0.4);
  flex-shrink: 0;
}
.plat-login-logo__dot svg {
  width: 24px;
  height: 24px;
}
.plat-login-logo__text {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #FFF, #93C5FD);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.plat-login-logo__sub {
  font-size: 0.78rem;
  color: #94A3B8;
  font-weight: 500;
}
.plat-login-title {
  font-size: 1.35rem;
  font-weight: 700;
  color: #FFFFFF;
  margin-bottom: 6px;
}
.plat-login-sub {
  font-size: 0.86rem;
  color: #94A3B8;
  margin-bottom: 24px;
  line-height: 1.45;
}
.plat-form-group {
  margin-bottom: 16px;
}
.plat-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: #CBD5E1;
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.plat-input {
  width: 100%;
  height: 44px;
  padding: 0 14px;
  background: rgba(2, 6, 23, 0.8);
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 10px;
  color: #FFFFFF;
  font-size: 0.92rem;
  transition: all 0.2s ease;
  outline: none;
}
.plat-input:focus {
  border-color: #38BDF8;
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.2);
  background: rgba(2, 6, 23, 0.95);
}
.plat-alert {
  padding: 12px 16px;
  border-radius: 10px;
  font-size: 0.88rem;
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
}
.plat-alert.error {
  background: rgba(239, 68, 68, 0.18);
  border: 1px solid rgba(239, 68, 68, 0.4);
  color: #FCA5A5;
}
.plat-alert.success {
  background: rgba(16, 185, 129, 0.18);
  border: 1px solid rgba(16, 185, 129, 0.4);
  color: #86EFAC;
}

