/* =========================================================================
   Ocurus Studio — back-office design system (Direction A, 2026-09)
   Dark "studio" chrome for creator pages, light variant (body.os-light) for
   superadmin. Tokens mirror docs/design/admin-2026/Components.dc.html.
   Loads AFTER Bootstrap 3 + Metronic components.css (kept for the legacy
   modals/plugins) and overrides page chrome; modals stay light on purpose.
   ========================================================================= */

:root {
  --os-bg: #0A0E17;
  --os-rail: #0D1220;
  --os-card: #111827;
  --os-card-2: #121A2B;
  --os-line: rgba(255, 255, 255, 0.06);
  --os-line-2: rgba(255, 255, 255, 0.10);
  --os-line-3: rgba(255, 255, 255, 0.14);
  --os-ink: #E6EAF2;
  --os-ink-strong: #FFFFFF;
  --os-dim: #C5CBD8;
  --os-muted: #8A93A6;
  --os-faint: #5B6478;
  --os-accent: #3B6BFF;
  --os-accent-hover: #2F5BE0;
  --os-accent-soft: rgba(59, 107, 255, 0.14);
  --os-accent-ink: #9DB4FF;
  --os-ember: #FF9E52;
  --os-ember-soft: rgba(255, 158, 82, 0.16);
  --os-ok: #4ADE80;
  --os-ok-soft: rgba(74, 222, 128, 0.14);
  --os-danger: #F87171;
  --os-danger-soft: rgba(248, 113, 113, 0.16);
  --os-warn: #FBBF24;
  --os-warn-soft: rgba(251, 191, 36, 0.16);
  --os-input: #111827;
  --os-hover: rgba(255, 255, 255, 0.04);
  --os-shadow: 0 24px 60px rgba(0, 0, 0, 0.5);
  --os-font: Sora, "Segoe UI", Helvetica, Arial, sans-serif;
  --os-mono: "JetBrains Mono", Menlo, Consolas, monospace;
  --os-radius: 14px;
  --os-radius-sm: 10px;
  --os-radius-xs: 6px;
  --os-control: 40px;
}

body.os-light {
  --os-bg: #F4F6FB;
  --os-rail: #EEF1F7;       /* "sunken" surfaces: thumbnails, wells, code — the aside keeps its own dark colours */
  --os-card: #FFFFFF;
  --os-card-2: #F4F7FF;
  --os-line: #E3E7F0;
  --os-line-2: #E3E7F0;
  --os-line-3: #C7CDDA;
  --os-ink: #0A0E17;
  --os-ink-strong: #0A0E17;
  --os-dim: #3A4152;
  --os-muted: #6B7386;
  --os-faint: #9AA3B5;
  --os-accent-soft: #E8EEFF;
  --os-accent-ink: #1E3A8A;
  --os-ember-soft: #FFF1E6;
  --os-ok: #15803D;
  --os-ok-soft: #DCFCE7;
  --os-danger: #B91C1C;
  --os-danger-soft: #FEE2E2;
  --os-warn: #B45309;
  --os-warn-soft: #FEF3C7;
  --os-input: #FFFFFF;
  --os-hover: #F4F7FF;
  --os-shadow: 0 16px 40px rgba(10, 14, 23, 0.12);
  --os-control: 36px;
}

/* ---------- base ---------- */
html, body.os-body { height: 100%; }
body.os-body {
  margin: 0;
  background: var(--os-bg);
  color: var(--os-ink);
  font-family: var(--os-font);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
/* :where() keeps the specificity at (0,0,1) so any .os-* class (buttons, tabs, tools) wins over the link colour */
:where(body.os-body) a { color: var(--os-accent-ink); text-decoration: none; }
:where(body.os-body) a:hover { color: var(--os-ink-strong); text-decoration: none; }
body.os-body h1, body.os-body h2, body.os-body h3, body.os-body h4 { font-family: var(--os-font); color: var(--os-ink-strong); margin: 0; }
.os-mono { font-family: var(--os-mono); font-variant-numeric: tabular-nums; }
.os-muted { color: var(--os-muted); }
.os-dim { color: var(--os-dim); }
.os-strong { color: var(--os-ink-strong); font-weight: 600; }
.os-hidden { display: none !important; }

/* ---------- app frame ---------- */
.os-app { display: flex; min-height: 100vh; background: var(--os-bg); }
.os-rail {
  position: sticky; top: 0; align-self: flex-start;
  width: 240px; flex: none; height: 100vh;
  display: flex; flex-direction: column;
  background: #0D1220; border-right: 1px solid rgba(255, 255, 255, 0.06);
  padding: 20px 16px 16px; color: #8A93A6;
  /* the admin nav is taller than a laptop screen: the rail scrolls on its own, thin bar */
  overflow-y: auto; overflow-x: hidden; scrollbar-width: thin; scrollbar-color: rgba(255, 255, 255, 0.16) transparent;
}
.os-rail__brand { display: flex; align-items: center; justify-content: space-between; padding: 4px 8px 22px; }
.os-rail__brand img { height: 22px; width: auto; display: block; }
.os-rail__tag { font-family: var(--os-mono); font-size: 10px; letter-spacing: 0.08em; padding: 3px 7px; border-radius: 5px; background: rgba(255, 158, 82, 0.18); color: #FF9E52; }
.os-nav { display: flex; flex-direction: column; gap: 4px; }
.os-nav__label { font-size: 11px; font-weight: 700; letter-spacing: 0.08em; color: #5B6478; padding: 14px 12px 6px; }
.os-nav a {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px; border-radius: 10px;
  color: #8A93A6; font-size: 14px; font-weight: 500; line-height: 1.2;
  transition: background 0.12s, color 0.12s;
}
.os-nav a:hover { background: rgba(255, 255, 255, 0.04); color: #FFFFFF; }
.os-nav a.is-active { background: rgba(59, 107, 255, 0.14); color: #FFFFFF; font-weight: 600; }
.os-nav a.is-active .os-i { color: #3B6BFF; }
.os-nav a .os-count { margin-left: auto; font-family: var(--os-mono); font-size: 10px; font-weight: 600; padding: 2px 6px; border-radius: 5px; background: #FF9E52; color: #0A0E17; }
.os-nav a .os-count--danger { background: #F87171; }
.os-i { width: 18px; height: 18px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.os-i--16 { width: 16px; height: 16px; }
.os-rail__spacer { flex-grow: 1; min-height: 16px; }
.os-rail::-webkit-scrollbar { width: 6px; }
.os-rail::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.16); border-radius: 3px; }
.os-rail::-webkit-scrollbar-track { background: transparent; }
.os-rail > * { flex-shrink: 0; }
.os-rail .os-rail__brand { position: sticky; top: -20px; margin-top: -20px; padding-top: 24px; background: #0D1220; z-index: 1; }
.os-plan { display: flex; flex-direction: column; gap: 10px; padding: 14px; border-radius: 12px; background: #121A2B; border: 1px solid rgba(255, 255, 255, 0.06); }
.os-plan__row { display: flex; justify-content: space-between; align-items: baseline; font-size: 12px; color: #8A93A6; }
.os-plan__row .os-mono { font-size: 11px; }
.os-plan__row .os-strong { color: #E6EAF2; font-size: 12px; }
.os-bar { height: 4px; border-radius: 2px; background: rgba(255, 255, 255, 0.08); overflow: hidden; }
.os-bar > span { display: block; height: 100%; background: var(--os-accent); }
.os-bar--ember > span { background: var(--os-ember); }
.os-bar--thick { height: 6px; border-radius: 3px; }
.os-rail__switch { display: flex; align-items: center; justify-content: space-between; padding: 12px 8px 0; font-size: 12px; color: #8A93A6; }
.os-rail__back { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; border: 1px solid rgba(255, 255, 255, 0.08); color: #C5CBD8; font-size: 13px; }
.os-rail__back:hover { color: #FFFFFF; border-color: rgba(255, 255, 255, 0.2); }

.os-main { flex-grow: 1; display: flex; flex-direction: column; min-width: 0; }
.os-topbar {
  display: flex; align-items: center; gap: 14px;
  min-height: 76px; padding: 14px 32px;
  border-bottom: 1px solid var(--os-line);
  background: var(--os-bg);
}
body.os-light .os-topbar { background: var(--os-card); min-height: 68px; }
.os-topbar__title { font-size: 20px; font-weight: 600; color: var(--os-ink-strong); letter-spacing: -0.01em; }
.os-topbar__sub { font-size: 13px; color: var(--os-muted); }
.os-topbar__spacer { flex-grow: 1; }
.os-crumb { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--os-muted); }
.os-crumb .os-i { width: 14px; height: 14px; }

.os-search {
  display: flex; align-items: center; gap: 10px;
  height: var(--os-control); padding: 0 14px; width: 420px; max-width: 100%;
  border-radius: var(--os-radius-sm); background: var(--os-input); border: 1px solid var(--os-line-2);
  color: var(--os-muted); font-size: 14px;
}
.os-search input { flex-grow: 1; min-width: 0; background: transparent; border: 0; outline: 0; color: var(--os-ink-strong); font: inherit; }
.os-search input::placeholder { color: var(--os-muted); }
.os-search:focus-within { border-color: var(--os-accent); box-shadow: 0 0 0 3px var(--os-accent-soft); }
.os-search--sm { width: 260px; height: 36px; font-size: 13px; }
.os-kbd { font-family: var(--os-mono); font-size: 11px; padding: 1px 6px; border-radius: 4px; border: 1px solid var(--os-line-3); color: var(--os-muted); }

.os-iconbtn {
  position: relative; display: inline-flex; align-items: center; justify-content: center;
  width: var(--os-control); height: var(--os-control); border-radius: var(--os-radius-sm);
  color: var(--os-muted); border: 1px solid transparent; background: transparent; cursor: pointer;
}
.os-iconbtn:hover { color: var(--os-ink-strong); background: var(--os-hover); }
body.os-light .os-iconbtn { border-color: var(--os-line); color: var(--os-dim); }
.os-iconbtn .os-count {
  position: absolute; top: 2px; right: 0; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px;
  background: #FF9E52; color: #0A0E17; font-family: var(--os-mono); font-size: 11px; font-weight: 500;
  display: none; align-items: center; justify-content: center;
}
.os-iconbtn .os-count.is-on { display: inline-flex; }
.os-user { display: flex; align-items: center; gap: 10px; padding: 4px 6px 4px 4px; border-radius: 22px; border: 1px solid var(--os-line-2); cursor: pointer; }
.os-user img, .os-user .os-avatar { width: 30px; height: 30px; border-radius: 15px; object-fit: cover; background: linear-gradient(135deg, #3B6BFF, #1E3A8A); }
.os-user span { font-size: 13px; font-weight: 500; color: var(--os-ink-strong); padding-right: 6px; }

.os-content { display: flex; flex-direction: column; gap: 24px; padding: 28px 32px 40px; }
body.os-light .os-content { gap: 18px; padding: 22px 32px 40px; }
.os-page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.os-eyebrow { font-family: var(--os-mono); font-size: 12px; color: var(--os-muted); letter-spacing: 0.04em; text-transform: uppercase; }
.os-h1 { font-size: 30px; font-weight: 600; letter-spacing: -0.02em; color: var(--os-ink-strong); }
.os-h2 { font-size: 18px; font-weight: 600; color: var(--os-ink-strong); }
.os-h3 { font-size: 15px; font-weight: 600; color: var(--os-ink-strong); }

/* ---------- grids ---------- */
.os-grid { display: grid; gap: 20px; }
.os-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.os-grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.os-grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.os-grid--side { grid-template-columns: minmax(0, 1fr) 380px; }
@media (max-width: 1280px) { .os-grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .os-grid--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .os-grid--side { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 767px) { .os-grid--2, .os-grid--3, .os-grid--4 { grid-template-columns: minmax(0, 1fr); } .os-content { padding: 20px 16px 32px; } .os-topbar { padding: 12px 16px; } .os-search { width: 100%; } }

/* ---------- cards & tiles ---------- */
.os-card { background: var(--os-card); border: 1px solid var(--os-line); border-radius: var(--os-radius); }
.os-card__head { display: flex; align-items: center; gap: 12px; padding: 16px 20px; border-bottom: 1px solid var(--os-line); }
.os-card__body { padding: 18px 20px; }
.os-tile { display: flex; flex-direction: column; gap: 4px; padding: 14px 16px; border-radius: 12px; background: var(--os-card); border: 1px solid var(--os-line); }
.os-tile__label { font-size: 12px; color: var(--os-muted); }
.os-tile__value { font-family: var(--os-mono); font-size: 22px; font-weight: 500; color: var(--os-ink-strong); line-height: 1.2; }
.os-tile__value--lg { font-size: 28px; }
.os-tile__delta { font-family: var(--os-mono); font-size: 12px; color: var(--os-muted); }
.os-tile__delta.is-up { color: var(--os-ok); }
.os-tile__delta.is-down { color: var(--os-danger); }

/* ---------- buttons ---------- */
.os-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: var(--os-control); padding: 0 16px; border-radius: var(--os-radius-sm);
  border: 1px solid transparent; background: var(--os-card); color: var(--os-ink);
  font-family: var(--os-font); font-size: 14px; font-weight: 600; line-height: 1; white-space: nowrap;
  cursor: pointer; text-decoration: none; transition: background 0.12s, border-color 0.12s, color 0.12s;
}
.os-btn:hover, .os-btn:focus { text-decoration: none; color: var(--os-ink-strong); }
.os-btn--primary { background: var(--os-accent); color: #FFFFFF; }
.os-btn--primary:hover, .os-btn--primary:focus { background: var(--os-accent-hover); color: #FFFFFF; }
.os-btn--inverse { background: var(--os-ink-strong); color: var(--os-bg); }
body.os-light .os-btn--inverse { background: #0A0E17; color: #FFFFFF; }
.os-btn--secondary { background: transparent; border-color: var(--os-line-3); color: var(--os-dim); }
.os-btn--secondary:hover { border-color: var(--os-muted); color: var(--os-ink-strong); background: var(--os-hover); }
body.os-light .os-btn--secondary { background: var(--os-card); border-color: var(--os-line); }
.os-btn--soft { background: var(--os-accent-soft); color: var(--os-accent-ink); }
.os-btn--soft:hover { color: var(--os-ink-strong); }
body.os-light .os-btn--soft:hover { color: var(--os-accent-ink); }
.os-btn--attention { background: var(--os-ember); color: #0A0E17; }
.os-btn--attention:hover { color: #0A0E17; filter: brightness(1.05); }
.os-btn--danger { background: transparent; border-color: rgba(248, 113, 113, 0.5); color: var(--os-danger); }
.os-btn--danger:hover { background: var(--os-danger-soft); color: var(--os-danger); }
.os-btn--sm { height: 32px; padding: 0 12px; font-size: 12px; border-radius: 8px; }
.os-btn--xs { height: 28px; padding: 0 10px; font-size: 12px; border-radius: 8px; }
.os-btn--block { width: 100%; }
.os-btn[disabled], .os-btn.is-disabled { background: rgba(255, 255, 255, 0.06); color: var(--os-faint); border-color: transparent; cursor: not-allowed; }
.os-btn .os-i { width: 16px; height: 16px; }

/* ---------- chips, badges ---------- */
.os-chips { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.os-chip {
  display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border-radius: 999px;
  border: 1px solid var(--os-line-3); color: var(--os-dim); font-size: 13px; cursor: pointer; background: transparent;
}
.os-chip:hover { color: var(--os-ink-strong); border-color: var(--os-muted); }
.os-chip.is-active { background: var(--os-ink-strong); color: var(--os-bg); border-color: var(--os-ink-strong); font-weight: 600; }
body.os-light .os-chip.is-active { background: #0A0E17; color: #FFFFFF; border-color: #0A0E17; }
.os-badge {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 8px; border-radius: var(--os-radius-xs);
  font-family: var(--os-mono); font-size: 11px; letter-spacing: 0.04em; text-transform: uppercase; white-space: nowrap;
}
.os-badge::before { content: ""; width: 6px; height: 6px; border-radius: 3px; background: currentColor; }
.os-badge--ok { background: var(--os-ok-soft); color: var(--os-ok); }
.os-badge--draft, .os-badge--warn { background: var(--os-ember-soft); color: var(--os-ember); }
body.os-light .os-badge--draft, body.os-light .os-badge--warn { color: var(--os-warn); background: var(--os-warn-soft); }
.os-badge--danger { background: var(--os-danger-soft); color: var(--os-danger); }
.os-badge--muted { background: rgba(255, 255, 255, 0.08); color: var(--os-dim); }
body.os-light .os-badge--muted { background: #EEF1F7; color: var(--os-muted); }
.os-badge--plain::before { display: none; }
.os-pill { display: inline-flex; align-items: center; padding: 3px 8px; border-radius: 999px; font-size: 11px; font-weight: 600; white-space: nowrap; }
.os-pill--ok { background: var(--os-ok-soft); color: var(--os-ok); }
.os-pill--warn { background: var(--os-warn-soft); color: var(--os-warn); }
.os-pill--danger { background: var(--os-danger-soft); color: var(--os-danger); }
.os-pill--muted { background: rgba(255, 255, 255, 0.08); color: var(--os-muted); }
body.os-light .os-pill--muted { background: #EEF1F7; }
.os-pill--accent { background: var(--os-accent-soft); color: var(--os-accent-ink); }
.os-dot { display: inline-block; width: 7px; height: 7px; border-radius: 4px; background: var(--os-muted); }
.os-dot--ok { background: var(--os-ok); } .os-dot--warn { background: var(--os-warn); } .os-dot--danger { background: var(--os-danger); } .os-dot--accent { background: var(--os-accent); }

/* ---------- inputs (studio pages, outside Metronic modals) ---------- */
.os-field { display: flex; flex-direction: column; gap: 6px; }
.os-label { font-size: 12px; font-weight: 600; color: var(--os-dim); }
.os-input, .os-select {
  height: var(--os-control); padding: 0 12px; border-radius: var(--os-radius-sm);
  background: var(--os-input); border: 1px solid var(--os-line-2); color: var(--os-ink-strong);
  font-family: var(--os-font); font-size: 13px; outline: 0; width: 100%;
}
.os-input::placeholder { color: var(--os-muted); }
.os-input:focus, .os-select:focus { border-color: var(--os-accent); box-shadow: 0 0 0 3px var(--os-accent-soft); }
.os-input.is-invalid { border-color: var(--os-danger); }
.os-help { font-size: 11px; color: var(--os-muted); }
.os-help--error { color: var(--os-danger); }
.os-select { appearance: none; -webkit-appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%238A93A6' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 34px; }
.os-select option { background: var(--os-card); color: var(--os-ink); }
.os-check { display: inline-flex; align-items: center; gap: 10px; font-size: 13px; color: var(--os-dim); cursor: pointer; }
.os-check input { position: absolute; opacity: 0; width: 0; height: 0; }
.os-check__box { width: 18px; height: 18px; border-radius: 5px; border: 1px solid var(--os-line-3); display: inline-flex; align-items: center; justify-content: center; flex: none; }
.os-check input:checked + .os-check__box { background: var(--os-accent); border-color: var(--os-accent); }
.os-check__box svg { width: 12px; height: 12px; stroke: #FFFFFF; stroke-width: 3; fill: none; stroke-linecap: round; stroke-linejoin: round; display: none; }
.os-check input:checked + .os-check__box svg { display: block; }
.os-switch { position: relative; display: inline-block; width: 38px; height: 22px; border-radius: 11px; background: rgba(255, 255, 255, 0.14); cursor: pointer; flex: none; transition: background 0.15s; }
.os-switch::after { content: ""; position: absolute; top: 2px; left: 2px; width: 18px; height: 18px; border-radius: 9px; background: #8A93A6; transition: left 0.15s, background 0.15s; }
.os-switch.is-on { background: var(--os-accent); }
.os-switch.is-on::after { left: 18px; background: #FFFFFF; }
body.os-light .os-switch { background: #D6DBE7; } body.os-light .os-switch::after { background: #FFFFFF; }

/* ---------- tables ---------- */
.os-table { width: 100%; border-collapse: collapse; }
.os-table th { padding: 10px 18px; font-size: 11px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--os-muted); text-align: left; border-bottom: 1px solid var(--os-line); white-space: nowrap; }
.os-table td { padding: 12px 18px; font-size: 13px; color: var(--os-ink); border-bottom: 1px solid var(--os-line); vertical-align: middle; }
.os-table tr:last-child td { border-bottom: 0; }
.os-table tbody tr:hover td { background: var(--os-hover); }
.os-table .os-num { text-align: right; font-family: var(--os-mono); font-variant-numeric: tabular-nums; }
.os-table .os-cell-sub { display: block; font-family: var(--os-mono); font-size: 11px; color: var(--os-muted); }

/* ---------- tour card (dashboard) ---------- */
.os-tours { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
@media (max-width: 1400px) { .os-tours { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 767px) { .os-tours { grid-template-columns: minmax(0, 1fr); } }
.os-tour { display: flex; flex-direction: column; border-radius: var(--os-radius); background: var(--os-card); border: 1px solid var(--os-line); overflow: hidden; transition: border-color 0.15s, transform 0.15s; }
.os-tour:hover { border-color: var(--os-line-3); }
.os-tour--new { border-style: dashed; border-color: var(--os-line-3); cursor: pointer; }
.os-tour--new:hover { border-color: var(--os-accent); }
.os-tour__cover { position: relative; height: 176px; background: #0D1220 center / cover no-repeat; }
.os-tour__cover--empty { display: flex; align-items: center; justify-content: center; background: linear-gradient(160deg, #1E3A8A 0%, #0B1B3F 60%, #3B6BFF 140%); }
.os-tour__badge { position: absolute; top: 12px; left: 12px; }
.os-tour__meta { position: absolute; bottom: 12px; right: 12px; padding: 4px 8px; border-radius: var(--os-radius-xs); background: rgba(10, 14, 23, 0.7); color: #E6EAF2; font-family: var(--os-mono); font-size: 11px; }
.os-tour__tools { position: absolute; top: 10px; right: 10px; display: flex; flex-direction: column; gap: 6px; opacity: 0; transform: translateX(6px); transition: opacity 0.15s, transform 0.15s; }
.os-tour:hover .os-tour__tools, .os-tour:focus-within .os-tour__tools { opacity: 1; transform: none; }
.os-tour__tools a {
  width: 34px; height: 34px; border-radius: 9px; display: inline-flex; align-items: center; justify-content: center;
  background: rgba(10, 14, 23, 0.82); color: #E6EAF2; border: 1px solid rgba(255, 255, 255, 0.12);
}
.os-tour__tools a:hover { background: #FFFFFF; color: #0A0E17; }
.os-tour__tools a.is-danger:hover { background: var(--os-danger); color: #0A0E17; }
.os-tour__tools a i { font-size: 14px; }
.os-tour__body { display: flex; flex-direction: column; gap: 10px; padding: 16px; }
.os-tour__title { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.os-tour__title h3 { font-size: 15px; font-weight: 600; color: var(--os-ink-strong); line-height: 1.3; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.os-tour__views { font-family: var(--os-mono); font-size: 13px; color: var(--os-dim); white-space: nowrap; }
.os-tour__desc { font-size: 12px; color: var(--os-muted); line-height: 1.5; max-height: 36px; overflow: hidden; }
.os-tour__desc p { margin: 0; }
.os-tour__actions { display: flex; gap: 8px; flex-wrap: wrap; }
.os-tour__actions .os-btn { height: 32px; padding: 0 10px; font-size: 12px; border-radius: 8px; }
.os-tour__new-inner { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 40px 24px; text-align: center; height: 100%; min-height: 300px; color: var(--os-muted); }
.os-tour__new-inner h3 { font-size: 16px; color: var(--os-ink-strong); }

/* ---------- misc ---------- */
.os-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 64px 24px; text-align: center; color: var(--os-muted); border: 1px dashed var(--os-line-3); border-radius: var(--os-radius); }
.os-empty h2 { font-size: 22px; color: var(--os-ink-strong); }
.os-note { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: var(--os-radius-sm); font-size: 12px; color: var(--os-dim); line-height: 1.5; }
.os-note--accent { background: var(--os-accent-soft); border: 1px solid rgba(59, 107, 255, 0.25); }
.os-note--ember { background: var(--os-ember-soft); border: 1px solid rgba(255, 158, 82, 0.3); }
.os-note--danger { background: var(--os-danger-soft); border: 1px solid rgba(248, 113, 113, 0.35); }
.os-divider { height: 1px; background: var(--os-line); }
.os-footer { padding: 24px 32px; font-size: 12px; color: var(--os-faint); }
.os-pagination { display: flex; justify-content: center; }
.os-pagination .pagination { margin: 0; }
.os-pagination .pagination > li > a, .os-pagination .pagination > li > span { background: var(--os-card); border-color: var(--os-line-2); color: var(--os-dim); font-family: var(--os-mono); font-size: 12px; }
.os-pagination .pagination > .active > a, .os-pagination .pagination > .active > span { background: var(--os-accent); border-color: var(--os-accent); color: #FFFFFF; }
.os-pagination .pagination > .disabled > a, .os-pagination .pagination > .disabled > span { background: var(--os-card); color: var(--os-faint); border-color: var(--os-line); }

/* dropdowns (Bootstrap 3 markup, studio skin) */
.os-dropdown { position: relative; }
.os-dropdown .dropdown-menu { background: var(--os-card); border: 1px solid var(--os-line-2); border-radius: 12px; box-shadow: var(--os-shadow); padding: 6px; min-width: 220px; margin-top: 8px; }
.os-dropdown .dropdown-menu > li > a { color: var(--os-dim); font-size: 13px; padding: 9px 12px; border-radius: 8px; display: flex; align-items: center; gap: 10px; }
.os-dropdown .dropdown-menu > li > a:hover, .os-dropdown .dropdown-menu > li > a:focus { background: var(--os-hover); color: var(--os-ink-strong); }
.os-dropdown .dropdown-menu > li > a i { width: 16px; text-align: center; color: var(--os-muted); }
.os-dropdown .dropdown-menu .divider { background: var(--os-line); margin: 6px 0; }
.os-dropdown .dropdown-menu .os-dropdown__head { padding: 8px 12px 6px; font-size: 11px; font-weight: 700; letter-spacing: 0.06em; color: var(--os-muted); text-transform: uppercase; }
.os-notifications { max-height: 320px; overflow-y: auto; min-width: 320px; }
/* main.js appends its own <span class="badge"> into .headerMessageCount; the studio badge mirrors it instead */
.os-body .headerMessageCount > .badge { display: none; }
.os-notifications li a { white-space: normal; }

/* ---------- Bootstrap 3 / Metronic / plugin popups themed for the studio ---------- */
/* Every popup the legacy scripts open (modals, wizard, select2, switches, sweetalert
   confirms, toastr notifications, blockUI spinner, shepherd guides) is re-skinned with the
   studio tokens here. The markup and the JS that drives them stay untouched. */

/* -- Bootstrap modal -- */
body.os-body .modal-content { background: var(--os-card); border: 1px solid var(--os-line-2); border-radius: 14px; box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6); color: var(--os-ink); font-family: var(--os-font); }
body.os-body .modal-header { padding: 16px 20px; border-bottom: 1px solid var(--os-line); border-radius: 14px 14px 0 0; }
body.os-body .modal-header .close, body.os-body .modal .close { filter: invert(1) brightness(1.6); opacity: 0.7; margin-top: 2px !important; }
body.os-body .modal-header .close:hover { opacity: 1; }
body.os-body .modal-content .modal-title { font-size: 16px; font-weight: 600; color: var(--os-ink-strong); }
body.os-body .modal-content h1, body.os-body .modal-content h2, body.os-body .modal-content h3, body.os-body .modal-content h4, body.os-body .modal-content h5 { color: var(--os-ink-strong); font-weight: 600; }
body.os-body .modal-content a { color: var(--os-accent-ink); }
body.os-body .modal-body { padding: 20px; }
body.os-body .modal-footer { padding: 14px 20px; border-top: 1px solid var(--os-line); }
body.os-body .modal-backdrop.in { opacity: 0.7; background: #04070E; }
body.os-body .modal-content hr { border-color: var(--os-line); }
body.os-body .modal-content .text-muted, body.os-body .modal-content .help-block, body.os-body .modal-content .form-control-static, body.os-body .modal-content small { color: var(--os-muted); }

/* -- form controls (modals + any legacy page on the studio layout) -- */
body.os-body .control-label, body.os-body label { color: var(--os-dim); font-weight: 600; font-size: 12px; }
body.os-body .form-control, body.os-body .select2-container--bootstrap .select2-selection, body.os-body .bootstrap-select > .btn, body.os-body .sweet-alert input {
  background: var(--os-input); border: 1px solid var(--os-line-2); color: var(--os-ink-strong); border-radius: 8px; box-shadow: none; font-family: var(--os-font); font-size: 13px;
}
body.os-body .form-control { height: 38px; padding: 6px 12px; }
body.os-body textarea.form-control, body.os-body select[multiple].form-control { height: auto; }
body.os-body .form-control:focus, body.os-body .sweet-alert input:focus, body.os-body .select2-container--bootstrap.select2-container--focus .select2-selection, body.os-body .select2-container--bootstrap.select2-container--open .select2-selection { border-color: var(--os-accent); box-shadow: 0 0 0 3px var(--os-accent-soft); outline: 0; }
body.os-body .form-control::placeholder, body.os-body .sweet-alert input::placeholder { color: var(--os-muted); }
body.os-body .form-control[readonly], body.os-body .form-control[disabled] { background: rgba(255, 255, 255, 0.03); color: var(--os-muted); }
body.os-body .form-control.input-sm { height: 32px; }
body.os-body .input-group-addon, body.os-body .input-group-btn > .btn { background: var(--os-rail); border-color: var(--os-line-2); color: var(--os-dim); border-radius: 8px; }
body.os-body .form-row-sepe .form-group, body.os-body .form-horizontal .form-group { border-color: var(--os-line); }
body.os-body .fileinput .form-control { color: var(--os-dim); }
/* Metronic checkbox / radio */
body.os-body .mt-checkbox, body.os-body .mt-radio { color: var(--os-dim); font-size: 13px; }
body.os-body .mt-checkbox > span, body.os-body .mt-radio > span { background: var(--os-input); border: 1px solid var(--os-line-3); }
body.os-body .mt-checkbox > input:checked ~ span, body.os-body .mt-radio > input:checked ~ span { background: var(--os-accent); border-color: var(--os-accent); }
body.os-body .mt-checkbox > span:after { border-color: #FFFFFF; }
body.os-body .mt-radio > span:after { background: #FFFFFF; }
/* bootstrap-switch */
body.os-body .bootstrap-switch { border-color: var(--os-line-2); background: var(--os-input); border-radius: 20px !important; overflow: hidden; }
body.os-body .bootstrap-switch .bootstrap-switch-handle-on, body.os-body .bootstrap-switch .bootstrap-switch-handle-off, body.os-body .bootstrap-switch .bootstrap-switch-label { border-radius: 16px; }
body.os-body .bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-primary, body.os-body .bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-success, body.os-body .bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-info, body.os-body .bootstrap-switch .bootstrap-switch-handle-off.bootstrap-switch-primary { background: var(--os-accent); color: #FFFFFF; }
body.os-body .bootstrap-switch .bootstrap-switch-handle-off.bootstrap-switch-default, body.os-body .bootstrap-switch .bootstrap-switch-handle-on.bootstrap-switch-default { background: rgba(255, 255, 255, 0.06); color: var(--os-dim); }
body.os-body .bootstrap-switch .bootstrap-switch-label { background: var(--os-card); color: var(--os-ink-strong); }
/* select2 (bootstrap theme) */
body.os-body .select2-container--bootstrap .select2-selection--single { height: 38px; }
body.os-body .select2-container--bootstrap .select2-selection--single .select2-selection__rendered { color: var(--os-ink-strong); line-height: 24px; }
body.os-body .select2-container--bootstrap .select2-selection--single .select2-selection__placeholder { color: var(--os-muted); }
body.os-body .select2-container--bootstrap .select2-selection--single .select2-selection__arrow b { border-color: var(--os-muted) transparent transparent; }
body.os-body .select2-container--bootstrap.select2-container--open .select2-selection--single .select2-selection__arrow b { border-color: transparent transparent var(--os-muted); }
body.os-body .select2-container--bootstrap .select2-dropdown { background: var(--os-card); border: 1px solid var(--os-line-2); border-radius: 10px; box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5); overflow: hidden; }
body.os-body .select2-container--bootstrap .select2-results__option { color: var(--os-ink); font-size: 13px; padding: 8px 12px; }
body.os-body .select2-container--bootstrap .select2-results__option[aria-selected="true"] { background: var(--os-hover); color: var(--os-ink-strong); }
body.os-body .select2-container--bootstrap .select2-results__option--highlighted[aria-selected] { background: var(--os-accent); color: #FFFFFF; }
body.os-body .select2-container--bootstrap .select2-search--dropdown .select2-search__field { background: var(--os-input); border: 1px solid var(--os-line-2); color: var(--os-ink-strong); border-radius: 8px; }
body.os-body .select2-container--bootstrap .select2-selection--multiple .select2-selection__choice { background: var(--os-accent-soft); border: 0; color: var(--os-ink-strong); border-radius: 6px; }
body.os-body .select2-container--bootstrap .select2-selection--multiple .select2-selection__choice__remove { color: var(--os-muted); }
body.os-body .select2-container--bootstrap .select2-results__group { color: var(--os-muted); }
/* bootstrap dropdown menus (bootstrap-select, header menus, tables) */
body.os-body .dropdown-menu { background: var(--os-card); border: 1px solid var(--os-line-2); border-radius: 10px; box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5); padding: 6px; }
body.os-body .dropdown-menu > li > a { color: var(--os-dim); font-size: 13px; border-radius: 8px; }
body.os-body .dropdown-menu > li > a:hover, body.os-body .dropdown-menu > li > a:focus, body.os-body .dropdown-menu > .active > a { background: var(--os-hover); color: var(--os-ink-strong); }
body.os-body .dropdown-menu > .selected > a, body.os-body .bootstrap-select .dropdown-menu > .selected > a { background: var(--os-accent); color: #FFFFFF; }
body.os-body .dropdown-menu .divider { background: var(--os-line); }
/* colour picker / date picker */
body.os-body .minicolors-panel { background: var(--os-card); border-color: var(--os-line-2); border-radius: 10px; }
body.os-body .datepicker, body.os-body .datetimepicker { background: var(--os-card); color: var(--os-ink); border: 1px solid var(--os-line-2); border-radius: 10px; }
body.os-body .datepicker table tr td, body.os-body .datepicker table tr th { color: var(--os-ink); border-radius: 6px; }
body.os-body .datepicker table tr td.day:hover, body.os-body .datepicker table tr th:hover { background: var(--os-hover); }
body.os-body .datepicker table tr td.active, body.os-body .datepicker table tr td.active:hover { background: var(--os-accent); color: #FFFFFF; }
body.os-body .datepicker table tr td.old, body.os-body .datepicker table tr td.new { color: var(--os-faint); }
/* tabs & wizard inside modals */
body.os-body .nav-tabs { border-bottom-color: var(--os-line); }
body.os-body .nav-tabs > li > a { color: var(--os-dim); border-radius: 8px 8px 0 0; }
body.os-body .nav-tabs > li > a:hover { background: var(--os-hover); border-color: transparent; color: var(--os-ink-strong); }
body.os-body .nav-tabs > li.active > a, body.os-body .nav-tabs > li.active > a:hover, body.os-body .nav-tabs > li.active > a:focus { background: transparent; color: var(--os-ink-strong); border-color: var(--os-line) var(--os-line) transparent; }
body.os-body .tabbable-line > .nav-tabs > li.active { border-bottom-color: var(--os-accent); }
body.os-body .tabbable-line > .nav-tabs > li:hover { border-bottom-color: var(--os-line-3); }
body.os-body .form-wizard .steps { background: transparent; }
body.os-body .form-wizard .steps > li > a.step { background: var(--os-rail); border-radius: 10px; }
body.os-body .form-wizard .steps > li > a.step > .number { background: rgba(255, 255, 255, 0.08); color: var(--os-dim); }
body.os-body .form-wizard .steps > li > a.step > .desc { color: var(--os-dim); }
body.os-body .form-wizard .steps > li.active > a.step > .number { background: var(--os-accent); color: #FFFFFF; }
body.os-body .form-wizard .steps > li.done > a.step > .number { background: var(--os-ok); color: #0A0E17; }
body.os-body .form-wizard .progress { background: rgba(255, 255, 255, 0.08); }
body.os-body .progress { background: rgba(255, 255, 255, 0.08); box-shadow: none; border-radius: 4px; }
body.os-body .progress .progress-bar { background: var(--os-accent); }
/* buttons (Metronic colour classes) */
body.os-body .btn { border-radius: 10px; font-family: var(--os-font); font-weight: 600; font-size: 13px; padding: 8px 14px; box-shadow: none !important; text-shadow: none; transition: background 0.15s, color 0.15s, border-color 0.15s; }
body.os-body .btn.btn-sm { padding: 6px 12px; font-size: 12px; border-radius: 8px; }
body.os-body .btn.btn-xs { padding: 4px 9px; font-size: 11px; border-radius: 7px; }
body.os-body .btn.btn-lg { padding: 11px 18px; font-size: 14px; }
body.os-body .btn.blue-madison, body.os-body .btn.blue, body.os-body .btn.btn-primary, body.os-body .btn.green, body.os-body .btn.green-meadow, body.os-body .btn.blue-hoki, body.os-body .btn.blue-steel, body.os-body .btn.btn-info, body.os-body .btn.btn-success, body.os-body .btn.purple-medium, body.os-body .btn.purple { background: var(--os-accent); color: #FFFFFF; border: 1px solid transparent; }
body.os-body .btn.blue-madison:hover, body.os-body .btn.blue:hover, body.os-body .btn.btn-primary:hover, body.os-body .btn.green:hover, body.os-body .btn.purple-medium:hover, body.os-body .btn.btn-success:hover, body.os-body .btn.btn-info:hover { background: #5B85FF; color: #FFFFFF; }
body.os-body .btn.btn-default, body.os-body .btn.default, body.os-body .btn.grey, body.os-body .btn.grey-salsa, body.os-body .btn.grey-cascade, body.os-body .btn.btn-outline, body.os-body .btn.blue.btn-outline, body.os-body .btn.blue-madison.btn-outline, body.os-body .btn.red.btn-outline, body.os-body .btn.red-mint.btn-outline, body.os-body .btn.green.btn-outline, body.os-body .btn.dark.btn-outline { background: transparent; border: 1px solid var(--os-line-3); color: var(--os-dim); }
body.os-body .btn.btn-default:hover, body.os-body .btn.default:hover, body.os-body .btn.btn-outline:hover, body.os-body .btn.blue.btn-outline:hover, body.os-body .btn.blue-madison.btn-outline:hover, body.os-body .btn.grey:hover, body.os-body .btn.grey-salsa:hover { background: rgba(255, 255, 255, 0.06); color: var(--os-ink-strong); border-color: var(--os-line-3); }
body.os-body .btn.red, body.os-body .btn.red-mint, body.os-body .btn.btn-danger, body.os-body .btn.red-intense, body.os-body .btn.red-thunderbird { background: var(--os-danger); color: #0A0E17; border: 1px solid transparent; }
body.os-body .btn.red:hover, body.os-body .btn.red-mint:hover, body.os-body .btn.btn-danger:hover { background: #FF8A8A; color: #0A0E17; }
body.os-body .btn.red.btn-outline:hover, body.os-body .btn.red-mint.btn-outline:hover { background: var(--os-danger-soft); color: var(--os-danger); border-color: rgba(248, 113, 113, 0.5); }
body.os-body .btn.yellow, body.os-body .btn.btn-warning, body.os-body .btn.yellow-crusta, body.os-body .btn.yellow-gold { background: var(--os-ember); color: #0A0E17; border: 1px solid transparent; }
body.os-body .btn.yellow:hover, body.os-body .btn.btn-warning:hover { filter: brightness(1.05); color: #0A0E17; }
body.os-body .btn.dark, body.os-body .btn.btn-dark, body.os-body .btn.white { background: var(--os-ink-strong); color: var(--os-bg); border: 1px solid transparent; }
body.os-body .btn[disabled], body.os-body .btn.disabled { opacity: 0.5; }
/* notes / alerts / labels */
body.os-body .note { background: rgba(255, 255, 255, 0.04); border-left: 3px solid var(--os-line-3); color: var(--os-dim); border-radius: 8px; font-size: 12px; line-height: 1.5; }
body.os-body .note h4, body.os-body .note .block { color: var(--os-ink-strong); }
body.os-body .note.note-info { background: var(--os-accent-soft); border-left-color: var(--os-accent); }
body.os-body .note.note-warning { background: var(--os-ember-soft); border-left-color: var(--os-ember); }
body.os-body .note.note-danger { background: var(--os-danger-soft); border-left-color: var(--os-danger); }
body.os-body .note.note-success { background: var(--os-ok-soft); border-left-color: var(--os-ok); }
body.os-body .alert { border-radius: 10px; border: 1px solid transparent; font-size: 13px; }
body.os-body .alert-warning { background: var(--os-ember-soft); color: var(--os-ember); border-color: rgba(255, 158, 82, 0.3); }
body.os-body .alert-danger { background: var(--os-danger-soft); color: var(--os-danger); border-color: rgba(248, 113, 113, 0.35); }
body.os-body .alert-success { background: var(--os-ok-soft); color: var(--os-ok); border-color: rgba(74, 222, 128, 0.3); }
body.os-body .alert-info { background: var(--os-accent-soft); color: var(--os-accent-ink); border-color: rgba(59, 107, 255, 0.3); }
body.os-body .alert .close { filter: invert(1) brightness(1.6); }
body.os-body .label { font-family: var(--os-mono); font-weight: 500; border-radius: 6px; }
body.os-body .well { background: var(--os-rail); border: 1px solid var(--os-line); border-radius: 10px; color: var(--os-ink); box-shadow: none; }
body.os-body .panel { background: transparent; border: 0; box-shadow: none; }
body.os-body .panel-body { padding: 0; }

/* -- tooltips & popovers -- */
body.os-body .tooltip-inner { background: #0A0E17; color: #E6EAF2; font-family: var(--os-font); font-size: 12px; border-radius: 6px; padding: 6px 10px; }
body.os-body .tooltip.left .tooltip-arrow { border-left-color: #0A0E17; }
body.os-body .tooltip.top .tooltip-arrow { border-top-color: #0A0E17; }
body.os-body .tooltip.right .tooltip-arrow { border-right-color: #0A0E17; }
body.os-body .tooltip.bottom .tooltip-arrow { border-bottom-color: #0A0E17; }
body.os-body .popover { background: var(--os-card); border: 1px solid var(--os-line-2); border-radius: 12px; box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5); font-family: var(--os-font); }
body.os-body .popover-title { background: transparent; border-bottom: 1px solid var(--os-line); color: var(--os-ink-strong); font-weight: 600; border-radius: 12px 12px 0 0; }
body.os-body .popover-content { color: var(--os-dim); font-size: 13px; }
body.os-body .popover.top > .arrow:after { border-top-color: var(--os-card); }
body.os-body .popover.bottom > .arrow:after { border-bottom-color: var(--os-card); }
body.os-body .popover.left > .arrow:after { border-left-color: var(--os-card); }
body.os-body .popover.right > .arrow:after { border-right-color: var(--os-card); }

/* -- toastr notifications -- */
body.os-body #toast-container > div { background-color: var(--os-card) !important; border: 1px solid var(--os-line-2); border-left: 3px solid var(--os-accent); color: var(--os-ink); border-radius: 12px; box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5); font-family: var(--os-font); opacity: 1; padding: 14px 18px 14px 50px; width: 340px; }
body.os-body #toast-container > div:hover { box-shadow: 0 20px 50px rgba(0, 0, 0, 0.7); }
body.os-body #toast-container > .toast-success { border-left-color: var(--os-ok); }
body.os-body #toast-container > .toast-error { border-left-color: var(--os-danger); }
body.os-body #toast-container > .toast-warning { border-left-color: var(--os-ember); }
body.os-body #toast-container > .toast-info { border-left-color: var(--os-accent); }
body.os-body #toast-container .toast-title { color: var(--os-ink-strong); font-weight: 600; font-size: 13px; }
body.os-body #toast-container .toast-message { color: var(--os-dim); font-size: 12px; line-height: 1.5; margin-top: 2px; }
body.os-body #toast-container .toast-close-button { color: var(--os-muted); text-shadow: none; opacity: 1; font-weight: 400; top: 4px; right: 4px; }
body.os-body #toast-container .toast-progress { background: var(--os-accent); opacity: 0.6; }

/* -- SweetAlert (v1) confirms -- */
body.os-body .sweet-overlay { background: rgba(4, 7, 14, 0.7); }
body.os-body .sweet-alert { background: var(--os-card); border: 1px solid var(--os-line-2); border-radius: 16px; padding: 24px 24px 22px; box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6); font-family: var(--os-font); }
body.os-body .sweet-alert h2 { color: var(--os-ink-strong); font-family: var(--os-font); font-size: 20px; font-weight: 600; line-height: 1.3; margin: 18px 0 8px; }
body.os-body .sweet-alert p { color: var(--os-dim); font-size: 13px; line-height: 1.6; font-weight: 400; white-space: pre-line; }
body.os-body .sweet-alert button { border-radius: 10px; font-family: var(--os-font); font-weight: 600; font-size: 13px; padding: 10px 20px; margin: 20px 4px 0; box-shadow: none !important; }
body.os-body .sweet-alert button.confirm { background: var(--os-accent) !important; color: #FFFFFF; }
body.os-body .sweet-alert button.confirm:hover { background: #5B85FF !important; }
/* a visible warning / error icon means a destructive confirm: keep the button red */
body.os-body .sweet-alert:has(.sa-icon.sa-warning[style*="display: block"]) button.confirm, body.os-body .sweet-alert:has(.sa-icon.sa-error[style*="display: block"]) button.confirm { background: var(--os-danger) !important; color: #0A0E17; }
body.os-body .sweet-alert button.cancel { background: transparent !important; border: 1px solid var(--os-line-3); color: var(--os-dim); }
body.os-body .sweet-alert button.cancel:hover { color: var(--os-ink-strong); background: rgba(255, 255, 255, 0.06) !important; }
body.os-body .sweet-alert .sa-icon { margin: 4px auto 0; border-radius: 50% !important; }
body.os-body .sweet-alert .sa-icon.sa-warning { border-color: var(--os-ember); }
body.os-body .sweet-alert .sa-icon.sa-warning .sa-body, body.os-body .sweet-alert .sa-icon.sa-warning .sa-dot { background: var(--os-ember); }
body.os-body .sweet-alert .sa-icon.sa-error { border-color: var(--os-danger); }
body.os-body .sweet-alert .sa-icon.sa-error .sa-line { background: var(--os-danger); }
body.os-body .sweet-alert .sa-icon.sa-success { border-color: var(--os-ok); }
body.os-body .sweet-alert .sa-icon.sa-success .sa-line { background: var(--os-ok); }
body.os-body .sweet-alert .sa-icon.sa-success .sa-placeholder { border-color: rgba(74, 222, 128, 0.3); }
body.os-body .sweet-alert .sa-icon.sa-success .sa-fix { background: var(--os-card); }
body.os-body .sweet-alert .sa-icon.sa-info { border-color: var(--os-accent); }
body.os-body .sweet-alert .sa-icon.sa-info::before, body.os-body .sweet-alert .sa-icon.sa-info::after { background: var(--os-accent); }
body.os-body .sweet-alert input { height: 40px; margin: 12px 0 4px; }
body.os-body .sweet-alert .sa-error-container { background: var(--os-danger-soft); border-radius: 8px; color: var(--os-danger); }
body.os-body .sweet-alert .sa-error-container .icon { background: var(--os-danger); }

/* -- Metronic blockUI spinner box -- */
body.os-body .blockUI.blockMsg { border-radius: 12px !important; font-family: var(--os-font); }
body.os-body .loading-message.loading-message-boxed, body.os-body .page-loading { background: var(--os-card); border: 1px solid var(--os-line-2); border-radius: 12px; color: var(--os-ink); box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5); padding: 14px 20px; font-size: 13px; }
body.os-body .block-spinner-bar > div { background: var(--os-accent); }

/* -- Shepherd guided tours (theme-arrows) -- */
body.os-body .shepherd-element.shepherd-theme-arrows { max-width: 440px; font-family: var(--os-font); }
body.os-body .shepherd-element.shepherd-theme-arrows .shepherd-content { background: var(--os-card); border: 1px solid var(--os-line-2); border-radius: 14px; box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6); filter: none; font-family: var(--os-font); font-size: 13px; }
body.os-body .shepherd-element.shepherd-theme-arrows .shepherd-content header { background: transparent; border-bottom: 1px solid var(--os-line); border-radius: 14px 14px 0 0; padding: 14px 18px; }
body.os-body .shepherd-element.shepherd-theme-arrows .shepherd-content header .shepherd-title { color: var(--os-ink-strong); font-size: 15px; font-weight: 600; }
body.os-body .shepherd-element.shepherd-theme-arrows .shepherd-content header a.shepherd-cancel-link { color: var(--os-muted); font-size: 18px; }
body.os-body .shepherd-element.shepherd-theme-arrows .shepherd-text { color: var(--os-dim); font-size: 13px; line-height: 1.6; padding: 14px 18px; }
body.os-body .shepherd-element.shepherd-theme-arrows .shepherd-text p { margin: 0 0 8px; }
body.os-body .shepherd-element.shepherd-theme-arrows .shepherd-text br { display: none; }
body.os-body .shepherd-element.shepherd-theme-arrows .shepherd-content footer { padding: 0 18px 16px; }
body.os-body .shepherd-element.shepherd-theme-arrows .shepherd-content footer .shepherd-buttons li .shepherd-button { border-radius: 10px; font-weight: 600; font-size: 12px; padding: 8px 14px; background: var(--os-accent); color: #FFFFFF; text-transform: none; letter-spacing: 0; }
body.os-body .shepherd-element.shepherd-theme-arrows .shepherd-content footer .shepherd-buttons li .shepherd-button.shepherd-button-secondary { background: transparent; border: 1px solid var(--os-line-3); color: var(--os-dim); }
body.os-body .shepherd-element.shepherd-theme-arrows.shepherd-element-attached-top .shepherd-content:before { border-bottom-color: var(--os-card) !important; }
body.os-body .shepherd-element.shepherd-theme-arrows.shepherd-element-attached-bottom .shepherd-content:before { border-top-color: var(--os-card) !important; }
body.os-body .shepherd-element.shepherd-theme-arrows.shepherd-element-attached-left .shepherd-content:before { border-right-color: var(--os-card) !important; }
body.os-body .shepherd-element.shepherd-theme-arrows.shepherd-element-attached-right .shepherd-content:before { border-left-color: var(--os-card) !important; }
/* Legacy `.page-content-wrapper` pages that still use Metronic markup get the studio background */
body.os-body .page-content-wrapper { background: transparent; }
body.os-body .page-content { background: transparent; padding: 0; }
body.os-body .portlet.light { background: var(--os-card); border: 1px solid var(--os-line); border-radius: var(--os-radius); color: var(--os-ink); }
body.os-body .portlet.light .portlet-title .caption { color: var(--os-ink-strong); }
body.os-body .portlet.light .portlet-title { border-bottom-color: var(--os-line); }
body.os-body .note.note-info, body.os-body .note.note-warning, body.os-body .note.note-danger { border-radius: var(--os-radius-sm); }
body.os-body .table-striped > tbody > tr:nth-of-type(odd) { background: var(--os-hover); }
body.os-body .table > tbody > tr > td, body.os-body .table > thead > tr > th { border-color: var(--os-line); color: var(--os-ink); }
body.os-body .label { font-family: var(--os-mono); font-weight: 500; border-radius: 6px; }

/* ---------- Narrow screens: rail becomes an off-canvas drawer ---------- */
.os-menubtn { display: none; }
.os-scrim { display: none; position: fixed; inset: 0; z-index: 1039; background: rgba(4, 7, 14, 0.6); }
@media (max-width: 900px) {
  .os-rail { position: fixed; left: 0; top: 0; z-index: 1040; transform: translateX(-100%); transition: transform 0.2s ease; box-shadow: 0 0 40px rgba(0, 0, 0, 0.5); }
  body.os-rail-open .os-rail { transform: none; }
  body.os-rail-open .os-scrim { display: block; }
  body.os-rail-open { overflow: hidden; }
  .os-menubtn { display: inline-flex; flex: none; }
  .os-topbar { flex-wrap: wrap; gap: 10px; padding: 12px 16px; }
  .os-topbar > div:not(.os-dropdown):first-of-type { min-width: 0; }
  .os-topbar__title { font-size: 17px; }
  .os-content { padding: 20px 16px 32px; }
  .os-drop, .os-drop__inner { flex-direction: column; align-items: flex-start; }
  .os-chips { flex-wrap: wrap; }
  .os-chips .os-search { width: 100%; }
}

/* ---------- Panorama manager ---------- */
.os-drop {
  display: flex; align-items: center; gap: 18px; padding: 18px 22px; cursor: pointer;
  border: 1px dashed rgba(59, 107, 255, 0.5); border-radius: var(--os-radius); background: rgba(59, 107, 255, 0.06);
  transition: background 0.15s, border-color 0.15s; min-height: 0;
}
.os-drop:hover, .os-drop.dz-drag-hover { background: rgba(59, 107, 255, 0.12); border-color: var(--os-accent); }
.os-drop__inner { display: flex; align-items: center; gap: 18px; width: 100%; margin: 0; }
.os-drop__text { flex-grow: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; text-align: left; }
.os-drop__text h3 { font-size: 15px; font-weight: 600; color: var(--os-ink-strong); margin: 0; }
.os-drop__text p { margin: 0; font-size: 13px; color: var(--os-muted); line-height: 1.5; }
.os-drop .warning-size { display: none; color: var(--os-danger); font-size: 12px; margin-top: 0; }
.os-drop .pano-progressUpload { font-size: 12px; color: var(--os-accent-ink); font-family: var(--os-mono); margin-top: 0; }
/* panorama.manager.css legacy rules that fight the studio dropzone / card */
#pano-dropzone.os-drop { height: auto; }
#pano-dropzone.os-drop:hover { border: 1px dashed var(--os-accent); }
.os-pano .progress-pano-done { border: 0; }
.os-seg { display: inline-flex; gap: 6px; }

.os-panos { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
@media (max-width: 1400px) { .os-panos { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 1024px) { .os-panos { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .os-panos { grid-template-columns: minmax(0, 1fr); } }
/* uploader.js wraps each freshly uploaded card in <div id="loadingPano-N">; let the card itself be the grid item */
.os-panos > div[id^="loadingPano-"] { display: contents; }
.os-pano { display: flex; flex-direction: column; border-radius: 12px; background: var(--os-card); border: 1px solid var(--os-line); overflow: hidden; transition: border-color 0.15s; }
.os-pano:hover { border-color: var(--os-line-3); }
.os-pano__cover { position: relative; height: 150px; background: #0D1220; overflow: hidden; }
.os-pano__cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.os-pano__start { position: absolute; top: 10px; left: 10px; }
.os-pano__meta { position: absolute; bottom: 10px; left: 10px; padding: 3px 7px; border-radius: 5px; background: rgba(10, 14, 23, 0.7); color: #E6EAF2; font-size: 10px; }
.os-pano__tools { position: absolute; bottom: 8px; right: 8px; display: flex; gap: 6px; opacity: 0; transform: translateY(6px); transition: opacity 0.15s, transform 0.15s; }
.os-pano:hover .os-pano__tools, .os-pano:focus-within .os-pano__tools { opacity: 1; transform: none; }
.os-pano__tools a { width: 32px; height: 32px; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center; background: rgba(10, 14, 23, 0.82); color: #E6EAF2; border: 1px solid rgba(255, 255, 255, 0.12); }
.os-pano__tools a:hover { background: #FFFFFF; color: #0A0E17; }
.os-pano__tools a.is-danger:hover { background: var(--os-danger); }
.os-pano__tools a.is-on, .os-pano__tools a .fa-star.yellow { color: #FBBF24; }
.os-pano__body { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 14px; }
.os-pano__name { font-size: 14px; font-weight: 600; color: var(--os-ink-strong); margin: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.os-pano__open { flex: none; font-size: 12px; color: var(--os-accent-ink); }
/* legacy progress card injected by uploader.js while a file tiles */
.os-panos .pano-list.col-lg-4 { width: auto; padding: 0; float: none; }
.os-panos .pano-list .portlet.portlet-fit { margin: 0; border-radius: 12px; background: var(--os-card); border: 1px solid var(--os-line-2); overflow: hidden; }
.os-panos .pano-list .portlet-body { padding: 0; }
.os-panos .pano-list .progress-pano { position: relative; height: 150px; display: flex; align-items: center; justify-content: center; color: var(--os-dim); font-family: var(--os-mono); font-size: 12px; }
.os-panos .pano-list .progress-pano img { display: none; }
.os-panos .pano-list .progress-pano .row, .os-panos .pano-list .progress-pano .col-md-12 { margin: 0; padding: 0; width: 100%; }
.os-panos .pano-list .progress-pano .mt-overlay-3 { position: static; }
.os-panos .pano-list .progress-pano .clearSmallPanoramaEvent { position: absolute; top: 8px; right: 8px; z-index: 2; }
.os-panos .pano-list .progress-pano .block-spinner-bar { text-align: center; margin-top: 6px; }

/* ---------- Tabs (topbar) ---------- */
.os-tabs { display: flex; gap: 4px; flex-wrap: wrap; }
.os-tab { padding: 8px 12px; border-radius: 8px; font-size: 13px; color: var(--os-dim); white-space: nowrap; }
.os-tab:hover { color: var(--os-ink-strong); background: rgba(255, 255, 255, 0.05); }
.os-tab.is-active { color: var(--os-ink-strong); background: rgba(255, 255, 255, 0.08); font-weight: 600; }
body.os-light .os-tab.is-active { background: rgba(15, 23, 42, 0.06); }
.os-tabpane[hidden] { display: none; }

/* ---------- Profile & billing ---------- */
.os-profile { display: grid; grid-template-columns: 320px minmax(0, 1fr); gap: 20px; align-items: start; }
.os-billing { display: grid; grid-template-columns: 400px minmax(0, 1fr); gap: 20px; align-items: start; }
@media (max-width: 1100px) { .os-profile, .os-billing { grid-template-columns: minmax(0, 1fr); } }
.os-stack { display: flex; flex-direction: column; gap: 16px; }
.os-avatar { position: relative; width: 100%; aspect-ratio: 1; border-radius: 14px; overflow: hidden; background: var(--os-rail); border: 1px solid var(--os-line); }
.os-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.os-avatar__edit { position: absolute; right: 10px; bottom: 10px; }
.os-identity { display: flex; flex-direction: column; gap: 4px; }
.os-identity h2 { font-size: 20px; font-weight: 600; color: var(--os-ink-strong); margin: 0; }
.os-identity p { margin: 0; font-size: 13px; color: var(--os-muted); }
.os-kv { display: grid; grid-template-columns: 160px minmax(0, 1fr); gap: 0 20px; }
.os-kv > dt { padding: 12px 0; font-size: 12px; font-weight: 600; color: var(--os-muted); border-bottom: 1px solid var(--os-line); }
.os-kv > dd { padding: 12px 0; margin: 0; font-size: 13px; color: var(--os-ink); border-bottom: 1px solid var(--os-line); min-width: 0; overflow-wrap: anywhere; }
.os-kv > dt:nth-last-of-type(1), .os-kv > dd:last-of-type { border-bottom: 0; }
.os-kv .os-empty-val { color: var(--os-faint); }
@media (max-width: 640px) { .os-kv { grid-template-columns: minmax(0, 1fr); } .os-kv > dt { padding-bottom: 0; border-bottom: 0; } }
.os-socials { display: flex; flex-wrap: wrap; gap: 8px; }

.os-plancard { position: relative; display: flex; flex-direction: column; gap: 14px; padding: 22px; border-radius: 16px; background: linear-gradient(160deg, #16224A 0%, #0D1220 70%); border: 1px solid rgba(59, 107, 255, 0.35); overflow: hidden; }
.os-plancard--warn { background: linear-gradient(160deg, #3A2418 0%, #0D1220 70%); border-color: rgba(255, 158, 82, 0.4); }
.os-plancard--danger { background: linear-gradient(160deg, #3F1D22 0%, #0D1220 70%); border-color: rgba(248, 113, 113, 0.4); }
.os-plancard__ring { position: absolute; right: -70px; top: -60px; opacity: 0.5; pointer-events: none; }
.os-plancard__name { font-size: 26px; font-weight: 600; color: #FFFFFF; line-height: 1.2; }
.os-plancard__sub { font-size: 13px; color: #C5CBD8; }
.os-plancard__row { display: flex; justify-content: space-between; font-size: 12px; color: #8A93A6; }
.os-plancard__actions { display: flex; flex-wrap: wrap; gap: 8px; padding-top: 4px; }
.os-plancard .os-bar { background: rgba(255, 255, 255, 0.08); }

.os-paymethod { display: flex; align-items: center; gap: 14px; padding: 14px; border-radius: 12px; background: var(--os-rail); border: 1px solid var(--os-line-2); }
.os-cardbrand { width: 44px; height: 30px; border-radius: 6px; background: linear-gradient(135deg, #1E3A8A, #3B6BFF); display: inline-flex; align-items: center; justify-content: center; font-size: 10px; font-weight: 700; color: #FFFFFF; text-transform: uppercase; letter-spacing: 0.04em; flex: none; }
.os-cardbrand--none { background: rgba(255, 255, 255, 0.08); color: var(--os-muted); }
.os-paymethod__num { font-family: var(--os-mono); font-size: 14px; color: var(--os-ink-strong); }
.os-paymethod__sub { font-family: var(--os-mono); font-size: 11px; color: var(--os-muted); }

.os-history { border-radius: 16px; overflow: hidden; }
.os-history .os-table td, .os-history .os-table th { padding-left: 20px; padding-right: 20px; }
.os-danger-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 20px; }
.os-danger-row h4 { font-size: 14px; font-weight: 600; color: var(--os-ink-strong); margin: 0 0 2px; }
.os-danger-row p { font-size: 12px; color: var(--os-muted); margin: 0; }

/* Pricing (upgrade-account) — ocurus-pay.js toggles .btn-outline on the period buttons */
.os-billing-toggle { display: inline-flex; gap: 6px; }
.os-billing-toggle .os-btn.btn-outline { background: transparent; color: var(--os-dim); border: 1px solid var(--os-line-3); }
.os-billing-toggle .os-btn:not(.btn-outline) { background: #FFFFFF; color: #0A0E17; border: 1px solid #FFFFFF; }
.os-pricing { width: 100%; border-collapse: collapse; }
.os-pricing th, .os-pricing td { padding: 12px 16px; font-size: 13px; color: var(--os-ink); border-bottom: 1px solid var(--os-line); text-align: center; }
.os-pricing th:first-child, .os-pricing td:first-child { text-align: left; color: var(--os-dim); }
.os-pricing tr:last-child td { border-bottom: 0; }
.os-pricing .os-pricing__group td { padding-top: 18px; font-size: 11px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--os-muted); text-align: left; }
.os-pricing .is-pro { background: rgba(59, 107, 255, 0.06); }
.os-pricing .os-check-ico { color: var(--os-ok); }
.os-pricing .os-dash { color: var(--os-faint); }
.os-planhead { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 8px 0 4px; }
.os-planhead h3 { margin: 0; font-size: 17px; font-weight: 600; color: var(--os-ink-strong); }
.os-planhead .os-price { font-family: var(--os-mono); font-size: 22px; color: var(--os-ink-strong); }
.os-planhead .os-price small { font-size: 12px; color: var(--os-muted); font-family: var(--os-font); }
.os-faq { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 24px; }
@media (max-width: 640px) { .os-faq { grid-template-columns: minmax(0, 1fr); } }
.os-faq h4 { font-size: 13px; font-weight: 600; color: var(--os-ink-strong); margin: 0 0 4px; }
.os-faq p { font-size: 12px; color: var(--os-muted); margin: 0; line-height: 1.5; }
.os-ask { display: flex; gap: 8px; }
.os-ask .os-input { flex-grow: 1; }

/* Stripe Elements host (update-paymentMethod) */
.os-stripe-el { min-height: var(--os-control); padding: 11px 12px; border-radius: var(--os-radius-sm); background: var(--os-input); border: 1px solid var(--os-line-2); }
.os-stripe-el.StripeElement--focus { border-color: var(--os-accent); box-shadow: 0 0 0 3px var(--os-accent-soft); }
.os-stripe-el.StripeElement--invalid { border-color: var(--os-danger); }
.os-narrow { max-width: 520px; margin: 0 auto; width: 100%; }
.os-content .note { border-radius: var(--os-radius-sm); }

/* ---------- Superadmin shell (light content, dark rail) ---------- */
.os-nav--admin { gap: 2px; }
.os-nav--admin .os-nav__label { padding: 12px 12px 4px; font-size: 10px; }
.os-nav--admin a { padding: 8px 12px; font-size: 13px; }
.os-count--danger.is-on { background: var(--os-danger); color: #0A0E17; }
body.os-light .os-count--danger.is-on { background: #F87171; }
.os-nav__group { margin: 0; }
.os-nav__group summary { list-style: none; display: flex; align-items: center; gap: 12px; padding: 8px 12px; border-radius: 10px; color: #8A93A6; font-size: 13px; font-weight: 500; cursor: pointer; }
.os-nav__group summary::-webkit-details-marker { display: none; }
.os-nav__group summary:hover { background: rgba(255, 255, 255, 0.04); color: #FFFFFF; }
.os-nav__group summary.is-danger { color: #F87171; }
.os-nav__group summary .os-nav__chev { margin-left: auto; transition: transform 0.15s; }
.os-nav__group[open] summary .os-nav__chev { transform: rotate(180deg); }
.os-nav--sub { display: flex; flex-direction: column; gap: 1px; padding: 2px 0 6px; }
.os-nav--sub a { padding: 6px 12px 6px 42px; font-size: 12px; color: #8A93A6; border-radius: 8px; }
.os-nav--sub a:hover { color: #FFFFFF; background: rgba(255, 255, 255, 0.04); }
.os-admin-search { width: 320px; }
.os-admin-search input { flex-grow: 1; min-width: 0; background: transparent; border: 0; outline: 0; color: var(--os-ink-strong); font-family: var(--os-font); font-size: 13px; }
.os-kbd { font-size: 10px; padding: 1px 6px; border-radius: 4px; border: 1px solid var(--os-line-3); color: var(--os-muted); }
.os-topbar__actions { display: flex; gap: 8px; align-items: center; }
body.os-light .os-topbar { min-height: 68px; }
body.os-light .os-content { padding: 22px 32px 40px; }
body.os-light .os-card { border-radius: 14px; }
.os-card__title { font-size: 14px; font-weight: 600; color: var(--os-ink-strong); }
.os-card__foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 18px; border-top: 1px solid var(--os-line); flex-wrap: wrap; }
.os-card__foot .os-pagination { justify-content: flex-end; }
body.os-light .os-badge--muted { background: #EEF1F7; color: var(--os-muted); }
body.os-light .os-badge--draft { background: var(--os-ember-soft); color: #C2410C; }
body.os-light .os-tile__delta.is-up { color: var(--os-ok); }
a.os-tile:hover { border-color: var(--os-line-3); }
body.os-light .os-iconbtn { border-color: var(--os-line-2); color: var(--os-muted); background: var(--os-card); }
body.os-light .os-iconbtn:hover { color: var(--os-ink-strong); border-color: var(--os-line-3); }
.os-iconbtn--sm { width: 30px; height: 30px; border-radius: 8px; }
body.os-light .os-search { background: var(--os-bg); border-color: var(--os-line); color: var(--os-muted); }
body.os-light .os-user { border-color: var(--os-line); background: var(--os-card); color: var(--os-ink-strong); }
body.os-light .os-empty { border-color: var(--os-line-3); }

/* health strip */
.os-health { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 1280px) { .os-health { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 767px) { .os-health { grid-template-columns: minmax(0, 1fr); } }
.os-health__item { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 12px; background: var(--os-card); border: 1px solid var(--os-line); color: inherit; min-width: 0; }
.os-health__item > div { min-width: 0; display: flex; flex-direction: column; }
.os-health__item strong { font-size: 12px; font-weight: 600; color: var(--os-ink-strong); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.os-health__sub { font-family: var(--os-mono); font-size: 11px; color: var(--os-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.os-health__item.is-bad { background: var(--os-danger-soft); border-color: rgba(248, 113, 113, 0.5); }
.os-health__item.is-bad strong { color: var(--os-danger); }
.os-health__item.is-bad .os-health__sub { color: var(--os-danger); opacity: 0.85; }
.os-health__item.is-warn { background: var(--os-ember-soft); border-color: rgba(255, 158, 82, 0.5); }
.os-dot { width: 8px; height: 8px; border-radius: 4px; flex: none; display: inline-block; }
body.os-light .os-dot--ok { background: #16A34A; }
body.os-light .os-dot--danger { background: #B91C1C; }
body.os-light .os-dot--warn { background: #EA580C; }

/* charts */
.os-linechart svg { width: 100%; height: auto; display: block; }
.os-bars { display: flex; align-items: flex-end; gap: 10px; height: 150px; padding: 0 4px; }
.os-bars__col { flex: 1 1 0; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 6px; height: 100%; min-width: 0; }
.os-bars__bar { width: 100%; max-width: 24px; border-radius: 4px 4px 0 0; background: var(--os-accent); }
.os-bars__bar.is-zero { background: var(--os-line-3); }
.os-bars__bar.is-future { background: var(--os-line); }
.os-bars__lbl { font-family: var(--os-mono); font-size: 10px; color: var(--os-muted); }

/* people */
.os-userline { display: flex; align-items: center; gap: 10px; min-width: 0; }
.os-ava { width: 32px; height: 32px; border-radius: 16px; display: inline-flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 600; color: #FFFFFF; background: linear-gradient(135deg, #3B6BFF, #0A0E17); flex: none; text-transform: uppercase; }
.os-table--compact td { padding: 10px 18px; }
.os-table--users td { padding: 10px 14px; }
.os-table--users th { padding: 10px 14px; }
.os-th-sort { color: inherit !important; }
.os-th-sort::after { content: " ↕"; opacity: 0.5; }
.os-rowmenu { position: relative; display: inline-block; }
.os-rowmenu__menu { min-width: 320px; }
.os-rowmenu__section { padding: 8px 12px 4px; font-size: 10px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--os-muted); }
.os-menu-form { display: flex; align-items: center; gap: 8px; padding: 6px 12px; }
.os-menu-form__text { flex-grow: 1; display: flex; flex-direction: column; min-width: 0; }
.os-menu-form__text span { font-size: 13px; color: var(--os-ink-strong); }
.os-menu-form__text small { font-size: 11px; color: var(--os-muted); }
.os-select--xs { width: 58px; height: 28px; padding: 0 22px 0 8px; font-size: 12px; background-position: right 6px center; }
body.os-body .os-rowmenu .dropdown-menu > li > a { padding: 7px 12px; }

/* filters toolbar */
.os-filters-card { padding: 0; }
.os-filters { display: flex; flex-wrap: wrap; gap: 10px 12px; align-items: flex-end; padding: 14px 18px; margin: 0; }
.os-filters .os-field { gap: 4px; }
.os-filters .os-label { font-size: 11px; }
.os-filters .os-input, .os-filters .os-select { height: 36px; font-size: 13px; min-width: 120px; }
.os-filters__actions { display: flex; gap: 6px; align-items: center; height: 36px; }
.os-filters__count { margin-left: auto; align-self: center; font-family: var(--os-mono); font-size: 12px; color: var(--os-muted); }

/* tables that hold row menus must not clip the dropdown */
.os-table-wrap { overflow: visible; }
@media (max-width: 1100px) { .os-table-wrap { overflow-x: auto; } }
.os-tab__count--danger { color: var(--os-danger); font-weight: 600; }
.os-btn--danger-ghost { color: var(--os-danger) !important; border-color: rgba(248, 113, 113, 0.5) !important; }
.os-btn--danger-ghost:hover { background: var(--os-danger-soft) !important; }
.os-topbar__actions form { display: inline; margin: 0; }
.os-details summary { list-style: none; }
.os-details summary::-webkit-details-marker { display: none; }
.os-pre { margin: 8px 0 0; padding: 10px 12px; border-radius: 8px; background: var(--os-hover); border: 1px solid var(--os-line); font-family: var(--os-mono); font-size: 11px; line-height: 1.5; color: var(--os-ink); white-space: pre-wrap; word-break: break-all; max-height: 320px; overflow: auto; }
.os-pre--dim { color: var(--os-muted); }
body.os-light .os-pre { background: #F7F8FC; }

/* application log */
.os-log { display: flex; flex-direction: column; }
.os-log__row { border-bottom: 1px solid var(--os-line); }
.os-log__row:last-child { border-bottom: 0; }
.os-log__row > summary { display: grid; grid-template-columns: 110px 56px minmax(0, 1fr); gap: 12px; align-items: center; padding: 8px 18px; cursor: pointer; list-style: none; }
.os-log__row > summary::-webkit-details-marker { display: none; }
.os-log__row > summary:hover { background: var(--os-hover); }
.os-log__time { font-size: 11px; color: var(--os-muted); }
.os-log__lvl { justify-self: start; font-size: 10px; padding: 2px 6px; }
.os-log__msg { font-size: 12px; color: var(--os-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.os-log__row[open] > summary .os-log__msg { white-space: normal; }
.os-log__detail { padding: 0 18px 12px 18px; }
.os-log__detail .os-pre { margin-top: 0; max-height: 480px; }
@media (max-width: 767px) { .os-log__row > summary { grid-template-columns: 90px 50px minmax(0, 1fr); gap: 8px; padding: 8px 12px; } }

/* controls lifted out of a legacy h1.page-title into the topbar */
.os-topbar__legacy { flex-wrap: wrap; }
.os-topbar__legacy .btn { margin: 0; }
body.os-body select.one-line-select, .os-topbar__legacy select { height: 36px; padding: 0 30px 0 12px; border-radius: 8px; background: var(--os-input); border: 1px solid var(--os-line-2); color: var(--os-ink-strong); font-family: var(--os-font); font-size: 13px; max-width: 260px; appearance: none; -webkit-appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%238A93A6' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 10px center; }
body.os-body select.form-control option, body.os-body select.one-line-select option { background: var(--os-card); color: var(--os-ink); }

/* ---------- Legacy admin markup (Metronic) rendered inside the light shell ---------- */
body.os-body .page-content-wrapper { display: block; }
body.os-body .page-content { padding: 22px 32px 40px !important; margin: 0 !important; min-height: 0 !important; background: transparent !important; }
body.os-body .page-content .theme-panel { display: none; }
body.os-body .page-title { font-size: 20px; font-weight: 600; color: var(--os-ink-strong); margin: 0 0 18px; padding: 0; border: 0; font-family: var(--os-font); }
body.os-body .page-title > small { display: block; font-size: 13px; color: var(--os-muted); font-weight: 400; margin-top: 2px; }
body.os-body .page-content h2 { font-size: 15px; font-weight: 600; margin: 8px 0 12px; }
body.os-body .portlet.light, body.os-body .portlet.light.bordered, body.os-body .portlet.box { background: var(--os-card); border: 1px solid var(--os-line); border-radius: 14px; padding: 0; margin-bottom: 16px; box-shadow: none; }
body.os-body .portlet.light > .portlet-title { padding: 14px 18px; min-height: 0; margin: 0; border-bottom: 1px solid var(--os-line); display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
body.os-body .portlet.light > .portlet-title::after, body.os-body .portlet.light > .portlet-title::before { display: none; }
body.os-body .portlet.light > .portlet-title > .caption { padding: 0; float: none; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
body.os-body .portlet.light > .portlet-title > .caption > .caption-subject { font-size: 14px !important; text-transform: none !important; color: var(--os-ink-strong) !important; letter-spacing: 0; font-weight: 600 !important; }
body.os-body .portlet.light > .portlet-title > .caption > i { color: var(--os-muted) !important; font-size: 15px; margin: 0; }
body.os-body .portlet.light > .portlet-title > .caption .caption-helper { color: var(--os-muted); font-size: 12px; padding: 0; }
body.os-body .portlet.light > .portlet-title > .actions { padding: 0; float: none; margin-left: auto; }
body.os-body .portlet.light > .portlet-body { padding: 16px 18px; }
body.os-body .portlet.light.portlet-fit > .portlet-body { padding: 0 0 12px; }
body.os-body .portlet.light.portlet-fit > .portlet-title { padding: 14px 18px; }
body.os-body .dashboard-stat.dashboard-stat-v2 { background: var(--os-card) !important; border: 1px solid var(--os-line); border-radius: 14px; padding: 16px 18px; margin-bottom: 16px; display: flex; flex-direction: column; gap: 4px; min-height: 0; }
body.os-body .dashboard-stat.dashboard-stat-v2 .visual { display: none; }
body.os-body .dashboard-stat.dashboard-stat-v2 .details { position: static; padding: 0; text-align: left; }
body.os-body .dashboard-stat.dashboard-stat-v2 .details .number { font-family: var(--os-mono); font-size: 26px; font-weight: 500; color: var(--os-ink-strong); padding: 0; margin: 0; line-height: 1.2; }
body.os-body .dashboard-stat.dashboard-stat-v2 .details .number span { font-size: 26px !important; }
body.os-body .dashboard-stat.dashboard-stat-v2 .details .desc { color: var(--os-muted); font-size: 12px; text-transform: none; letter-spacing: 0; }
body.os-body .dashboard-stat.dashboard-stat-v2 .more { background: transparent; color: var(--os-muted); font-size: 12px; padding: 4px 0 0; text-transform: none; letter-spacing: 0; font-family: var(--os-mono); }
body.os-body .dashboard-stat.dashboard-stat-v2 .more .m-icon-swapright { display: none; }
body.os-body .table { font-size: 13px; margin-bottom: 0; }
body.os-body .table > thead > tr > th { font-size: 11px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--os-muted); border-bottom: 1px solid var(--os-line); padding: 10px 12px; }
body.os-body .table > tbody > tr > td { padding: 10px 12px; border-top: 0; border-bottom: 1px solid var(--os-line); vertical-align: middle; color: var(--os-ink); }
body.os-body .table-bordered, body.os-body .table-bordered > tbody > tr > td, body.os-body .table-bordered > thead > tr > th { border: 0; border-bottom: 1px solid var(--os-line); }
body.os-body .table-striped > tbody > tr:nth-of-type(odd) { background: transparent; }
body.os-body .table-hover > tbody > tr:hover { background: var(--os-hover); }
body.os-body .table .text-muted, body.os-body .text-muted { color: var(--os-muted) !important; }
body.os-body .page-content > .row > .col-md-12 > .table { background: var(--os-card); border: 1px solid var(--os-line); border-radius: 14px; overflow: hidden; }
body.os-body .pagination { margin: 12px 0 0; }
body.os-body .pagination > li > a, body.os-body .pagination > li > span { border-color: var(--os-line-2); color: var(--os-dim); background: var(--os-card); font-family: var(--os-mono); font-size: 12px; padding: 6px 11px; margin-left: 4px; border-radius: 8px !important; }
body.os-body .pagination > .active > a, body.os-body .pagination > .active > span { background: var(--os-accent); border-color: var(--os-accent); color: #FFFFFF; }
body.os-body .pagination > .disabled > span, body.os-body .pagination > .disabled > a { color: var(--os-faint); }
body.os-body .label { font-family: var(--os-mono); font-size: 10px; letter-spacing: 0.04em; text-transform: uppercase; padding: 3px 7px; border-radius: 6px; font-weight: 500; }
body.os-body .label-success { background: var(--os-ok-soft); color: var(--os-ok); }
body.os-body .label-danger { background: var(--os-danger-soft); color: var(--os-danger); }
body.os-body .label-warning { background: var(--os-ember-soft); color: #C2410C; }
body.os-body .label-info, body.os-body .label-primary { background: var(--os-accent-soft); color: var(--os-accent-ink); }
body.os-body .label-default { background: var(--os-hover); color: var(--os-muted); border: 1px solid var(--os-line); }
body.os-body code { background: var(--os-hover); color: var(--os-ink); border-radius: 4px; padding: 1px 5px; font-family: var(--os-mono); font-size: 12px; border: 1px solid var(--os-line); word-break: break-all; }
body.os-body .word-break { word-break: break-all; font-family: var(--os-mono); font-size: 11px; color: var(--os-muted); max-width: 520px; }
body.os-body .progress { height: 8px; }
body.os-body .progress .progress-bar { font-size: 0; }
body.os-body .form-inline .form-group { vertical-align: bottom; }
body.os-body .btn-group .btn { border-radius: 8px !important; margin-right: 4px; }
body.os-body .note { margin-bottom: 14px; }
body.os-body .well { margin-bottom: 14px; }
body.os-body .right { text-align: right; padding: 0 18px 12px; }
body.os-body .right .pagination { margin-top: 0; }

/* ---------- Content editor form (admin blog / learn — AdminForm mockup) ---------- */
.os-postform { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 20px; align-items: start; margin: 0; }
@media (max-width: 1100px) { .os-postform { grid-template-columns: minmax(0, 1fr); } }
.os-input--lg { height: 50px !important; font-size: 18px !important; font-weight: 600; }
.os-postform__cover { width: 100% !important; aspect-ratio: 16 / 9; max-height: none !important; border-radius: 10px; overflow: hidden; background: var(--os-rail); border: 1px solid var(--os-line-2); display: flex; align-items: center; justify-content: center; padding: 0 !important; margin: 0 !important; }
.os-postform__cover img { width: 100% !important; height: 100% !important; object-fit: cover; max-height: none !important; border-radius: 0; }
.os-postform .fileinput-preview.os-postform__cover:empty { display: none; }
.os-switchrow { display: flex; justify-content: space-between; align-items: center; font-size: 13px; color: var(--os-ink-strong); font-weight: 600; margin: 0; cursor: pointer; }
.os-kv--tight > dt, .os-kv--tight > dd { padding: 7px 0; font-size: 12px; }
.os-kv--tight { grid-template-columns: 90px minmax(0, 1fr); }
body.os-light .os-switch { background: #D6DBE7; } body.os-light .os-switch.is-on { background: var(--os-accent); }
.os-postform .mce-tinymce { border-radius: 10px; }

/* Metronic coloured portlet boxes (navigation / form editors) */
body.os-body .portlet.box { background: var(--os-card) !important; border: 1px solid var(--os-line) !important; border-radius: 14px; overflow: hidden; margin-bottom: 16px; }
body.os-body .portlet.box > .portlet-title { background: var(--os-card-2) !important; border-bottom: 1px solid var(--os-line) !important; padding: 12px 18px; min-height: 0; display: flex; align-items: center; gap: 12px; }
body.os-body .portlet.box > .portlet-title::before, body.os-body .portlet.box > .portlet-title::after { display: none; }
body.os-body .portlet.box > .portlet-title > .caption { color: var(--os-ink-strong) !important; font-size: 14px; font-weight: 600; padding: 0; float: none; display: flex; align-items: center; gap: 8px; flex-grow: 1; }
body.os-body .portlet.box > .portlet-title > .caption > i { color: var(--os-muted) !important; }
body.os-body .portlet.box > .portlet-title > .tools { float: none; padding: 0; }
body.os-body .portlet.box > .portlet-title > .tools > a { background-image: none !important; width: 24px; height: 24px; display: inline-flex; align-items: center; justify-content: center; color: var(--os-muted); border-radius: 6px; }
body.os-body .portlet.box > .portlet-title > .tools > a.collapse::before { content: "▾"; } body.os-body .portlet.box > .portlet-title > .tools > a.expand::before { content: "▸"; }
body.os-body .portlet.box > .portlet-body { background: transparent !important; padding: 16px 18px; color: var(--os-ink); }
body.os-body .portlet.box .form-actions { background: transparent !important; border-top: 1px solid var(--os-line); padding: 14px 0 0; margin-top: 8px; }
body.os-body .portlet.box .form-body.noPadding { padding: 0; }
/* task list (navigation editor: panoramas that show the menu) */
body.os-body .task-list { list-style: none; padding: 0; margin: 0; }
body.os-body .task-list > li { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-bottom: 1px solid var(--os-line); background: transparent; }
body.os-body .task-list > li:last-child { border-bottom: 0; }
body.os-body .task-list .task-title, body.os-body .task-list .task-title-sp { color: var(--os-ink); font-family: var(--os-font); font-size: 13px; }
body.os-body .task-list .task-checkbox { margin: 0; }
body.os-body .scroller { max-height: none !important; }
/* nestable (drag & drop menu structure) */
body.os-body .dd { color: var(--os-ink); }
body.os-body .dd-handle { background: var(--os-card-2); border: 1px solid var(--os-line-2); border-radius: 8px; color: var(--os-ink-strong); font-family: var(--os-font); font-size: 13px; font-weight: 500; padding: 8px 12px; height: auto; }
body.os-body .dd-handle:hover { background: var(--os-hover); color: var(--os-ink-strong); }
body.os-body .dd-item > button { color: var(--os-muted); font-size: 12px; }
body.os-body .dd-placeholder, body.os-body .dd-empty { background: var(--os-accent-soft); border: 1px dashed var(--os-accent); border-radius: 8px; }
body.os-body .dd-item .dd-nodrag, body.os-body .dd3-content { background: var(--os-card-2); border-color: var(--os-line-2); color: var(--os-ink-strong); border-radius: 8px; }
body.os-body .dd3-handle { background: var(--os-rail); border-color: var(--os-line-2); border-radius: 8px 0 0 8px; }
body.os-body .dd3-handle::before { color: var(--os-muted); }
/* mini-map: list rows and canvas frame */
body.os-body .mt-checkbox-list { display: flex; flex-direction: column; gap: 6px; }
body.os-body .tiles .tile.panorama { background: var(--os-rail); border: 1px solid var(--os-line-2); border-radius: 10px; }
body.os-body .well.well-sm, body.os-body .list-group-item { background: var(--os-card-2); border-color: var(--os-line-2); color: var(--os-ink); }
body.os-body .list-group-item.active, body.os-body .list-group-item.active:hover { background: var(--os-accent); border-color: var(--os-accent); color: #FFFFFF; }

/* mini-map / navigation editors: Metronic .tiles rows (not the editor's thumbnail tiles) */
body.os-body:not(.os-editor) .tiles .tile { background: var(--os-card-2) !important; color: var(--os-ink) !important; border: 1px solid var(--os-line-2); border-radius: 8px; box-shadow: none !important; }
body.os-body:not(.os-editor) .tiles .tile:hover { border-color: var(--os-line-3); }
body.os-body:not(.os-editor) .tiles .tile.selected, body.os-body:not(.os-editor) .tiles .tile.panoSelected { border-color: var(--os-accent) !important; box-shadow: 0 0 0 3px var(--os-accent-soft) !important; }
body.os-body:not(.os-editor) .tiles .tile .tile-body, body.os-body:not(.os-editor) .tiles .tile .tile-object { color: var(--os-ink) !important; }
body.os-body:not(.os-editor) .tiles .tile .corner { display: none; }
/* Metronic .feeds rows inside those tiles */
body.os-body .feeds li, body.os-body .feeds li:nth-child(even), body.os-body .feeds li:hover { background: transparent !important; color: var(--os-ink) !important; }
body.os-body .feeds li .col1 > .cont, body.os-body .feeds li .col1 > .cont > .cont-col2 > .desc { color: var(--os-ink) !important; font-family: var(--os-font); }
body.os-body .feeds li .col1 > .cont > .cont-col1 > .label { background: var(--os-accent-soft) !important; color: var(--os-accent-ink) !important; border-radius: 6px; }
body.os-body .feeds li .col2 > .date { color: var(--os-muted) !important; }
/* notes inside legacy forms lost their tint when the portlet went dark */
body.os-body .portlet .note, body.os-body .form-body .note, body.os-body .modal .note { background: var(--os-accent-soft) !important; color: var(--os-dim) !important; border-left-color: var(--os-accent) !important; }
body.os-body .portlet .note.note-warning, body.os-body .modal .note.note-warning { background: var(--os-ember-soft) !important; border-left-color: var(--os-ember) !important; }
body.os-body .portlet .note.note-danger, body.os-body .modal .note.note-danger { background: var(--os-danger-soft) !important; border-left-color: var(--os-danger) !important; }
/* bare tables directly in the page content (project requests) */
body.os-body .page-content > .table, body.os-body .page-content > .table-scrollable, body.os-body .page-content > .table-responsive { background: var(--os-card); border: 1px solid var(--os-line); border-radius: 14px; overflow: hidden; }
/* small destructive buttons in list rows read as ghost, not as a red block */
body.os-body .btn.btn-xs.red, body.os-body .btn.red.btn-xs, body.os-body .btn.btn-xs.btn-danger, body.os-body .btn.btn-xs.red-mint, body.os-body .btn.btn-sm.red.btn-outline { background: transparent !important; border: 1px solid rgba(248, 113, 113, 0.5) !important; color: var(--os-danger) !important; }
body.os-body .btn.btn-xs.red:hover, body.os-body .btn.red.btn-xs:hover, body.os-body .btn.btn-xs.btn-danger:hover { background: var(--os-danger-soft) !important; }
body.os-body .table > tbody > tr > td:last-child .btn + .btn, body.os-body .table > tbody > tr > td:last-child form + form { margin-left: 4px; }
body.os-body .table > tbody > tr > td:last-child:has(.btn) { white-space: nowrap; }

/* Metronic dashboard-stat v1 (reports page): coloured blocks → studio tiles */
body.os-body .dashboard-stat:not(.dashboard-stat-v2) { background: var(--os-card) !important; border: 1px solid var(--os-line); border-radius: 14px; padding: 16px 18px; margin-bottom: 16px; display: flex; flex-direction: column-reverse; gap: 4px; min-height: 0; overflow: hidden; }
body.os-body .dashboard-stat:not(.dashboard-stat-v2) .visual { position: absolute; right: 14px; top: 10px; width: auto; height: auto; }
body.os-body .dashboard-stat:not(.dashboard-stat-v2) .visual > i { font-size: 34px; line-height: 1; color: var(--os-accent); opacity: 0.35; }
body.os-body .dashboard-stat:not(.dashboard-stat-v2) .details { position: static; padding: 0; text-align: left; }
body.os-body .dashboard-stat:not(.dashboard-stat-v2) .details .number { font-family: var(--os-mono); font-size: 26px; font-weight: 500; color: var(--os-ink-strong); padding: 0; margin: 0; line-height: 1.2; }
body.os-body .dashboard-stat:not(.dashboard-stat-v2) .details .desc { color: var(--os-muted); font-size: 12px; text-transform: none; letter-spacing: 0; }
body.os-body .dashboard-stat:not(.dashboard-stat-v2) .more { display: none; }
body.os-body .dashboard-stat { position: relative; }

/* ---------- DataTables (legacy admin lists) ---------- */
body.os-body .dataTables_wrapper { padding: 0; }
body.os-body .dataTables_wrapper .row { margin: 0; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px; }
body.os-body .dataTables_wrapper .row > div { padding: 0; width: auto; float: none; }
body.os-body .dataTables_filter, body.os-body .dataTables_length { padding: 12px 18px 4px; }
body.os-body .dataTables_filter label, body.os-body .dataTables_length label { display: flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 600; color: var(--os-muted); margin: 0; }
body.os-body .dataTables_filter input, body.os-body .dataTables_length select { height: 36px; padding: 0 12px; border-radius: 8px; background: var(--os-input); border: 1px solid var(--os-line-2); color: var(--os-ink-strong); font-family: var(--os-font); font-size: 13px; min-width: 220px; margin: 0; }
body.os-body .dataTables_filter input:focus { border-color: var(--os-accent); box-shadow: 0 0 0 3px var(--os-accent-soft); outline: 0; }
body.os-body .dataTables_length select { min-width: 70px; }
body.os-body .dataTables_info { padding: 12px 18px; font-family: var(--os-mono); font-size: 12px; color: var(--os-muted); }
body.os-body .dataTables_paginate { padding: 8px 18px 12px; }
body.os-body table.dataTable thead .sorting, body.os-body table.dataTable thead .sorting_asc, body.os-body table.dataTable thead .sorting_desc { background-image: none !important; position: relative; padding-right: 22px !important; cursor: pointer; }
body.os-body table.dataTable thead .sorting::after, body.os-body table.dataTable thead .sorting_asc::after, body.os-body table.dataTable thead .sorting_desc::after { content: "↕"; position: absolute; right: 8px; top: 50%; transform: translateY(-50%); font-size: 10px; opacity: 0.45; }
body.os-body table.dataTable thead .sorting_asc::after { content: "↑"; opacity: 1; color: var(--os-accent); }
body.os-body table.dataTable thead .sorting_desc::after { content: "↓"; opacity: 1; color: var(--os-accent); }
body.os-body table.dataTable thead th i.fa { display: none; }
body.os-body table.dataTable, body.os-body table.dataTable.no-footer { border: 0 !important; margin: 0 !important; width: 100% !important; }
body.os-body .table-scrollable { border: 0; margin: 0; }
body.os-body .btn.btn-icon-only { width: 34px; height: 34px !important; padding: 0 !important; display: inline-flex; align-items: center; justify-content: center; border-radius: 8px !important; }
body.os-body .bootstrap-switch-mini, body.os-body .bootstrap-switch-small { font-size: 11px; }
body.os-body .portlet.light .portlet-body > .table-scrollable > .table, body.os-body .portlet.light .portlet-body > .table { margin: 0; }

/* ---------- Owner review round 3 (2026-09-14) ---------- */
/* create-tour modal was cramped; widen the legacy .modal-medium */
body.os-body .modal-dialog.modal-medium { width: 960px; max-width: calc(100vw - 32px); }
@media (max-width: 767px) { body.os-body .modal-dialog.modal-medium { width: auto; margin: 10px; } }
/* every control in an input-group / touchspin shares one height */
body.os-body .modal .input-group { display: flex; width: 100%; }
body.os-body .modal .input-group > .form-control, body.os-body .modal .input-group > .form-control.input-sm { height: 38px !important; flex: 1 1 auto; width: auto !important; min-width: 0; }
body.os-body .modal .input-group-addon, body.os-body .modal .input-group-btn, body.os-body .modal .input-group-btn > .btn { height: 38px !important; display: inline-flex; align-items: center; justify-content: center; padding: 0 12px !important; line-height: 1 !important; width: auto; white-space: nowrap; }
body.os-body .modal .input-group-btn { padding: 0 !important; }
body.os-body .modal .input-group-btn > .btn { border-radius: 8px !important; }
body.os-body .modal .input-group > .form-control:not(:first-child):not(:last-child) { border-radius: 0 !important; }
body.os-body .modal .input-group-btn:first-child > .btn { border-radius: 8px 0 0 8px !important; margin-right: -1px; }
body.os-body .modal .input-group-btn:last-child > .btn { border-radius: 0 8px 8px 0 !important; margin-left: -1px; }
body.os-body .modal .input-group > .form-control:first-child { border-radius: 8px 0 0 8px !important; }
body.os-body .modal .input-group > .form-control:last-child { border-radius: 0 8px 8px 0 !important; }
body.os-body .bootstrap-touchspin .bootstrap-touchspin-prefix, body.os-body .bootstrap-touchspin .bootstrap-touchspin-postfix { display: none; }
body.os-body .modal .row.row-margin { display: flex; align-items: flex-start; margin-bottom: 14px; }
body.os-body .modal .row.row-margin > .control-label { padding-top: 9px; line-height: 1.3; }
body.os-body .modal .help-block { font-size: 12px; color: var(--os-muted); }
.os-thumb { width: 64px; height: 40px; border-radius: 6px; overflow: hidden; background: var(--os-rail); flex: none; border: 1px solid var(--os-line); }
.os-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
/* avatars anywhere in the studio */
body.os-body .os-user img, body.os-body .mt-head-user-img { background: url("/images/studio/no-avatar.svg") center / cover; }

/* ---------- Owner review fixes (2026-09-14) ---------- */
/* One placeholder everywhere: every legacy "no image" bitmap (local /images/no_image_*.png and the
   S3 defaults/noImage/no_image_*.png) is swapped for the studio SVG. `content: url()` replaces the
   rendered picture but leaves the src attribute alone, so scripts that compare src still work. */
body.os-body img[src*="no_image"] { content: url("/images/studio/no-image.svg"); object-fit: cover; background: #0F1626; }
body.os-body .thumbnail, body.os-body .fileinput .thumbnail, body.os-body .fileinput-preview.thumbnail { background: var(--os-rail); border: 1px solid var(--os-line-2); border-radius: 10px; padding: 4px; }
body.os-body .fileinput .thumbnail img { border-radius: 8px; }
/* Bootstrap-4 style pagination markup (Laravel default) rendered with the Bootstrap 3 sheet */
body.os-body .pagination > li > a, body.os-body .pagination > li > span, body.os-body .pagination .page-link { background: var(--os-card) !important; border: 1px solid var(--os-line-2) !important; color: var(--os-dim) !important; font-family: var(--os-mono); font-size: 12px; padding: 6px 11px; margin-left: 4px; border-radius: 8px !important; line-height: 1.4; box-shadow: none !important; }
body.os-body .pagination > li > a:hover, body.os-body .pagination .page-link:hover { background: var(--os-hover) !important; color: var(--os-ink-strong) !important; border-color: var(--os-line-3) !important; }
body.os-body .pagination > .active > a, body.os-body .pagination > .active > span, body.os-body .pagination > .active > a:hover, body.os-body .pagination > .active > span:hover { background: var(--os-accent) !important; border-color: var(--os-accent) !important; color: #FFFFFF !important; }
body.os-body .pagination > .disabled > a, body.os-body .pagination > .disabled > span, body.os-body .pagination > .disabled > a:hover, body.os-body .pagination > .disabled > span:hover { background: transparent !important; border-color: var(--os-line) !important; color: var(--os-faint) !important; }
/* select2 multiple: chosen items must read on the dark control */
body.os-body .select2-container--bootstrap .select2-selection--multiple .select2-selection__choice { background: var(--os-accent-soft) !important; border: 1px solid rgba(59, 107, 255, 0.35) !important; color: var(--os-ink-strong) !important; border-radius: 6px !important; padding: 1px 8px !important; margin: 5px 0 0 6px !important; font-size: 12px; }
body.os-body .select2-container--bootstrap .select2-selection--multiple .select2-selection__choice__remove { color: var(--os-muted) !important; margin-right: 4px; }
body.os-body .select2-container--bootstrap .select2-selection--multiple .select2-selection__choice__remove:hover { color: var(--os-danger) !important; }
body.os-body .select2-container--bootstrap .select2-selection--multiple .select2-search__field { color: var(--os-ink-strong); }
/* legacy modal forms: every control fills its column */
body.os-body .modal .input-icon > .form-control, body.os-body .modal .input-group > .form-control, body.os-body .modal .form-group .col-md-6 > .form-control, body.os-body .modal .select2-container { width: 100% !important; }
body.os-body .modal .input-icon { padding: 0 !important; position: relative; display: block; }
body.os-body .modal .input-icon > i { color: var(--os-muted); position: absolute; top: 50%; transform: translateY(-50%); margin: 0; left: 12px; }
body.os-body .modal .input-icon.right > i { left: auto; right: 12px; }
body.os-body .modal .input-icon.right > .form-control { padding-right: 12px; }
body.os-body .modal .form-horizontal .control-label { padding-top: 9px; }
body.os-body .modal .form-horizontal .form-group { margin-bottom: 16px; }
body.os-body .modal .help-block { min-height: 0; margin: 4px 0 0; }
body.os-body .modal .required, body.os-body .required { color: var(--os-danger); }
/* Metronic tabs-left (marker manager) */
body.os-body .nav-tabs.tabs-left { border-right: 1px solid var(--os-line); border-bottom: 0; }
body.os-body .nav-tabs.tabs-left > li > a { border-radius: 8px 0 0 8px; border: 0; color: var(--os-dim); }
body.os-body .nav-tabs.tabs-left > li.active > a, body.os-body .nav-tabs.tabs-left > li.active > a:hover { background: var(--os-hover); color: var(--os-ink-strong); border: 0; border-right: 2px solid var(--os-accent); margin-right: -1px; }
body.os-body .nav-tabs.tabs-left > li > a:hover { background: var(--os-hover); border: 0; }
body.os-body .tabs-left ~ .tab-content, body.os-body .tabbable-tabdrop .tab-content { border: 0; }
/* touchspin / input groups inside modals */
body.os-body .bootstrap-touchspin .input-group-btn .btn { border-radius: 8px; padding: 0 12px; height: 38px; }
body.os-body .noUi-target { background: rgba(255, 255, 255, 0.08); border: 0; box-shadow: none; }
body.os-body .noUi-connect { background: var(--os-accent); }
body.os-body .noUi-handle { background: #FFFFFF; border: 0; box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4); }
body.os-body .noUi-pips, body.os-body .noUi-value { color: var(--os-muted); }
body.os-body .noUi-marker { background: var(--os-line-3); }

/* ---------- TinyMCE 4 (lightgray skin) chrome in the dark theme; the document itself is
   styled by /js/layout/ocurus-tinymce-dark.js ---------- */
body.os-body .mce-tinymce { border: 1px solid var(--os-line-2) !important; border-radius: 8px; overflow: hidden; box-shadow: none !important; }
body.os-body .mce-container, body.os-body .mce-container *, body.os-body .mce-widget, body.os-body .mce-widget * { font-family: var(--os-font); }
/* the toolbar glyphs are an icon font — keep it */
body.os-body .mce-ico, body.os-body .mce-container .mce-ico, body.os-body .mce-widget .mce-ico { font-family: tinymce, Arial !important; }
body.os-body .mce-ico.mce-i-fa { font-family: FontAwesome !important; }
body.os-body .mce-panel { background: var(--os-card) !important; background-image: none !important; border-color: var(--os-line) !important; }
body.os-body .mce-toolbar-grp, body.os-body .mce-menubar, body.os-body .mce-statusbar { background: var(--os-rail) !important; border-color: var(--os-line) !important; }
body.os-body .mce-btn { background: transparent !important; background-image: none !important; border-color: transparent !important; box-shadow: none !important; border-radius: 6px; }
body.os-body .mce-btn:hover, body.os-body .mce-btn:active, body.os-body .mce-btn.mce-active, body.os-body .mce-btn.mce-active:hover { background: var(--os-hover) !important; border-color: var(--os-line-2) !important; }
body.os-body .mce-btn button, body.os-body .mce-ico, body.os-body .mce-btn .mce-txt, body.os-body .mce-menubtn button span { color: var(--os-dim) !important; text-shadow: none !important; }
body.os-body .mce-btn:hover .mce-ico, body.os-body .mce-btn.mce-active .mce-ico, body.os-body .mce-btn:hover .mce-txt { color: #FFFFFF !important; }
body.os-body .mce-btn.mce-disabled button, body.os-body .mce-btn.mce-disabled .mce-ico { color: var(--os-faint) !important; }
body.os-body .mce-caret { border-top-color: var(--os-muted) !important; }
body.os-body .mce-splitbtn .mce-open { border-left-color: var(--os-line) !important; }
body.os-body .mce-edit-area { background: #0D1220 !important; border-color: var(--os-line) !important; }
body.os-body .mce-edit-area iframe { background: #0D1220; }
body.os-light .mce-edit-area, body.os-light .mce-edit-area iframe { background: #FFFFFF !important; }
body.os-body .mce-statusbar .mce-path-item, body.os-body .mce-statusbar .mce-wordcount, body.os-body .mce-path .mce-divider { color: var(--os-muted) !important; }
body.os-body .mce-resizehandle .mce-ico { color: var(--os-faint) !important; }
/* floating pieces are appended to <body>: menus, tooltips, dialogs */
body.os-body .mce-menu { background: var(--os-card) !important; border: 1px solid var(--os-line-2) !important; border-radius: 10px; box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5) !important; padding: 6px !important; }
body.os-body .mce-menu-item { border-radius: 8px; }
body.os-body .mce-menu-item .mce-text, body.os-body .mce-menu-item .mce-ico, body.os-body .mce-menu-item .mce-menu-shortcut { color: var(--os-dim) !important; text-shadow: none !important; }
body.os-body .mce-menu-item:hover, body.os-body .mce-menu-item.mce-selected, body.os-body .mce-menu-item:focus { background: var(--os-accent) !important; }
body.os-body .mce-menu-item:hover .mce-text, body.os-body .mce-menu-item.mce-selected .mce-text, body.os-body .mce-menu-item:hover .mce-ico { color: #FFFFFF !important; }
body.os-body .mce-menu-item-sep, body.os-body .mce-menu-item-sep:hover { background: var(--os-line) !important; border: 0 !important; }
body.os-body .mce-menu-item-preview.mce-active { border-left-color: var(--os-accent) !important; }
body.os-body .mce-floatpanel { background: var(--os-card) !important; border-color: var(--os-line-2) !important; }
body.os-body .mce-tooltip-inner { background: #0A0E17 !important; color: #E6EAF2 !important; border-radius: 6px; font-family: var(--os-font); }
body.os-body .mce-tooltip-arrow { border-top-color: #0A0E17 !important; border-bottom-color: #0A0E17 !important; }
body.os-body .mce-window { background: var(--os-card) !important; border: 1px solid var(--os-line-2) !important; border-radius: 14px !important; box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6) !important; }
body.os-body .mce-window-head { background: transparent !important; border-bottom: 1px solid var(--os-line) !important; }
body.os-body .mce-window-head .mce-title { color: #FFFFFF !important; font-weight: 600; }
body.os-body .mce-window-head .mce-close i { color: var(--os-muted) !important; }
body.os-body .mce-window .mce-foot { border-top: 1px solid var(--os-line) !important; background: transparent !important; }
body.os-body .mce-textbox, body.os-body .mce-combobox input { background: var(--os-input) !important; color: var(--os-ink-strong) !important; border: 1px solid var(--os-line-2) !important; border-radius: 8px !important; box-shadow: none !important; }
body.os-body .mce-textbox:focus, body.os-body .mce-combobox input:focus { border-color: var(--os-accent) !important; }
body.os-body .mce-label { color: var(--os-dim) !important; text-shadow: none !important; }
body.os-body .mce-listbox { background: var(--os-input) !important; border-color: var(--os-line-2) !important; }
body.os-body .mce-listbox button { color: var(--os-ink-strong) !important; }
body.os-body .mce-checkbox .mce-i-checkbox { background: var(--os-input) !important; border-color: var(--os-line-3) !important; color: #FFFFFF !important; box-shadow: none !important; }
body.os-body .mce-checkbox.mce-checked .mce-i-checkbox { background: var(--os-accent) !important; border-color: var(--os-accent) !important; }
body.os-body .mce-btn.mce-primary { background: var(--os-accent) !important; border-color: var(--os-accent) !important; }
body.os-body .mce-btn.mce-primary button, body.os-body .mce-btn.mce-primary .mce-txt { color: #FFFFFF !important; }
body.os-body .mce-window .mce-btn:not(.mce-primary) { border: 1px solid var(--os-line-3) !important; }
body.os-body .mce-tabs { border-bottom: 1px solid var(--os-line) !important; background: transparent !important; }
body.os-body .mce-tab { background: transparent !important; border-color: transparent !important; color: var(--os-dim) !important; }
body.os-body .mce-tab.mce-active { color: #FFFFFF !important; border-bottom: 2px solid var(--os-accent) !important; }
body.os-body .mce-throbber { background-color: rgba(10, 14, 23, 0.7) !important; }
body.os-body #mce-modal-block { background: #04070E !important; }

/* ---------- Analytics page inside the studio: re-point its tokens at the dark theme ---------- */
body.os-body:not(.os-light) .an-page {
  --an-surface: var(--os-card);
  --an-ink: var(--os-ink-strong);
  --an-ink-2: var(--os-dim);
  --an-muted: var(--os-muted);
  --an-grid: rgba(255, 255, 255, 0.08);
  --an-axis: rgba(255, 255, 255, 0.2);
  --an-border: var(--os-line);
  --an-series-1: #3B6BFF;
  --an-series-2: #FF9E52;
  --an-up: #4ADE80;
  --an-down: #F87171;
  --an-wash: rgba(59, 107, 255, 0.10);
}
body.os-body:not(.os-light) .an-page .an-tile,
body.os-body:not(.os-light) .an-page .an-portlet { background: var(--os-card); border-color: var(--os-line); }
body.os-body:not(.os-light) .an-page .an-portlet .portlet-title { border-bottom-color: var(--os-line); }
body.os-body:not(.os-light) .an-page .form-control { background: var(--os-input); border-color: var(--os-line-2); color: var(--os-ink-strong); border-radius: 10px; height: 40px; box-shadow: none; }
body.os-body:not(.os-light) .an-page .form-control option { background: var(--os-card); }
body.os-body:not(.os-light) .an-page .btn-default { background: transparent; border-color: var(--os-line-3); color: var(--os-dim); border-radius: 10px; }
body.os-body:not(.os-light) .an-page .an-toggle-table[aria-pressed="true"] { background: var(--os-accent-soft); border-color: rgba(59, 107, 255, 0.4); color: var(--os-accent-ink); }
body.os-body:not(.os-light) .an-page .an-legend-item:hover { background: rgba(255, 255, 255, 0.06); }
body.os-body:not(.os-light) .an-page .an-tooltip { box-shadow: var(--os-shadow); }
body.os-body:not(.os-light) .an-page .an-empty, body.os-body:not(.os-light) .an-page .an-error { background: rgba(17, 24, 39, 0.85); }
body.os-body:not(.os-light) .an-page .table-striped > tbody > tr:nth-of-type(odd) { background: rgba(255, 255, 255, 0.03); }
body.os-body:not(.os-light) .an-page .an-table th, body.os-body:not(.os-light) .an-page .an-table td { color: var(--os-ink); }
body.os-body:not(.os-light) .an-page .an-tour-track { background: transparent; }
body.os-body:not(.os-light) .an-page .an-library-item > i { color: var(--os-accent-ink); }
body.os-body .an-page .an-filters label { color: var(--os-muted); }
body.os-body .an-page { --an-radius: 14px; }
body.os-body .an-page .an-tile, body.os-body .an-page .an-portlet { border-radius: 14px; }
