/* TrustedIdentity UI skin (local, no external deps).
   Designed to work alongside vendored Martex CSS. */

:root {
  --ti-font: var(--font-Jakarta, system-ui, -apple-system, "Segoe UI", Roboto, Arial);
  --ti-bg: #f8fafc;
  --ti-card: #ffffff;
  --ti-text: #0f172a;
  --ti-muted: #64748b;
  --ti-border: rgba(15, 23, 42, 0.10);
  --ti-shadow: 0 24px 70px rgba(2, 6, 23, 0.10);
  --ti-primary: #111827;
  --ti-primary-2: #374151;
}

html, body {
  font-family: var(--ti-font);
  color: var(--ti-text);
  font-size: 14px;
  background: var(--ti-bg);
}

body {
  margin: 0;
}

/* Heading hierarchy: h1 = 26px, others proportional */
h1 {
  font-size: 26px;
  line-height: 1.2;
  font-weight: 900;
  margin: 0.67em 0;
}

h2 {
  font-size: 22px;
  line-height: 1.3;
  font-weight: 800;
  margin: 0.75em 0;
}

h3 {
  font-size: 19px;
  line-height: 1.35;
  font-weight: 700;
  margin: 0.83em 0;
}

h4 {
  font-size: 17px;
  line-height: 1.4;
  font-weight: 700;
  margin: 1em 0;
}

h5 {
  font-size: 15px;
  line-height: 1.45;
  font-weight: 600;
  margin: 1.1em 0;
}

h6 {
  font-size: 13px;
  line-height: 1.5;
  font-weight: 600;
  margin: 1.2em 0;
}

/* Fix "stuck together" links even if flex/gap utilities fail */
.ti-nav a + a,
.ti-footer-links a + a,
.nav a + a {
  margin-left: 14px;
}

/* Public shell */
.ti-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.ti-topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.78);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--ti-border);
}

.ti-topbar.ti-topbar-dark {
  background:
    radial-gradient(1200px 500px at 15% 15%, rgba(99, 102, 241, 0.22), rgba(0,0,0,0)),
    radial-gradient(900px 420px at 80% 30%, rgba(168, 85, 247, 0.18), rgba(0,0,0,0)),
    linear-gradient(180deg, #0b0c24 0%, #07081a 55%, #07081a 100%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.10);
}

.ti-topbar.ti-topbar-dark .ti-brand,
.ti-topbar.ti-topbar-dark .ti-nav a {
  color: rgba(255, 255, 255, 0.92);
}

.ti-topbar.ti-topbar-dark .ti-nav a:hover {
  background: rgba(255, 255, 255, 0.10);
  color: #fff !important;
  border-color: rgba(255, 255, 255, 0.14);
}

.ti-topbar .ti-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.ti-container {
  max-width: 1100px;
  margin: 0 auto;width:100%;
  padding: 18px 20px;
}

.ti-container.ti-full {
  max-width: 100%;
  padding-left: 26px;
  padding-right: 26px;
}

/* Tighter vertical padding in header only */
.ti-topbar .ti-container {
  padding-top: 10px;
  padding-bottom: 10px;
}
.ti-brand.ti-brand-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.ti-logo {
  width: auto;
  height: 30px;
  display: inline-block;
}

.ti-logo-light {
  display: inline-block;
}

.ti-logo-dark { display: none; }

.ti-container.ti-wide {
  max-width: 1400px;
}

.ti-brand {
  font-weight: 900;
  letter-spacing: -0.02em;
  text-decoration: none;
  color: var(--ti-text);
}

.ti-nav {font-size:12px;font-weight:600 !important;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.ti-nav a {font-size:13px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 12px;
  border-radius: 12px;
  border: 1px solid transparent;
  text-decoration: none;
  font-weight: 600;
  color: var(--ti-text);
}

.ti-nav a:hover {
  background: rgba(15, 23, 42, 0.04);
  border-color: rgba(15, 23, 42, 0.08);
}

.ti-hero {
  padding: 26px 0 10px 0;
}

/* For pages that render their own full-bleed hero (e.g., homepage). */
.ti-hero.ti-hero-flush {
  padding: 0;
}

/* Home hero (dark, "Mifty-like") */
.ti-home-hero {
  position: relative;
  padding: 84px 0 0 0;
  background:
    radial-gradient(1200px 500px at 15% 15%, rgba(99, 102, 241, 0.22), rgba(0,0,0,0)),
    radial-gradient(900px 420px at 80% 30%, rgba(168, 85, 247, 0.18), rgba(0,0,0,0)),
    linear-gradient(180deg, #0b0c24 0%, #07081a 55%, #07081a 100%);
  overflow: hidden;
}

.ti-home-hero:before {
  content: "";
  position: absolute;
  inset: -200px -200px auto -200px;
  height: 520px;
  background: radial-gradient(closest-side, rgba(255,255,255,0.08), rgba(0,0,0,0));
  transform: translateY(40px);
  pointer-events: none;
}

.ti-container.ti-wide {
  max-width: 1200px;
}

.ti-home-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 28px;
  align-items: center;
}

@media (max-width: 980px) {
  .ti-home-grid {
    grid-template-columns: 1fr;
  }
}

.ti-home-left {
  min-width: 0;
}

.ti-home-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(245, 158, 11, 0.65);
  background: rgba(245, 158, 11, 0.12);
  color: rgba(255,255,255,0.95);
  font-weight: 900;
  font-size: 12px;
  letter-spacing: 0.02em;
}

.ti-home-title {
  margin: 16px 0 0 0;
  font-size: 54px;
  line-height: 1.33;
  font-weight: 950;
  /* letter-spacing: -0.03em; */
  color: rgba(255,255,255,0.98);
}

/* Marketing sections (homepage) */
.ti-section {
  padding: 14px 0 0 0;
}

.ti-section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.ti-section-title {
  font-weight: 950;
  font-size: 18px;
  letter-spacing: -0.02em;
  margin: 0;
}

.ti-section-sub {
  margin: 6px 0 0 0;
  color: var(--ti-muted);
  max-width: 78ch;
}

.ti-feature-card {
  background: #fff;
  display: grid;
  gap: 10px;
}

.ti-feature-ico {
  width: 40px;
  height: 40px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(15, 23, 42, 0.04);
  border: 1px solid rgba(15, 23, 42, 0.06);
  font-size: 18px;
}

.ti-feature-title {
  font-weight: 950;
  font-size: 15px;
  letter-spacing: -0.01em;
}

.ti-steps {
  counter-reset: ti_step;
  display: grid;
  gap: 12px;
}

.ti-step {
  counter-increment: ti_step;
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 12px;
  align-items: start;
  border: 1px solid var(--ti-border);
  background: #fff;
  border-radius: 16px;
  padding: 14px;
}

.ti-step:before {
  content: counter(ti_step);
  width: 40px;
  height: 40px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 950;
  color: #fff;
  background: linear-gradient(180deg, #6366f1, #8b5cf6);
}
@media (max-width: 620px) {
  .ti-home-title {
    font-size: 38px;
  }
}

.ti-home-sub {
  margin: 14px 0 0 0;
  color: rgba(226, 232, 240, 0.82);
  font-size: 16px;
  line-height: 1.6;
  max-width: 58ch;
}

.ti-home-ctas {
  margin-top: 22px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.ti-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 16px;
  border-radius: 14px;
  font-weight: 900;
  text-decoration: none;
  border: 1px solid rgba(255,255,255,0.18);
  background: rgba(255,255,255,0.06);
  color: rgba(255,255,255,0.92);
}

.ti-btn:hover {
  background: rgba(255,255,255,0.10);
}

.ti-btn-primary {
  background: #6366f1;
  border-color: #6366f1;
  color: #fff;
  box-shadow: 0 18px 55px rgba(99, 102, 241, 0.22);
}

.ti-btn-primary:hover {
  background: #5458f0;
  border-color: #5458f0;
}

.ti-btn-ghost {
  background: rgba(255,255,255,0.04);
}

.ti-home-preview {
  border-radius: 18px;
  border: 1px solid rgba(255,255,255,0.10);
  background: rgba(255,255,255,0.04);
  box-shadow: 0 30px 90px rgba(0,0,0,0.45);
  padding: 14px;
}

.ti-home-preview img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 14px;
}

.ti-home-wave {
  position: relative;
  display: block;
  width: 100%;
  height: 120px;
  margin-top: 40px;
}

.ti-card {
  background: var(--ti-card);
  border: 1px solid var(--ti-border);
  border-radius: 18px;
  box-shadow: var(--ti-shadow);
}

.ti-card-pad {
  padding: 22px;
}

@media (min-width: 860px) {
  .ti-card-pad {
    padding: 34px;
  }
}

.ti-muted {
  color: var(--ti-muted);
}

.ti-actions a,
.ti-actions button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 14px;
  border-radius: 14px;
  font-weight: 900;
  text-decoration: none;
  border: 1px solid var(--ti-border);
  background: #fff;
  color: var(--ti-text);
}

.ti-actions a.primary {
  background: var(--ti-primary);
  border-color: var(--ti-primary);
  color: #fff;
}

.ti-actions a.primary:hover {
  background: var(--ti-primary-2);
  border-color: var(--ti-primary-2);
}

.ti-actions a:hover {
  background: rgba(15, 23, 42, 0.04);
}

.ti-footer {
  margin-top: auto;
  border-top: 1px solid var(--ti-border);
}

/* Small UI helpers */
.ti-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: 999px;
  border: 1px solid var(--ti-border);
  background: rgba(255, 255, 255, 0.85);
  font-size: 12px;
  font-weight: 800;
  color: var(--ti-text);
}

.ti-grid {
  display: grid;
  gap: 12px;
}

.ti-grid.cols-4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.ti-grid.cols-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (max-width: 980px) {
  .ti-grid.cols-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 620px) {
  .ti-grid.cols-4,
  .ti-grid.cols-2 {
    grid-template-columns: 1fr;
  }
}

.ti-metric {
  border: 1px solid var(--ti-border);
  background: linear-gradient(180deg, rgba(248, 250, 252, 0.75), #ffffff);
  border-radius: 16px;
  padding: 14px 14px 16px 14px;
}

.ti-k {
  font-size: 11px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--ti-muted);
  font-weight: 900;
}

.ti-v {
  font-size: 30px;
  line-height: 1.05;
  margin-top: 8px;
  font-weight: 900;
}

.ti-footer-links a {
  text-decoration: none;
  color: var(--ti-muted);
  font-weight: 700;
}

.ti-footer-links a:hover {
  color: var(--ti-text);
  text-decoration: underline;
}

/* Auth pages */
.ti-auth {
  display: grid;
  grid-template-columns: 1fr 1fr;
  overflow: hidden;
  border-radius: 18px;
}

@media (max-width: 860px) {
  .ti-auth {
    grid-template-columns: 1fr;
  }
}

.ti-auth-side {
  min-height: 520px;
  background: #0b1220;
  background-position: center;
  background-size: cover;
}

@media (max-width: 860px) {
  .ti-auth-side {
    min-height: 220px;
  }
}

.ti-auth-form {
  padding: 26px;
  background: #fff;
}

@media (min-width: 860px) {
  .ti-auth-form {
    padding: 34px;
  }
}

.ti-field {
  margin-top: 12px;
}

.ti-label {
  display: block;
  font-weight: 900;
  font-size: 13px;
  margin-bottom: 8px;
  color: var(--ti-text);
}

.ti-input {
  width: 100%;
  box-sizing: border-box;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid rgba(15, 23, 42, 0.14);
  background: #ffffff;
  font-size: 14px;
  outline: none;
}

.ti-input:focus {
  border-color: rgba(22, 128, 251, 0.75);
  box-shadow: 0 0 0 4px rgba(22, 128, 251, 0.12);
}

.ti-form-actions {
  margin-top: 16px;
  display: grid;
  gap: 10px;
}

.ti-hint {
  margin-top: 12px;
  font-size: 13px;
  color: var(--ti-muted);
}

.ti-hint a {
  color: #0b64d3;
  font-weight: 800;
  text-decoration: none;
}

.ti-hint a:hover {
  text-decoration: underline;
}

.ti-alert {
  margin-top: 12px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid var(--ti-border);
  font-size: 13px;
  font-weight: 700;
}

.ti-alert--error {
  background: #fef2f2;
  border-color: rgba(220, 38, 38, 0.25);
  color: #991b1b;
}

.ti-alert--success {
  background: #ecfdf5;
  border-color: rgba(16, 185, 129, 0.25);
  color: #065f46;
}

/* Admin pages (existing HTML uses .nav, .card, etc) */
.nav {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  padding: 14px 16px;
  margin-bottom: 18px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid var(--ti-border);
  border-radius: 16px;
  backdrop-filter: blur(10px);
}

.nav a {
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
  border-radius: 12px;
  text-decoration: none;
  font-weight: 900;
  color: var(--ti-text);
  border: 1px solid transparent;
}

.nav a:hover {
  background: rgba(15, 23, 42, 0.04);
  border-color: rgba(15, 23, 42, 0.08);
}

.card {
  background: var(--ti-card);
  border-radius: 16px;
  box-shadow: 0 18px 55px rgba(2, 6, 23, 0.08);
}

table th {
  font-weight: 900;
}

/* Admin shell (sidebar + profile dropdown) */
:root {
  --ti-sidebar-w: 290px;
  --ti-topbar-h: 66px;
}

.ti-admin-body {
  margin: 0;
  min-height: 100vh;
}

.ti-admin-sidebar {
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  width: var(--ti-sidebar-w);
  background: rgba(255, 255, 255, 0.92);
  border-right: 1px solid var(--ti-border);
  padding: 18px 14px;
  overflow: auto;
  z-index: 40;
}

.ti-admin-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 10px 16px 10px;
  border-bottom: 1px solid rgba(15, 23, 42, 0.06);
  margin-bottom: 14px;
}

.ti-admin-nav {
  display: grid;
  gap: 6px;
}

.ti-admin-page {
  margin-left: var(--ti-sidebar-w);
  min-height: 100vh;
}

.ti-admin-topbar {
  position: sticky;
  top: 0;
  min-height: var(--ti-topbar-h);
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 16px;
}

.ti-admin-title {
  font-weight: 900;
  font-size: 18px;
  letter-spacing: -0.01em;
  color: rgba(255, 255, 255, 0.92);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ti-topbar.ti-topbar-dark .ti-icon-btn {
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.92);
}

.ti-topbar.ti-topbar-dark .ti-icon-btn:hover {
  background: rgba(255, 255, 255, 0.12);
}

.ti-topbar.ti-topbar-dark .ti-profile-btn {
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.92);
}

.ti-topbar.ti-topbar-dark .ti-profile-btn:hover {
  background: rgba(255, 255, 255, 0.12);
}

.ti-topbar.ti-topbar-dark .ti-actions a,
.ti-topbar.ti-topbar-dark .ti-actions button {
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.92);
}

.ti-topbar.ti-topbar-dark .ti-actions a:hover,
.ti-topbar.ti-topbar-dark .ti-actions button:hover {
  background: rgba(255, 255, 255, 0.12);
}
.ti-icon-btn {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  border: 1px solid rgba(15, 23, 42, 0.10);
  background: rgba(255, 255, 255, 0.92);
  cursor: pointer;
  font-weight: 900;
}

.ti-icon-btn:hover {
  background: #fff;
}

.ti-sidebar-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(2, 6, 23, 0.45);
  z-index: 35;
}

.ti-admin-content-wrap {
  padding: 18px 18px 28px 18px;
}

.ti-ico {
  width: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.ti-side-link {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid transparent;
  text-decoration: none;
  font-weight: 900;
  color: var(--ti-text);
}

.ti-side-link:hover {
  background: rgba(15, 23, 42, 0.04);
  border-color: rgba(15, 23, 42, 0.08);
}

.ti-side-link.active {
  background: rgba(15, 23, 42, 0.06);
  border-color: rgba(15, 23, 42, 0.12);
}

.ti-admin-content {
  min-width: 0;
}

.ti-admin-content .card {
  border: 1px solid rgba(15, 23, 42, 0.10);
  border-radius: 16px;
  padding: 16px;
  margin-top: 16px;
}

.ti-admin-content label {
  display: block;
  margin-top: 10px;
  font-weight: 900;
}

.ti-admin-content input,
.ti-admin-content select,
.ti-admin-content textarea {
  width: 100%;
  padding: 10px;
  border: 1px solid rgba(15, 23, 42, 0.12);
  border-radius: 12px;
  background: #fff;
}

.ti-admin-content button,
.ti-admin-content .btn {
  margin-top: 12px;
  padding: 10px 14px;
  border: 0;
  border-radius: 12px;
  background: #111827;
  color: #fff;
  font-weight: 900;
  cursor: pointer;
}

.ti-admin-content button.secondary,
.ti-admin-content .btn.secondary {
  background: #374151;
}

.ti-admin-content table {
  width: 100%;
  border-collapse: collapse;
}

.ti-admin-content th,
.ti-admin-content td {
  border-bottom: 1px solid rgba(15, 23, 42, 0.10);
  padding: 8px;
  text-align: left;
  font-size: 13px;
  vertical-align: top;
}

.ti-admin-content th {
  background: #f8fafc;
}

.ti-admin-content .muted {
  color: var(--ti-muted);
  font-size: 13px;
}

.ti-admin-content .row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

@media (max-width: 820px) {
  .ti-admin-content .row {
    grid-template-columns: 1fr;
  }
}

.ti-admin-profile {
  position: relative;
}

.ti-profile-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 999px;
  border: 1px solid rgba(15, 23, 42, 0.10);
  background: rgba(255, 255, 255, 0.92);
  cursor: pointer;
  font-weight: 900;
  color: var(--ti-text);
}

.ti-profile-btn:hover {
  background: #ffffff;
}

.ti-avatar {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(180deg, #0f172a, #334155);
  color: #fff;
  font-weight: 900;
  font-size: 14px;
  letter-spacing: 0.02em;
}

.ti-profile-name {
  max-width: 240px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ti-profile-menu {
  position: absolute;
  right: 0;
  top: calc(100% + 10px);
  width: 240px;
  background: #ffffff;
  border: 1px solid var(--ti-border);
  border-radius: 16px;
  box-shadow: 0 18px 55px rgba(2, 6, 23, 0.10);
  overflow: hidden;
}

.ti-profile-menu a {
  display: block;
  padding: 10px 12px;
  text-decoration: none;
  font-weight: 900;
  color: var(--ti-text);
  border-top: 1px solid rgba(15, 23, 42, 0.06);
}

.ti-profile-menu a:first-child {
  border-top: 0;
}

.ti-profile-menu a:hover {
  background: rgba(15, 23, 42, 0.04);
}

.ti-profile-meta {
  padding: 12px;
  background: rgba(248, 250, 252, 0.85);
  border-bottom: 1px solid rgba(15, 23, 42, 0.06);
}

.ti-profile-meta .ti-muted {
  font-size: 12px;
}

/* Slide-over panel (used by Admin Users edit) */
.ti-slide-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(2, 6, 23, 0.45);
  /* Must be above admin sidebar/topbar stacking contexts */
  z-index: 5000;
}

.ti-slide-panel {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(560px, 92vw);
  background: #ffffff;
  border-left: 1px solid var(--ti-border);
  box-shadow: 0 18px 55px rgba(2, 6, 23, 0.18);
  /* Must be above admin sidebar/topbar stacking contexts */
  z-index: 5100;
  transform: translateX(102%);
  transition: transform 180ms ease;
  overflow: auto;
}

.ti-slide-header {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.90);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(15, 23, 42, 0.10);
}

body.ti-slide-open .ti-slide-panel {
  transform: translateX(0);
}

/* Modal (Create user) */
.ti-modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(2, 6, 23, 0.45);
  /* Keep modal above sticky topbar/sidebar even with stacking contexts */
  z-index: 6000;
}

.ti-modal {
  position: fixed;
  inset: 0;
  /* Keep modal above sticky topbar/sidebar even with stacking contexts */
  z-index: 6100;
  display: grid;
  place-items: center;
  padding: 18px;
  pointer-events: none;
}

.ti-modal[aria-hidden="false"] {
  pointer-events: auto;
}

.ti-modal-card {
  width: min(860px, 96vw);
  background: #ffffff;
  border: 1px solid var(--ti-border);
  border-radius: 18px;
  box-shadow: 0 24px 70px rgba(2, 6, 23, 0.18);
  overflow: hidden;
  transform: translateY(8px);
  opacity: 0;
  transition: transform 160ms ease, opacity 160ms ease;
}

.ti-modal[aria-hidden="false"] .ti-modal-card {
  transform: translateY(0);
  opacity: 1;
}

.ti-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.90);
  border-bottom: 1px solid rgba(15, 23, 42, 0.10);
}

body.ti-modal-open {
  overflow: hidden;
}

/* Pre blocks inside panels/modals */
.ti-pre {
  margin: 10px 0 0 0;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(15, 23, 42, 0.10);
  background: rgba(248, 250, 252, 0.9);
  white-space: pre-wrap;
  word-break: break-word;
  font-size: 12px;
  line-height: 1.35;
}

@media (max-width: 980px) {
  .ti-admin-sidebar {
    transform: translateX(-102%);
    transition: transform 160ms ease;
    width: min(86vw, var(--ti-sidebar-w));
    box-shadow: 0 18px 55px rgba(2, 6, 23, 0.18);
  }
  .ti-admin-page {
    margin-left: 0;
  }
  body.ti-sidebar-open .ti-admin-sidebar {
    transform: translateX(0);
  }
  body.ti-sidebar-open .ti-sidebar-backdrop {
    display: block;
  }
  .ti-profile-name {
    max-width: 120px;
  }
}

