/*
  نوکسا – تحلیل تکنیکال (Technical Analysis UI)
  ------------------------------------------
  هدف: یک تجربه مدرن، تمیز و ریسپانسیو برای صفحه تحلیل تکنیکال.
*/

:root{
  --nx-ta-primary: var(--nx-primary, #2563eb);
  --nx-ta-primary-2: var(--nx-primary-2, #3b82f6);
  --nx-ta-muted: var(--nx-muted, #6b7280);
  --nx-ta-bg: var(--nx-bg, #f5f7fb);
  --nx-ta-surface: rgba(255,255,255,.86);
  --nx-ta-surface-2: rgba(255,255,255,.66);
  --nx-ta-border: rgba(203,213,225,.90);
  --nx-ta-shadow: 0 18px 55px rgba(15,23,42,.10);
  --nx-ta-shadow-sm: 0 10px 24px rgba(15,23,42,.08);
  --nx-ta-radius-lg: 1.35rem;
  --nx-ta-radius-md: 1.15rem;
  --nx-ta-radius-sm: .95rem;
  --nx-ta-ring: 0 0 0 .25rem rgba(37, 99, 235, .18);
}

/* -------------------------------------------------
   RTL/LTR helpers
   -------------------------------------------------
   In RTL contexts, negative numbers like "-2.3%" may render with the
   minus sign on the right. Apply this utility to numeric-only elements.
*/
.nx-ltr{
  direction: ltr;
  unicode-bidi: isolate;
  display: inline-block;
}

.nx-tech{
  position: relative;
  padding: 1.25rem 0;
}

.nx-tech::before{
  content:"";
  position:absolute;
  inset:0;
  background:
    radial-gradient(circle at top right, rgba(37,99,235,.14) 0, transparent 55%),
    radial-gradient(circle at bottom left, rgba(34,197,94,.10) 0, transparent 55%),
    radial-gradient(circle at 40% 80%, rgba(59,130,246,.10) 0, transparent 55%),
    var(--nx-ta-bg);
  z-index:0;
}

.nx-tech > .container-fluid{
  position:relative;
  z-index:1;
}

.nx-tech-hero{
  border: 1px solid var(--nx-ta-border);
  border-radius: var(--nx-ta-radius-lg);
  background:
    radial-gradient(circle at 20% 20%, rgba(37, 99, 235, .18) 0, transparent 62%),
    radial-gradient(circle at 90% 35%, rgba(0, 95, 255, .4) 0, transparent 62%),
    var(--nx-ta-surface-2);
  box-shadow: var(--nx-ta-shadow-sm);
  backdrop-filter: blur(10px);
  padding: 1.1rem 1.1rem;
  position: relative;
  z-index: 20;
}

@media (min-width: 992px){
  .nx-tech-hero{ padding: 1.25rem 1.35rem; }
}

.nx-tech-title{
  font-weight: 950;
  letter-spacing: -0.2px;
  margin: 0;
}

.nx-tech-sub{
  margin: .35rem 0 0;
  color: rgba(71,85,105,.95);
}

.nx-tech-search{
  margin-top: .85rem;
  display:flex;
  gap: .6rem;
  flex-wrap: wrap;
}

.nx-tech-search .form-control{
  min-width: 220px;
  flex: 1 1 280px;
  border-radius: 1rem;
}

.nx-tech-search .btn{
  border-radius: 1rem;
  font-weight: 900;
}

.nx-tech-card{
  border: 1px solid var(--nx-ta-border);
  border-radius: var(--nx-ta-radius-lg);
  background: var(--nx-ta-surface);
  box-shadow: var(--nx-ta-shadow-sm);
  backdrop-filter: blur(10px);
  position: relative;
  z-index: 1;

}

.nx-tech-card .card-body{ padding: 1rem 1rem; }

.nx-kpi{
  display:flex;
  flex-direction:column;
  gap: .1rem;
}

/* ─────────────────────────────────────────────────────────
   Symbol Dashboard – KPI chips / meters / plan
   ───────────────────────────────────────────────────────── */

.nx-ta-kpis{
  display:flex;
  flex-wrap: wrap;
  gap: .55rem;
}

@media (max-width: 576px){
  .nx-ta-kpis{
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: .25rem;
    -webkit-overflow-scrolling: touch;
  }
  .nx-ta-kpis::-webkit-scrollbar{ height: 8px; }
}

.nx-ta-chip{
  flex: 0 0 auto;
  display:flex;
  flex-direction: column;
  gap: .15rem;
  padding: .65rem .75rem;
  border: 1px solid rgba(203,213,225,.85);
  background: rgba(255,255,255,.70);
  border-radius: 1.05rem;
  box-shadow: 0 10px 18px rgba(15,23,42,.06);
  min-width: 150px;
}

.nx-ta-chip .label{
  font-size: .8rem;
  font-weight: 900;
  color: rgba(71,85,105,.95);
  white-space: nowrap;

}

.nx-ta-chip .value{
  margin-top:7px;
  font-weight: 950;
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
  color: rgba(15,23,42,.92);
  text-align: center;
}

.nx-ta-chip .sub{
  font-size: .78rem;
  color: rgba(100,116,139,.95);
  white-space: nowrap;
  text-align: right;
}

.nx-ta-chip.good{ border-color: rgba(34,197,94,.35); background: rgba(34,197,94,.08); }
.nx-ta-chip.warn{ border-color: rgba(245,158,11,.35); background: rgba(245,158,11,.08); }
.nx-ta-chip.bad{ border-color: rgba(239,68,68,.35); background: rgba(239,68,68,.08); }
.nx-ta-chip.neu{ border-color: rgba(99,102,241,.25); background: rgba(99,102,241,.06); }

.nx-meter{
  border: 1px solid rgba(203,213,225,.85);
  border-radius: 1.05rem;
  background: rgba(255,255,255,.66);
  padding: .7rem .75rem;
}

.nx-meter .top{
  display:flex;
  align-items:center;
  justify-content: space-between;
  gap: .75rem;
}

.nx-meter .title{ font-weight: 950; font-size: .9rem; }
.nx-meter .val{ font-weight: 950; font-variant-numeric: tabular-nums; }

.nx-meter .bar{
  height: 10px;
  border-radius: 9999px;
  background: rgba(226,232,240,.9);
  overflow:hidden;
  margin-top: .55rem;
}

.nx-meter .fill{
  height: 100%;
  width: 0%;
  border-radius: 9999px;
  background: linear-gradient(135deg, var(--nx-ta-primary), var(--nx-ta-primary-2));
  transition: width .35s ease;
}

.nx-ta-plan-grid{
  display:grid;
  grid-template-columns: 1fr;
  gap: .55rem;
}

.nx-ta-plan-row{
  display:flex;
  align-items:center;
  justify-content: space-between;
  gap: .75rem;
  padding: .55rem .65rem;
  border: 1px solid rgba(203,213,225,.85);
  background: rgba(255,255,255,.68);
  border-radius: 1rem;
}

.nx-ta-plan-row .k{ font-weight: 900; color: rgba(71,85,105,.95); font-size: .82rem; }
.nx-ta-plan-row .v{ font-weight: 950; font-variant-numeric: tabular-nums; }

.nx-ta-bullets{
  padding: 0;
  margin: .25rem 0 0;
  list-style: none;
}

.nx-ta-bullets li{
  display:flex;
  gap: .55rem;
  padding: .55rem .6rem;
  border: 1px solid rgba(203,213,225,.75);
  background: rgba(255,255,255,.60);
  border-radius: 1rem;
}

.nx-ta-bullets .dot{
  width: 10px;
  height: 10px;
  border-radius: 9999px;
  margin-top: .35rem;
  flex: 0 0 auto;
}

.nx-ta-bullets .dot.pos{ background: rgba(34,197,94,.95); }
.nx-ta-bullets .dot.neg{ background: rgba(239,68,68,.95); }
.nx-ta-bullets .dot.neu{ background: rgba(99,102,241,.85); }

.nx-ta-bullets .ttl{ font-weight: 950; }
.nx-ta-bullets .txt{ color: rgba(71,85,105,.95); font-size: .88rem; }

/* Signal summary (Key points) */
.nx-ta-signal-summary{
  display:flex;
  flex-wrap:wrap;
  gap: 8px;
  margin: .25rem 0 .65rem;
}
.nx-sum-pill{
  display:inline-flex;
  align-items:center;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: .75rem;
  font-weight: 900;
  border: 1px solid rgba(203,213,225,.85);
  background: rgba(255,255,255,.65);
  color: rgba(30,41,59,.95);
}
.nx-sum-pill.pos{
  background: rgba(34,197,94,.12);
  border-color: rgba(34,197,94,.28);
  color: rgba(22,101,52,.95);
}
.nx-sum-pill.warn{
  background: rgba(245,158,11,.12);
  border-color: rgba(245,158,11,.28);
  color: rgba(146,64,14,.95);
}
.nx-sum-pill.neg{
  background: rgba(239,68,68,.12);
  border-color: rgba(239,68,68,.28);
  color: rgba(153,27,27,.95);
}
.nx-sum-pill.neu{
  background: rgba(99,102,241,.10);
  border-color: rgba(99,102,241,.22);
  color: rgba(49,46,129,.95);
}
.nx-ta-checkwrap{
  border-top: 1px dashed rgba(203,213,225,.75);
  padding-top: .75rem;
}

.nx-ta-checklist{
  display: grid;
  grid-template-columns: 1fr;
  gap: .55rem;
}

.nx-ta-checkitem{
  display: flex;
  gap: .55rem;
  padding: .55rem .65rem;
  border: 1px solid rgba(203,213,225,.75);
  background: rgba(248,250,252,.75);
  border-radius: 1rem;
}

.nx-ta-checkitem .ic{
  width: 28px;
  height: 28px;
  border-radius: 9999px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  background: rgba(148,163,184,.18);
  color: rgba(71,85,105,.92);
}

.nx-ta-checkitem .k{ font-weight: 950; font-size: .85rem; }
.nx-ta-checkitem .v{ color: rgba(15,23,42,.92); font-weight: 800; font-size: .85rem; }
.nx-ta-checkitem .s{ color: rgba(100,116,139,.92); font-size: .78rem; }

.nx-ta-checkitem.good{ border-color: rgba(25,135,84,.28); background: rgba(25,135,84,.07); }
.nx-ta-checkitem.good .ic{ background: rgba(25,135,84,.14); color: rgba(25,135,84,.95); }

.nx-ta-checkitem.bad{ border-color: rgba(220,53,69,.25); background: rgba(220,53,69,.07); }
.nx-ta-checkitem.bad .ic{ background: rgba(220,53,69,.12); color: rgba(220,53,69,.95); }

.nx-ta-checkitem.warn{ border-color: rgba(255,193,7,.35); background: rgba(255,193,7,.10); }
.nx-ta-checkitem.warn .ic{ background: rgba(255,193,7,.18); color: rgba(146,64,14,.95); }

.nx-ta-checkitem.neu{ border-color: rgba(99,102,241,.25); background: rgba(99,102,241,.07); }
.nx-ta-checkitem.neu .ic{ background: rgba(99,102,241,.13); color: rgba(99,102,241,.95); }

.nx-kpi .nx-kpi-label{
  font-size: .78rem;
  color: rgba(71,85,105,.9);
  font-weight: 800;
}
.nx-kpi .nx-kpi-value{
  font-weight: 950;
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
}

.nx-ta-chart{
  width: 100%;
  height: 620px;
  min-height: 460px;
}


.nx-ta-toolbar{
  position: relative;
  z-index: 12;
  padding: .45rem .55rem;
  border-radius: 1.25rem;
  border: 1px solid rgba(203,213,225,.75);
  background: rgba(255,255,255,.62);
  backdrop-filter: blur(10px);
}

.nx-ta-toolbar .btn{
  border-radius: 1rem;
  font-weight: 900;
}

/* Highcharts Stock Tools (keep icons usable in RTL layouts) */
.highcharts-stocktools-wrapper{
  left: auto !important;
  right: 10px !important;
  direction: ltr;
}

.highcharts-popup{
  direction: rtl;
  text-align: right;
}

@media (max-width: 992px){
  .nx-ta-chart{ height: 520px; }
}
@media (max-width: 576px){
  .nx-ta-chart{ height: 460px; }
}

.nx-signal-item{
  border: 1px solid rgba(203,213,225,.8);
  background: rgba(255,255,255,.75);
  border-radius: 1rem;
  padding: .75rem .8rem;
  display:flex;
  gap: .65rem;
}

.nx-signal-dot{
  width: 10px;
  height: 10px;
  border-radius: 9999px;
  margin-top: .35rem;
  flex: 0 0 auto;
}

.nx-signal-title{ font-weight: 950; }
.nx-signal-detail{ color: rgba(71,85,105,.95); font-size: .88rem; }

.nx-signal-dot.pos{ background: rgba(34,197,94,.95); }
.nx-signal-dot.neg{ background: rgba(239,68,68,.95); }
.nx-signal-dot.neu{ background: rgba(99,102,241,.85); }

.nx-muted-small{ font-size: .85rem; color: rgba(100,116,139,.95); }

/* Smart money / queues cardlets */
.nx-ta-flow-grid{
  display:grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap:.65rem;
}

.nx-ta-flow-card{
  position:relative;
  overflow:hidden;
  border:1px solid rgba(203,213,225,.82);
  background:linear-gradient(135deg, rgba(255,255,255,.94), rgba(248,250,252,.72));
  border-radius:1rem;
  padding:.72rem .78rem;
  box-shadow:0 12px 28px rgba(15,23,42,.06);
}

.nx-ta-flow-card::before{
  content:"";
  position:absolute;
  inset:0 0 auto 0;
  height:3px;
  background:rgba(100,116,139,.5);
}

.nx-ta-flow-card.positive{
  border-color:rgba(34,197,94,.24);
  background:linear-gradient(135deg, rgba(240,253,244,.92), rgba(255,255,255,.78));
}
.nx-ta-flow-card.positive::before{ background:linear-gradient(90deg, rgba(22,163,74,.95), rgba(134,239,172,.7)); }
.nx-ta-flow-card.negative{
  border-color:rgba(239,68,68,.24);
  background:linear-gradient(135deg, rgba(254,242,242,.94), rgba(255,255,255,.78));
}
.nx-ta-flow-card.negative::before{ background:linear-gradient(90deg, rgba(220,38,38,.95), rgba(252,165,165,.7)); }
.nx-ta-flow-card.neutral{
  border-color:rgba(148,163,184,.28);
  background:linear-gradient(135deg, rgba(248,250,252,.95), rgba(255,255,255,.78));
}

.nx-ta-flow-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:.5rem;
  margin-bottom:.45rem;
}

.nx-ta-flow-label{
  color:rgba(30,41,59,.92);
  font-size:.78rem;
  font-weight:950;
  line-height:1.5;
}

.nx-ta-flow-icon{
  width:1.8rem;
  height:1.8rem;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  flex:0 0 auto;
  border-radius:.7rem;
  color:rgba(71,85,105,.95);
  background:rgba(100,116,139,.10);
}
.nx-ta-flow-card.positive .nx-ta-flow-icon{ color:rgb(22,101,52); background:rgba(34,197,94,.15); }
.nx-ta-flow-card.negative .nx-ta-flow-icon{ color:rgb(153,27,27); background:rgba(239,68,68,.14); }

.nx-ta-flow-grid,
.nx-ta-flow-card{
  direction: rtl;
}

.nx-ta-flow-head{
  flex-direction: row;
}

.nx-ta-flow-label{
  order:1;
  text-align:right;
  direction:rtl;
}

.nx-ta-flow-icon{
  order:2;
}

.nx-ta-flow-value{
  display:flex;
  align-items:baseline;
  justify-content:center;
  width:100%;
  gap:.25rem;
  color:rgba(15,23,42,.96);
  font-weight:950;
  letter-spacing:.01em;
  text-align:center;
  direction:ltr;
  unicode-bidi:isolate;
}
.nx-ta-flow-value b{ font-size:1.18rem; line-height:1.4; }
.nx-ta-flow-value small{ color:rgba(100,116,139,.9); font-size:.68rem; font-weight:900; }
.nx-ta-flow-card.positive .nx-ta-flow-value{ color:rgb(21,128,61); }
.nx-ta-flow-card.negative .nx-ta-flow-value{ color:rgb(220,38,38); }

.nx-ta-flow-hint{
  margin-top:.28rem;
  color:rgba(100,116,139,.95);
  font-size:.70rem;
  font-weight:800;
  line-height:1.55;
}

.nx-ta-flow-empty{
  color:rgba(100,116,139,.95);
  font-size:.82rem;
  font-weight:800;
}

@media (max-width: 576px){
  .nx-ta-flow-grid{ grid-template-columns: 1fr; }
}


/* ─────────────────────────────────────────────────────────────────────────
   Technical Scanner
   ───────────────────────────────────────────────────────────────────────── */

.nx-scan-controls{
  border-top: 1px solid rgba(203,213,225,.7);
  padding-top: .85rem;
}

.nx-scan-chips{
  display:flex;
  flex-wrap: wrap;
  gap: .5rem;
}

.nx-chip{
  border: 1px solid rgba(203,213,225,.95);
  background: rgba(255,255,255,.65);
  color: rgba(15,23,42,.92);
  border-radius: 9999px;
  padding: .45rem .75rem;
  font-weight: 900;
  font-size: .9rem;
  box-shadow: 0 8px 18px rgba(15,23,42,.06);
  transition: transform .12s ease, background .12s ease, border-color .12s ease;
}

.nx-chip:hover{ transform: translateY(-1px); }

.nx-chip.active{
  border-color: rgba(37,99,235,.45);
  background: rgba(37,99,235,.10);
}

/* Filters toolbar */
.nx-scan-filters{
  padding: .65rem;
  border: 1px solid rgba(203,213,225,.72);
  border-radius: 1.15rem;
  background: rgba(255,255,255,.68);
  box-shadow: 0 10px 26px rgba(15,23,42,.05);
}

.nx-filter-label{
  font-size: .78rem;
  font-weight: 950;
  color: rgba(71,85,105,.95);
  margin: 0 .25rem .25rem 0;
}

.nx-filter-group{
  border: 1px solid rgba(203,213,225,.85);
  border-radius: 999px;
  overflow: visible;
  position: relative;
  background: rgba(248,250,252,.92);
}

.nx-filter-group .input-group-text{
  border: 0;
  background: rgba(148,163,184,.12);
  border-radius: 999px;
  color: rgba(51,65,85,.92);
}

.nx-filter-select,
.nx-filter-input{
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  font-weight: 600;
  font-size: .8rem;
  color: rgba(15,23,42,.62);
}
.nx-filter-input.placeholder{
  font-weight: 600;
  font-size: .78rem;
  color: rgba(15,23,42,.62);
}
.nx-filter-select:focus,
.nx-filter-input:focus{
  outline: none;
}

/* Fancy dropdown (scanner filters) */
.nx-dd{ position: relative; }
.nx-filter-group .nx-dd{ flex: 1 1 auto; }
.nx-filter-group .nx-dd-toggle{
  border: 0;
  background: transparent;
  box-shadow: none;
  font-weight: 600;
  font-size: .78rem;
  color: rgba(15,23,42,.62);
  padding: .55rem .75rem;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .55rem;
}
.nx-filter-group .nx-dd-toggle:focus{ outline: none; box-shadow: none; }

.nx-dd-toggle .nx-dd-label{
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.nx-dd-toggle .bi-chevron-down{
  font-size: .9rem;
  opacity: .75;
}

.nx-dd-menu{
  z-index: 2000;
  border: 1px solid rgba(203,213,225,.88);
  border-radius: 1.15rem;
  box-shadow: 0 18px 44px rgba(15,23,42,.18);
  background: rgba(255,255,255,.96);
  backdrop-filter: blur(12px);
  padding: .55rem;
  margin-top: .45rem;
}

.nx-dd-searchwrap{
  display: flex;
  align-items: center;
  gap: .45rem;
  padding: .5rem .65rem;
  border: 1px solid rgba(203,213,225,.75);
  border-radius: 999px;
  background: rgba(248,250,252,.92);
}
.nx-dd-searchwrap i{ opacity: .7; }

.nx-dd-search{
  border: 0;
  background: transparent;
  box-shadow: none;
  padding: 0;
  min-height: 28px;
}
.nx-dd-search:focus{ outline: none; box-shadow: none; }

.nx-dd-items{
  margin-top: .5rem;
  max-height: 280px;
  overflow-y: auto;
  overflow-x: hidden;
  padding: .25rem;
}

.nx-dd-item{
  border-radius: .95rem;
  font-weight: 600;
  font-size: .8rem;
  padding: .55rem .75rem;
  white-space: normal;
}
.nx-dd-item:hover{ background: rgba(37,99,235,.08); }
.nx-dd-item.is-active,
.nx-dd-item.active{
  background: rgba(37,99,235,.14);
}



/* Results scroll (similar UX to market summary scroll cards) */
.nx-table-scroll{
  max-height: min(560px, calc(100vh - 340px));
  overflow-y: auto;
  overflow-x: auto;
  border: 1px solid rgba(203,213,225,.75);
  border-radius: 1.15rem;
}

.nx-table-scroll table{ margin-bottom: 0; }

.nx-table-scroll thead th{
  position: sticky;
  top: 0;
  z-index: 2;
  background: rgba(248,250,252,.96);
  backdrop-filter: blur(6px);
}

.nx-table-scroll::-webkit-scrollbar{ width: 6px; height: 6px; }
.nx-table-scroll::-webkit-scrollbar-thumb{ background: #c7c7c7; border-radius: 10px; }
.nx-table-scroll::-webkit-scrollbar-track{ background: #f1f1f1; }
.nx-table-scroll::-webkit-scrollbar-button{ height: 0; display: none; }

/* Value tooltip hint */
.nx-val{
  cursor: help;
  text-decoration: underline;
  text-decoration-style: dotted;
  text-underline-offset: 3px;
  opacity: .95;
}

/* Preview offcanvas: wider + responsive */
.nx-offcanvas-preview{
  width: min(680px, 96vw);
}
@media (max-width: 575.98px){
  .nx-offcanvas-preview{ width: 100vw; }
}

/* Tooltip style parity with other services (Fundamental / Reports) */
.sd-tooltip .tooltip-inner{
  background: #0b1220;
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  padding: 6px 10px;
  border-radius: 10px;
  box-shadow: 0 12px 28px rgba(15,23,42,.22);
  direction: rtl;
  /* Helps mixed RTL text + LTR numbers render correctly inside tooltips */
  unicode-bidi: plaintext;
  text-align: center;
  letter-spacing: .1px;
}
.sd-tooltip.bs-tooltip-top .tooltip-arrow::before    { border-top-color: #0b1220; }
.sd-tooltip.bs-tooltip-bottom .tooltip-arrow::before { border-bottom-color: #0b1220; }
.sd-tooltip.bs-tooltip-start .tooltip-arrow::before  { border-left-color: #0b1220; }
.sd-tooltip.bs-tooltip-end .tooltip-arrow::before    { border-right-color: #0b1220; }
.sd-tooltip.show .tooltip-inner{ animation: sdTooltipPop .14s ease-out; }
@keyframes sdTooltipPop{
  from { transform: translateY(2px) scale(.98); opacity: .0; }
  to   { transform: translateY(0) scale(1); opacity: 1; }
}

.nx-scan-table thead th{
  font-size: .8rem;
  color: rgba(71,85,105,.95);
  font-weight: 950;
  text-align: center;
  vertical-align: middle;
  white-space: nowrap;
}

.nx-scan-table td{
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
  text-align: center;
  font-size: .84rem;
  vertical-align: middle;
}

.nx-tag{
  display:inline-block;
  padding: .22rem .5rem;
  border-radius: 9999px;
  border: 1px solid rgba(203,213,225,.75);
  background: rgba(255,255,255,.6);
  font-size: .78rem;
  font-weight: 800;
  color: rgba(71,85,105,.95);
  margin: 0 .1rem .25rem 0;
}

/* RTL Highcharts tooltip helper */
.nx-hc-tooltip-rtl{
  direction: rtl;
  text-align: right;
}

/* ─────────────────────────────────────────────────────────
   ApexCharts panes (Price / Volume / Oscillator)
   ───────────────────────────────────────────────────────── */

/*
  2-pane layout (TradingView-like):
  - Pane 1: Price + Volume
  - Pane 2: RSI
*/
.nx-ta-charts{
  /* Slightly taller overall and allocate more space to RSI pane */
  height: clamp(600px, 76vh, 940px);
  display: grid;
  grid-template-rows: minmax(0, 7.4fr) minmax(0, 2.6fr);
  gap: .55rem;

  padding: .45rem;
  border: 1px solid rgba(203,213,225,.75);
  border-radius: 1.35rem;
  background: rgba(248,250,252,.55);
  overflow: hidden;
  position: relative;
}

/*
  IMPORTANT:
  ApexCharts height="100%" needs the parent containers to have an explicit height.
  In the original stylesheet we had `.nx-ta-charts .nx-ta-chart { height: auto; }`
  which has higher specificity than `.nx-ta-chart-price` and effectively cancels
  the intended fixed heights. That can cause the chart to briefly render and then
  collapse/reflow (appearing to "move down" and hide).

  Therefore: do NOT override height on the generic selector. Define heights on
  the pane classes with equal-or-higher specificity.
*/
/* Pane shells */
.nx-ta-charts .nx-ta-pane{
  width: 100%;
  height: 100%;
  min-height: 0;

  position: relative;
  overflow: hidden;

  border: 1px solid rgba(203,213,225,.65);
  border-radius: 1.15rem;
  background: rgba(255,255,255,.72);
  box-shadow: 0 8px 18px rgba(15,23,42,.04);
}

/* Pane 1: internal grid (price + volume) */
.nx-ta-charts .nx-ta-pane-main{
  display: grid;
  grid-template-rows: minmax(0, 7fr) minmax(0, 1.25fr);
  gap: 0;
}

/* Charts inside panes should fill their area; the pane draws the frame */
.nx-ta-charts .nx-ta-pane .nx-ta-chart{
  width: 100%;
  height: 100%;
  min-height: 0;

  position: relative;
  overflow: hidden;

  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

/* Divider between price & volume (within main pane) */
.nx-ta-charts .nx-ta-pane-main .nx-ta-chart-price{
  border-bottom: 1px solid rgba(203,213,225,.55);
}

/* Pane labels (top-left) */
.nx-ta-charts .nx-ta-chart[data-nx-title]::before{
  content: attr(data-nx-title);
  position: absolute;
  top: 10px;
  inset-inline-start: 12px;
  z-index: 5;

  padding: .18rem .55rem;
  border-radius: 999px;
  border: 1px solid rgba(203,213,225,.75);
  background: rgba(255,255,255,.82);
  backdrop-filter: blur(8px);

  font-size: .75rem;
  font-weight: 950;
  color: rgba(15,23,42,.86);
  letter-spacing: -0.1px;
  pointer-events: none;
}

/* Pane-specific tweaks (keep empty for now; heights are controlled by the grids) */
.nx-ta-charts .nx-ta-chart-price{ }
.nx-ta-charts .nx-ta-chart-volume{ }
.nx-ta-charts .nx-ta-chart-osc{ }

/* Mobile chart tabs behavior (show one pane at a time) */
.nx-ta-chart-tabs .btn-group .btn{
  border-radius: 999px;
}
.nx-ta-chart-tabs .btn-group .btn.active{
  font-weight: 900;
}

@media (max-width: 991.98px){
  .nx-ta-charts{
    height: 520px;
    grid-template-rows: 1fr;
    gap: 0;
  }
  #nx-ta-charts-wrap .nx-ta-pane[data-nx-pane]{
    display: none;
  }
  #nx-ta-charts-wrap[data-nx-active-pane="main"] .nx-ta-pane[data-nx-pane="main"],
  #nx-ta-charts-wrap[data-nx-active-pane="osc"] .nx-ta-pane[data-nx-pane="osc"]{
    display: block;
  }
}

/* Native fullscreen layout: make card-body fill viewport and keep the chart area scrollable */
#nx-ta-charts-card:fullscreen{
  width: 100vw;
  height: 100vh;
}
#nx-ta-charts-card:fullscreen .card-body{
  height: 100%;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
#nx-ta-charts-card:fullscreen #nx-ta-charts-wrap{
  flex: 1 1 auto;
  height: 100%;
  overflow: hidden;
}

/* Fullscreen (fallback CSS mode + native :fullscreen) */
body.nx-ta-faux-fullscreen{ overflow: hidden; }
body.nx-ta-faux-fullscreen #nx-ta-charts-card{
  position: fixed;
  inset: 0;
  z-index: 2000;
  margin: 0;
  border-radius: 0;
}
body.nx-ta-faux-fullscreen #nx-ta-charts-card .card-body{
  height: 100%;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
body.nx-ta-faux-fullscreen #nx-ta-charts-wrap{
  flex: 1 1 auto;
  height: 100%;
  overflow: hidden;
}

/* Fullscreen uses the same ratio grid; just fill the viewport area */
#nx-ta-charts-card:fullscreen .nx-ta-charts,
body.nx-ta-faux-fullscreen .nx-ta-charts{
  height: 100%;
}

/* ApexCharts tooltip RTL */
.apexcharts-tooltip,
.apexcharts-tooltip *{
  direction: rtl;
  text-align: right;
}

/* ─────────────────────────────────────────────────────────
   Help icon + Bootstrap tooltip RTL
   ───────────────────────────────────────────────────────── */

.nx-help{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 9999px;
  color: rgba(71,85,105,.95);
  cursor: help;
  margin-right: .25rem;
  opacity: .85;
  transition: opacity .12s ease, transform .12s ease;
}

.nx-help:hover{
  opacity: 1;
  transform: translateY(-1px);
}

.tooltip .tooltip-inner{
  direction: rtl;
  text-align: right;
  max-width: 320px;
  font-weight: 700;
}

/* Scanner chips when they contain help icon */
.nx-chip{
  display: inline-flex;
  align-items: center;
  gap: .35rem;
}

/* Modal style harmony */
.nx-modal{
  border-radius: 1.25rem;
  border: 1px solid rgba(203,213,225,.85);
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(10px);
}

.nx-modal .modal-header,
.nx-modal .modal-footer{
  border-color: rgba(203,213,225,.65);
}


/* ─────────────────────────────────────────────────────────
   Skeleton Loading (Technical)
   ───────────────────────────────────────────────────────── */

@keyframes nxShimmer{
  0%{ background-position: 100% 0; }
  100%{ background-position: 0 0; }
}

.nx-skel-line,
.nx-skel-box,
.nx-skel-chip{
  background: linear-gradient(90deg,
    rgba(148,163,184,.18) 25%,
    rgba(148,163,184,.34) 37%,
    rgba(148,163,184,.18) 63%);
  background-size: 400% 100%;
  animation: nxShimmer 1.2s ease-in-out infinite;
  border-radius: 12px;
}

.nx-skel-line{
  height: 12px;
}

.nx-skel-box{
  width: 100%;
  border-radius: 16px;
}

.nx-ta-kpi-skeleton{
  display:flex;
  gap: 10px;
  flex-wrap: wrap;
}

.nx-ta-kpi-skeleton .nx-skel-chip{
  height: 84px;
  flex: 1 1 160px;
  min-width: 160px;
  border-radius: 16px;
}

.nx-ta-chart-skeleton{
  padding: 6px 0 0 0;
}

.nx-ta-side-skeleton .nx-skel-box{
  border-radius: 16px;
}

/* Scanner: hide table while skeleton visible */
#nx-ta-scan-loading:not(.d-none) ~ .nx-ta-scan-tablewrap{
  display:none;
}

/* Auto levels toggle */
.nx-auto-levels-toggle{
  display:flex;
  align-items:center;
  gap: 8px;
  padding: 6px 10px;
  border: 1px solid var(--nx-ta-border);
  border-radius: 999px;
  background: rgba(255,255,255,.75);
  backdrop-filter: blur(8px);
  margin: 0;
  padding-inline-start: 10px;
  padding-inline-end: 10px;
}
.nx-auto-levels-toggle .form-check-input{
  cursor:pointer;
  float: none;
  margin: 0;
}
.nx-auto-levels-toggle .form-check-label{
  margin: 0;
  cursor: pointer;
  user-select: none;
}

/* Indicator legend (SMA/BB...) */
.nx-ta-indicators{
  display: flex;
  flex-wrap: wrap;
  gap: .45rem;
  align-items: center;
}
@media (max-width: 575.98px){
  .nx-ta-indicators{
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 4px;
  }
  .nx-ta-indicators::-webkit-scrollbar{ height: 5px; }
}

.nx-ind-btn{
  border: 1px solid rgba(203,213,225,.75);
  background: rgba(255,255,255,.78);
  border-radius: 999px;
  padding: 6px 10px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: .78rem;
  font-weight: 900;
  color: rgba(30,41,59,.95);
  line-height: 1;
  transition: transform .12s ease, opacity .12s ease;
}
.nx-ind-btn:hover{ transform: translateY(-1px); }
.nx-ind-btn:focus{ outline: none; box-shadow: 0 0 0 .2rem rgba(37,99,235,.18); }
.nx-ind-btn .dot{ width: 10px; height: 10px; border-radius: 999px; display: inline-block; }
.nx-ind-btn .dot.sma20{ background: #2563eb; }
.nx-ind-btn .dot.sma50{ background: #7c3aed; }
.nx-ind-btn .dot.sma200{ background: #64748b; }
.nx-ind-btn .dot.bb{ background: #f59e0b; }
.nx-ind-btn .val{ opacity: .86; font-variant-numeric: tabular-nums; font-feature-settings: "tnum" 1; }
.nx-ind-btn.is-off{
  opacity: .45;
  background: rgba(248,250,252,.55);
}
.nx-ind-btn.is-off .dot{ background: transparent; border: 2px solid rgba(71,85,105,.75); }

/* Risk/Reward gauge */
.nx-rr-wrap{ border-top: 1px dashed rgba(203,213,225,.75); padding-top: .75rem; }
.nx-rr-top{ display:flex; align-items:center; justify-content: space-between; gap: 12px; }
.nx-rr-gauge{ margin-top: .45rem; }
.nx-rr-track{
  position: relative;
  height: 12px;
  border-radius: 999px;
  overflow: visible;
  --rr-ok-pct: 37.5%;
}
.nx-rr-track-inner{
  position: absolute;
  inset: 0;
  border-radius: 999px;
  /* Smooth (continuous) risk→reward gradient: very red at start, very green at end */
  background: linear-gradient(90deg,
    rgba(239,68,68,.95) 0%,
    rgba(245,158,11,.95) 32%,
    rgba(250,204,21,.95) 52%,
    rgba(132,204,22,.95) 72%,
    rgba(34,197,94,.95) 100%
  );
  overflow: hidden;
}
.nx-rr-threshold{
  position: absolute;
  top: -2px;
  bottom: -2px;
  left: var(--rr-ok-pct);
  width: 2px;
  background: rgba(15,23,42,.55);
  border-radius: 2px;
  opacity: .85;
}
.nx-rr-threshold .nx-rr-th-label{
  position: absolute;
  top: -28px;
  left: 50%;
  transform: translateX(-50%);
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(255,255,255,.92);
  border: 1px solid rgba(203,213,225,.9);
  color: rgba(30,41,59,.92);
  font-size: .7rem;
  white-space: nowrap;
  box-shadow: 0 10px 22px rgba(15,23,42,.12);
}
.nx-rr-threshold .nx-rr-th-label .t{ opacity: .8; }
.nx-rr-pointer{
  position: absolute;
  top: 50%;
  width: 12px;
  height: 12px;
  border-radius: 999px;
  background: rgba(255,255,255,.95);
  border: 2px solid rgba(15,23,42,.55);
  transform: translate(-50%, -50%);
  box-shadow: 0 8px 20px rgba(15,23,42,.22);
}
.nx-rr-ticks{ display:flex; justify-content: space-between; margin-top: .35rem; font-size: .7rem; color: rgba(71,85,105,.85); }
.nx-rr-zones{ display:flex; margin-top: .25rem; font-size: .7rem; color: rgba(71,85,105,.85); }
.nx-rr-zones .z{ opacity: .92; }
.nx-rr-zones .z-bad{ flex: 0 0 var(--rr-ok-pct); }
.nx-rr-zones .z-good{ flex: 1 1 auto; text-align: end; }
.nx-rr-min{ font-variant-numeric: tabular-nums; font-feature-settings: "tnum" 1; }

.nx-rr-hint{ border-top: 1px dashed rgba(203,213,225,.75); padding-top: .6rem; }
.nx-rr-hint-row{ display:flex; align-items:center; justify-content: space-between; gap: 10px; }
.nx-rr-pill{ display:inline-flex; align-items:center; gap: 6px; padding: .2rem .55rem; border-radius: 999px; font-size: .75rem; font-weight: 800; letter-spacing: -.2px; white-space: nowrap; }
.nx-rr-pill.good{ background: rgba(34,197,94,.14); border: 1px solid rgba(34,197,94,.35); color: rgba(22,101,52,.96); }
.nx-rr-pill.bad{ background: rgba(239,68,68,.12); border: 1px solid rgba(239,68,68,.35); color: rgba(153,27,27,.96); }
.nx-rr-pill.neu{ background: rgba(245,158,11,.12); border: 1px solid rgba(245,158,11,.35); color: rgba(120,53,15,.96); }
.nx-rr-msg{ color: rgba(30,41,59,.92); line-height: 1.55; }


/* ─────────────────────────────────────────────────────────
   Lightweight toasts (used by TA buttons)
   ───────────────────────────────────────────────────────── */

.nx-ta-toast-stack{
  position: fixed;
  bottom: 18px;
  inset-inline-end: 18px;
  z-index: 3000;
  width: min(420px, calc(100vw - 28px));
  display: flex;
  flex-direction: column;
  gap: .5rem;
  pointer-events: none;
}

.nx-ta-toast-stack .nx-toast{
  pointer-events: none;
  padding: .7rem .9rem;
  border-radius: 1.15rem;
  border: 1px solid rgba(255,255,255,.18);
  color: #fff;
  font-weight: 900;
  background: rgba(15,23,42,.92);
  box-shadow: 0 18px 55px rgba(15,23,42,.18);
  opacity: 0;
  transform: translateY(10px);
  transition: opacity .18s ease, transform .18s ease;
}

.nx-ta-toast-stack .nx-toast.show{
  opacity: 1;
  transform: translateY(0);
}

.nx-ta-toast-stack .nx-toast-info{ background: rgba(37,99,235,.92); }
.nx-ta-toast-stack .nx-toast-success{ background: rgba(22,163,74,.92); }
.nx-ta-toast-stack .nx-toast-warning{
  background: rgba(234,179,8,.92);
  color: rgba(15,23,42,.95);
  border-color: rgba(15,23,42,.12);
}
.nx-ta-toast-stack .nx-toast-danger{ background: rgba(220,38,38,.92); }


 /* برای حذف کردن علامت سوال زمانی که تولتیپ میخوایم ببینیم */
[data-bs-toggle="tooltip"],
[data-bs-toggle="tooltip"] *,
.nx-compact-number,
.nx-compact-number *,
.tooltip-trigger,
.tooltip-trigger *,
.has-tooltip,
.has-tooltip * {
  cursor: default !important;
}
/* Freemium + SEO landing refinements */
.nx-technical-landing-page .nx-ta-landing-hero .nx-pm-lead{max-width:760px;}

.nx-ta-terminal .nx-pm-ticker-row strong{color:#0f766e;}
.nx-ta-public-table thead{background:linear-gradient(90deg, rgba(17,157,255,.18), rgba(34,197,94,.12)); color:#1e293b;}
.nx-ta-access-banner{
  display:flex; align-items:center; justify-content:space-between; gap:1rem; flex-wrap:wrap;
  border:1px solid rgba(37,99,235,.16); background:linear-gradient(135deg, rgba(239,246,255,.95), rgba(248,250,252,.98));
  border-radius:20px; padding:1rem 1.15rem; box-shadow:0 16px 45px rgba(15,23,42,.07);
}
.nx-ta-symbol-link,
.nx-ta-symbol-link:hover,
.nx-ta-symbol-link:focus,
.nx-ta-symbol-link:active,
.nx-ta-symbol-link:visited {
  display: inline-flex;
  flex-direction: column;
  gap: 2px;
  color: #0f172a;
  text-decoration: none !important;
  border-bottom: 0 !important;
  box-shadow: none !important;
}

.nx-ta-symbol-link:hover {
  color: #2563eb;
  transform: translateX(-2px);
}

.nx-ta-symbol-link *,
.nx-ta-symbol-link:hover *,
.nx-ta-symbol-link:focus * {
  text-decoration: none !important;
  border-bottom: 0 !important;
}
.nx-ta-access-banner-soft{background:linear-gradient(135deg, rgba(236,253,245,.95), rgba(248,250,252,.98)); border-color:rgba(16,185,129,.20);}
.nx-ta-lock-icon{width:42px;height:42px;display:inline-flex;align-items:center;justify-content:center;border-radius:15px;background:rgba(37,99,235,.10);color:#1d4ed8;flex:0 0 42px;}
.nx-ta-access-banner p{font-size:.88rem;color:#64748b;line-height:1.9;}
.nx-ta-locked-value{display:inline-flex;align-items:center;justify-content:center;min-height:28px;padding:.2rem .5rem;border-radius:999px;background:rgba(241,245,249,.95);color:#334155!important;font-weight:700;cursor:pointer;border:1px solid rgba(148,163,184,.28);white-space:nowrap;font-size:.82rem;}
.nx-ta-locked-value:hover,.nx-ta-open-access:hover,.nx-scan-locked-action:hover{filter:brightness(.98);transform:translateY(-1px);}
.nx-ta-access-locked .nx-meter .bar .fill{width:0!important;opacity:.25;}
.nx-ta-access-locked .nx-ta-chart-osc{position:relative;}
.nx-ta-access-locked .nx-ta-premium-disabled{opacity:.82;}
.nx-locked-cta{display:inline-flex;align-items:center;justify-content:center;gap:.35rem;border:1px solid rgba(37,99,235,.18);background:rgba(37,99,235,.07);color:#1d4ed8;border-radius:999px;padding:.25rem .65rem;font-weight:800;font-size:.82rem;text-decoration:none;cursor:pointer;}
.nx-scan-locked-action{font-weight:800;border-style:dashed!important;}
.nx-ta-scanner-locked .nx-scan-table tbody tr:nth-child(n+4){position:relative;}
.nx-pro-feature-pill{display:inline-flex;align-items:center;gap:.35rem;border:1px solid rgba(148,163,184,.22);border-radius:999px;padding:.35rem .6rem;background:#fff;font-size:.82rem;font-weight:700;color:#334155;}
.nx-pro-modal .nx-pro-modal-hero{background:linear-gradient(135deg,#0f172a,#1d4ed8);color:#fff;border-radius:var(--bs-modal-border-radius) var(--bs-modal-border-radius) 0 0;}
.nx-pro-modal .nx-pro-icon{width:48px;height:48px;border-radius:16px;display:inline-flex;align-items:center;justify-content:center;background:rgba(255,255,255,.14);}
@media (max-width: 768px){
  .nx-ta-access-banner{align-items:stretch;}
  .nx-ta-access-banner .btn{width:100%;}
  .nx-ta-public-table{font-size:12px;}
}
