/* ============================================================
   TEKEVER GRAPHICAL CHARTER — LibreChat Theme Override
   Version 2.0 | Applied via dist/assets/custom.css
   No source code fork required.
   ============================================================ */

/* Fonts loaded via index.html <link> tags for non-blocking render */

/* --- DARK MODE TOKEN OVERRIDES ----------------------------- */
/* LibreChat scopes dark mode under .dark, not :root */
.dark {
  /* Surface colours — deeper blacks, TEKEVER aesthetic */
  --gray-900: #0A0A0A;
  --gray-800: #111111;
  --gray-700: #1A1A1A;
  --gray-600: #222222;
  --gray-500: #666666;
  --gray-400: #888888;
  --gray-300: #AAAAAA;
  --gray-200: #CCCCCC;
  --gray-100: #F5F5F5;
  --gray-50:  #FAFAFA;

  /* Surface tokens */
  --surface-primary:    #0A0A0A;
  --surface-secondary:  #111111;
  --surface-tertiary:   #1A1A1A;

  /* Border tokens */
  --border-light:   rgba(255, 255, 255, 0.06);
  --border-medium:  rgba(255, 255, 255, 0.10);
  --border-heavy:   rgba(255, 255, 255, 0.15);
  --border-xheavy:  rgba(255, 255, 255, 0.20);

  /* Shadcn/Radix HSL tokens */
  --background:           0 0% 4%;
  --foreground:           0 0% 96%;
  --primary:              4 77% 46%;         /* #D42718 */
  --primary-foreground:   0 0% 98%;
  --accent:               0 0% 8%;
  --accent-foreground:    0 0% 96%;
  --muted:                0 0% 8%;
  --muted-foreground:     0 0% 55%;
  --border:               0 0% 14%;
  --card:                 0 0% 6%;
  --card-foreground:      0 0% 96%;
  --input:                0 0% 14%;
  --ring:                 4 77% 46%;
  --radius:               0.75rem;

  /* LibreChat-specific surface tokens */
  --surface-submit:       #D42718;
  --surface-submit-hover: #A81E10;
  --surface-active:       #D42718;
  --surface-active-alt:   #A81E10;
  --surface-hover:        #1A1A1A;
  --surface-hover-alt:    #202020;
  --header-hover:         #1A1A1A;
  --header-button-hover:  #1A1A1A;
  --border-medium-alt:    rgba(255, 255, 255, 0.10);
  --text-primary:         #F5F5F5;
  --text-secondary:       rgba(255, 255, 255, 0.55);
  --text-tertiary:        rgba(255, 255, 255, 0.35);
}

/* Also override :root for tokens that aren't scoped to .dark */
:root {
  --tekever-red:      #D42718;
  --tekever-red-dark: #A81E10;
}

/* --- SMOOTH HOVER TRANSITIONS ------------------------------ */
/* Tailwind hover utilities don't include transitions by default */
.hover\:bg-surface-active-alt,
.hover\:bg-surface-active {
  transition: background-color 0.2s ease !important;
}

/* --- TYPOGRAPHY -------------------------------------------- */
body,
html {
  font-family: 'Roboto', -apple-system, BlinkMacSystemFont, sans-serif !important;
}

h1, h2, h3, h4 {
  font-family: 'Roboto', sans-serif !important;
  font-weight: 500;
  letter-spacing: -0.01em;
}

/* --- SIDEBAR ----------------------------------------------- */
/* Left sidebar — darker than main content */
.dark nav,
.dark [class*="bg-token-surface-primary"] nav,
.dark aside {
  background-color: #080808 !important;
}

/* Sidebar items hover */
.dark nav a:hover,
.dark nav button:hover {
  background-color: #1A1A1A !important;
}

/* --- HEADER BAR -------------------------------------------- */
.dark .sticky.top-0,
.dark header {
  background-color: rgba(10, 10, 10, 0.90) !important;
  backdrop-filter: blur(12px) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06) !important;
}

/* --- MAIN CONTENT AREA ------------------------------------- */
.dark main,
.dark [class*="bg-token-surface-secondary"] {
  background-color: #0F0F0F !important;
}

/* --- SUBMIT / SEND BUTTON ---------------------------------- */
button[data-testid="send-button"],
button[aria-label*="Send"],
.dark [class*="bg-token-surface-submit"] {
  background-color: #D42718 !important;
  color: #FFFFFF !important;
  border-radius: 50px !important;
  transition: background-color 0.2s ease, box-shadow 0.2s ease !important;
}

button[data-testid="send-button"]:hover,
button[aria-label*="Send"]:hover,
.dark [class*="bg-token-surface-submit"]:hover {
  background-color: #A81E10 !important;
}

/* --- ACTIVE TABS / SELECTION ------------------------------- */
[role="tab"][data-state="active"],
.dark [role="tab"][data-state="active"] {
  background-color: #D42718 !important;
  color: #FFFFFF !important;
  border-radius: 50px !important;
}

/* Tab pills — rounded style */
[role="tab"],
.dark [role="tab"] {
  border-radius: 50px !important;
  transition: background-color 0.2s ease, color 0.2s ease !important;
}

/* --- AGENT CARDS ------------------------------------------- */
.dark [data-testid*="agent-card"],
.dark .group.relative.overflow-hidden {
  background-color: #141414 !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  border-radius: 16px !important;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.dark [data-testid*="agent-card"]:hover,
.dark .group.relative.overflow-hidden:hover {
  border-color: #D42718 !important;
  background-color: #1A1010 !important;
}

/* --- CHAT INPUT -------------------------------------------- */
.dark textarea,
.dark [data-testid*="text-input"],
.dark [class*="chat-input"] {
  background-color: #141414 !important;
  border: 1px solid rgba(255, 255, 255, 0.10) !important;
  border-radius: 24px !important;
}

.dark textarea:focus,
.dark [data-testid*="text-input"]:focus-within {
  border-color: #D42718 !important;
  box-shadow: 0 0 0 2px rgba(212, 39, 24, 0.20) !important;
}

/* --- SEARCH INPUT ------------------------------------------ */
.dark input[placeholder*="Search"],
.dark input[type="search"] {
  background-color: #141414 !important;
  border: 1px solid rgba(255, 255, 255, 0.10) !important;
  border-radius: 50px !important;
}

.dark input[placeholder*="Search"]:focus,
.dark input[type="search"]:focus {
  border-color: #D42718 !important;
  box-shadow: 0 0 0 2px rgba(212, 39, 24, 0.20) !important;
}

/* --- LINKS & INTERACTIVE TEXT ------------------------------ */
.dark a:hover {
  color: #E8453A !important;
}

/* --- SCROLLBAR --------------------------------------------- */
.dark ::-webkit-scrollbar {
  width: 6px;
}

.dark ::-webkit-scrollbar-track {
  background: #0A0A0A;
}

.dark ::-webkit-scrollbar-thumb {
  background: #2A2A2A;
  border-radius: 3px;
}

.dark ::-webkit-scrollbar-thumb:hover {
  background: #D42718;
}

/* --- DROPDOWNS / POPOVER MENUS ----------------------------- */
.dark [data-radix-popper-content-wrapper] > div,
.dark [role="menu"],
.dark [role="listbox"] {
  background-color: #141414 !important;
  border: 1px solid rgba(255, 255, 255, 0.10) !important;
  border-radius: 12px !important;
}

/* Dropdown items hover */
.dark [role="menuitem"]:hover,
.dark [role="option"]:hover,
.dark [role="option"][data-highlighted] {
  background-color: #1A1A1A !important;
}

/* --- DIALOG / MODAL ---------------------------------------- */
.dark [role="dialog"] {
  background-color: #111111 !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  border-radius: 16px !important;
}

/* --- CONVERSATION LIST ITEMS ------------------------------- */
.dark nav a[class*="bg-token-surface"] {
  border-radius: 8px !important;
}

/* Active conversation — subtle red accent */
.dark nav a[class*="bg-token-surface-tertiary"],
.dark nav a.bg-token-surface-tertiary {
  background-color: rgba(212, 39, 24, 0.08) !important;
  border-left: 2px solid #D42718 !important;
}

/* --- USER AVATAR ------------------------------------------- */
.dark img[alt*="avatar"],
.dark [class*="avatar"] img {
  border: 2px solid #D42718 !important;
  border-radius: 50% !important;
}

/* --- LOGIN PAGE --------------------------------------------- */
/* Hide the default LibreChat SVG icon */
.min-h-screen svg {
  display: none !important;
}

/* Make the login page a single centered column */
.min-h-screen {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
}

/* Hide left decorative panel entirely */
.min-h-screen > div:first-child:not(:last-child) {
  display: none !important;
}

/* Center the right-side form panel */
.min-h-screen > div:last-child {
  width: 100% !important;
  max-width: 420px !important;
  padding: 2rem !important;
}

/* Add TEKEVER logo above the form via pseudo-element */
.min-h-screen > div:last-child::before {
  content: '';
  display: block;
  width: 180px;
  height: 48px;
  margin: 0 auto 2rem auto;
  background-image: url('/assets/logo-red.svg');
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}

/* --- LIGHT MODE TEKEVER OVERRIDES -------------------------- */
/* For users who haven't set dark mode yet */
:root {
  --tekever-red:      #D42718;
  --tekever-red-dark: #A81E10;
  --primary:          4 77% 46%;
  --primary-foreground: 0 0% 98%;
  --ring:             4 77% 46%;
}

/* Light mode: red buttons and accents */
button[data-testid="send-button"],
button[aria-label*="Send"] {
  background-color: #D42718 !important;
  color: #FFFFFF !important;
  border-radius: 50px !important;
}

button[data-testid="send-button"]:hover,
button[aria-label*="Send"]:hover {
  background-color: #A81E10 !important;
}

/* Light mode active tabs */
[role="tab"][data-state="active"] {
  background-color: #D42718 !important;
  color: #FFFFFF !important;
  border-radius: 50px !important;
}

/* Light mode focus rings */
textarea:focus,
input:focus {
  border-color: #D42718 !important;
  box-shadow: 0 0 0 2px rgba(212, 39, 24, 0.15) !important;
  outline: none !important;
}

/* Kill browser default focus outline on all inputs */
input,
textarea,
select {
  outline: none !important;
  outline-offset: 0 !important;
}

/* --- RED TEKEVER LOGO ABOVE MAIN CONTENT ------------------- */
/* Inject red TEKEVER logo above the Agent Marketplace heading — only in chat, not login */
body:not(:has(.min-h-screen)) main::before {
  content: '';
  display: block;
  width: 160px;
  height: 44px;
  margin: 24px auto 0 auto;
  background-image: url('/assets/logo-red.svg');
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
}

/* --- AGENT CARDS — PERMANENT RED ACCENTS ------------------- */
/* Left red border always visible on agent cards */
.dark .group.relative.overflow-hidden {
  border-left: 3px solid #D42718 !important;
}

/* --- CATEGORY PILLS — RED TINT ----------------------------- */
.dark [class*="badge"],
.dark .rounded-full.text-xs {
  border: 1px solid rgba(212, 39, 24, 0.4) !important;
  color: #D42718 !important;
  background-color: rgba(212, 39, 24, 0.08) !important;
}

/* --- BID MANAGEMENT BADGE — BRANDED STYLE ------------------ */
/* All our agents are Bid Management — style the category badge with a
   target/crosshair icon (inline SVG) to visually represent the category */
.dark .group.relative.overflow-hidden .rounded-full.text-xs {
  display: inline-flex !important;
  align-items: center !important;
  gap: 4px !important;
  padding: 3px 10px !important;
  font-weight: 500 !important;
  background-color: rgba(212, 39, 24, 0.12) !important;
  border: 1px solid rgba(212, 39, 24, 0.5) !important;
  color: #E8453A !important;
}

.dark .group.relative.overflow-hidden .rounded-full.text-xs::before {
  content: '';
  display: inline-block;
  width: 12px;
  height: 12px;
  flex-shrink: 0;
  /* Inline SVG: crosshair/target icon in TEKEVER red */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23E8453A' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Ccircle cx='12' cy='12' r='6'/%3E%3Ccircle cx='12' cy='12' r='2'/%3E%3Cline x1='12' y1='2' x2='12' y2='6'/%3E%3Cline x1='12' y1='18' x2='12' y2='22'/%3E%3Cline x1='2' y1='12' x2='6' y2='12'/%3E%3Cline x1='18' y1='12' x2='22' y2='12'/%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
}

/* --- FEATURED AGENT — first card spans full width ----------- */
.dark [role="grid"].grid > *:first-child {
  grid-column: 1 / -1;
  border-top: 2px solid #D42718 !important;
  background: linear-gradient(135deg, rgba(212,39,24,0.06) 0%, rgba(15,15,15,1) 60%) !important;
}

/* --- BID MANAGEMENT SECTION HEADER — injected by JS as real element --- */
/* .tk-bid-divider is inserted by patch-index.sh JS after the first card */
.dark .tk-bid-divider {
  grid-column: 1 / -1;
  width: 100%;
  height: 36px;
  margin-top: 8px;
  margin-bottom: 8px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='280' height='32'%3E%3Cg transform='translate(0,4)' fill='none' stroke='%23D42718' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='2' y='7' width='20' height='14' rx='2' ry='2'/%3E%3Cpath d='M16 7V5a2 2 0 00-2-2h-4a2 2 0 00-2 2v2'/%3E%3Cline x1='12' y1='12' x2='12' y2='16'/%3E%3Cline x1='10' y1='14' x2='14' y2='14'/%3E%3C/g%3E%3Ctext x='32' y='22' font-family='Roboto,sans-serif' font-size='14' font-weight='500' letter-spacing='3' fill='%23D42718'%3EBID MANAGEMENT%3C/text%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 280px 32px;
  border-bottom: 1px solid rgba(212, 39, 24, 0.25);
  padding-bottom: 12px;
}

/* --- SEARCH BAR — RED BORDER ------------------------------- */
.dark input[placeholder*="Search"],
.dark input[type="search"] {
  border: 1px solid rgba(212, 39, 24, 0.3) !important;
}

/* --- SECTION HEADINGS — RED ACCENT ------------------------- */
/* "All Agents" and similar headings */
.dark h2,
.dark h3 {
  color: #F5F5F5 !important;
}

/* --- "Agent Marketplace" TITLE — RED UNDERLINE ------------- */
.dark .text-4xl,
.dark .text-3xl {
  background: linear-gradient(to right, #D42718, #E8453A);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* --- SIDEBAR — RED ACCENTS --------------------------------- */
/* Red top border on sidebar */
.dark [data-collapsed] > div {
  border-top: 2px solid #D42718 !important;
}

/* Sidebar active conversation — red left border */
.dark nav a[class*="bg-token-surface-tertiary"],
.dark nav li[class*="bg-token-surface-tertiary"] {
  border-left: 2px solid #D42718 !important;
  background-color: rgba(212, 39, 24, 0.06) !important;
}

/* Sidebar "Agent Marketplace" text */
.dark nav [class*="text-sm"] {
  color: rgba(255, 255, 255, 0.8) !important;
}

/* --- USER AVATAR — RED RING -------------------------------- */
.dark nav .rounded-full img,
.dark [data-testid*="avatar"] {
  border: 1.5px solid #D42718 !important;
}

/* --- NEW CHAT BUTTON — RED ACCENT -------------------------- */
.dark [data-testid="create-new-chat-button"],
.dark [aria-label*="New chat"],
.dark [aria-label*="new chat"] {
  border-color: rgba(212, 39, 24, 0.4) !important;
  transition: background-color 0.2s ease, border-color 0.2s ease !important;
}

.dark [data-testid="create-new-chat-button"]:hover,
.dark [aria-label*="New chat"]:hover,
.dark [aria-label*="new chat"]:hover {
  background-color: rgba(212, 39, 24, 0.1) !important;
  border-color: #D42718 !important;
}

/* --- AGENT CARD ICONS — RED TINT --------------------------- */
.dark .group.relative.overflow-hidden svg {
  color: #D42718 !important;
}

/* --- HORIZONTAL DIVIDER LINES — RED ----------------------- */
.dark hr,
.dark [class*="border-b"] {
  border-color: rgba(212, 39, 24, 0.15) !important;
}

/* --- TEKEVER MONOGRAM NEXT TO USER NAME -------------------- */
.dark [data-testid="nav-user"]::before {
  content: '';
  display: inline-block;
  width: 24px;
  height: 16px;
  margin-right: 4px;
  vertical-align: middle;
  flex-shrink: 0;
  background-image: url('/assets/monogram.svg');
  background-size: contain;
  background-repeat: no-repeat;
}

/* --- EXTERNAL AGENT CARDS (M365 Copilot etc.) -------------- */
.tekever-external-card:hover {
  border-color: #0078d4 !important;
  background-color: #101820 !important;
}

/* --- LOADING / SPLASH SCREEN ------------------------------- */
#loading-container {
  background-color: #0A0A0A !important;
}

/* --- BROWSER AUTOFILL — DARK OVERRIDE ---------------------- */
/* Browsers force a white/light background on autofilled inputs.
   This transitions it back to dark immediately. */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
textarea:-webkit-autofill,
textarea:-webkit-autofill:hover,
textarea:-webkit-autofill:focus {
  -webkit-box-shadow: 0 0 0 1000px #141414 inset !important;
  -webkit-text-fill-color: #F5F5F5 !important;
  caret-color: #F5F5F5 !important;
  transition: background-color 5000s ease-in-out 0s;
}

/* --- AGENTS MARKETPLACE RAIL BUTTON (DASC-1943) ------------ */
/* Injected at the top of LibreChat's left icon rail by patch-index.sh.
   Stacked vertically (icon on top, label below) so the text fits within
   the narrow rail. Visually distinct (TEKEVER red accent) to read as the
   primary nav entry. */
.tk-agents-rail-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  padding: 6px 0 5px;
  margin: 0 -4px 4px;
  border-radius: 6px;
  border: none;
  background: rgba(212, 39, 24, 0.10);
  color: #F5F5F5;
  text-decoration: none;
  overflow: visible;
  transition: background 120ms ease, transform 120ms ease;
}

div.flex.h-full.flex-shrink-0.flex-col.border-r {
  overflow: visible !important;
}

.tk-agents-rail-btn:hover {
  background: rgba(212, 39, 24, 0.22);
  transform: translateY(-1px);
}

.tk-agents-rail-btn:focus-visible {
  outline: 2px solid #D42718;
  outline-offset: 2px;
}

.tk-agents-rail-btn .tk-agents-label {
  display: block;
  font: 700 10px/1 "Roboto Condensed", "Roboto", system-ui, sans-serif;
  font-stretch: 90%;
  letter-spacing: 0.2px;
  text-transform: uppercase;
  text-align: center;
  color: #F5F5F5;
  white-space: nowrap;
  transform: scaleX(0.95);
  transform-origin: center;
}

.tk-agents-rail-btn svg {
  flex-shrink: 0;
  color: #D42718;
  width: 18px;
  height: 18px;
}

/* --- AGENT-CHAT HEADER FLATTENING (DASC-1943) -------------- */
/* When the active selection is an agent (feather icon present), the picker
   trigger is tagged .tk-agent-trigger by patch-index.sh JS. The model is
   fixed by the agent's config, so we strip the click affordance + chevron
   and leave the agent name visible as a static-looking pill. */
button.tk-agent-trigger {
  pointer-events: none !important;
  cursor: default !important;
}

button.tk-agent-trigger svg.lucide-chevron-down,
button.tk-agent-trigger svg[class*="chevron"] {
  display: none !important;
}

/* --- SWITCH TO MODEL BUTTON (DASC-1943) -------------------- */
/* Injected as a sibling of the picker trigger when an agent is active.
   Routes to /c/new which (with modelSpecs.prioritize=false) lands the user
   on their last-used modelSpec via the empty-conversation gating branch. */
.tk-switch-to-model {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-left: 8px;
  padding: 4px 10px 4px 8px;
  font: 500 12px/1 "Roboto", system-ui, sans-serif;
  color: rgba(245, 245, 245, 0.65);
  background: transparent;
  border: 1px solid rgba(245, 245, 245, 0.18);
  border-radius: 999px;
  cursor: pointer;
  flex-shrink: 0;
  white-space: nowrap;
  transition: color 120ms ease, border-color 120ms ease, background 120ms ease;
}

.tk-switch-to-model:hover {
  color: #F5F5F5;
  border-color: rgba(212, 39, 24, 0.7);
  background: rgba(212, 39, 24, 0.10);
}

.tk-switch-to-model:focus-visible {
  outline: 2px solid #D42718;
  outline-offset: 2px;
}

.tk-switch-to-model svg {
  flex-shrink: 0;
  color: #D42718;
}

/* --- MCP SERVERS WIP BANNER (DASC-1943) -------------------- */
/* Injected by patch-index.sh on the /mcp-servers route. The yaml gates
   user-side creation (interface.mcpServers.create=false) but keeps the
   tab visible so users see the feature is on the roadmap. */
.tk-mcp-wip-banner {
  display: block;
  padding: 12px 16px;
  margin: 0 0 16px;
  border: 1px solid rgba(212, 39, 24, 0.35);
  border-left: 4px solid #D42718;
  border-radius: 6px;
  background: rgba(212, 39, 24, 0.08);
  color: #F5F5F5;
  font: 400 13px/1.5 "Roboto", system-ui, sans-serif;
}

.tk-mcp-wip-banner strong {
  color: #D42718;
  font-weight: 700;
  margin-right: 4px;
}

/* --- DCA TIERING REFERENCE BUTTON + MODAL (DASC-1943) ------ */
/* Pill button next to the agent picker when Data Classification Agent
   is the active selection. Click opens a modal with the tiering chart
   (assets/dca-tiering.svg). Same visual language as .tk-switch-to-model. */
.tk-tiering-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-left: 8px;
  padding: 4px 10px 4px 8px;
  font: 500 12px/1 "Roboto", system-ui, sans-serif;
  color: rgba(245, 245, 245, 0.65);
  background: transparent;
  border: 1px solid rgba(245, 245, 245, 0.18);
  border-radius: 999px;
  cursor: pointer;
  flex-shrink: 0;
  white-space: nowrap;
  transition: color 120ms ease, border-color 120ms ease, background 120ms ease;
}

.tk-tiering-btn:hover {
  color: #F5F5F5;
  border-color: rgba(212, 39, 24, 0.7);
  background: rgba(212, 39, 24, 0.10);
}

.tk-tiering-btn:focus-visible {
  outline: 2px solid #D42718;
  outline-offset: 2px;
}

.tk-tiering-btn svg {
  flex-shrink: 0;
  color: #D42718;
}

.tk-tiering-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(4px);
  animation: tk-tiering-fade-in 150ms ease;
}

@keyframes tk-tiering-fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.tk-tiering-modal-inner {
  position: relative;
  background: #141414;
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: 12px;
  padding: 16px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.tk-tiering-modal-host {
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Height-bound sizing: SVG height fills 85vh, width is computed from the
   viewBox aspect ratio (690:562). On narrow / portrait screens, max-width
   takes over and height auto-shrinks. */
.tk-tiering-modal-host svg {
  display: block;
  height: 85vh;
  width: auto;
  max-width: 90vw;
}

.tk-tiering-modal-close {
  position: absolute;
  top: 8px;
  right: 12px;
  width: 32px;
  height: 32px;
  font: 700 22px/1 system-ui, sans-serif;
  color: rgba(245, 245, 245, 0.7);
  background: transparent;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  transition: color 120ms ease, background 120ms ease;
}

.tk-tiering-modal-close:hover {
  color: #F5F5F5;
  background: rgba(212, 39, 24, 0.20);
}

/* ============================================================
   END TEKEVER THEME
   ============================================================ */
