/* ==========================================================================
   IT SIGNATURE — MAIN STYLESHEET (main-style.css)
   Clean CSS Architecture with Mother Colors & Bootstrap 5 Compatibility
   ========================================================================== */

:root {
  /* ------------------------------------------------------------------------
     1. Core Mother Colors (Brand Palette)
     ------------------------------------------------------------------------ */
  --bg: #F4F5FB;
  --panel: #FFFFFF;
  --ink: #15142B;
  --soft: #65637E;
  --faint: #9997AD;
  --line: #E5E4F0;

  /* ------------------------------------------------------------------------
     2. Accents & Theme Colors
     ------------------------------------------------------------------------ */
  /* --accent: #6C4CF1; */
  --accent: #00b4ff;
  --accent-bg: #EDE8FE;
  --blue: #2E6BFF;
  --blue-bg: #E5EDFF;
  --teal: #00A98F;
  --teal-bg: #DFF7F2;
  --coral: #FF5A5F;
  --coral-bg: #FFE7E8;
  --amber: #E08A00;
  --amber-bg: #FFF1D6;
  --pink: #FF3D81;
  --pink-bg: #FFE2ED;
  --green: #17C971;
  --green-bg: #E1FAEC;
  --red: #E1382E;
  --red-bg: #FCE4E2;

  /* ------------------------------------------------------------------------
     3. WhatsApp Bot System Colors
     ------------------------------------------------------------------------ */
  --wa-green: #25D366;
  --wa-dark: #075E54;
  --wa-bg: #ECE5DD;
}

/* Base Reset & Typography */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--bg) !important;
  color: var(--ink) !important;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;
  font-size: 14px;
  line-height: 1.5;
  overflow-x: hidden;
}

a {
  text-decoration: none;
  color: inherit;
}

button {
  font-family: inherit;
}

/* ==========================================================================
   TOP NAVIGATION BAR (DESKTOP, TABLET & MOBILE)
   ========================================================================== */

.topnav {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 20px;
  height: 62px;
  background: var(--panel);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 1030;
  box-shadow: 0 2px 8px rgba(21, 20, 43, 0.03);
}

@media (min-width: 992px) {
  .topnav {
    padding: 0 24px;
    gap: 8px;
  }
}

.mark {
  display: flex;
  align-items: center;
  gap: 9px;
  flex-shrink: 0;
  margin-right: 12px;
  background: transparent !important;
  padding: 0 !important;
}

.mark .sq {
  width: 22px;
  height: 22px;
  border-radius: 7px;
  background: var(--accent);
}

.mark img {
  height: 24px;
  width: auto;
  display: block;
}

/* Desktop & Tablet Tabs */
.tabs {
  display: flex;
  align-items: center;
  gap: 4px;
  overflow: visible;
  flex: 1;
}

/* Tablet scrollable container if needed */
@media (max-width: 1200px) and (min-width: 992px) {
  .tabs {
    gap: 2px;
    overflow-x: auto;
    scrollbar-width: none; /* Firefox */
  }
  .tabs::-webkit-scrollbar {
    display: none; /* Chrome/Safari */
  }
  .navmain {
    padding: 7px 10px !important;
    font-size: 12px !important;
  }
}

.navgroup {
  position: relative;
}

.navmain {
  all: unset;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--soft);
  padding: 8px 12px;
  border-radius: 9px;
  cursor: pointer;
  white-space: nowrap;
  font-weight: 600;
  transition: all 0.15s ease-in-out;
}

.navmain .ic {
  width: 24px;
  height: 24px;
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.15s ease-in-out;
}

.navmain .ic svg {
  width: 13px;
  height: 13px;
}

.navmain:hover {
  background: var(--bg);
  color: var(--ink);
}

.navmain.on {
  background: var(--ink);
  color: #ffffff;
}

.navmain.on .ic {
  background: rgba(255, 255, 255, 0.18) !important;
  color: #ffffff !important;
}

/* Dropdown Menu (Hover based on Desktop) */
.dropdown-menu-custom {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  padding-top: 6px;
  z-index: 1050;
  animation: fadeIn 0.15s ease-in-out;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

.dropdown-inner {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: 0 14px 30px rgba(20, 19, 50, 0.12);
  padding: 6px;
  min-width: 190px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.navgroup:hover .dropdown-menu-custom {
  display: block;
}

.dropdown-item-btn {
  all: unset;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12.5px;
  color: var(--soft);
  padding: 8px 12px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 500;
  transition: all 0.12s ease;
}

.dropdown-item-btn:hover {
  background: var(--accent-bg);
  color: var(--accent);
}

.dropdown-item-btn.on {
  background: var(--accent-bg);
  color: var(--accent);
  font-weight: 700;
}

/* Color Accent Badges for Icons */
.cc-accent { background: var(--accent-bg); color: var(--accent); }
.cc-blue { background: var(--blue-bg); color: var(--blue); }
.cc-teal { background: var(--teal-bg); color: var(--teal); }
.cc-coral { background: var(--coral-bg); color: var(--coral); }
.cc-amber { background: var(--amber-bg); color: var(--amber); }
.cc-pink { background: var(--pink-bg); color: var(--pink); }
.cc-green { background: var(--green-bg); color: var(--green); }

/* Topnav Right Side */
.topnav-right {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
  margin-left: auto;
}

.avatar-top {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(108, 76, 241, 0.35);
  cursor: pointer;
}

/* Avatar dropdown wrapper */
.avatar-dropdown-wrap {
  position: relative;
}
.avatar-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  min-width: 240px;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.12);
  border: 1px solid var(--line);
  padding: 8px 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity 0.18s, transform 0.18s, visibility 0.18s;
  z-index: 9999;
}
.avatar-dropdown.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.avatar-dd-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
}
.avatar-dd-initials {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  flex-shrink: 0;
}
.avatar-dd-name {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.3;
}
.avatar-dd-email {
  font-size: 11.5px;
  color: var(--faint);
  line-height: 1.3;
}
.avatar-dd-divider {
  height: 1px;
  background: var(--line);
  margin: 4px 0;
}
.avatar-dd-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  font-size: 13px;
  font-weight: 500;
  color: var(--ink);
  text-decoration: none;
  transition: background 0.15s;
}
.avatar-dd-item:hover {
  background: var(--bg);
  color: var(--ink);
}
.avatar-dd-item i {
  font-size: 16px;
  color: var(--soft);
}
.avatar-dd-logout {
  color: var(--red);
}
.avatar-dd-logout i {
  color: var(--red);
}
.avatar-dd-logout:hover {
  background: var(--red-bg);
  color: var(--red);
}

/* Mobile Hamburger Toggle */
.mobile-toggle-btn {
  all: unset;
  width: 38px;
  height: 38px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink);
  cursor: pointer;
  background: var(--bg);
  transition: all 0.15s ease;
}

.mobile-toggle-btn:hover {
  background: var(--line);
}

.mobile-toggle-btn svg {
  width: 20px;
  height: 20px;
}

/* ==========================================================================
   MOBILE & TABLET OFFCANVAS DRAWER
   ========================================================================== */

.mobile-drawer {
  background-color: var(--panel) !important;
  border-right: 1px solid var(--line) !important;
  width: 300px !important;
  max-width: 85vw !important;
}

.mobile-drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--line);
}

.mobile-drawer-body {
  padding: 16px 14px;
  overflow-y: auto;
}

.mobile-nav-group {
  margin-bottom: 6px;
}

.mobile-nav-main {
  all: unset;
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--soft);
  cursor: pointer;
  box-sizing: border-box;
  transition: background 0.12s ease;
}

.mobile-nav-main:hover {
  background: var(--bg);
  color: var(--ink);
}

.mobile-nav-main.on {
  background: var(--ink);
  color: #fff;
}

.mobile-nav-main.on .ic {
  background: rgba(255, 255, 255, 0.18) !important;
  color: #fff !important;
}

.mobile-nav-main .chevron {
  margin-left: auto;
  transition: transform 0.2s ease;
}

.mobile-nav-main[aria-expanded="true"] .chevron {
  transform: rotate(90deg);
}

.mobile-sub-list {
  padding-left: 36px;
  padding-top: 4px;
  padding-bottom: 4px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.mobile-sub-item {
  all: unset;
  display: block;
  font-size: 12.5px;
  color: var(--soft);
  padding: 7px 12px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 500;
  transition: all 0.12s ease;
}

.mobile-sub-item:hover, .mobile-sub-item.on {
  background: var(--accent-bg);
  color: var(--accent);
  font-weight: 600;
}

/* Quick close button for drawer */
.drawer-close-btn {
  all: unset;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--soft);
}

.drawer-close-btn:hover {
  background: var(--line);
  color: var(--ink);
}

/* ==========================================================================
   CONTENT WRAPPER & RESPONSIVE CONTAINERS
   ========================================================================== */

.content {
  padding-top: 20px;
  padding-bottom: 76px;
  width: 100%;
}

.view {
  display: none;
  animation: viewIn 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.view.on {
  display: block;
}

@keyframes viewIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ==========================================================================
   ICON BUTTONS (components/ui/icon-button.php)
   Shared edit / delete / add / details / open / paid / send / email / whatsapp / toggle buttons.
   ========================================================================== */

.btn-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 0;
  border-radius: 8px;
  font-size: 14px;
  line-height: 1;
  transition: background-color 0.15s ease, color 0.15s ease, transform 0.15s ease;
}

.btn-icon:hover { transform: translateY(-1px); }
a.btn-icon { text-decoration: none; }
.btn-icon:active { transform: translateY(0); }

.btn-icon-edit    { background: var(--blue-bg);   color: var(--blue); }
.btn-icon-delete  { background: var(--red-bg);    color: var(--red); }
.btn-icon-add     { background: var(--green-bg);  color: var(--green); }
.btn-icon-details { background: var(--accent-bg); color: var(--accent); }
.btn-icon-open    { background: var(--teal-bg);   color: var(--teal); }
.btn-icon-paid    { background: var(--green-bg);  color: var(--green); }
.btn-icon-send    { background: var(--amber-bg);  color: var(--amber); }
.btn-icon-email   { background: var(--pink-bg);   color: var(--pink); }
.btn-icon-whatsapp { background: var(--green-bg); color: var(--green); }
.btn-icon-payment { background: var(--green-bg);  color: var(--green); }
.btn-icon-toggle  { background: #ECEBF3;          color: #4B4A6A; }

.btn-icon-edit:hover    { background: var(--blue);   color: #fff; }
.btn-icon-delete:hover  { background: var(--red);    color: #fff; }
.btn-icon-add:hover     { background: var(--green);  color: #fff; }
.btn-icon-details:hover { background: var(--accent); color: #fff; }
.btn-icon-open:hover    { background: var(--teal);   color: #fff; }
.btn-icon-paid:hover    { background: var(--green);  color: #fff; }
.btn-icon-send:hover    { background: var(--amber);  color: #fff; }
.btn-icon-email:hover   { background: var(--pink);   color: #fff; }
.btn-icon-whatsapp:hover { background: var(--green); color: #fff; }
.btn-icon-payment:hover { background: var(--green);  color: #fff; }
.btn-icon-toggle:hover  { background: #15142B;       color: #fff; }

/* ==========================================================================
   STAT CARDS (components/ui/stat-card.php)
   Coloured summary cards. Colour comes from a .tone-* class (--t-g, projects.css);
   the oversized icon behind the figures is decoration only.
   ========================================================================== */

.stat-card {
  position: relative;
  overflow: hidden;
  padding: 14px 18px;
  border-radius: 14px;
  background: var(--t-g);
  color: #fff;
}

.stat-card-bg {
  position: absolute;
  right: -10px;
  bottom: -18px;
  font-size: 84px;
  line-height: 1;
  color: rgba(255, 255, 255, .16);
  pointer-events: none;
}

.stat-card-l {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 8px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, .92);
}

.stat-card-i {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: rgba(255, 255, 255, .22);
  font-size: 14px;
  letter-spacing: 0;
}

.stat-card-n {
  white-space: nowrap;
  font-size: 30px;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}

.stat-block {
  padding: 8px 14px 10px;
  border-radius: 10px;
  background: rgba(255, 255, 255, .16);
}

.stat-block-l {
  display: block;
  margin-bottom: 2px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, .8);
}

.stat-block-eq {
  display: block;
  font-size: 12.5px;
  font-weight: 550;
  color: rgba(255, 255, 255, .85);
  font-variant-numeric: tabular-nums;
}

.stat-card-note {
  display: inline-block;
  margin: 8px 0 0;
  padding: 2px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .2);
  font-size: 11.5px;
  font-weight: 550;
  line-height: 1.5;
}

/* ==========================================================================
   LIVE METER FILL
   Add .meter-live to the inner fill of any progress bar whose track has a
   rounded shape: it grows in from the left once, then a light sweep keeps it
   looking live. The fill's own width, colour and radius stay with the page.
   ========================================================================== */

.meter-live {
  position: relative;
  overflow: hidden;
  transform-origin: left center;
  animation: meterIn .7s cubic-bezier(.22, 1, .36, 1);
}

.meter-live::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, transparent 20%, rgba(255, 255, 255, .55) 50%, transparent 80%);
  transform: translateX(-100%);
  animation: meterSheen 2.6s ease-in-out 1s infinite;
}

@keyframes meterIn {
  from { transform: scaleX(0); }
  to   { transform: scaleX(1); }
}

@keyframes meterSheen {
  0%        { transform: translateX(-100%); }
  45%, 100% { transform: translateX(220%); }
}

/* Motion is decoration — the figures beside the bar say the same thing. */
@media (prefers-reduced-motion: reduce) {
  .meter-live { animation: none; }
  .meter-live::after { content: none; }
}

/* ==========================================================================
   FORM FIELDS (components/ui/form-fields.php)
   Shared label / input / select / checkbox / image styles.
   ========================================================================== */

/* Material-style floating label field */
.mat-field {
  position: relative;
  margin-bottom: 0;
}
.mat-field input,
.mat-field select,
.mat-field textarea {
  width: 100%;
  padding: 22px 0 6px;
  font-size: 14px;
  font-family: inherit;
  color: var(--ink);
  background: transparent;
  border: none;
  border-bottom: 1.5px solid var(--line);
  border-radius: 0;
  outline: none;
  transition: border-color 0.2s;
  appearance: none;
  -webkit-appearance: none;
}
.mat-field select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%239997AD' d='M2.5 4.5L6 8l3.5-3.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 2px center;
  background-size: 14px;
  padding-right: 20px;
  cursor: pointer;
}
.mat-field textarea {
  min-height: 60px;
  resize: vertical;
}
.mat-field label {
  position: absolute;
  left: 0;
  top: 20px;
  font-size: 14px;
  color: var(--faint);
  pointer-events: none;
  transition: all 0.2s ease;
}
.mat-field input:focus ~ label,
.mat-field input:not(:placeholder-shown) ~ label,
.mat-field select:focus ~ label,
.mat-field select:not([data-empty]) ~ label,
.mat-field textarea:focus ~ label,
.mat-field textarea:not(:placeholder-shown) ~ label,
.mat-field .mat-label-up {
  top: 2px;
  font-size: 10.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--faint);
}
.mat-field input:focus ~ label,
.mat-field select:focus ~ label,
.mat-field textarea:focus ~ label {
  color: var(--accent);
}
.mat-field input:focus,
.mat-field select:focus,
.mat-field textarea:focus {
  border-bottom-color: var(--accent);
}
.mat-field input[type="color"] {
  padding: 4px 0;
  height: 36px;
  border-bottom: 1.5px solid var(--line);
  cursor: pointer;
}
.mat-field input[type="file"] {
  padding: 10px 0 6px;
  font-size: 13px;
}
.mat-field input[type="file"]::file-selector-button {
  background: var(--accent-bg);
  color: var(--accent);
  border: 0;
  border-radius: 6px;
  font-weight: 600;
  padding: 4px 10px;
  margin-right: 10px;
  font-size: 12px;
}

/* Legacy .ui-label / .ui-input kept for any page not yet converted */
.ui-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--soft);
  margin-bottom: 6px;
}
.ui-input {
  background-color: var(--panel);
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 10px;
  font-size: 14px;
  padding-top: 0.55rem;
  padding-bottom: 0.55rem;
  padding-left: 0.85rem;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.ui-input::placeholder { color: var(--faint); }
.ui-input:focus {
  background-color: var(--panel);
  color: var(--ink);
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-bg);
}

.ui-check .form-check-input {
  border-color: var(--faint);
  cursor: pointer;
}

.ui-check .form-check-input:checked {
  background-color: var(--accent);
  border-color: var(--accent);
}

.ui-check .form-check-input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-bg);
}

/* Toggle switch: keep the knob grey while focused (Bootstrap turns it blue) */
.ui-switch .form-check-input:not(:checked):focus {
  --bs-form-switch-bg: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='rgba%280, 0, 0, 0.25%29'/%3e%3c/svg%3e");
}

.ui-check .form-check-label {
  cursor: pointer;
  color: var(--ink);
}

.ui-img {
  max-width: 100%;
  object-fit: contain;
}

.ui-img-thumb {
  width: 44px;
  height: 44px;
}

/* ==========================================================================
   FORM SAVE BUTTON (.form-save-btn)
   Full-width, pill-shaped submit button used at the bottom of forms.
   ========================================================================== */

.form-save-btn {
  width: 100%;
  border: 0;
  border-radius: 50rem;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  padding: 0.65rem 1.25rem;
  transition: background-color 0.15s ease, transform 0.15s ease;
}

.form-save-btn:hover,
.form-save-btn:focus {
  background: #5a3bd6;
  color: #fff;
}

.form-save-btn:active {
  transform: scale(0.99);
}

/* Range slider (uiRange) */
.ui-range::-webkit-slider-runnable-track {
  height: 6px;
  border-radius: 6px;
  background: var(--line);
}

.ui-range::-moz-range-track {
  height: 6px;
  border-radius: 6px;
  background: var(--line);
}

.ui-range::-webkit-slider-thumb {
  background: var(--accent);
  margin-top: -6px;
  width: 18px;
  height: 18px;
}

.ui-range::-moz-range-thumb {
  background: var(--accent);
  width: 18px;
  height: 18px;
  border: 0;
}

.ui-range:focus::-webkit-slider-thumb {
  box-shadow: 0 0 0 4px var(--accent-bg);
}

.ui-range:focus::-moz-range-thumb {
  box-shadow: 0 0 0 4px var(--accent-bg);
}

/* ==========================================================================
   SOFT BUTTONS (.btn-soft + a colour: -blue, -red, -red-solid, -gray)
   Small pill buttons with a tinted background that fills in on hover.
   ========================================================================== */

.btn-soft {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 16px;
  border: 0;
  border-radius: 50rem;
  font-size: 13px;
  font-weight: 700;
  transition: background-color 0.15s ease, color 0.15s ease, transform 0.15s ease;
}

.btn-soft:hover { transform: translateY(-1px); }
.btn-soft:active { transform: translateY(0); }

.btn-soft-blue { background: var(--blue-bg); color: var(--blue); }
.btn-soft-blue:hover { background: var(--blue); color: #fff; }

.btn-soft-red { background: var(--red-bg); color: var(--red); }
.btn-soft-red:hover { background: var(--red); color: #fff; }

.btn-soft-red-solid { background: var(--red); color: #fff; }
.btn-soft-red-solid:hover { background: #c42f26; color: #fff; }

.btn-soft-gray { background: var(--bg); color: var(--soft); }
.btn-soft-gray:hover { background: var(--line); color: var(--ink); }

/* ==========================================================================
   SEARCHABLE SELECT (.ui-search-select) — markup from uiSearchSelect()
   ========================================================================== */
.ui-search-toggle {
  cursor: pointer;
  text-align: left;
}

.ui-search-toggle .ui-search-text.is-placeholder { color: var(--faint); }

.ui-search-menu {
  border-radius: 12px;
  border-color: var(--line);
  box-shadow: 0 14px 34px rgba(21, 20, 43, 0.14);
}

.ui-search-list {
  max-height: 260px;
  overflow-y: auto;
}

.ui-search-option {
  border-radius: 8px;
  padding: 10px 12px;
  white-space: normal;
}

.ui-search-option.active {
  background: var(--accent-bg);
  color: var(--accent);
  font-weight: 600;
}


/* ==========================================================================
   HEADERLESS MODAL SHELL (.ui-modal) — no .modal-header; the close button
   floats over the body, which carries all the spacing. Used by the stock
   modals (.stock-modal) and the domain modal.
   ========================================================================== */
.ui-modal .modal-body,
.stock-modal .modal-body {
  padding: 38px 24px 24px;
}

.ui-modal-close,
.stock-modal-close {
  position: absolute;
  top: 10px;
  right: 12px;
  z-index: 5;
  width: 32px;
  height: 32px;
  padding: 0;
  border-radius: 50%;
  background-color: var(--bg);
  background-size: 0.8em;
  opacity: 0.55;
  transition: background-color 0.15s ease, opacity 0.15s ease;
}

.ui-modal-close:hover,
.ui-modal-close:focus-visible,
.stock-modal-close:hover,
.stock-modal-close:focus-visible {
  background-color: var(--line);
  opacity: 1;
}

@media (max-width: 575.98px) {
  .ui-modal .modal-body,
  .stock-modal .modal-body { padding: 36px 16px 20px; }
}
