:root {
  --font-body: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  --font-heading: "Manrope", "Inter", system-ui, sans-serif;
}

html, body {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
}
*, *::before, *::after {
    box-sizing: border-box;
}
html, body {
    overflow-x: hidden;
}
html {
    -webkit-text-size-adjust: 100%;
    text-rendering: optimizeLegibility;
}

body {
    font-family: var(--font-body);
    font-weight: 400;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}
a {
  color: #1f4fb3;            /* Primary blue */
  text-decoration: none;
  cursor: pointer;
  font-weight: 500;
  transition: color 0.15s ease, text-decoration-color 0.15s ease;
}

a:hover,
a:focus {
  color: #163d8c;            /* Slightly darker blue */
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

a:active {
  color: #0f2c66;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  font-weight: 600;
  letter-spacing: 0.2px;
}
h1 { font-size: 2rem;   font-weight: 600; }
h2 { font-size: 1.6rem; font-weight: 600; }
h3 { font-size: 1.3rem; font-weight: 600; }
h4 { font-size: 1.1rem; font-weight: 600; }
h5 { font-size: 1rem;   font-weight: 600; }
h6 { font-size: 0.95rem; font-weight: 600; }

.top-space {
    margin-top: 10px;
}
.section-divider {
    position: relative;
    margin: 18px 0;
    height: 0;
    border-top: 3px solid #e5e7eb;
}

/* optional centered dot accent */
.section-divider::after {
    content: "";
    position: absolute;
    left: 50%;
    top: -6px;
    transform: translateX(-50%);

    width: 10px;
    height: 10px;
    background: #fff;
    border: 2px solid #cbd5e1;
    border-radius: 999px;
}

/* Container */
.credit-usage-box {
    width: 100%;
    max-width: 520px; /* limits width on desktop */
    
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;

    padding: 16px;
    margin: 0 0 6px;
}

/* Header */
.credit-header {
    margin-bottom: 10px;
    text-align:center;
}

.credit-description {
    font-size: 13px;
    color: #374151;
    margin: 10px 0 14px;
    line-height: 1.4;
}

.credit-title {
    font-size: 13px;
    font-weight: 600;
    color: #2563eb; /* subtle brand accent */
    letter-spacing: 0.3px;
}

/* Stats row */
.credit-stats {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 14px;
}

.credit-stat {
    flex: 1;
    text-align: center;
}

.credit-label {
    font-size: 12px;
    color: #6b7280;
    margin-bottom: 4px;
}

.credit-value {
    font-size: 18px;
    font-weight: 700;
    color: #111827;
    word-break: break-word;
}

/* Button (more prominent) */
.credit-action-btn {
    width: 100%;

    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    color: #fff;
    border: none;
    border-radius: 10px;

    padding: 12px;
    font-size: 14px;
    font-weight: 600;

    cursor: pointer;

    transition: all 0.15s ease;
}

.credit-action-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(37, 99, 235, 0.25);
}

.credit-action-btn:active {
    transform: scale(0.98);
}

/* Disabled */
.credit-action-btn:disabled {
    background: #9ca3af;
    box-shadow: none;
    cursor: not-allowed;
}

/* Locked state (subtle visual feedback) */
.credit-usage-box.is-locked {
    border-color: #fca5a5;
    background: #fff7f7;
}

/* Upsell container */
.credit-upsell {
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px dashed #e5e7eb;
    text-align: center;
}

/* Message */
.credit-upsell-text {
    font-size: 13px;
    color: #b91c1c;
    margin-bottom: 10px;
}

/* Actions row */
.credit-upsell-actions {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

/* Links styled as buttons */
.credit-link {
    display: inline-block;
    font-size: 13px;
    font-weight: 600;
    color: #2563eb;
    text-decoration: none;

    padding: 6px 10px;
    border-radius: 8px;

    transition: all 0.15s ease;
}

.credit-link:hover {
    background: rgba(37, 99, 235, 0.1);
}

/* Primary action (Buy Credits) */
.credit-link.primary {
    background: #2563eb;
    color: #fff;
}

.credit-link.primary:hover {
    background: #1d4ed8;
}

/* 📱 Mobile fix */
@media (max-width: 640px) {
    .credit-usage-box {
        max-width: 100%; /* full width on mobile */
        padding: 14px;
    }

    .credit-value {
        font-size: 16px;
    }
}

.removeable-field .input-wrap {
    position: relative;
}

/* Input padding so text doesn't overlap the X */
.removeable-field input {
    width: 100%;
    padding-right: 36px;
    box-sizing: border-box;
}

/* Remove button */
.remove-field {
    position: absolute;
    top: 50%;
    right: 8px;
    transform: translateY(-50%);

    width: 20px;
    height: 20px;
    border-radius: 50%;

    background: #374151;
    color: #fff;

    display: flex;
    align-items: center;
    justify-content: center;

    font-size: 14px;
    line-height: 1;
    cursor: pointer;

    transition: background 0.15s ease, transform 0.1s ease;
}

/* Hover effect */
.remove-field:hover {
    background: #000;
    transform: translateY(-50%) scale(1.05);
}

/* Optional: active click feel */
.remove-field:active {
    transform: translateY(-50%) scale(0.95);
}

/* Make select behave like input */
.removeable-field select {
    width: 100%;
    padding-right: 36px; /* space for X */
    box-sizing: border-box;

    /* Improve consistency across browsers */
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
}

/* Optional: add custom dropdown arrow */
.removeable-field .input-wrap {
    position: relative;
}

/* Custom arrow (optional but recommended) */
.removeable-field .input-wrap.has-select::after {
    content: "▼";
    position: absolute;
    right: 28px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 10px;
    pointer-events: none;
    color: #666;
}

img {
    height: auto;
    display: block;
}
button {
    touch-action: manipulation;
}
html {
    scrollbar-gutter: stable;
}
.small {
  font-size: 13px;
  line-height: 1.45;
}

.top_bottom_spacing {
    margin-top: 7px;
    margin-bottom: 7px;
}

.muted {
  color: #6b7280; /* neutral gray */
}

.limit_btn_size {
    max-width: 200px;
}

/* ----------------------------------
 * Status Labels (Base)
 * ---------------------------------- */
.status-label {
    display: inline-flex;         /* stronger than inline-block in flex contexts */
    align-items: center;
    width: auto;
    max-width: fit-content;
    margin-top: 8px;
    margin-bottom: 8px;
    padding: 2px 8px;
    border-radius: 999px; /* pill */
    font-size: 12px;
    font-weight: 600;
    line-height: 1.4;
    white-space: nowrap;
    user-select: none;
}

/* Force content-width only */
.status-label.is-fit {
    align-self: flex-start;       /* prevents flex stretch */
    justify-self: start;          /* prevents grid stretch */
}

/* Enabled */
.enabled-label {
    background-color: #e6f6ea;
    color: #1f7a3a;
    border: 1px solid #bfe6cc;
}

/* Disabled */
.disabled-label {
    background-color: #fdeaea;
    color: #9c1c1c;
    border: 1px solid #f3c2c2;
}

/* Compact variant */
.status-label.is-compact {
    font-size: 11px;
    padding: 1px 6px;
}



[data-ui="copy"] {
    cursor: pointer;
    position: relative;
}

[data-ui="copy"]::after {
    content: "📋";
    position: absolute;
    top: 8px;
    right: 8px;
    opacity: 0.6;
    font-size: 0.9rem;
}

[data-ui="copy"].copied::after {
    content: "✔";
    opacity: 1;
}

.copy-feedback {
    position: absolute;
    bottom: -24px;
    right: 8px;
    font-size: 0.75rem;
    color: green;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.copy-feedback.is-active {
    opacity: 1;
}
.is-hidden {
    display: none !important;
}
.center {
    text-align:center;
}
.margin-center {
   margin-right:auto;
   margin-left:auto;
}
.show-more {
  display: inline-flex; 
  vertical-align: middle; 
  width: 16px;
  height: 16px;
  margin-left: 6px;
  border-radius: 50%;
  border: 1.5px solid #2563eb;
  color: #2563eb;
  font-size: 11px;
  align-items: center;
  justify-content: center;
}

.show-more::before {
  content: "?";
  font-weight: 600;
}

/* =========================
   HIGHLIGHT MESSAGES
   ========================= */

.highlight-error,
.highlight-warning,
.highlight-success {
  display: flex; /* allow flex for content */
  align-items: center;
  gap: 10px;

  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;

  padding: 14px 18px;
  border-radius: 8px;
  font-size: 14px;
  max-width: 600px;
  width: 90%; /* max width 90% of viewport to prevent touching edges */

  box-shadow: 0 10px 25px rgba(0,0,0,0.15);

  opacity: 0;
  pointer-events: none;

  transition: all 0.25s ease;
}

/* ACTIVE STATE */
.highlight-error.is-active,
.highlight-warning.is-active,
.highlight-success.is-active {
  opacity: 1;
  pointer-events: auto;
}

/* STACKING: push each subsequent message down */
.highlight-error.is-active ~ .highlight-error.is-active,
.highlight-error.is-active ~ .highlight-warning.is-active,
.highlight-error.is-active ~ .highlight-success.is-active,
.highlight-warning.is-active ~ .highlight-error.is-active,
.highlight-warning.is-active ~ .highlight-warning.is-active,
.highlight-warning.is-active ~ .highlight-success.is-active,
.highlight-success.is-active ~ .highlight-error.is-active,
.highlight-success.is-active ~ .highlight-warning.is-active,
.highlight-success.is-active ~ .highlight-success.is-active {
  top: calc(20px + 70px); /* adjust for your message height */
}

/* ERROR */
.highlight-error {
  background: #ffeaea;
  border: 1px solid #ffb6b6;
  color: #c62828;
}
.highlight-error::before {
  content: "⚠️";
  font-size: 1.2rem;
}

/* WARNING */
.highlight-warning {
  background: #fff7e6;
  border: 1px solid #ffd59e;
  color: #b26a00;
}
.highlight-warning::before {
  content: "⚠️";
  font-size: 1.2rem;
}

/* SUCCESS */
.highlight-success {
  background: #e8f5e9;
  border: 1px solid #a5d6a7;
  color: #2e7d32;
}
.highlight-success::before {
  content: "✅";
  font-size: 1.2rem;
}

/* BANNER VARIANT (page-level) */
.highlight-banner {
  width: 95%;
  margin-bottom: 24px;
  top: 15px;
  z-index: 10;
}

/* MOBILE ADJUSTMENTS */
@media (max-width: 480px) {
  .highlight-error,
  .highlight-warning,
  .highlight-success {
    width: 95%; /* always 16px margin each side */
    padding: 12px 14px;
    font-size: 13px;
  }
}

/* ==========================================================
   TEXT SAFETY / OVERFLOW GUARD
   ========================================================== */

.text-wrap-safe {
  white-space: normal;          /* reset inherited nowrap */
  overflow-wrap: anywhere;      /* modern, best behavior */
  word-break: break-word;       /* legacy safety */
  max-width: 100%;
}

/* =========================
   STANDOUT BACKGROUND
   ========================= */
   
.standout {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 8px;
    background-color: #f3f4f6;   /* soft neutral */
    color: #1f2937;              /* dark gray */
    font-size: 13px;
    font-weight: 600;
    line-height: 1.4;
    white-space: nowrap;    
}

.standout.is-compact {
    padding: 2px 8px;
    font-size: 12px;
    border-radius: 6px;
}

.standout.is-muted {
    background-color: #f9fafb;
    color: #4b5563;
    font-weight: 500;
}

.standout.is-outline {
    background-color: transparent;
    border: 1px solid #d1d5db;
    color: #374151;
}

.standout.is-block {
    display: block;
    padding: 12px 14px;
    background-color: #f8fafc;
    border-left: 4px solid #c7d2fe; /* soft indigo accent */
    border-radius: 10px;
    font-size: 14px;
    color: #1f2937;
}

.standout.is-info {
    background-color: #e8f1ff;   /* soft blue */
    color: #1e3a8a;              /* deep blue text */
    border-radius: 4px;          /* squared but not sharp */
    font-weight: 600;
}

.standout.is-info.is-compact {
    padding: 2px 8px;
    font-size: 12px;
}

.standout.is-info.is-block {
    display: block;
    padding: 12px 14px;
    background-color: #e8f1ff;
    border-left: 4px solid #93c5fd; /* subtle accent */
    border-radius: 6px;
    font-size: 14px;
    margin-top:10px;
    margin-bottom:10px;
}
.device-header {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 4px;
}

/* Ensure the standout label behaves inline */
.device-header .standout {
    display: inline-flex;
    align-items: center;
}

/* Edit icon styling */
.device-edit-icon {
    width: 18px;
    height: 18px;
    cursor: pointer;
    opacity: 0.65;
    transition: opacity 0.15s ease, transform 0.15s ease;
}

.device-edit-icon:hover {
    opacity: 1;
    transform: scale(1.05);
}
   

/* ==========================================================
   CCS TABLE — ISOLATED, READABLE, PRODUCTION SAFE
   ========================================================== */

/* ---------- TABLE CONTAINER ---------- */

.ccs-table {
  width: 100%;
  margin-top: 16px;
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 14px;
}

.ccs-table-reset {
    margin-left: 12px;
    padding: 6px 10px;

    font-size: 13px;
    font-weight: 500;

    color: #666;
    background: transparent;

    border: 1px dashed #ccc;
    border-radius: 4px;

    cursor: pointer;
    transition: all 0.15s ease;
}

/* ACTIVE = something is set */
.ccs-table-reset.is-active {
    color: #b00020;
    border-color: #b00020;
    background: #fff5f5;
}

/* Hover when active */
.ccs-table-reset.is-active:hover {
    background: #ffecec;
}

/* Inactive */
.ccs-table-reset:disabled {
    opacity: 0.35;
    cursor: default;
}


/* ---------- HEADER / TOOLBAR ---------- */

.ccs-table-header {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-bottom: 12px;
  margin-bottom: 12px;
  border-bottom: 1px solid #e5e7eb;
}

.ccs-table-header h3 {
  margin: 0;
  font-size: 17px;
  font-weight: 600;
  color: #1f2937;
}

/* ---------- CONTROL FORM ---------- */

.ccs-table-header form[data-table-form] {
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: #f9fafb;
  padding: 10px;
  border-radius: 10px;
}


.ccs-table-header .ccs-filter-row select,
.ccs-table-header .ccs-toolbar-row select,
.ccs-table-header input[type="search"] {
  height: 36px;
  padding: 8px 12px;
  font-size: 14px;
  border-radius: 8px;
  border: 1px solid #d1d5db;
  background: #ffffff;
  color: #111827;
}

.ccs-table-header input[type="search"] {
  width: 100%;  
  min-width: 0; 
  font-weight: 500;
}

.ccs-table-header input::placeholder {
  color: #9ca3af;
}

.ccs-table-header input:focus,
.ccs-table-header select:focus {
  outline: none;
  border-color: #1f4fb3;
  box-shadow: 0 0 0 2px rgba(31,79,179,0.15);
}
@media (max-width: 720px) {
  .ccs-search-wrap {
    max-width: 100%;
  }
}

/* ---------- TABLE WRAPPER ---------- */

.ccs-table-wrap {
  overflow-x: auto;
  border-radius: 10px;
  border: 1px solid #e5e7eb;
}

/* ---------- GRID ---------- */

.ccs-grid {
  width: 100%;
  border-collapse: collapse;
  min-width: 700px;
}

/* Header cells */
.ccs-grid th {
  background: #f3f4f6;
  padding: 10px 12px;
  font-size: 13px;
  font-weight: 600;
  color: #374151;
  text-align: left;
  white-space: nowrap;
  border-bottom: 1px solid #e5e7eb;
  user-select: none;
}

.ccs-grid th[data-sort] {
  cursor: pointer;
}

.ccs-grid th[data-sort]:hover {
  background: #e5e7eb;
}

/* Body cells */
.ccs-grid td {
  padding: 10px 12px;
  font-size: 14px;
  color: #111827;
  border-bottom: 1px solid #e5e7eb;
  vertical-align: middle;
}

/* Alignment */
.ccs-grid th.right,
.ccs-grid td.right {
  text-align: right;
}

/* Row styling */
.ccs-grid tbody tr:nth-child(even) {
  background: #fafafa;
}

.ccs-grid tbody tr:hover {
  background: #eef2ff;
}

/* Empty state */
.ccs-table-empty {
  padding: 16px;
  text-align: center;
  font-size: 14px;
  color: #6b7280;
}

/* ---------- PAGER ---------- */

.ccs-table-pager {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  align-items: center;
  margin-top: 14px;
}

.ccs-table-pager button {
  background: #1f4fb3;
  color: #ffffff;
  border: none;
  padding: 6px 12px;
  font-size: 13px;
  border-radius: 8px;
  cursor: pointer;
}

.ccs-table-pager button:hover {
  background: #2a6cf4;
}

.ccs-page-info {
  font-size: 13px;
  color: #6b7280;
}


/* ---------- MOBILE: CARD MODE ---------- */

@media (max-width: 720px) {

  .ccs-grid {
    min-width: 0;
  }

  .ccs-grid thead {
    display: none;
  }

  .ccs-grid,
  .ccs-grid tbody,
  .ccs-grid tr,
  .ccs-grid td {
    display: block;
    width: 100%;
  }

  .ccs-grid tr {
    margin-bottom: 12px;
    padding: 12px;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    background: #ffffff;
  }

  .ccs-grid td {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
    border-bottom: none;
    font-size: 14px;
  }

  .ccs-grid td::before {
    content: attr(data-label);
    font-weight: 600;
    color: #374151;
    margin-right: 12px;
  }

  .ccs-table-pager {
    justify-content: center;
  }

  .ccs-table-header form[data-table-form] {
    flex-direction: column;
    align-items: stretch;
  }

  .ccs-table-header input,
  .ccs-table-header select {
    width: 100%;
  }
}

/* ---------- FILTER ROW ---------- */

.ccs-filter-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(160px, 1fr));
  gap: 10px;
  width: 100%;
}

/* ---------- TOOLBAR ROW ---------- */

/* ---------- TOOLBAR LAYOUT ---------- */
/* ---------- TOOLBAR LAYOUT (DESKTOP) ---------- */

.ccs-toolbar-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  width: 100%;
}

/* LEFT: search */
.ccs-toolbar-left {
  flex: 1 1 auto;
  align-self: stretch;     /* make left column match row height */
  display: flex;
  align-items: center;     /* now centering actually works */
}


.ccs-search-wrap {
  display: flex;
  align-items: center;
  width: 100%;
  max-width: 900px;
}

/* RIGHT: stacked controls */
.ccs-toolbar-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
}

.ccs-toolbar-line {
  display: flex;
  align-items: center;
  gap: 12px;
}

.ccs-toolbar-controls {
  justify-content: flex-end;
  gap: 16px;
}

.ccs-toolbar-pager {
  justify-content: flex-end;
}


/* ---------- PAGER BUTTONS ---------- */

/* ---------- PAGER BUTTONS ---------- */

.ccs-page-indicator {
  font-size: 13px;
  color: #6b7280;
  white-space: nowrap;
}
.ccs-toolbar-pager {
  gap: 10px;
}

.pager-buttons {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Hidden by default */
.pager-btn {
  display: none;

  height: 32px;
  min-width: 40px;
  padding: 0 10px;

  display: inline-flex;
  align-items: center;
  justify-content: center;

  font-size: 13px;
  font-weight: 500;
  line-height: 1;

  border-radius: 6px;
  border: 1px solid #d1d5db;
  background: #ffffff;
  color: #1f2937;

  cursor: pointer;
  white-space: nowrap;
  transition: background 0.15s ease, border-color 0.15s ease;
}

/* Backend enables buttons individually */
.pager-btn.is-active {
  display: inline-flex;
}

.pager-btn:hover:not(:disabled) {
  background: #f3f4f6;
  border-color: #9ca3af;
}

.pager-btn:active:not(:disabled) {
  background: #e5e7eb;
}

.pager-btn:disabled {
  opacity: 0.5;
  cursor: default;
}

/* ---------- MOBILE ---------- */

@media (max-width: 900px) {

  .ccs-toolbar-row {
    flex-direction: column;
    align-items: stretch;
  }

  .ccs-toolbar-right {
    align-items: stretch;
  }

  .ccs-toolbar-controls {
    justify-content: space-between;
  }

  .ccs-toolbar-pager {
    justify-content: flex-start;
  }

  .pager-buttons {
    justify-content: flex-start;
    gap: 6px;
    flex-wrap: wrap;
  }
}

@media (max-width: 900px) {
  .ccs-filter-row {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 720px) {
  .ccs-filter-row {
    grid-template-columns: 1fr;
  }
}



/* =====================
   Manrope
===================== */

@font-face {
  font-family: "Manrope";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/core-assets/fonts/manrope/manrope-v20-latin-regular.woff2") format("woff2");
  unicode-range: U+000-5FF;
}

@font-face {
  font-family: "Manrope";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/core-assets/fonts/manrope/manrope-v20-latin-500.woff2") format("woff2");
  unicode-range: U+000-5FF;
}

@font-face {
  font-family: "Manrope";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/core-assets/fonts/manrope/manrope-v20-latin-600.woff2") format("woff2");
  unicode-range: U+000-5FF;
}

/* =====================
   Inter
===================== */

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/core-assets/fonts/inter/inter-v20-latin-regular.woff2") format("woff2");
  unicode-range: U+000-5FF;
}

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/core-assets/fonts/inter/inter-v20-latin-500.woff2") format("woff2");
  unicode-range: U+000-5FF;
}

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/core-assets/fonts/inter/inter-v20-latin-600.woff2") format("woff2");
  unicode-range: U+000-5FF;
}


