:root {
      --bg-main: #020713;
      --bg-deep: #050816;
      --bg-panel: rgba(9, 20, 43, 0.84);
      --bg-panel-2: rgba(13, 25, 53, 0.88);
      --bg-soft: rgba(255, 255, 255, 0.045);

      --border-soft: rgba(148, 163, 184, 0.14);
      --border-blue: rgba(59, 130, 246, 0.28);
      --border-cyan: rgba(34, 211, 238, 0.25);
      --border-green: rgba(34, 197, 94, 0.25);

      --text-main: #f8fafc;
      --text-soft: #cbd5e1;
      --text-muted: #93a4c7;
      --text-faint: #64748b;

      --cyan: #22d3ee;
      --blue: #3b82f6;
      --violet: #7c3aed;
      --purple: #a855f7;
      --green: #22c55e;
      --red: #ef4444;
      --orange: #f97316;
      --yellow: #facc15;

      --shadow-main: 0 24px 70px rgba(0, 0, 0, 0.42);
      --shadow-soft: 0 18px 45px rgba(0, 0, 0, 0.28);

      --radius-xl: 28px;
      --radius-lg: 22px;
      --radius-md: 16px;
      --radius-sm: 12px;

      --sidebar-width: 260px;
    }

    * {
      box-sizing: border-box;
      margin: 0;
      padding: 0;
    }

    html {
      scroll-behavior: smooth;
    }

    body {
      min-height: 100vh;
      font-family:
        Inter,
        ui-sans-serif,
        system-ui,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        Roboto,
        Arial,
        sans-serif;
      color: var(--text-main);
      background:
        radial-gradient(circle at 12% 0%, rgba(34, 211, 238, 0.14), transparent 32%),
        radial-gradient(circle at 82% 5%, rgba(124, 58, 237, 0.20), transparent 34%),
        linear-gradient(135deg, #030712 0%, #061225 42%, #0b1028 100%);
      overflow-x: hidden;
    }

    body::before {
      content: "";
      position: fixed;
      inset: 0;
      z-index: 0;
      pointer-events: none;
      background-image:
        linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
      background-size: 58px 58px;
      mask-image: radial-gradient(circle at top, black, transparent 72%);
      opacity: 0.45;
    }

    body::after {
      content: "";
      position: fixed;
      inset: 0;
      z-index: 0;
      pointer-events: none;
      background:
        radial-gradient(circle at 60% 40%, rgba(34, 211, 238, 0.06), transparent 32%),
        radial-gradient(circle at 95% 80%, rgba(168, 85, 247, 0.08), transparent 26%);
      opacity: 0.9;
    }

    button,
    input {
      font-family: inherit;
    }

    button {
      border: 0;
      cursor: pointer;
    }

    input {
      width: 100%;
      border: 1px solid rgba(148, 163, 184, 0.18);
      outline: none;
      background: rgba(4, 10, 24, 0.78);
      color: var(--text-main);
      padding: 14px 16px;
      border-radius: 14px;
      font-size: 14px;
      transition: 0.22s ease;
    }

    input::placeholder {
      color: #6f7f9f;
    }

    input:focus {
      border-color: rgba(34, 211, 238, 0.52);
      box-shadow: 0 0 0 4px rgba(34, 211, 238, 0.08);
    }

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

    .hidden {
      display: none !important;
    }

    .gradient-text {
      background: linear-gradient(90deg, #22d3ee 0%, #3b82f6 42%, #a855f7 78%);
      -webkit-background-clip: text;
      background-clip: text;
      color: transparent;
    }

    .green-text {
      color: #22c55e;
    }

    .red-text {
      color: #fb7185;
    }

    .yellow-text {
      color: #fde68a;
    }

    .cyan-text {
      color: #67e8f9;
    }

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

    .mini-muted {
      font-size: 12px;
      color: #93a7cc;
    }

    /* AUTH */

    .auth-page {
      min-height: 100vh;
      display: grid;
      place-items: center;
      padding: 28px;
      position: relative;
      z-index: 2;
    }

    .auth-card {
      width: min(1060px, 100%);
      display: grid;
      grid-template-columns: 1.05fr 0.95fr;
      gap: 22px;
      background: linear-gradient(135deg, rgba(15, 23, 42, 0.72), rgba(30, 27, 75, 0.48));
      border: 1px solid var(--border-soft);
      border-radius: 30px;
      padding: 22px;
      box-shadow: var(--shadow-main);
      backdrop-filter: blur(22px);
      -webkit-backdrop-filter: blur(22px);
    }

    .auth-hero {
      min-height: 560px;
      border-radius: 25px;
      padding: 34px;
      background:
        linear-gradient(90deg, rgba(2, 6, 23, 0.92), rgba(2, 6, 23, 0.56)),
        url("../icons/banner1.png") center right / cover no-repeat;
      border: 1px solid rgba(34, 211, 238, 0.16);
      position: relative;
      overflow: hidden;
    }

    .auth-hero::after {
      content: "";
      position: absolute;
      inset: auto -80px -120px auto;
      width: 360px;
      height: 360px;
      background: radial-gradient(circle, rgba(34, 211, 238, 0.18), transparent 62%);
      filter: blur(4px);
    }

    .logo-row,
    .sidebar-brand {
      display: flex;
      align-items: center;
      gap: 14px;
    }

    .logo-mark {
      width: 64px;
      height: 64px;
      border-radius: 20px;
      display: grid;
      place-items: center;
      position: relative;
      overflow: hidden;
      background: linear-gradient(135deg, rgba(34, 211, 238, 0.95), rgba(79, 70, 229, 0.90), rgba(236, 72, 153, 0.86));
      box-shadow:
        0 0 34px rgba(34, 211, 238, 0.30),
        inset 0 0 0 2px rgba(255, 255, 255, 0.16);
    }

    .logo-img {
      width: 100%;
      height: 100%;
      object-fit: cover;
      border-radius: 18px;
    }

    .brand-title {
      font-weight: 800;
      font-size: 21px;
      letter-spacing: -0.5px;
    }

    .brand-sub {
      color: #a8b5d1;
      font-size: 13px;
      font-weight: 600;
      margin-top: 2px;
    }

    .auth-hero h1 {
      margin-top: 55px;
      font-size: clamp(38px, 5vw, 64px);
      line-height: 0.98;
      letter-spacing: -2px;
      font-weight: 850;
    }

    .auth-hero p {
      margin-top: 18px;
      max-width: 560px;
      color: #b8c7e6;
      line-height: 1.7;
      font-size: 16px;
    }

    .auth-points {
      margin-top: 36px;
      display: grid;
      gap: 14px;
    }

    .auth-point {
      display: flex;
      align-items: center;
      gap: 12px;
      color: #dbeafe;
      background: rgba(255, 255, 255, 0.045);
      border: 1px solid rgba(255, 255, 255, 0.08);
      border-radius: 16px;
      padding: 13px 15px;
      backdrop-filter: blur(10px);
    }

    .auth-form-wrap {
      border-radius: 25px;
      border: 1px solid rgba(148, 163, 184, 0.16);
      background: rgba(8, 13, 31, 0.84);
      padding: 26px;
      align-self: stretch;
      display: flex;
      flex-direction: column;
      justify-content: center;
    }

    .auth-form-wrap h2 {
      font-size: 28px;
      letter-spacing: -1px;
      font-weight: 800;
    }

    .auth-form-wrap p {
      color: #9fb0d0;
      margin-top: 7px;
      line-height: 1.6;
    }

    .tab-row {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 10px;
      margin: 22px 0;
    }

    .form {
      display: grid;
      gap: 12px;
    }

    .message {
      color: #93c5fd;
      font-size: 13px;
      line-height: 1.5;
      min-height: 20px;
      word-break: break-word;
    }

    /* BUTTONS */

    .tab-btn,
    .primary-btn,
    .danger-btn,
    .small-btn,
    .ghost-btn,
    .view-btn {
      min-height: 44px;
      border-radius: 14px;
      font-weight: 700;
      color: white;
      transition: 0.22s ease;
    }

    .tab-btn {
      background: rgba(255, 255, 255, 0.06);
      border: 1px solid rgba(255, 255, 255, 0.08);
    }

    .tab-btn.active,
    .primary-btn,
    .small-btn {
      background: linear-gradient(90deg, #22d3ee, #3b82f6, #7c3aed);
      box-shadow: 0 14px 34px rgba(59, 130, 246, 0.18);
    }

    .danger-btn,
    .small-btn.red {
      background: linear-gradient(90deg, #ef4444, #f97316);
      box-shadow: 0 14px 34px rgba(239, 68, 68, 0.16);
    }

    .ghost-btn {
      padding: 0 16px;
      background: rgba(2, 10, 28, 0.58);
      border: 1px solid rgba(59, 130, 246, 0.35);
      color: #93c5fd;
    }

    .view-btn {
      padding: 0 15px;
      background: rgba(2, 10, 28, 0.58);
      border: 1px solid rgba(34, 211, 238, 0.25);
      color: #bae6fd;
    }

    .ghost-btn:hover,
    .primary-btn:hover,
    .small-btn:hover,
    .danger-btn:hover,
    .view-btn:hover {
      transform: translateY(-1px);
      filter: brightness(1.08);
    }

    /* MAIN LAYOUT */

    .page {
      position: relative;
      z-index: 1;
      min-height: 100vh;
      padding: 18px;
    }

    .shell {
      width: min(1640px, 100%);
      margin: 0 auto;
      display: grid;
      grid-template-columns: var(--sidebar-width) 1fr;
      gap: 22px;
      align-items: start;
    }

    .sidebar {
      position: sticky;
      top: 18px;
      min-height: calc(100vh - 36px);
      border-radius: 26px;
      border: 1px solid rgba(148, 163, 184, 0.15);
      background:
        radial-gradient(circle at 20% 0%, rgba(34, 211, 238, 0.13), transparent 36%),
        linear-gradient(180deg, rgba(9, 22, 45, 0.92), rgba(5, 10, 24, 0.96));
      box-shadow: var(--shadow-main);
      padding: 18px;
      display: flex;
      flex-direction: column;
      overflow: hidden;
      backdrop-filter: blur(22px);
      -webkit-backdrop-filter: blur(22px);
    }

    .sidebar::before {
      content: "";
      position: absolute;
      inset: 0;
      background: radial-gradient(circle at top left, rgba(34, 211, 238, 0.10), transparent 46%);
      pointer-events: none;
    }

    .sidebar > * {
      position: relative;
      z-index: 1;
    }

    .sidebar-brand {
      flex-direction: column;
      text-align: center;
      padding: 14px 0 22px;
      border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    }

    .sidebar-brand .logo-mark {
      width: 88px;
      height: 88px;
      border-radius: 26px;
      margin-bottom: 4px;
    }

    .sidebar-brand .logo-img {
      border-radius: 24px;
    }

    .sidebar-brand .brand-title {
      font-size: 25px;
      margin-top: 4px;
    }

    .nav {
      margin-top: 22px;
      display: grid;
      gap: 10px;
    }

    .nav-item {
      text-decoration: none;
      color: #b9c5de;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 12px;
      border-radius: 14px;
      padding: 14px 14px;
      background: rgba(2, 10, 28, 0.36);
      border: 1px solid rgba(255, 255, 255, 0.045);
      font-weight: 650;
      transition: 0.22s ease;
    }

    .nav-item:hover,
    .nav-item.active {
      color: white;
      border-color: rgba(34, 211, 238, 0.34);
      background: linear-gradient(90deg, rgba(34, 211, 238, 0.16), rgba(124, 58, 237, 0.24));
      box-shadow:
        0 0 0 1px rgba(34, 211, 238, 0.12),
        0 16px 32px rgba(14, 165, 233, 0.08);
    }

    .nav-left {
      display: inline-flex;
      align-items: center;
      gap: 11px;
    }

    .nav-tag {
      font-size: 11px;
      color: #92a2c2;
      font-weight: 700;
    }

    .nav-ico,
    .point-ico,
    .top-ico {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      flex: 0 0 auto;
    }

    .nav-ico svg,
    .point-ico svg,
    .top-ico svg,
    .stat-icon svg {
      width: 18px;
      height: 18px;
      stroke: currentColor;
      fill: none;
      stroke-width: 1.9;
      stroke-linecap: round;
      stroke-linejoin: round;
    }

    .point-ico {
      width: 24px;
      height: 24px;
      border-radius: 999px;
      background: rgba(34, 211, 238, 0.12);
      color: #67e8f9;
    }

    .sidebar-spacer {
      flex: 1;
      min-height: 18px;
    }

    .user-mini {
      display: flex;
      align-items: center;
      gap: 12px;
      border-radius: 18px;
      padding: 13px;
      background: rgba(255, 255, 255, 0.05);
      border: 1px solid rgba(255, 255, 255, 0.08);
      margin-bottom: 14px;
    }

    .user-mini .name {
      font-weight: 750;
    }

    .user-mini .email {
      font-size: 12px;
      color: #9fb0d0;
      overflow: hidden;
      text-overflow: ellipsis;
    }

    .avatar {
      width: 52px;
      height: 52px;
      border-radius: 999px;
      display: grid;
      place-items: center;
      font-weight: 800;
      font-size: 17px;
      background: linear-gradient(135deg, rgba(34, 211, 238, 0.12), rgba(124, 58, 237, 0.30));
      border: 2px solid rgba(34, 211, 238, 0.50);
      box-shadow: 0 0 0 2px rgba(168, 85, 247, 0.18);
      flex: 0 0 auto;
    }

    .security-panel,
    .security-box {
      border-radius: 18px;
      padding: 16px;
      background: linear-gradient(135deg, rgba(5, 85, 76, 0.30), rgba(8, 47, 73, 0.24));
      border: 1px solid rgba(34, 197, 94, 0.24);
      color: #d1fae5;
      line-height: 1.6;
      font-size: 13px;
    }

    .security-head {
      display: flex;
      align-items: center;
      gap: 10px;
      font-weight: 750;
      color: #86efac;
      margin-bottom: 7px;
    }

        .main {
      min-width: 0;
    }

    .topbar {
      min-height: 46px;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 18px;
      margin-bottom: 14px;
    }

    .searchbar {
      width: min(480px, 100%);
      display: flex;
      align-items: center;
      gap: 10px;
      border: 1px solid rgba(148, 163, 184, 0.14);
      background: rgba(4, 10, 26, 0.66);
      border-radius: 15px;
      padding: 0 14px;
      box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035);
    }

    .searchbar input {
      border: 0;
      box-shadow: none;
      background: transparent;
      padding: 13px 0;
    }

    .searchbar .icon {
      color: #93c5fd;
      font-size: 17px;
    }

    .top-actions {
      display: flex;
      align-items: center;
      justify-content: flex-end;
      flex-wrap: wrap;
      gap: 10px;
    }

    .top-divider {
      width: 1px;
      height: 28px;
      background: rgba(148, 163, 184, 0.22);
      margin: 0 2px;
    }

    .bell {
      position: relative;
      width: 38px;
      height: 38px;
      border-radius: 999px;
      display: grid;
      place-items: center;
      border: 1px solid rgba(148, 163, 184, 0.16);
      background: rgba(5, 10, 25, 0.48);
      color: #cbd5e1;
    }

    .bell-dot {
      position: absolute;
      top: -5px;
      right: -4px;
      min-width: 18px;
      height: 18px;
      display: grid;
      place-items: center;
      border-radius: 999px;
      background: linear-gradient(135deg, #3b82f6, #7c3aed);
      font-size: 10px;
      font-weight: 800;
      color: white;
      box-shadow: 0 0 16px rgba(124, 58, 237, 0.45);
    }

    /* HERO */

    .hero-panel {
      position: relative;
      overflow: hidden;
      min-height: 156px;
      border-radius: 22px;
      border: 1px solid rgba(59, 130, 246, 0.24);
      background-image:
        linear-gradient(90deg, rgba(3, 7, 18, 0.62) 0%, rgba(3, 7, 18, 0.36) 42%, rgba(3, 7, 18, 0.08) 100%),
        url("../icons/banner1.png");
      background-repeat: no-repeat, no-repeat;
      background-size: 100% 100%, cover;
      background-position: center, right 56%;
      box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.05),
        0 24px 60px rgba(0, 0, 0, 0.28);
      margin-bottom: 14px;
    }

    .hero-panel::before {
      content: "";
      position: absolute;
      inset: 0;
      background:
        linear-gradient(90deg, rgba(2, 6, 23, 0.22), transparent 48%),
        radial-gradient(circle at 18% 50%, rgba(34, 211, 238, 0.07), transparent 34%);
      pointer-events: none;
    }

    .hero-content {
      position: relative;
      z-index: 1;
      padding: 30px 30px;
      width: min(760px, 100%);
    }

    .hero-panel h1 {
      font-size: clamp(31px, 3vw, 43px);
      letter-spacing: -1.2px;
      line-height: 1.05;
      font-weight: 850;
    }

    .hero-panel p {
      margin-top: 10px;
      max-width: 680px;
      color: #b7c8ec;
      line-height: 1.6;
      font-size: 15px;
    }

    .live-line {
      margin-top: 18px;
      display: flex;
      align-items: center;
      gap: 12px;
      color: #b8c7e6;
      font-size: 13px;
      flex-wrap: wrap;
    }

    .dot {
      width: 9px;
      height: 9px;
      border-radius: 999px;
      background: #22c55e;
      box-shadow: 0 0 14px rgba(34, 197, 94, 0.80);
    }

    /* GLOBAL UI */

    .pill,
    .badge,
    .status-pill,
    .side-pill {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: fit-content;
      border-radius: 999px;
      padding: 7px 11px;
      font-weight: 750;
      font-size: 12px;
      color: #67e8f9;
      background: rgba(34, 211, 238, 0.10);
      border: 1px solid rgba(34, 211, 238, 0.18);
      white-space: nowrap;
    }

    .pill.green,
    .status-pill {
      color: #86efac;
      background: rgba(34, 197, 94, 0.14);
      border-color: rgba(34, 197, 94, 0.20);
    }

    .pill.purple,
    .status-pill.stopped {
      color: #c4b5fd;
      background: rgba(124, 58, 237, 0.16);
      border-color: rgba(124, 58, 237, 0.20);
    }

    .badge {
      color: #7dd3fc;
      background: rgba(14, 116, 144, 0.20);
      border-color: rgba(34, 211, 238, 0.18);
    }

    .card,
    .stat-card,
    .mini-card,
    .page-panel {
      border: 1px solid rgba(148, 163, 184, 0.14);
      background:
        linear-gradient(135deg, rgba(13, 27, 57, 0.82), rgba(12, 18, 42, 0.88));
      border-radius: 20px;
      box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.05),
        0 20px 48px rgba(0, 0, 0, 0.20);
      backdrop-filter: blur(22px);
      -webkit-backdrop-filter: blur(22px);
      transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
    }

    .card:hover,
    .stat-card:hover,
    .mini-card:hover,
    .page-panel:hover,
    .exchange-card:hover,
    .bot-card:hover,
    .watch-card:hover,
    .dashboard-action-card:hover {
      border-color: rgba(34, 211, 238, 0.28);
      box-shadow:
        0 22px 55px rgba(0, 0, 0, 0.28),
        0 0 0 1px rgba(34, 211, 238, 0.04);
      transform: translateY(-1px);
    }

    .card {
      padding: 18px;
      overflow: hidden;
    }

    .card-header,
    .section-header {
      display: flex;
      justify-content: space-between;
      align-items: center;
      gap: 12px;
      margin-bottom: 15px;
    }

    .card-title,
    .section-title {
      font-size: 20px;
      letter-spacing: -0.5px;
      font-weight: 780;
    }

    .section-subtitle {
      color: #93a7cc;
      font-size: 13px;
      line-height: 1.5;
      margin-top: 4px;
    }

    .profile-box,
    .status-compact,
    .warning-box,
    .meta-box,
    .reason {
      background: rgba(5, 10, 25, 0.40);
      border: 1px solid rgba(148, 163, 184, 0.08);
      border-radius: 15px;
      padding: 14px;
      color: #dbeafe;
      line-height: 1.55;
    }

    .warning-box {
      margin-bottom: 14px;
      color: #fde68a;
      background: rgba(245, 158, 11, 0.12);
      border-color: rgba(245, 158, 11, 0.24);
      font-weight: 650;
    }

    /* PAGE SWITCHING */

    .app-page {
      display: none;
      animation: softFade 0.18s ease;
    }

    .app-page.active {
      display: block;
    }

    @keyframes softFade {
      from {
        opacity: 0;
        transform: translateY(6px);
      }

      to {
        opacity: 1;
        transform: translateY(0);
      }
    }

    .page-head {
      display: flex;
      align-items: flex-start;
      justify-content: space-between;
      gap: 16px;
      margin-bottom: 14px;
    }

    .page-title {
      font-size: 28px;
      line-height: 1.08;
      letter-spacing: -0.8px;
      font-weight: 850;
    }

    .page-desc {
      color: #93a7cc;
      max-width: 760px;
      font-size: 14px;
      line-height: 1.6;
      margin-top: 6px;
    }

    .compact-page-grid {
      display: grid;
      grid-template-columns: 1fr 1fr;
      gap: 14px;
      align-items: start;
    }

    .wide-grid {
      display: grid;
      grid-template-columns: 1fr;
      gap: 14px;
    }

    .dashboard-home-grid {
      display: grid;
      grid-template-columns: 1.12fr 0.88fr;
      gap: 14px;
      align-items: start;
    }

    .dashboard-action-grid {
      display: grid;
      grid-template-columns: repeat(3, minmax(0, 1fr));
      gap: 12px;
    }

    .dashboard-action-card {
      min-height: 132px;
      border-radius: 20px;
      border: 1px solid rgba(148, 163, 184, 0.14);
      background:
        radial-gradient(circle at 18% 0%, rgba(34, 211, 238, 0.12), transparent 36%),
        rgba(5, 10, 25, 0.42);
      padding: 16px;
      display: flex;
      flex-direction: column;
      justify-content: space-between;
      transition: 0.22s ease;
    }

    .action-top {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 12px;
    }

    .action-title {
      font-size: 16px;
      font-weight: 820;
      letter-spacing: -0.3px;
    }

    .action-desc {
      color: #93a7cc;
      font-size: 12.5px;
      line-height: 1.5;
      margin-top: 7px;
    }

    .action-icon {
      width: 40px;
      height: 40px;
      border-radius: 15px;
      display: grid;
      place-items: center;
      color: #67e8f9;
      background: rgba(34, 211, 238, 0.12);
      border: 1px solid rgba(34, 211, 238, 0.10);
      flex: 0 0 auto;
    }

    .action-icon svg {
      width: 19px;
      height: 19px;
      stroke: currentColor;
      fill: none;
      stroke-width: 1.9;
      stroke-linecap: round;
      stroke-linejoin: round;
    }

    .action-link {
      margin-top: 12px;
      color: #7dd3fc;
      font-size: 12px;
      font-weight: 800;
      display: inline-flex;
      align-items: center;
      gap: 6px;
    }

    .stats-row {
      display: grid;
      grid-template-columns: repeat(6, minmax(0, 1fr));
      gap: 12px;
      margin-bottom: 14px;
    }

    .stat-card {
      min-height: 112px;
      padding: 18px;
      display: flex;
      align-items: center;
      gap: 14px;
    }

    .stat-icon {
      width: 48px;
      height: 48px;
      border-radius: 16px;
      display: grid;
      place-items: center;
      color: #67e8f9;
      background:
        radial-gradient(circle at 30% 10%, rgba(34, 211, 238, 0.20), transparent 50%),
        rgba(34, 211, 238, 0.10);
      border: 1px solid rgba(34, 211, 238, 0.10);
      flex: 0 0 auto;
    }

    .stat-icon.green {
      color: #86efac;
      background: rgba(34, 197, 94, 0.12);
    }

    .stat-icon.violet {
      color: #c4b5fd;
      background: rgba(124, 58, 237, 0.13);
    }

    .stat-icon.orange {
      color: #fbbf24;
      background: rgba(245, 158, 11, 0.12);
    }

    .stat-icon.pink {
      color: #f472b6;
      background: rgba(236, 72, 153, 0.12);
    }

    .stat-label {
      color: #9fb0d0;
      font-size: 13px;
      font-weight: 500;
    }

    .stat-value {
      font-size: 26px;
      font-weight: 850;
      margin-top: 5px;
      letter-spacing: -0.5px;
    }

    .stat-sub {
      color: #93a7cc;
      font-size: 12px;
      margin-top: 4px;
    }

    /* EXCHANGE */

    .exchange-grid {
      display: grid;
      grid-template-columns: repeat(4, minmax(0, 1fr));
      gap: 12px;
    }

    .exchange-card {
      min-height: 144px;
      padding: 13px;
      border-radius: 16px;
      text-align: center;
      background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.045), rgba(255, 255, 255, 0.018));
      border: 1px solid rgba(148, 163, 184, 0.12);
      transition: 0.22s ease;
    }

    .exchange-card.active {
      border-color: rgba(34, 197, 94, 0.48);
      box-shadow:
        inset 0 0 0 1px rgba(34, 197, 94, 0.12),
        0 0 24px rgba(34, 197, 94, 0.10);
    }

    .exchange-logo-wrap {
      height: 58px;
      border-radius: 16px;
      display: grid;
      place-items: center;
      background: rgba(255, 255, 255, 0.035);
      border: 1px solid rgba(255, 255, 255, 0.06);
      padding: 8px;
      margin-bottom: 10px;
    }

    .exchange-logo-wrap img {
      max-width: 120px;
      max-height: 30px;
      object-fit: contain;
      display: block;
    }

    .exchange-card.active .exchange-logo-wrap {
      box-shadow:
        0 0 0 1px rgba(34, 197, 94, 0.25),
        0 0 18px rgba(34, 197, 94, 0.15);
    }

    .ex-name {
      font-weight: 780;
      margin: 8px 0;
    }

    .exchange-note {
      font-size: 12px;
      color: #93a7cc;
      margin-top: 5px;
    }

    .add-exchange {
      margin-top: 12px;
      border: 1px dashed rgba(148, 163, 184, 0.22);
      border-radius: 12px;
      padding: 12px;
      text-align: center;
      color: #b8c7e6;
      background: rgba(255, 255, 255, 0.025);
    }

    .exchange-coming {
      display: grid;
      grid-template-columns: repeat(5, minmax(0, 1fr));
      gap: 12px;
      margin-top: 14px;
    }

    .coming-card {
      padding: 13px;
      border-radius: 15px;
      background: rgba(255, 255, 255, 0.045);
      border: 1px solid rgba(255, 255, 255, 0.08);
    }

    /* BOT */

    .bot-grid {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 12px;
      max-height: 520px;
      overflow: auto;
      padding-right: 6px;
    }

    .bot-card,
    .signal-item,
    .watch-card {
      border-radius: 18px;
      padding: 15px;
      border: 1px solid rgba(148, 163, 184, 0.11);
      background: rgba(5, 10, 25, 0.42);
      position: relative;
      overflow: hidden;
    }

    .bot-card::before,
    .watch-card::before,
    .signal-item::before {
      content: "";
      position: absolute;
      inset: 0 0 auto 0;
      height: 1px;
      background: linear-gradient(90deg, transparent, rgba(34, 211, 238, 0.42), rgba(124, 58, 237, 0.34), transparent);
      opacity: 0.60;
    }

    .bot-top,
    .signal-head,
    .watch-head {
      display: flex;
      align-items: flex-start;
      justify-content: space-between;
      gap: 12px;
    }

    .bot-name {
      display: flex;
      align-items: center;
      gap: 12px;
      font-weight: 780;
      letter-spacing: -0.2px;
    }

    .algo-badge {
      width: 42px;
      height: 42px;
      border-radius: 14px;
      display: grid;
      place-items: center;
      font-weight: 850;
      letter-spacing: -0.4px;
      font-size: 14px;
      color: white;
      box-shadow:
        inset 0 0 0 1px rgba(255, 255, 255, 0.08),
        0 10px 24px rgba(0, 0, 0, 0.22);
      flex: 0 0 auto;
    }

    .algo-badge.orange {
      background: linear-gradient(135deg, #f59e0b, #f97316);
    }

    .algo-badge.violet {
      background: linear-gradient(135deg, #6366f1, #8b5cf6);
    }

    .algo-badge.cyan {
      background: linear-gradient(135deg, #06b6d4, #3b82f6);
    }

    .algo-badge.green {
      background: linear-gradient(135deg, #10b981, #22c55e);
    }

    .algo-badge.default {
      background: linear-gradient(135deg, #334155, #475569);
    }

    .bot-meta {
      display: grid;
      grid-template-columns: repeat(3, minmax(0, 1fr));
      gap: 10px;
      margin-top: 13px;
    }

    .meta-box {
      padding: 12px;
    }

    .meta-label {
      color: #91a3c6;
      font-size: 11px;
      margin-bottom: 5px;
    }

    .meta-value {
      font-weight: 760;
      word-break: break-word;
    }

    .bot-actions {
      display: grid;
      grid-template-columns: 1fr 1fr 42px;
      gap: 10px;
      margin-top: 13px;
    }

    .small-btn {
      min-height: 42px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      padding: 0 13px;
    }

    .small-btn.dark {
      background: rgba(255, 255, 255, 0.04);
      border: 1px solid rgba(255, 255, 255, 0.08);
      color: #cbd5e1;
      box-shadow: none;
    }

        /* SIGNALS / TRADES */

    .scroll-area {
      max-height: 540px;
      overflow: auto;
      padding-right: 6px;
      display: grid;
      gap: 10px;
    }

    .pair {
      font-weight: 760;
      letter-spacing: 0.1px;
    }

    .reason {
      margin-top: 10px;
      font-size: 12px;
      color: #b8c7e6;
    }

    .side-pill {
      padding: 6px 10px;
      background: rgba(34, 197, 94, 0.14);
      color: #86efac;
      font-size: 11px;
      border-color: transparent;
    }

    .side-pill.sell,
    .side-pill.short {
      background: rgba(239, 68, 68, 0.14);
      color: #fca5a5;
    }

    .trade-table {
      display: grid;
      gap: 8px;
    }

    .trade-table-head,
    .trade-table-row {
      display: grid;
      grid-template-columns: 1.1fr 0.7fr 0.75fr 0.85fr 0.9fr;
      gap: 10px;
      align-items: center;
    }

    .trade-table-head {
      color: #8aa0c7;
      font-size: 12px;
      padding: 0 8px 6px;
    }

    .trade-table-row {
      background: rgba(5, 10, 25, 0.34);
      border: 1px solid rgba(148, 163, 184, 0.08);
      border-radius: 13px;
      padding: 11px 8px;
      font-size: 13px;
    }

    .coin-dot {
      width: 34px;
      height: 34px;
      border-radius: 999px;
      display: grid;
      place-items: center;
      font-size: 12px;
      font-weight: 850;
      color: #fff;
      flex: 0 0 auto;
      box-shadow:
        inset 0 0 0 1px rgba(255, 255, 255, 0.12),
        0 8px 22px rgba(0, 0, 0, 0.25);
    }

    .coin-dot.btc {
      background: linear-gradient(135deg, #f59e0b, #f97316);
    }

    .coin-dot.eth {
      background: linear-gradient(135deg, #64748b, #8b5cf6);
    }

    .coin-dot.sol {
      background: linear-gradient(135deg, #14f195, #9945ff);
    }

    .coin-dot.bnb {
      background: linear-gradient(135deg, #facc15, #f59e0b);
    }

    .coin-dot.xrp {
      background: linear-gradient(135deg, #334155, #94a3b8);
    }

    .coin-row {
      display: flex;
      align-items: center;
      gap: 10px;
    }

    /* BINANCE STYLE MARKET WATCH */

    .market-card-premium {
      position: relative;
      overflow: hidden;
    }

    .market-card-premium::after {
      content: "";
      position: absolute;
      right: -120px;
      top: -120px;
      width: 260px;
      height: 260px;
      background: radial-gradient(circle, rgba(250, 204, 21, 0.10), transparent 62%);
      pointer-events: none;
    }

    .market-card-premium > * {
      position: relative;
      z-index: 1;
    }

    .market-topbar {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 12px;
      flex-wrap: wrap;
      margin-bottom: 14px;
    }

    .market-tabs {
      display: flex;
      flex-wrap: wrap;
      gap: 8px;
    }

    .market-tab {
      min-height: 34px;
      border-radius: 999px;
      padding: 0 14px;
      font-size: 12px;
      font-weight: 800;
      color: #94a3b8;
      background: rgba(2, 8, 23, 0.55);
      border: 1px solid rgba(148, 163, 184, 0.14);
    }

    .market-tab.active {
      color: #f8fafc;
      border-color: rgba(250, 204, 21, 0.40);
      background: linear-gradient(135deg, rgba(250, 204, 21, 0.16), rgba(59, 130, 246, 0.10));
      box-shadow: 0 0 22px rgba(250, 204, 21, 0.08);
    }

    .market-sync {
      display: flex;
      align-items: center;
      gap: 8px;
      color: #94a3b8;
      font-size: 12px;
    }

    .market-sync-dot {
      width: 8px;
      height: 8px;
      border-radius: 999px;
      background: #22c55e;
      box-shadow: 0 0 13px rgba(34, 197, 94, 0.75);
    }

    .rankings-grid {
      display: grid;
      grid-template-columns: 1fr;
      gap: 14px;
    }

    .ranking-card {
      border-radius: 18px;
      background: rgba(2, 6, 23, 0.48);
      border: 1px solid rgba(148, 163, 184, 0.13);
      box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035);
      overflow: hidden;
    }

    .ranking-card-header {
      display: flex;
      align-items: center;
      justify-content: space-between;
      padding: 16px 16px 10px;
      gap: 12px;
    }

    .ranking-title {
      display: flex;
      align-items: center;
      gap: 9px;
      font-size: 18px;
      line-height: 1;
      font-weight: 850;
      letter-spacing: -0.45px;
    }

    .ranking-title .accent {
      width: 7px;
      height: 22px;
      border-radius: 999px;
      background: linear-gradient(180deg, #facc15, #f97316);
      box-shadow: 0 0 18px rgba(250, 204, 21, 0.20);
    }

    .ranking-filter {
      border-radius: 999px;
      padding: 7px 10px;
      color: #cbd5e1;
      background: rgba(15, 23, 42, 0.78);
      border: 1px solid rgba(148, 163, 184, 0.16);
      font-size: 12px;
      font-weight: 750;
    }

    .ranking-head,
    .ranking-row {
      display: grid;
      grid-template-columns: 42px minmax(140px, 1.15fr) minmax(88px, 0.9fr) minmax(72px, 0.8fr);
      gap: 10px;
      align-items: center;
    }

    .ranking-head {
      padding: 9px 16px;
      color: #687897;
      font-size: 11px;
      font-weight: 750;
      border-bottom: 1px solid rgba(148, 163, 184, 0.08);
    }

    .ranking-row {
      padding: 10px 16px;
      border-bottom: 1px solid rgba(148, 163, 184, 0.065);
      transition: 0.18s ease;
    }

    .ranking-row:hover {
      background: rgba(255, 255, 255, 0.035);
    }

    .rank-number {
      color: #64748b;
      font-size: 13px;
      font-weight: 800;
    }

    .rank-coin {
      display: flex;
      align-items: center;
      gap: 9px;
      min-width: 0;
    }

    .coin-logo {
      width: 26px;
      height: 26px;
      border-radius: 999px;
      object-fit: cover;
      background: rgba(255, 255, 255, 0.08);
      flex: 0 0 auto;
    }

    .coin-fallback {
      width: 26px;
      height: 26px;
      border-radius: 999px;
      display: none;
      place-items: center;
      font-size: 10px;
      font-weight: 900;
      color: #fff;
      background: linear-gradient(135deg, #f59e0b, #7c3aed);
      flex: 0 0 auto;
    }

    .rank-symbol {
      font-size: 13px;
      font-weight: 850;
      color: #f8fafc;
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
    }

    .rank-name {
      margin-top: 2px;
      color: #64748b;
      font-size: 10.5px;
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
    }

    .rank-price {
      font-size: 13px;
      font-weight: 800;
      color: #e5e7eb;
      text-align: right;
    }

    .rank-change {
      font-size: 13px;
      font-weight: 850;
      text-align: right;
      color: #22c55e;
    }

    .rank-change.down {
      color: #f43f5e;
    }

    .market-note {
      margin-top: 12px;
      padding: 11px 13px;
      border-radius: 14px;
      color: #9fb0d0;
      background: rgba(2, 6, 23, 0.34);
      border: 1px solid rgba(148, 163, 184, 0.10);
      font-size: 12px;
      line-height: 1.5;
    }

    .toast {
      position: fixed;
      right: 22px;
      bottom: 22px;
      z-index: 99999;
      max-width: 420px;
      padding: 14px 16px;
      border-radius: 16px;
      background: rgba(15, 23, 42, 0.95);
      border: 1px solid rgba(34, 211, 238, 0.25);
      color: white;
      box-shadow: var(--shadow-main);
      display: none;
      line-height: 1.55;
    }

    .toast.show {
      display: block;
      animation: popIn 0.22s ease;
    }

    @keyframes popIn {
      from {
        transform: translateY(8px);
        opacity: 0;
      }

      to {
        transform: translateY(0);
        opacity: 1;
      }
    }

    ::-webkit-scrollbar {
      width: 10px;
      height: 10px;
    }

    ::-webkit-scrollbar-track {
      background: rgba(255, 255, 255, 0.025);
      border-radius: 999px;
    }

    ::-webkit-scrollbar-thumb {
      background: linear-gradient(180deg, #22d3ee, #7c3aed);
      border-radius: 999px;
    }

    /* === STT HOME DASHBOARD PREMIUM FIX === */

    #page-home .dashboard-home-grid {
      align-items: stretch;
    }

    #page-home .dashboard-home-grid > .card {
      height: 100%;
    }

    #page-home .dashboard-home-grid > .card:nth-child(2) {
      display: flex;
      flex-direction: column;
    }

    #page-home .dashboard-home-grid > .card:nth-child(2) .profile-box {
      flex: 0 0 auto;
    }

    #page-home .dashboard-home-grid > .card:nth-child(2) .security-box {
      margin-top: auto !important;
    }

    #page-home .dashboard-action-grid {
      height: 100%;
    }

    #page-home .dashboard-action-card {
      position: relative;
      overflow: hidden;
      width: 100%;
      color: var(--text-main);
      text-align: left;
      background:
        radial-gradient(circle at 16% 0%, rgba(34, 211, 238, 0.22), transparent 38%),
        radial-gradient(circle at 92% 16%, rgba(124, 58, 237, 0.22), transparent 34%),
        linear-gradient(135deg, rgba(10, 25, 55, 0.92), rgba(7, 13, 32, 0.94));
      border: 1px solid rgba(34, 211, 238, 0.16);
      box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.06),
        0 18px 38px rgba(0, 0, 0, 0.22);
    }

    #page-home .dashboard-action-card::before {
      content: "";
      position: absolute;
      inset: 0 0 auto 0;
      height: 1px;
      background: linear-gradient(
        90deg,
        transparent,
        rgba(34, 211, 238, 0.55),
        rgba(124, 58, 237, 0.45),
        transparent
      );
      opacity: 0.9;
    }

    #page-home .dashboard-action-card::after {
      content: "";
      position: absolute;
      right: -45px;
      bottom: -55px;
      width: 130px;
      height: 130px;
      background: radial-gradient(circle, rgba(34, 211, 238, 0.13), transparent 62%);
      pointer-events: none;
    }

    #page-home .dashboard-action-card > * {
      position: relative;
      z-index: 1;
    }

    #page-home .action-title {
      color: #f8fafc;
      font-weight: 850;
    }

    #page-home .action-desc {
      color: #b7c8ec;
    }

    #page-home .action-link {
      color: #67e8f9;
    }

    #page-home .action-icon {
      color: #67e8f9;
      background:
        radial-gradient(circle at 30% 10%, rgba(34, 211, 238, 0.35), transparent 55%),
        rgba(34, 211, 238, 0.12);
      border: 1px solid rgba(34, 211, 238, 0.22);
      box-shadow: 0 0 22px rgba(34, 211, 238, 0.10);
    }

    #page-home .card {
      border-color: rgba(34, 211, 238, 0.16);
      background:
        radial-gradient(circle at 12% 0%, rgba(34, 211, 238, 0.10), transparent 36%),
        linear-gradient(135deg, rgba(13, 27, 57, 0.88), rgba(8, 13, 35, 0.92));
    }

    @media (max-width: 1380px) {
      #page-home .dashboard-home-grid > .card {
        height: auto;
      }

      #page-home .dashboard-home-grid > .card:nth-child(2) .security-box {
        margin-top: 13px !important;
      }
    }

    /* === STT HOME CARD CROP FIX === */

    #page-home .dashboard-home-grid > .card:first-child {
      overflow: visible;
      padding-bottom: 32px;
    }

    #page-home .dashboard-action-grid {
      height: auto !important;
      overflow: visible;
      padding-bottom: 6px;
    }

    #page-home .dashboard-action-card {
      min-height: 140px;
      padding-bottom: 20px;
    }

    #page-home .dashboard-action-card .action-link {
      margin-top: 16px;
      padding-bottom: 4px;
    }

    /* === SIGNAL CENTER COMPACT PREMIUM UI === */

    .signal-list-compact {
      display: flex;
      flex-direction: column;
      gap: 14px;
    }

    .signal-item {
      position: relative;
      padding: 16px 18px;
      border-radius: 20px;
      border: 1px solid rgba(63, 111, 255, 0.16);
      background:
        radial-gradient(circle at 10% 0%, rgba(34, 211, 238, 0.08), transparent 34%),
        linear-gradient(135deg, rgba(8, 18, 45, 0.92), rgba(6, 12, 32, 0.96));
      box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.03),
        0 12px 30px rgba(0,0,0,0.20);
      overflow: hidden;
    }

    .signal-item::before {
      content: "";
      position: absolute;
      inset: 0 0 auto 0;
      height: 1px;
      background: linear-gradient(
        90deg,
        transparent,
        rgba(34, 211, 238, 0.35),
        rgba(124, 58, 237, 0.35),
        transparent
      );
    }

    .signal-topbar {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 14px;
      margin-bottom: 12px;
    }

    .signal-left {
      display: flex;
      align-items: center;
      gap: 12px;
      min-width: 0;
    }

    .signal-logo-wrap {
      width: 42px;
      height: 42px;
      border-radius: 50%;
      flex: 0 0 42px;
      display: grid;
      place-items: center;
      background: rgba(255,255,255,0.04);
      border: 1px solid rgba(255,255,255,0.08);
      overflow: hidden;
    }

    .signal-logo {
      width: 28px;
      height: 28px;
      object-fit: contain;
      display: block;
    }

    .signal-logo-fallback {
      width: 28px;
      height: 28px;
      border-radius: 50%;
      display: none;
      place-items: center;
      font-size: 11px;
      font-weight: 800;
      color: #fff;
      background: linear-gradient(135deg, #f59e0b, #f97316);
    }

    .signal-maintext {
      min-width: 0;
    }

    .signal-pair {
      font-size: 17px;
      font-weight: 800;
      color: #f8fbff;
      line-height: 1.15;
    }

    .signal-sub {
      margin-top: 3px;
      font-size: 12px;
      color: #94a7c6;
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
    }

    .signal-side {
      padding: 8px 14px;
      border-radius: 999px;
      font-size: 12px;
      font-weight: 800;
      letter-spacing: 0.3px;
      text-transform: uppercase;
      border: 1px solid rgba(255,255,255,0.06);
      white-space: nowrap;
    }

    .signal-side.buy,
    .signal-side.long {
      background: rgba(16, 185, 129, 0.15);
      color: #4ade80;
    }

    .signal-side.sell,
    .signal-side.short {
      background: rgba(239, 68, 68, 0.14);
      color: #fb7185;
    }

    .signal-side.no_trade {
      background: rgba(59, 130, 246, 0.13);
      color: #7dd3fc;
    }

    .signal-stats-row {
      display: grid;
      grid-template-columns: repeat(3, minmax(0, 1fr));
      gap: 10px;
      margin-bottom: 10px;
    }

    .signal-stat {
      border-radius: 14px;
      padding: 10px 12px;
      background: rgba(255,255,255,0.02);
      border: 1px solid rgba(255,255,255,0.05);
    }

    .signal-stat-label {
      font-size: 11px;
      color: #8ea4c9;
      margin-bottom: 4px;
      line-height: 1;
    }

    .signal-stat-value {
      font-size: 14px;
      font-weight: 800;
      color: #eef6ff;
      line-height: 1.2;
      word-break: break-word;
    }

    .signal-reason {
      border-radius: 14px;
      padding: 10px 12px;
      background: rgba(255,255,255,0.02);
      border: 1px solid rgba(255,255,255,0.04);
      color: #aebddb;
      font-size: 13px;
      line-height: 1.45;
    }

    .signal-empty {
      padding: 18px;
      border-radius: 18px;
      border: 1px dashed rgba(148, 163, 184, 0.22);
      color: #9fb0cc;
      text-align: center;
    }

    #strategyStatusBox {
      max-height: 780px;
      overflow-y: auto;
      padding-right: 4px;
    }

    #strategyStatusBox::-webkit-scrollbar {
      width: 8px;
    }

    #strategyStatusBox::-webkit-scrollbar-thumb {
      background: linear-gradient(180deg, #22d3ee, #7c3aed);
      border-radius: 20px;
    }

    @media (max-width: 900px) {
      .signal-topbar {
        align-items: flex-start;
        flex-direction: column;
      }

      .signal-stats-row {
        grid-template-columns: 1fr;
      }

      .signal-side {
        align-self: flex-start;
      }

      .signal-pair {
        font-size: 15px;
      }

      .signal-sub {
        white-space: normal;
      }

      #strategyStatusBox {
        max-height: none;
        overflow: visible;
        padding-right: 0;
      }
    }

    /* === STT SIGNAL CENTER ULTRA COMPACT FIX === */

    #page-signals .card {
      padding: 14px 14px 12px;
    }

    #strategyStatusBox {
      max-height: 650px;
      overflow-y: auto;
      padding-right: 6px;
    }

    #strategyStatusBox .signal-list-compact {
      gap: 8px;
    }

    #strategyStatusBox .signal-item {
      padding: 10px 12px !important;
      border-radius: 16px !important;
      background:
        radial-gradient(circle at 8% 0%, rgba(34, 211, 238, 0.08), transparent 34%),
        linear-gradient(135deg, rgba(8, 18, 45, 0.86), rgba(5, 10, 26, 0.94)) !important;
    }

    #strategyStatusBox .signal-topbar {
      margin-bottom: 8px !important;
      gap: 10px !important;
    }

    #strategyStatusBox .signal-left {
      gap: 10px !important;
    }

    #strategyStatusBox .signal-logo-wrap {
      width: 34px !important;
      height: 34px !important;
      flex-basis: 34px !important;
    }

    #strategyStatusBox .signal-logo {
      width: 24px !important;
      height: 24px !important;
    }

    #strategyStatusBox .signal-logo-fallback {
      width: 24px !important;
      height: 24px !important;
      font-size: 10px !important;
    }

    #strategyStatusBox .signal-pair {
      font-size: 15px !important;
      line-height: 1.1 !important;
    }

    #strategyStatusBox .signal-sub {
      margin-top: 2px !important;
      font-size: 11px !important;
    }

    #strategyStatusBox .signal-side {
      padding: 6px 10px !important;
      font-size: 11px !important;
    }

    #strategyStatusBox .signal-stats-row {
      grid-template-columns: 0.8fr 1fr 0.7fr !important;
      gap: 8px !important;
      margin-bottom: 7px !important;
    }

    #strategyStatusBox .signal-stat {
      padding: 7px 9px !important;
      border-radius: 12px !important;
    }

    #strategyStatusBox .signal-stat-label {
      font-size: 10px !important;
      margin-bottom: 3px !important;
    }

    #strategyStatusBox .signal-stat-value {
      font-size: 12.5px !important;
      line-height: 1.15 !important;
    }

    #strategyStatusBox .signal-reason {
      padding: 7px 9px !important;
      border-radius: 12px !important;
      font-size: 11.5px !important;
      line-height: 1.25 !important;
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
    }

    @media (max-width: 900px) {
      #strategyStatusBox {
        max-height: none;
        overflow: visible;
      }

      #strategyStatusBox .signal-topbar {
        flex-direction: row !important;
        align-items: center !important;
      }

      #strategyStatusBox .signal-stats-row {
        grid-template-columns: 1fr 1fr 0.8fr !important;
      }

      #strategyStatusBox .signal-reason {
        white-space: normal;
      }
    }

    /* === STT TRADE JOURNAL COMPACT PREMIUM FIX === */

    #page-trades .card {
      padding: 14px;
    }

    .trade-journal-wrap {
      max-height: 610px;
      overflow-y: auto;
      padding-right: 6px;
    }

    .trade-journal-wrap::-webkit-scrollbar {
      width: 8px;
    }

    .trade-journal-wrap::-webkit-scrollbar-thumb {
      background: linear-gradient(180deg, #22d3ee, #7c3aed);
      border-radius: 20px;
    }

    .trade-summary {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 14px;
      flex-wrap: wrap;
      margin-bottom: 10px;
      padding: 10px 12px;
      border-radius: 14px;
      background: rgba(2, 8, 23, 0.45);
      border: 1px solid rgba(148, 163, 184, 0.10);
      color: #67e8f9;
      font-size: 12px;
    }

    .trade-table {
      gap: 6px !important;
    }

    .trade-table-head,
    .trade-table-row {
      grid-template-columns: 1.15fr 0.62fr 0.62fr 0.72fr 0.9fr !important;
      gap: 8px !important;
    }

    .trade-table-head {
      position: sticky;
      top: 0;
      z-index: 3;
      padding: 8px 10px !important;
      border-radius: 12px;
      background: rgba(3, 7, 18, 0.92);
      backdrop-filter: blur(14px);
      -webkit-backdrop-filter: blur(14px);
    }

    .trade-table-row {
      min-height: 48px;
      padding: 8px 10px !important;
      border-radius: 13px !important;
      background:
        radial-gradient(circle at 8% 0%, rgba(34, 211, 238, 0.055), transparent 30%),
        rgba(5, 10, 25, 0.46) !important;
    }

    .trade-table-row:hover {
      border-color: rgba(34, 211, 238, 0.22);
      background:
        radial-gradient(circle at 8% 0%, rgba(34, 211, 238, 0.10), transparent 35%),
        rgba(8, 18, 45, 0.68) !important;
    }

    .trade-coin-row {
      display: flex;
      align-items: center;
      gap: 10px;
      min-width: 0;
    }

    .trade-logo-wrap {
      width: 32px;
      height: 32px;
      flex: 0 0 32px;
      border-radius: 999px;
      display: grid;
      place-items: center;
      background: rgba(255, 255, 255, 0.045);
      border: 1px solid rgba(255, 255, 255, 0.08);
      overflow: hidden;
    }

    .trade-logo {
      width: 23px;
      height: 23px;
      object-fit: contain;
      display: block;
    }

    .trade-logo-fallback {
      width: 24px;
      height: 24px;
      display: none;
      place-items: center;
      border-radius: 999px;
      font-size: 10px;
      font-weight: 900;
      color: #fff;
      background: linear-gradient(135deg, #f59e0b, #7c3aed);
    }

    .trade-symbol-wrap {
      min-width: 0;
    }

    .trade-symbol {
      font-size: 13px;
      font-weight: 850;
      color: #f8fafc;
      line-height: 1.1;
    }

    .trade-algo {
      margin-top: 2px;
      font-size: 10.5px;
      color: #7f91b3;
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
    }

    .trade-time {
      font-size: 12px;
      color: #dbeafe;
    }

    .trade-pnl {
      font-weight: 850;
      font-size: 12.5px;
    }

    .trade-mode {
      font-size: 12px;
      font-weight: 750;
      color: #e5e7eb;
    }

    .trade-table-row .side-pill {
      padding: 5px 9px !important;
      font-size: 10.5px !important;
    }

    @media (max-width: 780px) {
      .trade-journal-wrap {
        max-height: none;
        overflow: visible;
        padding-right: 0;
      }

      .trade-table-head {
        display: none !important;
      }

      .trade-table-row {
        grid-template-columns: 1fr 0.55fr !important;
        row-gap: 8px !important;
      }

      .trade-table-row > div:nth-child(3),
      .trade-table-row > div:nth-child(4),
      .trade-table-row > div:nth-child(5) {
        font-size: 12px;
      }
    }

    /* === STT BOT CENTER PREMIUM COMPACT FIX === */

    #page-bots .card {
      padding: 14px;
    }

    #page-bots #botList {
      max-height: 650px;
      overflow-y: auto;
      padding-right: 6px;
    }

    #page-bots #botList::-webkit-scrollbar {
      width: 8px;
    }

    #page-bots #botList::-webkit-scrollbar-thumb {
      background: linear-gradient(180deg, #22d3ee, #7c3aed);
      border-radius: 20px;
    }

    #page-bots .bot-grid {
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 14px;
      max-height: none;
      overflow: visible;
      padding-right: 0;
    }

    #page-bots .bot-card {
      position: relative;
      border-radius: 20px;
      padding: 16px;
      overflow: hidden;
      background:
        radial-gradient(circle at 10% 0%, rgba(34, 211, 238, 0.10), transparent 34%),
        radial-gradient(circle at 95% 12%, rgba(124, 58, 237, 0.12), transparent 34%),
        linear-gradient(135deg, rgba(8, 18, 45, 0.92), rgba(5, 10, 28, 0.96));
      border: 1px solid rgba(34, 211, 238, 0.14);
      box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.045),
        0 16px 34px rgba(0,0,0,0.22);
    }

    #page-bots .bot-card::before {
      content: "";
      position: absolute;
      inset: 0 0 auto 0;
      height: 1px;
      background: linear-gradient(
        90deg,
        transparent,
        rgba(34, 211, 238, 0.45),
        rgba(124, 58, 237, 0.35),
        transparent
      );
    }

    #page-bots .bot-top {
      align-items: center;
      margin-bottom: 12px;
    }

    #page-bots .bot-name {
      gap: 12px;
      min-width: 0;
    }

    .bot-logo-wrap {
      width: 44px;
      height: 44px;
      flex: 0 0 44px;
      border-radius: 15px;
      display: grid;
      place-items: center;
      background: rgba(255,255,255,0.045);
      border: 1px solid rgba(255,255,255,0.08);
      overflow: hidden;
    }

    .bot-coin-logo {
      width: 28px;
      height: 28px;
      object-fit: contain;
      display: block;
    }

    .bot-logo-fallback {
      width: 30px;
      height: 30px;
      border-radius: 12px;
      display: none;
      place-items: center;
      font-size: 11px;
      font-weight: 900;
      color: #fff;
      background: linear-gradient(135deg, #22d3ee, #7c3aed);
    }

    .bot-title-wrap {
      min-width: 0;
    }

    .bot-title {
      font-size: 16px;
      font-weight: 850;
      color: #f8fafc;
      line-height: 1.15;
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
    }

    .bot-desc {
      margin-top: 4px;
      font-size: 12px;
      line-height: 1.35;
      color: #98abc9;
      display: -webkit-box;
      -webkit-line-clamp: 2;
      -webkit-box-orient: vertical;
      overflow: hidden;
    }

    .bot-symbol-pill {
      margin-top: 7px;
      display: inline-flex;
      align-items: center;
      gap: 6px;
      width: fit-content;
      padding: 5px 9px;
      border-radius: 999px;
      color: #7dd3fc;
      background: rgba(34, 211, 238, 0.09);
      border: 1px solid rgba(34, 211, 238, 0.14);
      font-size: 11px;
      font-weight: 800;
    }

    #page-bots .status-pill {
      padding: 6px 10px;
      font-size: 11px;
    }

    #page-bots .bot-meta {
      grid-template-columns: repeat(3, minmax(0, 1fr));
      gap: 8px;
      margin-top: 10px;
    }

    #page-bots .meta-box {
      padding: 9px 10px;
      border-radius: 13px;
      background: rgba(2, 8, 23, 0.42);
    }

    #page-bots .meta-label {
      font-size: 10px;
      margin-bottom: 4px;
    }

    #page-bots .meta-value {
      font-size: 12.5px;
      line-height: 1.2;
    }

    #page-bots .bot-actions {
      grid-template-columns: 1fr 1fr 40px;
      gap: 9px;
      margin-top: 12px;
    }

    #page-bots .small-btn {
      min-height: 38px;
      border-radius: 12px;
      font-size: 12px;
      box-shadow: none;
    }

    #page-bots .small-btn:not(.red):not(.dark) {
      background: linear-gradient(90deg, #1db8e8, #5b5ff5);
    }

    #page-bots .small-btn.red {
      background: linear-gradient(90deg, #ef4444, #f97316);
    }

    #page-bots .small-btn.dark {
      background: rgba(255,255,255,0.045);
    }

    @media (max-width: 1180px) {
      #page-bots .bot-grid {
        grid-template-columns: 1fr;
      }
    }

    @media (max-width: 620px) {
      #page-bots #botList {
        max-height: none;
        overflow: visible;
        padding-right: 0;
      }

      #page-bots .bot-card {
        padding: 14px;
      }

      #page-bots .bot-meta {
        grid-template-columns: 1fr;
      }

      #page-bots .bot-actions {
        grid-template-columns: 1fr;
      }

      #page-bots .small-btn.dark {
        min-height: 36px;
      }
    }

    /* === STT BOT CONFIG STATUS BADGE === */

    #page-bots .bot-title-row {
      display: flex;
      align-items: flex-start;
      justify-content: space-between;
      gap: 8px;
      width: 100%;
      min-width: 0;
    }

    #page-bots .bot-title-row .bot-title {
      flex: 1;
      min-width: 0;
    }

    .bot-config-badge {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      white-space: nowrap;
      padding: 5px 8px;
      border-radius: 999px;
      font-size: 10px;
      font-weight: 850;
      letter-spacing: 0.15px;
      line-height: 1;
      border: 1px solid rgba(255, 255, 255, 0.12);
      background: rgba(2, 8, 23, 0.50);
      backdrop-filter: blur(12px);
      -webkit-backdrop-filter: blur(12px);
    }

    .bot-config-badge.cfg-checking {
      color: #dbeafe;
      background: rgba(148, 163, 184, 0.12);
      border-color: rgba(148, 163, 184, 0.22);
    }

    .bot-config-badge.cfg-saved {
      color: #86efac;
      background: rgba(34, 197, 94, 0.13);
      border-color: rgba(34, 197, 94, 0.38);
      box-shadow:
        0 0 14px rgba(34, 197, 94, 0.16),
        inset 0 0 10px rgba(34, 197, 94, 0.08);
    }

    .bot-config-badge.cfg-missing {
      color: #fde68a;
      background: rgba(245, 158, 11, 0.13);
      border-color: rgba(245, 158, 11, 0.38);
      box-shadow:
        0 0 14px rgba(245, 158, 11, 0.13),
        inset 0 0 10px rgba(245, 158, 11, 0.07);
    }

    .bot-config-badge.cfg-locked {
      color: #c4b5fd;
      background: rgba(124, 58, 237, 0.14);
      border-color: rgba(124, 58, 237, 0.34);
    }

    @media (max-width: 640px) {
      #page-bots .bot-title-row {
        gap: 6px;
      }

      .bot-config-badge {
        font-size: 9px;
        padding: 5px 7px;
      }
    }

    /* === STT DELETE CONFIG BUTTON PREMIUM === */

    .bot-config-actions {
      display: grid;
      grid-template-columns: 1fr 1fr 0.92fr;
      gap: 12px;
      align-items: center;
    }

    .cfg-delete-btn {
      min-height: 44px !important;
      color: #ffffff !important;
      border: 1px solid rgba(248, 113, 113, 0.55) !important;
      background:
        radial-gradient(circle at 18% 0%, rgba(255, 255, 255, 0.16), transparent 32%),
        linear-gradient(135deg, #dc2626 0%, #ef4444 42%, #f97316 100%) !important;
      box-shadow:
        0 12px 30px rgba(239, 68, 68, 0.22),
        0 0 18px rgba(249, 115, 22, 0.14),
        inset 0 1px 0 rgba(255, 255, 255, 0.18) !important;
    }

    .cfg-delete-btn:hover {
      transform: translateY(-1px);
      filter: brightness(1.08);
      border-color: rgba(254, 202, 202, 0.75) !important;
      box-shadow:
        0 16px 38px rgba(239, 68, 68, 0.34),
        0 0 26px rgba(249, 115, 22, 0.24),
        inset 0 1px 0 rgba(255, 255, 255, 0.22) !important;
    }

    @media (max-width: 720px) {
      .bot-config-actions {
        grid-template-columns: 1fr;
      }
    }

    .safety-check-list {
      display: grid;
      gap: 10px;
      margin-top: 14px;
    }

    .safety-check-row {
      display: flex;
      justify-content: space-between;
      align-items: flex-start;
      gap: 14px;
      padding: 12px 14px;
      border-radius: 14px;
      background: rgba(255, 255, 255, 0.045);
      border: 1px solid rgba(255, 255, 255, 0.08);
    }

    .safety-check-title {
      font-weight: 800;
      color: #eaf2ff;
      margin-bottom: 3px;
    }

    /* === STT SETTINGS PAGE EQUAL HEIGHT FIX === */

    #page-settings .compact-page-grid {
      align-items: stretch;
    }

    #page-settings .compact-page-grid > .card {
      height: 100%;
      display: flex;
      flex-direction: column;
    }

    #page-settings .profile-box,
    #page-settings .security-box {
      flex: 1;
    }

    #page-settings .danger-btn {
      margin-top: 14px !important;
    }

    #page-settings .security-box {
      min-height: 190px;
      background:
        radial-gradient(circle at 12% 0%, rgba(34, 211, 238, 0.13), transparent 38%),
        linear-gradient(135deg, rgba(5, 85, 76, 0.30), rgba(8, 47, 73, 0.24));
    }

    #page-settings .profile-box {
      min-height: 190px;
      background:
        radial-gradient(circle at 12% 0%, rgba(124, 58, 237, 0.12), transparent 38%),
        rgba(5, 10, 25, 0.42);
    }

    @media (max-width: 1380px) {
      #page-settings .compact-page-grid > .card {
        height: auto;
      }

      #page-settings .profile-box,
      #page-settings .security-box {
        flex: unset;
      }
    }

    /* === STT BOT PLAN ACCESS BADGES === */

    .bot-badge-stack {
      display: inline-flex;
      align-items: center;
      justify-content: flex-end;
      flex-wrap: wrap;
      gap: 6px;
    }

    .bot-plan-badge {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      white-space: nowrap;
      padding: 5px 8px;
      border-radius: 999px;
      font-size: 10px;
      font-weight: 850;
      letter-spacing: 0.15px;
      line-height: 1;
      border: 1px solid rgba(255, 255, 255, 0.12);
      background: rgba(2, 8, 23, 0.50);
      backdrop-filter: blur(12px);
      -webkit-backdrop-filter: blur(12px);
    }

    .bot-plan-badge.access-pro {
      color: #7dd3fc;
      background: rgba(14, 165, 233, 0.14);
      border-color: rgba(14, 165, 233, 0.36);
      box-shadow:
        0 0 14px rgba(14, 165, 233, 0.14),
        inset 0 0 10px rgba(14, 165, 233, 0.06);
    }

    .bot-plan-badge.access-premium {
      color: #d8b4fe;
      background: rgba(168, 85, 247, 0.14);
      border-color: rgba(168, 85, 247, 0.40);
      box-shadow:
        0 0 14px rgba(168, 85, 247, 0.18),
        inset 0 0 10px rgba(168, 85, 247, 0.07);
    }

    .bot-plan-badge.access-required {
      color: #fcd34d;
      background: rgba(245, 158, 11, 0.14);
      border-color: rgba(245, 158, 11, 0.42);
      box-shadow:
        0 0 14px rgba(245, 158, 11, 0.16),
        inset 0 0 10px rgba(245, 158, 11, 0.06);
    }

    .bot-plan-badge.access-locked {
      color: #c4b5fd;
      background: rgba(124, 58, 237, 0.14);
      border-color: rgba(124, 58, 237, 0.34);
    }

    .plan-locked-btn {
      background:
        radial-gradient(circle at 18% 0%, rgba(255, 255, 255, 0.14), transparent 32%),
        linear-gradient(135deg, #7c3aed 0%, #a855f7 50%, #f97316 100%) !important;
      border: 1px solid rgba(216, 180, 254, 0.38) !important;
      box-shadow:
        0 12px 30px rgba(168, 85, 247, 0.22),
        0 0 18px rgba(249, 115, 22, 0.12) !important;
    }

    .plan-locked-btn:hover {
      filter: brightness(1.08);
      box-shadow:
        0 16px 38px rgba(168, 85, 247, 0.34),
        0 0 26px rgba(249, 115, 22, 0.22) !important;
    }

    @media (max-width: 640px) {
      .bot-badge-stack {
        gap: 5px;
      }

      .bot-plan-badge {
        font-size: 9px;
        padding: 5px 7px;
      }
    }

    /* === STT PLAN MANAGEMENT PANEL === */

    .plan-admin-grid {
      display: grid;
      grid-template-columns: 1.4fr 0.8fr 0.8fr 0.8fr 0.7fr;
      gap: 12px;
      align-items: end;
    }

    .stt-select {
      width: 100%;
      min-height: 44px;
      border: 1px solid rgba(148, 163, 184, 0.18);
      outline: none;
      background: rgba(4, 10, 24, 0.78);
      color: var(--text-main);
      padding: 0 14px;
      border-radius: 14px;
      font-size: 14px;
      font-weight: 650;
    }

    .stt-select:focus {
      border-color: rgba(34, 211, 238, 0.52);
      box-shadow: 0 0 0 4px rgba(34, 211, 238, 0.08);
    }

    @media (max-width: 900px) {
      .plan-admin-grid {
        grid-template-columns: 1fr;
      }
    }

    .admin-runtime-table {
      width: 100%;
      border-collapse: collapse;
      min-width: 980px;
      font-size: 13px;
    }

    .admin-runtime-table th,
    .admin-runtime-table td {
      padding: 10px 12px;
      border-bottom: 1px solid rgba(255, 255, 255, 0.08);
      text-align: left;
      white-space: nowrap;
    }

    .admin-runtime-table th {
      color: #8ee8ff;
      font-weight: 800;
      background: rgba(255, 255, 255, 0.04);
    }

    .admin-runtime-table td {
      color: #dbe7ff;
    }

    .small-btn.danger-btn {
      border-color: rgba(255, 77, 109, 0.45);
      color: #ff9aac;
    }

    #adminRuntimePanel .primary-btn {
      min-width: 150px;
      padding-left: 22px;
      padding-right: 22px;
      justify-content: center;
      white-space: nowrap;
    }

    #adminRuntimePanel .card-header {
      align-items: center;
      gap: 16px;
    }
    
    #cfgMode option[disabled] {
      color: #ffcc66;
      background: #1b2038;
      font-weight: 800;
    }

    #cfgMode option {
      color: #ffffff;
      background: #0b1022;
    }

    #cfgMode {
      border-color: rgba(142, 232, 255, 0.45);
    } 

    /* === STT STEP 13: EXPIRY UI POLISH === */

    .plan-warning-banner {
      margin-bottom: 14px;
      border-radius: 18px;
      padding: 15px 16px;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 14px;
      border: 1px solid rgba(245, 158, 11, 0.34);
      background:
        radial-gradient(circle at 8% 0%, rgba(245, 158, 11, 0.18), transparent 36%),
        linear-gradient(135deg, rgba(69, 26, 3, 0.58), rgba(30, 41, 59, 0.72));
      box-shadow:
        0 18px 42px rgba(0, 0, 0, 0.24),
        inset 0 1px 0 rgba(255, 255, 255, 0.06);
    }

    .plan-warning-banner b {
      display: block;
      color: #fde68a;
      font-size: 15px;
      margin-bottom: 3px;
    }

    .plan-warning-banner span {
      color: #fed7aa;
      font-size: 13px;
      line-height: 1.45;
    }

    .plan-warning-banner button {
      min-height: 38px;
      border-radius: 999px;
      padding: 0 14px;
      color: #fff;
      font-weight: 800;
      background: linear-gradient(90deg, #f97316, #ef4444);
      box-shadow: 0 12px 28px rgba(249, 115, 22, 0.20);
    }

    .plan-warning-banner.blocked {
      border-color: rgba(248, 113, 113, 0.36);
      background:
        radial-gradient(circle at 8% 0%, rgba(239, 68, 68, 0.20), transparent 36%),
        linear-gradient(135deg, rgba(69, 10, 10, 0.62), rgba(30, 41, 59, 0.72));
    }

    .plan-access-locked-card {
      opacity: 0.88;
      border-color: rgba(245, 158, 11, 0.28) !important;
      background:
        radial-gradient(circle at 12% 0%, rgba(245, 158, 11, 0.12), transparent 34%),
        rgba(5, 10, 25, 0.46) !important;
    }

    @media (max-width: 720px) {
      .plan-warning-banner {
        align-items: flex-start;
        flex-direction: column;
      }

      .plan-warning-banner button {
        width: 100%;
      }
    }
    
    /* === STT DASHBOARD HOME FINAL PREMIUM COLOR FIX === */

    #page-home .dashboard-home-grid > .card:first-child {
      border-color: rgba(34, 211, 238, 0.24);
      background:
        radial-gradient(circle at 12% 0%, rgba(34, 211, 238, 0.18), transparent 34%),
        radial-gradient(circle at 88% 16%, rgba(124, 58, 237, 0.20), transparent 34%),
        linear-gradient(135deg, rgba(12, 28, 62, 0.96), rgba(8, 13, 36, 0.96));
      box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.07),
        0 22px 52px rgba(0, 0, 0, 0.28),
        0 0 34px rgba(34, 211, 238, 0.06);
    }

    #page-home .dashboard-action-grid {
      gap: 14px;
    }

    #page-home .dashboard-action-card {
      min-height: 145px;
      padding: 18px;
      border-radius: 22px;
      border: 1px solid rgba(34, 211, 238, 0.24);
      background:
        linear-gradient(145deg, rgba(15, 35, 78, 0.92), rgba(10, 17, 44, 0.94)),
        radial-gradient(circle at 12% 10%, rgba(34, 211, 238, 0.24), transparent 38%),
        radial-gradient(circle at 90% 18%, rgba(168, 85, 247, 0.28), transparent 36%);
      box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        0 18px 38px rgba(0, 0, 0, 0.28),
        0 0 26px rgba(34, 211, 238, 0.08);
    }

    #page-home .dashboard-action-card:nth-child(1) {
      background:
        radial-gradient(circle at 12% 0%, rgba(34, 211, 238, 0.28), transparent 38%),
        radial-gradient(circle at 90% 18%, rgba(59, 130, 246, 0.22), transparent 36%),
        linear-gradient(145deg, rgba(11, 41, 77, 0.96), rgba(7, 14, 38, 0.96));
    }

    #page-home .dashboard-action-card:nth-child(2) {
      background:
        radial-gradient(circle at 12% 0%, rgba(124, 58, 237, 0.28), transparent 38%),
        radial-gradient(circle at 90% 18%, rgba(34, 211, 238, 0.18), transparent 36%),
        linear-gradient(145deg, rgba(28, 23, 71, 0.96), rgba(7, 14, 38, 0.96));
    }

    #page-home .dashboard-action-card:nth-child(3) {
      background:
        radial-gradient(circle at 12% 0%, rgba(34, 197, 94, 0.18), transparent 38%),
        radial-gradient(circle at 90% 18%, rgba(34, 211, 238, 0.22), transparent 36%),
        linear-gradient(145deg, rgba(9, 47, 63, 0.96), rgba(7, 14, 38, 0.96));
    }

    #page-home .dashboard-action-card:nth-child(4) {
      background:
        radial-gradient(circle at 12% 0%, rgba(59, 130, 246, 0.24), transparent 38%),
        radial-gradient(circle at 90% 18%, rgba(168, 85, 247, 0.22), transparent 36%),
        linear-gradient(145deg, rgba(12, 30, 70, 0.96), rgba(7, 14, 38, 0.96));
    }

    #page-home .dashboard-action-card:nth-child(5) {
      background:
        radial-gradient(circle at 12% 0%, rgba(249, 115, 22, 0.18), transparent 38%),
        radial-gradient(circle at 90% 18%, rgba(124, 58, 237, 0.22), transparent 36%),
        linear-gradient(145deg, rgba(50, 28, 45, 0.96), rgba(7, 14, 38, 0.96));
    }

    #page-home .dashboard-action-card:nth-child(6) {
      background:
        radial-gradient(circle at 12% 0%, rgba(34, 211, 238, 0.20), transparent 38%),
        radial-gradient(circle at 90% 18%, rgba(34, 197, 94, 0.18), transparent 36%),
        linear-gradient(145deg, rgba(8, 43, 60, 0.96), rgba(7, 14, 38, 0.96));
    }

    #page-home .dashboard-action-card:hover {
      transform: translateY(-3px);
      border-color: rgba(34, 211, 238, 0.42);
      box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.10),
        0 24px 56px rgba(0, 0, 0, 0.36),
        0 0 32px rgba(34, 211, 238, 0.16);
    }

    #page-home .action-title {
      color: #ffffff;
      font-weight: 900;
      letter-spacing: -0.35px;
      text-shadow: 0 2px 16px rgba(0, 0, 0, 0.35);
    }

    #page-home .action-desc {
      color: #c4d4f4;
      font-weight: 500;
    }

    #page-home .action-link {
      color: #5ee7ff;
      font-weight: 900;
      text-shadow: 0 0 16px rgba(34, 211, 238, 0.28);
    }

    #page-home .action-icon {
      color: #ffffff;
      background:
        radial-gradient(circle at 30% 10%, rgba(255, 255, 255, 0.20), transparent 45%),
        linear-gradient(135deg, rgba(34, 211, 238, 0.55), rgba(124, 58, 237, 0.55));
      border: 1px solid rgba(255, 255, 255, 0.14);
      box-shadow:
        0 0 24px rgba(34, 211, 238, 0.22),
        inset 0 1px 0 rgba(255, 255, 255, 0.18);
    }

    /* === STT EXCHANGE HUB PREMIUM FIX === */

    #page-exchange .compact-page-grid {
      align-items: stretch;
      grid-template-columns: 1fr 1fr;
    }

    #page-exchange .compact-page-grid > .card {
      height: 100%;
      display: flex;
      flex-direction: column;
      border-color: rgba(34, 211, 238, 0.20);
      background:
        radial-gradient(circle at 10% 0%, rgba(34, 211, 238, 0.13), transparent 35%),
        radial-gradient(circle at 95% 8%, rgba(124, 58, 237, 0.14), transparent 32%),
        linear-gradient(135deg, rgba(12, 28, 62, 0.92), rgba(7, 12, 32, 0.96));
      box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.06),
        0 22px 52px rgba(0, 0, 0, 0.26),
        0 0 28px rgba(34, 211, 238, 0.055);
    }

    #page-exchange .card-header {
      margin-bottom: 16px;
    }

    #page-exchange .card-title {
      color: #ffffff;
      font-weight: 900;
      letter-spacing: -0.45px;
    }

    #page-exchange .badge {
      color: #a5f3fc;
      background:
        radial-gradient(circle at 30% 0%, rgba(34, 211, 238, 0.28), transparent 55%),
        rgba(14, 116, 144, 0.24);
      border-color: rgba(34, 211, 238, 0.28);
      box-shadow: 0 0 18px rgba(34, 211, 238, 0.08);
    }

    /* Supported exchange cards */
    #page-exchange .exchange-grid {
      grid-template-columns: repeat(4, minmax(0, 1fr));
      gap: 12px;
    }

    #page-exchange .exchange-card {
      min-height: 150px;
      border-radius: 18px;
      padding: 14px 12px;
      background:
        radial-gradient(circle at 15% 0%, rgba(34, 211, 238, 0.12), transparent 36%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.025));
      border: 1px solid rgba(148, 163, 184, 0.15);
      box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.04),
        0 12px 24px rgba(0, 0, 0, 0.16);
    }

    #page-exchange .exchange-card.active {
      border-color: rgba(34, 197, 94, 0.58);
      background:
        radial-gradient(circle at 15% 0%, rgba(34, 197, 94, 0.18), transparent 38%),
        linear-gradient(180deg, rgba(16, 185, 129, 0.09), rgba(255, 255, 255, 0.025));
      box-shadow:
        inset 0 0 0 1px rgba(34, 197, 94, 0.14),
        0 0 26px rgba(34, 197, 94, 0.12),
        0 14px 28px rgba(0, 0, 0, 0.22);
    }

    #page-exchange .exchange-logo-wrap {
      height: 58px;
      border-radius: 16px;
      background:
        radial-gradient(circle at 30% 0%, rgba(255, 255, 255, 0.08), transparent 55%),
        rgba(255, 255, 255, 0.045);
      border: 1px solid rgba(255, 255, 255, 0.08);
    }

    #page-exchange .ex-name {
      color: #f8fafc;
      font-weight: 900;
      letter-spacing: -0.25px;
    }

    #page-exchange .exchange-note {
      color: #9fb0d0;
    }

    /* Add exchange strip */
    #page-exchange .add-exchange {
      margin-top: 14px;
      padding: 13px;
      border-radius: 14px;
      color: #c8d7f4;
      background:
        linear-gradient(90deg, rgba(34, 211, 238, 0.06), rgba(124, 58, 237, 0.08));
      border: 1px dashed rgba(34, 211, 238, 0.25);
    }

    /* Coming soon cards */
    #page-exchange .exchange-coming {
      margin-top: auto;
      padding-top: 14px;
      grid-template-columns: repeat(5, minmax(0, 1fr));
      gap: 12px;
    }

    #page-exchange .coming-card {
      min-height: 122px;
      border-radius: 16px;
      padding: 13px;
      background:
        radial-gradient(circle at 20% 0%, rgba(124, 58, 237, 0.13), transparent 38%),
        rgba(255, 255, 255, 0.045);
      border: 1px solid rgba(148, 163, 184, 0.12);
    }

    #page-exchange .coming-card b {
      color: #f8fafc;
    }

    /* Binance API card */
    #page-exchange .warning-box {
      border-radius: 18px;
      padding: 16px;
      color: #ffef9f;
      background:
        radial-gradient(circle at 10% 0%, rgba(250, 204, 21, 0.12), transparent 38%),
        linear-gradient(135deg, rgba(245, 158, 11, 0.14), rgba(124, 58, 237, 0.08));
      border: 1px solid rgba(250, 204, 21, 0.26);
    }

    #page-exchange .form input {
      min-height: 48px;
      border-radius: 15px;
      background: rgba(2, 8, 23, 0.70);
      border-color: rgba(148, 163, 184, 0.13);
    }

    #page-exchange .form input:focus {
      border-color: rgba(34, 211, 238, 0.48);
      box-shadow: 0 0 0 4px rgba(34, 211, 238, 0.08);
    }

    #page-exchange .primary-btn {
      min-height: 48px;
      border-radius: 15px;
      background: linear-gradient(90deg, #20cde6, #3b82f6, #7c3aed);
      box-shadow:
        0 15px 32px rgba(59, 130, 246, 0.16),
        inset 0 1px 0 rgba(255, 255, 255, 0.12);
    }

    #page-exchange .primary-btn:hover {
      transform: translateY(-1px);
      filter: brightness(1.08);
    }

    /* Binance status box */
    #page-exchange #binanceStatus {
      margin-top: auto !important;
      border-radius: 18px;
      padding: 16px;
      background:
        radial-gradient(circle at 12% 0%, rgba(34, 211, 238, 0.10), transparent 38%),
        rgba(5, 10, 25, 0.48);
      border: 1px solid rgba(148, 163, 184, 0.12);
    }

    #page-exchange #binanceStatus .bot-meta {
      gap: 10px;
    }

    #page-exchange #binanceStatus .meta-box {
      border-radius: 14px;
      background: rgba(2, 8, 23, 0.44);
      border: 1px solid rgba(148, 163, 184, 0.10);
    }

    /* Equal card height desktop only */
    @media (min-width: 1381px) {
      #page-exchange .compact-page-grid > .card {
        min-height: 640px;
      }
    }

    @media (max-width: 1380px) {
      #page-exchange .compact-page-grid {
        grid-template-columns: 1fr;
      }

      #page-exchange .compact-page-grid > .card {
        height: auto;
        min-height: auto;
      }

      #page-exchange .exchange-coming {
        margin-top: 14px;
      }
    }

    @media (max-width: 620px) {
      #page-exchange .exchange-grid,
      #page-exchange .exchange-coming {
        grid-template-columns: 1fr;
      }

      #page-exchange .exchange-card,
      #page-exchange .coming-card {
        min-height: auto;
      }
    }

    /* === STT EXCHANGE HUB FINAL GRID + SPACING FIX === */

    /* Left card ko natural height me rakho, blank space remove */
    #page-exchange .compact-page-grid {
      align-items: start !important;
    }

    #page-exchange .compact-page-grid > .card {
      height: auto !important;
      min-height: auto !important;
    }

    /* Main exchange grid: 4 + 4 */
    #page-exchange .exchange-grid {
      display: grid;
      grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
      gap: 12px !important;
    }

    /* Last single exchange center */
    #page-exchange .exchange-coming {
      display: flex !important;
      justify-content: center;
      align-items: stretch;
      margin-top: 12px !important;
      padding-top: 0 !important;
    }

    #page-exchange .exchange-coming .exchange-card-center {
      width: calc((100% - 36px) / 4);
      min-width: 130px;
    }

    /* Add Exchange button bottom me */
    #page-exchange .add-exchange {
      margin-top: 14px !important;
      padding: 13px !important;
      border-radius: 14px !important;
      color: #c8d7f4 !important;
      background:
        linear-gradient(90deg, rgba(34, 211, 238, 0.06), rgba(124, 58, 237, 0.08)) !important;
      border: 1px dashed rgba(34, 211, 238, 0.25) !important;
    }

    /* Status warning ko meta boxes se clearly separate karo */
    #page-exchange #binanceStatus .bot-meta {
      margin-bottom: 18px !important;
    }

    #page-exchange #binanceStatus .warning-box {
      display: block;
      margin-top: 18px !important;
      margin-bottom: 0 !important;
      padding: 16px 18px !important;
      line-height: 1.6 !important;
      border-radius: 16px !important;
    }

    /* Inline style margin-bottom:0 ko override karne ke liye */
    #page-exchange #binanceStatus .warning-box[style] {
      margin-top: 18px !important;
      margin-bottom: 0 !important;
    }

    /* Right status box ka andar spacing clean */
    #page-exchange #binanceStatus {
      margin-top: 16px !important;
    }

    /* Mobile / tablet responsive */
    @media (max-width: 1380px) {
      #page-exchange .exchange-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
      }

      #page-exchange .exchange-coming .exchange-card-center {
        width: calc((100% - 36px) / 4);
      }
    }

    @media (max-width: 900px) {
      #page-exchange .exchange-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
      }

      #page-exchange .exchange-coming .exchange-card-center {
        width: calc((100% - 12px) / 2);
      }
    }

    @media (max-width: 620px) {
      #page-exchange .exchange-grid {
        grid-template-columns: 1fr !important;
      }

      #page-exchange .exchange-coming .exchange-card-center {
        width: 100%;
      }
    }

    /* === STT EXCHANGE HUB EQUAL HEIGHT FINAL FIX === */

    /* Exchange page ke dono main cards same height */
    #page-exchange .compact-page-grid {
      align-items: stretch !important;
    }

    /* Dono cards full height stretch honge */
    #page-exchange .compact-page-grid > .card {
      height: 100% !important;
      min-height: 0 !important;
    }

    /* Left Supported Exchanges card ko column layout do */
    #page-exchange .compact-page-grid > .card:first-child {
      display: flex !important;
      flex-direction: column !important;
    }

    /* Left card me Add Exchange button ko bottom ke near balance me rakho */
    #page-exchange .compact-page-grid > .card:first-child .add-exchange {
      margin-top: auto !important;
    }

    /* Exchange single center card aur add button ke beech gap clean */
    #page-exchange .exchange-coming {
      margin-bottom: 14px !important;
    }

    /* Right card natural rahe but equal height parent ke sath stretch ho */
    #page-exchange .compact-page-grid > .card:nth-child(2) {
      display: flex !important;
      flex-direction: column !important;
    }

    /* Binance status section right card ke lower part me balanced rahe */
    #page-exchange #binanceStatus {
      margin-top: 16px !important;
    }

    /* Right card ke bottom warning me proper breathing space */
    #page-exchange #binanceStatus .warning-box {
      margin-top: 18px !important;
      margin-bottom: 0 !important;
    }

    /* === STT EXCHANGE ROW SPACING FINAL FIX === */

    /* Left card ke andar exchange rows ko thoda spread karo */
    #page-exchange .compact-page-grid > .card:first-child {
      display: flex !important;
      flex-direction: column !important;
    }

    /* 4 + 4 exchange rows ke beech vertical gap badhao */
    #page-exchange .exchange-grid {
      row-gap: 25px !important;
      column-gap: 10px !important;
    }

    /* Delta Exchange row ko thoda niche breathing space do */
    #page-exchange .exchange-coming {
      margin-top: 20px !important;
      margin-bottom: 24px !important;
    }

    /* Individual exchange cards ko thoda taller and premium karo */
    #page-exchange .exchange-card {
      min-height: 158px !important;
      padding-top: 16px !important;
      padding-bottom: 16px !important;
    }

    /* Logo box aur text ke beech clean spacing */
    #page-exchange .exchange-logo-wrap {
      margin-bottom: 12px !important;
    }

    /* Add Exchange button bottom pe rahe */
    #page-exchange .compact-page-grid > .card:first-child .add-exchange {
      margin-top: auto !important;
    }

    /* Add Exchange ke upar thoda gap rahe */
    #page-exchange .add-exchange {
      margin-top: 18px !important;
    }

    /* === STT BOT CENTER CATEGORY TABS === */

    .bot-center-shell {
    display: grid;
    gap: 16px;
    }

    .bot-tabs {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    padding: 10px;
    border-radius: 18px;
    background:
        radial-gradient(circle at 10% 0%, rgba(34, 211, 238, 0.10), transparent 36%),
        rgba(2, 8, 23, 0.42);
    border: 1px solid rgba(148, 163, 184, 0.12);
    }

    .bot-tab {
    min-height: 38px;
    padding: 0 15px;
    border-radius: 999px;
    color: #a8b5d1;
    background: rgba(255, 255, 255, 0.045);
    border: 1px solid rgba(148, 163, 184, 0.12);
    font-size: 12px;
    font-weight: 850;
    transition: 0.22s ease;
    }

    .bot-tab:hover,
    .bot-tab.active {
    color: #ffffff;
    border-color: rgba(34, 211, 238, 0.38);
    background:
        radial-gradient(circle at 25% 0%, rgba(34, 211, 238, 0.28), transparent 55%),
        linear-gradient(135deg, rgba(34, 211, 238, 0.20), rgba(124, 58, 237, 0.24));
    box-shadow:
        0 0 24px rgba(34, 211, 238, 0.10),
        inset 0 1px 0 rgba(255, 255, 255, 0.08);
    }

    .bot-category-summary {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    }

    .bot-summary-card {
    min-height: 86px;
    border-radius: 18px;
    padding: 14px;
    background:
        radial-gradient(circle at 10% 0%, rgba(34, 211, 238, 0.12), transparent 38%),
        rgba(5, 10, 25, 0.42);
    border: 1px solid rgba(34, 211, 238, 0.13);
    }

    .bot-summary-label {
    color: #93a7cc;
    font-size: 12px;
    font-weight: 700;
    }

    .bot-summary-value {
    margin-top: 7px;
    color: #ffffff;
    font-size: 24px;
    line-height: 1;
    font-weight: 900;
    }

    .bot-summary-note {
    margin-top: 5px;
    color: #67e8f9;
    font-size: 11px;
    font-weight: 750;
    }

    .bot-category-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin: 4px 0 0;
    }

    .bot-category-heading h3 {
    font-size: 18px;
    font-weight: 900;
    letter-spacing: -0.4px;
    }

    .bot-category-heading p {
    margin-top: 4px;
    color: #93a7cc;
    font-size: 13px;
    }

    .bot-empty-state {
    padding: 22px;
    border-radius: 18px;
    text-align: center;
    color: #9fb0d0;
    border: 1px dashed rgba(148, 163, 184, 0.22);
    background: rgba(2, 8, 23, 0.36);
    }

    .bot-disabled-card {
    opacity: 0.78;
    }

    .bot-category-tag {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    padding: 5px 9px;
    border-radius: 999px;
    font-size: 10.5px;
    font-weight: 900;
    letter-spacing: 0.2px;
    color: #a5f3fc;
    background: rgba(34, 211, 238, 0.10);
    border: 1px solid rgba(34, 211, 238, 0.14);
    margin-top: 7px;
    }

    @media (max-width: 900px) {
    .bot-category-summary {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    }

    @media (max-width: 620px) {
    .bot-tabs {
        flex-wrap: nowrap;
        overflow-x: auto;
        padding-bottom: 12px;
    }

    .bot-tab {
        flex: 0 0 auto;
    }

    .bot-category-summary {
        grid-template-columns: 1fr;
      }
    }

    /* === STT BOT CENTER STABLE TABS FINAL FIX === */

    #page-bots {
    overflow-anchor: none;
    }

    #page-bots .card {
    overflow: visible !important;
    }

    #page-bots #botList.bot-center-shell {
    min-height: 720px;
    overflow-anchor: none;
    }

    #page-bots .bot-tabs {
    min-height: 58px;
    align-items: center;
    overflow-anchor: none;
    }

    #page-bots .bot-category-summary {
    min-height: 94px;
    }

    #page-bots .bot-category-heading {
    min-height: 64px;
    align-items: center;
    }

    #page-bots .bot-results-area {
    min-height: 420px;
    display: block;
    overflow-anchor: none;
    }

    #page-bots .bot-results-area .bot-grid {
    min-height: 420px;
    align-content: start;
    }

    #page-bots .bot-results-area .bot-empty-state {
    min-height: 240px;
    display: grid;
    place-items: center;
    }

    @media (max-width: 620px) {
    #page-bots #botList.bot-center-shell,
    #page-bots .bot-tabs,
    #page-bots .bot-category-summary,
    #page-bots .bot-category-heading,
    #page-bots .bot-results-area,
    #page-bots .bot-results-area .bot-grid,
    #page-bots .bot-results-area .bot-empty-state {
        min-height: auto;
      }
    }

    /* === STT BOT CONFIG MODAL === */

    .bot-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 22px;
    background:
        radial-gradient(circle at 20% 10%, rgba(34, 211, 238, 0.16), transparent 34%),
        radial-gradient(circle at 80% 20%, rgba(124, 58, 237, 0.20), transparent 34%),
        rgba(2, 6, 23, 0.78);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    }

    .bot-modal-overlay.show {
    display: flex;
    }

    .bot-modal {
    width: min(980px, 100%);
    max-height: 88vh;
    overflow: hidden;
    border-radius: 26px;
    border: 1px solid rgba(34, 211, 238, 0.22);
    background:
        radial-gradient(circle at 8% 0%, rgba(34, 211, 238, 0.14), transparent 38%),
        radial-gradient(circle at 92% 12%, rgba(124, 58, 237, 0.16), transparent 34%),
        linear-gradient(135deg, rgba(12, 28, 62, 0.96), rgba(5, 10, 28, 0.98));
    box-shadow:
        0 30px 90px rgba(0, 0, 0, 0.55),
        inset 0 1px 0 rgba(255, 255, 255, 0.07);
    }

    .bot-modal-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    padding: 22px 24px;
    border-bottom: 1px solid rgba(148, 163, 184, 0.12);
    }

    .bot-modal-title-row {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
    }

    .bot-modal-title {
    font-size: 24px;
    font-weight: 900;
    letter-spacing: -0.7px;
    color: #ffffff;
    }

    .bot-modal-sub {
    margin-top: 5px;
    color: #9fb0d0;
    font-size: 13px;
    line-height: 1.5;
    }

    .bot-modal-close {
    width: 40px;
    height: 40px;
    border-radius: 14px;
    color: #e5e7eb;
    background: rgba(255, 255, 255, 0.055);
    border: 1px solid rgba(255, 255, 255, 0.09);
    font-size: 20px;
    font-weight: 900;
    }

    .bot-modal-close:hover {
    filter: brightness(1.1);
    transform: translateY(-1px);
    }

    .bot-modal-body {
    max-height: calc(88vh - 92px);
    overflow-y: auto;
    padding: 20px 24px 24px;
    }

    .bot-config-grid {
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    gap: 16px;
    align-items: start;
    }

    .bot-config-card {
    border-radius: 20px;
    padding: 16px;
    border: 1px solid rgba(148, 163, 184, 0.13);
    background: rgba(2, 8, 23, 0.42);
    }

    .bot-config-card h3 {
    font-size: 17px;
    font-weight: 900;
    margin-bottom: 12px;
    letter-spacing: -0.3px;
    }

    .bot-config-info {
    display: grid;
    gap: 10px;
    }

    .bot-config-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 10px 12px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.035);
    border: 1px solid rgba(255, 255, 255, 0.055);
    }

    .bot-config-label {
    color: #91a3c6;
    font-size: 12px;
    font-weight: 750;
    }

    .bot-config-value {
    color: #f8fafc;
    font-size: 13px;
    font-weight: 850;
    text-align: right;
    word-break: break-word;
    }

    .bot-config-form {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    }

    .bot-field {
    display: grid;
    gap: 7px;
    }

    .bot-field label {
    color: #9fb0d0;
    font-size: 12px;
    font-weight: 800;
    }

    .bot-field input,
    .bot-field select {
    width: 100%;
    min-height: 44px;
    border-radius: 14px;
    border: 1px solid rgba(148, 163, 184, 0.14);
    background: rgba(2, 8, 23, 0.66);
    color: #f8fafc;
    padding: 0 13px;
    outline: none;
    }

    .bot-field input:focus,
    .bot-field select:focus {
    border-color: rgba(34, 211, 238, 0.48);
    box-shadow: 0 0 0 4px rgba(34, 211, 238, 0.08);
    }

    .bot-config-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-top: 14px;
    }

    .bot-config-note {
    margin-top: 14px;
    padding: 12px 14px;
    border-radius: 16px;
    color: #fde68a;
    background: rgba(245, 158, 11, 0.11);
    border: 1px solid rgba(245, 158, 11, 0.22);
    font-size: 12px;
    line-height: 1.5;
    }

    @media (max-width: 760px) {
    .bot-modal-overlay {
        align-items: flex-start;
        padding: 12px;
    }

    .bot-modal {
        max-height: 94vh;
        border-radius: 22px;
    }

    .bot-modal-head {
        padding: 18px;
    }

    .bot-modal-body {
        padding: 16px;
        max-height: calc(94vh - 84px);
    }

    .bot-config-grid,
    .bot-config-form,
    .bot-config-actions {
        grid-template-columns: 1fr;
    }

    .bot-modal-title {
        font-size: 20px;
    }
    }

    /* RESPONSIVE */

    @media (max-width: 1380px) {
      .stats-row {
        grid-template-columns: repeat(3, 1fr);
      }

      .dashboard-home-grid,
      .compact-page-grid {
        grid-template-columns: 1fr;
      }

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

      .bot-grid {
        grid-template-columns: 1fr;
      }

      .exchange-coming {
        grid-template-columns: repeat(3, 1fr);
      }
    }

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

      .sidebar {
        position: relative;
        top: 0;
        min-height: auto;
      }

      .sidebar-brand {
        flex-direction: row;
        text-align: left;
      }

      .sidebar-brand .logo-mark {
        width: 64px;
        height: 64px;
        border-radius: 20px;
      }

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

      .topbar {
        height: auto;
        align-items: stretch;
        flex-direction: column;
      }

      .searchbar {
        width: 100%;
      }

      .hero-panel {
        min-height: 190px;
        background-image:
          linear-gradient(180deg, rgba(3, 7, 18, 0.52), rgba(3, 7, 18, 0.20)),
          url("../icons/banner1.png");
        background-repeat: no-repeat, no-repeat;
        background-size: 100% 100%, cover;
        background-position: center, right 40%;
      }

      .auth-card {
        grid-template-columns: 1fr;
      }

      .auth-hero {
        min-height: auto;
      }
    }

    @media (max-width: 620px) {
      .page {
        padding: 12px;
      }

      .nav {
        grid-template-columns: 1fr;
      }

      .stats-row,
      .exchange-grid,
      .exchange-coming,
      .bot-meta,
      .bot-actions,
      .dashboard-action-grid {
        grid-template-columns: 1fr;
      }

      .trade-table-head {
        display: none;
      }

      .trade-table-row {
        grid-template-columns: 1fr 1fr;
      }

      .brand-title {
        font-size: 18px;
      }

      .auth-hero h1 {
        font-size: 42px;
      }

      .hero-panel {
        min-height: 210px;
        border-radius: 20px;
        background-image:
          linear-gradient(90deg, rgba(3, 7, 18, 0.92) 0%, rgba(3, 7, 18, 0.78) 52%, rgba(3, 7, 18, 0.48) 100%),
          url("../icons/banner1.png");
        background-repeat: no-repeat, no-repeat;
        background-size: 100% 100%, cover;
        background-position: center, 72% 42%;
      }

      .hero-content {
        width: 100%;
        padding: 26px 18px;
      }

      .hero-panel h1 {
        max-width: 280px;
        font-size: 28px;
        line-height: 1.08;
        letter-spacing: -0.8px;
      }

      .hero-panel p {
        max-width: 300px;
        margin-top: 10px;
        font-size: 13.5px;
        line-height: 1.45;
      }

      .live-line {
        margin-top: 16px;
        gap: 9px;
        font-size: 12px;
      }

      .page-head {
        flex-direction: column;
      }

      .page-title {
        font-size: 24px;
      }

      .ranking-head,
      .ranking-row {
        grid-template-columns: 30px minmax(95px, 1.2fr) minmax(70px, 0.8fr) minmax(62px, 0.7fr);
        gap: 7px;
        padding-left: 12px;
        padding-right: 12px;
      }

      .rank-price,
      .rank-change {
        font-size: 12px;
      }

      .market-tabs {
        overflow-x: auto;
        flex-wrap: nowrap;
        padding-bottom: 3px;
      }

      .market-tab {
        white-space: nowrap;
      }
    }
/* Step 25 Admin Upgrade Requests polish */
.admin-refresh-wide {
  min-width: 190px;
  padding-left: 26px;
  padding-right: 26px;
  justify-content: center;
  white-space: nowrap;
}

@media (max-width: 768px) {
  .admin-refresh-wide {
    width: 100%;
    min-width: 0;
  }
}

/* Step 26 premium support CTA buttons */
.support-cta-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(180px, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.support-cta {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 70px;
  padding: 13px 14px;
  border-radius: 18px;
  text-decoration: none;
  color: #f8fbff;
  border: 1px solid rgba(125, 211, 252, 0.22);
  background:
    radial-gradient(circle at 10% 0%, rgba(45, 212, 191, 0.18), transparent 38%),
    linear-gradient(135deg, rgba(15, 23, 42, 0.94), rgba(30, 41, 59, 0.72));
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.22);
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.support-cta:hover {
  transform: translateY(-2px);
  border-color: rgba(103, 232, 249, 0.65);
  box-shadow: 0 18px 44px rgba(34, 211, 238, 0.14);
}

.support-ico {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(15, 23, 42, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.support-ico svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

.support-cta b {
  display: block;
  font-size: 14px;
  line-height: 1.15;
  letter-spacing: 0.01em;
}

.support-cta small {
  display: block;
  margin-top: 4px;
  font-size: 11px;
  color: #a8b5d1;
  font-weight: 700;
}

.support-cta.whatsapp {
  color: #86efac;
}

.support-cta.telegram {
  color: #7dd3fc;
}

.support-cta.youtube {
  color: #fca5a5;
}

.support-cta.call {
  color: #fde68a;
}

@media (max-width: 1100px) {
  .support-cta-grid {
    grid-template-columns: repeat(2, minmax(180px, 1fr));
  }
}

@media (max-width: 720px) {
  .support-cta-grid {
    grid-template-columns: 1fr;
  }
}

/* Step 26 real brand support icons */
.support-ico.brand-icon img {
  width: 24px;
  height: 24px;
  display: block;
  object-fit: contain;
}

.support-cta.whatsapp .support-ico {
  background: rgba(37, 211, 102, 0.12);
  border-color: rgba(37, 211, 102, 0.35);
  box-shadow: inset 0 0 18px rgba(37, 211, 102, 0.08);
}

.support-cta.telegram .support-ico {
  background: rgba(38, 165, 228, 0.12);
  border-color: rgba(38, 165, 228, 0.35);
  box-shadow: inset 0 0 18px rgba(38, 165, 228, 0.08);
}

.support-cta.youtube .support-ico {
  background: rgba(255, 0, 0, 0.10);
  border-color: rgba(255, 0, 0, 0.32);
  box-shadow: inset 0 0 18px rgba(255, 0, 0, 0.08);
}

.support-cta.call .support-ico {
  background: rgba(250, 204, 21, 0.12);
  border-color: rgba(250, 204, 21, 0.34);
  box-shadow: inset 0 0 18px rgba(250, 204, 21, 0.08);
}

.support-cta.whatsapp {
  background:
    radial-gradient(circle at 10% 0%, rgba(37, 211, 102, 0.20), transparent 42%),
    linear-gradient(135deg, rgba(15, 23, 42, 0.95), rgba(22, 45, 38, 0.78));
}

.support-cta.telegram {
  background:
    radial-gradient(circle at 10% 0%, rgba(38, 165, 228, 0.22), transparent 42%),
    linear-gradient(135deg, rgba(15, 23, 42, 0.95), rgba(20, 44, 62, 0.78));
}

.support-cta.youtube {
  background:
    radial-gradient(circle at 10% 0%, rgba(255, 0, 0, 0.18), transparent 42%),
    linear-gradient(135deg, rgba(15, 23, 42, 0.95), rgba(55, 25, 33, 0.78));
}

.support-cta.call {
  background:
    radial-gradient(circle at 10% 0%, rgba(250, 204, 21, 0.18), transparent 42%),
    linear-gradient(135deg, rgba(15, 23, 42, 0.95), rgba(56, 48, 26, 0.78));
}

/* Step 26 support CTA premium glow polish */
.support-ico.brand-icon img {
  filter: drop-shadow(0 0 10px currentColor) saturate(1.25) brightness(1.08);
}

.support-cta .support-ico {
  position: relative;
  overflow: hidden;
}

.support-cta .support-ico::after {
  content: "";
  position: absolute;
  inset: -35%;
  background: radial-gradient(circle, rgba(255,255,255,0.22), transparent 55%);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.support-cta:hover .support-ico::after {
  opacity: 1;
}

.support-cta.whatsapp {
  border-color: rgba(37, 211, 102, 0.42);
  box-shadow: 0 16px 42px rgba(37, 211, 102, 0.10), 0 14px 34px rgba(0, 0, 0, 0.22);
}

.support-cta.whatsapp:hover {
  border-color: rgba(37, 211, 102, 0.85);
  box-shadow: 0 20px 54px rgba(37, 211, 102, 0.20), 0 16px 36px rgba(0, 0, 0, 0.25);
}

.support-cta.telegram {
  border-color: rgba(38, 165, 228, 0.42);
  box-shadow: 0 16px 42px rgba(38, 165, 228, 0.10), 0 14px 34px rgba(0, 0, 0, 0.22);
}

.support-cta.telegram:hover {
  border-color: rgba(38, 165, 228, 0.85);
  box-shadow: 0 20px 54px rgba(38, 165, 228, 0.20), 0 16px 36px rgba(0, 0, 0, 0.25);
}

.support-cta.youtube {
  border-color: rgba(255, 0, 0, 0.42);
  box-shadow: 0 16px 42px rgba(255, 0, 0, 0.10), 0 14px 34px rgba(0, 0, 0, 0.22);
}

.support-cta.youtube:hover {
  border-color: rgba(255, 0, 0, 0.85);
  box-shadow: 0 20px 54px rgba(255, 0, 0, 0.20), 0 16px 36px rgba(0, 0, 0, 0.25);
}

.support-cta.call {
  border-color: rgba(250, 204, 21, 0.44);
  box-shadow: 0 16px 42px rgba(250, 204, 21, 0.10), 0 14px 34px rgba(0, 0, 0, 0.22);
}

.support-cta.call:hover {
  border-color: rgba(250, 204, 21, 0.85);
  box-shadow: 0 20px 54px rgba(250, 204, 21, 0.20), 0 16px 36px rgba(0, 0, 0, 0.25);
}

.support-cta b {
  text-shadow: 0 0 18px rgba(255,255,255,0.10);
}

.support-cta.whatsapp b {
  color: #bbf7d0;
}

.support-cta.telegram b {
  color: #bae6fd;
}

.support-cta.youtube b {
  color: #fecaca;
}

.support-cta.call b {
  color: #fef3c7;
}

/* Step 26 support CTA premium glow polish */
.support-ico.brand-icon img {
  filter: drop-shadow(0 0 10px currentColor) saturate(1.25) brightness(1.08);
}

.support-cta .support-ico {
  position: relative;
  overflow: hidden;
}

.support-cta .support-ico::after {
  content: "";
  position: absolute;
  inset: -35%;
  background: radial-gradient(circle, rgba(255,255,255,0.22), transparent 55%);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.support-cta:hover .support-ico::after {
  opacity: 1;
}

.support-cta.whatsapp {
  border-color: rgba(37, 211, 102, 0.42);
  box-shadow: 0 16px 42px rgba(37, 211, 102, 0.10), 0 14px 34px rgba(0, 0, 0, 0.22);
}

.support-cta.whatsapp:hover {
  border-color: rgba(37, 211, 102, 0.85);
  box-shadow: 0 20px 54px rgba(37, 211, 102, 0.20), 0 16px 36px rgba(0, 0, 0, 0.25);
}

.support-cta.telegram {
  border-color: rgba(38, 165, 228, 0.42);
  box-shadow: 0 16px 42px rgba(38, 165, 228, 0.10), 0 14px 34px rgba(0, 0, 0, 0.22);
}

.support-cta.telegram:hover {
  border-color: rgba(38, 165, 228, 0.85);
  box-shadow: 0 20px 54px rgba(38, 165, 228, 0.20), 0 16px 36px rgba(0, 0, 0, 0.25);
}

.support-cta.youtube {
  border-color: rgba(255, 0, 0, 0.42);
  box-shadow: 0 16px 42px rgba(255, 0, 0, 0.10), 0 14px 34px rgba(0, 0, 0, 0.22);
}

.support-cta.youtube:hover {
  border-color: rgba(255, 0, 0, 0.85);
  box-shadow: 0 20px 54px rgba(255, 0, 0, 0.20), 0 16px 36px rgba(0, 0, 0, 0.25);
}

.support-cta.call {
  border-color: rgba(250, 204, 21, 0.44);
  box-shadow: 0 16px 42px rgba(250, 204, 21, 0.10), 0 14px 34px rgba(0, 0, 0, 0.22);
}

.support-cta.call:hover {
  border-color: rgba(250, 204, 21, 0.85);
  box-shadow: 0 20px 54px rgba(250, 204, 21, 0.20), 0 16px 36px rgba(0, 0, 0, 0.25);
}

.support-cta b {
  text-shadow: 0 0 18px rgba(255,255,255,0.10);
}

.support-cta.whatsapp b {
  color: #bbf7d0;
}

.support-cta.telegram b {
  color: #bae6fd;
}

.support-cta.youtube b {
  color: #fecaca;
}

.support-cta.call b {
  color: #fef3c7;
}

/* Step 26 support CTA sharp icon correction */
.support-ico.brand-icon img {
  filter: none !important;
  opacity: 1 !important;
  width: 26px;
  height: 26px;
}

.support-cta .support-ico::after {
  display: none !important;
}

.support-cta .support-ico {
  overflow: visible !important;
}

.support-cta.whatsapp .support-ico,
.support-cta.telegram .support-ico,
.support-cta.youtube .support-ico,
.support-cta.call .support-ico {
  box-shadow: none !important;
}

.support-cta.whatsapp {
  background:
    linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(18, 50, 38, 0.86)) !important;
  border-color: rgba(37, 211, 102, 0.42) !important;
}

.support-cta.telegram {
  background:
    linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(18, 45, 65, 0.86)) !important;
  border-color: rgba(38, 165, 228, 0.42) !important;
}

.support-cta.youtube {
  background:
    linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(60, 24, 32, 0.86)) !important;
  border-color: rgba(255, 0, 0, 0.42) !important;
}

.support-cta.call {
  background:
    linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(58, 48, 22, 0.86)) !important;
  border-color: rgba(250, 204, 21, 0.42) !important;
}

.support-cta:hover {
  transform: translateY(-2px);
  filter: brightness(1.08);
}

.support-cta.whatsapp:hover,
.support-cta.telegram:hover,
.support-cta.youtube:hover,
.support-cta.call:hover {
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.28) !important;
}

/* Step 27.2 - Premium Upgrade Modal Support Buttons */
.upgrade-modal-actions {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: 10px;
  margin-top: 16px;
}

.upgrade-modal-actions .upgrade-main-action {
  grid-row: span 2;
}

.upgrade-main-action,
.upgrade-secondary-action {
  border: 1px solid rgba(34, 211, 238, 0.25);
  border-radius: 16px;
  min-height: 50px;
  padding: 12px 14px;
  color: #ffffff;
  font-weight: 900;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  background: linear-gradient(135deg, #22d3ee, #7c3aed 58%, #fb6a21);
  box-shadow: 0 12px 32px rgba(34, 211, 238, 0.16);
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.upgrade-secondary-action {
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(30, 41, 59, 0.92));
  border-color: rgba(148, 163, 184, 0.22);
  color: #dbeafe;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.06);
}

.upgrade-main-action:hover,
.upgrade-secondary-action:hover,
.upgrade-support-card:hover {
  transform: translateY(-2px);
  border-color: rgba(34, 211, 238, 0.55);
  box-shadow: 0 16px 38px rgba(34, 211, 238, 0.18);
}

.upgrade-support-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.upgrade-support-card {
  min-height: 62px;
  border-radius: 16px;
  padding: 10px 12px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(30, 41, 59, 0.78));
  color: #ffffff;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 11px;
  overflow: hidden;
  position: relative;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.06);
}

.upgrade-support-card::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.16;
  pointer-events: none;
}

.upgrade-support-card.whatsapp::before {
  background: radial-gradient(circle at top left, #25D366, transparent 62%);
}

.upgrade-support-card.telegram::before {
  background: radial-gradient(circle at top left, #26A5E4, transparent 62%);
}

.upgrade-support-card.youtube::before {
  background: radial-gradient(circle at top left, #FF0000, transparent 62%);
}

.upgrade-support-card.call::before {
  background: radial-gradient(circle at top left, #facc15, transparent 62%);
}

.upgrade-support-icon {
  width: 38px;
  height: 38px;
  min-width: 38px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(15, 23, 42, 0.74);
  border: 1px solid rgba(255,255,255,0.12);
  box-shadow: 0 10px 26px rgba(0,0,0,0.22);
  z-index: 1;
}

.upgrade-support-icon img {
  width: 22px;
  height: 22px;
  display: block;
  filter: drop-shadow(0 0 8px rgba(255,255,255,0.18));
}

.upgrade-support-card span:last-child {
  z-index: 1;
  min-width: 0;
}

.upgrade-support-card b {
  display: block;
  font-size: 13px;
  line-height: 1.1;
  white-space: nowrap;
}

.upgrade-support-card small {
  display: block;
  margin-top: 4px;
  font-size: 11px;
  line-height: 1.1;
  color: #9fb4d8;
  white-space: nowrap;
}

.upgrade-support-card.call .call-icon {
  color: #facc15;
  font-size: 20px;
  font-weight: 900;
}

@media (max-width: 720px) {
  .upgrade-modal-actions,
  .upgrade-support-grid {
    grid-template-columns: 1fr;
  }

  .upgrade-modal-actions .upgrade-main-action {
    grid-row: auto;
  }
}

/* Step 27.2B - Clean Upgrade Modal Main Action Buttons */
.upgrade-modal-actions {
  display: grid !important;
  grid-template-columns: 1fr !important;
  gap: 10px !important;
  margin-top: 14px !important;
}

.upgrade-modal-actions .upgrade-main-action {
  grid-row: auto !important;
}

.upgrade-main-action,
.upgrade-secondary-action {
  width: 100% !important;
  min-height: 48px !important;
  border-radius: 14px !important;
  padding: 11px 14px !important;
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 10px !important;
  text-align: center !important;
  line-height: 1.1 !important;
}

.upgrade-main-action strong,
.upgrade-secondary-action strong {
  display: inline-block !important;
  white-space: nowrap !important;
  font-size: 13px !important;
  line-height: 1.1 !important;
}

.upgrade-main-action span,
.upgrade-secondary-action span {
  width: 22px !important;
  min-width: 22px !important;
  height: 22px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: 15px !important;
  line-height: 1 !important;
}

.upgrade-secondary-action {
  min-height: 44px !important;
}

.upgrade-support-grid {
  margin-top: 12px !important;
}

/* Step 27.2C - Premium secondary upgrade buttons */
.upgrade-secondary-action {
  background: linear-gradient(135deg, #1f78ff, #7c3aed 58%, #22d3ee) !important;
  border-color: rgba(34, 211, 238, 0.45) !important;
  color: #ffffff !important;
  box-shadow: 0 12px 28px rgba(124, 58, 237, 0.22) !important;
}

.upgrade-secondary-action:nth-child(3) {
  background: linear-gradient(135deg, #7c3aed, #2563eb 58%, #06b6d4) !important;
}

.upgrade-secondary-action span {
  filter: drop-shadow(0 0 8px rgba(255,255,255,0.28)) !important;
}

.upgrade-secondary-action strong {
  color: #ffffff !important;
}

/* Step 28.2 - Dynamic onboarding card */
.onboarding-card {
  margin-bottom: 18px;
  padding: 18px;
  border-radius: 24px;
  border: 1px solid rgba(34, 211, 238, 0.22);
  background:
    radial-gradient(circle at 12% 10%, rgba(34, 211, 238, 0.22), transparent 30%),
    radial-gradient(circle at 88% 0%, rgba(124, 58, 237, 0.22), transparent 32%),
    linear-gradient(135deg, rgba(8, 18, 38, 0.96), rgba(17, 24, 55, 0.94));
  box-shadow: 0 22px 55px rgba(0, 0, 0, 0.28), inset 0 1px 0 rgba(255,255,255,0.06);
  overflow: hidden;
  position: relative;
}

.onboarding-card::after {
  content: "";
  position: absolute;
  right: -80px;
  top: -90px;
  width: 210px;
  height: 210px;
  background: radial-gradient(circle, rgba(34, 211, 238, 0.16), transparent 68%);
  pointer-events: none;
}

.onboarding-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  position: relative;
  z-index: 1;
}

.onboarding-kicker {
  display: inline-flex;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(34, 211, 238, 0.12);
  border: 1px solid rgba(34, 211, 238, 0.22);
  color: #67e8f9;
  font-size: 12px;
  font-weight: 900;
  margin-bottom: 9px;
}

.onboarding-head h3 {
  margin: 0;
  color: #ffffff;
  font-size: 21px;
  line-height: 1.15;
}

.onboarding-head p {
  margin: 7px 0 0;
  color: #a8b5d1;
  font-size: 13px;
  line-height: 1.45;
}

.onboarding-plan-pill {
  white-space: nowrap;
  padding: 8px 11px;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.16), rgba(124, 58, 237, 0.20));
  border: 1px solid rgba(34, 211, 238, 0.26);
  color: #ffffff;
  font-size: 12px;
  font-weight: 900;
}

.onboarding-steps {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-top: 16px;
  position: relative;
  z-index: 1;
}

.onboarding-step {
  min-height: 112px;
  padding: 12px;
  border-radius: 18px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  background: rgba(15, 23, 42, 0.62);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.05);
}

.onboarding-step span {
  width: 30px;
  height: 30px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #22d3ee, #7c3aed);
  color: #ffffff;
  font-weight: 900;
  font-size: 12px;
  margin-bottom: 10px;
}

.onboarding-step b {
  display: block;
  color: #ffffff;
  font-size: 13px;
  line-height: 1.2;
}

.onboarding-step small {
  display: block;
  color: #9fb4d8;
  font-size: 11px;
  line-height: 1.35;
  margin-top: 5px;
}

.onboarding-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 15px;
  position: relative;
  z-index: 1;
}

.onboarding-actions button {
  border: 1px solid rgba(34, 211, 238, 0.24);
  border-radius: 14px;
  padding: 10px 14px;
  color: #ffffff;
  font-weight: 900;
  cursor: pointer;
  background: linear-gradient(135deg, #22d3ee, #4f46e5 58%, #7c3aed);
  box-shadow: 0 12px 28px rgba(34, 211, 238, 0.14);
}

.onboarding-actions button:hover {
  transform: translateY(-2px);
  border-color: rgba(34, 211, 238, 0.55);
  box-shadow: 0 16px 36px rgba(34, 211, 238, 0.20);
}

@media (max-width: 1180px) {
  .onboarding-steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .onboarding-head {
    flex-direction: column;
  }

  .onboarding-plan-pill {
    white-space: normal;
  }

  .onboarding-steps {
    grid-template-columns: 1fr;
  }

  .onboarding-actions button {
    width: 100%;
  }
}


/* Step 28.4 - Forgot password support box */
.auth-help-box {
  margin-top: 12px;
  padding: 12px;
  border-radius: 16px;
  border: 1px solid rgba(34, 211, 238, 0.22);
  background: linear-gradient(135deg, rgba(10, 20, 44, 0.92), rgba(17, 24, 39, 0.88));
  box-shadow:
    0 14px 34px rgba(0, 0, 0, 0.24),
    inset 0 1px 0 rgba(255,255,255,0.06);
}

.auth-help-box b {
  display: block;
  color: #ffffff;
  font-size: 13px;
  margin-bottom: 4px;
}

.auth-help-box span {
  display: block;
  color: #a8b5d1;
  font-size: 12px;
  line-height: 1.35;
}

.auth-help-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 10px;
}

.auth-help-actions .auth-help-link {
  min-height: 44px;
  border-radius: 14px;
  padding: 9px 14px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  position: relative;
  overflow: hidden;
  isolation: isolate;
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow:
    0 12px 28px rgba(34, 211, 238, 0.14),
    inset 0 1px 0 rgba(255,255,255,0.18);
}

.auth-help-actions .auth-help-link.whatsapp,
.auth-help-actions .auth-help-link.telegram {
  background: linear-gradient(135deg, #22d3ee 0%, #2563eb 48%, #7c3aed 100%);
}

.auth-help-actions .auth-help-link.whatsapp::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 18% 50%, rgba(37, 211, 102, 0.42), transparent 35%);
  z-index: -1;
}

.auth-help-actions .auth-help-link.telegram::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 18% 50%, rgba(38, 165, 228, 0.42), transparent 35%);
  z-index: -1;
}

.auth-help-actions .auth-help-link:hover {
  transform: translateY(-2px);
  box-shadow:
    0 16px 34px rgba(34, 211, 238, 0.24),
    inset 0 1px 0 rgba(255,255,255,0.24);
}

.auth-help-icon {
  width: 28px;
  height: 28px;
  min-width: 28px;
  background: transparent;
  border: none;
  box-shadow: none;
  padding: 0;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.auth-help-icon img {
  width: 24px;
  height: 24px;
  display: block;
  object-fit: contain;
  opacity: 1;
  filter:
    drop-shadow(0 2px 2px rgba(0,0,0,0.38))
    drop-shadow(0 0 6px rgba(255,255,255,0.28));
}

.auth-help-link b {
  position: relative;
  z-index: 2;
  color: #ffffff;
  font-size: 13px;
  font-weight: 900;
  text-shadow: 0 1px 8px rgba(0,0,0,0.30);
  letter-spacing: 0.1px;
}


/* Step 28.5 - Production safety banner polish */
.safety-top-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  padding: 8px 12px;
  border-radius: 999px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
  border: 1px solid rgba(255,255,255,0.14);
  box-shadow:
    0 10px 24px rgba(0,0,0,0.18),
    inset 0 1px 0 rgba(255,255,255,0.12);
}

.safety-top-pill.paper {
  background:
    radial-gradient(circle at 10% 50%, rgba(34, 197, 94, 0.34), transparent 36%),
    linear-gradient(135deg, rgba(15, 118, 110, 0.90), rgba(30, 64, 175, 0.88));
  border-color: rgba(34, 197, 94, 0.28);
}

.safety-top-pill.live-off {
  background:
    radial-gradient(circle at 10% 50%, rgba(168, 85, 247, 0.34), transparent 36%),
    linear-gradient(135deg, rgba(79, 70, 229, 0.90), rgba(88, 28, 135, 0.88));
  border-color: rgba(168, 85, 247, 0.28);
}

.safety-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #22c55e;
  box-shadow: 0 0 12px rgba(34, 197, 94, 0.85);
}

.safety-top-pill.live-off .safety-dot {
  background: #c084fc;
  box-shadow: 0 0 12px rgba(192, 132, 252, 0.85);
}

.production-safety-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin: 14px 0 18px;
}

.safety-strip-item {
  min-height: 86px;
  padding: 14px;
  border-radius: 20px;
  border: 1px solid rgba(34, 211, 238, 0.18);
  background:
    radial-gradient(circle at 12% 20%, rgba(34, 211, 238, 0.14), transparent 34%),
    linear-gradient(135deg, rgba(15, 23, 42, 0.92), rgba(17, 24, 39, 0.82));
  box-shadow:
    0 14px 34px rgba(0,0,0,0.18),
    inset 0 1px 0 rgba(255,255,255,0.05);
}

.safety-strip-item span {
  width: 32px;
  height: 32px;
  border-radius: 13px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 9px;
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.22), rgba(124, 58, 237, 0.24));
  border: 1px solid rgba(255,255,255,0.10);
}

.safety-strip-item b {
  display: block;
  color: #ffffff;
  font-size: 13px;
  line-height: 1.2;
}

.safety-strip-item small {
  display: block;
  color: #9fb4d8;
  font-size: 11px;
  line-height: 1.35;
  margin-top: 5px;
}

@media (max-width: 1180px) {
  .production-safety-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .production-safety-strip {
    grid-template-columns: 1fr;
  }

  .safety-top-pill {
    width: 100%;
    justify-content: center;
  }
}

/* Step 29.4 - Admin launch readiness metrics */
.admin-metrics-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.admin-metrics-status {
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
  border-radius: 999px;
  color: #ffffff;
  font-size: 13px;
  font-weight: 900;
  border: 1px solid rgba(255,255,255,0.14);
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.88), rgba(15, 23, 42, 0.84));
}

.admin-metrics-status.ready {
  background:
    radial-gradient(circle at 12% 50%, rgba(34, 197, 94, 0.32), transparent 38%),
    linear-gradient(135deg, rgba(15, 118, 110, 0.92), rgba(37, 99, 235, 0.84));
  border-color: rgba(34, 197, 94, 0.28);
}

.admin-metrics-status.warn {
  background:
    radial-gradient(circle at 12% 50%, rgba(245, 158, 11, 0.32), transparent 38%),
    linear-gradient(135deg, rgba(146, 64, 14, 0.92), rgba(124, 58, 237, 0.84));
  border-color: rgba(245, 158, 11, 0.30);
}

.admin-metrics-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.admin-metric-card {
  min-height: 118px;
  padding: 14px;
  border-radius: 20px;
  border: 1px solid rgba(34, 211, 238, 0.16);
  background:
    radial-gradient(circle at 12% 18%, rgba(34, 211, 238, 0.12), transparent 34%),
    linear-gradient(135deg, rgba(15, 23, 42, 0.92), rgba(17, 24, 39, 0.82));
  box-shadow:
    0 14px 34px rgba(0,0,0,0.16),
    inset 0 1px 0 rgba(255,255,255,0.05);
}

.admin-metric-card.good {
  border-color: rgba(34, 197, 94, 0.22);
}

.admin-metric-card.warn {
  border-color: rgba(245, 158, 11, 0.30);
}

.admin-metric-card span {
  display: block;
  color: #9fb4d8;
  font-size: 12px;
  font-weight: 800;
}

.admin-metric-card b {
  display: block;
  color: #ffffff;
  font-size: 24px;
  line-height: 1.1;
  margin-top: 8px;
}

.admin-metric-card small {
  display: block;
  color: #9fb4d8;
  font-size: 11px;
  line-height: 1.35;
  margin-top: 8px;
}

@media (max-width: 1180px) {
  .admin-metrics-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .admin-metrics-head {
    align-items: stretch;
    flex-direction: column;
  }

  .admin-metrics-grid {
    grid-template-columns: 1fr;
  }
}

/* Step 29.4B - Admin metrics refresh button polish */
.admin-metrics-head .primary-btn {
  min-width: 185px;
  padding-left: 22px;
  padding-right: 22px;
  white-space: nowrap;
}

/* Step 29.5 - Clickable admin metrics */
.admin-metric-card.clickable {
  width: 100%;
  text-align: left;
  cursor: pointer;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.admin-metric-card.clickable:hover {
  transform: translateY(-2px);
  border-color: rgba(34, 211, 238, 0.46);
  box-shadow:
    0 18px 42px rgba(34, 211, 238, 0.14),
    inset 0 1px 0 rgba(255,255,255,0.08);
}

.admin-metric-card.warn-soft {
  border-color: rgba(245, 158, 11, 0.22);
}

.admin-metric-card em {
  display: inline-flex;
  margin-top: 10px;
  color: #67e8f9;
  font-style: normal;
  font-size: 11px;
  font-weight: 900;
}

/* Step 29.5 - Clickable admin metrics */
.admin-metric-card.clickable {
  width: 100%;
  text-align: left;
  cursor: pointer;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.admin-metric-card.clickable:hover {
  transform: translateY(-2px);
  border-color: rgba(34, 211, 238, 0.46);
  box-shadow:
    0 18px 42px rgba(34, 211, 238, 0.14),
    inset 0 1px 0 rgba(255,255,255,0.08);
}

.admin-metric-card.warn-soft {
  border-color: rgba(245, 158, 11, 0.22);
}

.admin-metric-card em {
  display: inline-flex;
  margin-top: 10px;
  color: #67e8f9;
  font-style: normal;
  font-size: 11px;
  font-weight: 900;
}


/* Step 32 main website back-link */
.main-site-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 10px 18px;
  border-radius: 999px;
  border: 1px solid rgba(250, 204, 21, 0.36);
  background:
    radial-gradient(circle at 18% 50%, rgba(250, 204, 21, 0.22), transparent 30%),
    linear-gradient(135deg, #111827 0%, #1e1b4b 48%, #312e81 100%);
  color: #ffffff !important;
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.01em;
  text-decoration: none;
  box-shadow:
    0 14px 34px rgba(49, 46, 129, 0.34),
    0 0 24px rgba(250, 204, 21, 0.14),
    inset 0 1px 0 rgba(255,255,255,0.14);
  position: relative;
  overflow: hidden;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.main-site-link::before {
  content: "↗";
  width: 22px;
  height: 22px;
  margin-right: 8px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #f59e0b, #facc15);
  color: #111827;
  font-size: 13px;
  font-weight: 900;
  box-shadow:
    0 0 14px rgba(250, 204, 21, 0.34),
    inset 0 1px 0 rgba(255,255,255,0.40);
}

.main-site-link::after {
  content: "";
  position: absolute;
  top: -90%;
  left: -45%;
  width: 40%;
  height: 280%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.26), transparent);
  transform: rotate(25deg) translateX(-180%);
  transition: 0.65s ease;
}

.main-site-link:hover::after {
  transform: rotate(25deg) translateX(430%);
}

.main-site-link:hover {
  transform: translateY(-2px);
  border-color: rgba(250, 204, 21, 0.68);
  box-shadow:
    0 18px 44px rgba(49, 46, 129, 0.46),
    0 0 34px rgba(250, 204, 21, 0.22);
  color: #ffffff !important;
}

@media (max-width: 720px) {
  .main-site-link {
    width: 100%;
    min-height: 42px;
  }
}


/* Step 34 final mobile app-like bottom navigation */
.mobile-bottom-nav {
  display: none;
}

@media (max-width: 820px) {
  body {
    padding-bottom: calc(84px + env(safe-area-inset-bottom, 0px));
  }

  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    display: none !important;
  }

  .topbar {
    position: sticky;
    top: 0;
    z-index: 80;
    margin: -14px -14px 14px;
    padding: 12px 14px;
    border-radius: 0 0 20px 20px;
    background:
      linear-gradient(180deg, rgba(2, 6, 23, 0.96), rgba(15, 23, 42, 0.90));
    backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(148, 163, 184, 0.16);
    gap: 10px;
  }

  .search-box {
    min-height: 46px;
  }

  .top-actions {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 8px;
  }

  .main-site-link {
    grid-column: 1 / 2;
    width: 100%;
    max-width: none;
    min-height: 38px;
    padding: 8px 10px;
    font-size: 11px;
    justify-self: stretch;
  }

  .safety-top-pill {
    min-height: 36px;
    justify-content: center;
    font-size: 11px;
    padding: 9px 10px;
  }

  .top-actions .safety-top-pill.paper {
    grid-column: 1 / 2;
  }

  .top-actions .safety-top-pill.live-off {
    grid-column: 2 / 3;
  }

  .notification-btn {
    justify-self: start;
  }

  .user-chip {
    justify-self: end;
  }

  .mobile-bottom-nav {
    position: fixed;
    left: 0;
    right: 0;
    bottom: -14px;
    width: 100%;
    z-index: 999;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 5px;
    padding: 8px;
    border-radius: 22px 22px 0 0;
    border: 1px solid rgba(125, 211, 252, 0.38);
    background:
      radial-gradient(circle at 12% 0%, rgba(56, 189, 248, 0.38), transparent 34%),
      radial-gradient(circle at 88% 8%, rgba(16, 185, 129, 0.30), transparent 36%),
      linear-gradient(135deg, rgb(5, 18, 40), rgb(8, 34, 56), rgb(3, 56, 45));
    backdrop-filter: none;
    box-shadow:
      0 18px 52px rgba(0, 0, 0, 0.46),
      0 0 38px rgba(14, 165, 233, 0.18),
      inset 0 1px 0 rgba(255, 255, 255, 0.09);
  }

  .mobile-nav-item {
    min-width: 0;
    height: 58px;
    border: 0;
    border-radius: 18px;
    background: transparent;
    color: rgba(226, 232, 240, 0.82);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    font-size: 10.2px;
    font-weight: 900;
    letter-spacing: -0.01em;
    cursor: pointer;
    position: relative;
    -webkit-tap-highlight-color: transparent;
    transition: transform 0.18s ease, background 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
  }

  .mobile-nav-item:focus,
  .mobile-nav-item:focus-visible {
    outline: none;
    box-shadow: none;
  }

  .mobile-nav-icon-wrap {
    width: 28px;
    height: 28px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(15, 23, 42, 0.42);
    border: 1px solid rgba(148, 163, 184, 0.25);
    box-shadow:
      inset 0 1px 0 rgba(255,255,255,0.07),
      0 6px 16px rgba(0,0,0,0.10);
    transition: all 0.18s ease;
  }

  .mobile-nav-icon-svg {
    width: 18px;
    height: 18px;
    stroke: currentColor;
    stroke-width: 1.95;
    stroke-linecap: round;
    stroke-linejoin: round;
    fill: none;
  }

  .mobile-gear-icon {
    width: 18px;
    height: 18px;
    overflow: visible;
  }

  .mobile-nav-item.active {
    color: #ffffff;
    background:
      radial-gradient(circle at 35% 20%, rgba(255, 255, 255, 0.24), transparent 34%),
      linear-gradient(135deg, #2563eb 0%, #06b6d4 50%, #10b981 100%);
    box-shadow:
      0 13px 32px rgba(14, 165, 233, 0.34),
      0 0 24px rgba(16, 185, 129, 0.20),
      inset 0 1px 0 rgba(255, 255, 255, 0.24);
    transform: translateY(-2px);
  }

  .mobile-nav-item.active .mobile-nav-icon-wrap {
    background: rgba(255, 255, 255, 0.18);
    border-color: rgba(255, 255, 255, 0.30);
    box-shadow:
      0 8px 24px rgba(14, 165, 233, 0.24),
      inset 0 1px 0 rgba(255,255,255,0.24);
  }

  .mobile-nav-item:active {
    transform: scale(0.97);
  }

  .mobile-nav-item.active:active {
    transform: translateY(-2px) scale(0.98);
  }

  .mobile-nav-item::after {
    content: "";
    position: absolute;
    inset: auto 18px 5px;
    height: 3px;
    border-radius: 999px;
    background: transparent;
    transition: background 0.18s ease, box-shadow 0.18s ease;
  }

  .mobile-nav-item.active::after {
    background: rgba(255,255,255,0.72);
    box-shadow: 0 0 14px rgba(255,255,255,0.42);
  }

  .dashboard-action-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 11px;
  }

  .dashboard-action-card {
    min-height: 132px;
    padding: 15px;
    border-radius: 20px;
  }

  #page-home .action-title {
    font-size: 15px;
  }

  #page-home .action-desc {
    font-size: 12px;
    line-height: 1.45;
  }

  .page-title {
    font-size: 25px;
    letter-spacing: -0.04em;
  }

  .page-desc {
    font-size: 13px;
    line-height: 1.55;
  }

  .compact-page-grid,
  .dashboard-home-grid {
    gap: 12px;
  }

  .card,
  .stat-card,
  .mini-card {
    border-radius: 20px;
  }

  #page-settings .support-cta-grid {
    gap: 10px;
  }

  #page-settings .support-cta {
    min-height: 68px;
    padding: 12px 14px;
    border-radius: 20px;
  }

  #page-settings .support-ico {
    width: 44px;
    height: 44px;
    min-width: 44px;
  }

  #page-settings .support-cta b {
    font-size: 15px;
  }

  #page-settings .support-cta small {
    font-size: 12px;
  }

  .page-section,
  .app-page {
    padding-bottom: 14px;
  }
}


/* Step 36 mobile Settings tabs + Exchange/Get Pro sections */
.settings-mobile-tabs {
  display: none;
}

.settings-shortcut-btn {
  margin-top: 13px;
  width: 100%;
}

.get-pro-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 13px;
}

.get-pro-main-btn,
.secondary-pro-btn {
  min-height: 44px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-weight: 900;
  text-decoration: none;
}

.secondary-pro-btn {
  color: #e0f2fe;
  border: 1px solid rgba(125, 211, 252, 0.28);
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.90), rgba(30, 41, 59, 0.78));
  box-shadow: 0 12px 28px rgba(2, 6, 23, 0.18);
}

.secondary-pro-btn:hover {
  color: #ffffff;
  border-color: rgba(125, 211, 252, 0.52);
}

@media (max-width: 820px) {
  #page-settings .page-head {
    margin-bottom: 12px;
  }

  .settings-mobile-tabs {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 6px;
    margin: 0 0 12px;
    padding: 7px;
    border-radius: 22px;
    border: 1px solid rgba(125, 211, 252, 0.22);
    background:
      radial-gradient(circle at 12% 0%, rgba(56, 189, 248, 0.22), transparent 34%),
      linear-gradient(135deg, rgba(15, 23, 42, 0.94), rgba(30, 41, 59, 0.76));
    box-shadow:
      0 14px 34px rgba(2, 6, 23, 0.30),
      inset 0 1px 0 rgba(255,255,255,0.05);
  }

  .settings-mobile-tab {
    min-height: 42px;
    border: 0;
    border-radius: 15px;
    background: transparent;
    color: rgba(226, 232, 240, 0.72);
    font-size: 11px;
    font-weight: 900;
    letter-spacing: -0.01em;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    transition: transform 0.18s ease, background 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
  }

  .settings-mobile-tab.active {
    color: #ffffff;
    background:
      radial-gradient(circle at 35% 25%, rgba(255, 255, 255, 0.18), transparent 34%),
      linear-gradient(135deg, #2563eb 0%, #06b6d4 50%, #10b981 100%);
    box-shadow:
      0 10px 24px rgba(14, 165, 233, 0.26),
      inset 0 1px 0 rgba(255,255,255,0.20);
    transform: translateY(-1px);
  }

  .settings-mobile-tab.pro-tab.active {
    background:
      radial-gradient(circle at 35% 25%, rgba(255, 255, 255, 0.20), transparent 34%),
      linear-gradient(135deg, #f59e0b 0%, #facc15 48%, #10b981 100%);
    color: #111827;
  }

  .settings-mobile-tab:focus,
  .settings-mobile-tab:focus-visible {
    outline: none;
  }

  #page-settings .mobile-settings-group {
    display: none !important;
  }

  #page-settings .mobile-settings-group.mobile-active {
    display: block !important;
  }

  #page-settings .compact-page-grid.mobile-settings-group.mobile-active {
    display: grid !important;
    grid-template-columns: 1fr;
  }

  #page-settings .mobile-settings-group.hidden {
    display: none !important;
  }

  #page-settings #upgradeSupportCard.mobile-active,
  #page-settings #settingsExchangeCard.mobile-active,
  #page-settings #settingsGetProCard.mobile-active {
    margin-top: 0 !important;
  }

  #page-settings .card.mobile-settings-admin.mobile-active {
    margin-top: 0 !important;
  }

  .get-pro-actions {
    grid-template-columns: 1fr;
  }
}


/* Step 36.4 role-aware Guide/Admin settings tab */
@media (max-width: 820px) {
  .settings-mobile-tabs {
    grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
    gap: 6px !important;
    padding: 7px !important;
    margin-bottom: 13px !important;
  }

  .settings-mobile-tab {
    min-height: 41px !important;
    border-radius: 15px !important;
    font-size: 10.8px !important;
    font-weight: 900 !important;
    white-space: nowrap;
  }

  .settings-mobile-tab.pro-tab {
    color: #facc15;
  }

  .settings-mobile-tab.pro-tab.active {
    color: #111827 !important;
    background:
      radial-gradient(circle at 35% 25%, rgba(255, 255, 255, 0.24), transparent 34%),
      linear-gradient(135deg, #f59e0b 0%, #facc15 50%, #10b981 100%) !important;
  }

  .settings-guide-admin-tab.active {
    background:
      radial-gradient(circle at 35% 25%, rgba(255, 255, 255, 0.18), transparent 34%),
      linear-gradient(135deg, #7c3aed 0%, #2563eb 50%, #06b6d4 100%) !important;
    color: #ffffff !important;
  }

  #page-settings #settingsGuideCard.mobile-active,
  #page-settings #upgradeSupportCard.mobile-active,
  #page-settings #settingsExchangeCard.mobile-active,
  #page-settings #settingsGetProCard.mobile-active {
    margin-top: 0 !important;
  }

  #page-settings .card.mobile-settings-admin.mobile-active {
    margin-top: 0 !important;
  }
}

@media (max-width: 390px) {
  .settings-mobile-tab {
    font-size: 10px !important;
    padding-left: 3px !important;
    padding-right: 3px !important;
  }
}


/* Step 36 settings tab glitch fix */
@media (max-width: 820px) {
  .settings-mobile-tabs {
    position: relative;
    z-index: 20;
    pointer-events: auto;
  }

  .settings-mobile-tab {
    position: relative;
    z-index: 21;
    pointer-events: auto;
    touch-action: manipulation;
  }

  #page-settings .mobile-settings-group {
    position: relative;
    z-index: 1;
  }

  #page-settings .mobile-settings-group:not(.mobile-active) {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }

  #page-settings .mobile-settings-group.mobile-active {
    visibility: visible !important;
    pointer-events: auto !important;
  }

  #page-settings .compact-page-grid.mobile-settings-group.mobile-active {
    display: grid !important;
    grid-template-columns: 1fr !important;
  }

  #page-settings .card.mobile-settings-group.mobile-active {
    display: block !important;
  }

  #page-settings .mobile-settings-group.hidden.mobile-active {
    display: none !important;
  }
}


/* Step 36 final settings tab click-lock fix */
@media (max-width: 820px) {
  .settings-mobile-tabs {
    position: relative !important;
    z-index: 200 !important;
    pointer-events: auto !important;
    grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
  }

  .settings-mobile-tab {
    position: relative !important;
    z-index: 201 !important;
    pointer-events: auto !important;
    touch-action: manipulation !important;
    user-select: none;
  }

  #page-settings .mobile-settings-group {
    position: relative !important;
  }

  #page-settings .mobile-settings-group:not(.mobile-active) {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }

  #page-settings .mobile-settings-group.mobile-active {
    visibility: visible !important;
    pointer-events: auto !important;
  }

  #page-settings .compact-page-grid.mobile-settings-group.mobile-active {
    display: grid !important;
    grid-template-columns: 1fr !important;
  }

  #page-settings .card.mobile-settings-group.mobile-active {
    display: block !important;
  }

  #page-settings .mobile-settings-group.hidden.mobile-active {
    display: none !important;
  }

  .settings-guide-admin-tab.active {
    background:
      radial-gradient(circle at 35% 25%, rgba(255,255,255,0.18), transparent 34%),
      linear-gradient(135deg, #7c3aed 0%, #2563eb 50%, #06b6d4 100%) !important;
    color: #ffffff !important;
  }

  .settings-mobile-tab.pro-tab.active {
    background:
      radial-gradient(circle at 35% 25%, rgba(255,255,255,0.24), transparent 34%),
      linear-gradient(135deg, #f59e0b 0%, #facc15 50%, #10b981 100%) !important;
    color: #111827 !important;
  }
}


/* Step 36.6 mobile hamburger slide drawer */
.mobile-menu-toggle,
.mobile-control-drawer,
.mobile-drawer-overlay {
  display: none;
}

@media (max-width: 820px) {
  .topbar {
    position: sticky;
    top: 0;
    z-index: 90;
    margin: -14px -14px 14px;
    padding: 10px 12px;
    border-radius: 0 0 22px 22px;
    background:
      radial-gradient(circle at 12% 0%, rgba(56, 189, 248, 0.16), transparent 34%),
      linear-gradient(180deg, rgba(2, 6, 23, 0.97), rgba(15, 23, 42, 0.92));
    border-bottom: 1px solid rgba(148, 163, 184, 0.16);
    backdrop-filter: blur(16px);
    box-shadow: 0 14px 34px rgba(2, 6, 23, 0.34);
  }

  .search-box {
    min-height: 42px !important;
    border-radius: 18px !important;
    margin-bottom: 8px !important;
  }

  .top-actions {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    gap: 8px !important;
    width: 100% !important;
  }

  .top-actions .main-site-link,
  .top-actions .safety-top-pill,
  .top-actions .user-chip {
    display: none !important;
  }

  .notification-btn {
    width: 42px !important;
    height: 42px !important;
    min-width: 42px !important;
    justify-self: auto !important;
    order: 1;
  }

  .mobile-menu-toggle {
    order: 2;
    display: inline-flex;
    width: 44px;
    height: 42px;
    min-width: 44px;
    border-radius: 16px;
    border: 1px solid rgba(125, 211, 252, 0.22);
    background:
      radial-gradient(circle at 30% 25%, rgba(255,255,255,0.14), transparent 34%),
      linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(30, 41, 59, 0.86));
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 4px;
    cursor: pointer;
    box-shadow:
      0 10px 24px rgba(2, 6, 23, 0.28),
      inset 0 1px 0 rgba(255,255,255,0.08);
    -webkit-tap-highlight-color: transparent;
  }

  .mobile-menu-toggle span {
    width: 18px;
    height: 2px;
    border-radius: 999px;
    background: #e0f2fe;
    box-shadow: 0 0 12px rgba(56, 189, 248, 0.20);
  }

  body.mobile-drawer-open {
    overflow: hidden;
  }

  .mobile-drawer-overlay {
    position: fixed;
    inset: 0;
    z-index: 1190;
    background: rgba(2, 6, 23, 0.62);
    backdrop-filter: blur(4px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.22s ease;
  }

  .mobile-control-drawer {
    position: fixed;
    display: block;
    top: 0;
    left: 0;
    bottom: 0;
    width: min(86vw, 355px);
    z-index: 1200;
    padding: calc(18px + env(safe-area-inset-top, 0px)) 16px 18px;
    background:
      radial-gradient(circle at 12% 0%, rgba(56, 189, 248, 0.24), transparent 34%),
      radial-gradient(circle at 92% 8%, rgba(16, 185, 129, 0.18), transparent 36%),
      linear-gradient(180deg, rgba(8, 15, 35, 0.98), rgba(2, 6, 23, 0.98));
    border-right: 1px solid rgba(125, 211, 252, 0.22);
    box-shadow: 24px 0 70px rgba(0, 0, 0, 0.52);
    transform: translateX(-104%);
    transition: transform 0.26s ease;
    overflow-y: auto;
  }

  body.mobile-drawer-open .mobile-drawer-overlay {
    display: block;
    opacity: 1;
    pointer-events: auto;
  }

  body.mobile-drawer-open .mobile-control-drawer {
    transform: translateX(0);
  }

  .mobile-drawer-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
  }

  .mobile-drawer-head b {
    display: block;
    color: #ffffff;
    font-size: 20px;
    font-weight: 900;
  }

  .mobile-drawer-head small {
    display: block;
    color: rgba(226, 232, 240, 0.72);
    font-size: 12px;
    font-weight: 700;
  }

  .mobile-drawer-close {
    width: 40px;
    height: 40px;
    border: 0;
    border-radius: 15px;
    background: rgba(255,255,255,0.06);
    color: #ffffff;
    font-size: 26px;
    font-weight: 700;
    cursor: pointer;
  }

  .mobile-drawer-user {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 13px;
    border-radius: 20px;
    border: 1px solid rgba(125, 211, 252, 0.18);
    background: rgba(15, 23, 42, 0.62);
    margin-bottom: 12px;
  }

  .mobile-drawer-avatar {
    width: 44px;
    height: 44px;
    min-width: 44px;
    border-radius: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #2563eb, #06b6d4, #10b981);
    color: #ffffff;
    font-size: 13px;
    font-weight: 900;
    box-shadow: 0 12px 28px rgba(14,165,233,0.24);
  }

  .mobile-drawer-user b,
  .mobile-drawer-action b,
  .mobile-drawer-link b {
    display: block;
    color: #ffffff;
    font-size: 14px;
    font-weight: 900;
  }

  .mobile-drawer-user small,
  .mobile-drawer-action small,
  .mobile-drawer-link small {
    display: block;
    margin-top: 2px;
    color: rgba(226, 232, 240, 0.68);
    font-size: 11px;
    font-weight: 700;
  }

  .mobile-drawer-action,
  .mobile-drawer-link {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 58px;
    padding: 11px 13px;
    border-radius: 18px;
    border: 1px solid rgba(148, 163, 184, 0.16);
    background: rgba(15, 23, 42, 0.54);
    color: #ffffff;
    text-decoration: none;
    margin-bottom: 10px;
    cursor: pointer;
    text-align: left;
  }

  .mobile-drawer-action.main-site {
    border-color: rgba(250, 204, 21, 0.34);
    background:
      radial-gradient(circle at 18% 50%, rgba(250,204,21,0.16), transparent 34%),
      linear-gradient(135deg, rgba(15,23,42,0.72), rgba(49,46,129,0.62));
  }

  .drawer-action-icon,
  .mobile-drawer-link > span:first-child {
    width: 34px;
    height: 34px;
    min-width: 34px;
    border-radius: 13px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,0.07);
    color: #facc15;
    font-size: 17px;
    font-weight: 900;
  }

  .mobile-drawer-status-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 9px;
    margin: 12px 0 14px;
  }

  .mobile-drawer-status {
    min-height: 56px;
    padding: 11px 13px;
    border-radius: 18px;
    display: grid;
    grid-template-columns: auto 1fr;
    column-gap: 10px;
    align-items: center;
    border: 1px solid rgba(148, 163, 184, 0.16);
  }

  .mobile-drawer-status span {
    width: 11px;
    height: 11px;
    border-radius: 50%;
    grid-row: span 2;
  }

  .mobile-drawer-status b {
    color: #ffffff;
    font-size: 13px;
    font-weight: 900;
  }

  .mobile-drawer-status small {
    color: rgba(226,232,240,0.68);
    font-size: 11px;
    font-weight: 700;
  }

  .mobile-drawer-status.paper {
    background: linear-gradient(135deg, rgba(16,185,129,0.22), rgba(37,99,235,0.18));
    border-color: rgba(16,185,129,0.28);
  }

  .mobile-drawer-status.paper span {
    background: #22c55e;
    box-shadow: 0 0 14px rgba(34,197,94,0.60);
  }

  .mobile-drawer-status.live-off {
    background: linear-gradient(135deg, rgba(124,58,237,0.20), rgba(147,51,234,0.22));
    border-color: rgba(168,85,247,0.28);
  }

  .mobile-drawer-status.live-off span {
    background: #c084fc;
    box-shadow: 0 0 14px rgba(192,132,252,0.60);
  }

  .mobile-drawer-section-title {
    color: rgba(226,232,240,0.60);
    font-size: 11px;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin: 12px 2px 8px;
  }

  .mobile-drawer-note {
    margin-top: 12px;
    padding: 12px;
    border-radius: 16px;
    background: rgba(250, 204, 21, 0.08);
    border: 1px solid rgba(250, 204, 21, 0.18);
    color: #fde68a;
    font-size: 12px;
    line-height: 1.5;
    font-weight: 700;
  }
}


/* Step 36.7 clean mobile drawer refinement */
@media (max-width: 820px) {
  .topbar {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: flex-start !important;
    min-height: 70px !important;
    padding: calc(12px + env(safe-area-inset-top, 0px)) 14px 12px !important;
    margin: -14px -14px 14px !important;
    border-radius: 0 0 24px 24px !important;
    background:
      radial-gradient(circle at 15% 0%, rgba(59, 130, 246, 0.18), transparent 35%),
      linear-gradient(180deg, rgba(3, 7, 18, 0.97), rgba(12, 22, 46, 0.93)) !important;
    border-bottom: 1px solid rgba(148, 163, 184, 0.14) !important;
    box-shadow: 0 14px 34px rgba(2, 6, 23, 0.32) !important;
    backdrop-filter: blur(16px) !important;
    gap: 0 !important;
  }

  .topbar .search-box,
  .topbar .top-actions,
  .topbar .notification-btn,
  .topbar .user-chip,
  .topbar .main-site-link,
  .topbar .safety-top-pill {
    display: none !important;
  }

  .mobile-menu-toggle {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex-direction: column !important;
    gap: 5px !important;
    width: 56px !important;
    height: 52px !important;
    min-width: 56px !important;
    margin: 0 !important;
    border-radius: 18px !important;
    border: 1px solid rgba(125, 211, 252, 0.22) !important;
    background:
      radial-gradient(circle at 32% 25%, rgba(255,255,255,0.14), transparent 34%),
      linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(30, 41, 59, 0.88)) !important;
    box-shadow:
      0 12px 28px rgba(2, 6, 23, 0.30),
      inset 0 1px 0 rgba(255,255,255,0.07) !important;
  }

  .mobile-menu-toggle span {
    width: 24px !important;
    height: 2.8px !important;
    border-radius: 999px !important;
    background: #e0f2fe !important;
    box-shadow: 0 0 14px rgba(56, 189, 248, 0.22) !important;
  }

  .mobile-control-drawer {
    width: min(88vw, 372px) !important;
    padding: calc(18px + env(safe-area-inset-top, 0px)) 16px 18px !important;
    background:
      radial-gradient(circle at 10% 0%, rgba(34,211,238,0.20), transparent 36%),
      radial-gradient(circle at 88% 8%, rgba(16,185,129,0.14), transparent 38%),
      linear-gradient(180deg, rgba(6,12,29,0.985), rgba(2,6,23,0.985)) !important;
  }

  .mobile-drawer-head {
    align-items: flex-start !important;
    margin-bottom: 14px !important;
  }

  .mobile-drawer-brand {
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
  }

  .mobile-drawer-logo {
    width: 60px !important;
    height: 60px !important;
    min-width: 60px !important;
    border-radius: 20px !important;
    overflow: hidden !important;
    box-shadow: 0 14px 32px rgba(14, 165, 233, 0.20) !important;
  }

  .mobile-drawer-logo svg {
    width: 100% !important;
    height: 100% !important;
    display: block !important;
  }

  .mobile-drawer-head b {
    font-size: 22px !important;
    line-height: 1.02 !important;
  }

  .mobile-drawer-head small {
    font-size: 11px !important;
  }

  .mobile-drawer-close {
    width: 46px !important;
    height: 46px !important;
    border-radius: 16px !important;
    font-size: 30px !important;
  }

  .mobile-drawer-search-shell {
    position: relative !important;
    display: flex !important;
    align-items: center !important;
    min-height: 52px !important;
    margin: 6px 0 12px !important;
    border-radius: 18px !important;
    border: 1px solid rgba(125, 211, 252, 0.16) !important;
    background: rgba(15, 23, 42, 0.64) !important;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.05) !important;
    overflow: hidden !important;
  }

  .mobile-drawer-search-icon {
    width: 44px !important;
    min-width: 44px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    color: rgba(191, 219, 254, 0.72) !important;
  }

  .mobile-drawer-search-icon svg {
    width: 18px !important;
    height: 18px !important;
    display: block !important;
  }

  .mobile-drawer-search-input {
    flex: 1 !important;
    height: 52px !important;
    border: 0 !important;
    outline: 0 !important;
    background: transparent !important;
    color: #ffffff !important;
    font-size: 12.5px !important;
    font-weight: 700 !important;
    padding: 0 14px 0 0 !important;
  }

  .mobile-drawer-search-input::placeholder {
    color: rgba(191, 219, 254, 0.52) !important;
  }

  .mobile-drawer-meta-grid {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 10px !important;
    margin-bottom: 12px !important;
  }

  .mobile-drawer-meta-btn {
    width: 100% !important;
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
    min-height: 58px !important;
    padding: 10px 12px !important;
    border-radius: 18px !important;
    border: 1px solid rgba(148, 163, 184, 0.15) !important;
    background: rgba(15, 23, 42, 0.58) !important;
    color: #ffffff !important;
    text-align: left !important;
    cursor: pointer !important;
  }

  .drawer-svg-icon,
  .drawer-action-icon {
    width: 40px !important;
    height: 40px !important;
    min-width: 40px !important;
    border-radius: 14px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: rgba(255,255,255,0.07) !important;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.06) !important;
  }

  .drawer-svg-icon svg {
    width: 20px !important;
    height: 20px !important;
    display: block !important;
    color: currentColor !important;
  }

  .drawer-svg-icon.bell { color: #facc15 !important; }
  .drawer-svg-icon.language { color: #38bdf8 !important; }
  .drawer-svg-icon.exchange { color: #facc15 !important; }
  .drawer-svg-icon.bots { color: #a78bfa !important; }
  .drawer-svg-icon.settings { color: #38bdf8 !important; }
  .drawer-svg-icon.support { color: #22c55e !important; }

  .mobile-drawer-action,
  .mobile-drawer-link {
    min-height: 64px !important;
    border-radius: 20px !important;
    gap: 12px !important;
    padding: 12px 14px !important;
  }

  .mobile-drawer-action.main-site {
    border-color: rgba(250, 204, 21, 0.34) !important;
    background:
      radial-gradient(circle at 14% 45%, rgba(250,204,21,0.18), transparent 32%),
      linear-gradient(135deg, rgba(15,23,42,0.72), rgba(49,46,129,0.62)) !important;
  }

  .drawer-action-icon {
    font-size: 25px !important;
    font-weight: 900 !important;
    color: #facc15 !important;
  }

  .mobile-drawer-action b,
  .mobile-drawer-link b,
  .mobile-drawer-meta-btn b {
    font-size: 15px !important;
    font-weight: 900 !important;
  }

  .mobile-drawer-action small,
  .mobile-drawer-link small,
  .mobile-drawer-meta-btn small {
    font-size: 11.5px !important;
    font-weight: 700 !important;
  }

  .mobile-drawer-status-row {
    gap: 10px !important;
    margin: 12px 0 14px !important;
  }

  .mobile-drawer-status {
    min-height: 62px !important;
    border-radius: 20px !important;
    padding: 12px 14px !important;
  }

  .mobile-drawer-status b {
    font-size: 15px !important;
  }

  .mobile-drawer-status small {
    font-size: 11.5px !important;
  }

  .mobile-drawer-section-title {
    font-size: 12px !important;
    letter-spacing: 0.10em !important;
  }

  .mobile-drawer-note {
    border-radius: 18px !important;
    font-size: 12.5px !important;
    padding: 13px !important;
    line-height: 1.55 !important;
  }
}

@media (max-width: 430px) {
  .mobile-control-drawer {
    width: min(89vw, 360px) !important;
  }

  .mobile-menu-toggle {
    width: 54px !important;
    height: 50px !important;
  }

  .mobile-drawer-meta-grid {
    grid-template-columns: 1fr 1fr !important;
  }
}


/* Step 36.8 drawer logo/text cleanup */
@media (max-width: 820px) {
  .mobile-drawer-logo {
    background: transparent !important;
    border: 0 !important;
    box-shadow:
      0 14px 32px rgba(14, 165, 233, 0.22),
      0 0 24px rgba(16, 185, 129, 0.12) !important;
  }

  .mobile-drawer-logo img {
    width: 100% !important;
    height: 100% !important;
    display: block !important;
    object-fit: cover !important;
    border-radius: 20px !important;
  }

  .mobile-drawer-meta-grid {
    margin-top: 4px !important;
  }

  .drawer-action-icon {
    font-size: 30px !important;
    line-height: 1 !important;
  }
}


/* Step 36.9 mobile dashboard status accordion */
.mobile-status-accordion-toggle {
  display: none;
}

@media (max-width: 820px) {
  /* topbar ko clean rakho: sirf hamburger visible */
  .topbar {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    min-height: 68px !important;
    padding: calc(12px + env(safe-area-inset-top, 0px)) 14px 12px !important;
    margin: -14px -14px 12px !important;
    border-radius: 0 0 24px 24px !important;
    background:
      radial-gradient(circle at 15% 0%, rgba(59, 130, 246, 0.16), transparent 35%),
      linear-gradient(180deg, rgba(3, 7, 18, 0.97), rgba(12, 22, 46, 0.93)) !important;
    border-bottom: 1px solid rgba(148, 163, 184, 0.14) !important;
    box-shadow: 0 14px 34px rgba(2, 6, 23, 0.32) !important;
  }

  .topbar .search-box,
  .topbar .top-actions,
  .topbar .notification-btn,
  .topbar .user-chip,
  .topbar .main-site-link,
  .topbar .safety-top-pill {
    display: none !important;
  }

  .mobile-menu-toggle {
    display: inline-flex !important;
    width: 56px !important;
    height: 52px !important;
    min-width: 56px !important;
  }

  .mobile-status-accordion-toggle {
    display: flex;
    width: 100%;
    min-height: 54px;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 0 0 12px;
    padding: 12px 15px;
    border: 1px solid rgba(125, 211, 252, 0.24);
    border-radius: 22px;
    background:
      radial-gradient(circle at 18% 50%, rgba(56, 189, 248, 0.18), transparent 34%),
      linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(30, 41, 59, 0.82));
    color: #ffffff;
    box-shadow:
      0 14px 34px rgba(2, 6, 23, 0.28),
      inset 0 1px 0 rgba(255,255,255,0.06);
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
  }

  .mobile-status-toggle-left {
    display: inline-flex;
    align-items: center;
    gap: 11px;
    min-width: 0;
  }

  .mobile-status-toggle-icon {
    width: 36px;
    height: 36px;
    min-width: 36px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background:
      radial-gradient(circle at 32% 25%, rgba(255,255,255,0.18), transparent 34%),
      linear-gradient(135deg, #2563eb, #06b6d4, #10b981);
    box-shadow: 0 10px 24px rgba(14, 165, 233, 0.22);
  }

  .mobile-status-toggle-icon svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
    stroke-width: 2;
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
  }

  .mobile-status-toggle-text b {
    display: block;
    font-size: 15px;
    font-weight: 900;
    line-height: 1.1;
  }

  .mobile-status-toggle-text small {
    display: block;
    margin-top: 3px;
    color: rgba(226,232,240,0.70);
    font-size: 11.5px;
    font-weight: 700;
  }

  .mobile-status-toggle-arrow {
    width: 32px;
    height: 32px;
    min-width: 32px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,0.06);
    color: #bae6fd;
    transition: transform 0.2s ease;
  }

  body.mobile-status-expanded .mobile-status-toggle-arrow {
    transform: rotate(180deg);
  }

  body.mobile-status-collapsed .mobile-overview-item {
    display: none !important;
  }

  body.mobile-status-expanded .mobile-overview-item {
    display: block !important;
  }

  body.mobile-status-expanded .mobile-overview-item.stat-card,
  body.mobile-status-expanded .mobile-overview-item.mini-card {
    display: block !important;
  }

  .mobile-overview-item {
    transition: opacity 0.18s ease, transform 0.18s ease;
  }
}


/* Step 36.10 force all mobile overview/status blocks into accordion */
@media (max-width: 820px) {
  body.mobile-status-collapsed .mobile-overview-item {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }

  body.mobile-status-expanded .mobile-overview-item {
    display: block !important;
    visibility: visible !important;
    pointer-events: auto !important;
  }

  body.mobile-status-expanded .mobile-overview-item.stat-card,
  body.mobile-status-expanded .mobile-overview-item.mini-card,
  body.mobile-status-expanded .mobile-overview-item.card {
    display: block !important;
  }

  #mobileStatusAccordionToggle {
    display: flex !important;
  }
}


/* Step 36.12 force AI banner always visible */
@media (max-width: 820px) {
  .mobile-brand-banner-keep,
  .mobile-brand-banner-keep * {
    visibility: visible !important;
    pointer-events: auto !important;
  }

  .mobile-brand-banner-keep {
    display: block !important;
    opacity: 1 !important;
    transform: none !important;
    margin-bottom: 12px !important;
  }

  body.mobile-status-collapsed .mobile-brand-banner-keep,
  body.mobile-status-expanded .mobile-brand-banner-keep {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    pointer-events: auto !important;
  }

  body.mobile-status-collapsed .mobile-brand-banner-keep.mobile-overview-item {
    display: block !important;
  }
}


/* Step 36.14 logout button visibility polish */
#page-settings .page-head .view-btn,
#page-settings .danger-btn[onclick="logout()"] {
  border: 1px solid rgba(248, 113, 113, 0.45) !important;
  background:
    radial-gradient(circle at 22% 50%, rgba(255,255,255,0.16), transparent 28%),
    linear-gradient(135deg, rgba(127, 29, 29, 0.96), rgba(220, 38, 38, 0.90), rgba(249, 115, 22, 0.82)) !important;
  color: #ffffff !important;
  font-weight: 900 !important;
  box-shadow:
    0 14px 34px rgba(220, 38, 38, 0.22),
    0 0 22px rgba(248, 113, 113, 0.16),
    inset 0 1px 0 rgba(255,255,255,0.16) !important;
  text-shadow: 0 1px 0 rgba(0,0,0,0.22);
}

#page-settings .page-head .view-btn::before,
#page-settings .danger-btn[onclick="logout()"]::before {
  content: "⏻";
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-right: 7px;
  font-size: 14px;
  font-weight: 900;
}

#page-settings .page-head .view-btn:hover,
#page-settings .danger-btn[onclick="logout()"]:hover {
  transform: translateY(-2px);
  border-color: rgba(254, 202, 202, 0.76) !important;
  box-shadow:
    0 18px 44px rgba(220, 38, 38, 0.34),
    0 0 32px rgba(248, 113, 113, 0.24) !important;
}

@media (max-width: 820px) {
  #page-settings .page-head .view-btn {
    width: auto !important;
    min-width: 112px !important;
    min-height: 42px !important;
    padding: 10px 15px !important;
    border-radius: 16px !important;
    font-size: 13px !important;
  }

  #page-settings .danger-btn[onclick="logout()"] {
    min-height: 46px !important;
    border-radius: 16px !important;
    font-size: 14px !important;
  }
}


/* Step 36.15 logout icon mobile glyph fix */
#page-settings .page-head .view-btn::before,
#page-settings .danger-btn[onclick="logout()"]::before {
  content: "" !important;
  width: 15px;
  height: 15px;
  min-width: 15px;
  margin-right: 8px;
  display: inline-block;
  position: relative;
  border: 2px solid #ffffff;
  border-left-color: transparent;
  border-radius: 50%;
  box-sizing: border-box;
  transform: rotate(-35deg);
  vertical-align: -2px;
  filter: drop-shadow(0 1px 0 rgba(0,0,0,0.18));
}

#page-settings .page-head .view-btn::after,
#page-settings .danger-btn[onclick="logout()"]::after {
  content: "";
  width: 7px;
  height: 2px;
  display: inline-block;
  background: #ffffff;
  border-radius: 999px;
  margin-left: -13px;
  margin-right: 8px;
  transform: translateY(-3px) rotate(0deg);
  box-shadow: 0 1px 0 rgba(0,0,0,0.18);
}

@media (max-width: 820px) {
  #page-settings .page-head .view-btn::before,
  #page-settings .danger-btn[onclick="logout()"]::before {
    width: 16px;
    height: 16px;
    min-width: 16px;
    margin-right: 9px;
    border-width: 2px;
  }

  #page-settings .page-head .view-btn::after,
  #page-settings .danger-btn[onclick="logout()"]::after {
    width: 8px;
    height: 2px;
    margin-left: -14px;
    margin-right: 9px;
    transform: translateY(-3px);
  }
}


/* Step 36.16 logout icon final SVG fix */
#page-settings .page-head .view-btn::before,
#page-settings .danger-btn[onclick="logout()"]::before {
  content: "" !important;
  width: 17px !important;
  height: 17px !important;
  min-width: 17px !important;
  margin-right: 8px !important;
  display: inline-block !important;
  vertical-align: -3px !important;
  border: 0 !important;
  border-radius: 0 !important;
  transform: none !important;
  background-color: #ffffff !important;
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M10 17l5-5-5-5v3H3v4h7v3zM12 3h7a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2h-7v-2h7V5h-7V3z' fill='black'/%3E%3C/svg%3E") !important;
  mask-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M10 17l5-5-5-5v3H3v4h7v3zM12 3h7a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2h-7v-2h7V5h-7V3z' fill='black'/%3E%3C/svg%3E") !important;
  -webkit-mask-repeat: no-repeat !important;
  mask-repeat: no-repeat !important;
  -webkit-mask-position: center !important;
  mask-position: center !important;
  -webkit-mask-size: contain !important;
  mask-size: contain !important;
  filter: drop-shadow(0 1px 0 rgba(0,0,0,0.18)) !important;
}

#page-settings .page-head .view-btn::after,
#page-settings .danger-btn[onclick="logout()"]::after {
  content: none !important;
  display: none !important;
}

@media (max-width: 820px) {
  #page-settings .page-head .view-btn::before,
  #page-settings .danger-btn[onclick="logout()"]::before {
    width: 18px !important;
    height: 18px !important;
    min-width: 18px !important;
    margin-right: 9px !important;
    vertical-align: -4px !important;
  }
}

/* Step 37 mobile final polish */
@media (max-width: 820px) {
  html,
  body {
    max-width: 100%;
    overflow-x: hidden !important;
  }

  body.mobile-drawer-open {
    overflow: hidden !important;
    touch-action: none;
  }

  .mobile-drawer-overlay.show,
  .mobile-drawer-overlay.open,
  .mobile-drawer-overlay.active {
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
  }

  .mobile-control-drawer.show,
  .mobile-control-drawer.open,
  .mobile-control-drawer.active {
    transform: translateX(0) !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
  }

  .app-shell,
  .main-content {
    padding-bottom: calc(86px + env(safe-area-inset-bottom, 0px)) !important;
  }

  .app-page {
    scroll-margin-top: 84px;
  }

  .settings-mobile-tabs {
    position: sticky;
    top: 0;
    z-index: 20;
    background: rgba(3, 7, 18, 0.78);
    backdrop-filter: blur(14px);
    border-radius: 18px;
    padding: 7px;
    margin-bottom: 12px;
  }

  #page-settings .mobile-settings-group {
    display: none !important;
  }

  #page-settings .mobile-settings-group.mobile-active {
    display: block !important;
  }

  #page-settings .compact-page-grid.mobile-settings-group.mobile-active {
    display: grid !important;
  }

  .settings-mobile-tab {
    min-height: 42px !important;
    white-space: nowrap;
  }

  #page-bots #botList {
    max-height: none !important;
    overflow: visible !important;
    padding-right: 0 !important;
  }

  #page-bots .bot-grid {
    grid-template-columns: 1fr !important;
    gap: 13px !important;
  }

  #page-bots .bot-card {
    padding: 15px !important;
    border-radius: 20px !important;
  }

  #page-bots .bot-top {
    align-items: flex-start !important;
    gap: 10px !important;
  }

  #page-bots .bot-title {
    white-space: normal !important;
    overflow: visible !important;
    text-overflow: clip !important;
    line-height: 1.25 !important;
  }

  #page-bots .bot-meta {
    grid-template-columns: 1fr 1fr !important;
  }

  #page-bots .bot-actions {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 9px !important;
  }

  #page-bots .bot-actions button,
  #page-bots .bot-actions .small-btn,
  #page-bots .bot-actions .primary-btn {
    width: 100% !important;
    min-height: 42px !important;
    justify-content: center !important;
  }

  .bot-modal-overlay {
    align-items: flex-end !important;
    padding: 10px !important;
  }

  .bot-modal {
    width: 100% !important;
    max-width: 100% !important;
    max-height: calc(92dvh - env(safe-area-inset-bottom, 0px)) !important;
    overflow-y: auto !important;
    border-radius: 24px 24px 18px 18px !important;
  }

  .bot-modal-head {
    position: sticky !important;
    top: 0 !important;
    z-index: 3 !important;
    background: rgba(7, 12, 30, 0.96) !important;
    backdrop-filter: blur(14px) !important;
  }

  .bot-config-grid {
    grid-template-columns: 1fr !important;
  }

  .bot-field[style*="grid-column"] {
    grid-column: auto !important;
  }

  .bot-config-actions {
    position: sticky !important;
    bottom: 0 !important;
    z-index: 4 !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 9px !important;
    padding: 12px 0 4px !important;
    background: linear-gradient(180deg, rgba(7, 12, 30, 0), rgba(7, 12, 30, 0.98) 20%) !important;
  }

  .bot-config-actions button {
    width: 100% !important;
    min-height: 44px !important;
  }

  .support-cta-grid,
  .upgrade-support-grid {
    grid-template-columns: 1fr !important;
  }

  .admin-runtime-table,
  .admin-table,
  table {
    min-width: 720px;
  }

  #adminRuntimeBox,
  #adminUsersBox,
  #adminUpgradeRequestsBox {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
}

@media (max-width: 430px) {
  #page-bots .bot-meta {
    grid-template-columns: 1fr !important;
  }

  #page-bots .bot-actions {
    grid-template-columns: 1fr !important;
  }

  .mobile-bottom-nav {
    padding-left: 6px !important;
    padding-right: 6px !important;
  }

  .mobile-nav-item {
    min-width: 0 !important;
  }

  .mobile-nav-item span:last-child {
    font-size: 10.5px !important;
  }
}

/* Step 40 Admin Ops Status UI */
.admin-ops-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding: 14px;
  border-radius: 18px;
  margin-bottom: 14px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  background: rgba(15, 23, 42, 0.58);
}

.admin-ops-head.ok {
  border-color: rgba(34, 197, 94, 0.24);
  background: linear-gradient(135deg, rgba(22, 163, 74, 0.14), rgba(15, 23, 42, 0.62));
}

.admin-ops-head.warn {
  border-color: rgba(250, 204, 21, 0.30);
  background: linear-gradient(135deg, rgba(250, 204, 21, 0.12), rgba(15, 23, 42, 0.62));
}

.admin-ops-status {
  font-size: 18px;
  font-weight: 950;
  color: #f8fafc;
}

.admin-ops-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.admin-ops-card {
  border-radius: 18px;
  padding: 14px;
  min-height: 132px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  background: rgba(15, 23, 42, 0.58);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.04);
}

.admin-ops-card.good {
  border-color: rgba(34, 197, 94, 0.22);
  background: linear-gradient(135deg, rgba(22, 163, 74, 0.12), rgba(15, 23, 42, 0.62));
}

.admin-ops-card.warn {
  border-color: rgba(250, 204, 21, 0.28);
  background: linear-gradient(135deg, rgba(250, 204, 21, 0.11), rgba(15, 23, 42, 0.62));
}

.admin-ops-card span {
  display: block;
  color: #94a3b8;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.admin-ops-card b {
  display: block;
  margin-top: 8px;
  color: #f8fafc;
  font-size: 16px;
  line-height: 1.25;
  word-break: break-word;
}

.admin-ops-card small {
  display: block;
  margin-top: 8px;
  color: #cbd5e1;
  font-size: 12px;
  line-height: 1.4;
}

.admin-ops-card em {
  display: block;
  margin-top: 8px;
  color: #93c5fd;
  font-size: 12px;
  font-style: normal;
  line-height: 1.4;
}

.admin-ops-details {
  margin-top: 12px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 16px;
  padding: 12px;
  background: rgba(2, 6, 23, 0.42);
}

.admin-ops-details summary {
  cursor: pointer;
  color: #bae6fd;
  font-weight: 850;
}

.admin-ops-details pre {
  white-space: pre-wrap;
  word-break: break-word;
  color: #cbd5e1;
  font-size: 12px;
  line-height: 1.45;
  margin: 12px 0 0;
  max-height: 260px;
  overflow: auto;
}

@media (max-width: 1100px) {
  .admin-ops-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 680px) {
  .admin-ops-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .admin-ops-grid {
    grid-template-columns: 1fr;
  }
}


/* Step 43.19 Mobile Auth Responsive Fix Only */
@media (max-width: 820px) {
  html,
  body {
    width: 100% !important;
    max-width: 100% !important;
    overflow-x: hidden !important;
  }

  .auth-page {
    width: 100% !important;
    max-width: 100vw !important;
    min-height: 100dvh !important;
    padding: 12px 10px 18px !important;
    place-items: start center !important;
    overflow-x: hidden !important;
  }

  .auth-card {
    width: min(100%, 560px) !important;
    max-width: calc(100vw - 20px) !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 14px !important;
    padding: 14px !important;
    border-radius: 26px !important;
    margin: 0 auto !important;
    box-sizing: border-box !important;
  }

  .auth-hero {
    width: 100% !important;
    min-height: auto !important;
    border-radius: 22px !important;
    padding: 18px 16px !important;
    overflow: hidden !important;
  }

  .auth-form-wrap {
    width: 100% !important;
    border-radius: 22px !important;
    padding: 20px 16px !important;
    min-height: auto !important;
    box-sizing: border-box !important;
  }

  .auth-hero .logo-row,
  .auth-hero .sidebar-brand {
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
    width: 100% !important;
    min-width: 0 !important;
  }

  .auth-hero .logo-mark,
  .auth-hero .sidebar-brand .logo-mark {
    width: clamp(58px, 14vw, 72px) !important;
    height: clamp(58px, 14vw, 72px) !important;
    min-width: clamp(58px, 14vw, 72px) !important;
    border-radius: 999px !important;
    background: transparent !important;
    overflow: visible !important;
    box-shadow:
      0 12px 24px rgba(0,0,0,0.38),
      0 0 18px rgba(34,211,238,0.24),
      0 0 28px rgba(124,58,237,0.14) !important;
  }

  .auth-hero .logo-img,
  .auth-hero .sidebar-brand .logo-img {
    width: 100% !important;
    height: 100% !important;
    border-radius: 999px !important;
    object-fit: contain !important;
    object-position: center !important;
    background: transparent !important;
    box-shadow: none !important;
    display: block !important;
  }

  .auth-hero .brand-title {
    font-size: clamp(18px, 5vw, 24px) !important;
    line-height: 1.12 !important;
    word-break: normal !important;
    overflow-wrap: normal !important;
  }

  .auth-hero .brand-sub {
    font-size: clamp(12px, 3.7vw, 15px) !important;
    line-height: 1.2 !important;
  }

  .auth-hero h1 {
    margin-top: 30px !important;
    font-size: clamp(36px, 10.5vw, 58px) !important;
    line-height: 0.98 !important;
    letter-spacing: -1.8px !important;
  }

  .auth-hero p {
    margin-top: 14px !important;
    max-width: 100% !important;
    font-size: clamp(15px, 4.1vw, 19px) !important;
    line-height: 1.52 !important;
  }

  .auth-points {
    margin-top: 24px !important;
    gap: 10px !important;
  }

  .auth-point {
    width: 100% !important;
    min-height: 54px !important;
    padding: 10px 12px !important;
    gap: 10px !important;
    border-radius: 16px !important;
    font-size: clamp(13px, 3.6vw, 16px) !important;
    line-height: 1.18 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
  }

  .auth-point .point-ico {
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
  }

  .auth-point .point-ico svg {
    width: 18px !important;
    height: 18px !important;
  }

  .auth-form-wrap h2 {
    font-size: clamp(30px, 8.2vw, 42px) !important;
    line-height: 1.08 !important;
  }

  .auth-form-wrap p {
    font-size: clamp(15px, 4vw, 19px) !important;
    line-height: 1.5 !important;
  }

  .tab-row {
    gap: 10px !important;
    margin: 18px 0 !important;
  }

  .tab-btn,
  .auth-form-wrap .primary-btn {
    min-height: 52px !important;
    border-radius: 18px !important;
    font-size: 15px !important;
  }

  .form {
    gap: 12px !important;
  }

  .auth-form-wrap input {
    min-height: 52px !important;
    border-radius: 17px !important;
    font-size: 15px !important;
    padding: 0 16px !important;
  }

  .forgot-card,
  .forgot-password-card,
  .auth-support-card,
  .auth-help-box {
    width: 100% !important;
    max-width: 100% !important;
    padding: 14px !important;
    border-radius: 20px !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
  }

  .forgot-card h3,
  .forgot-password-card h3,
  .auth-support-card h3,
  .auth-help-box h3 {
    font-size: 17px !important;
    line-height: 1.2 !important;
  }

  .forgot-card p,
  .forgot-password-card p,
  .auth-support-card p,
  .auth-help-box p {
    font-size: 13.5px !important;
    line-height: 1.42 !important;
  }

  .forgot-actions,
  .auth-support-actions,
  .auth-help-actions,
  .support-cta-grid {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 9px !important;
    width: 100% !important;
    max-width: 100% !important;
  }

  .forgot-actions a,
  .auth-support-actions a,
  .auth-help-actions a,
  .support-cta-grid a,
  .support-cta {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    min-height: 48px !important;
    padding: 8px 8px !important;
    border-radius: 17px !important;
    font-size: 13.5px !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: clip !important;
    justify-content: center !important;
    box-sizing: border-box !important;
  }

  .forgot-actions img,
  .auth-support-actions img,
  .auth-help-actions img,
  .support-cta-grid img,
  .support-cta img {
    width: 23px !important;
    height: 23px !important;
    min-width: 23px !important;
  }
}

@media (max-width: 390px) {
  .auth-page {
    padding-left: 7px !important;
    padding-right: 7px !important;
  }

  .auth-card {
    max-width: calc(100vw - 14px) !important;
    padding: 12px !important;
  }

  .auth-hero {
    padding: 16px 13px !important;
  }

  .auth-form-wrap {
    padding: 18px 13px !important;
  }

  .auth-point {
    font-size: 12.5px !important;
    gap: 8px !important;
    padding: 9px 10px !important;
  }

  .forgot-actions,
  .auth-support-actions,
  .auth-help-actions,
  .support-cta-grid {
    grid-template-columns: 1fr !important;
  }

  .forgot-actions a,
  .auth-support-actions a,
  .auth-help-actions a,
  .support-cta-grid a,
  .support-cta {
    min-height: 46px !important;
    font-size: 14px !important;
  }
}

/* Step 42 Topbar Notification + Profile Dropdown */
.top-actions{
  position: relative;
}

.bell.notification-btn,
.user-chip{
  cursor: pointer;
  user-select: none;
}

.topbar-dropdown{
  position: absolute;
  top: 52px;
  right: 0;
  width: 310px;
  background: linear-gradient(180deg, rgba(15,23,42,.98), rgba(2,6,23,.98));
  border: 1px solid rgba(34,211,238,.28);
  border-radius: 18px;
  box-shadow: 0 24px 70px rgba(0,0,0,.48), 0 0 28px rgba(34,211,238,.14);
  padding: 14px;
  z-index: 9999;
  display: none;
  backdrop-filter: blur(16px);
}

.topbar-dropdown.show{
  display: block;
  animation: softFade .18s ease;
}

.notification-dropdown{
  right: 62px;
}

.profile-dropdown{
  right: 0;
  width: 250px;
}

.dropdown-title{
  font-weight: 900;
  color: #fff;
  margin-bottom: 10px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(148,163,184,.18);
}

.dropdown-item-soft{
  display: grid;
  gap: 3px;
  padding: 11px 10px;
  border-radius: 13px;
  background: rgba(15,23,42,.68);
  border: 1px solid rgba(148,163,184,.12);
  margin-bottom: 8px;
}

.dropdown-item-soft b{
  color: #e5f6ff;
  font-size: 13px;
}

.dropdown-item-soft small{
  color: #9fb0c9;
  font-size: 12px;
}

.profile-dropdown button{
  width: 100%;
  border: 0;
  background: rgba(15,23,42,.72);
  color: #e5f6ff;
  border: 1px solid rgba(148,163,184,.14);
  border-radius: 13px;
  padding: 11px 12px;
  margin-bottom: 8px;
  text-align: left;
  font-weight: 800;
  cursor: pointer;
}

.profile-dropdown button:hover,
.dropdown-item-soft:hover{
  border-color: rgba(34,211,238,.42);
  box-shadow: 0 0 18px rgba(34,211,238,.13);
  transform: translateY(-1px);
}

.profile-dropdown .logout-menu-btn{
  color: #fecaca;
  border-color: rgba(248,113,113,.28);
}

@media(max-width: 768px){
  .topbar-dropdown{
    position: fixed;
    top: 82px;
    left: 14px;
    right: 14px;
    width: auto;
  }
}

/* Step 42.2 professional profile icons + notification popup */
.profile-dropdown button{
  display:flex;
  align-items:center;
  gap:10px;
}

.menu-icon{
  width:30px;
  height:30px;
  border-radius:10px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  background:linear-gradient(135deg,rgba(34,211,238,.18),rgba(139,92,246,.18));
  border:1px solid rgba(34,211,238,.22);
  flex:0 0 auto;
}

.menu-icon svg{
  width:17px;
  height:17px;
  fill:#67e8f9;
  filter:drop-shadow(0 0 8px rgba(34,211,238,.28));
}

.logout-menu-btn .menu-icon{
  background:linear-gradient(135deg,rgba(248,113,113,.16),rgba(251,146,60,.14));
  border-color:rgba(248,113,113,.25);
}

.logout-menu-btn .menu-icon svg{
  fill:#fca5a5;
}

.notification-item{
  width:100%;
  text-align:left;
  cursor:pointer;
  border:none;
}

.notification-modal-backdrop{
  position:fixed;
  inset:0;
  background:rgba(0,0,0,.62);
  backdrop-filter:blur(10px);
  display:none;
  align-items:center;
  justify-content:center;
  z-index:20000;
  padding:18px;
}

.notification-modal-backdrop.show{
  display:flex;
}

.notification-modal-card{
  width:min(520px,100%);
  background:linear-gradient(180deg,rgba(15,23,42,.98),rgba(2,6,23,.98));
  border:1px solid rgba(34,211,238,.30);
  border-radius:24px;
  padding:26px;
  box-shadow:0 30px 90px rgba(0,0,0,.55),0 0 40px rgba(34,211,238,.15);
  position:relative;
}

.notification-modal-close{
  position:absolute;
  top:12px;
  right:14px;
  width:34px;
  height:34px;
  border-radius:50%;
  border:1px solid rgba(148,163,184,.20);
  background:rgba(15,23,42,.80);
  color:#fff;
  font-size:24px;
  line-height:1;
  cursor:pointer;
}

.notification-modal-icon{
  width:50px;
  height:50px;
  border-radius:16px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:linear-gradient(135deg,rgba(34,211,238,.20),rgba(139,92,246,.20));
  margin-bottom:14px;
}

.notification-modal-card h3{
  margin:0 0 10px;
  font-size:22px;
  font-weight:900;
  color:#fff;
}

.notification-modal-card p{
  margin:0;
  color:#bfd0e8;
  line-height:1.7;
}

/* Step 42.3.2 real notifications + admin broadcast */
.notification-mark-read-btn{
  width:100%;
  border:1px solid rgba(34,211,238,.22);
  background:rgba(34,211,238,.10);
  color:#dffafe;
  border-radius:13px;
  padding:10px 12px;
  font-weight:900;
  cursor:pointer;
  margin-top:6px;
}

.notification-mark-read-btn:hover{
  border-color:rgba(34,211,238,.45);
  box-shadow:0 0 20px rgba(34,211,238,.12);
}

.notification-item.unread{
  border-color:rgba(37,211,102,.38);
  background:linear-gradient(135deg,rgba(37,211,102,.12),rgba(15,23,42,.84));
}

.notification-time{
  display:block;
  margin-top:4px;
  color:#64748b;
  font-size:11px;
  font-weight:700;
}

.admin-broadcast-textarea{
  width:100%;
  min-height:130px;
  resize:vertical;
  border-radius:16px;
  border:1px solid rgba(148,163,184,.18);
  background:rgba(15,23,42,.74);
  color:#e5f6ff;
  padding:13px 14px;
  outline:none;
}

.admin-broadcast-textarea:focus{
  border-color:rgba(34,211,238,.42);
  box-shadow:0 0 0 3px rgba(34,211,238,.10);
}

/* Step 42.3.3 Admin broadcast button polish */
#adminBroadcastPanel .plan-admin-grid{
  grid-template-columns: minmax(320px, 1fr) 220px;
  align-items: end;
}

#adminBroadcastPanel .primary-btn{
  width: 100%;
  min-width: 210px;
  padding-left: 22px;
  padding-right: 22px;
  white-space: nowrap;
}

@media(max-width: 768px){
  #adminBroadcastPanel .plan-admin-grid{
    grid-template-columns: 1fr;
  }

  #adminBroadcastPanel .primary-btn{
    width: 100%;
    min-width: 100%;
  }
}

/* Step 43.3 Testnet/Live-ready mode polish */
#cfgMode option[value="testnet"]{
  color:#22c55e;
}

#cfgMode option[value="live"]{
  color:#f59e0b;
}

.bot-config-note{
  border-left:3px solid rgba(34,211,238,.45);
}

/* Step 43.4 Binance Testnet API card */
.testnet-api-card{
  border-color:rgba(34,197,94,.28) !important;
  box-shadow:0 0 28px rgba(34,197,94,.08);
}

.testnet-warning{
  border-color:rgba(34,197,94,.30);
  background:linear-gradient(135deg,rgba(34,197,94,.12),rgba(15,23,42,.82));
}

/* Step 43.7.2 Exchange balance cards */
.exchange-balance-box{
  border-color:rgba(34,211,238,.22);
}

.balance-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  margin-bottom:12px;
}

.balance-grid{
  display:grid;
  grid-template-columns:repeat(5,minmax(0,1fr));
  gap:10px;
}

.balance-asset-card{
  background:rgba(15,23,42,.78);
  border:1px solid rgba(148,163,184,.16);
  border-radius:14px;
  padding:12px;
}

.balance-asset{
  font-size:12px;
  color:#94a3b8;
  font-weight:900;
}

.balance-total{
  color:#e5f6ff;
  font-size:18px;
  font-weight:900;
  margin-top:3px;
}

.balance-asset-card small{
  display:block;
  color:#9fb0c9;
  font-size:11px;
  margin-top:4px;
}

@media(max-width:900px){
  .balance-grid{
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
}

/* Step 43.8.2 Enhanced Signal Center */
.signal-balance-panel{
  margin-bottom:14px;
  padding:16px;
  border:1px solid rgba(34,211,238,.22);
  background:linear-gradient(135deg,rgba(15,23,42,.92),rgba(3,7,18,.94));
  border-radius:22px;
  box-shadow:0 18px 50px rgba(0,0,0,.26);
}

.signal-balance-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  margin-bottom:12px;
}

.signal-balance-head b{
  display:block;
  color:#e5f6ff;
  font-size:17px;
}

.signal-balance-head small{
  display:block;
  color:#9fb0c9;
  margin-top:3px;
}

.signal-balance-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:12px;
}

.signal-balance-card{
  background:rgba(15,23,42,.78);
  border:1px solid rgba(34,211,238,.18);
  border-radius:16px;
  padding:14px;
}

.signal-balance-card b{
  display:block;
  color:#94a3b8;
  font-size:12px;
}

.signal-balance-card span{
  display:block;
  color:#22c55e;
  font-size:24px;
  font-weight:900;
  margin-top:5px;
}

.signal-balance-card small{
  display:block;
  color:#9fb0c9;
  margin-top:5px;
}

.signal-balance-card.danger-card span{
  color:#f87171;
}

.signal-balance-card.muted-card span{
  color:#fbbf24;
}

.mini-refresh{
  padding:9px 13px !important;
  min-height:auto !important;
}

.enhanced-signal-item{
  border-color:rgba(34,211,238,.20);
}

.enhanced-stats-row{
  grid-template-columns:repeat(4,minmax(0,1fr));
}

.signal-trade-note{
  margin-top:8px;
  padding:10px 12px;
  background:rgba(2,6,23,.45);
  border:1px solid rgba(148,163,184,.12);
  border-radius:12px;
  color:#cbd5e1;
  font-size:12px;
}

@media(max-width:900px){
  .signal-balance-grid,
  .enhanced-stats-row{
    grid-template-columns:1fr 1fr;
  }
}

@media(max-width:560px){
  .signal-balance-grid,
  .enhanced-stats-row{
    grid-template-columns:1fr;
  }
}

/* Step 43.8.3 Binance-style compact Signal Center */
.stt-signal-compact-wrap{
  border:1px solid rgba(34,211,238,.18);
  border-radius:18px;
  overflow:hidden;
  background:rgba(2,6,23,.28);
}

.stt-signal-toolbar{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:12px 14px;
  border-bottom:1px solid rgba(148,163,184,.13);
  background:linear-gradient(135deg,rgba(15,23,42,.92),rgba(8,13,26,.94));
}

.stt-signal-toolbar b{
  display:block;
  color:#e5f6ff;
  font-size:15px;
}

.stt-signal-toolbar small{
  display:block;
  color:#94a3b8;
  margin-top:2px;
  font-size:12px;
}

.stt-signal-table-scroll{
  overflow:auto;
  max-height:520px;
}

.stt-signal-table{
  width:100%;
  border-collapse:separate;
  border-spacing:0;
  min-width:1180px;
  font-size:12px;
}

.stt-signal-table thead th{
  position:sticky;
  top:0;
  z-index:2;
  background:#081225;
  color:#8ea4c8;
  font-weight:900;
  text-transform:uppercase;
  letter-spacing:.04em;
  padding:10px 10px;
  border-bottom:1px solid rgba(148,163,184,.16);
  white-space:nowrap;
}

.stt-signal-table tbody td{
  padding:9px 10px;
  border-bottom:1px solid rgba(148,163,184,.10);
  color:#dbeafe;
  vertical-align:middle;
  white-space:nowrap;
}

.stt-signal-table tbody tr:hover{
  background:rgba(34,211,238,.055);
}

.stt-signal-table .num{
  text-align:right;
  font-variant-numeric:tabular-nums;
  font-weight:800;
}

.stt-pair-cell{
  display:flex;
  align-items:center;
  gap:9px;
  min-width:150px;
}

.stt-pair-cell b{
  display:block;
  color:#fff;
  font-size:13px;
}

.stt-pair-cell small{
  display:block;
  color:#8092b4;
  font-size:11px;
  margin-top:1px;
}

.stt-coin-dot{
  width:28px;
  height:28px;
  border-radius:50%;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  background:linear-gradient(135deg,#f59e0b,#f97316);
  color:#fff;
  font-weight:900;
  box-shadow:0 0 16px rgba(245,158,11,.20);
}

.stt-side-pill,
.stt-mode-pill,
.stt-status-pill{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:62px;
  padding:5px 8px;
  border-radius:999px;
  font-weight:900;
  font-size:11px;
  text-transform:uppercase;
}

.stt-side-buy{
  color:#22c55e;
  background:rgba(34,197,94,.12);
  border:1px solid rgba(34,197,94,.24);
}

.stt-side-sell{
  color:#fb7185;
  background:rgba(244,63,94,.12);
  border:1px solid rgba(244,63,94,.24);
}

.stt-side-neutral{
  color:#60a5fa;
  background:rgba(59,130,246,.12);
  border:1px solid rgba(59,130,246,.24);
}

.stt-mode-testnet{
  color:#22d3ee;
  background:rgba(34,211,238,.12);
  border:1px solid rgba(34,211,238,.24);
}

.stt-mode-paper{
  color:#a78bfa;
  background:rgba(139,92,246,.12);
  border:1px solid rgba(139,92,246,.24);
}

.stt-mode-live{
  color:#f59e0b;
  background:rgba(245,158,11,.12);
  border:1px solid rgba(245,158,11,.24);
}

.stt-status-open{
  color:#22c55e;
  background:rgba(34,197,94,.12);
  border:1px solid rgba(34,197,94,.24);
}

.stt-status-closed{
  color:#38bdf8;
  background:rgba(56,189,248,.12);
  border:1px solid rgba(56,189,248,.24);
}

.stt-status-failed{
  color:#f87171;
  background:rgba(248,113,113,.12);
  border:1px solid rgba(248,113,113,.24);
}

.stt-status-neutral{
  color:#fbbf24;
  background:rgba(251,191,36,.12);
  border:1px solid rgba(251,191,36,.24);
}

.stt-note-cell{
  max-width:260px;
  overflow:hidden;
  text-overflow:ellipsis;
  color:#aab7d0 !important;
}

@media(max-width:768px){
  .stt-signal-toolbar{
    align-items:flex-start;
    flex-direction:column;
  }

  .stt-signal-table-scroll{
    max-height:520px;
  }
}

/* Step 43.9 premium real coin logo polish */
.coin-logo,
.signal-logo,
.trade-logo,
.bot-coin-logo{
  object-fit:contain !important;
  background:rgba(255,255,255,.96);
  border-radius:50%;
  padding:2px;
}

.coin-avatar,
.signal-logo-wrap,
.trade-logo-wrap,
.bot-logo-wrap{
  background:linear-gradient(135deg,rgba(34,211,238,.14),rgba(139,92,246,.16)) !important;
  border:1px solid rgba(34,211,238,.22);
  box-shadow:0 0 18px rgba(34,211,238,.10);
}

.signal-logo-fallback,
.trade-logo-fallback,
.bot-logo-fallback{
  background:linear-gradient(135deg,#0ea5e9,#7c3aed) !important;
  color:#fff !important;
  font-weight:900;
}

/* Step 43.9.1 Signal Center compact table real logos */
.stt-coin-logo-wrap{
  width:28px;
  height:28px;
  border-radius:50%;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  background:linear-gradient(135deg,rgba(34,211,238,.15),rgba(139,92,246,.18));
  border:1px solid rgba(34,211,238,.22);
  box-shadow:0 0 16px rgba(34,211,238,.10);
  overflow:hidden;
  flex:0 0 auto;
}

.stt-compact-coin-logo{
  width:24px;
  height:24px;
  object-fit:contain;
  border-radius:50%;
  display:block;
  background:rgba(255,255,255,.96);
  padding:2px;
}

.stt-compact-logo-fallback{
  width:100%;
  height:100%;
  display:none;
  align-items:center;
  justify-content:center;
  font-size:10px;
  font-weight:900;
  color:#fff;
  background:linear-gradient(135deg,#f59e0b,#7c3aed);
  border-radius:50%;
}

/* Step 43.10 Trade pagination + manual close */
.stt-close-trade-btn{
  border:1px solid rgba(248,113,113,.35);
  background:linear-gradient(135deg,rgba(239,68,68,.95),rgba(249,115,22,.95));
  color:#fff;
  border-radius:10px;
  padding:7px 11px;
  font-weight:900;
  cursor:pointer;
  min-width:64px;
  box-shadow:0 10px 24px rgba(239,68,68,.18);
}

.stt-close-trade-btn:hover{
  transform:translateY(-1px);
  box-shadow:0 14px 30px rgba(239,68,68,.28);
}

.stt-manage-muted{
  color:#64748b;
  font-weight:800;
}

.compact-trade-journal-wrap{
  overflow:auto;
  max-height:620px;
}

.stt-trade-history-table{
  width:100%;
  min-width:1050px;
  border-collapse:separate;
  border-spacing:0;
  font-size:12px;
}

.stt-trade-history-table th{
  position:sticky;
  top:0;
  z-index:2;
  background:#081225;
  color:#8ea4c8;
  text-transform:uppercase;
  letter-spacing:.04em;
  padding:10px;
  border-bottom:1px solid rgba(148,163,184,.16);
}

.stt-trade-history-table td{
  padding:9px 10px;
  color:#dbeafe;
  border-bottom:1px solid rgba(148,163,184,.10);
  white-space:nowrap;
}

.stt-trade-history-table tr:hover{
  background:rgba(34,211,238,.055);
}

.stt-trade-history-table .num{
  text-align:right;
  font-variant-numeric:tabular-nums;
  font-weight:800;
}

.trade-mode-pill,
.trade-status-pill{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:64px;
  border-radius:999px;
  padding:5px 8px;
  font-weight:900;
  text-transform:uppercase;
  font-size:11px;
  background:rgba(139,92,246,.14);
  color:#c4b5fd;
  border:1px solid rgba(139,92,246,.24);
}

.trade-status-pill.open{
  color:#22c55e;
  background:rgba(34,197,94,.12);
  border-color:rgba(34,197,94,.24);
}

.trade-status-pill.closed{
  color:#38bdf8;
  background:rgba(56,189,248,.12);
  border-color:rgba(56,189,248,.24);
}

.trade-status-pill.failed{
  color:#f87171;
  background:rgba(248,113,113,.12);
  border-color:rgba(248,113,113,.24);
}

.trade-pagination{
  display:flex;
  align-items:center;
  justify-content:center;
  flex-wrap:wrap;
  gap:8px;
  margin-top:14px;
}

.trade-page-btn{
  border:1px solid rgba(34,211,238,.20);
  background:rgba(15,23,42,.78);
  color:#dffafe;
  border-radius:10px;
  padding:8px 12px;
  font-weight:900;
  cursor:pointer;
}

.trade-page-btn.active{
  background:linear-gradient(135deg,#22d3ee,#7c3aed);
  color:#fff;
}

.trade-page-btn:disabled{
  opacity:.45;
  cursor:not-allowed;
}

.trade-page-ellipsis{
  color:#64748b;
  font-weight:900;
  padding:0 4px;
}

/* Step 43.10.2 Signal/Journal table polish */
.stt-trade-history-table th:nth-child(9),
.stt-trade-history-table td:nth-child(9){
  text-align:center !important;
}

.stt-signal-table th:nth-child(10),
.stt-signal-table td:nth-child(10){
  text-align:center !important;
}

.stt-signal-table th:last-child,
.stt-signal-table td:last-child{
  text-align:center !important;
}

.stt-signal-table{
  min-width:1080px;
}

.stt-note-cell{
  text-align:center !important;
}

/* Step 43.11 Signal Center header action buttons */
.signal-head-actions{
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:10px;
  flex-wrap:wrap;
}

@media(max-width:768px){
  #page-signals .page-head{
    align-items:flex-start;
  }

  .signal-head-actions{
    width:100%;
    justify-content:flex-start;
    margin-top:10px;
  }

  .signal-head-actions .view-btn{
    flex:1;
    min-width:140px;
  }
}

/* Step 43.11.1 Premium Signal Center Action Buttons */
#page-signals .view-btn,
#page-signals .mini-refresh,
.signal-head-actions .view-btn,
.signal-balance-head .view-btn,
.stt-signal-toolbar .view-btn{
  position:relative;
  overflow:hidden;
  border:1px solid rgba(34,211,238,.32) !important;
  background:
    radial-gradient(circle at 20% 20%, rgba(255,255,255,.10), transparent 28%),
    linear-gradient(135deg, rgba(8,145,178,.82), rgba(88,28,135,.82)) !important;
  color:#f8fbff !important;
  box-shadow:
    0 12px 30px rgba(0,0,0,.22),
    0 0 18px rgba(34,211,238,.10),
    inset 0 1px 0 rgba(255,255,255,.08);
  font-weight:900 !important;
  letter-spacing:.01em;
  transition:transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}

#page-signals .view-btn::before,
#page-signals .mini-refresh::before,
.signal-head-actions .view-btn::before,
.signal-balance-head .view-btn::before,
.stt-signal-toolbar .view-btn::before{
  content:"";
  position:absolute;
  inset:0;
  background:linear-gradient(90deg, transparent, rgba(255,255,255,.16), transparent);
  transform:translateX(-120%);
  transition:transform .55s ease;
  pointer-events:none;
}

#page-signals .view-btn:hover,
#page-signals .mini-refresh:hover,
.signal-head-actions .view-btn:hover,
.signal-balance-head .view-btn:hover,
.stt-signal-toolbar .view-btn:hover{
  transform:translateY(-2px);
  border-color:rgba(34,211,238,.50) !important;
  box-shadow:
    0 16px 38px rgba(0,0,0,.30),
    0 0 24px rgba(34,211,238,.16),
    0 0 18px rgba(139,92,246,.12);
}

#page-signals .view-btn:hover::before,
#page-signals .mini-refresh:hover::before,
.signal-head-actions .view-btn:hover::before,
.signal-balance-head .view-btn:hover::before,
.stt-signal-toolbar .view-btn:hover::before{
  transform:translateX(120%);
}

/* Slightly different premium accent for Trade History */
.signal-head-actions .view-btn:first-child{
  background:
    radial-gradient(circle at 20% 20%, rgba(255,255,255,.10), transparent 28%),
    linear-gradient(135deg, rgba(15,118,110,.86), rgba(67,56,202,.82)) !important;
}

/* Mobile touch polish */
@media(max-width:768px){
  .signal-head-actions{
    gap:12px;
  }

  .signal-head-actions .view-btn,
  .signal-balance-head .view-btn,
  .stt-signal-toolbar .view-btn{
    min-height:52px !important;
    border-radius:16px !important;
    font-size:14px !important;
  }

  .signal-balance-head{
    gap:14px;
  }

  .signal-balance-head .view-btn{
    min-width:126px;
    line-height:1.15;
  }

  .stt-signal-toolbar .view-btn{
    min-width:112px;
  }
}

@media(max-width:430px){
  .signal-head-actions .view-btn{
    flex:1 1 calc(50% - 6px);
    padding-left:10px !important;
    padding-right:10px !important;
  }

  .signal-balance-head .view-btn{
    padding-left:12px !important;
    padding-right:12px !important;
  }
}

/* Step 43.11.2 Signal buttons clean glow animation */
#page-signals .view-btn::before,
#page-signals .mini-refresh::before,
.signal-head-actions .view-btn::before,
.signal-balance-head .view-btn::before,
.stt-signal-toolbar .view-btn::before{
  display:none !important;
  content:none !important;
}

#page-signals .view-btn,
#page-signals .mini-refresh,
.signal-head-actions .view-btn,
.signal-balance-head .view-btn,
.stt-signal-toolbar .view-btn{
  border-radius:18px !important;
  isolation:isolate;
  -webkit-tap-highlight-color:transparent;
}

#page-signals .view-btn::after,
#page-signals .mini-refresh::after,
.signal-head-actions .view-btn::after,
.signal-balance-head .view-btn::after,
.stt-signal-toolbar .view-btn::after{
  content:"";
  position:absolute;
  inset:-2px;
  border-radius:inherit;
  background:radial-gradient(circle at 50% 50%, rgba(34,211,238,.22), transparent 62%);
  opacity:0;
  z-index:-1;
  transform:scale(.96);
  transition:opacity .22s ease, transform .22s ease;
  pointer-events:none;
}

#page-signals .view-btn:hover::after,
#page-signals .mini-refresh:hover::after,
.signal-head-actions .view-btn:hover::after,
.signal-balance-head .view-btn:hover::after,
.stt-signal-toolbar .view-btn:hover::after{
  opacity:1;
  transform:scale(1.04);
}

#page-signals .view-btn:active,
#page-signals .mini-refresh:active,
.signal-head-actions .view-btn:active,
.signal-balance-head .view-btn:active,
.stt-signal-toolbar .view-btn:active{
  transform:scale(.985) !important;
  box-shadow:
    0 8px 22px rgba(0,0,0,.24),
    0 0 26px rgba(34,211,238,.20),
    0 0 18px rgba(139,92,246,.16) !important;
}

#page-signals .view-btn:active::after,
#page-signals .mini-refresh:active::after,
.signal-head-actions .view-btn:active::after,
.signal-balance-head .view-btn:active::after,
.stt-signal-toolbar .view-btn:active::after{
  opacity:1;
  transform:scale(1.08);
}

/* Keep live monitor refresh button compact and clearly clickable */
.stt-signal-toolbar .view-btn{
  min-width:118px;
  cursor:pointer;
}

/* Step 43.12 Market Watch silent refresh + pagination */
.market-rank-card{
  background:rgba(2,6,23,.26);
  border:1px solid rgba(148,163,184,.12);
  border-radius:18px;
  overflow:hidden;
}

.market-rank-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:14px 16px;
  border-bottom:1px solid rgba(148,163,184,.12);
}

.market-rank-head h3{
  margin:0;
  color:#fff;
  font-size:18px;
  font-weight:900;
}

.market-rank-head small{
  display:block;
  color:#8ea4c8;
  margin-top:3px;
}

.market-usdt-pill{
  border:1px solid rgba(148,163,184,.18);
  background:rgba(15,23,42,.85);
  color:#dbeafe;
  border-radius:999px;
  padding:7px 10px;
  font-weight:900;
  font-size:12px;
}

.market-table-scroll{
  overflow:auto;
}

.stt-market-table{
  width:100%;
  border-collapse:separate;
  border-spacing:0;
  min-width:720px;
  font-size:13px;
}

.stt-market-table th{
  background:#081225;
  color:#8ea4c8;
  text-transform:uppercase;
  letter-spacing:.04em;
  font-size:11px;
  padding:10px 14px;
  border-bottom:1px solid rgba(148,163,184,.12);
}

.stt-market-table td{
  padding:12px 14px;
  border-bottom:1px solid rgba(148,163,184,.08);
  color:#dbeafe;
  vertical-align:middle;
}

.stt-market-table tr:hover{
  background:rgba(34,211,238,.045);
}

.stt-market-table .num{
  text-align:right;
  font-weight:900;
  font-variant-numeric:tabular-nums;
}

.market-rank{
  color:#8092b4 !important;
  font-weight:900;
  width:54px;
}

.market-name-cell{
  display:flex;
  align-items:center;
  gap:12px;
}

.market-name-cell b{
  display:block;
  color:#fff;
  font-weight:900;
}

.market-name-cell small{
  display:block;
  color:#70809e;
  margin-top:1px;
}

.market-coin-logo-wrap{
  width:32px;
  height:32px;
  border-radius:50%;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  background:linear-gradient(135deg,rgba(34,211,238,.15),rgba(139,92,246,.16));
  border:1px solid rgba(34,211,238,.22);
  overflow:hidden;
  flex:0 0 auto;
}

.market-coin-logo-wrap .coin-logo{
  width:28px;
  height:28px;
}

.market-logo-fallback{
  width:100%;
  height:100%;
  display:none;
  align-items:center;
  justify-content:center;
  font-size:10px;
  font-weight:900;
  color:#fff;
  background:linear-gradient(135deg,#f59e0b,#7c3aed);
  border-radius:50%;
}

.market-pagination{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  padding:14px;
  border-top:1px solid rgba(148,163,184,.10);
  flex-wrap:wrap;
}

.market-page-btn{
  border:1px solid rgba(34,211,238,.22);
  background:rgba(15,23,42,.82);
  color:#dffafe;
  border-radius:10px;
  padding:8px 12px;
  font-weight:900;
  cursor:pointer;
}

.market-page-btn.active{
  background:linear-gradient(135deg,#22d3ee,#7c3aed);
  color:#fff;
  box-shadow:0 0 18px rgba(34,211,238,.16);
}

.market-page-btn:disabled{
  opacity:.45;
  cursor:not-allowed;
}

@media(max-width:768px){
  .stt-market-table{
    min-width:620px;
  }

  .market-rank-head{
    align-items:flex-start;
    flex-direction:column;
  }
}

/* Step 43.12.1 Market Watch mobile table fit */
.market-pagination-simple{
  gap:10px;
}

.market-empty-row{
  text-align:center !important;
  color:#94a3b8 !important;
  padding:22px !important;
}

@media(max-width:768px){
  .market-table-scroll{
    overflow-x:hidden !important;
  }

  .stt-market-table{
    min-width:0 !important;
    width:100% !important;
    table-layout:fixed;
    font-size:12px;
  }

  .stt-market-table th,
  .stt-market-table td{
    padding:10px 7px !important;
  }

  .stt-market-table th:nth-child(1),
  .stt-market-table td:nth-child(1){
    width:34px;
    text-align:center;
  }

  .stt-market-table th:nth-child(2),
  .stt-market-table td:nth-child(2){
    width:auto;
  }

  .stt-market-table th:nth-child(3),
  .stt-market-table td:nth-child(3){
    width:86px;
    text-align:right;
  }

  .stt-market-table th:nth-child(4),
  .stt-market-table td:nth-child(4){
    width:70px;
    text-align:right;
  }

  .market-name-cell{
    gap:8px;
    min-width:0;
  }

  .market-name-cell > div{
    min-width:0;
  }

  .market-name-cell b,
  .market-name-cell small{
    overflow:hidden;
    text-overflow:ellipsis;
    white-space:nowrap;
    max-width:92px;
  }

  .market-coin-logo-wrap{
    width:28px;
    height:28px;
  }

  .market-coin-logo-wrap .coin-logo{
    width:24px;
    height:24px;
  }

  .market-price-cell{
    font-size:11px;
  }

  .market-change-cell{
    font-size:11px;
  }

  .market-pagination{
    padding:12px 8px 10px !important;
  }

  .market-page-btn{
    min-width:42px;
    height:42px;
    padding:0 !important;
    display:inline-flex;
    align-items:center;
    justify-content:center;
  }
}

@media(max-width:390px){
  .stt-market-table th:nth-child(3),
  .stt-market-table td:nth-child(3){
    width:78px;
  }

  .stt-market-table th:nth-child(4),
  .stt-market-table td:nth-child(4){
    width:64px;
  }

  .market-name-cell b,
  .market-name-cell small{
    max-width:76px;
  }
}

/* Step 43.12.3 Market Watch table alignment + premium button glow */

/* Table column alignment */
.stt-market-table{
  table-layout:fixed !important;
}

.stt-market-table th:nth-child(1),
.stt-market-table td:nth-child(1){
  width:56px !important;
  text-align:center !important;
}

.stt-market-table th:nth-child(2),
.stt-market-table td:nth-child(2){
  text-align:left !important;
}

.stt-market-table th:nth-child(3),
.stt-market-table td:nth-child(3){
  width:150px !important;
  text-align:right !important;
}

.stt-market-table th:nth-child(4),
.stt-market-table td:nth-child(4){
  width:120px !important;
  text-align:right !important;
}

.stt-market-table thead th{
  vertical-align:middle !important;
}

.market-name-cell{
  justify-content:flex-start !important;
}

/* Remove square shine animation from Market Watch buttons */
#page-market .view-btn::before,
.market-tab::before,
.market-page-btn::before{
  display:none !important;
  content:none !important;
}

#page-market .view-btn,
.market-tab,
.market-page-btn{
  position:relative;
  overflow:visible !important;
  isolation:isolate;
  -webkit-tap-highlight-color:transparent;
  transition:
    transform .20s ease,
    box-shadow .20s ease,
    border-color .20s ease,
    background .20s ease !important;
}

/* Soft glow animation instead of square animation */
#page-market .view-btn::after,
.market-tab::after,
.market-page-btn::after{
  content:"";
  position:absolute;
  inset:-2px;
  border-radius:inherit;
  background:radial-gradient(circle at 50% 50%, rgba(34,211,238,.22), transparent 64%);
  opacity:0;
  transform:scale(.96);
  transition:opacity .22s ease, transform .22s ease;
  pointer-events:none;
  z-index:-1;
}

#page-market .view-btn:hover::after,
.market-tab:hover::after,
.market-page-btn:hover::after,
#page-market .view-btn:active::after,
.market-tab:active::after,
.market-page-btn:active::after{
  opacity:1;
  transform:scale(1.05);
}

#page-market .view-btn:hover,
.market-tab:hover,
.market-page-btn:hover{
  transform:translateY(-1px);
  border-color:rgba(34,211,238,.42) !important;
  box-shadow:
    0 12px 28px rgba(0,0,0,.25),
    0 0 20px rgba(34,211,238,.13),
    0 0 14px rgba(139,92,246,.10) !important;
}

#page-market .view-btn:active,
.market-tab:active,
.market-page-btn:active{
  transform:scale(.985) !important;
  box-shadow:
    0 8px 20px rgba(0,0,0,.24),
    0 0 24px rgba(34,211,238,.18),
    0 0 16px rgba(139,92,246,.14) !important;
}

/* Premium active tab look */
.market-tab.active{
  background:
    radial-gradient(circle at 20% 20%, rgba(255,255,255,.10), transparent 28%),
    linear-gradient(135deg, rgba(15,118,110,.88), rgba(67,56,202,.84)) !important;
  color:#fff !important;
  border-color:rgba(34,211,238,.38) !important;
  box-shadow:
    0 12px 26px rgba(0,0,0,.22),
    0 0 18px rgba(34,211,238,.13) !important;
}

/* Mobile alignment */
@media(max-width:768px){
  .stt-market-table{
    table-layout:fixed !important;
    width:100% !important;
    min-width:0 !important;
  }

  .stt-market-table th:nth-child(1),
  .stt-market-table td:nth-child(1){
    width:36px !important;
    text-align:center !important;
  }

  .stt-market-table th:nth-child(2),
  .stt-market-table td:nth-child(2){
    width:auto !important;
    text-align:left !important;
  }

  .stt-market-table th:nth-child(3),
  .stt-market-table td:nth-child(3){
    width:88px !important;
    text-align:right !important;
  }

  .stt-market-table th:nth-child(4),
  .stt-market-table td:nth-child(4){
    width:68px !important;
    text-align:right !important;
  }

  .stt-market-table th{
    font-size:10px !important;
    padding:10px 6px !important;
  }

  .stt-market-table td{
    padding:11px 6px !important;
  }

  .market-name-cell{
    gap:8px !important;
  }

  .market-name-cell b{
    font-size:13px !important;
  }

  .market-name-cell small{
    font-size:10px !important;
  }

  .market-price-cell,
  .market-change-cell{
    font-size:11px !important;
  }

  .market-tab{
    overflow:visible !important;
  }
}

@media(max-width:390px){
  .stt-market-table th:nth-child(3),
  .stt-market-table td:nth-child(3){
    width:80px !important;
  }

  .stt-market-table th:nth-child(4),
  .stt-market-table td:nth-child(4){
    width:62px !important;
  }

  .market-name-cell b,
  .market-name-cell small{
    max-width:78px !important;
  }
}

/* Step 43.12.4 Global premium refresh/action button polish */
.view-btn,
.primary-btn.admin-refresh-wide,
button[onclick*="Refresh"],
button[onclick*="loadBinanceStatus"],
button[onclick*="loadAlgos"],
button[onclick*="loadTrades"],
button[onclick*="loadStrategyStatus"],
button[onclick*="loadMarketWatch"],
button[onclick*="loadAdmin"],
button[onclick*="loadAdminOpsStatus"],
button[onclick*="loadAdminRuntimeBots"],
button[onclick*="loadAdminUsers"],
button[onclick*="loadAdminUpgradeRequests"]{
  position:relative;
  overflow:visible !important;
  isolation:isolate;
  border:1px solid rgba(34,211,238,.34) !important;
  background:
    radial-gradient(circle at 22% 20%, rgba(255,255,255,.10), transparent 30%),
    linear-gradient(135deg, rgba(8,145,178,.86), rgba(79,70,229,.80), rgba(88,28,135,.78)) !important;
  color:#f8fbff !important;
  box-shadow:
    0 12px 30px rgba(0,0,0,.24),
    0 0 18px rgba(34,211,238,.11),
    inset 0 1px 0 rgba(255,255,255,.08) !important;
  font-weight:900 !important;
  letter-spacing:.01em;
  -webkit-tap-highlight-color:transparent;
  transition:
    transform .20s ease,
    box-shadow .20s ease,
    border-color .20s ease,
    background .20s ease !important;
}

/* Disable old square shine animation on all refresh/action buttons */
.view-btn::before,
.primary-btn.admin-refresh-wide::before,
button[onclick*="Refresh"]::before,
button[onclick*="loadBinanceStatus"]::before,
button[onclick*="loadAlgos"]::before,
button[onclick*="loadTrades"]::before,
button[onclick*="loadStrategyStatus"]::before,
button[onclick*="loadMarketWatch"]::before,
button[onclick*="loadAdmin"]::before,
button[onclick*="loadAdminOpsStatus"]::before,
button[onclick*="loadAdminRuntimeBots"]::before,
button[onclick*="loadAdminUsers"]::before,
button[onclick*="loadAdminUpgradeRequests"]::before{
  display:none !important;
  content:none !important;
}

/* Soft glow effect */
.view-btn::after,
.primary-btn.admin-refresh-wide::after,
button[onclick*="Refresh"]::after,
button[onclick*="loadBinanceStatus"]::after,
button[onclick*="loadAlgos"]::after,
button[onclick*="loadTrades"]::after,
button[onclick*="loadStrategyStatus"]::after,
button[onclick*="loadMarketWatch"]::after,
button[onclick*="loadAdmin"]::after,
button[onclick*="loadAdminOpsStatus"]::after,
button[onclick*="loadAdminRuntimeBots"]::after,
button[onclick*="loadAdminUsers"]::after,
button[onclick*="loadAdminUpgradeRequests"]::after{
  content:"";
  position:absolute;
  inset:-2px;
  border-radius:inherit;
  background:
    radial-gradient(circle at 50% 50%, rgba(34,211,238,.22), transparent 62%),
    radial-gradient(circle at 50% 50%, rgba(139,92,246,.16), transparent 72%);
  opacity:0;
  transform:scale(.96);
  transition:opacity .22s ease, transform .22s ease;
  pointer-events:none;
  z-index:-1;
}

.view-btn:hover,
.primary-btn.admin-refresh-wide:hover,
button[onclick*="Refresh"]:hover,
button[onclick*="loadBinanceStatus"]:hover,
button[onclick*="loadAlgos"]:hover,
button[onclick*="loadTrades"]:hover,
button[onclick*="loadStrategyStatus"]:hover,
button[onclick*="loadMarketWatch"]:hover,
button[onclick*="loadAdmin"]:hover,
button[onclick*="loadAdminOpsStatus"]:hover,
button[onclick*="loadAdminRuntimeBots"]:hover,
button[onclick*="loadAdminUsers"]:hover,
button[onclick*="loadAdminUpgradeRequests"]:hover{
  transform:translateY(-2px);
  border-color:rgba(34,211,238,.54) !important;
  box-shadow:
    0 16px 38px rgba(0,0,0,.30),
    0 0 26px rgba(34,211,238,.16),
    0 0 18px rgba(139,92,246,.13),
    inset 0 1px 0 rgba(255,255,255,.10) !important;
}

.view-btn:hover::after,
.primary-btn.admin-refresh-wide:hover::after,
button[onclick*="Refresh"]:hover::after,
button[onclick*="loadBinanceStatus"]:hover::after,
button[onclick*="loadAlgos"]:hover::after,
button[onclick*="loadTrades"]:hover::after,
button[onclick*="loadStrategyStatus"]:hover::after,
button[onclick*="loadMarketWatch"]:hover::after,
button[onclick*="loadAdmin"]:hover::after,
button[onclick*="loadAdminOpsStatus"]:hover::after,
button[onclick*="loadAdminRuntimeBots"]:hover::after,
button[onclick*="loadAdminUsers"]:hover::after,
button[onclick*="loadAdminUpgradeRequests"]:hover::after{
  opacity:1;
  transform:scale(1.05);
}

.view-btn:active,
.primary-btn.admin-refresh-wide:active,
button[onclick*="Refresh"]:active,
button[onclick*="loadBinanceStatus"]:active,
button[onclick*="loadAlgos"]:active,
button[onclick*="loadTrades"]:active,
button[onclick*="loadStrategyStatus"]:active,
button[onclick*="loadMarketWatch"]:active,
button[onclick*="loadAdmin"]:active,
button[onclick*="loadAdminOpsStatus"]:active,
button[onclick*="loadAdminRuntimeBots"]:active,
button[onclick*="loadAdminUsers"]:active,
button[onclick*="loadAdminUpgradeRequests"]:active{
  transform:scale(.985) !important;
  box-shadow:
    0 8px 22px rgba(0,0,0,.24),
    0 0 28px rgba(34,211,238,.20),
    0 0 18px rgba(139,92,246,.16) !important;
}

.view-btn:active::after,
.primary-btn.admin-refresh-wide:active::after,
button[onclick*="Refresh"]:active::after,
button[onclick*="loadBinanceStatus"]:active::after,
button[onclick*="loadAlgos"]:active::after,
button[onclick*="loadTrades"]:active::after,
button[onclick*="loadStrategyStatus"]:active::after,
button[onclick*="loadMarketWatch"]:active::after,
button[onclick*="loadAdmin"]:active::after,
button[onclick*="loadAdminOpsStatus"]:active::after,
button[onclick*="loadAdminRuntimeBots"]:active::after,
button[onclick*="loadAdminUsers"]:active::after,
button[onclick*="loadAdminUpgradeRequests"]:active::after{
  opacity:1;
  transform:scale(1.08);
}

/* Keep top page refresh buttons balanced */
.page-head .view-btn{
  min-width:142px;
  min-height:46px;
  border-radius:15px !important;
}

/* Mobile premium sizing */
@media(max-width:768px){
  .page-head .view-btn,
  #page-market .view-btn,
  #page-bots .view-btn,
  #page-trades .view-btn,
  #page-exchange .view-btn,
  #page-signals .view-btn{
    min-height:52px !important;
    border-radius:17px !important;
    font-size:14px !important;
    padding-left:16px !important;
    padding-right:16px !important;
  }

  .page-head{
    gap:12px;
  }
}

@media(max-width:430px){
  .page-head .view-btn{
    width:auto;
    min-width:150px;
  }
}

/* Step 43.13 Global Search Suggestions */
.stt-search-wrap{
  position:relative;
  z-index:999;
}

.stt-search-dropdown{
  position:absolute;
  top:calc(100% + 10px);
  left:0;
  right:0;
  background:linear-gradient(180deg,rgba(15,23,42,.98),rgba(2,6,23,.98));
  border:1px solid rgba(34,211,238,.24);
  border-radius:18px;
  padding:8px;
  box-shadow:
    0 24px 70px rgba(0,0,0,.45),
    0 0 28px rgba(34,211,238,.12);
  display:none;
  backdrop-filter:blur(16px);
  max-height:370px;
  overflow:auto;
}

.stt-search-dropdown.show{
  display:block;
}

.stt-search-item{
  width:100%;
  border:1px solid transparent;
  background:transparent;
  color:#e5f6ff;
  border-radius:14px;
  padding:11px 12px;
  display:flex;
  align-items:center;
  gap:11px;
  text-align:left;
  cursor:pointer;
  transition:.18s ease;
}

.stt-search-item:hover,
.stt-search-item.active{
  background:linear-gradient(135deg,rgba(34,211,238,.12),rgba(139,92,246,.12));
  border-color:rgba(34,211,238,.28);
  box-shadow:0 0 18px rgba(34,211,238,.10);
}

.stt-search-icon{
  width:34px;
  height:34px;
  border-radius:12px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  background:linear-gradient(135deg,rgba(34,211,238,.18),rgba(139,92,246,.18));
  flex:0 0 auto;
}

.stt-search-item b{
  display:block;
  font-size:13px;
  color:#fff;
  font-weight:900;
}

.stt-search-item small{
  display:block;
  color:#9fb0c9;
  margin-top:2px;
  font-size:11px;
}

.stt-search-empty{
  padding:14px;
  color:#fbbf24;
  font-weight:800;
  font-size:13px;
}

@media(max-width:768px){
  .stt-search-dropdown{
    position:fixed;
    top:72px;
    left:14px;
    right:78px;
    max-height:390px;
    z-index:99999;
  }
}

/* Step 43.13.1 Professional search suggestion icons */
.stt-search-icon{
  background:
    radial-gradient(circle at 30% 25%, rgba(255,255,255,.16), transparent 32%),
    linear-gradient(135deg, rgba(34,211,238,.20), rgba(139,92,246,.22)) !important;
  border:1px solid rgba(34,211,238,.24);
  box-shadow:
    0 0 16px rgba(34,211,238,.10),
    inset 0 1px 0 rgba(255,255,255,.08);
}

.stt-search-icon svg{
  width:18px;
  height:18px;
  fill:#67e8f9;
  filter:drop-shadow(0 0 8px rgba(34,211,238,.28));
}

.stt-search-item:hover .stt-search-icon,
.stt-search-item.active .stt-search-icon{
  background:
    radial-gradient(circle at 30% 25%, rgba(255,255,255,.20), transparent 32%),
    linear-gradient(135deg, rgba(34,211,238,.30), rgba(139,92,246,.30)) !important;
  border-color:rgba(34,211,238,.42);
  box-shadow:
    0 0 22px rgba(34,211,238,.16),
    0 0 14px rgba(139,92,246,.12);
}

.stt-search-item:hover .stt-search-icon svg,
.stt-search-item.active .stt-search-icon svg{
  fill:#ffffff;
}

/* Step 43.14 Mobile drawer notifications + language selector */
.stt-lang-popup-backdrop{
  position:fixed;
  inset:0;
  background:rgba(0,0,0,.62);
  backdrop-filter:blur(12px);
  display:none;
  align-items:center;
  justify-content:center;
  z-index:30000;
  padding:18px;
}

.stt-lang-popup-backdrop.show{
  display:flex;
}

.stt-lang-popup-card{
  width:min(430px,100%);
  background:linear-gradient(180deg,rgba(15,23,42,.98),rgba(2,6,23,.98));
  border:1px solid rgba(34,211,238,.28);
  border-radius:26px;
  padding:24px;
  box-shadow:
    0 30px 90px rgba(0,0,0,.55),
    0 0 42px rgba(34,211,238,.14);
  position:relative;
}

.stt-lang-close{
  position:absolute;
  top:14px;
  right:14px;
  width:38px;
  height:38px;
  border-radius:14px;
  border:1px solid rgba(148,163,184,.18);
  background:rgba(15,23,42,.78);
  color:#fff;
  font-size:26px;
  line-height:1;
  cursor:pointer;
}

.stt-lang-icon{
  width:54px;
  height:54px;
  border-radius:18px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:linear-gradient(135deg,rgba(34,211,238,.18),rgba(139,92,246,.20));
  border:1px solid rgba(34,211,238,.24);
  margin-bottom:14px;
}

.stt-lang-icon svg{
  width:28px;
  height:28px;
  fill:#67e8f9;
}

.stt-lang-popup-card h3{
  margin:0 0 8px;
  color:#fff;
  font-size:22px;
  font-weight:900;
}

.stt-lang-popup-card p{
  color:#9fb0c9;
  margin:0 0 16px;
  line-height:1.55;
}

.stt-lang-options{
  display:grid;
  gap:10px;
}

.stt-lang-options button{
  width:100%;
  border:1px solid rgba(148,163,184,.14);
  background:rgba(15,23,42,.76);
  border-radius:16px;
  padding:14px 15px;
  color:#e5f6ff;
  text-align:left;
  cursor:pointer;
  transition:.22s ease;
}

.stt-lang-options button:hover{
  transform:translateY(-2px);
  border-color:rgba(34,211,238,.38);
  box-shadow:0 0 22px rgba(34,211,238,.12);
}

.stt-lang-options b{
  display:block;
  color:#fff;
  font-size:15px;
}

.stt-lang-options small{
  display:block;
  color:#9fb0c9;
  margin-top:3px;
}

/* Step 43.14.1 Mobile notification modal + 8 language selector */
.stt-mobile-notify-backdrop{
  position:fixed;
  inset:0;
  background:rgba(0,0,0,.62);
  backdrop-filter:blur(12px);
  display:none;
  align-items:flex-end;
  justify-content:center;
  z-index:31000;
  padding:14px;
}

.stt-mobile-notify-backdrop.show{
  display:flex;
}

.stt-mobile-notify-card{
  width:min(480px,100%);
  max-height:82vh;
  overflow:auto;
  background:linear-gradient(180deg,rgba(15,23,42,.98),rgba(2,6,23,.98));
  border:1px solid rgba(34,211,238,.28);
  border-radius:28px;
  padding:18px;
  box-shadow:
    0 30px 90px rgba(0,0,0,.58),
    0 0 42px rgba(34,211,238,.14);
  position:relative;
}

.stt-mobile-notify-close{
  position:absolute;
  top:14px;
  right:14px;
  width:38px;
  height:38px;
  border-radius:14px;
  border:1px solid rgba(148,163,184,.18);
  background:rgba(15,23,42,.78);
  color:#fff;
  font-size:26px;
  line-height:1;
  cursor:pointer;
}

.stt-mobile-notify-head{
  display:flex;
  align-items:center;
  gap:12px;
  padding-right:44px;
  margin-bottom:16px;
}

.stt-mobile-notify-icon{
  width:50px;
  height:50px;
  border-radius:17px;
  display:flex;
  align-items:center;
  justify-content:center;
  background:linear-gradient(135deg,rgba(34,211,238,.18),rgba(139,92,246,.20));
  border:1px solid rgba(34,211,238,.24);
}

.stt-mobile-notify-icon svg{
  width:25px;
  height:25px;
  fill:#facc15;
}

.stt-mobile-notify-head h3{
  margin:0;
  color:#fff;
  font-size:21px;
  font-weight:900;
}

.stt-mobile-notify-head p{
  margin:3px 0 0;
  color:#9fb0c9;
}

.stt-mobile-notify-list{
  display:grid;
  gap:10px;
}

.stt-mobile-notify-item{
  width:100%;
  border:1px solid rgba(148,163,184,.14);
  background:rgba(15,23,42,.76);
  border-radius:16px;
  padding:13px 14px;
  text-align:left;
  color:#e5f6ff;
  cursor:pointer;
}

.stt-mobile-notify-item.unread{
  border-color:rgba(34,211,238,.34);
  background:linear-gradient(135deg,rgba(34,211,238,.12),rgba(139,92,246,.10));
}

.stt-mobile-notify-item b{
  display:block;
  color:#fff;
  font-weight:900;
}

.stt-mobile-notify-item small{
  display:block;
  color:#9fb0c9;
  margin-top:4px;
  line-height:1.45;
}

.stt-mobile-notify-item span{
  display:block;
  color:#64748b;
  font-size:11px;
  margin-top:7px;
}

.stt-mobile-notify-empty{
  padding:16px;
  border-radius:16px;
  border:1px dashed rgba(148,163,184,.22);
  color:#cbd5e1;
}

.stt-mobile-notify-empty b,
.stt-mobile-notify-empty small{
  display:block;
}

.stt-mobile-mark-read{
  width:100%;
  margin-top:14px;
  border:1px solid rgba(34,211,238,.30);
  background:linear-gradient(135deg,rgba(8,145,178,.82),rgba(88,28,135,.82));
  color:#fff;
  border-radius:16px;
  min-height:48px;
  font-weight:900;
}

/* Language popup grid for 8 languages */
.stt-lang-options-grid{
  grid-template-columns:1fr 1fr;
}

.stt-lang-options button.active{
  border-color:rgba(34,211,238,.48);
  background:linear-gradient(135deg,rgba(34,211,238,.14),rgba(139,92,246,.16));
  box-shadow:0 0 20px rgba(34,211,238,.12);
}

@media(max-width:430px){
  .stt-lang-options-grid{
    grid-template-columns:1fr;
  }

  .stt-mobile-notify-card{
    border-radius:24px;
  }
}

/* Step 43.14.2 Mobile drawer plan badge */
.drawer-svg-icon.plan{
  color:#22d3ee;
}

.drawer-svg-icon.plan svg{
  fill:#22d3ee;
  filter:drop-shadow(0 0 10px rgba(34,211,238,.28));
}

.mobile-plan-status.active{
  color:#86efac !important;
}

.mobile-plan-status.expired{
  color:#fbbf24 !important;
}

.mobile-plan-status.blocked{
  color:#f87171 !important;
}

.mobile-plan-meta-btn{
  border-color:rgba(34,211,238,.20) !important;
}


/* Step 45.8 Live UI table alignment polish */
.stt-signal-table th,
.stt-signal-table td,
.stt-trade-history-table th,
.stt-trade-history-table td{
  text-align:center !important;
  vertical-align:middle !important;
}

.stt-signal-table th:first-child,
.stt-signal-table td:first-child,
.stt-trade-history-table th:first-child,
.stt-trade-history-table td:first-child{
  text-align:left !important;
}

.stt-signal-table .num,
.stt-trade-history-table .num{
  text-align:center !important;
}

.stt-side-pill,
.stt-mode-pill,
.stt-status-pill,
.trade-mode-pill,
.trade-status-pill{
  text-transform:none !important;
  letter-spacing:.01em !important;
  font-weight:900 !important;
}

.stt-mode-live,
.trade-mode-pill.live,
.trade-mode-pill.mode-live{
  color:#facc15 !important;
  background:rgba(250,204,21,.13) !important;
  border-color:rgba(250,204,21,.30) !important;
}

.stt-status-failed,
.trade-status-pill.failed{
  color:#fb7185 !important;
  background:rgba(244,63,94,.13) !important;
  border-color:rgba(244,63,94,.30) !important;
}

.stt-signal-table thead th,
.stt-trade-history-table thead th,
.stt-trade-history-table th{
  font-size:12px !important;
  color:#9fb7dd !important;
  white-space:nowrap !important;
}

.security-card,
.security-box,
.safety-card{
  color:#dbeafe;
}


/* Step 45.9 Final live UI label and table polish */
.status-value,
.bot-detail-value,
.bot-card strong,
.bot-card b{
  text-transform:none;
}

.stt-mode-pill,
.trade-mode-pill,
.mode-pill,
[class*="mode-pill"]{
  text-transform:uppercase !important;
  letter-spacing:.04em !important;
  font-weight:950 !important;
}

.stt-mode-live,
.trade-mode-pill.live,
.trade-mode-pill.mode-live,
.mode-live,
.pill.live,
[class*="mode-live"]{
  color:#22c55e !important;
  background:rgba(34,197,94,.14) !important;
  border:1px solid rgba(34,197,94,.34) !important;
  box-shadow:0 0 16px rgba(34,197,94,.10) !important;
}

.stt-mode-testnet,
.trade-mode-pill.testnet,
.trade-mode-pill.mode-testnet,
.mode-testnet,
.pill.testnet,
[class*="mode-testnet"]{
  color:#22d3ee !important;
  background:rgba(34,211,238,.12) !important;
  border:1px solid rgba(34,211,238,.28) !important;
}

.stt-mode-paper,
.trade-mode-pill.paper,
.trade-mode-pill.mode-paper,
.mode-paper,
.pill.paper,
[class*="mode-paper"]{
  color:#c4b5fd !important;
  background:rgba(139,92,246,.12) !important;
  border:1px solid rgba(139,92,246,.28) !important;
}

.stt-signal-table th,
.stt-signal-table td,
.stt-trade-history-table th,
.stt-trade-history-table td{
  text-align:center !important;
  vertical-align:middle !important;
  white-space:nowrap !important;
}

.stt-signal-table th:first-child,
.stt-signal-table td:first-child,
.stt-trade-history-table th:first-child,
.stt-trade-history-table td:first-child{
  text-align:left !important;
}

.stt-signal-table thead th,
.stt-trade-history-table thead th,
.stt-trade-history-table th{
  color:#9fb7dd !important;
  font-size:12px !important;
  font-weight:950 !important;
  letter-spacing:.04em !important;
  text-transform:none !important;
}

.stt-signal-table .num,
.stt-trade-history-table .num{
  text-align:center !important;
}

.live-enabled-card,
.security-card{
  border-color:rgba(34,197,94,.20) !important;
}

/* JS FIX 1 stable mode/market labels */
.bot-config-value.mode-live{
  color:#22c55e !important;
  font-weight:950 !important;
  text-transform:uppercase !important;
  letter-spacing:.04em !important;
}

.bot-config-value.mode-testnet{
  color:#22d3ee !important;
  font-weight:950 !important;
  text-transform:uppercase !important;
  letter-spacing:.04em !important;
}

.bot-config-value.mode-paper{
  color:#c4b5fd !important;
  font-weight:950 !important;
  text-transform:uppercase !important;
  letter-spacing:.04em !important;
}

.bot-config-value.market-value{
  color:#e5f6ff !important;
  font-weight:900 !important;
  text-transform:capitalize !important;
}

.stt-signal-table th,
.stt-signal-table td,
.stt-trade-history-table th,
.stt-trade-history-table td{
  text-align:center !important;
  vertical-align:middle !important;
}

.stt-signal-table th:first-child,
.stt-signal-table td:first-child,
.stt-trade-history-table th:first-child,
.stt-trade-history-table td:first-child{
  text-align:left !important;
}

/* JS FIX 2 stable mode/market labels */
.bot-config-value.mode-live{
  color:#22c55e !important;
  font-weight:950 !important;
  text-transform:uppercase !important;
  letter-spacing:.04em !important;
}

.bot-config-value.mode-testnet{
  color:#22d3ee !important;
  font-weight:950 !important;
  text-transform:uppercase !important;
  letter-spacing:.04em !important;
}

.bot-config-value.mode-paper{
  color:#c4b5fd !important;
  font-weight:950 !important;
  text-transform:uppercase !important;
  letter-spacing:.04em !important;
}

.bot-config-value.market-value{
  color:#e5f6ff !important;
  font-weight:900 !important;
  text-transform:capitalize !important;
}

/* JS FIX 3 saved config mode display */
.meta-value.mode-live,
.bot-config-value.mode-live{
  color:#22c55e !important;
  font-weight:950 !important;
  text-transform:uppercase !important;
  letter-spacing:.04em !important;
}

.meta-value.mode-testnet,
.bot-config-value.mode-testnet{
  color:#22d3ee !important;
  font-weight:950 !important;
  text-transform:uppercase !important;
  letter-spacing:.04em !important;
}

.meta-value.mode-paper,
.bot-config-value.mode-paper{
  color:#c4b5fd !important;
  font-weight:950 !important;
  text-transform:uppercase !important;
  letter-spacing:.04em !important;
}

.meta-value.market-value,
.bot-config-value.market-value{
  color:#e5f6ff !important;
  font-weight:900 !important;
  text-transform:capitalize !important;
}


/* STT STEP45.14 LIVE STATUS DOT CSS START */
.safety-top-pill .stt-live-dot,
#topLivePill .stt-live-dot {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  display: inline-block;
  margin-right: 7px;
  vertical-align: middle;
  box-shadow: 0 0 12px currentColor;
}

#topLivePill.stt-live-dot-red .stt-live-dot,
#topLivePill.live-off .stt-live-dot {
  background: #ff3b5f;
  color: #ff3b5f;
}

#topLivePill.stt-live-dot-green .stt-live-dot,
#topLivePill.live-on .stt-live-dot {
  background: #20e87a;
  color: #20e87a;
}

#topLivePill.live-off,
.safety-top-pill.live-off {
  border: 1px solid rgba(255, 70, 105, 0.45) !important;
  background: linear-gradient(135deg, rgba(255, 54, 94, 0.22), rgba(116, 49, 255, 0.25)) !important;
  color: #ffd4dc !important;
  box-shadow: 0 0 18px rgba(255, 54, 94, 0.16) !important;
}

#topLivePill.live-on,
.safety-top-pill.live-on {
  border: 1px solid rgba(38, 232, 122, 0.45) !important;
  background: linear-gradient(135deg, rgba(32, 232, 122, 0.22), rgba(36, 117, 255, 0.22)) !important;
  color: #d9ffe9 !important;
  box-shadow: 0 0 18px rgba(32, 232, 122, 0.18) !important;
}

.stt-live-enabled-badge {
  background: linear-gradient(135deg, rgba(23, 210, 105, 0.28), rgba(34, 197, 94, 0.18)) !important;
  border: 1px solid rgba(34, 197, 94, 0.45) !important;
  color: #baffd4 !important;
  box-shadow: 0 0 16px rgba(34, 197, 94, 0.18) !important;
}

.stt-live-disabled-badge {
  background: linear-gradient(135deg, rgba(255, 59, 95, 0.26), rgba(255, 149, 0, 0.12)) !important;
  border: 1px solid rgba(255, 59, 95, 0.45) !important;
  color: #ffd1dc !important;
  box-shadow: 0 0 16px rgba(255, 59, 95, 0.16) !important;
}

.stt-live-value-enabled {
  color: #40ff97 !important;
  text-shadow: 0 0 12px rgba(64, 255, 151, 0.25);
}

.stt-live-value-disabled {
  color: #ff6680 !important;
  text-shadow: 0 0 12px rgba(255, 102, 128, 0.25);
}

.stt-api-connected-badge {
  background: linear-gradient(135deg, rgba(23, 210, 105, 0.26), rgba(34, 197, 94, 0.14)) !important;
  border: 1px solid rgba(34, 197, 94, 0.42) !important;
  color: #caffdf !important;
}

.stt-api-not-connected-badge {
  background: linear-gradient(135deg, rgba(124, 58, 237, 0.35), rgba(255, 59, 95, 0.14)) !important;
  border: 1px solid rgba(167, 139, 250, 0.32) !important;
  color: #e9ddff !important;
}
/* STT STEP45.14 LIVE STATUS DOT CSS END */


/* STT STEP45.15 EXCHANGE LIVE CARD CSS START */
#binanceLiveTradingBadge,
.stt-live-disabled-badge,
.stt-live-enabled-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border-radius: 999px;
  padding: 8px 14px;
  font-weight: 900;
  font-size: 12px;
  letter-spacing: .3px;
}

#binanceLiveTradingBadge::before,
.stt-live-disabled-badge::before,
.stt-live-enabled-badge::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 999px;
  display: inline-block;
  box-shadow: 0 0 12px currentColor;
}

#binanceLiveTradingBadge.stt-live-disabled-badge,
.stt-live-disabled-badge {
  background: linear-gradient(135deg, rgba(255, 59, 95, .24), rgba(255, 149, 0, .10)) !important;
  border: 1px solid rgba(255, 59, 95, .48) !important;
  color: #ffd4dc !important;
}

#binanceLiveTradingBadge.stt-live-enabled-badge,
.stt-live-enabled-badge {
  background: linear-gradient(135deg, rgba(20, 220, 120, .26), rgba(0, 180, 255, .10)) !important;
  border: 1px solid rgba(20, 220, 120, .48) !important;
  color: #caffdf !important;
}

#binanceLiveTradingValue.stt-live-value-disabled,
.stt-live-value-disabled {
  color: #ff5f7e !important;
  font-weight: 900 !important;
}

#binanceLiveTradingValue.stt-live-value-enabled,
.stt-live-value-enabled {
  color: #37ff96 !important;
  font-weight: 900 !important;
}

#binanceSafetyCheckCard.stt-live-card-disabled {
  border-color: rgba(255, 59, 95, .20) !important;
}

#binanceSafetyCheckCard.stt-live-card-enabled {
  border-color: rgba(20, 220, 120, .28) !important;
}

#topLivePill .stt-live-dot {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  display: inline-block;
  margin-right: 7px;
  box-shadow: 0 0 12px currentColor;
}

#topLivePill.stt-live-dot-red .stt-live-dot {
  background: #ff3b5f;
  color: #ff3b5f;
}

#topLivePill.stt-live-dot-green .stt-live-dot {
  background: #20e87a;
  color: #20e87a;
}
/* STT STEP45.15 EXCHANGE LIVE CARD CSS END */


/* STT STEP45.16 FINAL LIVE STATUS CSS START */
#topLivePill .stt-live-dot {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  display: inline-block;
  margin-right: 7px;
  box-shadow: 0 0 12px currentColor;
}

#topLivePill.stt-live-dot-red .stt-live-dot,
#topLivePill.live-off .stt-live-dot {
  background: #ff3b5f !important;
  color: #ff3b5f !important;
}

#topLivePill.stt-live-dot-green .stt-live-dot,
#topLivePill.live-on .stt-live-dot {
  background: #20e87a !important;
  color: #20e87a !important;
}

#topLivePill.live-off {
  border: 1px solid rgba(255, 59, 95, .45) !important;
  background: linear-gradient(135deg, rgba(255, 59, 95, .22), rgba(124, 58, 237, .24)) !important;
  color: #ffe1e7 !important;
}

#topLivePill.live-on {
  border: 1px solid rgba(32, 232, 122, .45) !important;
  background: linear-gradient(135deg, rgba(32, 232, 122, .22), rgba(59, 130, 246, .20)) !important;
  color: #dfffee !important;
}

.stt-live-disabled-badge {
  background: linear-gradient(135deg, rgba(255, 59, 95, .26), rgba(255, 149, 0, .12)) !important;
  border: 1px solid rgba(255, 59, 95, .50) !important;
  color: #ffd6df !important;
  box-shadow: 0 0 16px rgba(255, 59, 95, .16) !important;
}

.stt-live-enabled-badge {
  background: linear-gradient(135deg, rgba(20, 220, 120, .28), rgba(0, 180, 255, .12)) !important;
  border: 1px solid rgba(20, 220, 120, .50) !important;
  color: #caffdf !important;
  box-shadow: 0 0 16px rgba(20, 220, 120, .16) !important;
}

.stt-live-value-disabled {
  color: #ff6680 !important;
  font-weight: 900 !important;
}

.stt-live-value-enabled {
  color: #37ff96 !important;
  font-weight: 900 !important;
}

.stt-live-card-disabled {
  border-color: rgba(255, 59, 95, .22) !important;
}

.stt-live-card-enabled {
  border-color: rgba(20, 220, 120, .30) !important;
}
/* STT STEP45.16 FINAL LIVE STATUS CSS END */


/* STT STEP45.17 CLEAN LIVE STATUS CSS START */
#topLivePill .stt-live-dot {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  display: inline-block;
  margin-right: 7px;
  box-shadow: 0 0 12px currentColor;
}

#topLivePill.live-off .stt-live-dot,
#topLivePill.stt-live-dot-red .stt-live-dot {
  background: #ff3b5f !important;
  color: #ff3b5f !important;
}

#topLivePill.live-on .stt-live-dot,
#topLivePill.stt-live-dot-green .stt-live-dot {
  background: #20e87a !important;
  color: #20e87a !important;
}

#topLivePill.live-off {
  border: 1px solid rgba(255, 59, 95, .45) !important;
  background: linear-gradient(135deg, rgba(255, 59, 95, .22), rgba(124, 58, 237, .24)) !important;
  color: #ffe1e7 !important;
}

#topLivePill.live-on {
  border: 1px solid rgba(32, 232, 122, .45) !important;
  background: linear-gradient(135deg, rgba(32, 232, 122, .22), rgba(59, 130, 246, .20)) !important;
  color: #dfffee !important;
}

.stt-live-disabled-badge {
  background: linear-gradient(135deg, rgba(255, 59, 95, .26), rgba(255, 149, 0, .12)) !important;
  border: 1px solid rgba(255, 59, 95, .50) !important;
  color: #ffd6df !important;
  box-shadow: 0 0 16px rgba(255, 59, 95, .16) !important;
}

.stt-live-enabled-badge {
  background: linear-gradient(135deg, rgba(20, 220, 120, .28), rgba(0, 180, 255, .12)) !important;
  border: 1px solid rgba(20, 220, 120, .50) !important;
  color: #caffdf !important;
  box-shadow: 0 0 16px rgba(20, 220, 120, .16) !important;
}

.stt-live-value-disabled {
  color: #ff6680 !important;
  font-weight: 900 !important;
}

.stt-live-value-enabled {
  color: #37ff96 !important;
  font-weight: 900 !important;
}
/* STT STEP45.17 CLEAN LIVE STATUS CSS END */


/* STT STEP45.18 TOPBAR DUPLICATE STATUS FIX START */
/* Hide old plain topbar status labels that appear beside the real pills */
.topbar > span:not(.safety-top-pill):not(.profile-chip):not(.notification-badge),
.topbar-actions > span:not(.safety-top-pill):not(.profile-chip):not(.notification-badge),
.header-actions > span:not(.safety-top-pill):not(.profile-chip):not(.notification-badge) {
  display: none !important;
}

/* Keep the real pills visible */
#topModePill,
#topLivePill {
  display: inline-flex !important;
  align-items: center !important;
  gap: 4px !important;
  white-space: nowrap !important;
}

#topLivePill.live-on {
  border: 1px solid rgba(32, 232, 122, .48) !important;
  background: linear-gradient(135deg, rgba(32, 232, 122, .24), rgba(59, 130, 246, .20)) !important;
  color: #dfffee !important;
}

#topLivePill.live-off {
  border: 1px solid rgba(255, 59, 95, .48) !important;
  background: linear-gradient(135deg, rgba(255, 59, 95, .24), rgba(124, 58, 237, .24)) !important;
  color: #ffe1e7 !important;
}
/* STT STEP45.18 TOPBAR DUPLICATE STATUS FIX END */


/* STT STEP45.26 BOT CONFIG BUTTON POLISH START */

/* Bot card settings/config button premium look */
.bot-card button[onclick*="openBotConfig"],
.bot-card .bot-config-btn,
.bot-card .settings-btn,
.bot-card .config-btn,
.bot-card .gear-btn,
.bot-card button:has(.gear-icon),
.bot-card button:has(.config-icon) {
  min-height: 48px !important;
  border-radius: 15px !important;
  border: 1px solid rgba(34, 211, 238, 0.36) !important;
  background:
    radial-gradient(circle at 25% 20%, rgba(34, 211, 238, 0.22), transparent 34%),
    linear-gradient(135deg, rgba(8, 47, 73, 0.92), rgba(79, 70, 229, 0.34), rgba(15, 23, 42, 0.96)) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 12px 28px rgba(0, 0, 0, 0.26),
    0 0 18px rgba(34, 211, 238, 0.10) !important;
  color: #dffbff !important;
  font-weight: 900 !important;
  font-size: 0 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 10px !important;
  position: relative !important;
  overflow: hidden !important;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease, background .18s ease !important;
}

/* Bigger premium gear icon */
.bot-card button[onclick*="openBotConfig"]::before,
.bot-card .bot-config-btn::before,
.bot-card .settings-btn::before,
.bot-card .config-btn::before,
.bot-card .gear-btn::before {
  content: "⚙";
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 21px;
  line-height: 1;
  color: #ffffff;
  background:
    radial-gradient(circle at 35% 25%, rgba(255, 255, 255, 0.28), transparent 34%),
    linear-gradient(135deg, rgba(34, 211, 238, 0.95), rgba(124, 58, 237, 0.92));
  box-shadow:
    0 0 20px rgba(34, 211, 238, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.22);
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.45);
}

/* Optional text label on wider cards */
.bot-card button[onclick*="openBotConfig"]::after,
.bot-card .bot-config-btn::after,
.bot-card .settings-btn::after,
.bot-card .config-btn::after,
.bot-card .gear-btn::after {
  content: "Configure";
  font-size: 13px;
  letter-spacing: .2px;
  color: #e8fbff;
  text-shadow: 0 0 12px rgba(34, 211, 238, 0.18);
}

/* Shine effect */
.bot-card button[onclick*="openBotConfig"] span,
.bot-card .bot-config-btn span,
.bot-card .settings-btn span,
.bot-card .config-btn span,
.bot-card .gear-btn span {
  display: none !important;
}

.bot-card button[onclick*="openBotConfig"]:hover,
.bot-card .bot-config-btn:hover,
.bot-card .settings-btn:hover,
.bot-card .config-btn:hover,
.bot-card .gear-btn:hover {
  transform: translateY(-2px);
  border-color: rgba(34, 211, 238, 0.68) !important;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.10),
    0 16px 34px rgba(0, 0, 0, 0.34),
    0 0 28px rgba(34, 211, 238, 0.20) !important;
}

.bot-card button[onclick*="openBotConfig"]:active,
.bot-card .bot-config-btn:active,
.bot-card .settings-btn:active,
.bot-card .config-btn:active,
.bot-card .gear-btn:active {
  transform: translateY(0) scale(0.98);
}

/* Small screens: keep icon big, hide label to save space */
@media (max-width: 620px) {
  .bot-card button[onclick*="openBotConfig"]::after,
  .bot-card .bot-config-btn::after,
  .bot-card .settings-btn::after,
  .bot-card .config-btn::after,
  .bot-card .gear-btn::after {
    content: "";
  }

  .bot-card button[onclick*="openBotConfig"],
  .bot-card .bot-config-btn,
  .bot-card .settings-btn,
  .bot-card .config-btn,
  .bot-card .gear-btn {
    min-width: 92px !important;
  }
}

/* STT STEP45.26 BOT CONFIG BUTTON POLISH END */


/* STT STEP45.29 MARKET WATCH VOLUME CSS START */
.stt-market-table-with-volume th:nth-child(3),
.stt-market-table-with-volume th:nth-child(4),
.stt-market-table-with-volume th:nth-child(5),
.stt-market-table-with-volume td:nth-child(3),
.stt-market-table-with-volume td:nth-child(4),
.stt-market-table-with-volume td:nth-child(5) {
  text-align: right;
}

.market-volume-cell {
  color: #9fb8d8;
  font-weight: 800;
  white-space: nowrap;
}

.stt-market-table-with-volume .market-price-cell {
  white-space: nowrap;
}

.stt-market-table-with-volume .market-change-cell {
  white-space: nowrap;
}

@media (max-width: 760px) {
  .stt-market-table-with-volume th:nth-child(4),
  .stt-market-table-with-volume td:nth-child(4) {
    display: none;
  }
}
/* STT STEP45.29 MARKET WATCH VOLUME CSS END */


/* STT STEP45.30 MARKET WATCH COLUMN ALIGNMENT START */

.stt-market-table,
.stt-market-table-with-volume {
  width: 100%;
  table-layout: fixed !important;
  border-collapse: collapse;
}

/* # column */
.stt-market-table-with-volume th:nth-child(1),
.stt-market-table-with-volume td:nth-child(1) {
  width: 56px !important;
  text-align: center !important;
}

/* Name column takes main space */
.stt-market-table-with-volume th:nth-child(2),
.stt-market-table-with-volume td:nth-child(2) {
  width: auto !important;
  text-align: left !important;
}

/* Price */
.stt-market-table-with-volume th:nth-child(3),
.stt-market-table-with-volume td:nth-child(3) {
  width: 160px !important;
  text-align: right !important;
  padding-right: 22px !important;
}

/* 24H Volume */
.stt-market-table-with-volume th:nth-child(4),
.stt-market-table-with-volume td:nth-child(4) {
  width: 170px !important;
  text-align: right !important;
  padding-right: 22px !important;
}

/* 24H Change % */
.stt-market-table-with-volume th:nth-child(5),
.stt-market-table-with-volume td:nth-child(5) {
  width: 150px !important;
  text-align: right !important;
  padding-right: 18px !important;
}

.stt-market-table-with-volume th {
  color: #9fb8d8 !important;
  font-size: 12px !important;
  letter-spacing: .35px !important;
  text-transform: uppercase !important;
  white-space: nowrap !important;
}

.market-price-cell,
.market-volume-cell,
.market-change-cell {
  white-space: nowrap !important;
  font-variant-numeric: tabular-nums;
}

.market-price-cell {
  color: #e8f2ff !important;
  font-weight: 900 !important;
}

.market-volume-cell {
  color: #b8c9e6 !important;
  font-weight: 850 !important;
}

.market-change-cell {
  font-weight: 900 !important;
}

/* Medium screens: keep all columns but reduce widths */
@media (max-width: 1100px) {
  .stt-market-table-with-volume th:nth-child(3),
  .stt-market-table-with-volume td:nth-child(3) {
    width: 130px !important;
    padding-right: 14px !important;
  }

  .stt-market-table-with-volume th:nth-child(4),
  .stt-market-table-with-volume td:nth-child(4) {
    width: 135px !important;
    padding-right: 14px !important;
  }

  .stt-market-table-with-volume th:nth-child(5),
  .stt-market-table-with-volume td:nth-child(5) {
    width: 130px !important;
    padding-right: 12px !important;
  }
}

/* Phone: hide volume to avoid cramped table */
@media (max-width: 760px) {
  .stt-market-table-with-volume th:nth-child(4),
  .stt-market-table-with-volume td:nth-child(4) {
    display: none !important;
  }

  .stt-market-table-with-volume th:nth-child(3),
  .stt-market-table-with-volume td:nth-child(3) {
    width: 110px !important;
  }

  .stt-market-table-with-volume th:nth-child(5),
  .stt-market-table-with-volume td:nth-child(5) {
    width: 115px !important;
  }
}

/* STT STEP45.30 MARKET WATCH COLUMN ALIGNMENT END */


/* STT STEP45.31 MOBILE MARKET VOLUME SHOW START */

/* Mobile par bhi 24H Volume show rahega */
@media (max-width: 760px) {
  .market-table-scroll {
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch;
  }

  .stt-market-table-with-volume {
    min-width: 720px !important;
    table-layout: fixed !important;
  }

  .stt-market-table-with-volume th:nth-child(4),
  .stt-market-table-with-volume td:nth-child(4) {
    display: table-cell !important;
    width: 135px !important;
    text-align: right !important;
    padding-right: 12px !important;
  }

  .stt-market-table-with-volume th:nth-child(3),
  .stt-market-table-with-volume td:nth-child(3) {
    width: 120px !important;
  }

  .stt-market-table-with-volume th:nth-child(5),
  .stt-market-table-with-volume td:nth-child(5) {
    width: 130px !important;
  }
}

/* STT STEP45.31 MOBILE MARKET VOLUME SHOW END */


/* STT STEP45.32 MOBILE MARKET COMPACT VOLUME LAST START */

/* Desktop/tablet final order:
   # | Name | Price | 24H Change % | 24H Volume
*/
.stt-market-table-with-volume th:nth-child(3),
.stt-market-table-with-volume td:nth-child(3) {
  width: 150px !important;
  text-align: right !important;
  padding-right: 18px !important;
}

.stt-market-table-with-volume th:nth-child(4),
.stt-market-table-with-volume td:nth-child(4) {
  width: 150px !important;
  text-align: right !important;
  padding-right: 18px !important;
}

.stt-market-table-with-volume th:nth-child(5),
.stt-market-table-with-volume td:nth-child(5) {
  width: 155px !important;
  text-align: right !important;
  padding-right: 16px !important;
}

/* Phone view: name-price gap reduce + volume last with small horizontal scroll */
@media (max-width: 760px) {
  .market-table-scroll {
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch;
  }

  .stt-market-table-with-volume {
    min-width: 560px !important;
    table-layout: fixed !important;
  }

  .stt-market-table-with-volume th,
  .stt-market-table-with-volume td {
    padding-left: 8px !important;
    padding-right: 8px !important;
  }

  /* # column compact */
  .stt-market-table-with-volume th:nth-child(1),
  .stt-market-table-with-volume td:nth-child(1) {
    width: 36px !important;
    text-align: center !important;
  }

  /* Name column compact: gap kam */
  .stt-market-table-with-volume th:nth-child(2),
  .stt-market-table-with-volume td:nth-child(2) {
    width: 185px !important;
    max-width: 185px !important;
    text-align: left !important;
  }

  .market-name-cell {
    gap: 8px !important;
  }

  .coin-logo,
  .market-coin-logo-wrap {
    width: 28px !important;
    height: 28px !important;
    min-width: 28px !important;
  }

  .rank-symbol {
    font-size: 12px !important;
  }

  .rank-name {
    font-size: 10px !important;
    max-width: 105px !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  /* Price */
  .stt-market-table-with-volume th:nth-child(3),
  .stt-market-table-with-volume td:nth-child(3) {
    width: 100px !important;
    text-align: right !important;
    padding-right: 8px !important;
  }

  /* 24H Change % */
  .stt-market-table-with-volume th:nth-child(4),
  .stt-market-table-with-volume td:nth-child(4) {
    width: 105px !important;
    text-align: right !important;
    padding-right: 8px !important;
  }

  /* 24H Volume last */
  .stt-market-table-with-volume th:nth-child(5),
  .stt-market-table-with-volume td:nth-child(5) {
    display: table-cell !important;
    width: 115px !important;
    text-align: right !important;
    padding-right: 10px !important;
  }

  .market-price-cell,
  .market-change-cell,
  .market-volume-cell {
    font-size: 11px !important;
    white-space: nowrap !important;
  }
}

/* STT STEP45.32 MOBILE MARKET COMPACT VOLUME LAST END */


/* STT STEP45.33 MOBILE MARKET LESS SCROLL START */

/* Phone view: columns ko left shift + scroll ko kam karo */
@media (max-width: 760px) {
  .market-table-scroll {
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch;
  }

  .stt-market-table-with-volume {
    min-width: 500px !important;
    table-layout: fixed !important;
  }

  .stt-market-table-with-volume th,
  .stt-market-table-with-volume td {
    padding-left: 5px !important;
    padding-right: 5px !important;
  }

  /* # column */
  .stt-market-table-with-volume th:nth-child(1),
  .stt-market-table-with-volume td:nth-child(1) {
    width: 30px !important;
    min-width: 30px !important;
    text-align: center !important;
  }

  /* Name column: gap kam, width compact */
  .stt-market-table-with-volume th:nth-child(2),
  .stt-market-table-with-volume td:nth-child(2) {
    width: 145px !important;
    max-width: 145px !important;
    text-align: left !important;
  }

  .market-name-cell {
    gap: 6px !important;
    min-width: 0 !important;
  }

  .coin-logo,
  .market-coin-logo-wrap {
    width: 25px !important;
    height: 25px !important;
    min-width: 25px !important;
  }

  .rank-symbol {
    font-size: 11px !important;
    line-height: 1.1 !important;
  }

  .rank-name {
    font-size: 9px !important;
    max-width: 82px !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  /* Price ko left me lao */
  .stt-market-table-with-volume th:nth-child(3),
  .stt-market-table-with-volume td:nth-child(3) {
    width: 88px !important;
    min-width: 88px !important;
    text-align: right !important;
    padding-right: 6px !important;
  }

  /* 24H Change % ko bhi compact karo */
  .stt-market-table-with-volume th:nth-child(4),
  .stt-market-table-with-volume td:nth-child(4) {
    width: 92px !important;
    min-width: 92px !important;
    text-align: right !important;
    padding-right: 6px !important;
  }

  /* Volume last: sirf isi ke barabar extra scroll lage */
  .stt-market-table-with-volume th:nth-child(5),
  .stt-market-table-with-volume td:nth-child(5) {
    display: table-cell !important;
    width: 105px !important;
    min-width: 105px !important;
    text-align: right !important;
    padding-right: 7px !important;
  }

  .market-price-cell,
  .market-change-cell,
  .market-volume-cell {
    font-size: 10.5px !important;
    white-space: nowrap !important;
    font-variant-numeric: tabular-nums;
  }

  .stt-market-table-with-volume th {
    font-size: 9.5px !important;
    letter-spacing: .15px !important;
    white-space: nowrap !important;
  }
}

/* Extra small phone: aur compact */
@media (max-width: 420px) {
  .stt-market-table-with-volume {
    min-width: 485px !important;
  }

  .stt-market-table-with-volume th:nth-child(2),
  .stt-market-table-with-volume td:nth-child(2) {
    width: 132px !important;
    max-width: 132px !important;
  }

  .rank-name {
    max-width: 72px !important;
  }

  .stt-market-table-with-volume th:nth-child(3),
  .stt-market-table-with-volume td:nth-child(3) {
    width: 84px !important;
  }

  .stt-market-table-with-volume th:nth-child(4),
  .stt-market-table-with-volume td:nth-child(4) {
    width: 88px !important;
  }

  .stt-market-table-with-volume th:nth-child(5),
  .stt-market-table-with-volume td:nth-child(5) {
    width: 100px !important;
  }
}

/* STT STEP45.33 MOBILE MARKET LESS SCROLL END */


/* STT STEP45.34 RESTORE MOBILE MARKET TEXT SIZE START */

/* Mobile: text normal rakho, sirf Volume last me horizontal scroll me rahe */
@media (max-width: 760px) {
  .market-table-scroll {
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch;
  }

  .stt-market-table-with-volume {
    min-width: 620px !important;
    table-layout: fixed !important;
  }

  .stt-market-table-with-volume th,
  .stt-market-table-with-volume td {
    padding-left: 10px !important;
    padding-right: 10px !important;
  }

  /* # column normal */
  .stt-market-table-with-volume th:nth-child(1),
  .stt-market-table-with-volume td:nth-child(1) {
    width: 42px !important;
    min-width: 42px !important;
    text-align: center !important;
  }

  /* Name column normal size */
  .stt-market-table-with-volume th:nth-child(2),
  .stt-market-table-with-volume td:nth-child(2) {
    width: 205px !important;
    max-width: 205px !important;
    text-align: left !important;
  }

  .market-name-cell {
    gap: 10px !important;
    min-width: 0 !important;
  }

  .coin-logo,
  .market-coin-logo-wrap {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
  }

  .rank-symbol {
    font-size: 13px !important;
    line-height: 1.15 !important;
    font-weight: 900 !important;
  }

  .rank-name {
    font-size: 11px !important;
    max-width: 125px !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  /* Price normal readable */
  .stt-market-table-with-volume th:nth-child(3),
  .stt-market-table-with-volume td:nth-child(3) {
    width: 120px !important;
    min-width: 120px !important;
    text-align: right !important;
    padding-right: 10px !important;
  }

  /* 24H Change normal readable */
  .stt-market-table-with-volume th:nth-child(4),
  .stt-market-table-with-volume td:nth-child(4) {
    width: 125px !important;
    min-width: 125px !important;
    text-align: right !important;
    padding-right: 10px !important;
  }

  /* Volume last me rahega; mobile me right scroll karke dikhega */
  .stt-market-table-with-volume th:nth-child(5),
  .stt-market-table-with-volume td:nth-child(5) {
    display: table-cell !important;
    width: 125px !important;
    min-width: 125px !important;
    text-align: right !important;
    padding-right: 12px !important;
  }

  .market-price-cell,
  .market-change-cell,
  .market-volume-cell {
    font-size: 13px !important;
    white-space: nowrap !important;
    font-variant-numeric: tabular-nums;
  }

  .stt-market-table-with-volume th {
    font-size: 11px !important;
    letter-spacing: .25px !important;
    white-space: nowrap !important;
  }
}

/* Extra small phone par bhi text jyada small nahi hoga */
@media (max-width: 420px) {
  .stt-market-table-with-volume {
    min-width: 610px !important;
  }

  .stt-market-table-with-volume th:nth-child(2),
  .stt-market-table-with-volume td:nth-child(2) {
    width: 195px !important;
    max-width: 195px !important;
  }

  .rank-name {
    max-width: 118px !important;
  }

  .market-price-cell,
  .market-change-cell,
  .market-volume-cell {
    font-size: 12.5px !important;
  }

  .rank-symbol {
    font-size: 12.5px !important;
  }

  .rank-name {
    font-size: 10.5px !important;
  }
}

/* STT STEP45.34 RESTORE MOBILE MARKET TEXT SIZE END */


/* STT STEP45.35 MOBILE MARKET FIT CHANGE VISIBLE START */

/*
  Mobile final layout:
  Visible: # | Name | Price | 24H Change %
  Scroll right: 24H Volume only
*/
@media (max-width: 760px) {
  .market-table-scroll {
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch;
  }

  .stt-market-table-with-volume {
    min-width: 520px !important;
    table-layout: fixed !important;
  }

  .stt-market-table-with-volume th,
  .stt-market-table-with-volume td {
    padding-left: 5px !important;
    padding-right: 5px !important;
  }

  /* # */
  .stt-market-table-with-volume th:nth-child(1),
  .stt-market-table-with-volume td:nth-child(1) {
    width: 32px !important;
    min-width: 32px !important;
    text-align: center !important;
  }

  /* Name: readable but compact */
  .stt-market-table-with-volume th:nth-child(2),
  .stt-market-table-with-volume td:nth-child(2) {
    width: 165px !important;
    max-width: 165px !important;
    text-align: left !important;
  }

  .market-name-cell {
    gap: 8px !important;
    min-width: 0 !important;
  }

  .coin-logo,
  .market-coin-logo-wrap {
    width: 30px !important;
    height: 30px !important;
    min-width: 30px !important;
  }

  .rank-symbol {
    font-size: 13px !important;
    line-height: 1.15 !important;
    font-weight: 900 !important;
  }

  .rank-name {
    font-size: 10.5px !important;
    max-width: 95px !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  /* Price visible on phone */
  .stt-market-table-with-volume th:nth-child(3),
  .stt-market-table-with-volume td:nth-child(3) {
    width: 105px !important;
    min-width: 105px !important;
    text-align: right !important;
    padding-right: 6px !important;
  }

  /* 24H Change % visible on phone */
  .stt-market-table-with-volume th:nth-child(4),
  .stt-market-table-with-volume td:nth-child(4) {
    display: table-cell !important;
    width: 108px !important;
    min-width: 108px !important;
    text-align: right !important;
    padding-right: 7px !important;
  }

  /* Volume last: only this column should need right scroll */
  .stt-market-table-with-volume th:nth-child(5),
  .stt-market-table-with-volume td:nth-child(5) {
    display: table-cell !important;
    width: 110px !important;
    min-width: 110px !important;
    text-align: right !important;
    padding-right: 8px !important;
  }

  .market-price-cell,
  .market-change-cell,
  .market-volume-cell {
    font-size: 12.5px !important;
    white-space: nowrap !important;
    font-variant-numeric: tabular-nums;
  }

  .stt-market-table-with-volume th {
    font-size: 10px !important;
    letter-spacing: .12px !important;
    white-space: nowrap !important;
  }
}

/* Extra small phone final: still keep Price + Change visible */
@media (max-width: 420px) {
  .stt-market-table-with-volume {
    min-width: 505px !important;
  }

  .stt-market-table-with-volume th:nth-child(1),
  .stt-market-table-with-volume td:nth-child(1) {
    width: 30px !important;
    min-width: 30px !important;
  }

  .stt-market-table-with-volume th:nth-child(2),
  .stt-market-table-with-volume td:nth-child(2) {
    width: 155px !important;
    max-width: 155px !important;
  }

  .coin-logo,
  .market-coin-logo-wrap {
    width: 28px !important;
    height: 28px !important;
    min-width: 28px !important;
  }

  .rank-symbol {
    font-size: 12.5px !important;
  }

  .rank-name {
    font-size: 10px !important;
    max-width: 88px !important;
  }

  .stt-market-table-with-volume th:nth-child(3),
  .stt-market-table-with-volume td:nth-child(3) {
    width: 100px !important;
    min-width: 100px !important;
  }

  .stt-market-table-with-volume th:nth-child(4),
  .stt-market-table-with-volume td:nth-child(4) {
    width: 104px !important;
    min-width: 104px !important;
  }

  .stt-market-table-with-volume th:nth-child(5),
  .stt-market-table-with-volume td:nth-child(5) {
    width: 108px !important;
    min-width: 108px !important;
  }

  .market-price-cell,
  .market-change-cell,
  .market-volume-cell {
    font-size: 12px !important;
  }

  .stt-market-table-with-volume th {
    font-size: 9.5px !important;
  }
}

/* STT STEP45.35 MOBILE MARKET FIT CHANGE VISIBLE END */


/* STT STEP45.36 MOBILE MARKET SHIFT COLUMNS LEFT START */

/*
  Size same rahega.
  Sirf Price, 24H Change %, Volume ko mobile me thoda left shift karna hai.
*/
@media (max-width: 760px) {
  .stt-market-table-with-volume {
    min-width: 500px !important;
  }

  /* # compact */
  .stt-market-table-with-volume th:nth-child(1),
  .stt-market-table-with-volume td:nth-child(1) {
    width: 30px !important;
    min-width: 30px !important;
  }

  /* Name thoda compact, taki Price/Change left aa jaye */
  .stt-market-table-with-volume th:nth-child(2),
  .stt-market-table-with-volume td:nth-child(2) {
    width: 148px !important;
    max-width: 148px !important;
  }

  .market-name-cell {
    gap: 7px !important;
  }

  .rank-name {
    max-width: 82px !important;
  }

  /* Price left shift */
  .stt-market-table-with-volume th:nth-child(3),
  .stt-market-table-with-volume td:nth-child(3) {
    width: 96px !important;
    min-width: 96px !important;
    padding-left: 3px !important;
    padding-right: 5px !important;
    text-align: right !important;
  }

  /* 24H Change % left shift, cut nahi hoga */
  .stt-market-table-with-volume th:nth-child(4),
  .stt-market-table-with-volume td:nth-child(4) {
    width: 98px !important;
    min-width: 98px !important;
    padding-left: 3px !important;
    padding-right: 6px !important;
    text-align: right !important;
  }

  /* Volume bhi same proportion me left */
  .stt-market-table-with-volume th:nth-child(5),
  .stt-market-table-with-volume td:nth-child(5) {
    width: 106px !important;
    min-width: 106px !important;
    padding-left: 3px !important;
    padding-right: 7px !important;
    text-align: right !important;
  }
}

/* Extra small phone */
@media (max-width: 420px) {
  .stt-market-table-with-volume {
    min-width: 492px !important;
  }

  .stt-market-table-with-volume th:nth-child(2),
  .stt-market-table-with-volume td:nth-child(2) {
    width: 142px !important;
    max-width: 142px !important;
  }

  .rank-name {
    max-width: 78px !important;
  }

  .stt-market-table-with-volume th:nth-child(3),
  .stt-market-table-with-volume td:nth-child(3) {
    width: 94px !important;
    min-width: 94px !important;
  }

  .stt-market-table-with-volume th:nth-child(4),
  .stt-market-table-with-volume td:nth-child(4) {
    width: 96px !important;
    min-width: 96px !important;
  }

  .stt-market-table-with-volume th:nth-child(5),
  .stt-market-table-with-volume td:nth-child(5) {
    width: 104px !important;
    min-width: 104px !important;
  }
}

/* STT STEP45.36 MOBILE MARKET SHIFT COLUMNS LEFT END */


/* STT STEP45.37 MOBILE MARKET VALUE COLUMNS MORE LEFT START */

/* Sirf Price / 24H Change % / 24H Volume ko thoda aur left shift */
@media (max-width: 760px) {
  .stt-market-table-with-volume {
    min-width: 486px !important;
  }

  /* Name column ko thoda compact karke value columns left lao */
  .stt-market-table-with-volume th:nth-child(2),
  .stt-market-table-with-volume td:nth-child(2) {
    width: 138px !important;
    max-width: 138px !important;
  }

  .rank-name {
    max-width: 74px !important;
  }

  /* Price */
  .stt-market-table-with-volume th:nth-child(3),
  .stt-market-table-with-volume td:nth-child(3) {
    width: 90px !important;
    min-width: 90px !important;
    padding-left: 2px !important;
    padding-right: 4px !important;
  }

  /* 24H Change % */
  .stt-market-table-with-volume th:nth-child(4),
  .stt-market-table-with-volume td:nth-child(4) {
    width: 92px !important;
    min-width: 92px !important;
    padding-left: 2px !important;
    padding-right: 5px !important;
  }

  /* 24H Volume */
  .stt-market-table-with-volume th:nth-child(5),
  .stt-market-table-with-volume td:nth-child(5) {
    width: 100px !important;
    min-width: 100px !important;
    padding-left: 2px !important;
    padding-right: 6px !important;
  }
}

@media (max-width: 420px) {
  .stt-market-table-with-volume {
    min-width: 478px !important;
  }

  .stt-market-table-with-volume th:nth-child(2),
  .stt-market-table-with-volume td:nth-child(2) {
    width: 134px !important;
    max-width: 134px !important;
  }

  .rank-name {
    max-width: 70px !important;
  }

  .stt-market-table-with-volume th:nth-child(3),
  .stt-market-table-with-volume td:nth-child(3) {
    width: 88px !important;
    min-width: 88px !important;
  }

  .stt-market-table-with-volume th:nth-child(4),
  .stt-market-table-with-volume td:nth-child(4) {
    width: 90px !important;
    min-width: 90px !important;
  }

  .stt-market-table-with-volume th:nth-child(5),
  .stt-market-table-with-volume td:nth-child(5) {
    width: 98px !important;
    min-width: 98px !important;
  }
}

/* STT STEP45.37 MOBILE MARKET VALUE COLUMNS MORE LEFT END */


/* STT STEP45.38 EXTRA SMALL PHONE MARKET FIT START */

/*
  Very small phones:
  Visible: # | Name | Price | 24H Change %
  Scroll right: 24H Volume only
*/
@media (max-width: 390px) {
  .market-table-scroll {
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch;
  }

  .stt-market-table-with-volume {
    min-width: 438px !important;
    table-layout: fixed !important;
  }

  .stt-market-table-with-volume th,
  .stt-market-table-with-volume td {
    padding-left: 3px !important;
    padding-right: 3px !important;
  }

  /* # */
  .stt-market-table-with-volume th:nth-child(1),
  .stt-market-table-with-volume td:nth-child(1) {
    width: 26px !important;
    min-width: 26px !important;
    text-align: center !important;
  }

  /* Name */
  .stt-market-table-with-volume th:nth-child(2),
  .stt-market-table-with-volume td:nth-child(2) {
    width: 125px !important;
    max-width: 125px !important;
    text-align: left !important;
  }

  .market-name-cell {
    gap: 6px !important;
    min-width: 0 !important;
  }

  .coin-logo,
  .market-coin-logo-wrap {
    width: 27px !important;
    height: 27px !important;
    min-width: 27px !important;
  }

  .rank-symbol {
    font-size: 12.2px !important;
    line-height: 1.15 !important;
    font-weight: 900 !important;
  }

  .rank-name {
    font-size: 9.8px !important;
    max-width: 66px !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  /* Price visible */
  .stt-market-table-with-volume th:nth-child(3),
  .stt-market-table-with-volume td:nth-child(3) {
    width: 84px !important;
    min-width: 84px !important;
    text-align: right !important;
    padding-right: 4px !important;
  }

  /* 24H Change visible */
  .stt-market-table-with-volume th:nth-child(4),
  .stt-market-table-with-volume td:nth-child(4) {
    display: table-cell !important;
    width: 86px !important;
    min-width: 86px !important;
    text-align: right !important;
    padding-right: 5px !important;
  }

  /* Volume only scroll side */
  .stt-market-table-with-volume th:nth-child(5),
  .stt-market-table-with-volume td:nth-child(5) {
    display: table-cell !important;
    width: 92px !important;
    min-width: 92px !important;
    text-align: right !important;
    padding-right: 6px !important;
  }

  .market-price-cell,
  .market-change-cell,
  .market-volume-cell {
    font-size: 11.6px !important;
    white-space: nowrap !important;
    font-variant-numeric: tabular-nums;
  }

  .stt-market-table-with-volume th {
    font-size: 8.8px !important;
    letter-spacing: 0 !important;
    white-space: nowrap !important;
  }
}

/* Ultra small browser viewport */
@media (max-width: 360px) {
  .stt-market-table-with-volume {
    min-width: 425px !important;
  }

  .stt-market-table-with-volume th:nth-child(2),
  .stt-market-table-with-volume td:nth-child(2) {
    width: 118px !important;
    max-width: 118px !important;
  }

  .rank-name {
    max-width: 60px !important;
  }

  .stt-market-table-with-volume th:nth-child(3),
  .stt-market-table-with-volume td:nth-child(3) {
    width: 82px !important;
    min-width: 82px !important;
  }

  .stt-market-table-with-volume th:nth-child(4),
  .stt-market-table-with-volume td:nth-child(4) {
    width: 84px !important;
    min-width: 84px !important;
  }

  .stt-market-table-with-volume th:nth-child(5),
  .stt-market-table-with-volume td:nth-child(5) {
    width: 88px !important;
    min-width: 88px !important;
  }
}

/* STT STEP45.38 EXTRA SMALL PHONE MARKET FIT END */


/* STT STEP45.46 STATUS TOGGLE POSITION CSS START */

/*
  Mobile Dashboard Status button:
  - same jagah rahega
  - sticky/fixed nahi hoga
  - status cards button ke niche open/hide honge
*/
@media (max-width: 760px) {
  #mobileStatusAccordionToggle,
  #mobileStatusAccordionToggle.stt-status-toggle-fixed-place {
    position: relative !important;
    top: auto !important;
    bottom: auto !important;
    left: auto !important;
    right: auto !important;
    z-index: 1 !important;
    order: 2 !important;
    width: 100% !important;
    margin: 14px 0 14px 0 !important;
    transform: none !important;
  }

  body.mobile-status-expanded #mobileStatusAccordionToggle,
  body.mobile-status-collapsed #mobileStatusAccordionToggle {
    position: relative !important;
    margin: 14px 0 14px 0 !important;
    transform: none !important;
  }

  /* Status cards toggle ke niche normal flow me */
  .mobile-overview-item {
    order: 3 !important;
  }

  body.mobile-status-collapsed .mobile-overview-item {
    display: none !important;
  }

  body.mobile-status-expanded .mobile-overview-item {
    display: block !important;
  }

  /* Onboarding checklist status accordion ka part nahi hai */
  #onboardingCard,
  #onboardingCard .onboarding-step {
    display: block;
  }
}

/* STT STEP45.46 STATUS TOGGLE POSITION CSS END */


/* STT STEP45.47 MOBILE ONBOARDING CHECKLIST TOGGLE CSS START */

/* Desktop par ye button hide rahega */
.mobile-onboarding-checklist-toggle {
  display: none;
}

@media (max-width: 760px) {
  .mobile-onboarding-checklist-toggle {
    width: 100%;
    border: 1px solid rgba(34, 211, 238, 0.34);
    border-radius: 18px;
    background:
      radial-gradient(circle at 18% 20%, rgba(34, 211, 238, 0.22), transparent 34%),
      linear-gradient(135deg, rgba(8, 47, 73, 0.92), rgba(79, 70, 229, 0.34), rgba(15, 23, 42, 0.96));
    color: #e8fbff;
    display: flex !important;
    align-items: center;
    gap: 12px;
    padding: 14px 14px;
    margin: 18px 0 14px 0;
    text-align: left;
    box-shadow:
      inset 0 1px 0 rgba(255,255,255,0.08),
      0 12px 28px rgba(0,0,0,0.22),
      0 0 20px rgba(34,211,238,0.10);
  }

  .mobile-onboarding-checklist-toggle .mobile-checklist-toggle-icon {
    width: 42px;
    height: 42px;
    min-width: 42px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #22d3ee, #7c3aed);
    box-shadow: 0 0 22px rgba(34,211,238,0.26);
    font-size: 20px;
  }

  .mobile-onboarding-checklist-toggle span:nth-child(2) {
    display: flex;
    flex-direction: column;
    min-width: 0;
    flex: 1;
  }

  .mobile-onboarding-checklist-toggle b {
    font-size: 16px;
    line-height: 1.15;
    font-weight: 900;
  }

  .mobile-onboarding-checklist-toggle small {
    color: #a9bad6;
    font-size: 12.5px;
    line-height: 1.25;
    margin-top: 3px;
  }

  .mobile-onboarding-checklist-toggle em {
    width: 38px;
    height: 38px;
    min-width: 38px;
    border-radius: 14px;
    background: rgba(148, 163, 184, 0.12);
    color: #eaf6ff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-style: normal;
    font-size: 18px;
    font-weight: 900;
  }

  #onboardingCard.onboarding-checklist-collapsed .onboarding-steps {
    display: none !important;
  }

  #onboardingCard:not(.onboarding-checklist-collapsed) .onboarding-steps {
    display: grid !important;
  }
}

/* STT STEP45.47 MOBILE ONBOARDING CHECKLIST TOGGLE CSS END */


/* STT STEP45.48 PREMIUM UPGRADE ACTION ICONS START */

.upgrade-main-action,
.upgrade-secondary-action {
  position: relative;
  overflow: hidden;
}

.upgrade-action-icon {
  width: 32px;
  height: 32px;
  min-width: 32px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
  background:
    radial-gradient(circle at 30% 20%, rgba(255,255,255,.32), transparent 35%),
    linear-gradient(135deg, rgba(34, 211, 238, .96), rgba(124, 58, 237, .94));
  box-shadow:
    0 0 22px rgba(34, 211, 238, .28),
    inset 0 1px 0 rgba(255,255,255,.25);
}

.upgrade-action-icon::before,
.upgrade-action-icon::after {
  content: "";
  position: absolute;
  display: block;
}

/* Submit Access Request: premium arrow/launch icon */
.upgrade-action-icon.icon-request::before {
  width: 14px;
  height: 14px;
  border-top: 3px solid #ffffff;
  border-right: 3px solid #ffffff;
  transform: rotate(-45deg);
  top: 9px;
  left: 9px;
  border-radius: 2px;
}

.upgrade-action-icon.icon-request::after {
  width: 4px;
  height: 15px;
  background: #ffffff;
  border-radius: 999px;
  top: 11px;
  left: 14px;
  transform: rotate(45deg);
  box-shadow: 0 0 10px rgba(255,255,255,.45);
}

/* Copy Message: premium document/copy icon */
.upgrade-action-icon.icon-copy::before {
  width: 13px;
  height: 16px;
  border: 2px solid #ffffff;
  border-radius: 4px;
  top: 8px;
  left: 11px;
  background: rgba(255,255,255,.10);
}

.upgrade-action-icon.icon-copy::after {
  width: 13px;
  height: 16px;
  border: 2px solid rgba(255,255,255,.72);
  border-radius: 4px;
  top: 5px;
  left: 8px;
  background: rgba(255,255,255,.05);
}

/* View My Plan: premium user/card icon */
.upgrade-action-icon.icon-plan::before {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: #ffffff;
  top: 7px;
  left: 11.5px;
  box-shadow: 0 0 10px rgba(255,255,255,.45);
}

.upgrade-action-icon.icon-plan::after {
  width: 18px;
  height: 9px;
  border-radius: 999px 999px 6px 6px;
  background: #ffffff;
  top: 18px;
  left: 7px;
}

/* Button hover polish */
.upgrade-main-action:hover .upgrade-action-icon,
.upgrade-secondary-action:hover .upgrade-action-icon {
  transform: translateY(-1px) scale(1.04);
  box-shadow:
    0 0 30px rgba(34, 211, 238, .38),
    inset 0 1px 0 rgba(255,255,255,.30);
}

.upgrade-main-action strong,
.upgrade-secondary-action strong {
  letter-spacing: .15px;
}

/* Mobile: keep icon clean but compact */
@media (max-width: 640px) {
  .upgrade-action-icon {
    width: 30px;
    height: 30px;
    min-width: 30px;
    border-radius: 11px;
  }
}

/* STT STEP45.48 PREMIUM UPGRADE ACTION ICONS END */


/* STT STEP45.50 TARGETED SETTINGS BUTTON POLISH START */

/*
  Target only:
  - Send Screenshot on WhatsApp
  - View Get Pro
  Do not affect Open Bot Center or other Settings buttons.
*/

/* Premium style for Send Screenshot on WhatsApp */
button[onclick*="wa.me"],
a[href*="wa.me"].settings-action-btn,
button:has-text("Send Screenshot on WhatsApp") {
  border: 1px solid rgba(37, 211, 102, 0.42) !important;
  background:
    radial-gradient(circle at 18% 18%, rgba(37, 211, 102, 0.24), transparent 34%),
    linear-gradient(135deg, rgba(7, 94, 84, 0.96), rgba(18, 140, 126, 0.74), rgba(15, 23, 42, 0.98)) !important;
  color: #eafff3 !important;
  font-weight: 950 !important;
  letter-spacing: .2px !important;
  box-shadow:
    0 14px 34px rgba(37, 211, 102, 0.16),
    inset 0 1px 0 rgba(255,255,255,0.10) !important;
}

/* Safer class-style fallback: second button in Pro activation action row */
.settings-card .pro-action-row button:nth-child(2),
.get-pro-card .pro-action-row button:nth-child(2),
.pro-plan-card .pro-action-row button:nth-child(2) {
  border: 1px solid rgba(37, 211, 102, 0.42) !important;
  background:
    radial-gradient(circle at 18% 18%, rgba(37, 211, 102, 0.24), transparent 34%),
    linear-gradient(135deg, rgba(7, 94, 84, 0.96), rgba(18, 140, 126, 0.74), rgba(15, 23, 42, 0.98)) !important;
  color: #eafff3 !important;
  font-weight: 950 !important;
  box-shadow:
    0 14px 34px rgba(37, 211, 102, 0.16),
    inset 0 1px 0 rgba(255,255,255,0.10) !important;
}

/* Premium style for View Get Pro only */
button[onclick*="getPro"],
button[onclick*="Get Pro"],
button[onclick*="showGetPro"],
button[onclick*="showPage('settings')"][data-action="get-pro"],
button.view-get-pro-btn,
a.view-get-pro-btn {
  border: 1px solid rgba(34, 211, 238, 0.40) !important;
  background:
    radial-gradient(circle at 18% 18%, rgba(34,211,238,.20), transparent 34%),
    linear-gradient(135deg, rgba(8, 47, 73, .94), rgba(59, 130, 246, .34), rgba(124, 58, 237, .32)) !important;
  color: #e8fbff !important;
  font-weight: 950 !important;
  letter-spacing: .2px !important;
  box-shadow:
    0 12px 28px rgba(0,0,0,.24),
    0 0 22px rgba(34,211,238,.10),
    inset 0 1px 0 rgba(255,255,255,.08) !important;
}

/* Text-based fallback using JS-added class will be applied below */
.stt-target-whatsapp-btn {
  border: 1px solid rgba(37, 211, 102, 0.42) !important;
  background:
    radial-gradient(circle at 18% 18%, rgba(37, 211, 102, 0.24), transparent 34%),
    linear-gradient(135deg, rgba(7, 94, 84, 0.96), rgba(18, 140, 126, 0.74), rgba(15, 23, 42, 0.98)) !important;
  color: #eafff3 !important;
  font-weight: 950 !important;
  box-shadow:
    0 14px 34px rgba(37, 211, 102, 0.16),
    inset 0 1px 0 rgba(255,255,255,0.10) !important;
}

.stt-target-getpro-btn {
  border: 1px solid rgba(34, 211, 238, 0.40) !important;
  background:
    radial-gradient(circle at 18% 18%, rgba(34,211,238,.20), transparent 34%),
    linear-gradient(135deg, rgba(8, 47, 73, .94), rgba(59, 130, 246, .34), rgba(124, 58, 237, .32)) !important;
  color: #e8fbff !important;
  font-weight: 950 !important;
  box-shadow:
    0 12px 28px rgba(0,0,0,.24),
    0 0 22px rgba(34,211,238,.10),
    inset 0 1px 0 rgba(255,255,255,.08) !important;
}

.stt-target-whatsapp-btn,
.stt-target-getpro-btn {
  min-height: 52px !important;
  border-radius: 15px !important;
  transition: transform .18s ease, box-shadow .18s ease, filter .18s ease !important;
}

.stt-target-whatsapp-btn:hover,
.stt-target-getpro-btn:hover {
  transform: translateY(-2px);
  filter: brightness(1.08);
}

.stt-target-whatsapp-btn:active,
.stt-target-getpro-btn:active {
  transform: translateY(0) scale(.985);
}

/* STT STEP45.50 TARGETED SETTINGS BUTTON POLISH END */


/* STT STEP45.52 REAL EXCHANGE CAROUSEL CSS START */

.stt-exchange-carousel-real-grid {
  width: 100%;
}

.stt-exchange-carousel-real-track {
  display: grid;
  grid-template-columns: repeat(3, minmax(160px, 1fr));
  gap: 14px;
}

.stt-exchange-carousel-real-card {
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 22px;
  background:
    radial-gradient(circle at 20% 10%, rgba(34,211,238,.14), transparent 36%),
    linear-gradient(135deg, rgba(15, 23, 42, .92), rgba(30, 41, 80, .86));
  padding: 18px;
  color: #fff;
  text-align: center;
  cursor: pointer;
  min-height: 210px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.08);
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.stt-exchange-carousel-real-card.active {
  border-color: rgba(34, 211, 238, .70);
  box-shadow:
    0 0 0 1px rgba(34,211,238,.22),
    0 18px 38px rgba(34,211,238,.12),
    inset 0 1px 0 rgba(255,255,255,.10);
}

.stt-exchange-logo-box {
  border: 1px solid rgba(148, 163, 184, .20);
  border-radius: 18px;
  background: rgba(255,255,255,.06);
  min-height: 82px;
  display: grid;
  place-items: center;
  margin-bottom: 16px;
}

.stt-exchange-logo-box img {
  max-width: 74px;
  max-height: 52px;
  object-fit: contain;
}

.stt-exchange-card-title {
  font-size: 20px;
  font-weight: 950;
  margin-bottom: 12px;
}

.stt-exchange-card-pill {
  display: inline-flex;
  border: 1px solid rgba(34,211,238,.36);
  border-radius: 999px;
  background: rgba(34,211,238,.10);
  color: #67e8f9;
  padding: 7px 12px;
  font-weight: 900;
  margin-bottom: 8px;
}

.stt-exchange-card-pill.active {
  border-color: rgba(34,197,94,.46);
  background: rgba(34,197,94,.12);
  color: #86efac;
}

.stt-exchange-carousel-real-card small {
  display: block;
  color: #aabbd6;
  font-size: 13px;
}

.stt-exchange-carousel-real-dots {
  display: none;
}

.stt-selected-exchange-coming-soon-real {
  border: 1px solid rgba(34, 211, 238, 0.24);
  border-radius: 20px;
  background:
    radial-gradient(circle at 15% 10%, rgba(34, 211, 238, 0.14), transparent 35%),
    linear-gradient(135deg, rgba(8, 47, 73, 0.78), rgba(15, 23, 42, 0.95));
  padding: 20px;
  margin-top: 16px;
}

.stt-selected-exchange-coming-soon-real.hidden {
  display: none !important;
}

.stt-selected-exchange-badge-real {
  display: inline-flex;
  border: 1px solid rgba(34, 211, 238, 0.35);
  border-radius: 999px;
  color: #67e8f9;
  font-weight: 900;
  padding: 7px 12px;
  margin-bottom: 12px;
  background: rgba(34, 211, 238, 0.10);
}

.stt-selected-exchange-coming-soon-real h3 {
  color: #ffffff;
  font-size: 22px;
  margin: 0 0 8px 0;
}

.stt-selected-exchange-coming-soon-real p {
  color: #aabbd6;
  margin: 0 0 16px 0;
  line-height: 1.45;
}

.stt-selected-exchange-coming-soon-real button {
  border: 1px solid rgba(34, 211, 238, 0.42);
  border-radius: 14px;
  background: linear-gradient(135deg, #22d3ee, #3b82f6, #7c3aed);
  color: #fff;
  padding: 13px 18px;
  font-weight: 950;
}

@media (max-width: 760px) {
  .stt-exchange-carousel-real-grid {
    overflow: hidden !important;
  }

  .stt-exchange-carousel-real-track {
    display: flex !important;
    grid-template-columns: none !important;
    flex-wrap: nowrap !important;
    gap: 14px !important;
    overflow-x: auto !important;
    overflow-y: hidden !important;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    padding: 8px 4px 12px 4px !important;
    margin: 0 -2px !important;
  }

  .stt-exchange-carousel-real-track::-webkit-scrollbar {
    height: 0;
  }

  .stt-exchange-carousel-real-card {
    flex: 0 0 86% !important;
    max-width: 86% !important;
    min-width: 86% !important;
    min-height: 230px;
    scroll-snap-align: center;
  }

  .stt-exchange-carousel-real-dots {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 7px;
    padding: 2px 0 8px 0;
  }

  .stt-exchange-carousel-real-dots button {
    width: 8px;
    height: 8px;
    border-radius: 999px;
    border: 0;
    padding: 0;
    background: rgba(148, 163, 184, 0.35);
    box-shadow: none;
  }

  .stt-exchange-carousel-real-dots button.active {
    width: 24px;
    background: linear-gradient(135deg, #22d3ee, #7c3aed);
    box-shadow: 0 0 14px rgba(34, 211, 238, .32);
  }
}

/* STT STEP45.52 REAL EXCHANGE CAROUSEL CSS END */


/* STT STEP45.60 CLEAN EXCHANGE SELECT CSS START */

.stt-hide-direct-binance-api-4560,
body.stt-non-binance-selected-4560 .binance-api-select-card {
  display: none !important;
  visibility: hidden !important;
  height: 0 !important;
  min-height: 0 !important;
  max-height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  overflow: hidden !important;
  pointer-events: none !important;
}

.stt-selected-exchange-coming-soon-real.hidden {
  display: none !important;
}

.stt-selected-exchange-coming-soon-real:not(.hidden) {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
}

.stt-exchange-carousel-real-grid,
.stt-exchange-carousel-real-dots {
  display: block !important;
}

.stt-exchange-carousel-real-track {
  display: flex !important;
}

.stt-exchange-carousel-real-dots {
  width: 100% !important;
  justify-content: center !important;
  align-items: center !important;
  gap: 8px !important;
  padding: 12px 0 14px 0 !important;
  margin: 0 auto !important;
  text-align: center !important;
}

.stt-exchange-carousel-real-dots button {
  width: 9px !important;
  height: 9px !important;
  border-radius: 999px !important;
  border: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  background: rgba(148, 163, 184, 0.34) !important;
  opacity: 0.72 !important;
  transition: width .2s ease, opacity .2s ease, background .2s ease, box-shadow .2s ease !important;
}

.stt-exchange-carousel-real-dots button.active {
  width: 28px !important;
  opacity: 1 !important;
  background: linear-gradient(135deg, #22d3ee, #7c3aed) !important;
  box-shadow: 0 0 18px rgba(34, 211, 238, .42) !important;
}

/* STT STEP45.60 CLEAN EXCHANGE SELECT CSS END */


/* STT STEP45.61 MOBILE BINANCE API ACCORDION CSS START */

.stt-mobile-api-card-toggle {
  display: none;
}

@media (max-width: 760px) {
  .binance-api-select-card.stt-mobile-api-accordion-card {
    padding: 14px !important;
  }

  .stt-mobile-api-card-toggle {
    width: 100%;
    border: 1px solid rgba(34, 211, 238, 0.36);
    border-radius: 18px;
    background:
      radial-gradient(circle at 18% 18%, rgba(34, 211, 238, 0.20), transparent 34%),
      linear-gradient(135deg, rgba(8, 47, 73, 0.94), rgba(59, 130, 246, 0.30), rgba(124, 58, 237, 0.26));
    color: #e8fbff;
    display: flex !important;
    align-items: center;
    gap: 12px;
    padding: 14px;
    text-align: left;
    box-shadow:
      inset 0 1px 0 rgba(255,255,255,0.08),
      0 12px 28px rgba(0,0,0,0.22),
      0 0 20px rgba(34,211,238,0.10);
  }

  .stt-mobile-api-toggle-icon {
    width: 42px;
    height: 42px;
    min-width: 42px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #22d3ee, #7c3aed);
    box-shadow: 0 0 22px rgba(34,211,238,0.26);
    font-size: 18px;
  }

  .stt-mobile-api-toggle-text {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
  }

  .stt-mobile-api-toggle-text b {
    font-size: 16px;
    line-height: 1.15;
    font-weight: 950;
  }

  .stt-mobile-api-toggle-text small {
    color: #a9bad6;
    font-size: 12.5px;
    line-height: 1.25;
    margin-top: 3px;
  }

  .stt-mobile-api-card-toggle em {
    width: 38px;
    height: 38px;
    min-width: 38px;
    border-radius: 14px;
    background: rgba(148, 163, 184, 0.12);
    color: #eaf6ff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-style: normal;
    font-size: 18px;
    font-weight: 900;
  }

  /* Collapsed state: hide original card content except toggle */
  .binance-api-select-card.stt-mobile-api-card-collapsed > :not(.stt-mobile-api-card-toggle) {
    display: none !important;
  }

  .binance-api-select-card.stt-mobile-api-card-open > :not(.stt-mobile-api-card-toggle) {
    display: revert;
  }

  .binance-api-select-card.stt-mobile-api-card-open .card-header {
    display: flex !important;
    margin-top: 14px;
  }

  .binance-api-select-card.stt-mobile-api-card-open .warning-box,
  .binance-api-select-card.stt-mobile-api-card-open .form,
  .binance-api-select-card.stt-mobile-api-card-open .status-compact,
  .binance-api-select-card.stt-mobile-api-card-open .exchange-balance-box {
    display: block !important;
  }

  .binance-api-select-card.stt-mobile-api-card-open .form {
    display: grid !important;
  }

  /* Non-Binance selected ho to accordion bhi hide rahe */
  body.stt-non-binance-selected-4560 .binance-api-select-card,
  body.stt-non-binance-exchange-selected-4558 .binance-api-select-card,
  body.stt-non-binance-exchange-selected .binance-api-select-card {
    display: none !important;
  }
}

/* STT STEP45.61 MOBILE BINANCE API ACCORDION CSS END */


/* STT STEP45.62 DESKTOP EXCHANGE GRID RESTORE START */

/*
  Desktop/PC: old grid-style Supported Exchanges.
  Mobile: Step 45 carousel remains active.
*/
@media (min-width: 761px) {
  .stt-exchange-carousel-real-grid {
    width: 100% !important;
    overflow: visible !important;
  }

  .stt-exchange-carousel-real-track {
    display: grid !important;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)) !important;
    gap: 14px !important;
    overflow: visible !important;
    padding: 0 !important;
    margin: 0 !important;
    scroll-snap-type: none !important;
  }

  .stt-exchange-carousel-real-card {
    min-width: 0 !important;
    max-width: none !important;
    width: 100% !important;
    flex: none !important;
    min-height: 190px !important;
    padding: 16px 14px !important;
    scroll-snap-align: none !important;
  }

  .stt-exchange-carousel-real-dots {
    display: none !important;
  }

  .stt-exchange-logo-box {
    min-height: 72px !important;
    margin-bottom: 14px !important;
  }

  .stt-exchange-logo-box img {
    max-width: 68px !important;
    max-height: 48px !important;
  }

  .stt-exchange-card-title {
    font-size: 18px !important;
    margin-bottom: 10px !important;
  }

  .stt-exchange-card-pill {
    padding: 6px 11px !important;
    font-size: 12px !important;
  }

  .stt-exchange-carousel-real-card small {
    font-size: 12px !important;
  }

  /* Desktop par Binance API cards normal full card jaise rahenge */
  .binance-api-select-card {
    display: block;
    visibility: visible;
    height: auto;
    min-height: initial;
    max-height: none;
    overflow: visible;
    pointer-events: auto;
  }

  .stt-mobile-api-card-toggle {
    display: none !important;
  }

  .binance-api-select-card > :not(.stt-mobile-api-card-toggle) {
    display: revert;
  }

  .binance-api-select-card .card-header {
    display: flex !important;
  }

  .binance-api-select-card .form {
    display: grid !important;
  }
}

/* STT STEP45.62 DESKTOP EXCHANGE GRID RESTORE END */


/* STT STEP45.64 SIGNAL COLUMN ALIGNMENT SAFE CSS START */

/*
  Signal Center table:
  - Do NOT use table-layout: fixed, it mixes Pair/Side columns.
  - Keep natural layout, but set stable min widths to reduce refresh shake.
*/

.stt-signal-monitor-stable-card {
  overflow-anchor: none !important;
}

.stt-signal-scroll-stable-box {
  overflow-anchor: none !important;
  scroll-behavior: auto !important;
  overscroll-behavior: contain;
}

.stt-signal-scroll-stable-box table {
  table-layout: auto !important;
  width: 100% !important;
  min-width: 980px !important;
  border-collapse: collapse;
}

.stt-signal-scroll-stable-box th,
.stt-signal-scroll-stable-box td {
  white-space: nowrap !important;
  vertical-align: middle !important;
  font-variant-numeric: tabular-nums;
}

/* Pair column */
.stt-signal-scroll-stable-box th:nth-child(1),
.stt-signal-scroll-stable-box td:nth-child(1) {
  min-width: 170px !important;
  width: 170px !important;
  text-align: left !important;
}

/* Side */
.stt-signal-scroll-stable-box th:nth-child(2),
.stt-signal-scroll-stable-box td:nth-child(2) {
  min-width: 90px !important;
  width: 90px !important;
  text-align: center !important;
}

/* Mode */
.stt-signal-scroll-stable-box th:nth-child(3),
.stt-signal-scroll-stable-box td:nth-child(3) {
  min-width: 90px !important;
  width: 90px !important;
  text-align: center !important;
}

/* Status */
.stt-signal-scroll-stable-box th:nth-child(4),
.stt-signal-scroll-stable-box td:nth-child(4) {
  min-width: 95px !important;
  width: 95px !important;
  text-align: center !important;
}

/* Amount */
.stt-signal-scroll-stable-box th:nth-child(5),
.stt-signal-scroll-stable-box td:nth-child(5) {
  min-width: 85px !important;
  width: 85px !important;
  text-align: right !important;
}

/* Qty */
.stt-signal-scroll-stable-box th:nth-child(6),
.stt-signal-scroll-stable-box td:nth-child(6) {
  min-width: 70px !important;
  width: 70px !important;
  text-align: right !important;
}

/* Entry */
.stt-signal-scroll-stable-box th:nth-child(7),
.stt-signal-scroll-stable-box td:nth-child(7) {
  min-width: 100px !important;
  width: 100px !important;
  text-align: right !important;
}

/* Current */
.stt-signal-scroll-stable-box th:nth-child(8),
.stt-signal-scroll-stable-box td:nth-child(8) {
  min-width: 100px !important;
  width: 100px !important;
  text-align: right !important;
}

/* PnL */
.stt-signal-scroll-stable-box th:nth-child(9),
.stt-signal-scroll-stable-box td:nth-child(9) {
  min-width: 75px !important;
  width: 75px !important;
  text-align: right !important;
}

/* Time */
.stt-signal-scroll-stable-box th:nth-child(10),
.stt-signal-scroll-stable-box td:nth-child(10) {
  min-width: 105px !important;
  width: 105px !important;
  text-align: center !important;
}

/* Manage */
.stt-signal-scroll-stable-box th:nth-child(11),
.stt-signal-scroll-stable-box td:nth-child(11) {
  min-width: 80px !important;
  width: 80px !important;
  text-align: center !important;
}

/* Keep row height stable without forcing wrong layout */
.stt-signal-scroll-stable-box tbody tr {
  height: 54px !important;
}

/* Pair cell content should not overlap into Side column */
.stt-signal-scroll-stable-box td:first-child {
  overflow: hidden !important;
}

.stt-signal-scroll-stable-box td:first-child b,
.stt-signal-scroll-stable-box td:first-child span,
.stt-signal-scroll-stable-box td:first-child small,
.stt-signal-scroll-stable-box td:first-child div {
  max-width: 145px !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}

/* Keep badge pills compact and centered */
.stt-signal-scroll-stable-box .pill,
.stt-signal-scroll-stable-box .badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* STT STEP45.64 SIGNAL COLUMN ALIGNMENT SAFE CSS END */


/* STT STEP45.65 SIGNAL NO SHAKE CSS START */

/* Do not animate table/card during auto refresh */
.stt-signal-monitor-stable-card,
.stt-signal-monitor-stable-card *,
.stt-signal-no-shake-box,
.stt-signal-no-shake-box * {
  scroll-behavior: auto !important;
}

.stt-signal-no-shake-box table,
.stt-signal-no-shake-box tr,
.stt-signal-no-shake-box td,
.stt-signal-no-shake-box th {
  transition: none !important;
  animation: none !important;
}

/* Keep natural column layout from Step45.64 */
.stt-signal-no-shake-box table {
  table-layout: auto !important;
}

/* Prevent browser scroll anchoring from moving the card */
.stt-signal-monitor-stable-card,
.stt-signal-no-shake-box {
  overflow-anchor: none !important;
}

/* STT STEP45.65 SIGNAL NO SHAKE CSS END */


/* STT STEP45.66 SIGNAL INPLACE STABLE CSS START */

/* Prevent visual wobble when only values update */
.stt-signal-table {
  border-collapse: collapse;
}

.stt-signal-table td,
.stt-signal-table th {
  transition: none !important;
  animation: none !important;
  font-variant-numeric: tabular-nums;
}

/* Keep numeric columns steady */
.stt-signal-table td.num {
  min-width: 78px;
  text-align: right;
}

/* Current/Entry/PnL columns stable */
.stt-signal-table td:nth-child(7),
.stt-signal-table td:nth-child(8),
.stt-signal-table td:nth-child(9) {
  min-width: 88px;
  text-align: right;
}

/* Time stable */
.stt-signal-table td:nth-child(10) {
  min-width: 95px;
  text-align: center;
}

/* Pair cell does not push Side column */
.stt-signal-table .stt-pair-cell {
  max-width: 170px;
  overflow: hidden;
}

.stt-signal-table .stt-pair-cell b,
.stt-signal-table .stt-pair-cell small {
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* STT STEP45.66 SIGNAL INPLACE STABLE CSS END */


/* STT STEP45.75 FINAL EXACT BOT GRID CAROUSEL CSS START */

.stt-bot-grid-dots-4575 {
  display: none;
}

@media (max-width: 760px) {
  /* Category tabs clean horizontal scroll */
  #page-bots .bot-tabs {
    display: flex !important;
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    overflow-y: hidden !important;
    gap: 10px !important;
    width: 100% !important;
    max-width: 100% !important;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 10px !important;
  }

  #page-bots .bot-tabs::-webkit-scrollbar {
    height: 0;
  }

  #page-bots .bot-tab {
    flex: 0 0 auto !important;
    white-space: nowrap !important;
  }

  /* Only exact result grid becomes carousel */
  #page-bots .bot-results-area {
    width: 100% !important;
    max-width: 100% !important;
    overflow: hidden !important;
  }

  #page-bots .bot-results-area .bot-grid.stt-exact-bot-grid-carousel-4575 {
    display: flex !important;
    grid-template-columns: none !important;
    flex-wrap: nowrap !important;
    gap: 14px !important;
    overflow-x: auto !important;
    overflow-y: visible !important;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    padding: 8px 4px 14px 4px !important;
    margin: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  #page-bots .bot-results-area .bot-grid.stt-exact-bot-grid-carousel-4575::-webkit-scrollbar {
    height: 0;
  }

  #page-bots .bot-results-area .bot-grid.stt-exact-bot-grid-carousel-4575 > .bot-card.stt-exact-bot-slide-4575 {
    flex: 0 0 calc(100vw - 84px) !important;
    width: calc(100vw - 84px) !important;
    min-width: calc(100vw - 84px) !important;
    max-width: calc(100vw - 84px) !important;
    scroll-snap-align: center !important;
    align-self: flex-start !important;
    margin: 0 !important;
    padding: 16px !important;
    height: auto !important;
    min-height: 0 !important;
    max-height: none !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
  }

  #page-bots .bot-results-area .bot-grid.stt-exact-bot-grid-carousel-4575 > .bot-card.stt-active-bot-slide-4575 {
    border-color: rgba(34, 211, 238, 0.62) !important;
    box-shadow:
      0 0 0 1px rgba(34,211,238,.18),
      0 18px 38px rgba(34,211,238,.10),
      inset 0 1px 0 rgba(255,255,255,.08) !important;
  }

  .stt-bot-grid-dots-4575 {
    display: flex !important;
    justify-content: center;
    align-items: center;
    gap: 8px;
    padding: 4px 0 12px 0;
    margin: 0 auto 10px auto;
  }

  .stt-bot-grid-dots-4575 button {
    width: 9px;
    height: 9px;
    border-radius: 999px;
    border: 0;
    padding: 0;
    margin: 0;
    background: rgba(148, 163, 184, 0.34);
    opacity: .72;
    transition: width .2s ease, opacity .2s ease, background .2s ease, box-shadow .2s ease;
  }

  .stt-bot-grid-dots-4575 button.active {
    width: 28px;
    opacity: 1;
    background: linear-gradient(135deg, #22d3ee, #7c3aed);
    box-shadow: 0 0 18px rgba(34, 211, 238, .42);
  }

  /* Compact professional bot card layout */
  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-top {
    display: grid !important;
    grid-template-columns: 1fr auto !important;
    gap: 10px !important;
    align-items: start !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-name {
    display: grid !important;
    grid-template-columns: 54px minmax(0, 1fr) !important;
    gap: 12px !important;
    align-items: start !important;
    min-width: 0 !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-logo-wrap {
    width: 54px !important;
    height: 54px !important;
    min-width: 54px !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-title-wrap {
    min-width: 0 !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-title-row {
    display: block !important;
    min-width: 0 !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-title {
    font-size: 19px !important;
    line-height: 1.14 !important;
    max-width: 150px !important;
    margin: 0 0 4px 0 !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-badge-stack {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 5px !important;
    margin: 0 0 7px 0 !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-badge-stack .pill,
  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-badge-stack .badge,
  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-badge-stack span {
    max-width: 108px !important;
    font-size: 10.5px !important;
    padding: 5px 8px !important;
    white-space: nowrap !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .status-pill {
    max-width: 92px !important;
    font-size: 11px !important;
    padding: 6px 10px !important;
    white-space: nowrap !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-desc {
    font-size: 12px !important;
    line-height: 1.28 !important;
    max-width: 180px !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-symbol-pill,
  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-category-tag {
    font-size: 11px !important;
    padding: 6px 10px !important;
    max-width: 118px !important;
    white-space: nowrap !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-meta {
    gap: 9px !important;
    margin-top: 12px !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .meta-box {
    min-height: 52px !important;
    padding: 9px 10px !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-actions {
    gap: 10px !important;
    margin-top: 12px !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-actions button {
    min-height: 44px !important;
  }

  #botList {
    max-width: 100% !important;
    overflow-x: hidden !important;
  }
}

/* STT STEP45.75 FINAL EXACT BOT GRID CAROUSEL CSS END */


/* STT STEP45.76 MOBILE BOT CARD PROFESSIONAL CSS START */

@media (max-width: 760px) {
  /* Category tabs: selected tab center me aaye aur hidden na ho */
  #page-bots .bot-tabs {
    scroll-snap-type: x proximity;
    scroll-padding-inline: 42px;
  }

  #page-bots .bot-tab {
    scroll-snap-align: center;
  }

  #page-bots .bot-tab.active {
    box-shadow:
      0 0 0 1px rgba(34, 211, 238, 0.22),
      0 0 22px rgba(34, 211, 238, 0.18) !important;
  }

  /* Bot slider width thoda balanced */
  #page-bots .bot-results-area .bot-grid.stt-exact-bot-grid-carousel-4575 > .bot-card.stt-exact-bot-slide-4575 {
    flex-basis: calc(100vw - 92px) !important;
    width: calc(100vw - 92px) !important;
    min-width: calc(100vw - 92px) !important;
    max-width: calc(100vw - 92px) !important;
    padding: 14px !important;
  }

  /* Header layout: logo + info, status top-right; no overlap */
  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-top {
    display: block !important;
    position: relative !important;
    min-height: 118px !important;
    padding-right: 88px !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .status-pill {
    position: absolute !important;
    top: 0 !important;
    right: 0 !important;
    max-width: 82px !important;
    font-size: 10.5px !important;
    padding: 6px 9px !important;
    white-space: nowrap !important;
    z-index: 3 !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-name {
    display: grid !important;
    grid-template-columns: 52px minmax(0, 1fr) !important;
    gap: 11px !important;
    align-items: start !important;
    min-width: 0 !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-logo-wrap {
    width: 52px !important;
    height: 52px !important;
    min-width: 52px !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-title-wrap {
    min-width: 0 !important;
    padding-right: 0 !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-title-row {
    display: block !important;
    min-width: 0 !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-title {
    font-size: 18px !important;
    line-height: 1.15 !important;
    max-width: 145px !important;
    margin: 0 0 6px 0 !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-badge-stack {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 5px !important;
    margin: 0 0 7px 0 !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-badge-stack .pill,
  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-badge-stack .badge,
  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-badge-stack span {
    max-width: 105px !important;
    font-size: 10.5px !important;
    padding: 5px 8px !important;
    white-space: nowrap !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-desc {
    font-size: 11.8px !important;
    line-height: 1.25 !important;
    max-width: 150px !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden !important;
    margin-bottom: 7px !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-symbol-pill,
  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-category-tag {
    display: inline-flex !important;
    font-size: 10.8px !important;
    padding: 5px 9px !important;
    max-width: 112px !important;
    white-space: nowrap !important;
    margin: 2px 5px 2px 0 !important;
  }

  /* Meta area compact, card height kam */
  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-meta {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 8px !important;
    margin-top: 10px !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .meta-box {
    min-height: 46px !important;
    padding: 8px 10px !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .meta-label {
    font-size: 10.5px !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .meta-value {
    font-size: 12.8px !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-actions {
    gap: 8px !important;
    margin-top: 10px !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-actions button {
    min-height: 42px !important;
    font-size: 12.5px !important;
  }

  /* Dots smooth and clear */
  .stt-bot-grid-dots-4575 {
    gap: 7px !important;
    padding-top: 6px !important;
  }

  .stt-bot-grid-dots-4575 button {
    width: 8px !important;
    height: 8px !important;
  }

  .stt-bot-grid-dots-4575 button.active {
    width: 26px !important;
  }
}

/* STT STEP45.76 MOBILE BOT CARD PROFESSIONAL CSS END */


/* STT STEP45.80 FINAL MOBILE BOT HEADER CSS START */

/* Desktop: keep existing old bot header */
.stt-mobile-bot-head-final {
  display: none;
}

@media (max-width: 760px) {
  /* Mobile: use clean custom header, hide old congested header */
  #page-bots .bot-card.stt-exact-bot-slide-4575 > .bot-top {
    display: none !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .stt-mobile-bot-head-final {
    display: block !important;
    margin: 0 0 12px 0 !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .stt-mobile-bot-head-top {
    display: grid !important;
    grid-template-columns: 58px minmax(0, 1fr) 82px !important;
    gap: 12px !important;
    align-items: start !important;
    width: 100% !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .stt-mobile-bot-logo {
    width: 58px !important;
    height: 58px !important;
    min-width: 58px !important;
    border-radius: 18px !important;
    display: grid !important;
    place-items: center !important;
    background: rgba(15, 23, 42, 0.54) !important;
    border: 1px solid rgba(34, 211, 238, 0.22) !important;
    overflow: hidden !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .stt-mobile-bot-logo img {
    width: 36px !important;
    height: 36px !important;
    object-fit: contain !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .stt-mobile-bot-logo .bot-logo-fallback {
    width: 36px !important;
    height: 36px !important;
    display: none;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .stt-mobile-bot-main {
    min-width: 0 !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .stt-mobile-bot-title {
    font-size: 19px !important;
    line-height: 1.14 !important;
    font-weight: 950 !important;
    color: #f8fbff !important;
    margin: 0 0 6px 0 !important;
    white-space: normal !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .stt-mobile-bot-desc {
    font-size: 11.8px !important;
    line-height: 1.28 !important;
    color: rgba(226, 232, 240, 0.78) !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden !important;
    max-width: 100% !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .stt-mobile-bot-status {
    position: static !important;
    width: 82px !important;
    min-width: 82px !important;
    max-width: 82px !important;
    justify-content: center !important;
    text-align: center !important;
    font-size: 10.8px !important;
    padding: 6px 8px !important;
    white-space: nowrap !important;
    box-sizing: border-box !important;
  }

  /* Row layout: left item full left, right item full right */
  #page-bots .bot-card.stt-exact-bot-slide-4575 .stt-mobile-bot-row {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
    gap: 10px !important;
    align-items: center !important;
    width: 100% !important;
    margin-top: 8px !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .stt-mobile-bot-left,
  #page-bots .bot-card.stt-exact-bot-slide-4575 .stt-mobile-bot-right {
    min-width: 0 !important;
    width: 100% !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .stt-mobile-bot-left > *,
  #page-bots .bot-card.stt-exact-bot-slide-4575 .stt-mobile-bot-right > * {
    width: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
    display: inline-flex !important;
    justify-content: center !important;
    align-items: center !important;
    text-align: center !important;
    white-space: nowrap !important;
    overflow: visible !important;
    text-overflow: unset !important;
    box-sizing: border-box !important;
    font-size: 10.8px !important;
    line-height: 1.1 !important;
    padding: 6px 8px !important;
    margin: 0 !important;
  }

  /* Lower card content compact */
  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-meta {
    margin-top: 10px !important;
    gap: 8px !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .meta-box {
    min-height: 44px !important;
    padding: 8px 10px !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-actions {
    margin-top: 10px !important;
    gap: 8px !important;
  }

  #page-bots .bot-card.stt-exact-bot-slide-4575 .bot-actions button {
    min-height: 42px !important;
    font-size: 12.5px !important;
  }

  /* Hide duplicate small gear/text inside config button */
  #page-bots .bot-card.stt-exact-bot-slide-4575 button[onclick*="openBotConfig"] span,
  #page-bots .bot-card.stt-exact-bot-slide-4575 button[onclick*="openBotConfig"] svg + span {
    display: none !important;
  }
}

/* STT STEP45.80 FINAL MOBILE BOT HEADER CSS END */


/* STT STEP45.81 BOT SINGLE ACTIVE DOT CSS START */

@media (max-width: 760px) {
  #sttBotGridDots4575 {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 8px !important;
  }

  #sttBotGridDots4575 [data-bot-dot-4575] {
    width: 9px !important;
    height: 9px !important;
    min-width: 9px !important;
    border-radius: 999px !important;
    border: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    background: rgba(80, 96, 125, 0.58) !important;
    opacity: 0.72 !important;
    box-shadow: none !important;
    transition: width .18s ease, background .18s ease, opacity .18s ease, box-shadow .18s ease !important;
  }

  #sttBotGridDots4575 [data-bot-dot-4575].active {
    width: 28px !important;
    min-width: 28px !important;
    opacity: 1 !important;
    background: linear-gradient(135deg, #22d3ee, #7c3aed) !important;
    box-shadow: 0 0 18px rgba(34, 211, 238, .42) !important;
  }

  #sttBotGridDots4575 [data-bot-dot-4575].inactive {
    width: 9px !important;
    min-width: 9px !important;
    background: rgba(80, 96, 125, 0.58) !important;
    opacity: 0.72 !important;
    box-shadow: none !important;
  }
}

/* STT STEP45.81 BOT SINGLE ACTIVE DOT CSS END */


/* STT STEP45.82 PREMIUM BOT CATEGORY TABS CSS START */

@media (max-width: 760px) {
  #page-bots .bot-tabs {
    scroll-behavior: auto !important;
    scroll-snap-type: none !important;
    display: flex !important;
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    overflow-y: hidden !important;
    gap: 10px !important;
    padding: 10px 8px 12px 8px !important;
    max-width: 100% !important;
    -webkit-overflow-scrolling: touch;
  }

  #page-bots .bot-tabs::-webkit-scrollbar {
    height: 0 !important;
  }

  #page-bots .bot-tab {
    flex: 0 0 auto !important;
    scroll-snap-align: none !important;
    min-height: 48px !important;
    border-radius: 18px !important;
    padding: 0 18px !important;
    border: 1px solid rgba(148, 163, 184, 0.20) !important;
    background:
      radial-gradient(circle at 20% 15%, rgba(34,211,238,.10), transparent 34%),
      linear-gradient(135deg, rgba(15,23,42,.92), rgba(30,41,80,.72)) !important;
    color: rgba(226, 232, 240, 0.82) !important;
    font-weight: 900 !important;
    white-space: nowrap !important;
    box-shadow:
      inset 0 1px 0 rgba(255,255,255,.06),
      0 8px 22px rgba(0,0,0,.18) !important;
    transition: border-color .15s ease, filter .15s ease, box-shadow .15s ease, background .15s ease !important;
  }

  #page-bots .bot-tab.active {
    border-color: rgba(34, 211, 238, 0.70) !important;
    background:
      radial-gradient(circle at 22% 18%, rgba(255,255,255,.20), transparent 32%),
      linear-gradient(135deg, #0891b2 0%, #2563eb 48%, #7c3aed 100%) !important;
    color: #ffffff !important;
    box-shadow:
      0 0 0 1px rgba(34,211,238,.22),
      0 0 26px rgba(34,211,238,.22),
      0 14px 30px rgba(124,58,237,.18),
      inset 0 1px 0 rgba(255,255,255,.18) !important;
  }

  #page-bots .bot-tab:active {
    filter: brightness(1.10);
  }
}

/* STT STEP45.82 PREMIUM BOT CATEGORY TABS CSS END */


/* STT STEP45.83 DASHBOARD STATUS NO FLASH START */

/*
  Mobile Dashboard Status cards must stay hidden immediately after refresh.
  They should show only after user taps Dashboard Status toggle.
*/
@media (max-width: 760px) {
  /* Default first-paint hidden state */
  body:not(.mobile-status-expanded) .status-grid,
  body:not(.mobile-status-expanded) .dashboard-status-grid,
  body:not(.mobile-status-expanded) .dashboard-stats-grid,
  body:not(.mobile-status-expanded) .stats-grid,
  body:not(.mobile-status-expanded) .safety-grid,
  body:not(.mobile-status-expanded) .status-cards,
  body:not(.mobile-status-expanded) .dashboard-status-cards,
  body:not(.mobile-status-expanded) #dashboardStatusCards,
  body:not(.mobile-status-expanded) #dashboardStatsCards,
  body:not(.mobile-status-expanded) #statusCardsGrid {
    display: none !important;
    visibility: hidden !important;
    height: 0 !important;
    max-height: 0 !important;
    overflow: hidden !important;
    margin: 0 !important;
    padding: 0 !important;
    opacity: 0 !important;
    pointer-events: none !important;
  }

  /* Expanded state after Dashboard Status click */
  body.mobile-status-expanded .status-grid,
  body.mobile-status-expanded .dashboard-status-grid,
  body.mobile-status-expanded .dashboard-stats-grid,
  body.mobile-status-expanded .stats-grid,
  body.mobile-status-expanded .safety-grid,
  body.mobile-status-expanded .status-cards,
  body.mobile-status-expanded .dashboard-status-cards,
  body.mobile-status-expanded #dashboardStatusCards,
  body.mobile-status-expanded #dashboardStatsCards,
  body.mobile-status-expanded #statusCardsGrid {
    display: grid !important;
    visibility: visible !important;
    height: auto !important;
    max-height: none !important;
    overflow: visible !important;
    opacity: 1 !important;
    pointer-events: auto !important;
  }

  /* Toggle button always visible */
  #mobileStatusAccordionToggle,
  .mobile-status-accordion-toggle,
  .dashboard-status-toggle,
  .mobile-dashboard-status-toggle {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
  }
}

/* STT STEP45.83 DASHBOARD STATUS NO FLASH END */


/* STT STEP45.84 EXACT DASHBOARD STATUS NO FLASH START */

/*
  Exact mobile first-paint fix:
  These are the real dashboard status containers:
  - #topSafetyStrip
  - .stats-row
  Keep them hidden immediately after refresh until Dashboard Status is expanded.
*/
@media (max-width: 760px) {
  body:not(.mobile-status-expanded) #topSafetyStrip,
  body:not(.mobile-status-expanded) .production-safety-strip,
  body:not(.mobile-status-expanded) .stats-row {
    display: none !important;
    visibility: hidden !important;
    height: 0 !important;
    min-height: 0 !important;
    max-height: 0 !important;
    overflow: hidden !important;
    margin: 0 !important;
    padding: 0 !important;
    opacity: 0 !important;
    pointer-events: none !important;
  }

  body.mobile-status-expanded #topSafetyStrip,
  body.mobile-status-expanded .production-safety-strip {
    display: grid !important;
    visibility: visible !important;
    height: auto !important;
    min-height: initial !important;
    max-height: none !important;
    overflow: visible !important;
    margin: 0 0 7px 0 !important;
    opacity: 1 !important;
    pointer-events: auto !important;
  }

  body.mobile-status-expanded .stats-row {
    display: grid !important;
    visibility: visible !important;
    height: auto !important;
    min-height: initial !important;
    max-height: none !important;
    overflow: visible !important;
    margin: 0 0 14px 0 !important;
    opacity: 1 !important;
    pointer-events: auto !important;
  }

  #mobileStatusAccordionToggle,
  .mobile-status-accordion-toggle {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
  }
}

/* STT STEP45.84 EXACT DASHBOARD STATUS NO FLASH END */


/* STT STEP45.85 STRONG EXACT STATUS NO FLICKER CSS START */

@media (max-width: 760px) {
  html body:not(.mobile-status-expanded) #dashboardTop #topSafetyStrip,
  html body:not(.mobile-status-expanded) #dashboardTop .production-safety-strip,
  html body:not(.mobile-status-expanded) #dashboardTop .stats-row {
    display: none !important;
    visibility: hidden !important;
    height: 0 !important;
    min-height: 0 !important;
    max-height: 0 !important;
    overflow: hidden !important;
    margin: 0 !important;
    padding: 0 !important;
    opacity: 0 !important;
    pointer-events: none !important;
  }

  html body.mobile-status-expanded #dashboardTop #topSafetyStrip,
  html body.mobile-status-expanded #dashboardTop .production-safety-strip {
    display: grid !important;
    visibility: visible !important;
    height: auto !important;
    min-height: initial !important;
    max-height: none !important;
    overflow: visible !important;
    margin: 0 0 14px 0 !important;
    opacity: 1 !important;
    pointer-events: auto !important;
  }

  html body.mobile-status-expanded #dashboardTop .stats-row {
    display: grid !important;
    visibility: visible !important;
    height: auto !important;
    min-height: initial !important;
    max-height: none !important;
    overflow: visible !important;
    margin: 0 0 14px 0 !important;
    opacity: 1 !important;
    pointer-events: auto !important;
  }
}

/* STT STEP45.85 STRONG EXACT STATUS NO FLICKER CSS END */


/* STT STEP45.86 MOBILE FIRST PAINT NO GLITCH CSS START */

@media (max-width: 760px) {
  html.stt-mobile-first-paint-lock,
  html.stt-mobile-first-paint-lock body {
    scroll-behavior: auto !important;
    overflow-anchor: none !important;
  }

  html.stt-mobile-first-paint-lock *,
  html.stt-mobile-first-paint-lock *::before,
  html.stt-mobile-first-paint-lock *::after {
    transition: none !important;
    animation: none !important;
    scroll-behavior: auto !important;
  }

  /* During first paint, make status containers fully non-rendered */
  html.stt-mobile-first-paint-lock body:not(.mobile-status-expanded) #dashboardTop #topSafetyStrip,
  html.stt-mobile-first-paint-lock body:not(.mobile-status-expanded) #dashboardTop .production-safety-strip,
  html.stt-mobile-first-paint-lock body:not(.mobile-status-expanded) #dashboardTop .stats-row {
    display: none !important;
    visibility: hidden !important;
    height: 0 !important;
    min-height: 0 !important;
    max-height: 0 !important;
    overflow: hidden !important;
    margin: 0 !important;
    padding: 0 !important;
    opacity: 0 !important;
    pointer-events: none !important;
  }
}

/* STT STEP45.86 MOBILE FIRST PAINT NO GLITCH CSS END */


/* STT STEP45.87 MOBILE REFRESH STABLE CSS START */

@media (max-width: 760px) {
  html,
  body,
  #dashboardTop,
  .main {
    overflow-anchor: none !important;
  }

  html.stt-mobile-first-paint-lock #dashboardTop {
    transform: translateZ(0);
    backface-visibility: hidden;
  }
}

/* STT STEP45.87 MOBILE REFRESH STABLE CSS END */

/* STT STEP45.97 CLEAN EXACT DRAWER STATUS CSS START */

@media (max-width: 820px) {
  .mobile-drawer-status {
    display: grid !important;
    grid-template-columns: auto 1fr !important;
    column-gap: 10px !important;
    align-items: center !important;
    overflow: hidden !important;
  }

  .mobile-drawer-status span:first-child {
    width: 11px !important;
    height: 11px !important;
    min-width: 11px !important;
    border-radius: 50% !important;
    grid-row: span 2 !important;
  }

  .mobile-drawer-status b {
    display: block !important;
    font-size: 15px !important;
    line-height: 1.12 !important;
    font-weight: 950 !important;
    color: #ffffff !important;
    white-space: normal !important;
  }

  .mobile-drawer-status small {
    display: block !important;
    margin-top: 3px !important;
    font-size: 11.5px !important;
    line-height: 1.22 !important;
    font-weight: 700 !important;
    color: rgba(226,232,240,0.72) !important;
    white-space: normal !important;
  }

  .mobile-drawer-status.paper {
    background:
      radial-gradient(circle at 14% 50%, rgba(34,211,238,0.16), transparent 34%),
      linear-gradient(135deg, rgba(8,47,73,0.82), rgba(30,41,90,0.78)) !important;
    border-color: rgba(34,211,238,0.30) !important;
  }

  .mobile-drawer-status.paper span:first-child {
    background: #22d3ee !important;
    box-shadow: 0 0 14px rgba(34,211,238,0.60) !important;
  }

  .mobile-drawer-status.testnet {
    background:
      radial-gradient(circle at 14% 50%, rgba(56,189,248,0.18), transparent 34%),
      linear-gradient(135deg, rgba(12,74,110,0.84), rgba(49,46,129,0.78)) !important;
    border-color: rgba(56,189,248,0.36) !important;
  }

  .mobile-drawer-status.testnet span:first-child {
    background: #38bdf8 !important;
    box-shadow: 0 0 14px rgba(56,189,248,0.60) !important;
  }

  .mobile-drawer-status.live-on {
    background:
      radial-gradient(circle at 14% 50%, rgba(34,197,94,0.18), transparent 34%),
      linear-gradient(135deg, rgba(6,78,59,0.84), rgba(12,35,74,0.78)) !important;
    border-color: rgba(34,197,94,0.36) !important;
  }

  .mobile-drawer-status.live-on span:first-child {
    background: #22c55e !important;
    box-shadow: 0 0 14px rgba(34,197,94,0.60) !important;
  }

  .mobile-drawer-status.live-off {
    background:
      radial-gradient(circle at 14% 50%, rgba(244,63,94,0.16), transparent 34%),
      linear-gradient(135deg, rgba(76,5,25,0.82), rgba(49,24,90,0.76)) !important;
    border-color: rgba(244,63,94,0.34) !important;
  }

  .mobile-drawer-status.live-off span:first-child {
    background: #f43f5e !important;
    box-shadow: 0 0 14px rgba(244,63,94,0.60) !important;
  }
}

/* STT STEP45.97 CLEAN EXACT DRAWER STATUS CSS END */


/* STT STEP45.98 COMPACT MOBILE DRAWER START */

@media (max-width: 820px) {
  /* Drawer overall compact */
  .mobile-control-drawer {
    width: min(82vw, 330px) !important;
    padding: calc(12px + env(safe-area-inset-top, 0px)) 12px 14px !important;
  }

  /* Header compact */
  .mobile-drawer-head {
    margin-bottom: 10px !important;
    gap: 10px !important;
  }

  .mobile-drawer-logo {
    width: 50px !important;
    height: 50px !important;
    min-width: 50px !important;
    border-radius: 16px !important;
  }

  .mobile-drawer-logo img {
    border-radius: 16px !important;
  }

  .mobile-drawer-head b {
    font-size: 18px !important;
    line-height: 1.04 !important;
  }

  .mobile-drawer-head small {
    font-size: 10.5px !important;
    line-height: 1.1 !important;
  }

  .mobile-drawer-close {
    width: 38px !important;
    height: 38px !important;
    min-width: 38px !important;
    border-radius: 14px !important;
    font-size: 24px !important;
  }

  /* Meta cards compact */
  .mobile-drawer-meta-grid {
    gap: 8px !important;
    margin: 6px 0 10px !important;
  }

  .mobile-drawer-meta-btn {
    min-height: 50px !important;
    padding: 8px 10px !important;
    border-radius: 16px !important;
    gap: 8px !important;
  }

  .drawer-svg-icon,
  .mobile-drawer-link > span:first-child,
  .drawer-action-icon {
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
    border-radius: 12px !important;
    font-size: 21px !important;
  }

  .drawer-svg-icon svg {
    width: 17px !important;
    height: 17px !important;
  }

  .mobile-drawer-meta-btn b,
  .mobile-drawer-action b,
  .mobile-drawer-link b {
    font-size: 13.5px !important;
    line-height: 1.08 !important;
  }

  .mobile-drawer-meta-btn small,
  .mobile-drawer-action small,
  .mobile-drawer-link small {
    font-size: 10.2px !important;
    line-height: 1.15 !important;
    margin-top: 2px !important;
  }

  /* Main website button compact */
  .mobile-drawer-action,
  .mobile-drawer-link {
    min-height: 52px !important;
    padding: 9px 11px !important;
    border-radius: 17px !important;
    gap: 10px !important;
    margin-bottom: 8px !important;
  }

  .mobile-drawer-action.main-site {
    min-height: 54px !important;
    margin-bottom: 10px !important;
  }

  /* Status cards compact */
  .mobile-drawer-status-row {
    gap: 8px !important;
    margin: 10px 0 11px !important;
  }

  .mobile-drawer-status {
    min-height: 50px !important;
    padding: 9px 11px !important;
    border-radius: 17px !important;
    column-gap: 9px !important;
  }

  .mobile-drawer-status span:first-child {
    width: 10px !important;
    height: 10px !important;
    min-width: 10px !important;
  }

  .mobile-drawer-status b {
    font-size: 13.5px !important;
    line-height: 1.08 !important;
  }

  .mobile-drawer-status small {
    font-size: 10.2px !important;
    line-height: 1.16 !important;
    margin-top: 2px !important;
  }

  /* Section title compact */
  .mobile-drawer-section-title {
    font-size: 10.5px !important;
    letter-spacing: 0.08em !important;
    margin: 10px 2px 7px !important;
  }

  /* Quick links compact */
  .mobile-drawer-link {
    min-height: 54px !important;
  }

  /* Bottom note compact */
  .mobile-drawer-note {
    margin-top: 9px !important;
    padding: 10px 11px !important;
    border-radius: 15px !important;
    font-size: 11px !important;
    line-height: 1.38 !important;
  }
}

@media (max-width: 430px) {
  .mobile-control-drawer {
    width: min(84vw, 322px) !important;
    padding-left: 11px !important;
    padding-right: 11px !important;
  }

  .mobile-drawer-head b {
    font-size: 17px !important;
  }

  .mobile-drawer-logo {
    width: 48px !important;
    height: 48px !important;
    min-width: 48px !important;
  }

  .mobile-drawer-meta-grid {
    gap: 7px !important;
  }

  .mobile-drawer-meta-btn {
    min-height: 48px !important;
  }

  .mobile-drawer-action,
  .mobile-drawer-link {
    min-height: 50px !important;
  }
}

/* STT STEP45.98 COMPACT MOBILE DRAWER END */


/* STT STEP45.99 MOBILE EXCHANGE DOT SYNC ONLY CSS START */

@media (max-width: 760px) {
  .stt-exchange-carousel-real-dots {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 8px !important;
  }

  .stt-exchange-carousel-real-dots [data-exchange-dot] {
    width: 9px !important;
    height: 9px !important;
    min-width: 9px !important;
    border-radius: 999px !important;
    border: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    background: rgba(80, 96, 125, 0.58) !important;
    opacity: 0.72 !important;
    box-shadow: none !important;
    transition: width .18s ease, background .18s ease, opacity .18s ease, box-shadow .18s ease !important;
  }

  .stt-exchange-carousel-real-dots [data-exchange-dot].active {
    width: 28px !important;
    min-width: 28px !important;
    opacity: 1 !important;
    background: linear-gradient(135deg, #22d3ee, #7c3aed) !important;
    box-shadow: 0 0 18px rgba(34, 211, 238, .42) !important;
  }

  .stt-exchange-carousel-real-dots [data-exchange-dot].inactive {
    width: 9px !important;
    min-width: 9px !important;
    background: rgba(80, 96, 125, 0.58) !important;
    opacity: 0.72 !important;
    box-shadow: none !important;
  }
}

/* STT STEP45.99 MOBILE EXCHANGE DOT SYNC ONLY CSS END */


/* STT STEP45.107 NEUTRAL STATUS NO GLITCH CSS START */

/* Keep status cards visually stable while JS fetches real status */
.safety-top-pill.status-checking,
#topModePill.status-checking,
#topLivePill.status-checking {
  min-width: 150px !important;
  justify-content: center !important;
  color: #dbeafe !important;
  background: rgba(30, 41, 59, 0.72) !important;
  border-color: rgba(148, 163, 184, 0.22) !important;
}

html.stt-status-loading #topTradingModesCard,
html.stt-status-loading #topLiveOrdersCard,
html.stt-status-loading #topBinanceApiCard,
html.stt-status-loading #topWithdrawCard {
  min-height: 92px !important;
}

html.stt-status-loading #topTradingModesTitle,
html.stt-status-loading #topLiveOrdersTitle,
html.stt-status-loading #topBinanceApiTitle,
html.stt-status-loading #topWithdrawTitle,
html.stt-status-loading #accountModeValue {
  color: #dbeafe !important;
}

html.stt-status-loading #topTradingModesSub,
html.stt-status-loading #topLiveOrdersSub,
html.stt-status-loading #topBinanceApiSub,
html.stt-status-loading #topWithdrawSub,
html.stt-status-loading #accountModeSub {
  color: rgba(226,232,240,0.68) !important;
}

/* STT STEP45.107 NEUTRAL STATUS NO GLITCH CSS END */


/* STT STEP45.110 STATUS CHECKING SIZE STABILITY START */

/*
  Prevent refresh/loading layout shift:
  - Topbar status pills keep final-like width during "Checking status..."
  - Safety cards keep final-like height during "Checking..."
  - Account mode stat card keeps stable height/width
*/

/* Desktop/topbar fixed pill widths */
#topModePill.safety-top-pill,
#topModePill.status-checking {
  min-width: 150px !important;
  width: 150px !important;
  justify-content: center !important;
  white-space: nowrap !important;
  flex-shrink: 0 !important;
}

#topLivePill.safety-top-pill,
#topLivePill.status-checking {
  min-width: 170px !important;
  width: 170px !important;
  justify-content: center !important;
  white-space: nowrap !important;
  flex-shrink: 0 !important;
}

/* Keep top actions stable while loading */
.top-actions {
  align-items: center !important;
}

.top-actions .main-site-link {
  flex-shrink: 0 !important;
}

.top-actions .notification-btn,
.top-actions .user-chip {
  flex-shrink: 0 !important;
}

/* Dashboard status cards: reserve same space in loading and final state */
#topSafetyStrip .safety-strip-item,
#topTradingModesCard,
#topLiveOrdersCard,
#topBinanceApiCard,
#topWithdrawCard {
  min-height: 96px !important;
  height: 96px !important;
  box-sizing: border-box !important;
  overflow: hidden !important;
  align-content: center !important;
}

/* Title/sub stable line boxes */
#topTradingModesTitle,
#topLiveOrdersTitle,
#topBinanceApiTitle,
#topWithdrawTitle {
  display: block !important;
  min-height: 20px !important;
  line-height: 1.2 !important;
}

#topTradingModesSub,
#topLiveOrdersSub,
#topBinanceApiSub,
#topWithdrawSub {
  display: block !important;
  min-height: 32px !important;
  line-height: 1.28 !important;
}

/* Stats cards stable */
.stats-row .stat-card {
  min-height: 118px !important;
  height: 118px !important;
  box-sizing: border-box !important;
  overflow: hidden !important;
}

#accountModeValue {
  min-height: 42px !important;
  line-height: 1.08 !important;
  display: block !important;
}

#accountModeSub {
  min-height: 18px !important;
  display: block !important;
}

/* Loading visual should not shrink cards */
html.stt-status-loading #topModePill,
html.stt-status-loading #topLivePill {
  opacity: 0.96 !important;
}

html.stt-status-loading #topSafetyStrip .safety-strip-item,
html.stt-status-loading .stats-row .stat-card {
  transform: none !important;
}

/* Mobile: do not force desktop widths */
@media (max-width: 820px) {
  #topModePill.safety-top-pill,
  #topModePill.status-checking,
  #topLivePill.safety-top-pill,
  #topLivePill.status-checking {
    width: auto !important;
    min-width: 0 !important;
  }

  #topSafetyStrip .safety-strip-item,
  #topTradingModesCard,
  #topLiveOrdersCard,
  #topBinanceApiCard,
  #topWithdrawCard {
    height: auto !important;
    min-height: 78px !important;
  }

  .stats-row .stat-card {
    height: auto !important;
    min-height: 92px !important;
  }
}

/* STT STEP45.110 STATUS CHECKING SIZE STABILITY END */


/* STT STEP45.111 RESTORE STATUS CARD HEIGHT START */

/*
  Step45.110 ne status cards ko 96px fixed height diya tha,
  jiski wajah se bottom text crop/touch feel ho raha tha.
  Ab fixed height remove karke stable min-height + padding use kar rahe hain.
*/

#topSafetyStrip .safety-strip-item,
#topTradingModesCard,
#topLiveOrdersCard,
#topBinanceApiCard,
#topWithdrawCard {
  height: auto !important;
  min-height: 112px !important;
  padding: 18px 18px 16px !important;
  box-sizing: border-box !important;
  overflow: visible !important;
  align-content: center !important;
}

#topTradingModesTitle,
#topLiveOrdersTitle,
#topBinanceApiTitle,
#topWithdrawTitle {
  display: block !important;
  min-height: 22px !important;
  line-height: 1.22 !important;
  margin-bottom: 6px !important;
}

#topTradingModesSub,
#topLiveOrdersSub,
#topBinanceApiSub,
#topWithdrawSub {
  display: block !important;
  min-height: 38px !important;
  line-height: 1.35 !important;
  padding-bottom: 2px !important;
}

/* Loading state me bhi same card height rahe, layout shift nahi hoga */
html.stt-status-loading #topSafetyStrip .safety-strip-item,
html.stt-status-loading #topTradingModesCard,
html.stt-status-loading #topLiveOrdersCard,
html.stt-status-loading #topBinanceApiCard,
html.stt-status-loading #topWithdrawCard {
  height: auto !important;
  min-height: 112px !important;
  padding: 18px 18px 16px !important;
  overflow: visible !important;
}

/* Stats row cards ko bhi thoda breathing space */
.stats-row .stat-card {
  height: auto !important;
  min-height: 126px !important;
  padding-top: 18px !important;
  padding-bottom: 18px !important;
  overflow: visible !important;
}

@media (max-width: 820px) {
  #topSafetyStrip .safety-strip-item,
  #topTradingModesCard,
  #topLiveOrdersCard,
  #topBinanceApiCard,
  #topWithdrawCard {
    min-height: 68px !important;
    padding: 14px 14px 13px !important;
  }

  #topTradingModesSub,
  #topLiveOrdersSub,
  #topBinanceApiSub,
  #topWithdrawSub {
    min-height: 30px !important;
    line-height: 1.30 !important;
  }

  .stats-row .stat-card {
    min-height: 100px !important;
  }
}

/* STT STEP45.111 RESTORE STATUS CARD HEIGHT END */


/* STT STEP45.112 COMPACT STABLE STATUS CARDS START */

/*
  Final balance:
  - Safety cards compact but not cropped
  - Stats cards stable during refresh/checking
  - No height jump between checking and final value
*/

/* Top 4 safety cards */
#topSafetyStrip .safety-strip-item,
#topTradingModesCard,
#topLiveOrdersCard,
#topBinanceApiCard,
#topWithdrawCard,
html.stt-status-loading #topSafetyStrip .safety-strip-item,
html.stt-status-loading #topTradingModesCard,
html.stt-status-loading #topLiveOrdersCard,
html.stt-status-loading #topBinanceApiCard,
html.stt-status-loading #topWithdrawCard {
  height: 104px !important;
  min-height: 104px !important;
  max-height: 104px !important;
  padding: 15px 16px 13px !important;
  box-sizing: border-box !important;
  overflow: hidden !important;
  align-content: center !important;
}

/* Safety card title */
#topTradingModesTitle,
#topLiveOrdersTitle,
#topBinanceApiTitle,
#topWithdrawTitle {
  display: block !important;
  min-height: 19px !important;
  line-height: 1.18 !important;
  margin-bottom: 5px !important;
  overflow: hidden !important;
}

/* Safety card subtitle */
#topTradingModesSub,
#topLiveOrdersSub,
#topBinanceApiSub,
#topWithdrawSub {
  display: block !important;
  min-height: 34px !important;
  line-height: 1.28 !important;
  padding-bottom: 0 !important;
  overflow: hidden !important;
}

/* Stats row cards: stable fixed height during refresh */
.stats-row .stat-card,
html.stt-status-loading .stats-row .stat-card {
  height: 112px !important;
  min-height: 112px !important;
  max-height: 112px !important;
  padding: 15px 16px !important;
  box-sizing: border-box !important;
  overflow: hidden !important;
}

/* Stats text blocks stable */
.stats-row .stat-label {
  min-height: 16px !important;
  line-height: 1.15 !important;
}

.stats-row .stat-value,
#accountModeValue {
  min-height: 34px !important;
  line-height: 1.08 !important;
  display: block !important;
}

.stats-row .stat-sub,
#accountModeSub {
  min-height: 16px !important;
  line-height: 1.15 !important;
  display: block !important;
}

/* Account mode can be 2-line, keep box stable */
#accountModeValue {
  white-space: normal !important;
}

/* Mobile override */
@media (max-width: 820px) {
  #topSafetyStrip .safety-strip-item,
  #topTradingModesCard,
  #topLiveOrdersCard,
  #topBinanceApiCard,
  #topWithdrawCard,
  html.stt-status-loading #topSafetyStrip .safety-strip-item,
  html.stt-status-loading #topTradingModesCard,
  html.stt-status-loading #topLiveOrdersCard,
  html.stt-status-loading #topBinanceApiCard,
  html.stt-status-loading #topWithdrawCard {
    height: auto !important;
    min-height: 82px !important;
    max-height: none !important;
    padding: 13px 14px 12px !important;
    overflow: visible !important;
  }

  .stats-row .stat-card,
  html.stt-status-loading .stats-row .stat-card {
    height: auto !important;
    min-height: 94px !important;
    max-height: none !important;
    padding: 13px 14px !important;
    overflow: visible !important;
  }

  #topTradingModesSub,
  #topLiveOrdersSub,
  #topBinanceApiSub,
  #topWithdrawSub {
    min-height: 28px !important;
  }
}

/* STT STEP45.112 COMPACT STABLE STATUS CARDS END */


/* STT STEP45.113 TOP SAFETY CARD HEIGHT POLISH START */

/*
  Top 4 safety cards final size:
  - Slightly taller than Step45.112
  - Text fully visible
  - Refresh/loading and final state keep same height
*/

#topSafetyStrip .safety-strip-item,
#topTradingModesCard,
#topLiveOrdersCard,
#topBinanceApiCard,
#topWithdrawCard,
html.stt-status-loading #topSafetyStrip .safety-strip-item,
html.stt-status-loading #topTradingModesCard,
html.stt-status-loading #topLiveOrdersCard,
html.stt-status-loading #topBinanceApiCard,
html.stt-status-loading #topWithdrawCard {
  height: 112px !important;
  min-height: 112px !important;
  max-height: 112px !important;
  padding: 16px 17px 15px !important;
  box-sizing: border-box !important;
  overflow: hidden !important;
  align-content: center !important;
}

#topTradingModesTitle,
#topLiveOrdersTitle,
#topBinanceApiTitle,
#topWithdrawTitle {
  min-height: 21px !important;
  line-height: 1.22 !important;
  margin-bottom: 6px !important;
}

#topTradingModesSub,
#topLiveOrdersSub,
#topBinanceApiSub,
#topWithdrawSub {
  min-height: 40px !important;
  line-height: 1.34 !important;
  padding-bottom: 3px !important;
  overflow: hidden !important;
}

/* Keep stats cards from Step45.112 unchanged */
.stats-row .stat-card,
html.stt-status-loading .stats-row .stat-card {
  height: 112px !important;
  min-height: 112px !important;
  max-height: 112px !important;
}

/* Mobile remains compact */
@media (max-width: 820px) {
  #topSafetyStrip .safety-strip-item,
  #topTradingModesCard,
  #topLiveOrdersCard,
  #topBinanceApiCard,
  #topWithdrawCard,
  html.stt-status-loading #topSafetyStrip .safety-strip-item,
  html.stt-status-loading #topTradingModesCard,
  html.stt-status-loading #topLiveOrdersCard,
  html.stt-status-loading #topBinanceApiCard,
  html.stt-status-loading #topWithdrawCard {
    height: auto !important;
    min-height: 88px !important;
    max-height: none !important;
    padding: 14px 14px 13px !important;
    overflow: visible !important;
  }
}

/* STT STEP45.113 TOP SAFETY CARD HEIGHT POLISH END */


/* STT STEP45.114A SMART SAFETY CARD LAYOUT START */

/*
  Smart layout for top 4 dashboard status cards:
  Icon left, title on same level to the right, description below title.
  This avoids text crop without making cards too tall.
*/

#topSafetyStrip .safety-strip-item,
#topTradingModesCard,
#topLiveOrdersCard,
#topBinanceApiCard,
#topWithdrawCard,
html.stt-status-loading #topSafetyStrip .safety-strip-item,
html.stt-status-loading #topTradingModesCard,
html.stt-status-loading #topLiveOrdersCard,
html.stt-status-loading #topBinanceApiCard,
html.stt-status-loading #topWithdrawCard {
  display: grid !important;
  grid-template-columns: 42px minmax(0, 1fr) !important;
  grid-template-rows: auto auto !important;
  column-gap: 12px !important;
  row-gap: 3px !important;
  align-items: center !important;

  height: 104px !important;
  min-height: 104px !important;
  max-height: 104px !important;
  padding: 15px 16px !important;
  box-sizing: border-box !important;
  overflow: hidden !important;
}

/* icon box / first icon inside card */
#topSafetyStrip .safety-strip-item > span:first-child,
#topSafetyStrip .safety-strip-item > div:first-child,
#topTradingModesCard > span:first-child,
#topLiveOrdersCard > span:first-child,
#topBinanceApiCard > span:first-child,
#topWithdrawCard > span:first-child,
#topTradingModesCard > div:first-child,
#topLiveOrdersCard > div:first-child,
#topBinanceApiCard > div:first-child,
#topWithdrawCard > div:first-child {
  grid-column: 1 !important;
  grid-row: 1 / span 2 !important;
  align-self: start !important;
  margin-top: 2px !important;
}

/* title */
#topTradingModesTitle,
#topLiveOrdersTitle,
#topBinanceApiTitle,
#topWithdrawTitle {
  grid-column: 2 !important;
  grid-row: 1 !important;
  display: block !important;
  min-height: 18px !important;
  line-height: 1.18 !important;
  margin: 0 0 3px 0 !important;
  overflow: hidden !important;
  white-space: normal !important;
}

/* subtitle */
#topTradingModesSub,
#topLiveOrdersSub,
#topBinanceApiSub,
#topWithdrawSub {
  grid-column: 2 !important;
  grid-row: 2 !important;
  display: block !important;
  min-height: 36px !important;
  line-height: 1.28 !important;
  margin: 0 !important;
  padding: 0 !important;
  overflow: hidden !important;
  white-space: normal !important;
}

/* If existing HTML wraps title/sub in inner div, make it use right column */
#topSafetyStrip .safety-strip-item > div:not(:first-child),
#topTradingModesCard > div:not(:first-child),
#topLiveOrdersCard > div:not(:first-child),
#topBinanceApiCard > div:not(:first-child),
#topWithdrawCard > div:not(:first-child) {
  grid-column: 2 !important;
  min-width: 0 !important;
}

/* Stable during checking/final update */
html.stt-status-loading #topTradingModesTitle,
html.stt-status-loading #topLiveOrdersTitle,
html.stt-status-loading #topBinanceApiTitle,
html.stt-status-loading #topWithdrawTitle {
  min-height: 18px !important;
}

html.stt-status-loading #topTradingModesSub,
html.stt-status-loading #topLiveOrdersSub,
html.stt-status-loading #topBinanceApiSub,
html.stt-status-loading #topWithdrawSub {
  min-height: 36px !important;
}

/* Keep second row status cards unchanged from stable setup */
.stats-row .stat-card,
html.stt-status-loading .stats-row .stat-card {
  height: 112px !important;
  min-height: 112px !important;
  max-height: 112px !important;
}

/* Mobile: preserve compact vertical behavior */
@media (max-width: 820px) {
  #topSafetyStrip .safety-strip-item,
  #topTradingModesCard,
  #topLiveOrdersCard,
  #topBinanceApiCard,
  #topWithdrawCard,
  html.stt-status-loading #topSafetyStrip .safety-strip-item,
  html.stt-status-loading #topTradingModesCard,
  html.stt-status-loading #topLiveOrdersCard,
  html.stt-status-loading #topBinanceApiCard,
  html.stt-status-loading #topWithdrawCard {
    height: auto !important;
    min-height: 86px !important;
    max-height: none !important;
    grid-template-columns: 38px minmax(0, 1fr) !important;
    column-gap: 10px !important;
    padding: 13px 14px !important;
    overflow: visible !important;
  }

  #topTradingModesSub,
  #topLiveOrdersSub,
  #topBinanceApiSub,
  #topWithdrawSub {
    min-height: 30px !important;
    line-height: 1.30 !important;
    overflow: visible !important;
  }
}

/* STT STEP45.114A SMART SAFETY CARD LAYOUT END */


/* ===== STT STEP46 FINAL REAL FIX: MOBILE BOT CAROUSEL NO FLICKER START ===== */
/* Prevent mobile bot carousel class changes from producing visible glow repaint. */
@media (max-width: 768px) {
  #page-bots .bot-results-area .bot-grid.stt-exact-bot-grid-carousel-4575,
  #page-bots .bot-results-area .bot-grid.stt-exact-bot-grid-carousel-4575 > .bot-card,
  #page-bots .bot-results-area .bot-grid.stt-exact-bot-grid-carousel-4575 > .bot-card.stt-active-bot-slide-4575 {
    transition: none !important;
    animation: none !important;
  }

  #page-bots .bot-results-area .bot-grid.stt-exact-bot-grid-carousel-4575 > .bot-card::before,
  #page-bots .bot-results-area .bot-grid.stt-exact-bot-grid-carousel-4575 > .bot-card::after {
    transition: none !important;
    animation: none !important;
  }
}
/* ===== STT STEP46 FINAL REAL FIX: MOBILE BOT CAROUSEL NO FLICKER END ===== */



/* ===== STT STEP46.12 CLEAN FINAL BOTTOM NAV OVERRIDE START ===== */
/*
  Final override only for mobile bottom nav:
  - force actual screen-bottom position
  - no body overlay / no shadow mask
  - same size/padding remains from original nav
  - solid background so text does not show through
*/
@media (max-width: 768px) {
  .mobile-bottom-nav {
    position: fixed !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    z-index: 99999 !important;

    border-radius: 22px 22px 0 0 !important;

    background:
      radial-gradient(circle at 12% 0%, rgba(56, 189, 248, 0.32), transparent 34%),
      radial-gradient(circle at 88% 8%, rgba(16, 185, 129, 0.24), transparent 36%),
      linear-gradient(135deg, rgb(5, 18, 40), rgb(8, 34, 56), rgb(3, 56, 45)) !important;

    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }
}
/* ===== STT STEP46.12 CLEAN FINAL BOTTOM NAV OVERRIDE END ===== */



/* ===== STT STEP46.22 MOBILE STATUS METRIC CARDS ROW LAYOUT START ===== */
/*
  Target only Dashboard Status lower metric cards on mobile:
  API Health, Exchange Status, Running AI Bots, Trade Logs, Signal Engine, Account Mode.
  Icon left, text/value right. No bottom-nav changes. No desktop changes.
*/
@media (max-width: 820px) {
  body.mobile-status-expanded .stats-row .stat-card.mobile-overview-item,
  body.mobile-status-expanded .enhanced-stats-row .stat-card.mobile-overview-item {
    display: grid !important;
    grid-template-columns: 48px minmax(0, 1fr) !important;
    grid-template-rows: auto auto auto !important;
    column-gap: 12px !important;
    row-gap: 0 !important;
    align-items: center !important;

    min-height: 86px !important;
    height: auto !important;
    padding: 8px 14px !important;
    margin: 0 0 14px 0 !important;

    text-align: left !important;
    overflow: hidden !important;
  }

  body.mobile-status-expanded .stats-row .stat-card.mobile-overview-item > :first-child,
  body.mobile-status-expanded .enhanced-stats-row .stat-card.mobile-overview-item > :first-child {
    grid-column: 1 !important;
    grid-row: 1 / span 3 !important;
    align-self: center !important;
    justify-self: center !important;
    margin: 0 !important;
  }

  body.mobile-status-expanded .stats-row .stat-card.mobile-overview-item .stat-label,
  body.mobile-status-expanded .enhanced-stats-row .stat-card.mobile-overview-item .stat-label {
    grid-column: 2 !important;
    grid-row: 1 !important;
    margin: 0 !important;
    text-align: left !important;
    line-height: 1.2 !important;
  }

  body.mobile-status-expanded .stats-row .stat-card.mobile-overview-item .stat-value,
  body.mobile-status-expanded .enhanced-stats-row .stat-card.mobile-overview-item .stat-value {
    grid-column: 2 !important;
    grid-row: 2 !important;
    margin: 4px 0 0 0 !important;
    text-align: left !important;
    line-height: 1.05 !important;
  }

  body.mobile-status-expanded .stats-row .stat-card.mobile-overview-item .stat-sub,
  body.mobile-status-expanded .enhanced-stats-row .stat-card.mobile-overview-item .stat-sub {
    grid-column: 2 !important;
    grid-row: 3 !important;
    margin: 4px 0 0 0 !important;
    text-align: left !important;
    line-height: 1.25 !important;
  }

  /* Keep Dashboard Home below status cards with clean separation */
  body.mobile-status-expanded #page-home {
    clear: both !important;
    margin-top: 14px !important;
  }
}
/* ===== STT STEP46.22 MOBILE STATUS METRIC CARDS ROW LAYOUT END ===== */

/* ===== STT STEP46.23 COMPACT MOBILE STATUS METRIC CARDS START ===== */
@media (max-width: 820px) {
  body.mobile-status-expanded .stats-row .stat-card.mobile-overview-item > :first-child,
  body.mobile-status-expanded .enhanced-stats-row .stat-card.mobile-overview-item > :first-child {
    max-width: 44px !important;
    max-height: 44px !important;
  }

  body.mobile-status-expanded .stats-row .stat-card.mobile-overview-item .stat-label,
  body.mobile-status-expanded .enhanced-stats-row .stat-card.mobile-overview-item .stat-label {
    font-size: 14px !important;
  }

  body.mobile-status-expanded .stats-row .stat-card.mobile-overview-item .stat-value,
  body.mobile-status-expanded .enhanced-stats-row .stat-card.mobile-overview-item .stat-value {
    font-size: 23px !important;
  }

  body.mobile-status-expanded .stats-row .stat-card.mobile-overview-item .stat-sub,
  body.mobile-status-expanded .enhanced-stats-row .stat-card.mobile-overview-item .stat-sub {
    font-size: 12px !important;
  }
}
/* ===== STT STEP46.23 COMPACT MOBILE STATUS METRIC CARDS END ===== */

/* ===== STT STEP46.24 EXTRA COMPACT MOBILE STATUS CARDS START ===== */
@media (max-width: 820px) {
  body.mobile-status-expanded .stats-row,
  body.mobile-status-expanded .enhanced-stats-row {
    gap: 7px !important;
    row-gap: 4px !important;
  }

  body.mobile-status-expanded .stats-row .stat-card.mobile-overview-item,
  body.mobile-status-expanded .enhanced-stats-row .stat-card.mobile-overview-item {
    min-height: 68px !important;
    padding-top: 8px !important;
    padding-bottom: 8px !important;
  }

  body.mobile-status-expanded .stats-row .stat-card.mobile-overview-item .stat-value,
  body.mobile-status-expanded .enhanced-stats-row .stat-card.mobile-overview-item .stat-value {
    margin-top: 1px !important;
    margin-bottom: 0 !important;
    line-height: 1 !important;
  }

  body.mobile-status-expanded .stats-row .stat-card.mobile-overview-item .stat-sub,
  body.mobile-status-expanded .enhanced-stats-row .stat-card.mobile-overview-item .stat-sub {
    margin-top: 1px !important;
    line-height: 1.15 !important;
  }
}
/* ===== STT STEP46.24 EXTRA COMPACT MOBILE STATUS CARDS END ===== */

/* ===== STT STEP46.27 VISUAL CENTER MOBILE STATUS VALUE ONLY START ===== */
/*
  Only visually move metric value slightly down between label and subtext.
  No margin/height/padding change, so card size remains same.
*/
@media (max-width: 820px) {
  body.mobile-status-expanded .stats-row .stat-card.mobile-overview-item .stat-value,
  body.mobile-status-expanded .enhanced-stats-row .stat-card.mobile-overview-item .stat-value {
    transform: translateY(4px) !important;
  }
}
/* ===== STT STEP46.27 VISUAL CENTER MOBILE STATUS VALUE ONLY END ===== */



/* ===== STT STEP46.34 STATUS TOGGLE PLACEHOLDER STABLE FIRST PAINT START ===== */
@media (max-width: 820px) {
  #page-home > #mobileStatusAccordionToggle.mobile-status-accordion-toggle {
    display: flex !important;
    position: relative !important;
    width: 100% !important;
    margin: 0 0 12px 0 !important;
    transform: none !important;
  }
}
/* ===== STT STEP46.34 STATUS TOGGLE PLACEHOLDER STABLE FIRST PAINT END ===== */

/* ===== STT STEP46.39 HERO NEVER STATUS ITEM START ===== */
/*
  Real root fix:
  Hero/banner was temporarily treated as mobile status accordion item,
  causing refresh jump when it was hidden then restored.
*/
@media (max-width: 820px) {
  .hero-panel {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: auto !important;
    min-height: 210px !important;
    max-height: none !important;
    overflow: hidden !important;
    transform: none !important;
  }

  body.mobile-status-collapsed .hero-panel,
  body.mobile-status-expanded .hero-panel,
  body.mobile-status-collapsed .hero-panel.mobile-overview-item,
  body.mobile-status-expanded .hero-panel.mobile-overview-item {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: auto !important;
    min-height: 210px !important;
    max-height: none !important;
    margin-bottom: 12px !important;
    transform: none !important;
  }
}
/* ===== STT STEP46.39 HERO NEVER STATUS ITEM END ===== */

/* ===== STT STEP46.41 STABLE LOADING AREAS START ===== */
/*
  Reduce refresh-time loading shake:
  reserve stable space for page containers while API data is loading.
  This does not change desktop layout.
*/
@media (max-width: 820px) {
  #page-bots #botList {
    min-height: 360px !important;
  }

  #page-bots .bot-results-area {
    min-height: 320px !important;
  }

  #strategyStatusBox {
    min-height: 520px !important;
  }

  #marketWatchBox {
    min-height: 520px !important;
  }

  #page-trades .card {
    min-height: 360px !important;
  }

  #page-settings .compact-page-grid {
    min-height: 420px !important;
  }

  #page-exchange .exchange-grid,
  #exchangeGridBox {
    min-height: 260px !important;
  }

  .status-compact {
    min-height: 80px !important;
    display: flex !important;
    align-items: center !important;
  }
}
/* ===== STT STEP46.41 STABLE LOADING AREAS END ===== */

/* =========================================================
   STT STEP 47 — Market Watch coin click chart modal
   Safe append only: does not touch bottom nav/status/restore.
   ========================================================= */

.stt-chart-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 99980;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(2, 6, 23, 0.78);
  backdrop-filter: blur(14px);
}

.stt-chart-modal-overlay.show {
  display: flex;
}

.stt-chart-modal {
  width: min(1120px, 96vw);
  max-height: 92vh;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 24px;
  background:
    radial-gradient(circle at 15% 0%, rgba(124, 58, 237, 0.20), transparent 34%),
    radial-gradient(circle at 95% 10%, rgba(34, 211, 238, 0.12), transparent 32%),
    linear-gradient(145deg, #07111f, #0b1020 55%, #090b18);
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.58);
  color: #e5e7eb;
}

.stt-chart-modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 18px 20px 12px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.16);
}

.stt-chart-title-wrap {
  min-width: 0;
}

.stt-chart-title {
  margin: 0;
  font-size: 20px;
  line-height: 1.2;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.stt-chart-subtitle {
  margin-top: 5px;
  font-size: 12px;
  color: rgba(226, 232, 240, 0.72);
}

.stt-chart-close {
  width: 38px;
  height: 38px;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.68);
  color: #f8fafc;
  cursor: pointer;
  font-size: 22px;
  line-height: 1;
}

.stt-chart-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 12px 20px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
}

.stt-chart-interval {
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 999px;
  padding: 7px 12px;
  background: rgba(15, 23, 42, 0.60);
  color: rgba(226, 232, 240, 0.86);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.stt-chart-interval.active {
  border-color: rgba(250, 204, 21, 0.74);
  background: rgba(250, 204, 21, 0.13);
  color: #fde68a;
}

.stt-chart-body {
  padding: 14px 16px 16px;
}

#sttMarketCoinChart {
  width: 100%;
  height: 470px;
  border-radius: 18px;
  overflow: hidden;
  background: rgba(2, 6, 23, 0.38);
}

.stt-chart-loader,
.stt-chart-error {
  display: none;
  padding: 12px 20px 0;
  font-size: 13px;
}

.stt-chart-loader.show {
  display: block;
  color: rgba(226, 232, 240, 0.78);
}

.stt-chart-error.show {
  display: block;
  color: #fecaca;
}

.stt-market-click-hint {
  cursor: pointer;
}

@media (max-width: 720px) {
  .stt-chart-modal-overlay {
    align-items: flex-end;
    padding: 0;
  }

  .stt-chart-modal {
    width: 100%;
    max-height: 92vh;
    border-radius: 24px 24px 0 0;
  }

  .stt-chart-modal-header {
    padding: 16px 16px 10px;
  }

  .stt-chart-title {
    font-size: 17px;
  }

  .stt-chart-toolbar {
    padding: 10px 16px;
    overflow-x: auto;
    flex-wrap: nowrap;
  }

  .stt-chart-interval {
    flex: 0 0 auto;
  }

  .stt-chart-body {
    padding: 10px 10px 14px;
  }

  #sttMarketCoinChart {
    height: 390px;
  }
}

/* =========================================================
   STT STEP 49.7 — Chart fullscreen toggle
   ========================================================= */

.stt-chart-window-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.stt-chart-fullscreen {
  width: 38px;
  height: 38px;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.68);
  color: #f8fafc;
  cursor: pointer;
  font-size: 17px;
  line-height: 1;
}

.stt-chart-fullscreen:hover,
.stt-chart-close:hover {
  border-color: rgba(250, 204, 21, 0.72);
  background: rgba(250, 204, 21, 0.12);
}

.stt-chart-modal-overlay.stt-chart-fullscreen-mode {
  padding: 10px;
  align-items: stretch;
  justify-content: stretch;
}

.stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-modal {
  width: 100%;
  max-height: none;
  height: calc(100vh - 20px);
  border-radius: 20px;
}

.stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-body {
  height: calc(100vh - 162px);
}

.stt-chart-modal-overlay.stt-chart-fullscreen-mode #sttMarketCoinChart {
  height: 100%;
}

@media (max-width: 720px) {
  .stt-chart-fullscreen {
    width: 36px;
    height: 36px;
    border-radius: 13px;
  }

  .stt-chart-modal-overlay.stt-chart-fullscreen-mode {
    padding: 0;
  }

  .stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-modal {
    height: 100vh;
    border-radius: 0;
  }

  .stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-body {
    height: calc(100vh - 156px);
  }
}

/* =========================================================
   STT STEP 50.1 — Chart open trade panel + manual close
   ========================================================= */

.stt-chart-trade-panel {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 10px 20px 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.08);
}

.stt-chart-trade-panel-empty {
  width: 100%;
  padding: 10px 12px;
  border: 1px dashed rgba(148, 163, 184, 0.25);
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.34);
  color: rgba(226, 232, 240, 0.75);
  font-size: 12px;
  font-weight: 700;
}

.stt-chart-trade-panel-empty span {
  margin-left: 8px;
  color: rgba(148, 163, 184, 0.78);
  font-weight: 600;
}

.stt-chart-open-trade-card {
  min-width: 245px;
  flex: 0 0 auto;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 16px;
  background:
    radial-gradient(circle at 10% 0%, rgba(34, 211, 238, 0.10), transparent 30%),
    rgba(15, 23, 42, 0.72);
  padding: 11px;
}

.stt-chart-open-trade-card.buy {
  border-color: rgba(34, 197, 94, 0.34);
}

.stt-chart-open-trade-card.sell {
  border-color: rgba(239, 68, 68, 0.34);
}

.stt-chart-open-trade-main {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.stt-chart-open-trade-symbol {
  color: #f8fafc;
  font-size: 13px;
  font-weight: 900;
}

.stt-chart-open-trade-side {
  border-radius: 999px;
  padding: 4px 8px;
  background: rgba(15, 23, 42, 0.88);
  color: #f8fafc;
  font-size: 11px;
  font-weight: 900;
}

.stt-chart-open-trade-card.buy .stt-chart-open-trade-side {
  color: #86efac;
}

.stt-chart-open-trade-card.sell .stt-chart-open-trade-side {
  color: #fca5a5;
}

.stt-chart-open-trade-grid {
  display: grid;
  grid-template-columns: 54px 1fr;
  gap: 5px 9px;
  margin-bottom: 10px;
  font-size: 11px;
}

.stt-chart-open-trade-grid span {
  color: rgba(148, 163, 184, 0.86);
}

.stt-chart-open-trade-grid strong {
  color: rgba(226, 232, 240, 0.95);
  text-align: right;
}

.stt-chart-open-trade-grid strong.profit {
  color: #86efac;
}

.stt-chart-open-trade-grid strong.loss {
  color: #fca5a5;
}

.stt-chart-close-trade-btn {
  width: 100%;
  border: 1px solid rgba(248, 113, 113, 0.38);
  border-radius: 12px;
  padding: 8px 10px;
  background: rgba(127, 29, 29, 0.35);
  color: #fecaca;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.stt-chart-close-trade-btn:hover {
  border-color: rgba(248, 113, 113, 0.80);
  background: rgba(220, 38, 38, 0.24);
}

.stt-chart-close-trade-btn:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

@media (max-width: 720px) {
  .stt-chart-trade-panel {
    padding: 8px 12px 0;
  }

  .stt-chart-open-trade-card {
    min-width: 220px;
  }

  .stt-chart-trade-panel-empty {
    font-size: 11px;
  }

  .stt-chart-trade-panel-empty span {
    display: block;
    margin-left: 0;
    margin-top: 4px;
  }
}

/* =========================================================
   STT STEP 50.2 — Floating close button on trade entry line
   ========================================================= */

.stt-chart-trade-panel-hidden {
  display: none !important;
  padding: 0 !important;
  border: 0 !important;
}

.stt-chart-canvas-wrap {
  position: relative;
  width: 100%;
  height: 100%;
}

.stt-chart-canvas-wrap #sttMarketCoinChart {
  width: 100%;
  height: 470px;
}

.stt-chart-line-close-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 8;
}

.stt-line-close-btn {
  position: absolute;
  pointer-events: auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 30px;
  padding: 0 9px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.28);
  background: rgba(15, 23, 42, 0.88);
  color: #f8fafc;
  font-size: 11px;
  font-weight: 900;
  cursor: pointer;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(10px);
}

.stt-line-close-btn span {
  letter-spacing: 0.02em;
}

.stt-line-close-btn b {
  display: inline-grid;
  place-items: center;
  width: 16px;
  height: 16px;
  border-radius: 999px;
  font-size: 13px;
  line-height: 1;
  background: rgba(248, 113, 113, 0.18);
  color: #fecaca;
}

.stt-line-close-btn.buy {
  border-color: rgba(34, 197, 94, 0.50);
  color: #bbf7d0;
}

.stt-line-close-btn.sell {
  border-color: rgba(239, 68, 68, 0.50);
  color: #fecaca;
}

.stt-line-close-btn:hover {
  transform: translateY(-1px);
  border-color: rgba(250, 204, 21, 0.85);
  background: rgba(30, 41, 59, 0.95);
}

.stt-line-close-btn:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

.stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-canvas-wrap #sttMarketCoinChart {
  height: 100%;
}

@media (max-width: 720px) {
  .stt-chart-canvas-wrap #sttMarketCoinChart {
    height: 390px;
  }

  .stt-line-close-btn {
    right: 38px !important;
    height: 28px;
    padding: 0 8px;
    font-size: 10px;
  }
}

/* =========================================================
   STT STEP 50.3 — Clean attached close control on entry line
   ========================================================= */

.stt-line-close-btn.stt-line-close-attached {
  height: 24px;
  padding: 0 5px 0 8px;
  gap: 5px;
  border-radius: 999px;
  font-size: 10px;
  line-height: 1;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.28);
  transform: translateY(0);
}

.stt-line-close-btn.stt-line-close-attached span {
  font-size: 10px;
  font-weight: 900;
}

.stt-line-close-btn.stt-line-close-attached b {
  width: 14px;
  height: 14px;
  font-size: 12px;
  background: rgba(248, 113, 113, 0.26);
}

.stt-line-close-btn.stt-line-close-attached.buy {
  background: rgba(6, 78, 59, 0.82);
  border-color: rgba(34, 197, 94, 0.72);
  color: #bbf7d0;
}

.stt-line-close-btn.stt-line-close-attached.sell {
  background: rgba(127, 29, 29, 0.82);
  border-color: rgba(239, 68, 68, 0.72);
  color: #fecaca;
}

.stt-line-close-btn.stt-line-close-attached:hover {
  transform: none;
  border-color: rgba(250, 204, 21, 0.9);
  background: rgba(30, 41, 59, 0.96);
}

@media (max-width: 720px) {
  .stt-line-close-btn.stt-line-close-attached {
    right: 6px !important;
    height: 23px;
    padding: 0 5px 0 7px;
    font-size: 9px;
  }
}

/* =========================================================
   STT STEP 50.4 — Only X close control beside BUY/SELL line label
   ========================================================= */

.stt-line-close-btn.stt-line-close-x-only {
  width: 18px;
  height: 18px;
  min-width: 18px;
  padding: 0;
  border-radius: 999px;
  display: grid;
  place-items: center;
  font-size: 13px;
  font-weight: 950;
  line-height: 1;
  color: #fecaca;
  background: rgba(127, 29, 29, 0.88);
  border: 1px solid rgba(248, 113, 113, 0.78);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.36);
  transform: none !important;
}

.stt-line-close-btn.stt-line-close-x-only.buy {
  background: rgba(22, 101, 52, 0.88);
  border-color: rgba(34, 197, 94, 0.86);
  color: #dcfce7;
}

.stt-line-close-btn.stt-line-close-x-only.sell {
  background: rgba(127, 29, 29, 0.88);
  border-color: rgba(248, 113, 113, 0.86);
  color: #fee2e2;
}

.stt-line-close-btn.stt-line-close-x-only:hover {
  background: rgba(250, 204, 21, 0.22);
  border-color: rgba(250, 204, 21, 0.95);
  color: #fef9c3;
  transform: none !important;
}

.stt-line-close-btn.stt-line-close-x-only span,
.stt-line-close-btn.stt-line-close-x-only b {
  display: none !important;
}

@media (max-width: 720px) {
  .stt-line-close-btn.stt-line-close-x-only {
    right: 2px !important;
    width: 17px;
    height: 17px;
    min-width: 17px;
    font-size: 12px;
  }
}

/* =========================================================
   STT STEP 50.5 — BUY × close label left of price column
   ========================================================= */

.stt-line-close-btn.stt-line-close-buyx {
  height: 22px;
  min-width: 52px;
  padding: 0 6px 0 8px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  font-size: 10px;
  font-weight: 950;
  line-height: 1;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.34);
  transform: none !important;
}

.stt-line-close-btn.stt-line-close-buyx span {
  display: inline !important;
  letter-spacing: 0.02em;
  font-size: 10px;
  font-weight: 950;
}

.stt-line-close-btn.stt-line-close-buyx b {
  display: inline-grid !important;
  place-items: center;
  width: 13px;
  height: 13px;
  border-radius: 999px;
  font-size: 11px;
  line-height: 1;
  background: rgba(248, 113, 113, 0.28);
  color: #fee2e2;
}

.stt-line-close-btn.stt-line-close-buyx.buy {
  background: rgba(22, 101, 52, 0.88);
  border: 1px solid rgba(34, 197, 94, 0.82);
  color: #dcfce7;
}

.stt-line-close-btn.stt-line-close-buyx.sell {
  background: rgba(127, 29, 29, 0.88);
  border: 1px solid rgba(248, 113, 113, 0.82);
  color: #fee2e2;
}

.stt-line-close-btn.stt-line-close-buyx:hover {
  border-color: rgba(250, 204, 21, 0.95);
  background: rgba(30, 41, 59, 0.96);
  color: #fef9c3;
  transform: none !important;
}

/* override old x-only/mobile rules */
.stt-line-close-btn.stt-line-close-buyx span,
.stt-line-close-btn.stt-line-close-buyx b {
  visibility: visible !important;
}

@media (max-width: 720px) {
  .stt-line-close-btn.stt-line-close-buyx {
    right: 58px !important;
    height: 21px;
    min-width: 48px;
    padding: 0 5px 0 7px;
    font-size: 9px;
  }

  .stt-line-close-btn.stt-line-close-buyx span {
    font-size: 9px;
  }

  .stt-line-close-btn.stt-line-close-buyx b {
    width: 12px;
    height: 12px;
    font-size: 10px;
  }
}

/* =========================================================
   STT STEP 50.9 — Floating toolbar inside chart + bigger chart
   ========================================================= */

.stt-chart-canvas-wrap {
  position: relative;
}

/* Toolbar now floats inside chart, so it does not consume extra vertical space */
.stt-chart-toolbar.stt-chart-toolbar-floating {
  position: absolute;
  top: 10px;
  left: 10px;
  right: auto;
  z-index: 15;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 7px;
  max-width: calc(100% - 94px);
  padding: 7px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 16px;
  background: rgba(2, 6, 23, 0.52);
  backdrop-filter: blur(12px);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.26);
}

/* Make floating toolbar buttons smaller and cleaner */
.stt-chart-toolbar.stt-chart-toolbar-floating .stt-chart-interval {
  padding: 6px 10px;
  font-size: 11px;
  line-height: 1;
}

/* Bigger chart area after toolbar is moved inside the canvas */
.stt-chart-modal:not(.unused) #sttMarketCoinChart {
  height: 540px;
}

.stt-chart-modal .stt-chart-body {
  padding-top: 12px;
}

/* Since toolbar is floating, remove old toolbar space when moved */
.stt-chart-toolbar.stt-chart-toolbar-floating + #sttMarketCoinChart,
.stt-chart-toolbar.stt-chart-toolbar-floating ~ #sttMarketCoinChart {
  margin-top: 0;
}

/* Fullscreen gets maximum chart height */
.stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-body {
  height: calc(100vh - 96px);
}

.stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-canvas-wrap,
.stt-chart-modal-overlay.stt-chart-fullscreen-mode #sttMarketCoinChart {
  height: 100% !important;
}

/* Keep close button layer above candles but below toolbar */
.stt-chart-line-close-layer {
  z-index: 12;
}

@media (max-width: 720px) {
  .stt-chart-toolbar.stt-chart-toolbar-floating {
    top: 8px;
    left: 8px;
    max-width: calc(100% - 20px);
    overflow-x: auto;
    flex-wrap: nowrap;
    padding: 6px;
    border-radius: 14px;
  }

  .stt-chart-toolbar.stt-chart-toolbar-floating .stt-chart-interval {
    flex: 0 0 auto;
    padding: 6px 9px;
    font-size: 10px;
  }

  .stt-chart-modal:not(.unused) #sttMarketCoinChart {
    height: 455px;
  }

  .stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-body {
    height: calc(100vh - 86px);
  }
}

/* =========================================================
   STT STEP 50.10 — Hide/show floating chart toolbar
   ========================================================= */

.stt-chart-toolbar-toggle {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 18;
  width: 28px;
  height: 28px;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 999px;
  background: rgba(2, 6, 23, 0.68);
  color: #e5e7eb;
  display: none;
  place-items: center;
  cursor: pointer;
  font-size: 13px;
  font-weight: 900;
  line-height: 1;
  backdrop-filter: blur(10px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.28);
}

.stt-chart-toolbar-toggle:hover {
  border-color: rgba(250, 204, 21, 0.85);
  background: rgba(30, 41, 59, 0.92);
  color: #fef3c7;
}

.stt-chart-toolbar.stt-chart-toolbar-floating ~ .stt-chart-toolbar-toggle,
.stt-chart-canvas-wrap .stt-chart-toolbar-toggle {
  display: grid;
}

/* Move toolbar slightly right to leave room for toggle button */
.stt-chart-toolbar.stt-chart-toolbar-floating {
  left: 46px;
  max-width: calc(100% - 132px);
  transition: opacity 0.16s ease, transform 0.16s ease, visibility 0.16s ease;
}

.stt-chart-toolbar.stt-chart-toolbar-floating.stt-chart-toolbar-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateX(-8px);
}

.stt-chart-toolbar-toggle.tools-hidden {
  background: rgba(15, 23, 42, 0.88);
  border-color: rgba(34, 211, 238, 0.48);
  color: #a5f3fc;
}

@media (max-width: 720px) {
  .stt-chart-toolbar-toggle {
    top: 9px;
    left: 9px;
    width: 26px;
    height: 26px;
    font-size: 12px;
  }

  .stt-chart-toolbar.stt-chart-toolbar-floating {
    left: 42px;
    max-width: calc(100% - 52px);
  }
}

/* =========================================================
   STT STEP 50.11 — Mobile chart fixes
   1) Keep BUY × close control out of price column
   2) Preserve bottom time scale in fullscreen mobile
   ========================================================= */

/* Desktop/tablet: move close label away from price scale */
.stt-line-close-btn.stt-line-close-buyx {
  right: 92px !important;
}

/* Mobile: price column is wider, so shift BUY × further left */
@media (max-width: 720px) {
  .stt-line-close-btn.stt-line-close-buyx {
    right: 118px !important;
    min-width: 48px;
    height: 21px;
    padding: 0 5px 0 7px;
  }

  /* Keep chart inside viewport and leave room for time scale */
  .stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-modal {
    height: 100dvh;
    max-height: 100dvh;
    overflow: hidden;
  }

  .stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-body {
    height: calc(100dvh - 96px);
    padding-bottom: 18px;
    box-sizing: border-box;
  }

  .stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-canvas-wrap {
    height: 100%;
    padding-bottom: 26px;
    box-sizing: border-box;
  }

  .stt-chart-modal-overlay.stt-chart-fullscreen-mode #sttMarketCoinChart {
    height: calc(100% - 26px) !important;
    min-height: 360px;
  }

  /* Normal mobile modal: also leave a little room for time axis */
  .stt-chart-canvas-wrap #sttMarketCoinChart {
    height: 430px;
  }
}

/* Extra small phones */
@media (max-width: 420px) {
  .stt-line-close-btn.stt-line-close-buyx {
    right: 126px !important;
  }

  .stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-body {
    height: calc(100dvh - 102px);
    padding-bottom: 22px;
  }

  .stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-canvas-wrap {
    padding-bottom: 30px;
  }

  .stt-chart-modal-overlay.stt-chart-fullscreen-mode #sttMarketCoinChart {
    height: calc(100% - 30px) !important;
  }
}

/* =========================================================
   STT STEP 50.12 — Mobile chart fine tune
   1) BUY × close label closer to price column
   2) Fullscreen chart uses more bottom space
   ========================================================= */

@media (max-width: 720px) {
  /* Was too far left. Put it just left of BTC price column. */
  .stt-line-close-btn.stt-line-close-buyx {
    right: 72px !important;
  }

  .stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-body {
    height: calc(100dvh - 78px) !important;
    padding-bottom: 6px !important;
  }

  .stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-canvas-wrap {
    height: 100% !important;
    padding-bottom: 8px !important;
  }

  .stt-chart-modal-overlay.stt-chart-fullscreen-mode #sttMarketCoinChart {
    height: calc(100% - 8px) !important;
    min-height: 480px;
  }
}

@media (max-width: 420px) {
  /* For narrow phones, still keep BUY × outside price scale but not too far left */
  .stt-line-close-btn.stt-line-close-buyx {
    right: 78px !important;
  }

  .stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-body {
    height: calc(100dvh - 82px) !important;
    padding-bottom: 6px !important;
  }

  .stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-canvas-wrap {
    padding-bottom: 8px !important;
  }

  .stt-chart-modal-overlay.stt-chart-fullscreen-mode #sttMarketCoinChart {
    height: calc(100% - 8px) !important;
    min-height: 500px;
  }
}

/* =========================================================
   STT STEP 50.14 — Custom close confirm with 7-day skip
   ========================================================= */

.stt-close-confirm-overlay {
  position: fixed;
  inset: 0;
  z-index: 100200;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(2, 6, 23, 0.62);
  backdrop-filter: blur(8px);
}

.stt-close-confirm-overlay.show {
  display: flex;
}

.stt-close-confirm-card {
  width: min(430px, 94vw);
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 22px;
  background:
    radial-gradient(circle at 10% 0%, rgba(34, 211, 238, 0.12), transparent 34%),
    linear-gradient(145deg, rgba(15, 23, 42, 0.98), rgba(2, 6, 23, 0.98));
  color: #e5e7eb;
  box-shadow: 0 24px 78px rgba(0, 0, 0, 0.58);
  padding: 18px;
}

.stt-close-confirm-title {
  font-size: 18px;
  font-weight: 900;
  margin-bottom: 8px;
}

.stt-close-confirm-text {
  color: rgba(226, 232, 240, 0.82);
  font-size: 14px;
  margin-bottom: 14px;
}

.stt-close-confirm-check {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 10px 11px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.64);
  color: rgba(226, 232, 240, 0.86);
  font-size: 13px;
  cursor: pointer;
  user-select: none;
}

.stt-close-confirm-check input {
  width: 16px;
  height: 16px;
  accent-color: #22c55e;
}

.stt-close-confirm-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 16px;
}

.stt-close-confirm-actions button {
  border: 0;
  border-radius: 13px;
  padding: 10px 14px;
  font-weight: 900;
  cursor: pointer;
}

.stt-close-confirm-cancel {
  background: rgba(30, 41, 59, 0.92);
  color: #cbd5e1;
}

.stt-close-confirm-ok {
  background: linear-gradient(135deg, #ef4444, #f97316);
  color: #fff7ed;
}

@media (max-width: 720px) {
  .stt-close-confirm-card {
    border-radius: 18px;
    padding: 16px;
  }

  .stt-close-confirm-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }
}

/* =========================================================
   STT STEP 50.20 — Mobile BUY× flicker fix
   ========================================================= */

@media (max-width: 720px) {
  .stt-chart-touch-moving .stt-chart-line-close-layer {
    will-change: transform;
  }

  .stt-chart-touch-moving .stt-line-close-btn.stt-line-close-buyx {
    opacity: 0.86;
    transition: opacity 0.12s ease;
  }

  .stt-line-close-btn.stt-line-close-buyx {
    transition: opacity 0.12s ease, border-color 0.12s ease, background 0.12s ease;
  }
}

/* =========================================================
   STT STEP 50.21 — Keep BUY× stable during mobile drag
   ========================================================= */

@media (max-width: 720px) {
  .stt-chart-touch-moving .stt-line-close-btn.stt-line-close-buyx {
    opacity: 1 !important;
  }

  .stt-line-close-btn.stt-line-close-buyx {
    will-change: top, right;
    backface-visibility: hidden;
    transform: translateZ(0) !important;
  }
}

/* =========================================================
   STT STEP 50.25 — Chart Close All button
   ========================================================= */

.stt-chart-interval.stt-chart-close-all-btn {
  border-color: rgba(248, 113, 113, 0.42);
  background: rgba(127, 29, 29, 0.34);
  color: #fecaca;
}

.stt-chart-interval.stt-chart-close-all-btn:hover {
  border-color: rgba(248, 113, 113, 0.86);
  background: rgba(220, 38, 38, 0.28);
  color: #fff1f2;
}

.stt-chart-interval.stt-chart-close-all-btn:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

/* =========================================================
   STT STEP 51 — Chart manual paper trade open
   ========================================================= */

.stt-chart-interval.stt-chart-open-manual-btn {
  border-color: rgba(34, 211, 238, 0.42);
  background: rgba(8, 47, 73, 0.38);
  color: #a5f3fc;
}

.stt-chart-interval.stt-chart-open-manual-btn:hover {
  border-color: rgba(34, 211, 238, 0.88);
  background: rgba(8, 145, 178, 0.22);
  color: #ecfeff;
}

.stt-manual-open-overlay {
  position: fixed;
  inset: 0;
  z-index: 100300;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(2, 6, 23, 0.64);
  backdrop-filter: blur(10px);
}

.stt-manual-open-overlay.show {
  display: flex;
}

.stt-manual-open-card {
  width: min(440px, 94vw);
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 22px;
  background:
    radial-gradient(circle at 10% 0%, rgba(34, 211, 238, 0.12), transparent 34%),
    linear-gradient(145deg, rgba(15, 23, 42, 0.98), rgba(2, 6, 23, 0.98));
  color: #e5e7eb;
  box-shadow: 0 24px 78px rgba(0, 0, 0, 0.58);
  padding: 18px;
}

.stt-manual-open-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 16px;
}

.stt-manual-open-title {
  font-size: 18px;
  font-weight: 950;
}

.stt-manual-open-subtitle {
  margin-top: 4px;
  color: rgba(203, 213, 225, 0.82);
  font-size: 13px;
  font-weight: 700;
}

.stt-manual-open-x {
  width: 36px;
  height: 36px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 13px;
  background: rgba(15, 23, 42, 0.75);
  color: #f8fafc;
  font-size: 20px;
  cursor: pointer;
}

.stt-manual-open-field {
  display: grid;
  gap: 7px;
  margin-bottom: 12px;
}

.stt-manual-open-field label {
  color: rgba(226, 232, 240, 0.88);
  font-size: 13px;
  font-weight: 900;
}

.stt-manual-open-field input {
  width: 100%;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.78);
  color: #f8fafc;
  padding: 12px 13px;
  font-size: 15px;
  font-weight: 900;
  outline: none;
}

.stt-manual-open-presets {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 12px;
}

.stt-manual-open-presets button {
  border: 1px solid rgba(148, 163, 184, 0.20);
  border-radius: 12px;
  background: rgba(30, 41, 59, 0.74);
  color: #dbeafe;
  padding: 8px 6px;
  font-weight: 900;
  cursor: pointer;
}

.stt-manual-open-note {
  color: rgba(148, 163, 184, 0.88);
  font-size: 12px;
  margin-bottom: 14px;
}

.stt-manual-open-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.stt-manual-open-actions button {
  border: 0;
  border-radius: 14px;
  padding: 12px 14px;
  color: white;
  font-size: 14px;
  font-weight: 950;
  cursor: pointer;
}

.stt-manual-sell-btn {
  background: linear-gradient(135deg, #ef4444, #991b1b);
}

.stt-manual-buy-btn {
  background: linear-gradient(135deg, #22c55e, #047857);
}

.stt-manual-open-actions button:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

@media (max-width: 720px) {
  .stt-manual-open-card {
    border-radius: 18px;
    padding: 16px;
  }

  .stt-manual-open-presets {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* =========================================================
   STT STEP 51.4 — Custom open trade confirm with 7-day skip
   ========================================================= */

.stt-open-confirm-overlay {
  position: fixed;
  inset: 0;
  z-index: 100350;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(2, 6, 23, 0.62);
  backdrop-filter: blur(8px);
}

.stt-open-confirm-overlay.show {
  display: flex;
}

.stt-open-confirm-card {
  width: min(430px, 94vw);
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 22px;
  background:
    radial-gradient(circle at 10% 0%, rgba(34, 211, 238, 0.12), transparent 34%),
    linear-gradient(145deg, rgba(15, 23, 42, 0.98), rgba(2, 6, 23, 0.98));
  color: #e5e7eb;
  box-shadow: 0 24px 78px rgba(0, 0, 0, 0.58);
  padding: 18px;
}

.stt-open-confirm-title {
  font-size: 18px;
  font-weight: 900;
  margin-bottom: 8px;
}

.stt-open-confirm-text {
  color: rgba(226, 232, 240, 0.82);
  font-size: 14px;
  margin-bottom: 14px;
}

.stt-open-confirm-check {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 10px 11px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.64);
  color: rgba(226, 232, 240, 0.86);
  font-size: 13px;
  cursor: pointer;
  user-select: none;
}

.stt-open-confirm-check input {
  width: 16px;
  height: 16px;
  accent-color: #22c55e;
}

.stt-open-confirm-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 16px;
}

.stt-open-confirm-actions button {
  border: 0;
  border-radius: 13px;
  padding: 10px 14px;
  font-weight: 900;
  cursor: pointer;
}

.stt-open-confirm-cancel {
  background: rgba(30, 41, 59, 0.92);
  color: #cbd5e1;
}

.stt-open-confirm-ok {
  background: linear-gradient(135deg, #22c55e, #0891b2);
  color: #f0fdf4;
}

@media (max-width: 720px) {
  .stt-open-confirm-card {
    border-radius: 18px;
    padding: 16px;
  }

  .stt-open-confirm-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }
}

/* =========================================================
   STT STEP 52 — Manual trade SL/TP inputs
   ========================================================= */

.stt-manual-open-risk-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 12px 0;
}

.stt-manual-open-field.compact {
  margin-bottom: 0;
}

.stt-manual-open-field.compact label {
  font-size: 12px;
}

.stt-manual-open-field.compact input {
  padding: 10px 11px;
  font-size: 13px;
}

@media (max-width: 720px) {
  .stt-manual-open-risk-grid {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   STT STEP 53 — Draggable SL/TP handles
   ========================================================= */

.stt-chart-risk-drag-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 13;
}

.stt-risk-drag-handle {
  position: absolute;
  pointer-events: auto;
  height: 26px;
  min-width: 54px;
  padding: 0 7px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(15, 23, 42, 0.92);
  color: #f8fafc;
  font-size: 10px;
  font-weight: 950;
  cursor: ns-resize;
  user-select: none;
  box-shadow: 0 6px 20px rgba(0,0,0,0.34);
  backdrop-filter: blur(10px);
}

.stt-risk-drag-handle.sl {
  border-color: rgba(248, 113, 113, 0.86);
  background: rgba(127, 29, 29, 0.86);
  color: #fee2e2;
}

.stt-risk-drag-handle.tp {
  border-color: rgba(34, 197, 94, 0.86);
  background: rgba(22, 101, 52, 0.86);
  color: #dcfce7;
}

.stt-risk-drag-handle b {
  font-size: 11px;
  opacity: 0.85;
}

.stt-risk-drag-handle.dragging {
  border-color: rgba(250, 204, 21, 0.96);
  box-shadow: 0 0 0 3px rgba(250, 204, 21, 0.18), 0 10px 26px rgba(0,0,0,0.40);
}

@media (max-width: 720px) {
  .stt-risk-drag-handle {
    right: 118px !important;
    height: 24px;
    min-width: 50px;
    font-size: 9px;
  }
}

/* =========================================================
   STT STEP 53.4 — Smooth silent SL/TP drag
   ========================================================= */

.stt-risk-dragging-active {
  touch-action: none !important;
  user-select: none !important;
}

.stt-risk-dragging-active #sttMarketCoinChart {
  cursor: ns-resize !important;
}

.stt-risk-drag-handle {
  z-index: 30;
  will-change: top, transform;
  touch-action: none;
}

.stt-risk-drag-handle.dragging {
  transform: scale(1.04);
  cursor: ns-resize !important;
}

@media (max-width: 720px) {
  .stt-risk-drag-handle {
    min-width: 58px;
    height: 26px;
    font-size: 10px;
  }

  .stt-risk-drag-handle.dragging {
    transform: scale(1.06);
  }
}

/* =========================================================
   STT STEP 53.5 — Silent smooth SL/TP drag live line
   ========================================================= */

.stt-risk-temp-live-line {
  position: absolute;
  left: 0;
  right: 0;
  height: 0;
  border-top: 2px dashed rgba(250, 204, 21, 0.95);
  pointer-events: none;
  z-index: 24;
  display: none;
  filter: drop-shadow(0 0 6px rgba(250, 204, 21, 0.38));
}

.stt-risk-temp-live-line.sl {
  border-top-color: rgba(248, 113, 113, 0.98);
  filter: drop-shadow(0 0 6px rgba(248, 113, 113, 0.38));
}

.stt-risk-temp-live-line.tp {
  border-top-color: rgba(34, 197, 94, 0.98);
  filter: drop-shadow(0 0 6px rgba(34, 197, 94, 0.38));
}

.stt-risk-drag-handle.dragging {
  z-index: 35;
}

/* =========================================================
   STT STEP 53.6 — Force silent smooth SL/TP drag visual
   ========================================================= */

#sttRiskTempLiveLine,
.stt-risk-temp-live-line {
  position: absolute;
  left: 0;
  right: 0;
  height: 0;
  border-top: 2px dashed rgba(250, 204, 21, 0.96);
  pointer-events: none;
  z-index: 50;
  display: none;
  filter: drop-shadow(0 0 7px rgba(250, 204, 21, 0.38));
}

#sttRiskTempLiveLine.sl,
.stt-risk-temp-live-line.sl {
  border-top-color: rgba(248, 113, 113, 0.98);
  filter: drop-shadow(0 0 7px rgba(248, 113, 113, 0.40));
}

#sttRiskTempLiveLine.tp,
.stt-risk-temp-live-line.tp {
  border-top-color: rgba(34, 197, 94, 0.98);
  filter: drop-shadow(0 0 7px rgba(34, 197, 94, 0.40));
}

.stt-risk-dragging-active {
  touch-action: none !important;
  user-select: none !important;
}

.stt-risk-drag-handle.dragging {
  z-index: 60 !important;
  transform: scale(1.05);
}

/* =========================================================
   STT STEP 53.8 — Final smooth SL/TP drag live line
   ========================================================= */

#sttRiskDragLiveLineFinal {
  position: absolute;
  left: 0;
  right: 0;
  height: 0;
  border-top: 2px dashed rgba(250, 204, 21, 0.98);
  pointer-events: none;
  z-index: 90;
  display: none;
  filter: drop-shadow(0 0 8px rgba(250, 204, 21, 0.45));
}

#sttRiskDragLiveLineFinal.sl {
  border-top-color: rgba(248, 113, 113, 0.98);
  filter: drop-shadow(0 0 8px rgba(248, 113, 113, 0.45));
}

#sttRiskDragLiveLineFinal.tp {
  border-top-color: rgba(34, 197, 94, 0.98);
  filter: drop-shadow(0 0 8px rgba(34, 197, 94, 0.45));
}

.stt-risk-dragging-active {
  touch-action: none !important;
  user-select: none !important;
}

.stt-risk-drag-handle.dragging {
  z-index: 100 !important;
  transform: scale(1.06);
  cursor: ns-resize !important;
}

/* =========================================================
   STT STEP 53.9 — Final active SL/TP drag listener visual
   ========================================================= */

#sttRiskDragLiveLineFinal {
  position: absolute;
  left: 0;
  right: 0;
  height: 0;
  border-top: 2px dashed rgba(250, 204, 21, 0.98);
  pointer-events: none;
  z-index: 90;
  display: none;
  filter: drop-shadow(0 0 8px rgba(250, 204, 21, 0.45));
}

#sttRiskDragLiveLineFinal.sl {
  border-top-color: rgba(248, 113, 113, 0.98);
  filter: drop-shadow(0 0 8px rgba(248, 113, 113, 0.45));
}

#sttRiskDragLiveLineFinal.tp {
  border-top-color: rgba(34, 197, 94, 0.98);
  filter: drop-shadow(0 0 8px rgba(34, 197, 94, 0.45));
}

.stt-risk-dragging-active {
  touch-action: none !important;
  user-select: none !important;
}

.stt-risk-drag-handle.dragging {
  z-index: 100 !important;
  transform: scale(1.06);
  cursor: ns-resize !important;
}

/* =========================================================
   STT STEP 53.10 — Stable SL/TP drag live line + price tag
   ========================================================= */

.stt-risk-drag-live-wrap-final {
  position: absolute;
  left: 0;
  right: 0;
  height: 0;
  pointer-events: none;
  z-index: 95;
  display: none;
}

.stt-risk-drag-live-line-final {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 0;
  border-top: 2px dashed rgba(250, 204, 21, 0.98);
  filter: drop-shadow(0 0 8px rgba(250, 204, 21, 0.45));
}

.stt-risk-drag-live-price-final {
  position: absolute;
  right: 6px;
  top: -13px;
  min-height: 24px;
  align-items: center;
  justify-content: center;
  padding: 0 8px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.94);
  color: #f8fafc;
  border: 1px solid rgba(250, 204, 21, 0.75);
  font-size: 10px;
  font-weight: 950;
  white-space: nowrap;
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(10px);
}

.stt-risk-drag-live-wrap-final.sl .stt-risk-drag-live-line-final {
  border-top-color: rgba(248, 113, 113, 0.98);
  filter: drop-shadow(0 0 8px rgba(248, 113, 113, 0.45));
}

.stt-risk-drag-live-wrap-final.sl .stt-risk-drag-live-price-final {
  background: rgba(127, 29, 29, 0.94);
  border-color: rgba(248, 113, 113, 0.86);
  color: #fee2e2;
}

.stt-risk-drag-live-wrap-final.tp .stt-risk-drag-live-line-final {
  border-top-color: rgba(34, 197, 94, 0.98);
  filter: drop-shadow(0 0 8px rgba(34, 197, 94, 0.45));
}

.stt-risk-drag-live-wrap-final.tp .stt-risk-drag-live-price-final {
  background: rgba(22, 101, 52, 0.94);
  border-color: rgba(34, 197, 94, 0.86);
  color: #dcfce7;
}

/* Keep the active dragged handle visible, but reduce old visual clutter while dragging */
.stt-risk-drag-live-active .stt-risk-drag-handle:not(.dragging) {
  opacity: 0.35;
}

.stt-risk-drag-handle.dragging {
  opacity: 1 !important;
}

@media (max-width: 720px) {
  .stt-risk-drag-live-price-final {
    right: 58px;
    min-height: 23px;
    font-size: 9px;
    padding: 0 7px;
  }
}

/* =========================================================
   STT STEP 53.12 — Hide old static SL/TP visuals while dragging
   ========================================================= */

.stt-risk-drag-live-active .stt-risk-drag-handle:not(.dragging) {
  opacity: 0.12 !important;
}

.stt-risk-drag-live-active #sttRiskDragLiveLineFinal,
.stt-risk-drag-live-active #sttRiskDragLiveLineActual,
.stt-risk-drag-live-active #sttRiskTempLiveLine,
.stt-risk-drag-live-active .stt-risk-drag-live-wrap-final {
  z-index: 120 !important;
}

.stt-risk-drag-live-active .stt-risk-drag-handle.dragging {
  opacity: 1 !important;
  z-index: 130 !important;
}

/* =========================================================
   STT STEP 53.13 — Hide duplicate right price tag during SL/TP drag
   ========================================================= */

/* Hide the right-side price tag on the temporary moving drag line.
   Keep only the in-chart SL/TP drag handle label visible. */
.stt-risk-drag-live-price-final {
  display: none !important;
}

/* During drag, old risk handles are dimmed and the dragged one remains visible. */
.stt-risk-drag-live-active .stt-risk-drag-handle:not(.dragging) {
  opacity: 0.08 !important;
}

.stt-risk-drag-live-active .stt-risk-drag-handle.dragging {
  opacity: 1 !important;
  z-index: 140 !important;
}

/* Make the moving line itself clear enough without showing a second price tag. */
.stt-risk-drag-live-active #sttRiskDragLiveLineFinal,
.stt-risk-drag-live-active #sttRiskDragLiveLineActual,
.stt-risk-drag-live-active #sttRiskTempLiveLine,
.stt-risk-drag-live-active .stt-risk-drag-live-wrap-final {
  z-index: 130 !important;
}

/* =========================================================
   STT STEP 53.13R.1 — Keep opposite SL/TP tag visible while dragging
   ========================================================= */

/* Earlier drag patches dimmed non-drag handles. Keep the opposite SL/TP tag visible. */
.stt-risk-drag-live-active .stt-risk-drag-handle:not(.dragging),
.stt-risk-drag-live-active .stt-risk-drag-handle-v2:not(.dragging),
.stt-risk-drag-live-active .stt-risk-edit-handle:not(.dragging) {
  opacity: 1 !important;
  visibility: visible !important;
}

/* Keep opposite static SL/TP label visible too. */
.stt-risk-drag-live-active .stt-risk-static-line-wrap:not(.stt-risk-line-being-dragged),
.stt-risk-drag-live-active .stt-risk-static-price {
  opacity: 1 !important;
  visibility: visible !important;
}

/* =========================================================
   STT STEP54 — Safe SL/TP clear/remove button
   Separate from draggable SL/TP handle to avoid drag conflict.
   ========================================================= */
.stt-risk-clear-btn {
  position: absolute;
  z-index: 67;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.20);
  background: rgba(8, 14, 28, 0.88);
  color: #fff;
  font-size: 13px;
  line-height: 1;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  user-select: none;
  touch-action: manipulation;
  box-shadow: 0 5px 14px rgba(0,0,0,0.24);
}

.stt-risk-clear-btn.sl {
  border-color: rgba(255, 90, 120, 0.58);
  color: #ff8fa3;
}

.stt-risk-clear-btn.tp {
  border-color: rgba(37, 211, 102, 0.58);
  color: #69f0a4;
}

.stt-risk-clear-btn:hover {
  transform: translateY(-1px);
  filter: brightness(1.16);
}

.stt-risk-drag-live-active .stt-risk-clear-btn:not(.dragging) {
  opacity: 0;
  pointer-events: none;
}

/* =========================================================
   STT STEP54.3R.3 — Compact centered SL/TP clear cross
   Final override because older risk CSS blocks exist below/above.
   ========================================================= */
.stt-chart-risk-drag-layer .stt-risk-clear-btn {
  width: 14px !important;
  height: 14px !important;
  min-width: 14px !important;
  min-height: 14px !important;
  padding: 0 !important;
  border-radius: 999px !important;
  font-size: 10px !important;
  line-height: 10px !important;
  font-weight: 800 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  transform: none !important;
  box-shadow: 0 3px 8px rgba(0,0,0,0.22) !important;
}

.stt-chart-risk-drag-layer .stt-risk-clear-btn:hover {
  transform: scale(1.04) !important;
}

.stt-chart-risk-drag-layer .stt-risk-clear-btn.sl {
  color: #ff9aaa !important;
}

.stt-chart-risk-drag-layer .stt-risk-clear-btn.tp {
  color: #7af2ad !important;
}

/* STT STEP54.3R.6 — SL/TP clear button press feedback */
.stt-chart-risk-drag-layer .stt-risk-clear-btn.pressed {
  transform: scale(0.92) !important;
  filter: brightness(1.25) !important;
}

/* STT STEP54.3R.8 — force SL/TP clear cross clickable */
.stt-chart-risk-drag-layer .stt-risk-clear-btn {
  z-index: 9999 !important;
  pointer-events: auto !important;
  cursor: pointer !important;
}

.stt-chart-risk-drag-layer .stt-risk-clear-btn * {
  pointer-events: none !important;
}

/* =========================================================
   STT STEP55 — Drag BUY/SELL entry label to add missing SL/TP
   ========================================================= */
.stt-line-close-btn.stt-line-close-buyx .stt-entry-risk-drag-grip {
  cursor: ns-resize;
  user-select: none;
  touch-action: none;
}

.stt-line-close-btn.stt-line-close-buyx .stt-entry-risk-drag-grip.dragging {
  filter: brightness(1.25);
}

.stt-line-close-btn.stt-line-close-buyx .stt-entry-risk-drag-grip.tp {
  color: #7af2ad !important;
}

.stt-line-close-btn.stt-line-close-buyx .stt-entry-risk-drag-grip.sl {
  color: #ff9aaa !important;
}

.stt-entry-risk-dragging-active #sttMarketCoinChart {
  cursor: ns-resize;
}

.stt-entry-risk-preview-wrap {
  position: absolute;
  left: 0;
  right: 0;
  z-index: 9998;
  pointer-events: none;
  display: none;
}

.stt-entry-risk-preview-line {
  position: absolute;
  left: 0;
  right: 54px;
  top: 0;
  height: 0;
  border-top: 2px dotted rgba(255,255,255,0.75);
}

.stt-entry-risk-preview-tag {
  position: absolute;
  right: 58px;
  top: -12px;
  min-width: 72px;
  height: 24px;
  padding: 0 9px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 900;
  color: #fff;
  background: rgba(12, 18, 32, 0.94);
  border: 1px solid rgba(255,255,255,0.18);
  box-shadow: 0 8px 22px rgba(0,0,0,0.26);
}

.stt-entry-risk-preview-wrap.tp .stt-entry-risk-preview-line {
  border-top-color: rgba(34,197,94,0.95);
}

.stt-entry-risk-preview-wrap.tp .stt-entry-risk-preview-tag {
  border-color: rgba(34,197,94,0.52);
  color: #7af2ad;
}

.stt-entry-risk-preview-wrap.sl .stt-entry-risk-preview-line {
  border-top-color: rgba(239,68,68,0.95);
}

.stt-entry-risk-preview-wrap.sl .stt-entry-risk-preview-tag {
  border-color: rgba(239,68,68,0.52);
  color: #ff9aaa;
}

/* =========================================================
   STT STEP55.2R — Separate entry drag label + close X
   ========================================================= */
.stt-entry-risk-label-btn {
  position: absolute;
  z-index: 75;
  height: 24px;
  min-width: 54px;
  border-radius: 999px;
  padding: 0 10px;
  border: 1px solid rgba(255,255,255,0.18);
  color: #fff;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: ns-resize;
  user-select: none;
  touch-action: none;
  box-shadow: 0 8px 20px rgba(0,0,0,0.26);
}

.stt-entry-risk-label-btn.buy {
  background: rgba(22, 163, 74, 0.78);
  border-color: rgba(34,197,94,0.55);
}

.stt-entry-risk-label-btn.sell {
  background: rgba(220, 38, 38, 0.76);
  border-color: rgba(239,68,68,0.55);
}

.stt-entry-risk-label-btn.dragging {
  filter: brightness(1.25);
  transform: translateY(-1px);
}

.stt-entry-risk-label-btn.tp {
  box-shadow: 0 0 0 2px rgba(34,197,94,0.22), 0 8px 20px rgba(0,0,0,0.26);
}

.stt-entry-risk-label-btn.sl {
  box-shadow: 0 0 0 2px rgba(239,68,68,0.22), 0 8px 20px rgba(0,0,0,0.26);
}

.stt-line-close-btn.stt-line-close-entry-x {
  position: absolute;
  z-index: 76;
  width: 14px !important;
  height: 14px !important;
  min-width: 14px !important;
  min-height: 14px !important;
  padding: 0 !important;
  border-radius: 999px !important;
  font-size: 10px !important;
  line-height: 10px !important;
  font-weight: 900 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  cursor: pointer !important;
  box-shadow: 0 3px 8px rgba(0,0,0,0.22) !important;
}

.stt-line-close-btn.stt-line-close-entry-x.buy {
  color: #7af2ad !important;
  background: rgba(8,14,28,0.88) !important;
  border-color: rgba(34,197,94,0.52) !important;
}

.stt-line-close-btn.stt-line-close-entry-x.sell {
  color: #ff9aaa !important;
  background: rgba(8,14,28,0.88) !important;
  border-color: rgba(239,68,68,0.52) !important;
}

.stt-entry-risk-dragging-active #sttMarketCoinChart {
  cursor: ns-resize;
}

.stt-entry-risk-preview-wrap {
  position: absolute;
  left: 0;
  right: 0;
  z-index: 9998;
  pointer-events: none;
  display: none;
}

.stt-entry-risk-preview-line {
  position: absolute;
  left: 0;
  right: 54px;
  top: 0;
  height: 0;
  border-top: 2px dotted rgba(255,255,255,0.75);
}

.stt-entry-risk-preview-tag {
  position: absolute;
  right: 58px;
  top: -12px;
  min-width: 72px;
  height: 24px;
  padding: 0 9px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 900;
  color: #fff;
  background: rgba(12, 18, 32, 0.94);
  border: 1px solid rgba(255,255,255,0.18);
  box-shadow: 0 8px 22px rgba(0,0,0,0.26);
}

.stt-entry-risk-preview-wrap.tp .stt-entry-risk-preview-line {
  border-top-color: rgba(34,197,94,0.95);
}

.stt-entry-risk-preview-wrap.tp .stt-entry-risk-preview-tag {
  border-color: rgba(34,197,94,0.52);
  color: #7af2ad;
}

.stt-entry-risk-preview-wrap.sl .stt-entry-risk-preview-line {
  border-top-color: rgba(239,68,68,0.95);
}

.stt-entry-risk-preview-wrap.sl .stt-entry-risk-preview-tag {
  border-color: rgba(239,68,68,0.52);
  color: #ff9aaa;
}

/* =========================================================
   STT STEP55.2R.2 — Separate BUY/SELL drag label + close X
   Final override.
   ========================================================= */
.stt-entry-risk-label-btn {
  position: absolute;
  z-index: 75;
  height: 24px;
  min-width: 54px;
  border-radius: 999px;
  padding: 0 10px;
  border: 1px solid rgba(255,255,255,0.18);
  color: #fff;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: ns-resize;
  user-select: none;
  touch-action: none;
  box-shadow: 0 8px 20px rgba(0,0,0,0.26);
}

.stt-entry-risk-label-btn.buy {
  background: rgba(22, 163, 74, 0.78);
  border-color: rgba(34,197,94,0.55);
}

.stt-entry-risk-label-btn.sell {
  background: rgba(220, 38, 38, 0.76);
  border-color: rgba(239,68,68,0.55);
}

.stt-entry-risk-label-btn.dragging {
  filter: brightness(1.25);
  transform: translateY(-1px);
}

.stt-entry-risk-label-btn.tp {
  box-shadow: 0 0 0 2px rgba(34,197,94,0.22), 0 8px 20px rgba(0,0,0,0.26);
}

.stt-entry-risk-label-btn.sl {
  box-shadow: 0 0 0 2px rgba(239,68,68,0.22), 0 8px 20px rgba(0,0,0,0.26);
}

.stt-line-close-btn.stt-line-close-entry-x {
  position: absolute;
  z-index: 76;
  width: 14px !important;
  height: 14px !important;
  min-width: 14px !important;
  min-height: 14px !important;
  padding: 0 !important;
  border-radius: 999px !important;
  font-size: 10px !important;
  line-height: 10px !important;
  font-weight: 900 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  cursor: pointer !important;
  box-shadow: 0 3px 8px rgba(0,0,0,0.22) !important;
}

.stt-line-close-btn.stt-line-close-entry-x.buy {
  color: #7af2ad !important;
  background: rgba(8,14,28,0.88) !important;
  border-color: rgba(34,197,94,0.52) !important;
}

.stt-line-close-btn.stt-line-close-entry-x.sell {
  color: #ff9aaa !important;
  background: rgba(8,14,28,0.88) !important;
  border-color: rgba(239,68,68,0.52) !important;
}

/* =========================================================
   STT STEP55.2R.3 — Separate BUY/SELL drag label + close X
   Final override.
   ========================================================= */
.stt-entry-risk-label-btn {
  position: absolute;
  z-index: 75;
  height: 24px;
  min-width: 54px;
  border-radius: 999px;
  padding: 0 10px;
  border: 1px solid rgba(255,255,255,0.18);
  color: #fff;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: ns-resize;
  user-select: none;
  touch-action: none;
  box-shadow: 0 8px 20px rgba(0,0,0,0.26);
}

.stt-entry-risk-label-btn.buy {
  background: rgba(22, 163, 74, 0.78);
  border-color: rgba(34,197,94,0.55);
}

.stt-entry-risk-label-btn.sell {
  background: rgba(220, 38, 38, 0.76);
  border-color: rgba(239,68,68,0.55);
}

.stt-entry-risk-label-btn.dragging {
  filter: brightness(1.25);
  transform: translateY(-1px);
}

.stt-entry-risk-label-btn.tp {
  box-shadow: 0 0 0 2px rgba(34,197,94,0.22), 0 8px 20px rgba(0,0,0,0.26);
}

.stt-entry-risk-label-btn.sl {
  box-shadow: 0 0 0 2px rgba(239,68,68,0.22), 0 8px 20px rgba(0,0,0,0.26);
}

.stt-line-close-btn.stt-line-close-entry-x {
  position: absolute;
  z-index: 76;
  width: 14px !important;
  height: 14px !important;
  min-width: 14px !important;
  min-height: 14px !important;
  padding: 0 !important;
  border-radius: 999px !important;
  font-size: 10px !important;
  line-height: 10px !important;
  font-weight: 900 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  cursor: pointer !important;
  box-shadow: 0 3px 8px rgba(0,0,0,0.22) !important;
}

.stt-line-close-btn.stt-line-close-entry-x.buy {
  color: #7af2ad !important;
  background: rgba(8,14,28,0.88) !important;
  border-color: rgba(34,197,94,0.52) !important;
}

.stt-line-close-btn.stt-line-close-entry-x.sell {
  color: #ff9aaa !important;
  background: rgba(8,14,28,0.88) !important;
  border-color: rgba(239,68,68,0.52) !important;
}

/* =========================================================
   STT STEP55.2R.4 — Make separated BUY/SELL label draggable
   Parent chart overlay layers can have pointer-events disabled,
   so force entry label and close X to receive pointer events.
   ========================================================= */
.stt-chart-line-close-layer .stt-entry-risk-label-btn {
  pointer-events: auto !important;
  cursor: ns-resize !important;
  touch-action: none !important;
  user-select: none !important;
  z-index: 9998 !important;
}

.stt-chart-line-close-layer .stt-entry-risk-label-btn * {
  pointer-events: none !important;
}

.stt-chart-line-close-layer .stt-line-close-btn.stt-line-close-entry-x {
  pointer-events: auto !important;
  z-index: 9999 !important;
}

.stt-chart-line-close-layer .stt-line-close-btn.stt-line-close-entry-x * {
  pointer-events: none !important;
}

/* =========================================================
   STT STEP55.4 — Mobile chart overlay alignment + flicker fix
   Fixes:
   1) BUY/SELL close X going into price column on phones.
   2) SL/TP tags and cross buttons flickering during touch/scroll.
   ========================================================= */

@media (max-width: 768px) {
  /* Keep BUY/SELL entry label and close X away from price scale */
  .stt-chart-line-close-layer .stt-entry-risk-label-btn {
    right: 128px !important;
    z-index: 9998 !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    transform: translateZ(0);
    backface-visibility: hidden;
    will-change: top;
  }

  .stt-chart-line-close-layer .stt-line-close-btn.stt-line-close-entry-x {
    right: 112px !important;
    z-index: 9999 !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    transform: translateZ(0);
    backface-visibility: hidden;
    will-change: top;
  }

  /* Keep SL/TP handles and their clear crosses stable during mobile chart touch */
  .stt-chart-risk-drag-layer,
  .stt-chart-line-close-layer {
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: none;
    transform: translateZ(0);
    backface-visibility: hidden;
    will-change: transform;
  }

  .stt-chart-risk-drag-layer .stt-risk-drag-handle,
  .stt-chart-risk-drag-layer .stt-risk-clear-btn,
  .stt-chart-line-close-layer .stt-entry-risk-label-btn,
  .stt-chart-line-close-layer .stt-line-close-entry-x {
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
  }

  /*
    Old mobile touch rules hide/fade overlays while chart is moving.
    For current stable chart tools, overlays must remain visible.
  */
  .stt-chart-touch-moving .stt-chart-line-close-layer,
  .stt-chart-touch-moving .stt-chart-risk-drag-layer,
  .stt-chart-touch-moving .stt-line-close-btn,
  .stt-chart-touch-moving .stt-line-close-btn.stt-line-close-buyx,
  .stt-chart-touch-moving .stt-line-close-btn.stt-line-close-entry-x,
  .stt-chart-touch-moving .stt-entry-risk-label-btn,
  .stt-chart-touch-moving .stt-risk-drag-handle,
  .stt-chart-touch-moving .stt-risk-clear-btn {
    opacity: 1 !important;
    visibility: visible !important;
  }

  /*
    During actual SL/TP drag, only non-drag old risk handles may hide,
    but entry BUY/SELL labels and close X should stay stable.
  */
  .stt-risk-drag-live-active .stt-entry-risk-label-btn,
  .stt-risk-drag-live-active .stt-line-close-entry-x {
    opacity: 1 !important;
    visibility: visible !important;
  }

  /* Keep clear crosses compact and centered on phones */
  .stt-chart-risk-drag-layer .stt-risk-clear-btn {
    width: 14px !important;
    height: 14px !important;
    min-width: 14px !important;
    min-height: 14px !important;
    font-size: 10px !important;
    line-height: 10px !important;
    z-index: 9999 !important;
  }
}

/* =========================================================
   STT STEP55.4R — Root mobile overlay flicker fix
   JS pauses re-render during touch; this disables visual opacity transitions.
   ========================================================= */
@media (max-width: 768px) {
  .stt-chart-line-close-layer,
  .stt-chart-risk-drag-layer,
  .stt-entry-risk-label-btn,
  .stt-line-close-btn.stt-line-close-entry-x,
  .stt-risk-drag-handle,
  .stt-risk-clear-btn {
    transition: none !important;
    animation: none !important;
    opacity: 1 !important;
    visibility: visible !important;
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
  }

  .stt-chart-touch-moving .stt-entry-risk-label-btn,
  .stt-chart-touch-moving .stt-line-close-btn.stt-line-close-entry-x,
  .stt-chart-touch-moving .stt-risk-drag-handle,
  .stt-chart-touch-moving .stt-risk-clear-btn {
    transition: none !important;
    opacity: 1 !important;
    visibility: visible !important;
  }
}

/* =========================================================
   STT STEP55.4R.4 — Safe mobile overlay no-flicker fix
   Keeps chart trade/risk labels visible while touchmove rerender is skipped in JS.
   ========================================================= */
@media (max-width: 768px) {
  .stt-chart-line-close-layer,
  .stt-chart-risk-drag-layer {
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: none !important;
  }

  .stt-entry-risk-label-btn,
  .stt-line-close-btn.stt-line-close-entry-x,
  .stt-risk-drag-handle,
  .stt-risk-clear-btn {
    opacity: 1 !important;
    visibility: visible !important;
    transition: none !important;
    animation: none !important;
    pointer-events: auto !important;
  }

  .stt-chart-touch-moving .stt-entry-risk-label-btn,
  .stt-chart-touch-moving .stt-line-close-btn.stt-line-close-entry-x,
  .stt-chart-touch-moving .stt-risk-drag-handle,
  .stt-chart-touch-moving .stt-risk-clear-btn {
    opacity: 1 !important;
    visibility: visible !important;
  }
}

/* =========================================================
   STT STEP55.4R.5 — Mobile overlay live position sync
   Prevent transition lag while JS updates top positions.
   ========================================================= */
@media (max-width: 768px) {
  .stt-entry-risk-label-btn,
  .stt-line-close-btn.stt-line-close-entry-x,
  .stt-risk-drag-handle,
  .stt-risk-clear-btn {
    transition-property: none !important;
    will-change: top !important;
  }
}

/* =========================================================
   STT STEP55.6 — Professional Close All confirm modal
   ========================================================= */
.stt-close-all-confirm-overlay {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(2, 6, 23, 0.62);
  backdrop-filter: blur(8px);
}

.stt-close-all-confirm-overlay.show {
  display: flex;
}

.stt-close-all-confirm-card {
  width: min(420px, calc(100vw - 32px));
  border-radius: 22px;
  padding: 22px;
  border: 1px solid rgba(248, 113, 113, 0.32);
  background:
    radial-gradient(circle at top left, rgba(248, 113, 113, 0.20), transparent 34%),
    linear-gradient(145deg, rgba(15, 23, 42, 0.98), rgba(2, 6, 23, 0.98));
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.46);
  color: #e5e7eb;
  text-align: center;
}

.stt-close-all-confirm-icon {
  width: 44px;
  height: 44px;
  margin: 0 auto 12px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fecaca;
  background: rgba(127, 29, 29, 0.62);
  border: 1px solid rgba(248, 113, 113, 0.42);
  font-size: 22px;
  font-weight: 900;
}

.stt-close-all-confirm-title {
  font-size: 20px;
  font-weight: 950;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
}

.stt-close-all-confirm-text {
  font-size: 14px;
  color: rgba(226, 232, 240, 0.88);
  line-height: 1.5;
}

.stt-close-all-confirm-sub {
  margin-top: 6px;
  color: rgba(148, 163, 184, 0.96);
  font-size: 13px;
}

.stt-close-all-confirm-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 20px;
}

.stt-close-all-cancel,
.stt-close-all-ok {
  height: 44px;
  border-radius: 14px;
  border: 1px solid rgba(148, 163, 184, 0.28);
  font-weight: 950;
  cursor: pointer;
}

.stt-close-all-cancel {
  color: #cbd5e1;
  background: rgba(15, 23, 42, 0.86);
}

.stt-close-all-ok {
  color: #fff;
  border-color: rgba(248, 113, 113, 0.48);
  background: linear-gradient(135deg, rgba(220, 38, 38, 0.98), rgba(127, 29, 29, 0.98));
  box-shadow: 0 12px 28px rgba(220, 38, 38, 0.28);
}

.stt-close-all-cancel:hover,
.stt-close-all-ok:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

@media (max-width: 560px) {
  .stt-close-all-confirm-card {
    border-radius: 20px;
    padding: 20px 16px;
  }

  .stt-close-all-confirm-actions {
    gap: 10px;
  }

  .stt-close-all-cancel,
  .stt-close-all-ok {
    height: 42px;
  }
}

/* =========================================================
   STT STEP55.6R.2 — Professional Close All confirm modal
   ========================================================= */
.stt-close-all-confirm-overlay {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(2, 6, 23, 0.62);
  backdrop-filter: blur(8px);
}

.stt-close-all-confirm-overlay.show {
  display: flex;
}

.stt-close-all-confirm-card {
  width: min(420px, calc(100vw - 32px));
  border-radius: 22px;
  padding: 22px;
  border: 1px solid rgba(248, 113, 113, 0.32);
  background:
    radial-gradient(circle at top left, rgba(248, 113, 113, 0.20), transparent 34%),
    linear-gradient(145deg, rgba(15, 23, 42, 0.98), rgba(2, 6, 23, 0.98));
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.46);
  color: #e5e7eb;
  text-align: center;
}

.stt-close-all-confirm-icon {
  width: 44px;
  height: 44px;
  margin: 0 auto 12px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fecaca;
  background: rgba(127, 29, 29, 0.62);
  border: 1px solid rgba(248, 113, 113, 0.42);
  font-size: 22px;
  font-weight: 900;
}

.stt-close-all-confirm-title {
  font-size: 20px;
  font-weight: 950;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
}

.stt-close-all-confirm-text {
  font-size: 14px;
  color: rgba(226, 232, 240, 0.88);
  line-height: 1.5;
}

.stt-close-all-confirm-sub {
  margin-top: 6px;
  color: rgba(148, 163, 184, 0.96);
  font-size: 13px;
}

.stt-close-all-confirm-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 20px;
}

.stt-close-all-cancel,
.stt-close-all-ok {
  height: 44px;
  border-radius: 14px;
  border: 1px solid rgba(148, 163, 184, 0.28);
  font-weight: 950;
  cursor: pointer;
}

.stt-close-all-cancel {
  color: #cbd5e1;
  background: rgba(15, 23, 42, 0.86);
}

.stt-close-all-ok {
  color: #fff;
  border-color: rgba(248, 113, 113, 0.48);
  background: linear-gradient(135deg, rgba(220, 38, 38, 0.98), rgba(127, 29, 29, 0.98));
  box-shadow: 0 12px 28px rgba(220, 38, 38, 0.28);
}

.stt-close-all-cancel:hover,
.stt-close-all-ok:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

@media (max-width: 560px) {
  .stt-close-all-confirm-card {
    border-radius: 20px;
    padding: 20px 16px;
  }

  .stt-close-all-confirm-actions {
    gap: 10px;
  }

  .stt-close-all-cancel,
  .stt-close-all-ok {
    height: 42px;
  }
}


/* =========================================================
   STT STEP55.10 — Signal Center Close All beside Refresh
   ========================================================= */
.stt-signal-monitor-actions-plus {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  flex-wrap: nowrap;
}

.stt-signal-monitor-actions-plus button {
  white-space: nowrap;
}

.stt-signal-close-all-btn {
  min-height: 42px;
  padding: 0 22px;
  border-radius: 16px;
  border: 1px solid rgba(248, 113, 113, 0.46);
  color: #fff;
  font-weight: 950;
  cursor: pointer;
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.98), rgba(154, 52, 18, 0.98));
  box-shadow: 0 12px 28px rgba(239, 68, 68, 0.22);
}

.stt-signal-close-all-btn:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

.stt-signal-close-all-btn:disabled {
  opacity: 0.65;
  cursor: wait;
  transform: none;
}

/* Desktop: action group stays on right; Refresh appears left of Close All */
@media (min-width: 769px) {
  .stt-signal-monitor-actions-plus {
    margin-left: auto;
  }
}

/* Phone: Refresh + Close All side-by-side below title area */
@media (max-width: 768px) {
  .stt-signal-monitor-actions-plus {
    width: 100%;
    justify-content: flex-start;
    gap: 10px;
    margin-top: 12px;
  }

  .stt-signal-monitor-actions-plus button {
    min-width: 112px;
    height: 42px;
    padding: 0 16px;
    border-radius: 15px;
  }

  .stt-signal-close-all-btn {
    min-width: 120px;
  }
}

/* =========================================================
   STT STEP55.10R — Signal Center Close All mobile right alignment
   ========================================================= */
@media (max-width: 768px) {
  .stt-signal-monitor-actions-plus {
    width: 100% !important;
    justify-content: flex-end !important;
    gap: 10px !important;
    padding-right: 2px !important;
  }

  .stt-signal-monitor-actions-plus button {
    min-width: 116px !important;
    height: 42px !important;
  }

  .stt-signal-close-all-btn {
    min-width: 124px !important;
    margin-left: 0 !important;
  }
}

/* =========================================================
   STT STEP55.10R.2 — Signal Close All confirm card + mobile spacing
   ========================================================= */

/* Phone: Refresh left edge, Close All right edge */
@media (max-width: 768px) {
  .stt-signal-monitor-actions-plus {
    width: 100% !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    gap: 12px !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
  }

  .stt-signal-monitor-actions-plus button {
    width: calc(50% - 6px) !important;
    min-width: 0 !important;
    max-width: none !important;
    height: 42px !important;
    padding: 0 12px !important;
  }

  .stt-signal-close-all-btn {
    margin-left: 0 !important;
  }
}

/* Dedicated Signal Center Close All confirm modal */
.stt-signal-close-all-confirm-overlay {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(2, 6, 23, 0.64);
  backdrop-filter: blur(8px);
}

.stt-signal-close-all-confirm-overlay.show {
  display: flex;
}

.stt-signal-close-all-confirm-card {
  width: min(430px, calc(100vw - 32px));
  border-radius: 22px;
  padding: 22px;
  border: 1px solid rgba(248, 113, 113, 0.34);
  background:
    radial-gradient(circle at top left, rgba(248, 113, 113, 0.20), transparent 34%),
    linear-gradient(145deg, rgba(15, 23, 42, 0.98), rgba(2, 6, 23, 0.98));
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.46);
  color: #e5e7eb;
  text-align: center;
}

.stt-signal-close-all-confirm-icon {
  width: 44px;
  height: 44px;
  margin: 0 auto 12px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fecaca;
  background: rgba(127, 29, 29, 0.62);
  border: 1px solid rgba(248, 113, 113, 0.42);
  font-size: 22px;
  font-weight: 900;
}

.stt-signal-close-all-confirm-title {
  font-size: 20px;
  font-weight: 950;
  letter-spacing: -0.02em;
  margin-bottom: 8px;
}

.stt-signal-close-all-confirm-text {
  font-size: 14px;
  color: rgba(226, 232, 240, 0.9);
  line-height: 1.5;
}

.stt-signal-close-all-confirm-sub {
  margin-top: 6px;
  color: rgba(148, 163, 184, 0.96);
  font-size: 13px;
}

.stt-signal-close-all-confirm-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 20px;
}

.stt-signal-close-all-cancel,
.stt-signal-close-all-ok {
  height: 44px;
  border-radius: 14px;
  border: 1px solid rgba(148, 163, 184, 0.28);
  font-weight: 950;
  cursor: pointer;
}

.stt-signal-close-all-cancel {
  color: #cbd5e1;
  background: rgba(15, 23, 42, 0.86);
}

.stt-signal-close-all-ok {
  color: #fff;
  border-color: rgba(248, 113, 113, 0.48);
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.98), rgba(154, 52, 18, 0.98));
  box-shadow: 0 12px 28px rgba(239, 68, 68, 0.28);
}

.stt-signal-close-all-cancel:hover,
.stt-signal-close-all-ok:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

/* =========================================================
   STT STEP55.10R.3 — Close All mobile tap animation polish
   Removes browser square/focus highlight and uses short glow instead.
   ========================================================= */
.stt-signal-close-all-btn,
.stt-signal-close-all-btn:focus,
.stt-signal-close-all-btn:focus-visible,
.stt-signal-close-all-btn:active {
  outline: none !important;
  -webkit-tap-highlight-color: transparent !important;
  -webkit-touch-callout: none !important;
  box-shadow: 0 12px 28px rgba(239, 68, 68, 0.22) !important;
}

.stt-signal-close-all-btn::-moz-focus-inner {
  border: 0 !important;
}

.stt-signal-close-all-btn.stt-signal-close-all-tapped,
.stt-signal-close-all-btn:active {
  animation: sttSignalCloseAllGlowTap 0.18s ease-out 1 !important;
}

@keyframes sttSignalCloseAllGlowTap {
  0% {
    transform: scale(1);
    box-shadow:
      0 0 0 0 rgba(248, 113, 113, 0.0),
      0 12px 28px rgba(239, 68, 68, 0.22);
    filter: brightness(1);
  }
  45% {
    transform: scale(0.985);
    box-shadow:
      0 0 0 5px rgba(248, 113, 113, 0.24),
      0 14px 32px rgba(239, 68, 68, 0.34);
    filter: brightness(1.12);
  }
  100% {
    transform: scale(1);
    box-shadow:
      0 0 0 0 rgba(248, 113, 113, 0.0),
      0 12px 28px rgba(239, 68, 68, 0.22);
    filter: brightness(1);
  }
}

/* Remove any persistent focus square from confirm modal buttons too */
.stt-signal-close-all-confirm-overlay button,
.stt-signal-close-all-confirm-overlay button:focus,
.stt-signal-close-all-confirm-overlay button:focus-visible,
.stt-signal-close-all-confirm-overlay button:active {
  outline: none !important;
  -webkit-tap-highlight-color: transparent !important;
}

/* Phone-specific: keep tap feedback short and clean */
@media (max-width: 768px) {
  .stt-signal-close-all-btn {
    touch-action: manipulation !important;
  }

  .stt-signal-close-all-btn:focus,
  .stt-signal-close-all-btn:focus-visible {
    box-shadow: 0 12px 28px rgba(239, 68, 68, 0.22) !important;
  }
}

/* STT STEP 58 Admin Live/Testnet Safety UI */
.stt-admin-exchange-safety {
  border: 1px solid rgba(255, 193, 7, 0.22);
}

.stt-admin-safety-box {
  display: grid;
  gap: 14px;
}

.stt-safety-warning {
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255, 193, 7, 0.12);
  border: 1px solid rgba(255, 193, 7, 0.28);
  color: #ffe9a6;
  line-height: 1.5;
}

.stt-safety-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(140px, 1fr));
  gap: 12px;
}

.stt-safety-stat {
  padding: 14px;
  border-radius: 16px;
  background: rgba(255,255,255,0.055);
  border: 1px solid rgba(255,255,255,0.09);
}

.stt-safety-stat span {
  display: block;
  font-size: 12px;
  opacity: 0.75;
  margin-bottom: 6px;
}

.stt-safety-stat b {
  font-size: 20px;
}

.stt-safety-stat.warn {
  border-color: rgba(255, 152, 0, 0.35);
  background: rgba(255, 152, 0, 0.10);
}

.stt-safety-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.danger-btn.stt-emergency-btn {
  background: linear-gradient(135deg, #ff3b30, #9b111e);
  color: #fff;
  border: 0;
  border-radius: 12px;
  padding: 11px 14px;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(255, 59, 48, 0.20);
}

.danger-btn.stt-emergency-btn.live {
  background: linear-gradient(135deg, #ff1744, #6a0010);
}

.stt-safety-two-col {
  display: grid;
  grid-template-columns: repeat(2, minmax(220px, 1fr));
  gap: 12px;
}

.stt-safety-panel {
  padding: 14px;
  border-radius: 16px;
  background: rgba(255,255,255,0.045);
  border: 1px solid rgba(255,255,255,0.08);
}

.stt-safety-panel h3 {
  margin: 0 0 10px;
  font-size: 15px;
}

.stt-safety-mini-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255,255,255,0.07);
}

.stt-safety-mini-row:last-child {
  border-bottom: 0;
}

.stt-safety-table th,
.stt-safety-table td {
  white-space: nowrap;
}

@media (max-width: 760px) {
  .stt-safety-grid,
  .stt-safety-two-col {
    grid-template-columns: 1fr;
  }

  .stt-safety-actions {
    flex-direction: column;
  }

  .danger-btn.stt-emergency-btn,
  .stt-safety-actions .secondary-btn {
    width: 100%;
  }
}

/* STT STEP 58.4E Admin Exchange Safety button polish */
#adminExchangeSafetyPanel .card-header {
  align-items: flex-start;
  gap: 18px;
}

#adminExchangeSafetyPanel .admin-runtime-actions {
  min-width: 180px;
  display: flex;
  justify-content: flex-end;
}

#adminExchangeSafetyPanel .admin-runtime-actions .primary-btn,
#adminExchangeSafetyPanel button[onclick*="loadAdminExchangeSafety"] {
  min-width: 170px;
  width: auto;
  padding: 12px 22px;
  border-radius: 16px;
  white-space: nowrap;
  text-align: center;
  justify-content: center;
  box-shadow: 0 10px 24px rgba(84, 116, 255, 0.22);
}

#adminExchangeSafetyPanel .stt-safety-actions {
  display: grid;
  grid-template-columns: minmax(230px, 1fr) minmax(230px, 1fr) minmax(150px, 0.55fr);
  align-items: stretch;
  gap: 12px;
  max-width: 720px;
}

#adminExchangeSafetyPanel .stt-safety-actions button {
  min-height: 48px;
  width: 100%;
  border-radius: 15px;
  padding: 12px 16px;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

#adminExchangeSafetyPanel .stt-safety-actions .secondary-btn {
  background: linear-gradient(135deg, #248cff, #793cff);
  border: 1px solid rgba(255,255,255,0.16);
  color: #fff;
  font-weight: 800;
  box-shadow: 0 10px 24px rgba(84, 116, 255, 0.20);
}

#adminExchangeSafetyPanel .stt-safety-actions .secondary-btn:hover,
#adminExchangeSafetyPanel .admin-runtime-actions .primary-btn:hover {
  transform: translateY(-1px);
  filter: brightness(1.08);
}

@media (max-width: 900px) {
  #adminExchangeSafetyPanel .card-header {
    flex-direction: column;
  }

  #adminExchangeSafetyPanel .admin-runtime-actions {
    width: 100%;
    justify-content: stretch;
  }

  #adminExchangeSafetyPanel .admin-runtime-actions .primary-btn {
    width: 100%;
  }

  #adminExchangeSafetyPanel .stt-safety-actions {
    grid-template-columns: 1fr;
    max-width: none;
  }
}



/* STT STEP 58.4H Fix Admin Exchange Safety refresh cross-glow/dull effect */


#adminExchangeSafetyPanel.stt-safety-refreshing button[onclick*="loadAdminExchangeSafety"],
#adminExchangeSafetyPanel.stt-safety-refreshing .stt-safety-actions .secondary-btn,
#adminExchangeSafetyPanel.stt-safety-refreshing .admin-runtime-actions .primary-btn {
  pointer-events: auto !important;
  filter: none !important;
  opacity: 1 !important;
  transform: none !important;
}

#adminExchangeSafetyPanel .stt-safety-refresh-active {
  filter: brightness(1.06) !important;
  box-shadow: 0 0 0 1px rgba(255,255,255,0.18), 0 10px 24px rgba(84,116,255,0.24) !important;
}

#adminExchangeSafetyPanel .stt-safety-refresh-active::after {
  display: none !important;
}

/* STT STEP 58.4I Admin Exchange Safety last refreshed timestamp */
#adminExchangeSafetyPanel .stt-safety-last-refresh {
  align-self: center;
  margin-left: auto;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(48, 209, 88, 0.10);
  border: 1px solid rgba(48, 209, 88, 0.22);
  color: #9fffc1;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

@media (max-width: 900px) {
  #adminExchangeSafetyPanel .stt-safety-last-refresh {
    margin-left: 0;
    width: 100%;
    text-align: center;
  }
}


#adminRuntimePanel .card-header {
  align-items: flex-start;
  gap: 18px;
}

#adminRuntimePanel .admin-runtime-actions {
  display: flex;
  justify-content: flex-end;
  min-width: 170px;
}

#adminRuntimePanel button[onclick*="loadAdminRuntimeBots"],
#adminRuntimePanel .primary-btn {
  min-width: 160px !important;
  width: 170px !important;
  max-width: 180px !important;
  min-height: 46px !important;
  border-radius: 15px !important;
  padding: 11px 18px !important;
  white-space: nowrap;
  justify-content: center;
}

#adminRuntimePanel .admin-table-scroll,
#adminRuntimePanel .runtime-table-scroll,
#adminRuntimePanel table.admin-runtime-table {
  overflow-anchor: none;
}




@media (max-width: 900px) {
  #adminRuntimePanel .card-header {
    flex-direction: column;
  }

  #adminRuntimePanel .admin-runtime-actions,
  #adminRuntimePanel button[onclick*="loadAdminRuntimeBots"],
  #adminRuntimePanel .primary-btn {
    width: 100% !important;
    max-width: none !important;
  }
}



/* STT STEP 58.4M Align last refreshed tag with Refresh Safety button */
#adminExchangeSafetyPanel .card-header {
  position: relative;
  display: flex;
  align-items: flex-start;
}

#adminExchangeSafetyPanel .stt-safety-last-refresh {
  position: absolute;
  top: 14px;
  right: 190px;
  margin: 0;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

#adminExchangeSafetyPanel .admin-runtime-actions {
  position: relative;
  z-index: 2;
}

@media (max-width: 900px) {
  #adminExchangeSafetyPanel .stt-safety-last-refresh {
    position: static;
    margin-top: 10px;
    right: auto;
    top: auto;
    width: 100%;
  }
}

/* STT STEP 58.6B Admin Ops Review button polish */
#adminOpsPanel button[onclick*="sttAdminOpsReview"] {
  cursor: pointer;
  min-width: 92px;
}

/* STT STEP 58.6F Admin Ops Review button */
#adminOpsPanel button {
  cursor: pointer;
}

#adminOpsPanel button:has(+ .stt-unused),
#adminOpsPanel button[onclick*="sttAdminOpsReview"] {
  min-width: 92px;
}

/* STT STEP 58.6G Admin Ops Review clickable polish */
#adminOpsPanel .stt-ops-review-clickable {
  cursor: pointer !important;
  user-select: none;
  pointer-events: auto !important;
}

#adminOpsPanel .stt-ops-review-clickable:hover {
  filter: brightness(1.12);
  transform: translateY(-1px);
}

/* STT STEP 59.2 Signal Center row click opens chart */
.stt-signal-chart-clickable {
  cursor: pointer;
  transition: background 0.16s ease, transform 0.16s ease, box-shadow 0.16s ease;
}

.stt-signal-chart-clickable:hover {
  background: rgba(42, 188, 255, 0.08) !important;
  box-shadow: inset 3px 0 0 rgba(45, 212, 255, 0.75);
}

.stt-signal-chart-clickable:active {
  transform: scale(0.998);
}

.stt-signal-pair-chart-clickable {
  cursor: pointer;
}

.stt-signal-pair-chart-clickable::after {
  content: "  ↗";
  opacity: 0.55;
  font-size: 11px;
}

/* STT STEP 59.4 Trade Journal row click opens chart */
#page-trades .stt-trade-journal-chart-clickable {
  cursor: pointer;
  transition: background 0.16s ease, transform 0.16s ease, box-shadow 0.16s ease;
}

#page-trades .stt-trade-journal-chart-clickable:hover {
  background: rgba(42, 188, 255, 0.08) !important;
  box-shadow: inset 3px 0 0 rgba(45, 212, 255, 0.75);
}

#page-trades .stt-trade-journal-chart-clickable:active {
  transform: scale(0.998);
}

#page-trades .stt-trade-journal-chart-clickable td:first-child::after {
  content: "  ↗";
  opacity: 0.55;
  font-size: 11px;
}

/* STT STEP 59.5 Stable admin safety buttons after scroll cleanup */
#adminExchangeSafetyPanel .stt-safety-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

#adminExchangeSafetyPanel .stt-safety-actions .secondary-btn,
#adminExchangeSafetyPanel .stt-safety-actions button[onclick*="loadAdminExchangeSafety"] {
  width: 132px !important;
  min-width: 132px !important;
  max-width: 132px !important;
  height: 46px !important;
  min-height: 46px !important;
  padding: 10px 16px !important;
  border-radius: 14px !important;
}

#adminExchangeSafetyPanel .admin-runtime-actions .primary-btn,
#adminExchangeSafetyPanel .admin-runtime-actions button[onclick*="loadAdminExchangeSafety"] {
  width: 160px !important;
  min-width: 150px !important;
  max-width: 170px !important;
  height: 46px !important;
  padding: 11px 18px !important;
  border-radius: 15px !important;
}

@media (max-width: 900px) {
  #adminExchangeSafetyPanel .stt-safety-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  #adminExchangeSafetyPanel .stt-safety-actions .secondary-btn,
  #adminExchangeSafetyPanel .stt-safety-actions button[onclick*="loadAdminExchangeSafety"],
  #adminExchangeSafetyPanel .admin-runtime-actions .primary-btn {
    width: 100% !important;
    max-width: none !important;
  }
}


/* =========================================================
   STT STEP60.3 — Chart Spot/Futures selector
   ========================================================= */
.stt-chart-market-switch {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px;
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 999px;
  background: rgba(2, 6, 23, 0.45);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.04);
}

.stt-chart-market-btn {
  border: 0;
  border-radius: 999px;
  padding: 7px 12px;
  background: transparent;
  color: rgba(226, 232, 240, 0.76);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.01em;
  cursor: pointer;
}

.stt-chart-market-btn.active {
  color: #fde68a;
  background:
    radial-gradient(circle at 30% 0%, rgba(250, 204, 21, 0.28), transparent 42%),
    rgba(250, 204, 21, 0.12);
  box-shadow: 0 0 0 1px rgba(250, 204, 21, 0.34);
}

.stt-chart-market-btn:not(.active):hover {
  color: #f8fafc;
  background: rgba(148, 163, 184, 0.10);
}

@media (max-width: 720px) {
  .stt-chart-market-switch {
    flex: 0 0 auto;
  }

  .stt-chart-market-btn {
    padding: 7px 11px;
  }
}


/* =========================================================
   STT STEP60.3U — Chart loader no-layout-jump overlay
   Keeps modal/chart size fixed while candles reload.
   ========================================================= */
.stt-chart-modal {
  position: relative;
}

.stt-chart-loader,
.stt-chart-error {
  position: absolute !important;
  left: 36px;
  top: 112px;
  z-index: 99984;
  width: auto;
  max-width: min(520px, calc(100% - 72px));
  min-height: 0 !important;
  margin: 0 !important;
  padding: 7px 11px !important;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 999px;
  background: rgba(2, 6, 23, 0.58);
  backdrop-filter: blur(10px);
  box-shadow: 0 12px 34px rgba(0, 0, 0, 0.22);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.2;
  pointer-events: none;
}

.stt-chart-loader.show {
  display: inline-flex !important;
  align-items: center;
  color: rgba(226, 232, 240, 0.86);
}

.stt-chart-error.show {
  display: inline-flex !important;
  align-items: center;
  color: #fecaca;
  border-color: rgba(248, 113, 113, 0.28);
  background: rgba(69, 10, 10, 0.50);
}

.stt-chart-loader:not(.show),
.stt-chart-error:not(.show) {
  display: none !important;
}

.stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-loader,
.stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-error {
  top: 108px;
  left: 34px;
}

@media (max-width: 720px) {
  .stt-chart-loader,
  .stt-chart-error {
    top: 104px;
    left: 18px;
    max-width: calc(100% - 36px);
    padding: 6px 10px !important;
    font-size: 11px;
  }

  .stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-loader,
  .stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-error {
    top: 96px;
    left: 14px;
  }
}

/* =========================================================
   STT STEP60.3V — Chart loader compact aligned pill
   Keeps loader inside chart toolbar area, no left overflow.
   ========================================================= */
.stt-chart-loader,
.stt-chart-error {
  left: 78px !important;
  top: 116px !important;
  max-width: 170px !important;
  padding: 5px 9px !important;
  font-size: 10.5px !important;
  line-height: 1.1 !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}

.stt-chart-loader.show::before {
  content: "";
  width: 6px;
  height: 6px;
  flex: 0 0 auto;
  margin-right: 6px;
  border-radius: 999px;
  background: rgba(250, 204, 21, 0.95);
  box-shadow: 0 0 10px rgba(250, 204, 21, 0.65);
}

@media (max-width: 720px) {
  .stt-chart-loader,
  .stt-chart-error {
    left: 54px !important;
    top: 104px !important;
    max-width: 145px !important;
    padding: 5px 8px !important;
    font-size: 10px !important;
  }
}

.stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-loader,
.stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-error {
  left: 76px !important;
  top: 108px !important;
}

@media (max-width: 720px) {
  .stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-loader,
  .stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-error {
    left: 52px !important;
    top: 96px !important;
  }
}

/* =========================================================
   STT STEP60.3X — Clean chart header + bottom-right loader
   ========================================================= */
.stt-chart-loader,
.stt-chart-error {
  left: auto !important;
  right: 32px !important;
  top: auto !important;
  bottom: 34px !important;
  max-width: 120px !important;
  padding: 5px 9px !important;
  font-size: 10px !important;
  line-height: 1.1 !important;
  opacity: 0.86;
  z-index: 99986 !important;
}

.stt-chart-loader.show {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
}

.stt-chart-loader.show::before {
  width: 5px !important;
  height: 5px !important;
  margin-right: 5px !important;
}

@media (max-width: 720px) {
  .stt-chart-loader,
  .stt-chart-error {
    right: 18px !important;
    bottom: 22px !important;
    max-width: 104px !important;
    font-size: 9.5px !important;
    padding: 5px 8px !important;
  }
}

.stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-loader,
.stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-error {
  left: auto !important;
  right: 32px !important;
  top: auto !important;
  bottom: 34px !important;
}

@media (max-width: 720px) {
  .stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-loader,
  .stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-error {
    right: 18px !important;
    bottom: 22px !important;
  }
}

/* =========================================================
   STT STEP60.3Y — Loader above chart time axis, away from price scale
   ========================================================= */
.stt-chart-loader,
.stt-chart-error {
  left: auto !important;
  right: 112px !important;
  top: auto !important;
  bottom: 48px !important;
  max-width: 96px !important;
  padding: 4px 8px !important;
  font-size: 9.5px !important;
  line-height: 1 !important;
  opacity: 0.82 !important;
  transform: none !important;
}

.stt-chart-loader.show::before {
  width: 5px !important;
  height: 5px !important;
  margin-right: 5px !important;
}

.stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-loader,
.stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-error {
  right: 112px !important;
  bottom: 48px !important;
}

@media (max-width: 720px) {
  .stt-chart-loader,
  .stt-chart-error {
    right: 78px !important;
    bottom: 42px !important;
    max-width: 88px !important;
    font-size: 9px !important;
    padding: 4px 7px !important;
  }

  .stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-loader,
  .stt-chart-modal-overlay.stt-chart-fullscreen-mode .stt-chart-error {
    right: 78px !important;
    bottom: 42px !important;
  }
}

/* =========================================================
   STT STEP60.3Z — Mobile Spot/Futures selector premium tap glow
   Removes ugly square tap/focus highlight.
   ========================================================= */
.stt-chart-market-btn,
.stt-chart-market-btn:focus,
.stt-chart-market-btn:focus-visible,
.stt-chart-market-btn:active {
  outline: none !important;
  -webkit-tap-highlight-color: transparent !important;
  box-shadow: none;
}

.stt-chart-market-btn {
  position: relative;
  overflow: hidden;
  touch-action: manipulation;
  user-select: none;
  -webkit-user-select: none;
  transition:
    transform 0.16s ease,
    background 0.18s ease,
    color 0.18s ease,
    box-shadow 0.18s ease,
    border-color 0.18s ease;
}

.stt-chart-market-btn::after {
  content: "";
  position: absolute;
  inset: -35%;
  border-radius: inherit;
  background: radial-gradient(circle, rgba(250, 204, 21, 0.30), transparent 56%);
  opacity: 0;
  transform: scale(0.72);
  pointer-events: none;
  transition: opacity 0.22s ease, transform 0.22s ease;
}

.stt-chart-market-btn:active {
  transform: scale(0.96);
}

.stt-chart-market-btn:active::after {
  opacity: 1;
  transform: scale(1);
}

.stt-chart-market-btn.active {
  box-shadow:
    0 0 0 1px rgba(250, 204, 21, 0.36),
    0 0 18px rgba(250, 204, 21, 0.14) !important;
}

.stt-chart-market-btn.active::before {
  content: "";
  position: absolute;
  inset: 2px;
  border-radius: inherit;
  background: linear-gradient(135deg, rgba(255,255,255,0.13), transparent 55%);
  pointer-events: none;
}

@media (hover: hover) {
  .stt-chart-market-btn:hover {
    box-shadow: 0 0 14px rgba(250, 204, 21, 0.12);
  }
}

@media (max-width: 720px) {
  .stt-chart-market-btn,
  .stt-chart-interval,
  .stt-chart-filter-btn,
  .stt-chart-trades-toggle,
  .stt-chart-open-trade-btn,
  .stt-chart-close-all-btn {
    -webkit-tap-highlight-color: transparent !important;
  }

  .stt-chart-market-btn:focus,
  .stt-chart-market-btn:focus-visible {
    outline: none !important;
    box-shadow:
      0 0 0 1px rgba(250, 204, 21, 0.30),
      0 0 16px rgba(250, 204, 21, 0.12) !important;
  }

  .stt-chart-market-btn:not(.active):focus,
  .stt-chart-market-btn:not(.active):focus-visible {
    box-shadow: none !important;
  }
}




/* =========================================================
   STT STEP60.3ZC — Safe toolbar toggle tap fix only
   Removes mobile square highlight without changing toolbar layout.
   ========================================================= */
.stt-chart-toolbar-toggle,
.stt-chart-toolbar-toggle:focus,
.stt-chart-toolbar-toggle:focus-visible,
.stt-chart-toolbar-toggle:active {
  outline: none !important;
  -webkit-tap-highlight-color: transparent !important;
}

.stt-chart-toolbar-toggle {
  touch-action: manipulation;
  user-select: none;
  -webkit-user-select: none;
  transition:
    transform 0.14s ease,
    box-shadow 0.18s ease,
    border-color 0.18s ease,
    background 0.18s ease;
}

.stt-chart-toolbar-toggle:active {
  transform: scale(0.94);
  border-color: rgba(34, 211, 238, 0.46) !important;
  background: rgba(34, 211, 238, 0.10) !important;
  box-shadow: 0 0 14px rgba(34, 211, 238, 0.16) !important;
}

.stt-chart-toolbar-toggle:focus:not(:active),
.stt-chart-toolbar-toggle:focus-visible:not(:active) {
  box-shadow: none !important;
}

@media (hover: hover) {
  .stt-chart-toolbar-toggle:hover {
    border-color: rgba(34, 211, 238, 0.38) !important;
    box-shadow: 0 0 12px rgba(34, 211, 238, 0.12);
  }
}

/* =========================================================
   STT STEP60.3ZD — Compact chart toolbar height only
   Keeps toolbar position stable, reduces top/bottom thickness.
   ========================================================= */
.stt-chart-toolbar {
  padding-top: 6px !important;
  padding-bottom: 6px !important;
  min-height: 42px !important;
  max-height: 48px !important;
  align-items: center !important;
}

.stt-chart-body {
  padding-top: 8px !important;
}

.stt-chart-market-switch {
  height: 28px !important;
  min-height: 28px !important;
  max-height: 28px !important;
  align-items: center !important;
}

.stt-chart-market-btn {
  height: 22px !important;
  min-height: 22px !important;
  max-height: 22px !important;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
  line-height: 1 !important;
}

.stt-chart-interval,
.stt-chart-filter-btn,
.stt-chart-trades-toggle,
.stt-chart-open-trade-btn,
.stt-chart-close-all-btn {
  height: 26px !important;
  min-height: 26px !important;
  max-height: 26px !important;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
  line-height: 1 !important;
}

.stt-chart-toolbar-toggle {
  width: 26px !important;
  height: 26px !important;
  min-width: 26px !important;
  min-height: 26px !important;
  max-width: 26px !important;
  max-height: 26px !important;
  padding: 0 !important;
  line-height: 1 !important;
}

@media (max-width: 720px) {
  .stt-chart-toolbar {
    padding-top: 5px !important;
    padding-bottom: 5px !important;
    min-height: 38px !important;
    max-height: 44px !important;
  }

  .stt-chart-body {
    padding-top: 7px !important;
  }

  .stt-chart-market-switch {
    height: 27px !important;
    min-height: 27px !important;
    max-height: 27px !important;
  }

  .stt-chart-market-btn {
    height: 21px !important;
    min-height: 21px !important;
    max-height: 21px !important;
  }

  .stt-chart-interval,
  .stt-chart-filter-btn,
  .stt-chart-trades-toggle,
  .stt-chart-open-trade-btn,
  .stt-chart-close-all-btn {
    height: 25px !important;
    min-height: 25px !important;
    max-height: 25px !important;
  }

  .stt-chart-toolbar-toggle {
    width: 25px !important;
    height: 25px !important;
    min-width: 25px !important;
    min-height: 25px !important;
    max-width: 25px !important;
    max-height: 25px !important;
  }
}

/* =========================================================
   STT STEP60.3ZE — Ultra compact chart toolbar height
   Only reduces vertical thickness; no position/animation changes.
   ========================================================= */
.stt-chart-toolbar {
  padding-top: 3px !important;
  padding-bottom: 3px !important;
  min-height: 32px !important;
  max-height: 38px !important;
  gap: 6px !important;
  align-items: center !important;
}

.stt-chart-body {
  padding-top: 5px !important;
}

.stt-chart-market-switch {
  height: 24px !important;
  min-height: 24px !important;
  max-height: 24px !important;
  padding: 1px !important;
}

.stt-chart-market-btn {
  height: 20px !important;
  min-height: 20px !important;
  max-height: 20px !important;
  padding: 0 8px !important;
  font-size: 10px !important;
  line-height: 1 !important;
}

.stt-chart-interval,
.stt-chart-filter-btn,
.stt-chart-trades-toggle,
.stt-chart-open-trade-btn,
.stt-chart-close-all-btn {
  height: 22px !important;
  min-height: 22px !important;
  max-height: 22px !important;
  padding: 0 8px !important;
  font-size: 10px !important;
  line-height: 1 !important;
}

.stt-chart-toolbar-toggle {
  width: 22px !important;
  height: 22px !important;
  min-width: 22px !important;
  min-height: 22px !important;
  max-width: 22px !important;
  max-height: 22px !important;
  padding: 0 !important;
  font-size: 10px !important;
  line-height: 1 !important;
}

@media (max-width: 720px) {
  .stt-chart-toolbar {
    padding-top: 3px !important;
    padding-bottom: 3px !important;
    min-height: 30px !important;
    max-height: 36px !important;
    gap: 5px !important;
  }

  .stt-chart-body {
    padding-top: 5px !important;
  }

  .stt-chart-market-switch {
    height: 23px !important;
    min-height: 23px !important;
    max-height: 23px !important;
  }

  .stt-chart-market-btn {
    height: 19px !important;
    min-height: 19px !important;
    max-height: 19px !important;
    padding: 0 7px !important;
    font-size: 9.5px !important;
  }

  .stt-chart-interval,
  .stt-chart-filter-btn,
  .stt-chart-trades-toggle,
  .stt-chart-open-trade-btn,
  .stt-chart-close-all-btn {
    height: 21px !important;
    min-height: 21px !important;
    max-height: 21px !important;
    padding: 0 7px !important;
    font-size: 9.5px !important;
  }

  .stt-chart-toolbar-toggle {
    width: 21px !important;
    height: 21px !important;
    min-width: 21px !important;
    min-height: 21px !important;
    max-width: 21px !important;
    max-height: 21px !important;
    font-size: 9px !important;
  }
}

/* =========================================================
   STT STEP60.3ZF — Hide mobile chart toolbar scrollbars
   Keeps swipe/scroll working, removes ugly colorful scrollbar.
   ========================================================= */
.stt-chart-toolbar,
.stt-chart-toolbar-floating,
#sttChartToolbar {
  scrollbar-width: none !important;        /* Firefox */
  -ms-overflow-style: none !important;     /* IE/Edge legacy */
}

.stt-chart-toolbar::-webkit-scrollbar,
.stt-chart-toolbar-floating::-webkit-scrollbar,
#sttChartToolbar::-webkit-scrollbar {
  width: 0 !important;
  height: 0 !important;
  display: none !important;
}

.stt-chart-toolbar {
  overflow-x: auto !important;
  overflow-y: hidden !important;
  -webkit-overflow-scrolling: touch;
}

@media (max-width: 720px) {
  .stt-chart-toolbar,
  .stt-chart-toolbar-floating,
  #sttChartToolbar {
    scrollbar-width: none !important;
    -ms-overflow-style: none !important;
  }

  .stt-chart-toolbar::-webkit-scrollbar,
  .stt-chart-toolbar-floating::-webkit-scrollbar,
  #sttChartToolbar::-webkit-scrollbar {
    width: 0 !important;
    height: 0 !important;
    display: none !important;
  }
}


/* =========================================================
   STT STEP60.3ZI — Chart fit latest button + context menu
   ========================================================= */
.stt-chart-fit-btn {
  height: 22px;
  min-height: 22px;
  max-height: 22px;
  padding: 0 8px;
  border: 1px solid rgba(34, 211, 238, 0.34);
  border-radius: 999px;
  background: rgba(34, 211, 238, 0.08);
  color: #a5f3fc;
  font-size: 10px;
  font-weight: 900;
  line-height: 1;
  cursor: pointer;
  outline: none !important;
  -webkit-tap-highlight-color: transparent !important;
  transition: transform 0.14s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.stt-chart-fit-btn:hover {
  background: rgba(34, 211, 238, 0.13);
  box-shadow: 0 0 13px rgba(34, 211, 238, 0.13);
}

.stt-chart-fit-btn:active {
  transform: scale(0.95);
  box-shadow: 0 0 16px rgba(34, 211, 238, 0.20);
}

.stt-chart-context-menu {
  position: fixed;
  z-index: 100005;
  display: none;
  min-width: 178px;
  padding: 7px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 14px;
  background:
    radial-gradient(circle at 10% 0%, rgba(34, 211, 238, 0.13), transparent 35%),
    rgba(2, 6, 23, 0.94);
  backdrop-filter: blur(14px);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.46);
}

.stt-chart-context-menu.show {
  display: block;
}

.stt-chart-context-menu button {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 9px;
  border: 0;
  border-radius: 11px;
  padding: 9px 10px;
  background: rgba(15, 23, 42, 0.70);
  color: #e5e7eb;
  cursor: pointer;
  text-align: left;
  outline: none !important;
  -webkit-tap-highlight-color: transparent !important;
}

.stt-chart-context-menu button:hover,
.stt-chart-context-menu button:active {
  background: rgba(34, 211, 238, 0.13);
  box-shadow: inset 0 0 0 1px rgba(34, 211, 238, 0.18);
}

.stt-chart-context-menu span {
  color: #67e8f9;
  font-size: 13px;
}

.stt-chart-context-menu b {
  font-size: 12px;
  font-weight: 900;
}

@media (max-width: 720px) {
  .stt-chart-fit-btn {
    height: 21px;
    min-height: 21px;
    max-height: 21px;
    padding: 0 7px;
    font-size: 9.5px;
  }

  .stt-chart-context-menu {
    min-width: 166px;
  }
}

/* =========================================================
   STT STEP60.3ZJ — Context menu save image option polish
   ========================================================= */
.stt-chart-context-menu {
  min-width: 190px !important;
}

.stt-chart-context-menu button + button {
  margin-top: 5px;
}

.stt-chart-context-menu button#sttChartContextSaveBtn span {
  color: #fde68a;
}

.stt-chart-context-menu button#sttChartContextSaveBtn:hover,
.stt-chart-context-menu button#sttChartContextSaveBtn:active {
  background: rgba(250, 204, 21, 0.12);
  box-shadow: inset 0 0 0 1px rgba(250, 204, 21, 0.18);
}

@media (max-width: 720px) {
  .stt-chart-context-menu {
    min-width: 176px !important;
  }
}

/* =========================================================
   STT STEP60.3ZK — Fit to Screen label polish
   ========================================================= */
.stt-chart-context-menu button#sttChartContextFitBtn b {
  letter-spacing: 0.01em;
}

.stt-chart-fit-btn {
  min-width: 28px;
}

/* =========================================================
   STT STEP60.4A — Market Watch Spot/Futures selector
   ========================================================= */
.stt-market-type-switch {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 999px;
  background: rgba(2, 6, 23, 0.42);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.04);
  flex: 0 0 auto;
}

.stt-market-type-btn {
  border: 0;
  border-radius: 999px;
  padding: 8px 14px;
  background: transparent;
  color: rgba(226, 232, 240, 0.78);
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
  outline: none !important;
  -webkit-tap-highlight-color: transparent !important;
  transition: transform 0.14s ease, background 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
}

.stt-market-type-btn.active {
  color: #fde68a;
  background:
    radial-gradient(circle at 30% 0%, rgba(250, 204, 21, 0.25), transparent 42%),
    rgba(250, 204, 21, 0.12);
  box-shadow:
    0 0 0 1px rgba(250, 204, 21, 0.32),
    0 0 16px rgba(250, 204, 21, 0.12);
}

.stt-market-type-btn:active {
  transform: scale(0.96);
}

.stt-market-render-headline {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.stt-market-source-pill {
  flex: 0 0 auto;
  border: 1px solid rgba(34, 211, 238, 0.30);
  border-radius: 999px;
  padding: 6px 10px;
  background: rgba(34, 211, 238, 0.08);
  color: #a5f3fc;
  font-size: 11px;
  font-weight: 900;
}

@media (max-width: 720px) {
  .market-topbar {
    gap: 8px !important;
  }

  .stt-market-type-switch {
    order: -1;
    width: max-content;
    padding: 2px;
    margin-bottom: 4px;
  }

  .stt-market-type-btn {
    padding: 7px 12px;
    font-size: 11px;
  }

  .stt-market-render-headline {
    align-items: center;
  }

  .stt-market-source-pill {
    font-size: 10px;
    padding: 5px 8px;
  }
}

/* =========================================================
   STT STEP60.4B — Market selector no page jump helper
   ========================================================= */
html.stt-market-switching-no-jump,
html.stt-market-switching-no-jump body {
  scroll-behavior: auto !important;
}

.stt-market-type-btn:focus,
.stt-market-type-btn:focus-visible {
  outline: none !important;
}

/* =========================================================
   STT STEP60.4C — Market Watch loading no-shrink/no-jump
   Keeps table card stable while switching Spot/Futures.
   ========================================================= */
#marketWatchBox {
  min-height: 360px;
}

#marketWatchBox.stt-market-preserve-loading {
  position: relative;
}

#marketWatchBox.stt-market-preserve-loading::after {
  content: "Updating market data...";
  position: absolute;
  right: 16px;
  top: 10px;
  z-index: 2;
  border: 1px solid rgba(34, 211, 238, 0.24);
  border-radius: 999px;
  padding: 6px 10px;
  background: rgba(2, 6, 23, 0.72);
  color: rgba(165, 243, 252, 0.92);
  font-size: 11px;
  font-weight: 900;
  pointer-events: none;
  box-shadow: 0 10px 26px rgba(0,0,0,0.22);
}

@media (max-width: 720px) {
  #marketWatchBox {
    min-height: 520px;
  }

  #marketWatchBox.stt-market-preserve-loading::after {
    right: 10px;
    top: 8px;
    font-size: 10px;
    padding: 5px 8px;
  }
}


/* =========================================================
   STT STEP60.4D — Remove Market Watch loading pill + stable sync text
   ========================================================= */
#marketWatchBox.stt-market-preserve-loading::after {
  display: none !important;
  content: none !important;
}

.market-sync {
  min-width: 190px !important;
  justify-content: flex-end !important;
}

#marketLastUpdated {
  display: inline-block !important;
  min-width: 138px !important;
  text-align: right !important;
  white-space: nowrap !important;
}

#marketLastUpdated.stt-market-updating-soft {
  opacity: 0.72;
}

@media (max-width: 720px) {
  .market-sync {
    min-width: 150px !important;
    justify-content: flex-start !important;
  }

  #marketLastUpdated {
    min-width: 112px !important;
    text-align: left !important;
  }
}

/* =========================================================
   STT STEP60.4E — Market Watch search bar + 5 page support
   ========================================================= */
.stt-market-search-wrap {
  position: relative;
  margin: 12px 0 14px;
}

.stt-market-search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  width: min(520px, 100%);
  border: 1px solid rgba(34, 211, 238, 0.22);
  border-radius: 18px;
  background:
    radial-gradient(circle at 8% 0%, rgba(34, 211, 238, 0.10), transparent 34%),
    rgba(2, 6, 23, 0.42);
  padding: 9px 12px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.04);
}

.stt-market-search-icon {
  color: rgba(165, 243, 252, 0.90);
  font-weight: 900;
  font-size: 15px;
}

.stt-market-search-input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: none;
  background: transparent;
  color: #e5e7eb;
  font-size: 13px;
  font-weight: 800;
}

.stt-market-search-input::placeholder {
  color: rgba(148, 163, 184, 0.72);
  font-weight: 700;
}

.stt-market-search-clear {
  width: 24px;
  height: 24px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.72);
  color: rgba(226, 232, 240, 0.82);
  cursor: pointer;
  font-size: 15px;
  line-height: 1;
  outline: none !important;
  -webkit-tap-highlight-color: transparent !important;
}

.stt-market-search-results {
  display: none;
  position: absolute;
  z-index: 80;
  top: calc(100% + 8px);
  left: 0;
  width: min(560px, 100%);
  max-height: 360px;
  overflow: auto;
  border: 1px solid rgba(34, 211, 238, 0.22);
  border-radius: 18px;
  background:
    radial-gradient(circle at 8% 0%, rgba(34, 211, 238, 0.10), transparent 35%),
    rgba(2, 6, 23, 0.96);
  backdrop-filter: blur(12px);
  box-shadow: 0 20px 54px rgba(0, 0, 0, 0.42);
  padding: 8px;
}

.stt-market-search-results.show {
  display: block;
}

.stt-market-search-item {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 0;
  border-radius: 14px;
  padding: 10px 11px;
  background: transparent;
  color: #e5e7eb;
  cursor: pointer;
  text-align: left;
  outline: none !important;
  -webkit-tap-highlight-color: transparent !important;
}

.stt-market-search-item:hover,
.stt-market-search-item:active {
  background: rgba(34, 211, 238, 0.10);
}

.stt-market-search-main {
  display: grid;
  gap: 2px;
}

.stt-market-search-main b,
.stt-market-search-meta b {
  font-size: 12px;
  font-weight: 900;
}

.stt-market-search-main small,
.stt-market-search-meta small {
  font-size: 11px;
  color: rgba(148, 163, 184, 0.88);
}

.stt-market-search-meta {
  display: grid;
  gap: 2px;
  text-align: right;
  flex: 0 0 auto;
}

.stt-market-search-loading,
.stt-market-search-empty {
  padding: 12px;
  color: rgba(226, 232, 240, 0.78);
  font-size: 12px;
  font-weight: 800;
}

@media (max-width: 720px) {
  .stt-market-search-wrap {
    margin: 10px 0 12px;
  }

  .stt-market-search-box {
    width: 100%;
    border-radius: 16px;
    padding: 8px 10px;
  }

  .stt-market-search-input {
    font-size: 12px;
  }

  .stt-market-search-results {
    width: 100%;
    max-height: 320px;
  }
}

/* =========================================================
   STT STEP60.4F — Professional Market Watch search UI
   Makes search compact, opaque, non-overlapping and premium.
   ========================================================= */
.stt-market-search-wrap {
  width: min(440px, 100%) !important;
  margin: 12px 0 12px !important;
  position: relative !important;
  z-index: 5 !important;
}

.stt-market-search-box {
  width: 100% !important;
  min-height: 42px !important;
  border-radius: 16px !important;
  border: 1px solid rgba(34, 211, 238, 0.22) !important;
  background:
    linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(2, 6, 23, 0.92)) !important;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.04),
    0 10px 28px rgba(0,0,0,0.18) !important;
}

.stt-market-search-input {
  height: 24px !important;
  font-size: 13px !important;
  color: #f8fafc !important;
}

.stt-market-search-results {
  position: static !important;
  display: none;
  width: 100% !important;
  max-height: 260px !important;
  margin-top: 8px !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  border: 1px solid rgba(34, 211, 238, 0.18) !important;
  border-radius: 16px !important;
  background: #07111f !important;
  backdrop-filter: none !important;
  box-shadow:
    0 14px 36px rgba(0,0,0,0.36),
    inset 0 1px 0 rgba(255,255,255,0.04) !important;
  padding: 6px !important;
}

.stt-market-search-results.show {
  display: block !important;
}

.stt-market-search-item {
  min-height: 54px !important;
  border-radius: 12px !important;
  padding: 9px 10px !important;
  background: rgba(15, 23, 42, 0.58) !important;
  border: 1px solid rgba(148, 163, 184, 0.08) !important;
  margin-bottom: 5px !important;
}

.stt-market-search-item:last-child {
  margin-bottom: 0 !important;
}

.stt-market-search-item:hover,
.stt-market-search-item:active {
  background: rgba(34, 211, 238, 0.11) !important;
  border-color: rgba(34, 211, 238, 0.18) !important;
}

.stt-market-search-main b,
.stt-market-search-meta b {
  color: #f8fafc !important;
  font-size: 12px !important;
}

.stt-market-search-main small,
.stt-market-search-meta small {
  color: rgba(148, 163, 184, 0.86) !important;
  font-size: 10.5px !important;
}

.stt-market-search-loading,
.stt-market-search-empty {
  background: rgba(15, 23, 42, 0.58) !important;
  border-radius: 12px !important;
  color: rgba(226, 232, 240, 0.82) !important;
}

@media (max-width: 720px) {
  .stt-market-search-wrap {
    width: 100% !important;
    margin: 10px 0 12px !important;
  }

  .stt-market-search-box {
    min-height: 40px !important;
    border-radius: 15px !important;
  }

  .stt-market-search-input {
    font-size: 12px !important;
  }

  .stt-market-search-results {
    max-height: 240px !important;
    border-radius: 15px !important;
  }

  .stt-market-search-item {
    min-height: 50px !important;
  }
}

/* =========================================================
   STT STEP60.4G — Floating Market Watch search dropdown
   Search results no longer push table/card down.
   ========================================================= */
.stt-market-search-wrap {
  position: relative !important;
  z-index: 120 !important;
  width: min(440px, 100%) !important;
  margin: 12px 0 12px !important;
}

.stt-market-search-results {
  position: absolute !important;
  top: calc(100% + 8px) !important;
  left: 0 !important;
  width: min(440px, 100%) !important;
  max-height: 300px !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  z-index: 9995 !important;
  display: none;
  border: 1px solid rgba(34, 211, 238, 0.22) !important;
  border-radius: 16px !important;
  background:
    radial-gradient(circle at 8% 0%, rgba(34, 211, 238, 0.10), transparent 35%),
    #07111f !important;
  box-shadow:
    0 20px 60px rgba(0, 0, 0, 0.58),
    inset 0 1px 0 rgba(255,255,255,0.04) !important;
  padding: 7px !important;
}

.stt-market-search-results.show {
  display: block !important;
}

.stt-market-search-results::-webkit-scrollbar {
  width: 3px !important;
  height: 3px !important;
}

.stt-market-search-results::-webkit-scrollbar-thumb {
  border-radius: 999px !important;
  background: rgba(34, 211, 238, 0.55) !important;
}

.stt-market-search-results::-webkit-scrollbar-track {
  background: rgba(15, 23, 42, 0.25) !important;
}

.stt-market-search-item {
  min-height: 46px !important;
  padding: 8px 10px !important;
  margin-bottom: 5px !important;
  border-radius: 12px !important;
  background: rgba(15, 23, 42, 0.82) !important;
}

.stt-market-search-item:last-child {
  margin-bottom: 0 !important;
}

/* Keep table card stable while dropdown floats over it */
#marketWatchBox {
  position: relative !important;
  z-index: 1 !important;
}

@media (max-width: 720px) {
  .stt-market-search-wrap {
    width: 100% !important;
    z-index: 150 !important;
  }

  .stt-market-search-results {
    width: 100% !important;
    max-height: 260px !important;
  }

  .stt-market-search-item {
    min-height: 44px !important;
  }
}



/* =========================================================
   STT STEP60.4T — Clean SL/TP drag root fix
   Keeps original Step53/Step55 drag logic, only restores visibility.
   ========================================================= */

/* Existing SL/TP drag: live dotted line + price tag must move with handle */
#sttMarketCoinChartWrap.stt-risk-drag-live-active #sttChartRiskDragLayer {
  z-index: 99980 !important;
  pointer-events: none !important;
  overflow: visible !important;
}

#sttMarketCoinChartWrap.stt-risk-drag-live-active .stt-risk-drag-live-wrap-final {
  display: block !important;
  position: absolute !important;
  left: 0 !important;
  right: 0 !important;
  z-index: 99986 !important;
  pointer-events: none !important;
  opacity: 1 !important;
  visibility: visible !important;
}

#sttMarketCoinChartWrap.stt-risk-drag-live-active .stt-risk-drag-live-line-final {
  display: block !important;
  position: absolute !important;
  left: 0 !important;
  right: 0 !important;
  top: 0 !important;
  height: 0 !important;
  opacity: 1 !important;
  visibility: visible !important;
}

#sttMarketCoinChartWrap.stt-risk-drag-live-active .stt-risk-drag-live-price-final {
  display: inline-flex !important;
  opacity: 1 !important;
  visibility: visible !important;
}

/* Add-missing SL/TP from BUY/SELL entry tag: preview must follow cursor */
#sttMarketCoinChartWrap.stt-entry-risk-dragging-active #sttChartRiskDragLayer {
  z-index: 99980 !important;
  pointer-events: none !important;
  overflow: visible !important;
}

#sttMarketCoinChartWrap.stt-entry-risk-dragging-active .stt-entry-risk-preview-wrap {
  display: block !important;
  position: absolute !important;
  left: 0 !important;
  right: 0 !important;
  z-index: 99986 !important;
  pointer-events: none !important;
  opacity: 1 !important;
  visibility: visible !important;
}

#sttMarketCoinChartWrap.stt-entry-risk-dragging-active .stt-entry-risk-preview-line {
  display: block !important;
  opacity: 1 !important;
  visibility: visible !important;
}

#sttMarketCoinChartWrap.stt-entry-risk-dragging-active .stt-entry-risk-preview-tag {
  display: inline-flex !important;
  opacity: 1 !important;
  visibility: visible !important;
}

/* During chart move, do not hide drag handles/previews if drag is active */
#sttMarketCoinChartWrap.stt-risk-drag-live-active.stt-chart-touch-moving .stt-chart-risk-drag-layer,
#sttMarketCoinChartWrap.stt-risk-drag-live-active.stt-chart-touch-moving .stt-risk-drag-handle,
#sttMarketCoinChartWrap.stt-entry-risk-dragging-active.stt-chart-touch-moving .stt-chart-risk-drag-layer,
#sttMarketCoinChartWrap.stt-entry-risk-dragging-active.stt-chart-touch-moving .stt-entry-risk-label-btn {
  opacity: 1 !important;
  visibility: visible !important;
}

/* =========================================================
   STT STEP60.4U — Market search single clear button
   Prevents browser/native clear icon; keeps only custom × button.
   ========================================================= */
#sttMarketSearchInput,
.stt-market-search-input {
  -webkit-appearance: none !important;
  appearance: none !important;
}

#sttMarketSearchInput::-webkit-search-cancel-button,
#sttMarketSearchInput::-webkit-search-decoration,
#sttMarketSearchInput::-webkit-search-results-button,
#sttMarketSearchInput::-webkit-search-results-decoration,
.stt-market-search-input::-webkit-search-cancel-button,
.stt-market-search-input::-webkit-search-decoration,
.stt-market-search-input::-webkit-search-results-button,
.stt-market-search-input::-webkit-search-results-decoration {
  -webkit-appearance: none !important;
  appearance: none !important;
  display: none !important;
  width: 0 !important;
  height: 0 !important;
}

.stt-market-search-clear {
  flex: 0 0 auto !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
}

/* =========================================================
   STT STEP60.4Y — Mobile Market Watch hide heavy scrollbars
   Removes thick colorful scrollbars from category tabs and pair table.
   Scroll/swipe still works.
   ========================================================= */
@media (max-width: 720px) {
  /* Market Watch category/tabs horizontal scroll */
  #page-market .market-tabs,
  #page-market .market-topbar,
  #page-market .stt-market-type-switch,
  #page-market .card-header,
  #page-market .market-card-premium,
  #page-market .market-table-scroll,
  #page-market .stt-market-table,
  #page-market .stt-market-table-with-volume,
  #page-market #marketWatchBox,
  #page-market .market-note,
  #marketWatchBox,
  .market-tabs,
  .market-topbar,
  .market-table-scroll,
  .stt-market-table,
  .stt-market-table-with-volume {
    scrollbar-width: none !important;
    -ms-overflow-style: none !important;
  }

  #page-market .market-tabs::-webkit-scrollbar,
  #page-market .market-topbar::-webkit-scrollbar,
  #page-market .stt-market-type-switch::-webkit-scrollbar,
  #page-market .card-header::-webkit-scrollbar,
  #page-market .market-card-premium::-webkit-scrollbar,
  #page-market .market-table-scroll::-webkit-scrollbar,
  #page-market .stt-market-table::-webkit-scrollbar,
  #page-market .stt-market-table-with-volume::-webkit-scrollbar,
  #page-market #marketWatchBox::-webkit-scrollbar,
  #page-market .market-note::-webkit-scrollbar,
  #marketWatchBox::-webkit-scrollbar,
  .market-tabs::-webkit-scrollbar,
  .market-topbar::-webkit-scrollbar,
  .market-table-scroll::-webkit-scrollbar,
  .stt-market-table::-webkit-scrollbar,
  .stt-market-table-with-volume::-webkit-scrollbar {
    width: 0 !important;
    height: 0 !important;
    display: none !important;
    background: transparent !important;
  }

  /* Direct child containers inside marketWatchBox sometimes receive overflow */
  #marketWatchBox *,
  #page-market .market-card-premium * {
    scrollbar-width: none !important;
    -ms-overflow-style: none !important;
  }

  #marketWatchBox *::-webkit-scrollbar,
  #page-market .market-card-premium *::-webkit-scrollbar {
    width: 0 !important;
    height: 0 !important;
    display: none !important;
    background: transparent !important;
  }

  /* Keep horizontal scroll usable but invisible */
  #page-market .market-tabs,
  #page-market .market-topbar,
  #page-market .market-table-scroll {
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
  }

  /* Remove extra bottom space previously reserved for scrollbar */
  #page-market .market-tabs,
  #page-market .market-table-scroll,
  #page-market #marketWatchBox {
    padding-bottom: 0 !important;
  }
}

/* =========================================================
   STT STEP60.4Z — Mobile Trade Journal / Signal Center hide heavy scrollbars
   Removes thick colorful scrollbars from Running Trades, Trade History,
   Signal Center tables/cards while keeping scroll/swipe working.
   ========================================================= */
@media (max-width: 720px) {
  /* Hide all scrollbars inside Trade Journal and Signal Center pages */
  #page-trades,
  #page-trades *,
  #page-signals,
  #page-signals *,
  #trades,
  #trades *,
  #signals,
  #signals * {
    scrollbar-width: none !important;
    -ms-overflow-style: none !important;
  }

  #page-trades::-webkit-scrollbar,
  #page-trades *::-webkit-scrollbar,
  #page-signals::-webkit-scrollbar,
  #page-signals *::-webkit-scrollbar,
  #trades::-webkit-scrollbar,
  #trades *::-webkit-scrollbar,
  #signals::-webkit-scrollbar,
  #signals *::-webkit-scrollbar {
    width: 0 !important;
    height: 0 !important;
    display: none !important;
    background: transparent !important;
  }

  /* Known table/card scroll wrappers */
  #page-trades .card,
  #page-trades .admin-table-scroll,
  #page-trades .table-scroll,
  #page-trades .trade-table-scroll,
  #page-trades .trade-journal-table-wrap,
  #page-trades .stt-trade-table-wrap,
  #page-trades .stt-trade-scroll,
  #page-signals .card,
  #page-signals .admin-table-scroll,
  #page-signals .table-scroll,
  #page-signals .signal-table-scroll,
  #page-signals .signal-center-table-wrap,
  #page-signals .stt-signal-table-wrap,
  #page-signals .stt-signal-scroll,
  #trades .card,
  #trades .admin-table-scroll,
  #trades .table-scroll,
  #trades .trade-table-scroll,
  #trades .trade-journal-table-wrap,
  #trades .stt-trade-table-wrap,
  #trades .stt-trade-scroll,
  #signals .card,
  #signals .admin-table-scroll,
  #signals .table-scroll,
  #signals .signal-table-scroll,
  #signals .signal-center-table-wrap,
  #signals .stt-signal-table-wrap,
  #signals .stt-signal-scroll {
    overflow-x: auto !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch !important;
    scrollbar-width: none !important;
    -ms-overflow-style: none !important;
    padding-bottom: 0 !important;
  }

  #page-trades .card::-webkit-scrollbar,
  #page-trades .admin-table-scroll::-webkit-scrollbar,
  #page-trades .table-scroll::-webkit-scrollbar,
  #page-trades .trade-table-scroll::-webkit-scrollbar,
  #page-trades .trade-journal-table-wrap::-webkit-scrollbar,
  #page-trades .stt-trade-table-wrap::-webkit-scrollbar,
  #page-trades .stt-trade-scroll::-webkit-scrollbar,
  #page-signals .card::-webkit-scrollbar,
  #page-signals .admin-table-scroll::-webkit-scrollbar,
  #page-signals .table-scroll::-webkit-scrollbar,
  #page-signals .signal-table-scroll::-webkit-scrollbar,
  #page-signals .signal-center-table-wrap::-webkit-scrollbar,
  #page-signals .stt-signal-table-wrap::-webkit-scrollbar,
  #page-signals .stt-signal-scroll::-webkit-scrollbar,
  #trades .card::-webkit-scrollbar,
  #trades .admin-table-scroll::-webkit-scrollbar,
  #trades .table-scroll::-webkit-scrollbar,
  #trades .trade-table-scroll::-webkit-scrollbar,
  #trades .trade-journal-table-wrap::-webkit-scrollbar,
  #trades .stt-trade-table-wrap::-webkit-scrollbar,
  #trades .stt-trade-scroll::-webkit-scrollbar,
  #signals .card::-webkit-scrollbar,
  #signals .admin-table-scroll::-webkit-scrollbar,
  #signals .table-scroll::-webkit-scrollbar,
  #signals .signal-table-scroll::-webkit-scrollbar,
  #signals .signal-center-table-wrap::-webkit-scrollbar,
  #signals .stt-signal-table-wrap::-webkit-scrollbar,
  #signals .stt-signal-scroll::-webkit-scrollbar {
    width: 0 !important;
    height: 0 !important;
    display: none !important;
    background: transparent !important;
  }

  /* Remove extra blank scrollbar space near pagination/bottom */
  #page-trades .pagination,
  #page-trades .trade-pagination,
  #page-trades .stt-pagination,
  #trades .pagination,
  #trades .trade-pagination,
  #trades .stt-pagination {
    margin-top: 8px !important;
  }
}

/* STT STEP61.10 — Professional SL/TP rejection card */
.stt-sltp-reject-card {
  position: fixed;
  top: 96px;
  left: 50%;
  transform: translate(-50%, -18px) scale(0.96);
  z-index: 999999;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  width: min(520px, calc(100vw - 28px));
  padding: 15px 16px;
  border: 1px solid rgba(248, 113, 113, 0.45);
  border-radius: 18px;
  background:
    radial-gradient(circle at 18% 0%, rgba(248, 113, 113, 0.22), transparent 36%),
    linear-gradient(135deg, rgba(24, 24, 38, 0.98), rgba(9, 14, 28, 0.98));
  box-shadow:
    0 24px 70px rgba(0, 0, 0, 0.55),
    0 0 0 1px rgba(255, 255, 255, 0.04) inset,
    0 0 24px rgba(248, 113, 113, 0.18);
  color: #f8fafc;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.22s ease;
}

.stt-sltp-reject-card.show {
  opacity: 1;
  pointer-events: auto;
  transform: translate(-50%, 0) scale(1);
}

.stt-sltp-reject-icon {
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-weight: 900;
  color: #fff;
  background: linear-gradient(135deg, #ef4444, #f97316);
  box-shadow: 0 10px 24px rgba(239, 68, 68, 0.38);
}

.stt-sltp-reject-body {
  min-width: 0;
  flex: 1;
}

.stt-sltp-reject-title {
  font-size: 14px;
  font-weight: 900;
  letter-spacing: 0.02em;
  margin-bottom: 4px;
}

.stt-sltp-reject-msg {
  font-size: 13px;
  line-height: 1.45;
  color: #fee2e2;
  font-weight: 650;
}

.stt-sltp-reject-hint {
  margin-top: 6px;
  font-size: 12px;
  line-height: 1.35;
  color: rgba(226, 232, 240, 0.78);
}

.stt-sltp-reject-close {
  flex: 0 0 auto;
  width: 28px;
  height: 28px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.13);
  background: rgba(255, 255, 255, 0.07);
  color: rgba(255, 255, 255, 0.9);
  cursor: pointer;
  font-size: 18px;
  line-height: 1;
}

.stt-sltp-reject-close:hover {
  background: rgba(248, 113, 113, 0.22);
  border-color: rgba(248, 113, 113, 0.48);
}

@media (max-width: 720px) {
  .stt-sltp-reject-card {
    top: 74px;
    width: calc(100vw - 22px);
    padding: 13px 13px;
    border-radius: 16px;
  }

  .stt-sltp-reject-msg {
    font-size: 12.5px;
  }

  .stt-sltp-reject-hint {
    font-size: 11.5px;
  }
}





/* STT STEP62.5N — Premium compact Futures Open Trade card final polish */
.stt-manual-open-card {
  max-width: 410px !important;
  padding: 15px 16px !important;
  border-radius: 18px !important;
  background:
    radial-gradient(circle at 0% 0%, rgba(56,189,248,.11), transparent 32%),
    linear-gradient(145deg, rgba(9, 16, 32, .98), rgba(7, 11, 24, .98)) !important;
  box-shadow:
    0 26px 90px rgba(0,0,0,.56),
    0 0 0 1px rgba(148,163,184,.10) inset !important;
}

.stt-manual-open-title {
  font-size: 16px !important;
  font-weight: 950 !important;
  letter-spacing: .01em !important;
  color: #f8fafc !important;
}

.stt-manual-open-subtitle,
.stt-manual-open-price-hint {
  font-size: 11px !important;
  font-weight: 750 !important;
  color: rgba(203, 213, 225, .82) !important;
  line-height: 1.22 !important;
}

.stt-manual-open-field {
  margin-bottom: 7px !important;
}

.stt-manual-open-field label {
  display: block !important;
  margin: 0 0 5px !important;
  font-size: 10.8px !important;
  line-height: 1 !important;
  font-weight: 900 !important;
  letter-spacing: .01em !important;
  color: rgba(226, 232, 240, .88) !important;
}

.stt-manual-open-field input,
.stt-manual-open-field select {
  height: 34px !important;
  min-height: 34px !important;
  width: 100% !important;
  padding: 6px 10px !important;
  border-radius: 10px !important;
  border: 1px solid rgba(148, 163, 184, .18) !important;
  background: rgba(15, 23, 42, .78) !important;
  color: #e5e7eb !important;
  font-size: 12px !important;
  font-weight: 850 !important;
  box-sizing: border-box !important;
  outline: none !important;
}

.stt-manual-open-field input:focus,
.stt-manual-open-field select:focus {
  border-color: rgba(56, 189, 248, .55) !important;
  box-shadow: 0 0 0 3px rgba(56, 189, 248, .10) !important;
}

/* Presets compact */
.stt-manual-open-presets {
  gap: 7px !important;
  margin: 8px 0 9px !important;
}

.stt-manual-open-presets button {
  height: 32px !important;
  min-height: 32px !important;
  padding: 6px 9px !important;
  border-radius: 10px !important;
  font-size: 12px !important;
  font-weight: 900 !important;
}

/* Futures premium box */
.stt-manual-futures-controls {
  margin: 8px 0 10px !important;
  padding: 10px !important;
  border-radius: 14px !important;
  border: 1px solid rgba(99, 102, 241, .24) !important;
  background:
    radial-gradient(circle at 14% 0%, rgba(34, 197, 94, .10), transparent 30%),
    linear-gradient(145deg, rgba(15, 23, 42, .68), rgba(15, 23, 42, .42)) !important;
}

.stt-manual-futures-head {
  display: flex !important;
  justify-content: space-between !important;
  align-items: center !important;
  gap: 8px !important;
  margin: 0 0 7px !important;
}

.stt-manual-futures-head span {
  font-size: 12px !important;
  line-height: 1 !important;
  font-weight: 950 !important;
  color: #f1f5f9 !important;
}

.stt-manual-futures-head small {
  font-size: 9.5px !important;
  line-height: 1 !important;
  font-weight: 850 !important;
  color: rgba(199, 210, 254, .80) !important;
}

/* Layout:
   Row 1: Leverage full width
   Row 2: Margin + Order + Limit all in one compact row
*/
.stt-manual-futures-grid {
  display: grid !important;
  grid-template-columns: .82fr .82fr 1fr !important;
  gap: 7px !important;
  align-items: end !important;
}

.stt-manual-futures-grid > .stt-manual-open-field {
  margin: 0 !important;
  min-width: 0 !important;
}

.stt-manual-futures-grid > .stt-manual-open-field:nth-child(1) {
  grid-column: 1 / -1 !important;
}

/* Limit price no full-width height jump */
#sttManualLimitPriceWrap {
  grid-column: auto !important;
}

/* Dark, compact select/input */
#sttManualOpenMarginMode,
#sttManualOpenOrderType,
#sttManualOpenLimitPrice {
  height: 33px !important;
  min-height: 33px !important;
  padding: 6px 8px !important;
  border-radius: 10px !important;
  font-size: 11.6px !important;
  font-weight: 900 !important;
  border: 1px solid rgba(148,163,184,.18) !important;
  background: rgba(15,23,42,.88) !important;
  color: #f1f5f9 !important;
  margin: 0 !important;
  max-width: 100% !important;
}

/* Browser select dropdown options */
#sttManualOpenMarginMode option,
#sttManualOpenOrderType option {
  background: #0f172a !important;
  color: #f8fafc !important;
}

/* Leverage ultra-thin premium slider */
.stt-leverage-slider-head {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  height: 20px !important;
  margin: 0 0 4px !important;
}

.stt-leverage-slider-head span {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-width: 38px !important;
  height: 21px !important;
  padding: 0 8px !important;
  border-radius: 999px !important;
  background: linear-gradient(135deg, rgba(34,197,94,.24), rgba(20,184,166,.18)) !important;
  border: 1px solid rgba(34,197,94,.34) !important;
  color: #bbf7d0 !important;
  font-size: 11px !important;
  font-weight: 950 !important;
}

.stt-leverage-slider-head small {
  font-size: 9px !important;
  color: rgba(226,232,240,.65) !important;
  font-weight: 850 !important;
}

.stt-leverage-range {
  --lev-pct: 0%;
  -webkit-appearance: none !important;
  appearance: none !important;
  display: block !important;
  width: calc(100% - 6px) !important;
  height: 3px !important;
  min-height: 3px !important;
  margin: 7px 3px 0 !important;
  padding: 0 !important;
  border-radius: 999px !important;
  outline: none !important;
  cursor: pointer !important;
  background:
    linear-gradient(90deg, #22c55e 0%, #22c55e var(--lev-pct), rgba(71,85,105,.72) var(--lev-pct), rgba(71,85,105,.72) 100%) !important;
}

.stt-leverage-range::-webkit-slider-runnable-track {
  height: 3px !important;
  border-radius: 999px !important;
  background: transparent !important;
}

.stt-leverage-range::-webkit-slider-thumb {
  -webkit-appearance: none !important;
  appearance: none !important;
  width: 13px !important;
  height: 13px !important;
  border-radius: 999px !important;
  margin-top: -5px !important;
  background: linear-gradient(135deg, #22c55e, #14b8a6) !important;
  border: 2px solid rgba(240,253,244,.96) !important;
  box-shadow: 0 0 0 3px rgba(34,197,94,.13), 0 6px 16px rgba(0,0,0,.34) !important;
  cursor: pointer !important;
}

.stt-leverage-range::-moz-range-track,
.stt-leverage-range::-moz-range-progress {
  height: 3px !important;
  border-radius: 999px !important;
}

.stt-leverage-range::-moz-range-thumb {
  width: 13px !important;
  height: 13px !important;
  border-radius: 999px !important;
  background: linear-gradient(135deg, #22c55e, #14b8a6) !important;
  border: 2px solid rgba(240,253,244,.96) !important;
}

.stt-leverage-marks {
  display: flex !important;
  justify-content: space-between !important;
  gap: 4px !important;
  margin-top: 5px !important;
  padding: 0 1px !important;
  font-size: 8.8px !important;
  line-height: 1 !important;
  font-weight: 850 !important;
  color: rgba(226,232,240,.60) !important;
}

/* Estimate/warning */
.stt-manual-futures-estimate {
  margin-top: 8px !important;
  padding: 6px 8px !important;
  border-radius: 10px !important;
  background: rgba(34,197,94,.08) !important;
  border: 1px solid rgba(34,197,94,.16) !important;
  color: #bbf7d0 !important;
  font-size: 11px !important;
  line-height: 1.2 !important;
  font-weight: 900 !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}

.stt-manual-futures-warning {
  margin-top: 6px !important;
  font-size: 10.3px !important;
  line-height: 1.25 !important;
  color: rgba(254,240,138,.88) !important;
}

/* Keep rest compact */
.stt-manual-open-risk-grid {
  gap: 8px !important;
  margin-top: 8px !important;
}

.stt-manual-open-note {
  margin-top: 6px !important;
  font-size: 10.7px !important;
  color: rgba(203,213,225,.72) !important;
}

.stt-manual-open-actions {
  gap: 8px !important;
  margin-top: 9px !important;
}

.stt-manual-sell-btn,
.stt-manual-buy-btn {
  height: 39px !important;
  min-height: 39px !important;
  border-radius: 12px !important;
  font-size: 12.5px !important;
  font-weight: 950 !important;
}

/* Mobile */
@media (max-width: 720px) {
  .stt-manual-open-card {
    width: min(94vw, 420px) !important;
    max-height: 88vh !important;
    overflow-y: auto !important;
  }

  .stt-manual-futures-grid {
    grid-template-columns: 1fr 1fr !important;
  }

  .stt-manual-futures-grid > .stt-manual-open-field:nth-child(1),
  #sttManualLimitPriceWrap {
    grid-column: 1 / -1 !important;
  }
}



/* STT STEP62.5R — Final ultra-thin green filled Amount + Leverage sliders */
.stt-hide-old-amount-presets {
  display: none !important;
}

.stt-amount-field {
  margin-bottom: 8px !important;
}

.stt-amount-slider-head {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 8px !important;
  margin: 6px 0 0 !important;
}

.stt-amount-slider-head span,
.stt-leverage-slider-head span {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  min-width: 42px !important;
  height: 20px !important;
  padding: 0 8px !important;
  border-radius: 999px !important;
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.24), rgba(20, 184, 166, 0.16)) !important;
  border: 1px solid rgba(34, 197, 94, 0.34) !important;
  color: #bbf7d0 !important;
  font-size: 10.8px !important;
  font-weight: 950 !important;
}

.stt-amount-slider-head small,
.stt-leverage-slider-head small {
  font-size: 8.8px !important;
  color: rgba(226, 232, 240, 0.62) !important;
  font-weight: 800 !important;
}

.stt-amount-range {
  --amt-pct: 2.4%;
  -webkit-appearance: none !important;
  appearance: none !important;
  display: block !important;
  width: calc(100% - 4px) !important;
  height: 2px !important;
  min-height: 2px !important;
  margin: 7px 2px 0 !important;
  padding: 0 !important;
  border-radius: 999px !important;
  outline: none !important;
  cursor: pointer !important;
  background: linear-gradient(
    90deg,
    #22c55e 0%,
    #22c55e var(--amt-pct),
    rgba(71, 85, 105, 0.72) var(--amt-pct),
    rgba(71, 85, 105, 0.72) 100%
  ) !important;
}

.stt-leverage-range {
  --lev-pct: 0%;
  -webkit-appearance: none !important;
  appearance: none !important;
  display: block !important;
  width: calc(100% - 4px) !important;
  height: 2px !important;
  min-height: 2px !important;
  margin: 7px 2px 0 !important;
  padding: 0 !important;
  border-radius: 999px !important;
  outline: none !important;
  cursor: pointer !important;
  background: linear-gradient(
    90deg,
    #22c55e 0%,
    #22c55e var(--lev-pct),
    rgba(71, 85, 105, 0.72) var(--lev-pct),
    rgba(71, 85, 105, 0.72) 100%
  ) !important;
}

.stt-amount-range::-webkit-slider-runnable-track,
.stt-leverage-range::-webkit-slider-runnable-track {
  height: 2px !important;
  background: transparent !important;
  border-radius: 999px !important;
}

.stt-amount-range::-webkit-slider-thumb,
.stt-leverage-range::-webkit-slider-thumb {
  -webkit-appearance: none !important;
  appearance: none !important;
  width: 11px !important;
  height: 11px !important;
  border-radius: 999px !important;
  margin-top: -4.5px !important;
  background: linear-gradient(135deg, #22c55e, #14b8a6) !important;
  border: 2px solid rgba(240, 253, 244, 0.96) !important;
  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.13), 0 5px 14px rgba(0, 0, 0, 0.34) !important;
}

.stt-amount-range::-moz-range-track,
.stt-leverage-range::-moz-range-track,
.stt-amount-range::-moz-range-progress,
.stt-leverage-range::-moz-range-progress {
  height: 2px !important;
  border-radius: 999px !important;
}

.stt-amount-range::-moz-range-progress,
.stt-leverage-range::-moz-range-progress {
  background: #22c55e !important;
}

.stt-amount-range::-moz-range-thumb,
.stt-leverage-range::-moz-range-thumb {
  width: 11px !important;
  height: 11px !important;
  border-radius: 999px !important;
  background: linear-gradient(135deg, #22c55e, #14b8a6) !important;
  border: 2px solid rgba(240, 253, 244, 0.96) !important;
}

.stt-amount-marks,
.stt-leverage-marks {
  display: flex !important;
  justify-content: space-between !important;
  gap: 4px !important;
  margin-top: 5px !important;
  padding: 0 1px !important;
  font-size: 8.6px !important;
  line-height: 1 !important;
  font-weight: 850 !important;
  color: rgba(226, 232, 240, 0.58) !important;
}

/* STT STEP62.5T — Force ultra-thin green filled range sliders */
#sttManualOpenLeverage.stt-leverage-range,
#sttManualOpenAmountRange.stt-amount-range {
  --range-pct: 0%;
  -webkit-appearance: none !important;
  appearance: none !important;
  display: block !important;
  width: 100% !important;
  height: 12px !important;          /* only hit-area, not visual line */
  min-height: 12px !important;
  padding: 0 !important;
  margin: 5px 0 0 !important;
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
  border-radius: 999px !important;
  cursor: pointer !important;
  background: transparent !important;
}

/* Chrome / Edge actual visible line */
#sttManualOpenLeverage.stt-leverage-range::-webkit-slider-runnable-track {
  height: 2px !important;
  border: 0 !important;
  border-radius: 999px !important;
  background:
    linear-gradient(
      90deg,
      #22c55e 0%,
      #22c55e var(--lev-pct),
      rgba(71, 85, 105, 0.72) var(--lev-pct),
      rgba(71, 85, 105, 0.72) 100%
    ) !important;
}

#sttManualOpenAmountRange.stt-amount-range::-webkit-slider-runnable-track {
  height: 2px !important;
  border: 0 !important;
  border-radius: 999px !important;
  background:
    linear-gradient(
      90deg,
      #22c55e 0%,
      #22c55e var(--amt-pct),
      rgba(71, 85, 105, 0.72) var(--amt-pct),
      rgba(71, 85, 105, 0.72) 100%
    ) !important;
}

#sttManualOpenLeverage.stt-leverage-range::-webkit-slider-thumb,
#sttManualOpenAmountRange.stt-amount-range::-webkit-slider-thumb {
  -webkit-appearance: none !important;
  appearance: none !important;
  width: 11px !important;
  height: 11px !important;
  border-radius: 999px !important;
  margin-top: -4.5px !important;
  background: linear-gradient(135deg, #22c55e, #14b8a6) !important;
  border: 2px solid rgba(240, 253, 244, 0.96) !important;
  box-shadow:
    0 0 0 3px rgba(34, 197, 94, 0.13),
    0 5px 14px rgba(0, 0, 0, 0.34) !important;
  cursor: pointer !important;
}

/* Firefox */
#sttManualOpenLeverage.stt-leverage-range::-moz-range-track,
#sttManualOpenAmountRange.stt-amount-range::-moz-range-track {
  height: 2px !important;
  border: 0 !important;
  border-radius: 999px !important;
  background: rgba(71, 85, 105, 0.72) !important;
}

#sttManualOpenLeverage.stt-leverage-range::-moz-range-progress,
#sttManualOpenAmountRange.stt-amount-range::-moz-range-progress {
  height: 2px !important;
  border-radius: 999px !important;
  background: #22c55e !important;
}

#sttManualOpenLeverage.stt-leverage-range::-moz-range-thumb,
#sttManualOpenAmountRange.stt-amount-range::-moz-range-thumb {
  width: 11px !important;
  height: 11px !important;
  border-radius: 999px !important;
  background: linear-gradient(135deg, #22c55e, #14b8a6) !important;
  border: 2px solid rgba(240, 253, 244, 0.96) !important;
}

/* Remove old visual rectangle caused by generic input style */
.stt-manual-open-field input[type="range"].stt-leverage-range,
.stt-manual-open-field input[type="range"].stt-amount-range {
  background-color: transparent !important;
  border-color: transparent !important;
}

/* Tighter labels around sliders */
.stt-amount-slider-head,
.stt-leverage-slider-head {
  margin-top: 4px !important;
  margin-bottom: 2px !important;
}

.stt-amount-marks,
.stt-leverage-marks {
  margin-top: 1px !important;
}

/* STT STEP62.5V — Mobile compact Open Trade modal */
@media (max-width: 720px) {
  .stt-manual-open-overlay {
    align-items: center !important;
    justify-content: center !important;
    padding: 8px !important;
  }

  .stt-manual-open-card {
    width: min(92vw, 390px) !important;
    max-height: 84vh !important;
    overflow-y: auto !important;
    padding: 11px 12px !important;
    border-radius: 17px !important;
  }

  .stt-manual-open-head {
    margin-bottom: 6px !important;
  }

  .stt-manual-open-title {
    font-size: 15px !important;
    line-height: 1.05 !important;
  }

  .stt-manual-open-subtitle,
  .stt-manual-open-price-hint {
    font-size: 10.3px !important;
    line-height: 1.15 !important;
  }

  .stt-manual-open-x {
    width: 34px !important;
    height: 34px !important;
    min-width: 34px !important;
  }

  .stt-manual-open-field {
    margin-bottom: 6px !important;
  }

  .stt-manual-open-field label {
    font-size: 10.5px !important;
    margin-bottom: 4px !important;
  }

  .stt-manual-open-field input,
  .stt-manual-open-field select {
    height: 32px !important;
    min-height: 32px !important;
    padding: 6px 9px !important;
    font-size: 11.5px !important;
    border-radius: 10px !important;
  }

  /* Amount slider mobile compact */
  .stt-amount-slider-head {
    margin: 4px 0 0 !important;
  }

  .stt-amount-slider-head span {
    height: 19px !important;
    min-width: 39px !important;
    font-size: 10px !important;
  }

  .stt-amount-slider-head small {
    font-size: 8.2px !important;
  }

  #sttManualOpenAmountRange.stt-amount-range {
    height: 10px !important;
    min-height: 10px !important;
    margin-top: 4px !important;
  }

  .stt-amount-marks {
    font-size: 7.8px !important;
    margin-top: 1px !important;
  }

  .stt-hide-old-amount-presets {
    display: none !important;
  }

  /* Futures controls mobile compact */
  .stt-manual-futures-controls {
    margin: 6px 0 8px !important;
    padding: 8px !important;
    border-radius: 13px !important;
  }

  .stt-manual-futures-head {
    margin-bottom: 5px !important;
  }

  .stt-manual-futures-head span {
    font-size: 11.5px !important;
  }

  .stt-manual-futures-head small {
    font-size: 8.6px !important;
  }

  .stt-manual-futures-grid {
    grid-template-columns: 1fr 1fr !important;
    gap: 6px !important;
  }

  .stt-manual-futures-grid > .stt-manual-open-field:nth-child(1) {
    grid-column: 1 / -1 !important;
  }

  #sttManualLimitPriceWrap {
    grid-column: 1 / -1 !important;
  }

  .stt-leverage-slider-head {
    height: 19px !important;
    margin-bottom: 2px !important;
  }

  .stt-leverage-slider-head span {
    height: 19px !important;
    min-width: 36px !important;
    font-size: 10px !important;
  }

  .stt-leverage-slider-head small {
    font-size: 8.2px !important;
  }

  #sttManualOpenLeverage.stt-leverage-range {
    height: 10px !important;
    min-height: 10px !important;
    margin-top: 4px !important;
  }

  .stt-leverage-marks {
    font-size: 7.8px !important;
    margin-top: 1px !important;
  }

  #sttManualOpenMarginMode,
  #sttManualOpenOrderType,
  #sttManualOpenLimitPrice {
    height: 31px !important;
    min-height: 31px !important;
    padding: 5px 8px !important;
    font-size: 11.2px !important;
    border-radius: 9px !important;
  }

  .stt-manual-futures-estimate {
    margin-top: 6px !important;
    padding: 6px 8px !important;
    font-size: 10.2px !important;
    line-height: 1.15 !important;
  }

  .stt-manual-futures-warning {
    margin-top: 4px !important;
    font-size: 9.7px !important;
    line-height: 1.18 !important;
  }

  /* SL / TP same row on phone */
  .stt-manual-open-risk-grid {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 7px !important;
    margin-top: 7px !important;
  }

  .stt-manual-open-risk-grid .stt-manual-open-field {
    margin-bottom: 0 !important;
    min-width: 0 !important;
  }

  .stt-manual-open-risk-grid input {
    height: 32px !important;
    min-height: 32px !important;
    padding: 6px 8px !important;
    font-size: 11.2px !important;
  }

  .stt-manual-open-note {
    margin-top: 6px !important;
    font-size: 9.8px !important;
    line-height: 1.2 !important;
  }

  .stt-manual-open-actions {
    gap: 7px !important;
    margin-top: 8px !important;
  }

  .stt-manual-sell-btn,
  .stt-manual-buy-btn {
    height: 37px !important;
    min-height: 37px !important;
    border-radius: 12px !important;
    font-size: 12px !important;
  }
}

/* STT STEP 62.6 — Pending limit order line/tag on chart */
.stt-chart-pending-layer {
  position: absolute;
  inset: 0;
  z-index: 14;
  pointer-events: none;
}

.stt-pending-limit-row {
  position: absolute;
  left: 8px;
  right: 74px;
  height: 0;
  border-top: 1px dotted rgba(250, 204, 21, 0.96);
  filter: drop-shadow(0 0 8px rgba(250, 204, 21, 0.35));
  pointer-events: none;
}

.stt-pending-limit-label {
  position: absolute;
  top: -14px;
  left: 8px;
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 4px 9px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.94);
  border: 1px solid rgba(250, 204, 21, 0.78);
  color: #fde68a;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .04em;
  text-transform: uppercase;
  white-space: nowrap;
  box-shadow: 0 10px 22px rgba(0,0,0,.32);
  pointer-events: none;
}

.stt-pending-limit-cancel {
  position: absolute;
  top: -14px;
  right: -34px;
  width: 24px;
  height: 24px;
  border-radius: 999px;
  border: 1px solid rgba(250, 204, 21, 0.75);
  background: rgba(24, 24, 27, 0.96);
  color: #facc15;
  font-size: 18px;
  line-height: 18px;
  font-weight: 900;
  cursor: pointer;
  pointer-events: auto;
  box-shadow: 0 10px 22px rgba(0,0,0,.35);
}

.stt-pending-limit-cancel:hover {
  background: rgba(127, 29, 29, 0.95);
  color: #fff7ed;
  border-color: rgba(251, 113, 133, 0.95);
}

@media (max-width: 720px) {
  .stt-pending-limit-row {
    left: 6px;
    right: 46px;
  }
  .stt-pending-limit-label {
    max-width: 210px;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 9px;
    padding: 4px 7px;
  }
  .stt-pending-limit-cancel {
    right: -28px;
    width: 22px;
    height: 22px;
    font-size: 17px;
  }
}

/* STT STEP 62.6S — Professional pending limit polish */
.stt-chart-pending-layer {
  z-index: 42 !important;
  pointer-events: none;
}

.stt-pending-limit-row {
  left: 10px !important;
  right: 86px !important;
  border-top: 1px dashed rgba(250, 204, 21, 0.92) !important;
  filter: drop-shadow(0 0 7px rgba(250, 204, 21, 0.28)) !important;
}

.stt-pending-limit-label {
  top: -13px !important;
  left: 12px !important;
  min-height: 22px !important;
  padding: 4px 10px !important;
  border-radius: 999px !important;
  background: linear-gradient(135deg, rgba(24, 24, 27, 0.98), rgba(63, 48, 5, 0.96)) !important;
  border: 1px solid rgba(250, 204, 21, 0.88) !important;
  color: #fde68a !important;
  font-size: 10px !important;
  font-weight: 900 !important;
  letter-spacing: .035em !important;
  text-transform: uppercase !important;
  box-shadow: 0 0 0 1px rgba(250,204,21,.08), 0 8px 20px rgba(0,0,0,.35), 0 0 18px rgba(250,204,21,.20) !important;
}

.stt-pending-limit-label::before {
  content: "⏳";
  margin-right: 5px;
  font-size: 10px;
}

.stt-pending-limit-cancel {
  top: -13px !important;
  left: 176px !important;
  right: auto !important;
  width: 22px !important;
  height: 22px !important;
  border-radius: 999px !important;
  background: rgba(15, 23, 42, 0.98) !important;
  border: 1px solid rgba(250, 204, 21, 0.85) !important;
  color: #facc15 !important;
  font-size: 16px !important;
  line-height: 18px !important;
  font-weight: 950 !important;
  cursor: pointer !important;
  pointer-events: auto !important;
  z-index: 45 !important;
  box-shadow: 0 8px 18px rgba(0,0,0,.35), 0 0 12px rgba(250,204,21,.20) !important;
}

.stt-pending-limit-cancel:hover {
  background: linear-gradient(135deg, rgba(185, 28, 28, 0.96), rgba(127, 29, 29, 0.98)) !important;
  color: #fff !important;
  border-color: rgba(254, 202, 202, 0.95) !important;
  transform: scale(1.06);
}

.stt-pending-limit-cancel.is-loading {
  opacity: .55;
  cursor: wait !important;
  transform: none !important;
}

@media (max-width: 720px) {
  .stt-pending-limit-row {
    left: 7px !important;
    right: 52px !important;
  }

  .stt-pending-limit-label {
    left: 8px !important;
    max-width: 160px !important;
    font-size: 9px !important;
    padding: 4px 8px !important;
  }

  .stt-pending-limit-cancel {
    left: 150px !important;
    width: 21px !important;
    height: 21px !important;
    font-size: 15px !important;
  }
}

/* STT STEP 62.6V — Pending label + amount + cancel clean flex spacing */
.stt-pending-limit-row {
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  width: auto !important;
  max-width: calc(100% - 120px) !important;
  right: auto !important;
  height: 0 !important;
  pointer-events: none !important;
}

.stt-pending-limit-label {
  position: relative !important;
  top: -13px !important;
  left: 12px !important;
  width: auto !important;
  max-width: 320px !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  pointer-events: none !important;
}

.stt-pending-limit-cancel {
  position: relative !important;
  top: -13px !important;
  left: 12px !important;
  right: auto !important;
  flex: 0 0 auto !important;
  margin-left: 2px !important;
  pointer-events: auto !important;
}

@media (max-width: 720px) {
  .stt-pending-limit-row {
    max-width: calc(100% - 70px) !important;
    gap: 6px !important;
  }

  .stt-pending-limit-label {
    left: 8px !important;
    max-width: 210px !important;
  }

  .stt-pending-limit-cancel {
    left: 8px !important;
    margin-left: 1px !important;
  }
}

/* STT STEP 62.6W — Center pending label/cancel exactly on dotted line */
.stt-pending-limit-row {
  align-items: center !important;
  height: 0 !important;
  line-height: 0 !important;
}

.stt-pending-limit-label {
  top: 0 !important;
  transform: translateY(-50%) !important;
  line-height: 14px !important;
}

.stt-pending-limit-cancel {
  top: 0 !important;
  transform: translateY(-50%) !important;
  line-height: 18px !important;
}

.stt-pending-limit-cancel:hover {
  transform: translateY(-50%) scale(1.06) !important;
}

.stt-pending-limit-cancel.is-loading {
  transform: translateY(-50%) !important;
}

@media (max-width: 720px) {
  .stt-pending-limit-label {
    top: 0 !important;
    transform: translateY(-50%) !important;
  }

  .stt-pending-limit-cancel {
    top: 0 !important;
    transform: translateY(-50%) !important;
  }

  .stt-pending-limit-cancel:hover {
    transform: translateY(-50%) scale(1.06) !important;
  }
}

/* STT STEP 62.6X — Final pending label vertical center fix */
.stt-pending-limit-row {
  align-items: center !important;
  height: 0 !important;
  line-height: 0 !important;
}

.stt-pending-limit-label {
  top: 0 !important;
  transform: translateY(-28%) !important;
  line-height: 14px !important;
}

.stt-pending-limit-cancel {
  top: 0 !important;
  transform: translateY(-28%) !important;
  line-height: 18px !important;
}

.stt-pending-limit-cancel:hover {
  transform: translateY(-28%) scale(1.06) !important;
}

.stt-pending-limit-cancel.is-loading {
  transform: translateY(-28%) !important;
}

@media (max-width: 720px) {
  .stt-pending-limit-label {
    top: 0 !important;
    transform: translateY(-28%) !important;
  }

  .stt-pending-limit-cancel {
    top: 0 !important;
    transform: translateY(-28%) !important;
  }

  .stt-pending-limit-cancel:hover {
    transform: translateY(-28%) scale(1.06) !important;
  }
}

/* STT STEP 62.6Y — Final exact center: flex handles vertical centering, no upward transform */
.stt-pending-limit-row {
  display: inline-flex !important;
  align-items: center !important;
  height: 0 !important;
  line-height: 0 !important;
}

.stt-pending-limit-label {
  top: 0 !important;
  transform: translateY(0) !important;
  line-height: 14px !important;
}

.stt-pending-limit-cancel {
  top: 0 !important;
  transform: translateY(0) !important;
  line-height: 18px !important;
}

.stt-pending-limit-cancel:hover {
  transform: scale(1.06) !important;
}

.stt-pending-limit-cancel.is-loading {
  transform: translateY(0) !important;
}

@media (max-width: 720px) {
  .stt-pending-limit-label {
    top: 0 !important;
    transform: translateY(0) !important;
  }

  .stt-pending-limit-cancel {
    top: 0 !important;
    transform: translateY(0) !important;
  }

  .stt-pending-limit-cancel:hover {
    transform: scale(1.06) !important;
  }
}

/* STT STEP 62.6.6A — Signal Center pending limit rows */
.stt-status-pill.stt-status-pending,
.stt-status-pending {
  background: rgba(250, 204, 21, 0.14) !important;
  border: 1px solid rgba(250, 204, 21, 0.55) !important;
  color: #fde68a !important;
  box-shadow: 0 0 14px rgba(250, 204, 21, 0.16) !important;
}

.stt-pending-cancel-signal-btn {
  background: linear-gradient(135deg, rgba(113, 63, 18, 0.96), rgba(24, 24, 27, 0.98)) !important;
  border: 1px solid rgba(250, 204, 21, 0.75) !important;
  color: #fde68a !important;
}

.stt-pending-cancel-signal-btn:hover {
  background: linear-gradient(135deg, rgba(185, 28, 28, 0.96), rgba(127, 29, 29, 0.98)) !important;
  color: #fff !important;
  border-color: rgba(254, 202, 202, 0.95) !important;
}

/* STT STEP 62.6.8 — Pending limit drag/modify */
.stt-pending-limit-label {
  cursor: ns-resize !important;
  pointer-events: auto !important;
  user-select: none !important;
}

body.stt-pending-limit-dragging,
body.stt-pending-limit-dragging * {
  cursor: ns-resize !important;
  user-select: none !important;
}

body.stt-pending-limit-dragging .stt-pending-limit-label {
  box-shadow: 0 0 0 1px rgba(250,204,21,.22), 0 10px 26px rgba(0,0,0,.42), 0 0 26px rgba(250,204,21,.32) !important;
}

/* STT STEP 62.6.9 — Open Trade amount balance pill */
.stt-manual-amount-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}

.stt-manual-amount-head label {
  margin: 0 !important;
}

.stt-manual-balance-pill {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  max-width: 58%;
  padding: 3px 8px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.25);
  background: rgba(15, 23, 42, 0.78);
  color: rgba(226, 232, 240, 0.82);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .015em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.stt-manual-balance-pill.paper {
  border-color: rgba(34, 197, 94, 0.34);
  color: #bbf7d0;
  background: rgba(6, 78, 59, 0.38);
}

.stt-manual-balance-pill.testnet {
  border-color: rgba(250, 204, 21, 0.42);
  color: #fde68a;
  background: rgba(113, 63, 18, 0.34);
}

.stt-manual-balance-pill.live {
  border-color: rgba(56, 189, 248, 0.42);
  color: #bae6fd;
  background: rgba(12, 74, 110, 0.36);
}

.stt-manual-balance-pill.missing,
.stt-manual-balance-pill.error {
  border-color: rgba(148, 163, 184, 0.25);
  color: rgba(203, 213, 225, 0.72);
}

@media (max-width: 720px) {
  .stt-manual-amount-head {
    gap: 6px;
  }

  .stt-manual-balance-pill {
    max-width: 54%;
    font-size: 9px;
    padding: 3px 6px;
  }
}

/* STT STEP63.5B — Exchange Hub 2-card Spot/Futures API toggle */
.stt-api-mode-toggle{
  margin:10px 0 12px;
  padding:12px;
  border:1px solid rgba(34,211,238,.24);
  border-radius:16px;
  background:linear-gradient(135deg, rgba(8,47,73,.72), rgba(46,16,101,.54));
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.035);
}
.stt-api-mode-title{
  font-weight:900;
  color:#eaf6ff;
  font-size:13px;
  margin-bottom:8px;
}
.stt-api-mode-buttons{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:8px;
}
.stt-api-mode-buttons button{
  border:1px solid rgba(34,211,238,.24);
  border-radius:999px;
  background:rgba(15,23,42,.72);
  color:#a8c7ff;
  font-weight:900;
  padding:9px 10px;
  cursor:pointer;
  transition:.18s ease;
}
.stt-api-mode-buttons button.active{
  color:#ffffff;
  background:linear-gradient(135deg,#06b6d4,#7c3aed);
  border-color:rgba(255,255,255,.25);
  box-shadow:0 0 18px rgba(34,211,238,.18);
}
.stt-api-mode-note{
  margin-top:8px;
  line-height:1.35;
}
@media(max-width:680px){
  .stt-api-mode-buttons{
    grid-template-columns:1fr;
  }
}

/* STT STEP63.5D — Exchange Hub Spot/Futures toggle no-jump polish */
#page-exchange #binanceTestnetStatus,
#page-exchange #binanceStatus{
  min-height:180px;
}

#page-exchange #binanceTestnetBalanceBox,
#page-exchange #binanceBalanceBox{
  min-height:104px;
}

html.stt-exchange-no-jump-refresh{
  scroll-behavior:auto !important;
}

html.stt-exchange-no-jump-refresh #page-exchange #binanceTestnetStatus,
html.stt-exchange-no-jump-refresh #page-exchange #binanceStatus,
html.stt-exchange-no-jump-refresh #page-exchange #binanceTestnetBalanceBox,
html.stt-exchange-no-jump-refresh #page-exchange #binanceBalanceBox{
  transition:none !important;
}

#page-exchange .stt-api-mode-toggle{
  min-height:92px;
}

/* STT STEP63.5E — hard no-jump toggle behavior */
#page-exchange .stt-api-mode-toggle,
#page-exchange .stt-api-mode-buttons,
#page-exchange .stt-api-mode-buttons button{
  transform:none !important;
}

#page-exchange .stt-api-mode-buttons button:focus{
  outline:none !important;
}

#page-exchange .stt-api-mode-buttons button:active{
  transform:none !important;
}

#page-exchange #binanceTestnetStatus,
#page-exchange #binanceStatus{
  overflow:hidden;
}

#page-exchange .balance-head{
  min-height:44px;
}

/* STT STEP63.6H — Stable Exchange action button refresh */
#page-exchange #binanceTestnetStatus,
#page-exchange #binanceStatus{
  min-height:220px !important;
}

#page-exchange #binanceTestnetBalanceBox,
#page-exchange #binanceBalanceBox{
  min-height:120px !important;
}

html.stt-exchange-no-jump-refresh,
html.stt-exchange-no-jump-refresh *{
  scroll-behavior:auto !important;
}

html.stt-exchange-no-jump-refresh #page-exchange #binanceTestnetStatus,
html.stt-exchange-no-jump-refresh #page-exchange #binanceStatus,
html.stt-exchange-no-jump-refresh #page-exchange #binanceTestnetBalanceBox,
html.stt-exchange-no-jump-refresh #page-exchange #binanceBalanceBox{
  transition:none !important;
}

/* STT STEP63.6X — Prevent Exchange API toggle late-inject card jump */
#page-exchange .stt-api-mode-toggle{
  min-height:92px !important;
  opacity:1;
}

#page-exchange:not(.stt-exchange-toggles-ready) #binanceTestnetApiKey,
#page-exchange:not(.stt-exchange-toggles-ready) #binanceApiKey{
  margin-top:104px !important;
}

#page-exchange.stt-exchange-toggles-ready #binanceTestnetApiKey,
#page-exchange.stt-exchange-toggles-ready #binanceApiKey{
  margin-top:0 !important;
}

/* STT STEP63.6Y — Exchange Hub scroll anchor/jump fix */
#page-exchange,
#page-exchange *{
  overflow-anchor:none !important;
}

#page-exchange .card,
#page-exchange .compact-page-grid,
#page-exchange #binanceTestnetStatus,
#page-exchange #binanceStatus,
#page-exchange #binanceTestnetBalanceBox,
#page-exchange #binanceBalanceBox,
#page-exchange .stt-api-mode-toggle{
  overflow-anchor:none !important;
}

#page-exchange .stt-api-mode-toggle{
  min-height:92px !important;
}

#page-exchange #binanceTestnetStatus,
#page-exchange #binanceStatus{
  min-height:178px !important;
}

#page-exchange #binanceTestnetBalanceBox,
#page-exchange #binanceBalanceBox{
  min-height:116px !important;
}

/* During scroll, avoid visual transition flicker/jump in Exchange Hub cards */
body.stt-exchange-user-scrolling #page-exchange .card,
body.stt-exchange-user-scrolling #page-exchange #binanceTestnetStatus,
body.stt-exchange-user-scrolling #page-exchange #binanceStatus,
body.stt-exchange-user-scrolling #page-exchange #binanceTestnetBalanceBox,
body.stt-exchange-user-scrolling #page-exchange #binanceBalanceBox{
  transition:none !important;
}

/* STT STEP63.6Z — Stable Exchange balance box height to prevent page jump */
#page-exchange #binanceTestnetBalanceBox,
#page-exchange #binanceBalanceBox{
  min-height:226px !important;
  contain:layout paint;
}

#page-exchange .balance-head{
  min-height:48px !important;
}

#page-exchange .balance-grid{
  min-height:96px !important;
}

#page-exchange .balance-asset-card{
  min-height:86px !important;
}

#page-exchange .stt-balance-skeleton-card{
  opacity:.72;
}

#page-exchange .stt-balance-skeleton-card .balance-total{
  color:#94a3b8 !important;
}

#page-exchange .stt-balance-stable-footer{
  min-height:18px !important;
}

/* Desktop: enough reserved height for 5 asset cards */
@media (min-width: 901px){
  #page-exchange #binanceTestnetBalanceBox,
  #page-exchange #binanceBalanceBox{
    min-height:232px !important;
  }
}

/* Mobile: keep room but avoid oversized cards */
@media (max-width: 900px){
  #page-exchange #binanceTestnetBalanceBox,
  #page-exchange #binanceBalanceBox{
    min-height:260px !important;
  }
}

/* STT STEP63.6ZA — Stable compact Testnet/Live API status box */
#page-exchange #binanceTestnetStatus,
#page-exchange #binanceStatus{
  min-height:232px !important;
  max-height:232px !important;
  overflow:hidden !important;
  contain:layout paint;
}

#page-exchange #binanceTestnetStatus .stt-status-stable-head,
#page-exchange #binanceStatus .stt-status-stable-head,
#page-exchange #binanceTestnetStatus > div:first-child,
#page-exchange #binanceStatus > div:first-child{
  min-height:42px !important;
  margin-bottom:8px !important;
}

#page-exchange #binanceTestnetStatus b,
#page-exchange #binanceStatus b{
  font-size:15px !important;
  line-height:1.15 !important;
}

#page-exchange #binanceTestnetStatus .mini-muted,
#page-exchange #binanceStatus .mini-muted{
  font-size:11px !important;
  line-height:1.25 !important;
}

#page-exchange #binanceTestnetStatus .bot-meta,
#page-exchange #binanceStatus .bot-meta,
#page-exchange #binanceTestnetStatus .stt-status-stable-meta,
#page-exchange #binanceStatus .stt-status-stable-meta{
  display:grid !important;
  grid-template-columns:repeat(3, minmax(0, 1fr)) !important;
  gap:8px !important;
  margin-top:8px !important;
}

#page-exchange #binanceTestnetStatus .meta-box,
#page-exchange #binanceStatus .meta-box{
  min-height:58px !important;
  padding:9px 10px !important;
  border-radius:13px !important;
}

#page-exchange #binanceTestnetStatus .meta-label,
#page-exchange #binanceStatus .meta-label{
  font-size:10px !important;
  margin-bottom:4px !important;
}

#page-exchange #binanceTestnetStatus .meta-value,
#page-exchange #binanceStatus .meta-value{
  font-size:13px !important;
  line-height:1.2 !important;
}

#page-exchange #binanceTestnetStatus .binance-status-warning,
#page-exchange #binanceStatus .binance-status-warning,
#page-exchange #binanceTestnetStatus .stt-status-stable-warning,
#page-exchange #binanceStatus .stt-status-stable-warning{
  min-height:48px !important;
  max-height:58px !important;
  overflow:hidden !important;
  padding:9px 11px !important;
  margin-top:8px !important;
  border-radius:13px !important;
  font-size:12px !important;
  line-height:1.35 !important;
}

/* Desktop slightly tighter */
@media (min-width: 901px){
  #page-exchange #binanceTestnetStatus,
  #page-exchange #binanceStatus{
    min-height:214px !important;
    max-height:214px !important;
  }

  #page-exchange #binanceTestnetStatus .binance-status-warning,
  #page-exchange #binanceStatus .binance-status-warning{
    min-height:44px !important;
    max-height:52px !important;
  }
}

/* Mobile keep readable */
@media (max-width: 900px){
  #page-exchange #binanceTestnetStatus,
  #page-exchange #binanceStatus{
    min-height:238px !important;
    max-height:238px !important;
  }
}

/* STT STEP63.6ZB — Fix API status text clipping while keeping stable height */
#page-exchange #binanceTestnetStatus,
#page-exchange #binanceStatus{
  min-height:268px !important;
  height:268px !important;
  max-height:268px !important;
  overflow:hidden !important;
  padding:14px !important;
  box-sizing:border-box !important;
  contain:layout paint;
}

#page-exchange #binanceTestnetStatus > div:first-child,
#page-exchange #binanceStatus > div:first-child,
#page-exchange #binanceTestnetStatus .stt-status-stable-head,
#page-exchange #binanceStatus .stt-status-stable-head{
  min-height:44px !important;
  margin-bottom:8px !important;
}

#page-exchange #binanceTestnetStatus .bot-meta,
#page-exchange #binanceStatus .bot-meta,
#page-exchange #binanceTestnetStatus .stt-status-stable-meta,
#page-exchange #binanceStatus .stt-status-stable-meta{
  display:grid !important;
  grid-template-columns:repeat(3, minmax(0, 1fr)) !important;
  gap:8px !important;
  margin-top:8px !important;
  margin-bottom:8px !important;
}

#page-exchange #binanceTestnetStatus .meta-box,
#page-exchange #binanceStatus .meta-box{
  min-height:56px !important;
  padding:8px 10px !important;
  border-radius:13px !important;
  box-sizing:border-box !important;
}

#page-exchange #binanceTestnetStatus .meta-label,
#page-exchange #binanceStatus .meta-label{
  font-size:10px !important;
  margin-bottom:4px !important;
  line-height:1.1 !important;
}

#page-exchange #binanceTestnetStatus .meta-value,
#page-exchange #binanceStatus .meta-value{
  font-size:13px !important;
  line-height:1.18 !important;
  word-break:break-word !important;
}

#page-exchange #binanceTestnetStatus .binance-status-warning,
#page-exchange #binanceStatus .binance-status-warning,
#page-exchange #binanceTestnetStatus .stt-status-stable-warning,
#page-exchange #binanceStatus .stt-status-stable-warning{
  display:block !important;
  min-height:72px !important;
  max-height:84px !important;
  overflow:hidden !important;
  padding:9px 11px !important;
  margin-top:8px !important;
  border-radius:13px !important;
  font-size:11.5px !important;
  line-height:1.32 !important;
  box-sizing:border-box !important;
}

/* Live status warning is longer, keep it readable without changing box height */
#page-exchange #binanceStatus .binance-status-warning{
  font-size:11px !important;
  line-height:1.28 !important;
}

/* Balance boxes remain stable but not oversized */
#page-exchange #binanceTestnetBalanceBox,
#page-exchange #binanceBalanceBox{
  min-height:232px !important;
  height:auto !important;
  overflow:visible !important;
}

/* Mobile readability */
@media(max-width:900px){
  #page-exchange #binanceTestnetStatus,
  #page-exchange #binanceStatus{
    min-height:292px !important;
    height:292px !important;
    max-height:292px !important;
  }

  #page-exchange #binanceTestnetStatus .bot-meta,
  #page-exchange #binanceStatus .bot-meta{
    grid-template-columns:1fr !important;
  }

  #page-exchange #binanceTestnetStatus .binance-status-warning,
  #page-exchange #binanceStatus .binance-status-warning{
    min-height:84px !important;
    max-height:96px !important;
  }
}

/* STT STEP63.6ZI — Safe Exchange Hub compression after rollback
   Only reduces vertical gaps/heights. Does NOT change grid columns/layout.
*/
@media (min-width: 901px){

  /* Main card spacing */
  #page-exchange .compact-page-grid{
    gap:14px !important;
  }

  #page-exchange .compact-page-grid > .card{
    padding:16px !important;
    border-radius:20px !important;
  }

  #page-exchange .card-header{
    margin-bottom:10px !important;
  }

  #page-exchange .card-title,
  #page-exchange .card h3,
  #page-exchange .card-header h3{
    font-size:20px !important;
    line-height:1.15 !important;
  }

  /* Supported Exchanges: keep existing 3-column layout, just compact tile height */
  #page-exchange .exchange-grid{
    gap:10px !important;
  }

  #page-exchange .exchange-card,
  #page-exchange .coming-card{
    min-height:145px !important;
    padding:11px 10px !important;
    border-radius:18px !important;
  }

  #page-exchange .exchange-logo-wrap{
    height:56px !important;
    min-height:56px !important;
    padding:8px !important;
    margin-bottom:7px !important;
    border-radius:15px !important;
  }

  #page-exchange .exchange-logo-wrap img{
    max-height:38px !important;
    max-width:80px !important;
  }

  #page-exchange .exchange-card b,
  #page-exchange .coming-card b,
  #page-exchange .ex-name{
    font-size:16px !important;
    line-height:1.12 !important;
    margin:2px 0 4px !important;
  }

  #page-exchange .exchange-note,
  #page-exchange .coming-card small{
    font-size:10.5px !important;
    line-height:1.2 !important;
  }

  #page-exchange .exchange-card .pill,
  #page-exchange .coming-card .pill{
    font-size:10.5px !important;
    padding:4px 8px !important;
  }

  #page-exchange .add-exchange{
    min-height:40px !important;
    height:40px !important;
    padding:8px 10px !important;
    margin-top:10px !important;
    border-radius:14px !important;
  }

  /* API card top warning */
  #page-exchange .warning-box{
    padding:10px 12px !important;
    margin-bottom:9px !important;
    border-radius:15px !important;
    font-size:12px !important;
    line-height:1.34 !important;
  }

  /* API type toggle */
  #page-exchange .stt-api-mode-toggle{
    min-height:74px !important;
    padding:8px 10px !important;
    margin:8px 0 9px !important;
    border-radius:15px !important;
  }

  #page-exchange .stt-api-mode-title{
    font-size:11px !important;
    margin-bottom:5px !important;
    line-height:1.1 !important;
  }

  #page-exchange .stt-api-mode-buttons{
    gap:7px !important;
  }

  #page-exchange .stt-api-mode-buttons button{
    min-height:32px !important;
    height:32px !important;
    padding:6px 9px !important;
    font-size:11.5px !important;
  }

  #page-exchange .stt-api-mode-note{
    margin-top:5px !important;
    font-size:10px !important;
    line-height:1.22 !important;
  }

  /* Inputs/buttons */
  #page-exchange input,
  #page-exchange .form input{
    min-height:38px !important;
    height:38px !important;
    padding:7px 12px !important;
    margin-bottom:6px !important;
    border-radius:13px !important;
    font-size:12.5px !important;
  }

  #page-exchange .primary-btn,
  #page-exchange button.primary-btn,
  #page-exchange .form button:not(.stt-api-mode-buttons button),
  #page-exchange .card > button{
    min-height:38px !important;
    height:38px !important;
    padding:7px 12px !important;
    margin-top:6px !important;
    border-radius:13px !important;
    font-size:12.5px !important;
  }

  /* API status boxes: stable height, compact content */
  #page-exchange #binanceTestnetStatus,
  #page-exchange #binanceStatus{
    min-height:220px !important;
    height:220px !important;
    max-height:220px !important;
    padding:11px !important;
    margin-top:9px !important;
    border-radius:16px !important;
    overflow:hidden !important;
  }

  #page-exchange #binanceTestnetStatus > div:first-child,
  #page-exchange #binanceStatus > div:first-child,
  #page-exchange #binanceTestnetStatus .stt-status-stable-head,
  #page-exchange #binanceStatus .stt-status-stable-head{
    min-height:36px !important;
    margin-bottom:6px !important;
  }

  #page-exchange #binanceTestnetStatus b,
  #page-exchange #binanceStatus b{
    font-size:14px !important;
    line-height:1.15 !important;
  }

  #page-exchange #binanceTestnetStatus .mini-muted,
  #page-exchange #binanceStatus .mini-muted{
    font-size:10px !important;
    line-height:1.2 !important;
  }

  #page-exchange #binanceTestnetStatus .bot-meta,
  #page-exchange #binanceStatus .bot-meta{
    gap:6px !important;
    margin-top:6px !important;
    margin-bottom:6px !important;
  }

  #page-exchange #binanceTestnetStatus .meta-box,
  #page-exchange #binanceStatus .meta-box{
    min-height:50px !important;
    padding:7px 8px !important;
    border-radius:12px !important;
  }

  #page-exchange #binanceTestnetStatus .meta-label,
  #page-exchange #binanceStatus .meta-label{
    font-size:9px !important;
    margin-bottom:2px !important;
  }

  #page-exchange #binanceTestnetStatus .meta-value,
  #page-exchange #binanceStatus .meta-value{
    font-size:12px !important;
    line-height:1.15 !important;
  }

  #page-exchange #binanceTestnetStatus .binance-status-warning,
  #page-exchange #binanceStatus .binance-status-warning,
  #page-exchange #binanceTestnetStatus .stt-status-stable-warning,
  #page-exchange #binanceStatus .stt-status-stable-warning{
    min-height:56px !important;
    max-height:64px !important;
    padding:7px 9px !important;
    margin-top:6px !important;
    border-radius:12px !important;
    font-size:10.5px !important;
    line-height:1.23 !important;
    overflow:hidden !important;
  }

  /* Balance boxes: stable and smaller */
  #page-exchange #binanceTestnetBalanceBox,
  #page-exchange #binanceBalanceBox{
    min-height:190px !important;
    padding:11px !important;
    margin-top:9px !important;
    border-radius:16px !important;
  }

  #page-exchange .balance-head{
    min-height:36px !important;
    margin-bottom:7px !important;
  }

  #page-exchange .balance-head b{
    font-size:14px !important;
  }

  #page-exchange .balance-head .mini-muted{
    font-size:10px !important;
    line-height:1.18 !important;
  }

  #page-exchange .balance-grid{
    gap:6px !important;
    min-height:70px !important;
  }

  #page-exchange .balance-asset-card{
    min-height:66px !important;
    padding:7px !important;
    border-radius:12px !important;
  }

  #page-exchange .balance-asset{
    font-size:9.5px !important;
  }

  #page-exchange .balance-total{
    font-size:14px !important;
    margin:3px 0 !important;
  }

  #page-exchange .balance-asset-card small{
    font-size:9px !important;
    line-height:1.15 !important;
  }

  #page-exchange .pill{
    font-size:10px !important;
    padding:4px 8px !important;
  }
}

/* STT STEP63.6ZL — Signal Center 4-card balance monitor */
.signal-balance-grid.stt-signal-balance-4grid{
  display:grid !important;
  grid-template-columns:repeat(4, minmax(0, 1fr)) !important;
  gap:10px !important;
}

.signal-balance-grid.stt-signal-balance-4grid .signal-balance-card{
  min-height:92px !important;
  padding:13px 14px !important;
  border-radius:15px !important;
}

.signal-balance-grid.stt-signal-balance-4grid .signal-balance-card b{
  font-size:13px !important;
  line-height:1.15 !important;
}

.signal-balance-grid.stt-signal-balance-4grid .signal-balance-card span{
  font-size:19px !important;
  line-height:1.1 !important;
  margin-top:8px !important;
}

.signal-balance-grid.stt-signal-balance-4grid .signal-balance-card small{
  font-size:11px !important;
  line-height:1.25 !important;
  margin-top:7px !important;
}

.signal-balance-grid.stt-signal-balance-4grid .stt-signal-balance-ok span{
  color:#22c55e !important;
  font-weight:900 !important;
}

.signal-balance-grid.stt-signal-balance-4grid .warning-card span{
  color:#fbbf24 !important;
  font-weight:900 !important;
}

.signal-balance-grid.stt-signal-balance-4grid .muted-card span{
  color:#94a3b8 !important;
  font-weight:900 !important;
}

@media(max-width:1100px){
  .signal-balance-grid.stt-signal-balance-4grid{
    grid-template-columns:repeat(2, minmax(0, 1fr)) !important;
  }
}

@media(max-width:680px){
  .signal-balance-grid.stt-signal-balance-4grid{
    grid-template-columns:1fr !important;
  }
}

/* STT STEP63.6ZM — Final Signal Center 4-card balance CSS */
.signal-balance-grid.stt-signal-balance-4grid{
  display:grid !important;
  grid-template-columns:repeat(4, minmax(0, 1fr)) !important;
  gap:10px !important;
}
.signal-balance-grid.stt-signal-balance-4grid .signal-balance-card{
  min-height:92px !important;
  padding:13px 14px !important;
  border-radius:15px !important;
}
.signal-balance-grid.stt-signal-balance-4grid .signal-balance-card b{
  font-size:13px !important;
  line-height:1.15 !important;
}
.signal-balance-grid.stt-signal-balance-4grid .signal-balance-card span{
  font-size:19px !important;
  line-height:1.1 !important;
  margin-top:8px !important;
}
.signal-balance-grid.stt-signal-balance-4grid .signal-balance-card small{
  font-size:11px !important;
  line-height:1.25 !important;
  margin-top:7px !important;
}
.signal-balance-grid.stt-signal-balance-4grid .stt-signal-balance-ok span{
  color:#22c55e !important;
  font-weight:900 !important;
}
.signal-balance-grid.stt-signal-balance-4grid .warning-card span{
  color:#fbbf24 !important;
  font-weight:900 !important;
}
.signal-balance-grid.stt-signal-balance-4grid .muted-card span{
  color:#94a3b8 !important;
  font-weight:900 !important;
}
@media(max-width:1100px){
  .signal-balance-grid.stt-signal-balance-4grid{
    grid-template-columns:repeat(2, minmax(0, 1fr)) !important;
  }
}
@media(max-width:680px){
  .signal-balance-grid.stt-signal-balance-4grid{
    grid-template-columns:1fr !important;
  }
}

/* STT STEP63.6ZN — Signal Center silent balance refresh polish */
.signal-balance-grid.stt-signal-balance-4grid{
  min-height:92px !important;
}

.signal-balance-grid.stt-signal-balance-4grid .signal-balance-card{
  transition:background .18s ease, border-color .18s ease, transform .18s ease !important;
}


/* STT STEP63.7B EXECUTION MODE SELECTOR CSS */
.stt-manual-execution-box {
  border: 1px solid rgba(59, 130, 246, 0.26);
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.92), rgba(2, 6, 23, 0.88));
  border-radius: 16px;
  padding: 12px;
  margin: 12px 0;
  box-shadow: 0 14px 30px rgba(2, 6, 23, 0.28);
}

.stt-manual-execution-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.stt-manual-execution-row label {
  display: block;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #dbeafe;
}

.stt-manual-execution-row small {
  display: block;
  margin-top: 4px;
  color: #8ea4c8;
  font-size: 11px;
}

#sttManualExecutionMode {
  min-width: 170px;
  height: 38px;
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.28);
  background: rgba(2, 6, 23, 0.86);
  color: #e5eefc;
  padding: 0 10px;
  outline: none;
  font-weight: 800;
}

#sttManualExecutionMode:focus {
  border-color: rgba(59, 130, 246, 0.72);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.16);
}

.stt-manual-execution-warning {
  margin-top: 10px;
  font-size: 11px;
  line-height: 1.45;
  color: #93a4bf;
  border-top: 1px solid rgba(148, 163, 184, 0.12);
  padding-top: 9px;
}

.stt-manual-execution-warning.testnet {
  color: #fde68a;
}

@media (max-width: 700px) {
  .stt-manual-execution-row {
    align-items: stretch;
    flex-direction: column;
  }

  #sttManualExecutionMode {
    width: 100%;
    min-width: 0;
  }

  .stt-manual-execution-box {
    padding: 10px;
    margin: 10px 0;
  }
}



/* STT STEP63.7D COMPACT MODAL OVERRIDE CSS */
.stt-manual-execution-box {
  padding: 8px 10px;
  margin: 8px 0 10px;
  border-radius: 12px;
}

.stt-manual-execution-row {
  gap: 8px;
  align-items: center;
}

.stt-manual-execution-row label {
  font-size: 11px;
  letter-spacing: .06em;
}

.stt-manual-execution-row small {
  margin-top: 2px;
  font-size: 10px;
  line-height: 1.25;
  max-width: 180px;
}

#sttManualExecutionMode {
  min-width: 150px;
  height: 34px;
  border-radius: 10px;
  padding: 0 8px;
  font-size: 13px;
}

.stt-manual-execution-warning {
  margin-top: 6px;
  padding-top: 0;
  border-top: none;
  font-size: 10px;
  line-height: 1.25;
}

#sttManualOpenTradeOverlay .stt-manual-open-note {
  font-size: 10px;
  line-height: 1.3;
  margin-top: 6px;
}

@media (max-width: 700px) {
  .stt-manual-execution-box {
    padding: 7px 8px;
    margin: 7px 0 8px;
  }

  .stt-manual-execution-row {
    gap: 6px;
  }

  .stt-manual-execution-row label {
    font-size: 10.5px;
  }

  .stt-manual-execution-row small,
  .stt-manual-execution-warning,
  #sttManualOpenTradeOverlay .stt-manual-open-note {
    font-size: 9.5px;
    line-height: 1.2;
  }

  #sttManualExecutionMode {
    height: 32px;
    font-size: 12px;
  }
}


/* STT STEP63.8B LABEL POLISH CSS */
.stt638-trade-mode-label,
.trade-mode.stt638-trade-mode-label,
.trade-mode-pill.stt638-trade-mode-label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  max-width: 160px;
  white-space: nowrap;
  font-size: 10.5px;
  font-weight: 900;
  letter-spacing: .2px;
  line-height: 1.1;
  padding: 5px 8px;
  border-radius: 999px;
}

.stt638-label-testnet {
  border: 1px solid rgba(56,189,248,.42);
  box-shadow: 0 0 12px rgba(56,189,248,.12);
}

.stt638-label-paper {
  border: 1px solid rgba(148,163,184,.34);
  box-shadow: 0 0 10px rgba(148,163,184,.10);
}

.stt638-label-live {
  border: 1px solid rgba(251,146,60,.44);
  box-shadow: 0 0 12px rgba(251,146,60,.12);
}

@media (max-width: 700px) {
  .stt638-trade-mode-label,
  .trade-mode.stt638-trade-mode-label,
  .trade-mode-pill.stt638-trade-mode-label {
    max-width: 132px;
    font-size: 9.5px;
    padding: 4px 7px;
  }
}


/* STT STEP63.9A API INPUT HIDE CSS */
.stt639-api-credential-hidden {
  -webkit-text-security: disc;
  opacity: .72;
  pointer-events: none;
  user-select: none;
  border-style: dashed !important;
}

.stt639-api-hidden-note {
  margin: 10px 0 12px;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(34,211,238,.24);
  background: rgba(15,23,42,.54);
  color: rgba(226,232,240,.92);
  font-size: 12px;
  line-height: 1.35;
}

.stt639-api-hidden-note b {
  color: #67e8f9;
}


/* STT STEP63.9B LIVE SAFETY CHECKLIST CSS */
.stt639-safety-card {
  padding: 14px;
  border-radius: 18px;
  border: 1px solid rgba(34,211,238,.18);
  background: rgba(15,23,42,.55);
}

.stt639-safety-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.stt639-safety-head b {
  color: rgba(241,245,249,.96);
}

.stt639-safety-head small,
.stt639-safety-row small,
.stt639-safety-foot {
  display: block;
  color: rgba(148,163,184,.92);
  font-size: 12px;
  line-height: 1.35;
}

.stt639-safety-list {
  display: grid;
  gap: 8px;
}

.stt639-safety-row {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 9px 10px;
  border-radius: 14px;
  border: 1px solid rgba(148,163,184,.16);
  background: rgba(2,6,23,.24);
}

.stt639-safety-row.ok {
  border-color: rgba(34,197,94,.25);
}

.stt639-safety-row.warn {
  border-color: rgba(251,191,36,.28);
}

.stt639-safety-dot {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 22px;
  font-size: 13px;
  font-weight: 900;
  color: white;
  background: rgba(34,197,94,.72);
}

.stt639-safety-row.warn .stt639-safety-dot {
  background: rgba(245,158,11,.82);
}

.stt639-safety-foot {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid rgba(148,163,184,.12);
}


/* STT STEP63.9D COMPACT EXCHANGE API UI */
#page-exchange .stt-api-mode-toggle {
  padding: 8px 10px !important;
  margin: 8px 0 10px !important;
  border-radius: 14px !important;
}

#page-exchange .stt-api-mode-title {
  font-size: 11px !important;
  margin-bottom: 5px !important;
}

#page-exchange .stt-api-mode-buttons {
  gap: 6px !important;
}

#page-exchange .stt-api-mode-buttons button {
  min-height: 32px !important;
  padding: 7px 10px !important;
  font-size: 12px !important;
  border-radius: 12px !important;
}

#page-exchange .stt-api-mode-note,
#page-exchange .mini-muted {
  font-size: 11px !important;
  line-height: 1.25 !important;
}

/* Once API is saved, credential inputs should not consume card height. */
#page-exchange input.stt639-api-credential-hidden {
  display: none !important;
  height: 0 !important;
  min-height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
}

#page-exchange .stt639-api-hidden-note {
  margin: 6px 0 8px !important;
  padding: 8px 10px !important;
  border-radius: 12px !important;
  font-size: 11px !important;
  line-height: 1.25 !important;
}

/* Compact Exchange API action buttons. */
#page-exchange button[onclick*="saveBinance"],
#page-exchange button[onclick*="testBinance"],
#page-exchange button[onclick*="loadBinance"],
#page-exchange button[onclick*="deleteBinance"] {
  min-height: 36px !important;
  padding: 8px 12px !important;
  margin-top: 8px !important;
  margin-bottom: 0 !important;
  border-radius: 13px !important;
  font-size: 12px !important;
}

/* Compact status/balance panels inside API cards. */
#page-exchange .bot-meta {
  gap: 7px !important;
  margin: 8px 0 !important;
}

#page-exchange .meta-box {
  padding: 8px 9px !important;
  border-radius: 12px !important;
  min-height: 48px !important;
}

#page-exchange .meta-label {
  font-size: 10px !important;
  margin-bottom: 2px !important;
}

#page-exchange .meta-value {
  font-size: 12px !important;
  line-height: 1.15 !important;
}

#page-exchange .warning-box.binance-status-warning {
  margin-top: 8px !important;
  padding: 9px 11px !important;
  border-radius: 12px !important;
  font-size: 11px !important;
  line-height: 1.25 !important;
}

/* Compact live safety checklist. */
#page-exchange .stt639-safety-card {
  padding: 10px 12px !important;
  border-radius: 15px !important;
}

#page-exchange .stt639-safety-head {
  margin-bottom: 8px !important;
  gap: 8px !important;
}

#page-exchange .stt639-safety-head b {
  font-size: 13px !important;
}

#page-exchange .stt639-safety-head small,
#page-exchange .stt639-safety-row small,
#page-exchange .stt639-safety-foot {
  font-size: 10.5px !important;
  line-height: 1.2 !important;
}

#page-exchange .stt639-safety-list {
  gap: 6px !important;
}

#page-exchange .stt639-safety-row {
  padding: 7px 9px !important;
  gap: 8px !important;
  border-radius: 12px !important;
  min-height: 42px !important;
}

#page-exchange .stt639-safety-row b {
  font-size: 12px !important;
  line-height: 1.15 !important;
}

#page-exchange .stt639-safety-dot {
  width: 18px !important;
  height: 18px !important;
  flex-basis: 18px !important;
  font-size: 11px !important;
}

#page-exchange .stt639-safety-foot {
  margin-top: 8px !important;
  padding-top: 7px !important;
}

/* Compact balance cards */
#page-exchange .balance-head {
  margin-bottom: 8px !important;
}

#page-exchange .balance-grid {
  gap: 7px !important;
}

#page-exchange .balance-asset-card {
  padding: 8px 9px !important;
  border-radius: 12px !important;
  min-height: 62px !important;
}

#page-exchange .balance-asset {
  font-size: 10px !important;
}

#page-exchange .balance-total {
  font-size: 14px !important;
  line-height: 1.15 !important;
}

#page-exchange .balance-asset-card small {
  font-size: 10px !important;
  line-height: 1.15 !important;
}

@media (min-width: 901px) {
  #page-exchange .exchange-card,
  #page-exchange .settings-card,
  #page-exchange .glass-card {
    padding-top: 14px !important;
    padding-bottom: 14px !important;
  }
}

@media (max-width: 700px) {
  #page-exchange .stt639-safety-row {
    min-height: 38px !important;
  }

  #page-exchange button[onclick*="saveBinance"],
  #page-exchange button[onclick*="testBinance"],
  #page-exchange button[onclick*="loadBinance"],
  #page-exchange button[onclick*="deleteBinance"] {
    min-height: 34px !important;
    font-size: 11px !important;
  }
}


/* STT STEP64.2A LIVE LIVE UI CSS */
#sttManualExecutionMode option[value="spot_live"],
#sttManualExecutionMode option[value="futures_live"] {
  font-weight: 900;
}

.stt-live-live-warning {
  border-color: rgba(248,113,113,.36) !important;
  box-shadow: 0 0 16px rgba(248,113,113,.16) !important;
}



/* removed STEP64.4E noisy UI CSS */


/* STT STEP65.1 PROFESSIONAL LIVE CSS */
#sttManualExecutionMode option[value="spot_live"],
#sttManualExecutionMode option[value="futures_live"] {
  font-weight: 900;
}


/* STT STEP65.5 COMPACT LIVE FORM CSS */
.stt65-live-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 10px;
  margin: 10px 0 8px;
  align-items: end;
}

.stt65-live-field {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.stt65-live-field label {
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .02em;
  color: rgba(226, 232, 240, .92);
}

.stt65-live-field select,
.stt65-live-field input,
#stt65LiveOrderControls select,
#stt65LiveOrderControls input,
#sttManualLimitPriceWrap input {
  width: 100%;
  height: 38px;
  border-radius: 11px;
  border: 1px solid rgba(34, 211, 238, .22);
  background: rgba(15, 23, 42, .92);
  color: #f8fafc;
  padding: 0 11px;
  font-weight: 800;
  outline: none;
  box-shadow: inset 0 0 0 1px rgba(148, 163, 184, .05);
}

#sttManualLimitPriceWrap {
  margin-top: 8px;
}

#sttManualLimitPriceWrap label {
  font-size: 11px;
  font-weight: 900;
  color: rgba(226, 232, 240, .92);
}

@media (max-width: 700px) {
  .stt65-live-row {
    grid-template-columns: 1fr;
    gap: 8px;
  }
}


/* STT STEP65.6 FINAL COMPACT LIVE FORM CSS */
#stt65SpotLiveControls.stt65-live-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 8px;
  margin: 8px 0 8px;
  align-items: end;
}

.stt65-live-field,
#stt65FuturesLimitInline {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.stt65-live-field label,
#stt65FuturesLimitInline label {
  font-size: 10.5px;
  font-weight: 900;
  line-height: 1;
  color: rgba(226, 232, 240, .9);
}

#stt65SpotLiveControls select,
#stt65SpotLiveControls input,
#stt65FuturesLimitInline input,
#sttManualLimitPrice {
  width: 100%;
  height: 34px;
  border-radius: 10px;
  border: 1px solid rgba(34, 211, 238, .24);
  background: rgba(15, 23, 42, .95);
  color: #f8fafc;
  padding: 0 9px;
  font-size: 12px;
  font-weight: 850;
  outline: none;
  color-scheme: dark;
  appearance: none;
  -webkit-appearance: none;
  box-shadow: inset 0 0 0 1px rgba(148, 163, 184, .06);
}

#sttManualLimitPrice::placeholder {
  color: rgba(203, 213, 225, .68);
  font-size: 11px;
  font-weight: 800;
}

#stt65FuturesLimitInline {
  margin-top: 0;
}

@media (max-width: 700px) {
  #stt65SpotLiveControls.stt65-live-row {
    grid-template-columns: 1fr;
    gap: 7px;
  }
}


/* STT STEP65.7 NO-HANG LIVE FORM CSS */
#stt65SpotLiveControls.stt65-live-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 8px;
  margin: 8px 0 8px;
  align-items: end;
}

.stt65-live-field,
#stt65FuturesLimitInline {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.stt65-live-field label,
#stt65FuturesLimitInline label {
  font-size: 10.5px;
  font-weight: 900;
  line-height: 1;
  color: rgba(226, 232, 240, .9);
}

#stt65SpotLiveControls select,
#stt65SpotLiveControls input,
#stt65FuturesLimitInline input,
#sttManualLimitPrice {
  width: 100%;
  height: 34px;
  border-radius: 10px;
  border: 1px solid rgba(34, 211, 238, .24);
  background: rgba(15, 23, 42, .95);
  color: #f8fafc;
  padding: 0 9px;
  font-size: 12px;
  font-weight: 850;
  outline: none;
  color-scheme: dark;
  box-shadow: inset 0 0 0 1px rgba(148, 163, 184, .06);
}

#sttManualLimitPrice::placeholder {
  color: rgba(203, 213, 225, .68);
  font-size: 11px;
  font-weight: 800;
}


/* STT STEP65.8 STABLE MANUAL FORM CSS */
#stt65SpotOrderRow.stt65-order-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 8px;
  margin: 8px 0 8px;
  align-items: end;
}

.stt65-order-field,
#stt65FuturesLimitBox {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.stt65-order-field label,
#stt65FuturesLimitBox label {
  font-size: 10.5px;
  font-weight: 900;
  line-height: 1;
  color: rgba(226, 232, 240, .9);
}

#stt65SpotOrderRow select,
#stt65SpotOrderRow input,
#stt65FuturesLimitBox input,
#sttManualLimitPrice {
  width: 100%;
  height: 34px;
  border-radius: 10px;
  border: 1px solid rgba(34, 211, 238, .24);
  background: rgba(15, 23, 42, .95);
  color: #f8fafc;
  padding: 0 9px;
  font-size: 12px;
  font-weight: 850;
  outline: none;
  color-scheme: dark;
  box-shadow: inset 0 0 0 1px rgba(148, 163, 184, .06);
}

#sttManualLimitPrice::placeholder {
  color: rgba(203, 213, 225, .68);
  font-size: 11px;
  font-weight: 800;
}


/* STT STEP65.9 FINAL MODAL CSS */
#stt65SpotOrderRow.stt65-order-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 8px;
  margin: 8px 0 8px;
  align-items: end;
}

.stt65-order-field,
#stt65FuturesLimitBox {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.stt65-order-field label,
#stt65FuturesLimitBox label {
  font-size: 10.5px;
  font-weight: 900;
  line-height: 1;
  color: rgba(226, 232, 240, .9);
}

#stt65SpotOrderRow select,
#stt65SpotOrderRow input,
#stt65FuturesLimitBox input,
#sttManualLimitPrice {
  width: 100%;
  height: 34px;
  border-radius: 10px;
  border: 1px solid rgba(34, 211, 238, .24);
  background: rgba(15, 23, 42, .95);
  color: #f8fafc;
  padding: 0 9px;
  font-size: 12px;
  font-weight: 850;
  outline: none;
  color-scheme: dark;
  box-shadow: inset 0 0 0 1px rgba(148, 163, 184, .06);
}

#sttManualLimitPrice::placeholder {
  color: rgba(203, 213, 225, .68);
  font-size: 11px;
  font-weight: 800;
}


/* STT STEP65.10 STABLE FORM LOCK CSS */
#stt65SpotOrderRow.stt65-order-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 8px;
  margin: 8px 0 8px;
  align-items: end;
}

.stt65-order-field,
#stt65FuturesLimitBox {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.stt65-order-field label,
#stt65FuturesLimitBox label {
  font-size: 10.5px;
  font-weight: 900;
  line-height: 1;
  color: rgba(226, 232, 240, .9);
}

#stt65SpotOrderRow select,
#stt65SpotOrderRow input,
#stt65FuturesLimitBox input,
#sttManualLimitPrice {
  width: 100%;
  height: 34px;
  border-radius: 10px;
  border: 1px solid rgba(34, 211, 238, .24);
  background: rgba(15, 23, 42, .95);
  color: #f8fafc;
  padding: 0 9px;
  font-size: 12px;
  font-weight: 850;
  outline: none;
  color-scheme: dark;
  box-shadow: inset 0 0 0 1px rgba(148, 163, 184, .06);
}

#sttManualLimitPrice::placeholder {
  color: rgba(203, 213, 225, .68);
  font-size: 11px;
  font-weight: 800;
}


/* STT STEP65.11 ROOT MODAL CSS */
#stt65SpotOrderRow.stt65-order-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 8px;
  margin: 8px 0 8px;
  align-items: end;
}

.stt65-order-field,
#stt65FuturesLimitBox {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.stt65-order-field label,
#stt65FuturesLimitBox label {
  font-size: 10.5px;
  font-weight: 900;
  line-height: 1;
  color: rgba(226, 232, 240, .9);
}

#stt65SpotOrderRow select,
#stt65SpotOrderRow input,
#stt65FuturesLimitBox input,
#sttManualLimitPrice {
  width: 100%;
  height: 34px;
  border-radius: 10px;
  border: 1px solid rgba(34, 211, 238, .24);
  background: rgba(15, 23, 42, .95);
  color: #f8fafc;
  padding: 0 9px;
  font-size: 12px;
  font-weight: 850;
  outline: none;
  color-scheme: dark;
  box-shadow: inset 0 0 0 1px rgba(148, 163, 184, .06);
}

#sttManualLimitPrice::placeholder {
  color: rgba(203, 213, 225, .68);
  font-size: 11px;
  font-weight: 800;
}


/* STT STEP65.12 ORIGINAL MODAL CSS */
#stt65SpotOrderRow.stt65-order-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 8px;
  margin: 8px 0 8px;
  align-items: end;
}

.stt65-order-field,
#stt65FuturesLimitBox {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.stt65-order-field label,
#stt65FuturesLimitBox label {
  font-size: 10.5px;
  font-weight: 900;
  line-height: 1;
  color: rgba(226, 232, 240, .9);
}

#stt65SpotOrderRow select,
#stt65SpotOrderRow input,
#stt65FuturesLimitBox input,
#sttManualLimitPrice {
  width: 100%;
  height: 34px;
  border-radius: 10px;
  border: 1px solid rgba(34, 211, 238, .24);
  background: rgba(15, 23, 42, .95);
  color: #f8fafc;
  padding: 0 9px;
  font-size: 12px;
  font-weight: 850;
  outline: none;
  color-scheme: dark;
  box-shadow: inset 0 0 0 1px rgba(148, 163, 184, .06);
}

#sttManualLimitPrice::placeholder {
  color: rgba(203, 213, 225, .68);
  font-size: 11px;
  font-weight: 800;
}


/* STT STEP65.13 STRICT MODAL CSS */
#sttManualLimitPrice:disabled {
  opacity: .55;
}



/* removed modal jump css block: STT STEP65.14 HARD LOCK CSS */


/* removed modal jump css block: STT STEP65.15 MODAL STABLE CSS */


/* removed modal jump css block: STT STEP65.15H COMPACT STABLE ROWS */


/* STT STEP65.15I COMPACT NO-JUMP CSS */
/* No intervals, no fixed giant height. Only compact stable inner rows. */

#sttManualOpenTradeOverlay,
.stt-manual-open-overlay {
  align-items: flex-start !important;
  justify-content: center !important;
  padding-top: clamp(72px, 9vh, 96px) !important;
  box-sizing: border-box !important;
}

#sttManualOpenTradeOverlay > *,
#sttManualOpenTradeOverlay .stt-manual-open-card,
#sttManualOpenTradeOverlay .stt-modal-card,
#sttManualOpenTradeOverlay .modal-card,
.stt6515i-card {
  transform: none !important;
  transition: none !important;
  will-change: auto !important;
  max-height: calc(100vh - 90px) !important;
  overflow-y: auto !important;
}

/* Compact boxes only */
#sttManualOpenTradeOverlay input:not([type="range"]),
#sttManualOpenTradeOverlay select {
  height: 32px !important;
  min-height: 32px !important;
  box-sizing: border-box !important;
  font-size: 12px !important;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
}

#sttManualOpenTradeOverlay input[type="range"] {
  height: 18px !important;
  min-height: 18px !important;
}

#sttManualOpenTradeOverlay label {
  min-height: 12px !important;
  line-height: 12px !important;
  font-size: 11px !important;
  margin-bottom: 3px !important;
}

/* SL/TP inputs stay compact and stable */
#sttManualOpenTradeOverlay input[placeholder*="Stop"],
#sttManualOpenTradeOverlay input[placeholder*="Take"] {
  height: 32px !important;
  min-height: 32px !important;
  line-height: 32px !important;
}

#sttManualExecutionWarning,
#sttManualOpenTradeOverlay .stt-manual-open-note {
  min-height: 20px !important;
  max-height: 20px !important;
  line-height: 1.15 !important;
  overflow: hidden !important;
  margin-top: 5px !important;
  margin-bottom: 5px !important;
}

#sttManualOpenBalancePill {
  min-width: 132px !important;
  max-width: 132px !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  text-align: center !important;
}

#sttManualOpenTradeOverlay button {
  height: 40px !important;
  min-height: 40px !important;
  transition: none !important;
}



/* removed duplicate spot row css block: STT STEP65.15J SPOT ORDER ROW RESTORE CSS */


/* STT STEP65.15L SINGLE SPOT ORDER ROW CSS */
/* Keep only original spot order row and prevent bottom extend. */

#stt6515kSpotRow,
#stt65HardSpotRow {
  display: none !important;
}

#stt65SpotOrderRow {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 8px;
  margin: 5px 0 5px !important;
  min-height: 44px !important;
  max-height: 44px !important;
  overflow: visible !important;
}

#stt65SpotOrderRow label {
  font-size: 11px !important;
  line-height: 12px !important;
  min-height: 12px !important;
  margin-bottom: 3px !important;
}

#stt65SpotOrderRow select,
#stt65SpotOrderRow input {
  height: 32px !important;
  min-height: 32px !important;
  font-size: 12px !important;
  border-radius: 10px !important;
  box-sizing: border-box !important;
}

#sttManualOpenTradeOverlay .stt-manual-open-note {
  min-height: 22px !important;
  max-height: 22px !important;
  overflow: hidden !important;
  line-height: 1.2 !important;
  margin-top: 5px !important;
  margin-bottom: 5px !important;
}

#sttManualOpenTradeOverlay .stt-manual-open-card,
#sttManualOpenTradeOverlay .stt-modal-card,
#sttManualOpenTradeOverlay .modal-card,
#sttManualOpenTradeOverlay > div {
  padding-bottom: 20px !important;
  overflow-y: auto !important;
}


/* STT STEP65.15M FINAL SINGLE SPOT ROW CSS */
#stt65SpotOrderRow,
#stt65HardSpotRow,
#stt6515kSpotRow,
#sttManualOrderTypeLiveWrap,
#stt65SpotLiveControls {
  display: none !important;
}

#stt6515mSpotRow.stt6515m-spot-row {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 8px;
  margin: 5px 0 5px !important;
  min-height: 44px !important;
  max-height: 44px !important;
  overflow: visible !important;
}

.stt6515m-field {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.stt6515m-field label {
  font-size: 11px;
  font-weight: 900;
  line-height: 12px;
  min-height: 12px;
}

#stt6515mSpotOrderType,
#stt6515mSpotLimitPrice {
  height: 32px !important;
  min-height: 32px !important;
  border-radius: 10px;
  font-size: 12px;
  box-sizing: border-box;
  width: 100%;
}

#sttManualOpenTradeOverlay .stt-manual-open-note {
  min-height: 24px !important;
  max-height: 24px !important;
  overflow: hidden !important;
  line-height: 1.2 !important;
}

#sttManualOpenTradeOverlay .stt-manual-open-card,
#sttManualOpenTradeOverlay .stt-modal-card,
#sttManualOpenTradeOverlay .modal-card,
#sttManualOpenTradeOverlay > div {
  padding-bottom: 24px !important;
  overflow-y: auto !important;
}


/* STT STEP65.15N SPOT UI POLISH CSS */
/* Professional dark Order Type + proper spacing + stable Paper/Live note area. */

#stt6515mSpotRow.stt6515m-spot-row {
  margin-top: 8px !important;
  margin-bottom: 10px !important;
  min-height: 48px !important;
  max-height: 48px !important;
  align-items: end !important;
}

#stt6515mSpotRow .stt6515m-field {
  gap: 5px !important;
}

#stt6515mSpotRow .stt6515m-field label {
  color: rgba(226, 232, 240, .92) !important;
  font-size: 11px !important;
  font-weight: 900 !important;
  line-height: 12px !important;
  min-height: 12px !important;
  letter-spacing: .01em !important;
}

#stt6515mSpotOrderType,
#stt6515mSpotLimitPrice {
  width: 100% !important;
  height: 34px !important;
  min-height: 34px !important;
  border-radius: 10px !important;
  border: 1px solid rgba(34, 211, 238, .28) !important;
  background: rgba(15, 23, 42, .96) !important;
  color: #f8fafc !important;
  color-scheme: dark !important;
  font-size: 12px !important;
  font-weight: 850 !important;
  padding: 0 10px !important;
  outline: none !important;
  box-shadow:
    inset 0 0 0 1px rgba(148, 163, 184, .06),
    0 0 0 1px rgba(15, 23, 42, .25) !important;
  appearance: auto !important;
}

#stt6515mSpotOrderType option {
  background: #111827 !important;
  color: #f8fafc !important;
}

#stt6515mSpotOrderType:focus,
#stt6515mSpotLimitPrice:focus {
  border-color: rgba(34, 211, 238, .65) !important;
  box-shadow:
    0 0 0 1px rgba(34, 211, 238, .22),
    0 0 12px rgba(34, 211, 238, .10) !important;
}

#sttManualOpenTradeOverlay label:has(+ #stt6515mSpotOrderType),
#sttManualOpenTradeOverlay label:has(+ #stt6515mSpotLimitPrice) {
  margin-bottom: 5px !important;
}

#sttManualOpenTradeOverlay input[placeholder*="Stop"],
#sttManualOpenTradeOverlay input[placeholder*="Take"] {
  margin-top: 2px !important;
}

#sttManualOpenTradeOverlay .stt-manual-open-note {
  min-height: 24px !important;
  max-height: 24px !important;
  overflow: hidden !important;
  line-height: 1.2 !important;
  margin-top: 7px !important;
  margin-bottom: 7px !important;
}


/* STT STEP65.15O SPOT BALANCE + EXEC BOX CSS */
#sttManualOpenBalancePill {
  min-width: 154px !important;
  max-width: 154px !important;
  width: 154px !important;
  text-align: center !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}

#sttManualExecutionBox,
.stt-manual-execution-box {
  min-height: 70px !important;
  padding-bottom: 7px !important;
}

#sttManualExecutionWarning {
  min-height: 17px !important;
  max-height: 17px !important;
  line-height: 1.15 !important;
  margin-bottom: 0 !important;
  overflow: hidden !important;
}


/* STT STEP65.15P FUTURES DUPLICATE CLEANUP CSS */
.stt6515p-removed {
  display: none !important;
}


/* STT STEP65.15Q FUTURES LIMIT RESTORE CSS */
#stt65FuturesLimitBox.stt65-futures-limit-box {
  display: grid;
  gap: 4px;
  min-width: 0;
  margin: 0 !important;
}

#stt65FuturesLimitBox label {
  font-size: 11px !important;
  font-weight: 900 !important;
  line-height: 12px !important;
  min-height: 12px !important;
  color: rgba(226, 232, 240, .92) !important;
}

#stt65FuturesLimitBox input {
  height: 34px !important;
  min-height: 34px !important;
  border-radius: 10px !important;
  border: 1px solid rgba(34, 211, 238, .28) !important;
  background: rgba(15, 23, 42, .96) !important;
  color: #f8fafc !important;
  color-scheme: dark !important;
  font-size: 12px !important;
  font-weight: 850 !important;
  padding: 0 10px !important;
  outline: none !important;
  box-sizing: border-box !important;
  width: 100% !important;
}

#sttManualOpenTradeOverlay .stt-manual-open-note {
  min-height: 24px !important;
  max-height: 24px !important;
  overflow: hidden !important;
  line-height: 1.2 !important;
}


/* STT STEP65.15R FUTURES COMPACT MODAL CSS */
/* Compact Futures modal and hide the colorful inner scrollbar. Spot modal untouched. */

#sttManualOpenTradeOverlay.stt6515r-futures-modal,
.stt-manual-open-overlay.stt6515r-futures-modal {
  align-items: flex-start !important;
  justify-content: center !important;
  padding-top: clamp(38px, 5vh, 58px) !important;
  box-sizing: border-box !important;
  scrollbar-width: none !important;
}

#sttManualOpenTradeOverlay.stt6515r-futures-modal::-webkit-scrollbar,
.stt6515r-futures-modal::-webkit-scrollbar,
.stt6515r-futures-card::-webkit-scrollbar {
  width: 0 !important;
  height: 0 !important;
  display: none !important;
}

.stt6515r-futures-card {
  max-height: calc(100vh - 74px) !important;
  overflow-y: auto !important;
  scrollbar-width: none !important;
  padding-top: 13px !important;
  padding-bottom: 14px !important;
  transition: none !important;
}

/* Header + execution box compact */
.stt6515r-futures-modal #sttManualExecutionBox,
.stt6515r-futures-modal .stt-manual-execution-box {
  min-height: 64px !important;
  padding: 8px 9px !important;
  margin-bottom: 8px !important;
}

.stt6515r-futures-modal #sttManualExecutionMode {
  height: 31px !important;
  min-height: 31px !important;
  font-size: 12px !important;
}

/* Labels + inputs compact */
.stt6515r-futures-modal label {
  font-size: 10.5px !important;
  line-height: 11px !important;
  min-height: 11px !important;
  margin-bottom: 3px !important;
}

.stt6515r-futures-modal input:not([type="range"]),
.stt6515r-futures-modal select {
  height: 31px !important;
  min-height: 31px !important;
  font-size: 12px !important;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
  box-sizing: border-box !important;
}

.stt6515r-futures-modal input[type="range"] {
  height: 16px !important;
  min-height: 16px !important;
  margin-top: 3px !important;
  margin-bottom: 3px !important;
}

/* Amount area compact */
.stt6515r-futures-modal #sttManualOpenBalancePill {
  height: 22px !important;
  min-height: 22px !important;
  line-height: 20px !important;
  min-width: 134px !important;
  max-width: 134px !important;
  font-size: 10.5px !important;
}

/* Futures controls panel compact */
.stt6515r-futures-modal .stt-manual-futures-controls,
.stt6515r-futures-modal .futures-controls,
.stt6515r-futures-modal div:has(> #sttManualLeverage),
.stt6515r-futures-modal div:has(#sttManualMarginMode) {
  padding: 9px !important;
  margin-top: 8px !important;
  margin-bottom: 8px !important;
  gap: 5px !important;
}

/* Position summary compact */
.stt6515r-futures-modal div,
.stt6515r-futures-modal span,
.stt6515r-futures-modal small {
  transition: none !important;
}

.stt6515r-futures-modal div:has(> #sttManualMarginMode),
.stt6515r-futures-modal div:has(> #sttManualOrderType) {
  gap: 6px !important;
}

/* Limit price box compact */
.stt6515r-futures-modal #stt65FuturesLimitBox,
.stt6515r-futures-modal #sttManualLimitPriceWrap {
  margin: 0 !important;
  gap: 3px !important;
}

.stt6515r-futures-modal #stt65FuturesLimitBox input,
.stt6515r-futures-modal #sttManualLimitPrice {
  height: 31px !important;
  min-height: 31px !important;
}

/* Yellow warning inside futures controls compact */
.stt6515r-futures-modal .stt-manual-futures-controls .text-yellow,
.stt6515r-futures-modal .futures-controls .text-yellow,
.stt6515r-futures-modal div[style*="yellow"],
.stt6515r-futures-modal div:has(#sttManualLeverage) small {
  font-size: 10px !important;
  line-height: 1.15 !important;
  max-height: 28px !important;
  overflow: hidden !important;
}

/* SL/TP + footer compact */
.stt6515r-futures-modal input[placeholder*="Stop"],
.stt6515r-futures-modal input[placeholder*="Take"] {
  height: 31px !important;
  min-height: 31px !important;
}

.stt6515r-futures-modal .stt-manual-open-note {
  min-height: 20px !important;
  max-height: 20px !important;
  line-height: 1.15 !important;
  margin-top: 5px !important;
  margin-bottom: 6px !important;
  overflow: hidden !important;
  font-size: 11px !important;
}

.stt6515r-futures-modal button {
  height: 38px !important;
  min-height: 38px !important;
  font-size: 12px !important;
  transition: none !important;
}

@media (max-height: 760px) {
  #sttManualOpenTradeOverlay.stt6515r-futures-modal,
  .stt-manual-open-overlay.stt6515r-futures-modal {
    padding-top: 20px !important;
  }

  .stt6515r-futures-card {
    max-height: calc(100vh - 38px) !important;
  }
}


/* STT STEP65.15S PAPER BALANCE PILL CSS */
#sttManualOpenBalancePill {
  min-width: 154px !important;
  max-width: 154px !important;
  width: 154px !important;
  text-align: center !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}


/* STT STEP65.15U BALANCE PILL WIDTH FIX */
#sttManualOpenBalancePill {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: auto !important;
  min-width: 176px !important;
  max-width: none !important;
  white-space: nowrap !important;
  padding: 0 14px !important;
  box-sizing: border-box !important;
  text-align: center !important;
  overflow: visible !important;
}

#sttManualOpenTradeOverlay #sttManualOpenBalancePill {
  flex: 0 0 auto !important;
}


/* STT STEP65.15V FUTURES ULTRA COMPACT CSS */
/* Futures modal only: smaller controls, less footer gap, hidden inner scrollbar. */

#sttManualOpenTradeOverlay.stt6515v-futures-modal,
.stt-manual-open-overlay.stt6515v-futures-modal {
  align-items: flex-start !important;
  justify-content: center !important;
  padding-top: clamp(18px, 3vh, 36px) !important;
  box-sizing: border-box !important;
  scrollbar-width: none !important;
}

#sttManualOpenTradeOverlay.stt6515v-futures-modal::-webkit-scrollbar,
.stt6515v-futures-modal::-webkit-scrollbar,
.stt6515v-futures-card::-webkit-scrollbar {
  width: 0 !important;
  height: 0 !important;
  display: none !important;
}

.stt6515v-futures-card {
  max-height: calc(100vh - 42px) !important;
  overflow-y: auto !important;
  scrollbar-width: none !important;
  padding-top: 10px !important;
  padding-bottom: 8px !important;
  transition: none !important;
}

/* Top title area compact */
.stt6515v-futures-modal .stt-manual-open-title,
.stt6515v-futures-modal h2,
.stt6515v-futures-modal h3 {
  margin-bottom: 2px !important;
  line-height: 1.05 !important;
}

.stt6515v-futures-modal .stt-manual-open-subtitle,
.stt6515v-futures-modal #sttManualOpenSymbol {
  line-height: 1.15 !important;
  margin-bottom: 5px !important;
}

/* Execution box compact */
.stt6515v-futures-modal #sttManualExecutionBox,
.stt6515v-futures-modal .stt-manual-execution-box {
  min-height: 56px !important;
  padding: 7px 8px !important;
  margin-bottom: 6px !important;
}

.stt6515v-futures-modal #sttManualExecutionMode {
  height: 29px !important;
  min-height: 29px !important;
  font-size: 11.5px !important;
}

/* All inner labels/inputs compact */
.stt6515v-futures-modal label {
  font-size: 10px !important;
  line-height: 10px !important;
  min-height: 10px !important;
  margin-bottom: 2px !important;
}

.stt6515v-futures-modal input:not([type="range"]),
.stt6515v-futures-modal select {
  height: 29px !important;
  min-height: 29px !important;
  font-size: 11.5px !important;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
  box-sizing: border-box !important;
  border-radius: 9px !important;
}

.stt6515v-futures-modal input[type="range"] {
  height: 13px !important;
  min-height: 13px !important;
  margin-top: 2px !important;
  margin-bottom: 2px !important;
}

/* Amount row compact */
.stt6515v-futures-modal #sttManualOpenBalancePill {
  height: 20px !important;
  min-height: 20px !important;
  line-height: 18px !important;
  min-width: 134px !important;
  max-width: 134px !important;
  font-size: 10px !important;
  padding: 0 8px !important;
}

/* Futures controls panel compact */
.stt6515v-futures-modal .stt-manual-futures-controls,
.stt6515v-futures-modal .futures-controls,
.stt6515v-futures-modal div:has(> #sttManualLeverage),
.stt6515v-futures-modal div:has(#sttManualMarginMode) {
  padding: 7px !important;
  margin-top: 6px !important;
  margin-bottom: 6px !important;
  gap: 4px !important;
}

/* Margin/order/limit rows compact */
.stt6515v-futures-modal div:has(> #sttManualMarginMode),
.stt6515v-futures-modal div:has(> #sttManualOrderType),
.stt6515v-futures-modal #stt65FuturesLimitBox {
  gap: 5px !important;
  margin-top: 0 !important;
  margin-bottom: 0 !important;
}

.stt6515v-futures-modal #stt65FuturesLimitBox input,
.stt6515v-futures-modal #sttManualLimitPrice {
  height: 29px !important;
  min-height: 29px !important;
}

/* Position green summary compact */
.stt6515v-futures-modal div[style*="background"],
.stt6515v-futures-modal .stt-position-summary,
.stt6515v-futures-modal .position-summary {
  min-height: 22px !important;
  max-height: 24px !important;
  line-height: 1.1 !important;
  font-size: 10.5px !important;
}

/* Yellow warning compact */
.stt6515v-futures-modal .stt-manual-futures-controls small,
.stt6515v-futures-modal .futures-controls small,
.stt6515v-futures-modal div:has(#sttManualLeverage) small {
  font-size: 9.8px !important;
  line-height: 1.08 !important;
  max-height: 24px !important;
  overflow: hidden !important;
}

/* SL/TP compact */
.stt6515v-futures-modal input[placeholder*="Stop"],
.stt6515v-futures-modal input[placeholder*="Take"] {
  height: 29px !important;
  min-height: 29px !important;
}

.stt6515v-futures-modal div:has(input[placeholder*="Stop"]),
.stt6515v-futures-modal div:has(input[placeholder*="Take"]) {
  margin-top: 3px !important;
  margin-bottom: 3px !important;
}

/* Footer/note/buttons compact */
.stt6515v-futures-modal .stt-manual-open-note {
  min-height: 16px !important;
  max-height: 16px !important;
  line-height: 1.1 !important;
  margin-top: 3px !important;
  margin-bottom: 4px !important;
  overflow: hidden !important;
  font-size: 10.5px !important;
}

.stt6515v-futures-modal .stt-manual-actions,
.stt6515v-futures-modal .manual-actions {
  gap: 8px !important;
  margin-top: 4px !important;
}

.stt6515v-futures-modal button {
  height: 35px !important;
  min-height: 35px !important;
  font-size: 11.5px !important;
  transition: none !important;
}

/* Remove extra blank gaps inside modal */
.stt6515v-futures-modal .stt-field,
.stt6515v-futures-modal .stt-form-field,
.stt6515v-futures-modal .form-group {
  margin-bottom: 5px !important;
}

@media (max-height: 760px) {
  #sttManualOpenTradeOverlay.stt6515v-futures-modal,
  .stt-manual-open-overlay.stt6515v-futures-modal {
    padding-top: 12px !important;
  }

  .stt6515v-futures-card {
    max-height: calc(100vh - 24px) !important;
  }
}


/* STT STEP65.15W SPOT SPACING POLISH CSS */
/* Spot cart only: add breathing room above SL/TP and push actions slightly lower. */

.stt6515w-spot-spacing #stt6515mSpotRow {
  margin-top: 6px !important;
  margin-bottom: 12px !important;
}

.stt6515w-spot-spacing #stt6515mSpotOrderType,
.stt6515w-spot-spacing #stt6515mSpotLimitPrice {
  height: 33px !important;
  min-height: 33px !important;
}

/* SL/TP row ko order row se thoda niche shift */
.stt6515w-spot-spacing div:has(input[placeholder*="Stop"]),
.stt6515w-spot-spacing div:has(input[placeholder*="Take"]) {
  margin-top: 8px !important;
}

/* SL/TP labels ke liye breathing space */
.stt6515w-spot-spacing label {
  margin-bottom: 4px !important;
}

/* Note + Buy/Sell buttons ko thoda niche, but cart compact rahe */
.stt6515w-spot-spacing .stt-manual-open-note {
  margin-top: 9px !important;
  margin-bottom: 9px !important;
  min-height: 20px !important;
  max-height: 20px !important;
  line-height: 1.2 !important;
}

/* Action row slightly lower */
.stt6515w-spot-spacing .stt-manual-actions,
.stt6515w-spot-spacing .manual-actions,
.stt6515w-spot-spacing div:has(> button) {
  margin-top: 6px !important;
}

/* Buttons ke niche existing space use ho, crop na ho */
.stt6515w-spot-card {
  padding-bottom: 20px !important;
}


/* STT STEP65.16K EXACT BINANCE STATUS HEIGHT FIX */
/* Root fix: old patches left #binanceStatus min-height 220/238/268px. After removing warning, make this exact status card content-sized. */

#page-exchange #binanceStatus {
  min-height: 0 !important;
  height: auto !important;
  max-height: none !important;
  padding-bottom: 12px !important;
  overflow: visible !important;
}

#page-exchange #binanceStatus .bot-meta {
  margin-top: 8px !important;
  margin-bottom: 0 !important;
  padding-bottom: 0 !important;
}

#page-exchange #binanceStatus .meta-box {
  min-height: 50px !important;
}

#page-exchange #binanceStatus .warning-box,
#page-exchange #binanceStatus .binance-status-warning,
#page-exchange #binanceStatus .stt-status-stable-warning {
  display: none !important;
  height: 0 !important;
  min-height: 0 !important;
  max-height: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  overflow: hidden !important;
}


/* STT STEP70.9MJ — mobile-only chart label flicker fix */
@media (max-width: 820px), (pointer: coarse) {
  #sttMarketCoinChartWrap .stt-entry-risk-label-btn,
  #sttMarketCoinChartWrap .stt-line-close-btn,
  #sttMarketCoinChartWrap .stt-risk-drag-handle,
  #sttMarketCoinChartWrap .stt-risk-clear-btn,
  #sttMarketCoinChartWrap .stt-pending-limit-row,
  #sttMarketCoinChart .stt-entry-risk-label-btn,
  #sttMarketCoinChart .stt-line-close-btn,
  #sttMarketCoinChart .stt-risk-drag-handle,
  #sttMarketCoinChart .stt-risk-clear-btn,
  #sttMarketCoinChart .stt-pending-limit-row {
    transition: none !important;
    animation: none !important;
    will-change: top, transform !important;
    transform: translate3d(0, 0, 0) !important;
    backface-visibility: hidden !important;
    -webkit-font-smoothing: antialiased !important;
  }

  #sttMarketCoinChartWrap.stt-mobile-overlay-freeze {
    overscroll-behavior: contain;
  }
}


/* STT STEP70.10C — PnL report button modal fresh */
.stt-pnl-open-btn {
  border: 1px solid rgba(89, 219, 255, 0.35) !important;
  background: linear-gradient(135deg, rgba(19, 163, 215, 0.92), rgba(96, 64, 190, 0.9)) !important;
  color: #fff !important;
}

.stt-pnl-modal {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: none;
}

.stt-pnl-modal.show {
  display: block;
}

.stt-pnl-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(1, 6, 18, 0.78);
  backdrop-filter: blur(8px);
}

.stt-pnl-modal-card {
  position: relative;
  width: min(980px, calc(100vw - 32px));
  max-height: min(86vh, 820px);
  overflow: auto;
  margin: 7vh auto;
  padding: 18px;
  border: 1px solid rgba(53, 211, 255, 0.24);
  border-radius: 22px;
  background:
    radial-gradient(circle at top left, rgba(53, 211, 255, 0.13), transparent 34%),
    linear-gradient(135deg, rgba(10, 22, 42, 0.98), rgba(18, 18, 48, 0.96));
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.45);
}

.stt-pnl-modal-head {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 14px;
}

.stt-pnl-modal-head h3 {
  margin: 0;
  color: #eef6ff;
  font-size: 21px;
}

.stt-pnl-modal-head p {
  margin: 5px 0 0;
  color: #9fb0cc;
  font-size: 13px;
}

.stt-pnl-modal-x {
  border: 1px solid rgba(148, 163, 184, .25);
  background: rgba(15, 23, 42, .75);
  color: #e5e7eb;
  width: 38px;
  height: 38px;
  border-radius: 14px;
  font-size: 22px;
  cursor: pointer;
}

.stt-pnl-filter-title {
  color: #dbeafe;
  font-size: 12px;
  font-weight: 900;
  margin: 12px 0 8px;
}

.stt-pnl-ranges,
.stt-pnl-markets {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.stt-pnl-range-btn,
.stt-pnl-market-btn {
  border: 1px solid rgba(89, 219, 255, 0.28);
  background: rgba(13, 26, 49, 0.86);
  color: #dbeafe;
  border-radius: 999px;
  padding: 8px 12px;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.stt-pnl-range-btn.active,
.stt-pnl-market-btn.active {
  border-color: rgba(250, 204, 21, 0.75);
  background: rgba(250, 204, 21, 0.16);
  color: #fde68a;
}

.stt-pnl-modal-body {
  margin-top: 16px;
}

.stt-pnl-summary-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
}

.stt-pnl-metric {
  padding: 12px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 14px;
  background: rgba(7, 16, 32, 0.72);
}

.stt-pnl-metric span {
  display: block;
  color: #91a4c8;
  font-size: 11px;
  margin-bottom: 5px;
}

.stt-pnl-metric strong {
  color: #eef6ff;
  font-size: 15px;
}

.stt-pnl-metric.primary strong {
  font-size: 18px;
}

.stt-pnl-modal .profit { color: #22c55e !important; }
.stt-pnl-modal .loss { color: #ef4444 !important; }
.stt-pnl-modal .flat { color: #cbd5e1 !important; }

.stt-pnl-mini-sections {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 14px;
}

.stt-pnl-breakdown,
.stt-pnl-recent {
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 14px;
  background: rgba(5, 12, 26, 0.58);
  padding: 12px;
}

.stt-pnl-subtitle {
  color: #e2e8f0;
  font-size: 13px;
  font-weight: 900;
  margin-bottom: 8px;
}

.stt-pnl-break-row,
.stt-pnl-trade-row {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 8px;
  align-items: center;
  padding: 8px 0;
  border-top: 1px solid rgba(148, 163, 184, 0.09);
  color: #cbd5e1;
  font-size: 12px;
}

.stt-pnl-break-row:first-of-type,
.stt-pnl-trade-row:first-of-type {
  border-top: 0;
}

.stt-pnl-break-row em,
.stt-pnl-trade-row em {
  color: #8090ad;
  font-style: normal;
  font-size: 11px;
}

.stt-pnl-empty,
.stt-pnl-loading,
.stt-pnl-error {
  padding: 14px;
  text-align: center;
  color: #9fb0cc;
  border: 1px dashed rgba(148, 163, 184, 0.18);
  border-radius: 12px;
}

.stt-pnl-error {
  color: #fca5a5;
  border-color: rgba(239, 68, 68, 0.26);
}

@media (max-width: 900px) {
  .stt-pnl-modal-card {
    width: calc(100vw - 18px);
    max-height: 88vh;
    margin: 5vh auto;
    padding: 14px;
    border-radius: 18px;
  }

  .stt-pnl-ranges,
  .stt-pnl-markets {
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 4px;
  }

  .stt-pnl-range-btn,
  .stt-pnl-market-btn {
    white-space: nowrap;
    padding: 7px 10px;
  }

  .stt-pnl-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .stt-pnl-mini-sections {
    grid-template-columns: 1fr;
  }

  .stt-pnl-break-row,
  .stt-pnl-trade-row {
    grid-template-columns: 1fr auto;
  }

  .stt-pnl-break-row em,
  .stt-pnl-trade-row em {
    grid-column: 1 / -1;
  }
}



/* STT STEP70.10H — Premium PnL icon polish */
.stt-pnl-open-btn,
.stt-pnl-title-with-icon {
  display: inline-flex !important;
  align-items: center !important;
  gap: 9px !important;
}

.stt-pnl-premium-icon {
  width: 26px;
  height: 26px;
  border-radius: 9px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #dff8ff;
  background:
    radial-gradient(circle at 30% 20%, rgba(255,255,255,.28), transparent 28%),
    linear-gradient(135deg, rgba(34,211,238,.95), rgba(99,102,241,.9));
  border: 1px solid rgba(125, 245, 255, .38);
  box-shadow:
    0 0 0 1px rgba(255,255,255,.06) inset,
    0 8px 22px rgba(34,211,238,.18);
  flex: 0 0 auto;
}

.stt-pnl-title-with-icon .stt-pnl-premium-icon {
  width: 30px;
  height: 30px;
  border-radius: 10px;
}

.stt-pnl-premium-icon svg {
  display: block;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,.25));
}

@media (max-width: 900px) {
  .stt-pnl-premium-icon {
    width: 24px;
    height: 24px;
  }
}


/* STT STEP70.10H2 — Premium PnL icon polish */
.stt-pnl-open-btn,
.stt-pnl-title-with-icon {
  display: inline-flex !important;
  align-items: center !important;
  gap: 9px !important;
}

.stt-pnl-premium-icon {
  width: 26px;
  height: 26px;
  border-radius: 9px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #e8fbff;
  background:
    radial-gradient(circle at 30% 20%, rgba(255,255,255,.32), transparent 30%),
    linear-gradient(135deg, rgba(34,211,238,.95), rgba(99,102,241,.92));
  border: 1px solid rgba(125,245,255,.4);
  box-shadow:
    0 0 0 1px rgba(255,255,255,.07) inset,
    0 8px 22px rgba(34,211,238,.18);
  flex: 0 0 auto;
}

.stt-pnl-title-with-icon .stt-pnl-premium-icon {
  width: 30px;
  height: 30px;
  border-radius: 10px;
}

.stt-pnl-premium-icon svg {
  display: block;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,.28));
}

@media (max-width: 900px) {
  .stt-pnl-premium-icon {
    width: 24px;
    height: 24px;
  }
}










/* STT STEP70.10H8 — Static PnL button group */
/* Bot Center + Trade Journal: PnL button stays directly left of Refresh button. */
.stt-pnl-static-action-group {
  margin-left: auto !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: flex-end !important;
  gap: 12px !important;
  flex-wrap: nowrap !important;
  width: auto !important;
  max-width: max-content !important;
}

.stt-pnl-static-action-group > .view-btn,
.stt-pnl-static-action-group > .stt-pnl-open-btn {
  height: 46px !important;
  min-height: 46px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  line-height: 1 !important;
  margin: 0 !important;
  align-self: center !important;
  vertical-align: middle !important;
  transform: none !important;
}

.stt-pnl-static-action-group .stt-pnl-open-btn {
  gap: 8px !important;
}

.stt-pnl-static-action-group .stt-pnl-premium-icon {
  width: 24px !important;
  height: 24px !important;
  margin: 0 !important;
  transform: none !important;
}

@media (max-width: 900px) {
  .stt-pnl-static-action-group {
    gap: 8px !important;
  }

  .stt-pnl-static-action-group > .view-btn,
  .stt-pnl-static-action-group > .stt-pnl-open-btn {
    height: 42px !important;
    min-height: 42px !important;
    padding-left: 12px !important;
    padding-right: 12px !important;
    font-size: 12px !important;
  }

  .stt-pnl-static-action-group .stt-pnl-premium-icon {
    width: 22px !important;
    height: 22px !important;
  }
}
