@import url("theme.css");

:root {
  --bg: var(--fx-bg);
  --surface: var(--fx-surface);
  --surface2: var(--fx-bg-mid);
  --border: var(--fx-border-subtle);
  --frame-border: var(--fx-border);
  --frame-border-strong: var(--fx-border-strong);
  --frame-white: var(--fx-text);
  --frame-white-dim: var(--fx-text-muted);
  --text: var(--fx-text);
  --muted: var(--fx-text-muted);
  --buy: var(--fx-green);
  --buy-dark: var(--fx-green-dark);
  --sell: var(--fx-sell);
  --orange: var(--fx-orange);
  --orange-dark: var(--fx-orange-mid);
  --gold: var(--fx-orange);
  --teal: var(--fx-teal);
  --accent: var(--fx-teal);
  --radius: var(--fx-radius);
  --shadow: var(--fx-shadow);
  --panel-glow: 0 0 0 1px rgba(76, 194, 191, 0.1) inset;
}

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

body,
body.app-body {
  font-family: "Source Sans Pro", system-ui, sans-serif;
  background-color: #000;
  color: var(--text);
  min-height: 100vh;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

.app {
  position: relative;
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 1rem 1.5rem 2rem;
  min-height: 100vh;
}

.app-bg {
  position: fixed;
  inset: 0;
  background: #000;
  z-index: 0;
  pointer-events: none;
}

.app-bg::before,
.app-bg::after {
  display: none;
}

.app > *:not(.app-bg) {
  position: relative;
  z-index: 1;
}

/* Panel — trên nền đen */
.panel-frame {
  position: relative;
  background: #0c0c0c;
  border: 1px solid rgba(76, 194, 191, 0.2);
  border-radius: 16px;
  box-shadow:
    0 8px 32px rgba(0, 0, 0, 0.6),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.panel-frame::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  z-index: 3;
  border-radius: 16px 16px 0 0;
  background: linear-gradient(90deg, #33d5d5, rgb(0, 136, 79), #f49a3a);
  opacity: 0.75;
  pointer-events: none;
}

/* Topbar */
.topbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 1.15rem;
  margin-bottom: 1rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.brand-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: inherit;
}

.topbar-inner {
  display: contents;
}

.btn-user {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 0.75rem;
  border: 1px solid var(--frame-border);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--frame-white-dim);
  font-family: inherit;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
}

.btn-user:hover {
  border-color: var(--teal);
  background: rgba(76, 194, 191, 0.1);
  color: var(--fx-teal-light);
}

.btn-user-avatar {
  display: none;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  font-size: 0.78rem;
  font-weight: 800;
  color: #031018;
  background: linear-gradient(135deg, #33d5d5, #51da73);
  box-shadow: 0 2px 10px rgba(51, 213, 213, 0.35);
}

.btn-user-copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.15;
  text-align: left;
}

.btn-user-text {
  font-weight: 700;
  color: var(--frame-white);
}

.btn-user-plan {
  display: none;
  font-size: 0.58rem;
  font-weight: 600;
  color: var(--muted);
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.btn-ghost {
  display: inline-flex;
  align-items: center;
  padding: 0.55rem 0.9rem;
  border: 1px solid var(--frame-border);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--frame-white-dim);
  font-family: inherit;
  font-size: 0.8rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.btn-ghost:hover {
  border-color: var(--teal);
  color: var(--fx-teal-light);
  background: rgba(76, 194, 191, 0.08);
}

.topbar-mid {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.5rem 0.75rem;
}

.api-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.22rem 0.5rem;
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--frame-white-dim);
  border: 1px solid var(--frame-border);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
}

.api-pill.ok {
  color: var(--fx-teal-light);
  border-color: var(--fx-border-strong);
}

.api-pill.err {
  color: #fca5a5;
  border-color: rgba(239, 68, 68, 0.4);
}

.api-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--muted);
}

.api-pill.ok .api-dot {
  background: var(--teal);
  box-shadow: 0 0 8px var(--fx-teal-glow);
}

.api-pill.err .api-dot {
  background: var(--sell);
}

.session-pills {
  display: flex;
  gap: 0.25rem;
}

.session-pill {
  padding: 0.2rem 0.45rem;
  font-size: 0.55rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
  border: 1px solid transparent;
  border-radius: 6px;
  opacity: 0.45;
  transition: opacity 0.2s ease, background 0.2s ease;
}

.session-pill.active {
  opacity: 1;
  color: var(--frame-white);
  border-color: var(--frame-border-strong);
  background: rgba(255, 255, 255, 0.1);
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: #031018;
  background: linear-gradient(135deg, #33d5d5, #51da73);
  box-shadow: 0 4px 16px rgba(51, 213, 213, 0.35);
}

.brand h1 {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--frame-white);
  line-height: 1.1;
}

.brand-supper {
  color: #f49a3a;
}

.brand p {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--fx-teal-dim);
  letter-spacing: 0.04em;
}

.live-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.55rem;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--buy);
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.35);
  border-radius: 999px;
}

.live-pill.pulse {
  animation: livePulse 0.5s ease;
}

.live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--buy);
  animation: liveBlink 1.2s ease-in-out infinite;
}

@keyframes liveBlink {
  50% { opacity: 0.35; }
}

@keyframes livePulse {
  0% { box-shadow: 0 0 0 rgba(34, 197, 94, 0.5); }
  100% { box-shadow: 0 0 0 transparent; }
}

.spot-box {
  text-align: right;
}

.spot-label {
  display: block;
  font-size: 0.62rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.spot-value {
  display: block;
  font-size: 1.4rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  color: #fff;
  text-shadow: 0 0 24px rgba(51, 213, 213, 0.25);
}

.spot-value.tick {
  animation: priceTick 0.4s ease;
}

@keyframes priceTick {
  0% { text-shadow: 0 0 12px rgba(234, 179, 8, 0.6); }
}

.spot-meta {
  font-size: 0.68rem;
  color: var(--muted);
}

.btn-analyze,
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.65rem 1.35rem;
  border: none;
  border-radius: 999px;
  background: linear-gradient(90deg, #33d5d5, #51da73);
  color: #031018;
  font-family: inherit;
  font-size: 0.88rem;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 6px 24px rgba(51, 213, 213, 0.35);
}

.btn-analyze:hover,
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 32px rgba(51, 213, 213, 0.45);
}

.btn-analyze:disabled,
.btn-analyze.analyzing,
.btn-primary:disabled,
.btn-primary.analyzing {
  opacity: 0.75;
  cursor: wait;
  transform: none;
}

.btn-icon.spin {
  display: inline-block;
  animation: spin 0.7s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Dashboard grid */
.dashboard {
  display: grid;
  grid-template-columns: 1fr minmax(300px, 28vw);
  gap: 1.25rem;
  align-items: start;
  width: 100%;
}

.card {
  overflow: hidden;
}

.panel-frame > * {
  position: relative;
  z-index: 2;
}

.card-label {
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--fx-teal-dim);
  margin-bottom: 0.75rem;
}

.panel.analyzing {
  border-color: var(--frame-border-strong);
  box-shadow: var(--shadow), 0 0 0 1px rgba(255, 255, 255, 0.2), 0 0 24px rgba(255, 255, 255, 0.06);
}

.panel.chart-updated {
  animation: chartFlash 0.45s ease;
}

.panel.chart-live-pulse {
  animation: chartLiveGlow 0.5s ease;
}

.card-chart[hidden] {
  display: none !important;
}

@keyframes chartLiveGlow {
  0% { box-shadow: var(--shadow), var(--panel-glow); }
  40% {
    box-shadow:
      var(--shadow),
      0 0 0 1px rgba(255, 255, 255, 0.2) inset,
      0 0 20px rgba(255, 255, 255, 0.08);
  }
  100% { box-shadow: var(--shadow), var(--panel-glow); }
}

.chart-price.tick.up {
  color: #4ade80;
}

.chart-price.tick.down {
  color: #fb7185;
}

@keyframes chartFlash {
  50% { border-color: var(--gold); }
}

/* Signal card */
.card-signal {
  padding: 1.35rem 1.5rem 1.5rem;
}

.card-signal.signal-awaiting {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.card-signal.signal-awaiting .signal-hero {
  display: flex;
  flex: 1;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: min(26rem, 48vh);
  margin-bottom: 0;
  padding: 1.5rem 1rem 2rem;
}

.card-signal.signal-awaiting .signal-hero-visual,
.card-signal.signal-awaiting .signal-info,
.card-signal.signal-awaiting .rules {
  display: none !important;
}

.signal-awaiting {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 0.85rem;
  width: 100%;
  max-width: none;
  margin: 0 auto;
  padding: 2rem 1.75rem;
}

.card-signal.signal-awaiting .signal-awaiting {
  display: flex;
}

.signal-awaiting-title {
  font-size: clamp(1.35rem, 3.2vw, 1.9rem);
  font-weight: 800;
  color: var(--frame-white);
  letter-spacing: 0.02em;
}

.signal-awaiting-desc {
  max-width: 42rem;
  font-size: clamp(0.95rem, 1.5vw, 1.05rem);
  line-height: 1.6;
  color: var(--frame-white-dim);
}

.signal-awaiting-desc strong {
  color: var(--fx-teal-light);
  font-weight: 800;
}

.signal-hero-visual {
  display: contents;
}

.signal-hero-arrow {
  display: contents;
}

.signal-hero {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 1.5rem;
  margin-bottom: 1.35rem;
  padding-right: min(252px, 44vw);
}

.signal-info {
  flex: 1 1 12rem;
  min-width: 0;
}

.signal-side-img {
  position: absolute;
  top: 1.75rem;
  right: 1.5rem;
  width: min(248px, 42vw);
  height: auto;
  max-height: min(248px, 42vw);
  object-fit: contain;
  z-index: 4;
  pointer-events: none;
  animation: signalSideFloat 2.6s ease-in-out infinite;
  will-change: transform;
}

@keyframes signalSideFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-14px); }
}

@keyframes signalSideFloatCenter {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(-12px); }
}

.signal-side-img.sell {
  filter: drop-shadow(0 8px 24px rgba(239, 68, 68, 0.45));
  animation-duration: 2.4s;
}

.signal-side-img.buy {
  filter: drop-shadow(0 8px 24px rgba(34, 197, 94, 0.45));
  animation-duration: 2.8s;
}

@media (prefers-reduced-motion: reduce) {
  .signal-side-img {
    animation: none;
  }
}

/* Analyze effect: text-only, no background/no rectangle */
.analyze-screen {
  background: transparent !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}

.analyze-screen-bg,
.analyze-border-glow,
.analyze-scan,
.analyze-screen-sub,
.analyze-screen-pct,
.analyze-steps,
.analyze-screen-progress,
.analyze-screen-timer {
  display: none !important;
}

.analyze-screen-inner {
  width: min(260px, 72vw) !important;
  padding: 0.4rem 0 !important;
  border: none !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  transform: none !important;
}

.analyze-hero {
  display: block !important;
  width: 180px !important;
  height: 180px !important;
  margin: 0 auto 0.35rem !important;
  animation: analyzeOnlyRotate 7s linear infinite !important;
}

.analyze-hero::before,
.analyze-hero::after {
  display: none !important;
}

.analyze-ring-track {
  stroke: rgba(255, 255, 255, 0.18) !important;
  stroke-width: 6 !important;
}

.analyze-ring-fill {
  stroke: rgba(255, 255, 255, 0.92) !important;
  stroke-width: 6 !important;
}

.analyze-ring-orbit {
  stroke: rgba(255, 255, 255, 0.52) !important;
  stroke-width: 1.3 !important;
  stroke-dasharray: 6 8 !important;
  animation: analyzeOnlyOrbit 3.4s linear infinite !important;
}

.analyze-hero-glow {
  display: block !important;
  inset: 10% !important;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.14) 0%, rgba(255, 255, 255, 0) 70%) !important;
}

.analyze-screen-step {
  display: block !important;
  margin: 0 !important;
  min-height: 0 !important;
  font-size: 1.4rem !important;
  font-weight: 800 !important;
  color: #ffffff !important;
  letter-spacing: 0.04em !important;
  text-transform: uppercase !important;
  text-align: center !important;
}

.analyze-screen-step::before {
  content: "PHÂN TÍCH";
}

@keyframes analyzeOnlyRotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes analyzeOnlyOrbit {
  from { transform: rotate(0deg); }
  to { transform: rotate(-360deg); }
}

/* Analyze Screen v6 - full cinematic override */
.analyze-screen {
  background:
    radial-gradient(circle at 20% 20%, rgba(56, 189, 248, 0.16), transparent 35%),
    radial-gradient(circle at 80% 75%, rgba(34, 197, 94, 0.16), transparent 38%),
    linear-gradient(180deg, rgba(2, 8, 12, 0.88), rgba(1, 4, 8, 0.92)) !important;
  backdrop-filter: blur(6px) !important;
  -webkit-backdrop-filter: blur(6px) !important;
}

.analyze-screen-inner {
  width: min(520px, 92vw) !important;
  padding: 2rem 1.4rem 1.4rem !important;
  border-radius: 24px !important;
  border: 1px solid rgba(148, 163, 184, 0.3) !important;
  background: linear-gradient(180deg, rgba(7, 14, 24, 0.94), rgba(5, 10, 18, 0.96)) !important;
  box-shadow:
    0 28px 80px rgba(0, 0, 0, 0.62),
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 0 40px rgba(56, 189, 248, 0.18) !important;
}

.analyze-screen-bg,
.analyze-border-glow,
.analyze-scan,
.analyze-screen-sub,
.analyze-screen-pct,
.analyze-steps,
.analyze-screen-progress,
.analyze-screen-timer {
  display: none !important;
}

.analyze-hero {
  width: 220px !important;
  height: 220px !important;
  margin: 0 auto 1rem !important;
  animation: analyzeCineSpin 8s linear infinite !important;
}

.analyze-hero::before,
.analyze-hero::after {
  content: "";
  position: absolute;
  inset: -10px;
  border-radius: 50%;
}

.analyze-hero::before {
  border: 1px dashed rgba(148, 163, 184, 0.35);
  animation: analyzeCineOrbit 6s linear infinite;
}

.analyze-hero::after {
  border: 1px solid rgba(255, 255, 255, 0.12);
  transform: scale(0.86);
}

.analyze-ring-track {
  stroke: rgba(148, 163, 184, 0.2) !important;
  stroke-width: 7 !important;
}

.analyze-ring-fill {
  stroke: #e2e8f0 !important;
  stroke-width: 7 !important;
  filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.28)) !important;
}

.analyze-ring-orbit {
  stroke: rgba(56, 189, 248, 0.58) !important;
  stroke-width: 1.5 !important;
  stroke-dasharray: 6 8 !important;
  animation: analyzeCineOrbitReverse 3.4s linear infinite !important;
}

.analyze-hero-glow {
  display: block !important;
  inset: 8% !important;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.22) 0%, rgba(56, 189, 248, 0) 72%) !important;
}

.analyze-brand-mark {
  display: none !important;
}

.analyze-screen-step {
  display: block !important;
  margin: 0 !important;
  text-align: center !important;
  font-size: 1.55rem !important;
  font-weight: 800 !important;
  letter-spacing: 0.08em !important;
  color: #f8fafc !important;
  text-transform: uppercase !important;
  text-shadow: 0 0 18px rgba(56, 189, 248, 0.35) !important;
}

.analyze-screen-step::before {
  content: "PHÂN TÍCH";
}

@keyframes analyzeCineSpin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes analyzeCineOrbit {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes analyzeCineOrbitReverse {
  from { transform: rotate(0deg); }
  to { transform: rotate(-360deg); }
}

/* Analyze Screen v7 - dark tech HUD premium */
.analyze-screen {
  background:
    radial-gradient(circle at 16% 18%, rgba(34, 211, 238, 0.12), transparent 34%),
    radial-gradient(circle at 84% 78%, rgba(16, 185, 129, 0.1), transparent 36%),
    linear-gradient(180deg, rgba(2, 8, 14, 0.74), rgba(1, 5, 10, 0.84)) !important;
  backdrop-filter: blur(8px) saturate(1.08) !important;
  -webkit-backdrop-filter: blur(8px) saturate(1.08) !important;
}

body.analyze-lock .app {
  filter: brightness(0.8) contrast(1.03) !important;
}

.analyze-screen-inner {
  width: min(500px, 92vw) !important;
  padding: 1.25rem 1.2rem 1rem !important;
  border-radius: 18px !important;
  border: 1px solid rgba(56, 189, 248, 0.28) !important;
  background:
    linear-gradient(180deg, rgba(6, 14, 24, 0.94), rgba(4, 10, 18, 0.96)) !important;
  box-shadow:
    0 24px 60px rgba(0, 0, 0, 0.58),
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 0 36px rgba(34, 211, 238, 0.15) !important;
}

.analyze-border-glow {
  display: block !important;
  opacity: 1 !important;
  border-radius: 18px !important;
  box-shadow:
    0 0 0 1px rgba(56, 189, 248, 0.32),
    0 0 22px rgba(34, 211, 238, 0.22) !important;
}

.analyze-screen-bg {
  display: block !important;
}

.analyze-scan {
  display: block !important;
  height: 2px !important;
  top: 0 !important;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(56, 189, 248, 0.9),
    rgba(255, 255, 255, 0.9),
    rgba(16, 185, 129, 0.85),
    transparent
  ) !important;
  opacity: 0.75 !important;
  animation: analyzeHudScan 2.6s cubic-bezier(0.25, 0.1, 0.2, 0.98) infinite !important;
}

@keyframes analyzeHudScan {
  0% { top: 0; opacity: 0; }
  10% { opacity: 0.8; }
  90% { opacity: 0.8; }
  100% { top: 100%; opacity: 0; }
}

.analyze-hero {
  display: block !important;
  width: 170px !important;
  height: 170px !important;
  margin: 0 auto 0.55rem !important;
  animation: analyzeHudSpin 7.2s linear infinite !important;
}

.analyze-hero::before,
.analyze-hero::after {
  display: none !important;
}

.analyze-ring-track {
  stroke: rgba(148, 163, 184, 0.24) !important;
  stroke-width: 6 !important;
}

.analyze-ring-fill {
  stroke: #e2e8f0 !important;
  stroke-width: 6 !important;
  filter: drop-shadow(0 0 10px rgba(34, 211, 238, 0.35)) !important;
}

.analyze-ring-orbit {
  stroke: rgba(34, 211, 238, 0.62) !important;
  stroke-width: 1.3 !important;
  stroke-dasharray: 5 8 !important;
  animation: analyzeHudOrbit 3.2s linear infinite !important;
}

.analyze-hero-glow {
  display: block !important;
  inset: 10% !important;
  opacity: 1 !important;
  background: radial-gradient(circle, rgba(34, 211, 238, 0.24) 0%, rgba(16, 185, 129, 0.08) 42%, transparent 72%) !important;
}

@keyframes analyzeHudSpin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes analyzeHudOrbit {
  from { transform: rotate(0deg); }
  to { transform: rotate(-360deg); }
}

.analyze-brand-mark,
.analyze-screen-sub,
.analyze-steps,
.analyze-screen-timer {
  display: none !important;
}

.analyze-screen-pct {
  display: flex !important;
  margin-bottom: 0.45rem !important;
  justify-content: center !important;
  color: #e2e8f0 !important;
  font-size: 2rem !important;
  text-shadow:
    0 0 14px rgba(34, 211, 238, 0.3),
    0 0 30px rgba(16, 185, 129, 0.16) !important;
}

.analyze-screen-step {
  display: block !important;
  margin: 0 0 0.55rem !important;
  text-align: center !important;
  font-size: 0.82rem !important;
  font-weight: 700 !important;
  letter-spacing: 0.12em !important;
  text-transform: uppercase !important;
  color: rgba(186, 230, 253, 0.95) !important;
  text-shadow:
    0 0 10px rgba(34, 211, 238, 0.35),
    0 0 18px rgba(16, 185, 129, 0.2) !important;
}

.analyze-screen-step::before {
  content: none !important;
}

.analyze-screen-progress {
  display: block !important;
  height: 8px !important;
  margin-bottom: 0 !important;
  background: rgba(2, 6, 23, 0.55) !important;
  border: 1px solid rgba(56, 189, 248, 0.3) !important;
}

.analyze-screen-bar {
  width: 0% !important;
  height: 100% !important;
  border-radius: inherit !important;
  background: linear-gradient(90deg, #22d3ee, #38bdf8, #10b981) !important;
  box-shadow: 0 0 10px rgba(34, 211, 238, 0.35) !important;
}

/* Single stable effect theme (prevents random style switching) */
body.analyze-lock.analyze-stable .analyze-screen {
  background: #000 !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}

body.analyze-lock.analyze-stable .analyze-screen-bg,
body.analyze-lock.analyze-stable .analyze-screen-pct,
body.analyze-lock.analyze-stable .analyze-steps,
body.analyze-lock.analyze-stable .analyze-screen-progress,
body.analyze-lock.analyze-stable .analyze-screen-timer,
body.analyze-lock.analyze-stable .analyze-screen-sub,
body.analyze-lock.analyze-stable .analyze-brand-mark {
  display: none !important;
}

body.analyze-lock.analyze-stable .analyze-screen-inner {
  width: min(760px, 92vw) !important;
  padding: 2.2rem 0.8rem !important;
  border: none !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body.analyze-lock.analyze-stable .analyze-hero {
  width: 110px !important;
  height: 110px !important;
  margin: 0 auto 0.35rem !important;
  animation: analyzeStableSpin 5.2s linear infinite !important;
}

body.analyze-lock.analyze-stable .analyze-ring-track {
  stroke: rgba(255, 255, 255, 0.2) !important;
  stroke-width: 4 !important;
}

body.analyze-lock.analyze-stable .analyze-ring-fill {
  stroke: rgba(255, 255, 255, 0.95) !important;
  stroke-width: 4 !important;
  filter: none !important;
}

body.analyze-lock.analyze-stable .analyze-ring-orbit {
  stroke: rgba(255, 255, 255, 0.45) !important;
  stroke-width: 1.1 !important;
  stroke-dasharray: 5 8 !important;
  animation: analyzeStableOrbit 2.8s linear infinite !important;
}

body.analyze-lock.analyze-stable .analyze-screen-step {
  display: block !important;
  margin: 0 !important;
  text-align: center !important;
  font-size: 1.85rem !important;
  font-weight: 900 !important;
  letter-spacing: 0.2em !important;
  color: #fff !important;
  text-transform: uppercase !important;
  text-shadow: none !important;
}

@keyframes analyzeStableSpin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes analyzeStableOrbit {
  from { transform: rotate(0deg); }
  to { transform: rotate(-360deg); }
}

/* Absolute override mode: guaranteed visibly different */
.analyze-screen.analyze-plain-mode .analyze-screen-inner {
  width: min(760px, 92vw) !important;
  padding: 2rem 0.8rem !important;
  border: none !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.analyze-screen.analyze-plain-mode .analyze-screen-inner > * {
  display: none !important;
}

.analyze-screen.analyze-plain-mode #analyzePlain {
  display: block !important;
  position: relative;
  width: 100%;
  text-align: center;
  padding: 1.15rem 0 0.85rem;
}

.analyze-screen.analyze-plain-mode #analyzePlain::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: min(620px, 82vw);
  height: 180px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.16), rgba(16, 185, 129, 0.08) 45%, transparent 72%);
  filter: blur(18px);
  pointer-events: none;
}

.analyze-screen.analyze-plain-mode .analyze-plain-text {
  display: inline-block;
  position: relative;
  z-index: 1;
  font-size: clamp(2.2rem, 4.4vw, 3.35rem);
  font-weight: 900;
  letter-spacing: 0.2em;
  color: #f9fafb;
  text-transform: uppercase;
  text-shadow:
    0 1px 0 rgba(15, 23, 42, 0.65),
    0 0 16px rgba(56, 189, 248, 0.5),
    0 0 34px rgba(16, 185, 129, 0.3);
}

.analyze-screen.analyze-plain-mode .analyze-plain-scan {
  display: block;
  position: relative;
  z-index: 1;
  width: min(560px, 74vw);
  height: 4px;
  margin: 0.9rem auto 0;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, #22d3ee, #ffffff, #10b981, transparent);
  box-shadow:
    0 0 12px rgba(56, 189, 248, 0.45),
    0 0 26px rgba(16, 185, 129, 0.22);
  animation: analyzePlainSweep 1.9s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

/* Analyze mode: full black background, hide main UI */
body.analyze-lock .app {
  opacity: 0 !important;
}

.analyze-screen {
  background: #000 !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}

@keyframes analyzePlainSweep {
  0% { transform: translateX(-20px); opacity: 0.2; }
  50% { transform: translateX(20px); opacity: 1; }
  100% { transform: translateX(-20px); opacity: 0.2; }
}

/* Force single effect theme (v10) */
body.analyze-lock.analyze-v10 .analyze-screen {
  background:
    radial-gradient(circle at 18% 20%, rgba(56, 189, 248, 0.16), transparent 34%),
    radial-gradient(circle at 82% 78%, rgba(16, 185, 129, 0.14), transparent 36%),
    linear-gradient(180deg, rgba(1, 10, 18, 0.86), rgba(1, 6, 12, 0.92)) !important;
  backdrop-filter: blur(10px) !important;
  -webkit-backdrop-filter: blur(10px) !important;
}

body.analyze-lock.analyze-v10 .analyze-screen-inner {
  width: min(480px, 92vw) !important;
  padding: 1.4rem 1.25rem 1rem !important;
  border-radius: 18px !important;
  border: 1px solid rgba(56, 189, 248, 0.34) !important;
  background: linear-gradient(180deg, rgba(7, 16, 28, 0.95), rgba(5, 11, 22, 0.97)) !important;
  box-shadow:
    0 26px 70px rgba(0, 0, 0, 0.62),
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 0 36px rgba(34, 211, 238, 0.18) !important;
}

body.analyze-lock.analyze-v10 .analyze-screen-bg,
body.analyze-lock.analyze-v10 .analyze-steps,
body.analyze-lock.analyze-v10 .analyze-screen-sub,
body.analyze-lock.analyze-v10 .analyze-screen-timer {
  display: none !important;
}

body.analyze-lock.analyze-v10 .analyze-brand-mark.lp-logo {
  display: flex !important;
  flex-direction: row !important;
  gap: 0.7rem !important;
}

body.analyze-lock.analyze-v10 .analyze-brand-mark.lp-logo .lp-logo__mark {
  width: 2.4rem !important;
  height: 2.4rem !important;
  font-size: 0.7rem !important;
}

body.analyze-lock.analyze-v10 .analyze-brand-mark.lp-logo .lp-logo__text {
  font-size: 1.65rem !important;
  font-weight: 800 !important;
  letter-spacing: -0.03em !important;
  color: #f8fafc !important;
  text-shadow:
    0 2px 0 rgba(2, 6, 23, 0.7),
    0 0 16px rgba(61, 158, 122, 0.34) !important;
}

body.analyze-lock.analyze-v10 .analyze-brand-mark.lp-logo .lp-logo__text em {
  color: var(--lp-green-light) !important;
}

body.analyze-lock.analyze-v10 .analyze-hero {
  width: 170px !important;
  height: 170px !important;
  margin: 0 auto 0.55rem !important;
  animation: analyzeV10Spin 7.2s linear infinite !important;
}

body.analyze-lock.analyze-v10 .analyze-ring-track {
  stroke: rgba(148, 163, 184, 0.24) !important;
  stroke-width: 6 !important;
}

body.analyze-lock.analyze-v10 .analyze-ring-fill {
  stroke: #e2e8f0 !important;
  stroke-width: 6 !important;
  filter: drop-shadow(0 0 10px rgba(34, 211, 238, 0.34)) !important;
}

body.analyze-lock.analyze-v10 .analyze-ring-orbit {
  stroke: rgba(34, 211, 238, 0.62) !important;
  stroke-width: 1.3 !important;
  stroke-dasharray: 6 8 !important;
  animation: analyzeV10Orbit 3.2s linear infinite !important;
}

body.analyze-lock.analyze-v10 .analyze-screen-pct {
  display: flex !important;
  justify-content: center !important;
  margin-bottom: 0.45rem !important;
}

body.analyze-lock.analyze-v10 .analyze-screen-step {
  display: block !important;
  margin: 0 !important;
  text-align: center !important;
  font-size: 0.84rem !important;
  font-weight: 700 !important;
  letter-spacing: 0.12em !important;
  color: rgba(186, 230, 253, 0.95) !important;
  text-transform: uppercase !important;
}

@keyframes analyzeV10Spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes analyzeV10Orbit {
  from { transform: rotate(0deg); }
  to { transform: rotate(-360deg); }
}

/* Hard override visual: V11 text + scan only */
body.analyze-lock.analyze-v11 .analyze-screen {
  background: rgba(0, 0, 0, 0.72) !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}

body.analyze-lock.analyze-v11 .analyze-screen-inner {
  width: min(760px, 92vw) !important;
  padding: 2.2rem 1rem !important;
  border: none !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body.analyze-lock.analyze-v11 .analyze-brand-mark,
body.analyze-lock.analyze-v11 .analyze-screen-pct,
body.analyze-lock.analyze-v11 .analyze-steps,
body.analyze-lock.analyze-v11 .analyze-screen-progress,
body.analyze-lock.analyze-v11 .analyze-screen-sub,
body.analyze-lock.analyze-v11 .analyze-screen-timer,
body.analyze-lock.analyze-v11 .analyze-hero {
  display: none !important;
}

/* Analyze Screen v9 - totally different clean hologram */
.analyze-screen {
  background:
    linear-gradient(180deg, rgba(2, 8, 12, 0.82), rgba(1, 4, 8, 0.9)) !important;
  backdrop-filter: blur(6px) !important;
  -webkit-backdrop-filter: blur(6px) !important;
}

body.analyze-lock .app {
  filter: brightness(0.76) !important;
}

.analyze-screen-inner {
  width: min(560px, 92vw) !important;
  padding: 1.7rem 1.3rem 1.15rem !important;
  border-radius: 20px !important;
  border: 1px solid rgba(148, 163, 184, 0.24) !important;
  background:
    repeating-linear-gradient(
      0deg,
      rgba(8, 14, 22, 0.94) 0px,
      rgba(8, 14, 22, 0.94) 8px,
      rgba(6, 12, 20, 0.94) 8px,
      rgba(6, 12, 20, 0.94) 16px
    ) !important;
  box-shadow:
    0 26px 70px rgba(0, 0, 0, 0.62),
    inset 0 1px 0 rgba(255, 255, 255, 0.05) !important;
}

.analyze-border-glow {
  display: block !important;
  opacity: 1 !important;
  border-radius: 20px !important;
  box-shadow: 0 0 0 1px rgba(125, 211, 252, 0.26) !important;
}

.analyze-screen-bg,
.analyze-scan,
.analyze-steps,
.analyze-screen-progress,
.analyze-screen-timer,
.analyze-screen-sub {
  display: none !important;
}

.analyze-hero {
  width: 190px !important;
  height: 190px !important;
  margin: 0 auto 0.8rem !important;
  animation: analyzeV9Spin 9s linear infinite !important;
}

.analyze-ring-track {
  stroke: rgba(148, 163, 184, 0.28) !important;
  stroke-width: 5 !important;
}

.analyze-ring-fill {
  stroke: rgba(255, 255, 255, 0.9) !important;
  stroke-width: 5 !important;
  filter: drop-shadow(0 0 10px rgba(125, 211, 252, 0.3)) !important;
}

.analyze-ring-orbit {
  stroke: rgba(125, 211, 252, 0.62) !important;
  stroke-width: 1.2 !important;
  stroke-dasharray: 4 8 !important;
  animation: analyzeV9Orbit 2.8s linear infinite !important;
}

.analyze-hero-glow {
  display: block !important;
  inset: 12% !important;
  opacity: 1 !important;
  background: radial-gradient(circle, rgba(125, 211, 252, 0.22) 0%, rgba(125, 211, 252, 0) 70%) !important;
}

.analyze-brand-mark.lp-logo {
  display: flex !important;
  flex-direction: row !important;
  gap: 0.65rem !important;
}

.analyze-brand-mark.lp-logo .lp-logo__mark {
  width: 2.1rem !important;
  height: 2.1rem !important;
  font-size: 0.62rem !important;
}

.analyze-brand-mark.lp-logo .lp-logo__text {
  font-size: 1.35rem !important;
  font-weight: 800 !important;
  color: #f8fafc !important;
  letter-spacing: -0.03em !important;
  text-shadow:
    0 2px 0 rgba(2, 6, 23, 0.65),
    0 0 14px rgba(61, 158, 122, 0.26) !important;
}

.analyze-brand-mark.lp-logo .lp-logo__text em {
  color: var(--lp-green-light) !important;
}

.analyze-screen-pct {
  display: none !important;
}

.analyze-screen-step {
  display: block !important;
  margin: 0 !important;
  text-align: center !important;
  font-size: 0.86rem !important;
  letter-spacing: 0.14em !important;
  text-transform: uppercase !important;
  color: rgba(226, 232, 240, 0.95) !important;
}

.analyze-screen-step::before {
  content: none !important;
}

@keyframes analyzeV9Spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes analyzeV9Orbit {
  from { transform: rotate(0deg); }
  to { transform: rotate(-360deg); }
}

.analyze-screen-bar::after {
  display: block !important;
  content: "" !important;
  position: absolute !important;
  right: 0 !important;
  top: 0 !important;
  bottom: 0 !important;
  width: 20px !important;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.55)) !important;
}

/* No blur mode: darken slightly only */
body.analyze-lock .app {
  filter: brightness(0.88) !important;
}

.analyze-screen {
  background: rgba(0, 0, 0, 0.28) !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}

/* Analyze effect: rotate-only, no text */
.analyze-screen {
  background: rgba(0, 0, 0, 0.32);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

.analyze-screen-inner {
  width: auto;
  padding: 0;
  border: none;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.analyze-brand-mark,
.analyze-screen-sub,
.analyze-screen-pct,
.analyze-steps,
.analyze-screen-progress,
.analyze-screen-timer {
  display: none !important;
}

.analyze-hero {
  width: 112px;
  height: 112px;
  margin: 0 auto 0.2rem;
  animation: analyzeOnlyRotate 7s linear infinite;
}

.analyze-hero::before,
.analyze-hero::after {
  display: none !important;
}

.analyze-ring-track {
  stroke: rgba(255, 255, 255, 0.2);
  stroke-width: 4;
}

.analyze-ring-fill {
  stroke: rgba(255, 255, 255, 0.92) !important;
  stroke-width: 4;
  filter: drop-shadow(0 0 6px rgba(255, 255, 255, 0.2));
}

.analyze-ring-orbit {
  stroke: rgba(255, 255, 255, 0.4);
  stroke-width: 1.1;
  stroke-dasharray: 5 8;
  animation: analyzeOnlyOrbit 3.2s linear infinite;
}

.analyze-hero-glow {
  inset: 10%;
  opacity: 1;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.14) 0%, rgba(255, 255, 255, 0) 70%);
}

.analyze-scan {
  display: none;
}

@keyframes analyzeOnlyRotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes analyzeOnlyOrbit {
  from { transform: rotate(0deg); }
  to { transform: rotate(-360deg); }
}

.signal-badge {
  flex-shrink: 0;
  margin-top: 3.5rem;
}

.signal-medallion {
  position: relative;
  width: min(148px, 32vw);
  height: min(148px, 32vw);
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, rgba(34, 197, 94, 0.25), rgba(2, 6, 33, 0.9) 65%);
  border: 2px solid rgba(34, 197, 94, 0.55);
  box-shadow:
    0 0 40px rgba(34, 197, 94, 0.25),
    inset 0 0 30px rgba(34, 197, 94, 0.08);
}

.signal-medallion.sell {
  background: radial-gradient(circle at 35% 30%, rgba(239, 68, 68, 0.28), rgba(2, 6, 33, 0.9) 65%);
  border-color: rgba(239, 68, 68, 0.6);
  box-shadow:
    0 0 40px rgba(239, 68, 68, 0.28),
    inset 0 0 30px rgba(239, 68, 68, 0.08);
}

.signal-medallion-ring {
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 1px dashed rgba(51, 213, 213, 0.45);
  animation: medallionSpin 12s linear infinite;
}

@keyframes medallionSpin {
  to { transform: rotate(360deg); }
}

.signal-medallion-text {
  position: relative;
  z-index: 1;
  font-size: clamp(1.75rem, 5vw, 2.25rem);
  font-weight: 800;
  letter-spacing: 0.08em;
  color: #4ade80;
  text-shadow: 0 0 20px rgba(74, 222, 128, 0.5);
}

.signal-medallion.sell .signal-medallion-text {
  color: #f87171;
  text-shadow: 0 0 20px rgba(248, 113, 113, 0.5);
}

.signal-badge.signal-reveal {
  animation: signalPop 0.55s cubic-bezier(0.34, 1.3, 0.64, 1);
}

@keyframes signalPop {
  0% { transform: scale(0.88); opacity: 0.6; }
  70% { transform: scale(1.04); }
  100% { transform: scale(1); opacity: 1; }
}

.signal-info .signal-title {
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 800;
  letter-spacing: 0.04em;
  margin-bottom: 0.75rem;
}

.signal-info .signal-title.buy { color: var(--buy); }
.signal-info .signal-title.sell { color: var(--sell); }

.signal-info .confidence-wrap {
  margin-bottom: 0.65rem;
}

.signal-info .confidence-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.65rem;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 0.3rem;
}

.signal-info .confidence-head strong {
  font-size: 0.85rem;
  font-variant-numeric: tabular-nums;
  color: var(--frame-white);
}

.signal-info .confidence-bar {
  height: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  overflow: hidden;
  border: 1px solid var(--frame-border);
}

.confidence-fill {
  height: 100%;
  width: 0%;
  border-radius: inherit;
  background: linear-gradient(90deg, rgb(0, 136, 79), #51da73, #33d5d5);
  transition: width 0.45s ease, background 0.3s ease;
}

.confidence-fill.sell {
  background: linear-gradient(90deg, #b91c1c, #ef4444, #fca5a5);
}

.signal-info .signal-meta {
  font-size: 0.68rem;
  color: var(--muted);
  margin-bottom: 0.55rem;
}

.signal-info .metrics-row {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.35rem;
  margin-bottom: 0.65rem;
}

.signal-info .metrics-row li {
  padding: 0.5rem 0.35rem;
  border-radius: 10px;
  text-align: center;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(76, 194, 191, 0.15);
}

.signal-info .metrics-row span {
  display: block;
  font-size: 0.55rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  margin-bottom: 0.15rem;
}

.signal-info .metrics-row strong {
  display: block;
  font-size: 0.72rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  color: var(--frame-white);
}

.signal-info .metrics-row strong.up { color: var(--buy); }
.signal-info .metrics-row strong.down { color: var(--sell); }
.signal-info .metrics-row strong.neutral { color: var(--gold); }

.risk-hint {
  margin-top: 0.55rem;
  font-size: 0.65rem;
  font-weight: 600;
  text-align: center;
  color: #94a3b8;
}

.limit-setups {
  margin-top: 0.6rem;
  display: grid;
  gap: 0.45rem;
}

.limit-setup-item {
  padding: 0.5rem 0.5rem 0.55rem;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid var(--border);
}

.limit-setup-item.buy {
  border-color: rgba(34, 197, 94, 0.35);
}

.limit-setup-item.sell {
  border-color: rgba(239, 68, 68, 0.35);
}

.limit-setup-item.selected {
  border-width: 2px;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.08) inset;
}

.limit-setup-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.2rem;
}

.limit-setup-head strong {
  font-size: 0.66rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.limit-setup-head em {
  font-style: normal;
  font-size: 0.62rem;
  color: var(--frame-white-dim);
}

.setup-mode-field {
  margin-top: 0.15rem;
}

.limit-levels-three {
  gap: 0.35rem;
}

@media (max-width: 800px) {
  .limit-levels-three {
    grid-template-columns: repeat(3, 1fr);
  }
}

.signal-info .checklist {
  list-style: none;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--muted);
}

.signal-info .checklist li {
  display: flex;
  align-items: flex-start;
  gap: 0.45rem;
  padding: 0.35rem 0;
  border-bottom: 1px solid var(--border);
}

.signal-info .checklist li:last-child {
  border-bottom: none;
}

.signal-info .checklist .mark {
  font-weight: 800;
  flex-shrink: 0;
}

.signal-info .checklist .ok .mark { color: var(--buy); }
.signal-info .checklist .ok { color: #cbd5e1; }
.signal-info .checklist .no .mark { color: var(--sell); }

.rules {
  position: relative;
  padding: 1rem 1.1rem;
  background: rgba(0, 0, 0, 0.28);
  border-radius: 14px;
  border: 1px solid rgba(76, 194, 191, 0.18);
}

.levels-heading {
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--frame-white-dim);
  text-align: center;
  margin: 0 0 0.55rem;
  line-height: 1.35;
}

.levels-three {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.4rem;
}

.price-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.3rem;
  padding: 0.75rem 0.5rem;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--border);
  text-align: center;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.price-card:hover {
  transform: translateY(-2px);
}

.price-card span {
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.06em;
}

.price-card strong {
  font-size: 0.92rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.price-card em {
  font-size: 0.58rem;
  font-style: normal;
  color: var(--muted);
  font-weight: 600;
}

.price-card.entry { border-color: rgba(51, 213, 213, 0.5); box-shadow: 0 4px 20px rgba(51, 213, 213, 0.12); }
.price-card.entry span { color: #33d5d5; }
.price-card.entry strong { color: #5eead4; font-size: 1rem; }

.price-card.sl { border-color: rgba(239, 68, 68, 0.45); }
.price-card.sl span { color: var(--sell); }
.price-card.sl strong { color: #fb7185; }

.price-card.tp { border-color: rgba(34, 197, 94, 0.45); }
.price-card.tp span { color: var(--buy); }
.price-card.tp strong { color: #4ade80; }

.level-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.4rem 0.55rem;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.25);
  font-size: 0.72rem;
}

.level-row span {
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.06em;
}

.level-row strong {
  font-size: 0.9rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.level-row.entry span { color: var(--accent); }
.level-row.entry strong { color: var(--accent); }

.level-row.sl span { color: var(--sell); }
.level-row.sl strong { color: #fb7185; }


/* Sidebar */
.sidebar {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.card-chart {
  padding: 0.75rem;
  overflow: hidden;
}

.card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--muted);
}

.card-head-chart {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 0;
}

.card-head em {
  font-style: normal;
  color: var(--frame-white);
}

.chart-candle-timer {
  font-size: 0.68rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--orange);
  letter-spacing: 0.02em;
}

.chart-candle-close {
  position: absolute;
  top: 0.45rem;
  right: 0.45rem;
  z-index: 6;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.1rem;
  padding: 0.45rem 0.65rem;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.88);
  border: 1px solid rgba(244, 154, 58, 0.45);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.55);
  pointer-events: none;
}

.chart-candle-close-kicker {
  font-size: 0.52rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--frame-white-dim);
}

.chart-candle-close-tf {
  font-size: 0.62rem;
  font-weight: 800;
  color: var(--fx-teal-light);
  letter-spacing: 0.06em;
}

.chart-candle-close-time {
  font-size: clamp(1.35rem, 4vw, 1.65rem);
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  color: var(--orange);
  text-shadow: 0 0 18px rgba(244, 154, 58, 0.35);
}

.chart-price {
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  color: var(--frame-white);
}

.chart-price.tick.up { color: var(--buy); }
.chart-price.tick.down { color: var(--sell); }

.chart-area {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  background: #000000;
  border: 1px solid var(--frame-border);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.chart-area.live-tick {
  animation: chartAreaPulse 0.55s ease;
}

.chart-area.live-tick.up {
  border-color: rgba(34, 197, 94, 0.55);
  box-shadow: inset 0 0 24px rgba(34, 197, 94, 0.08);
}

.chart-area.live-tick.down {
  border-color: rgba(239, 68, 68, 0.55);
  box-shadow: inset 0 0 24px rgba(239, 68, 68, 0.08);
}

.chart-legend {
  position: absolute;
  bottom: 0.35rem;
  left: 0.35rem;
  z-index: 4;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.5rem;
  padding: 0.25rem 0.4rem;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.85);
  border: 1px solid var(--frame-border);
  font-size: 0.52rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--frame-white-dim);
  pointer-events: none;
}

.chart-legend li {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.chart-legend .leg {
  width: 8px;
  height: 8px;
  border-radius: 2px;
  flex-shrink: 0;
}

.chart-legend .leg.entry { background: #3b82f6; }
.chart-legend .leg.sl { background: #ef4444; }
.chart-legend .leg.tp { background: #22c55e; }
.chart-legend .leg.live { background: var(--orange); border-radius: 50%; }

.chart-live-beacon {
  position: absolute;
  top: 0.45rem;
  right: 0.45rem;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--buy);
  box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.65);
  z-index: 4;
  opacity: 0.35;
  pointer-events: none;
}

.chart-area.live-tick .chart-live-beacon {
  animation: beaconPing 0.9s ease;
  opacity: 1;
}

@keyframes chartAreaPulse {
  0% { filter: brightness(1); }
  35% { filter: brightness(1.12); }
  100% { filter: brightness(1); }
}

@keyframes beaconPing {
  0% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.75); transform: scale(1); }
  70% { box-shadow: 0 0 0 10px rgba(34, 197, 94, 0); transform: scale(1.15); }
  100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0); transform: scale(1); }
}

.chart-wrap {
  height: 200px;
  width: 100%;
}


/* Ẩn logo TradingView trên lightweight-charts */
#chartMain #tv-attr-logo,
#chartMain a[id="tv-attr-logo"],
#chartMain .tv-lightweight-charts a[href*="tradingview"] {
  display: none !important;
  visibility: hidden !important;
  pointer-events: none !important;
  width: 0 !important;
  height: 0 !important;
  overflow: hidden !important;
}

.chart-tip {
  padding: 0.35rem 0.5rem;
  font-size: 0.68rem;
  line-height: 1.35;
  font-variant-numeric: tabular-nums;
}

.card-tf {
  padding: 0;
  overflow: hidden;
}

.card-tf > .card-label {
  margin: 0;
  padding: 0.85rem 1rem 0.5rem;
}

.tf-panel {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.tf-section {
  padding: 0.85rem 1rem 1rem;
}

.tf-section-head {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  margin-bottom: 0.75rem;
}

.tf-section-icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  border: 1px solid rgba(76, 194, 191, 0.25);
  background: rgba(0, 0, 0, 0.35);
  position: relative;
}

.tf-section-icon::after {
  content: "";
  position: absolute;
  inset: 0;
  margin: auto;
  width: 14px;
  height: 14px;
  border-radius: 3px;
}

.tf-section-icon--chart {
  background: linear-gradient(145deg, rgba(51, 213, 213, 0.2), rgba(0, 0, 0, 0.4));
}

.tf-section-icon--chart::after {
  box-shadow:
    inset 0 -8px 0 rgba(34, 197, 94, 0.7),
    inset 0 4px 0 rgba(239, 68, 68, 0.6);
}

.tf-section-icon--analyze {
  background: linear-gradient(145deg, rgba(244, 154, 58, 0.18), rgba(0, 0, 0, 0.4));
}

.tf-section-icon--analyze::after {
  width: 16px;
  height: 2px;
  border-radius: 2px;
  background: #f49a3a;
  box-shadow: 0 -5px 0 #33d5d5, 0 5px 0 #51da73;
}

.tf-section-title {
  margin: 0;
  font-size: 0.82rem;
  font-weight: 800;
  color: var(--frame-white);
  letter-spacing: 0.02em;
}

.tf-section-desc {
  margin: 0.15rem 0 0;
  font-size: 0.65rem;
  font-weight: 500;
  color: var(--muted);
  line-height: 1.35;
}

.tf-section-rule {
  height: 1px;
  margin: 0 1rem;
  background: linear-gradient(90deg, transparent, rgba(76, 194, 191, 0.35), transparent);
}

.tf-rail {
  display: flex;
  align-items: stretch;
  gap: 0.35rem;
  padding: 0.25rem;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.35);
  border: 1px solid rgba(76, 194, 191, 0.15);
}

.tf-scalp-pick {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  margin-top: 0;
  margin-bottom: 0.55rem;
}

.tf-scalp-pick-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0 0.1rem;
}

.tf-scalp-pick-head .tf-field-hint {
  color: #7ee8b8;
  background: rgba(51, 213, 213, 0.1);
  border: 1px solid rgba(51, 213, 213, 0.28);
  border-radius: 6px;
  padding: 0.12rem 0.4rem;
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.tf-rail--scalp {
  border-color: rgba(244, 154, 58, 0.22);
}

.tf-rail--scalp .tf-btn.active {
  background: linear-gradient(180deg, #fbbf24, #f49a3a);
  border-color: rgba(244, 154, 58, 0.55);
  color: #1a0f02;
  box-shadow: 0 4px 14px rgba(244, 154, 58, 0.35);
}

#tfScalpRail.signal-buy .tf-btn.active {
  background: linear-gradient(180deg, #4ade80, #22c55e);
  border-color: rgba(34, 197, 94, 0.62);
  color: #03150a;
  box-shadow: 0 4px 14px rgba(34, 197, 94, 0.35);
}

#tfScalpRail.signal-sell .tf-btn.active {
  background: linear-gradient(180deg, #f87171, #ef4444);
  border-color: rgba(239, 68, 68, 0.62);
  color: #1a0505;
  box-shadow: 0 4px 14px rgba(239, 68, 68, 0.35);
}

.tf-btn--locked {
  cursor: not-allowed;
  opacity: 0.72;
  color: rgba(255, 255, 255, 0.45);
  background: rgba(0, 0, 0, 0.25);
}

.tf-btn--locked:hover {
  border-color: rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.45);
  background: rgba(0, 0, 0, 0.25);
  box-shadow: none;
}

.tf-btn--locked.active {
  background: rgba(0, 0, 0, 0.35);
  border-color: rgba(255, 255, 255, 0.15);
  color: rgba(255, 255, 255, 0.5);
  box-shadow: none;
}

.tf-btn-lock {
  display: inline-block;
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  margin-top: 0.05rem;
  background: center / contain no-repeat url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fbbf24' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='5' y='11' width='14' height='10' rx='2'/%3E%3Cpath d='M8 11V8a4 4 0 0 1 8 0v3'/%3E%3C/svg%3E");
  opacity: 0.98;
  filter: drop-shadow(0 0 4px rgba(251, 191, 36, 0.45));
}

.tf-btn {
  flex: 1;
  min-height: 42px;
  padding: 0.4rem 0.45rem;
  border: 1px solid transparent;
  border-radius: 9px;
  background: transparent;
  color: var(--frame-white-dim);
  font-family: inherit;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.12rem;
  transition:
    background 0.2s ease,
    color 0.2s ease,
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

.tf-btn:hover {
  border-color: rgba(76, 194, 191, 0.35);
  color: var(--fx-teal-light);
  background: rgba(76, 194, 191, 0.08);
}

.tf-btn-label {
  line-height: 1;
}

.tf-btn-countdown {
  font-size: 0.58rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
  color: var(--orange);
  line-height: 1;
}

.tf-btn.active {
  background: var(--fx-gradient-teal);
  border-color: rgba(76, 194, 191, 0.55);
  color: #020621;
  box-shadow: 0 4px 16px rgba(51, 213, 213, 0.3);
}

.tf-btn.active .tf-btn-countdown {
  color: #0a2a28;
  opacity: 0.85;
}

.tf-btn-refresh {
  flex: 0 0 auto;
  min-width: 3.25rem;
  padding: 0.45rem 0.65rem;
  background: linear-gradient(135deg, rgba(244, 154, 58, 0.25), rgba(244, 154, 58, 0.08));
  border-color: rgba(244, 154, 58, 0.45);
  color: #ffc078;
  font-size: 1rem;
}

.tf-btn-refresh:hover {
  background: linear-gradient(135deg, rgba(244, 154, 58, 0.4), rgba(244, 154, 58, 0.15));
  border-color: var(--orange);
  color: #fff;
  box-shadow: 0 4px 14px rgba(244, 154, 58, 0.25);
}

.tf-pairs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.55rem;
}

.tf-field {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto auto;
  align-items: center;
  gap: 0.15rem 0.4rem;
  padding: 0.65rem 0.7rem;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.32);
  border: 1px solid rgba(76, 194, 191, 0.16);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.tf-field:focus-within {
  border-color: rgba(76, 194, 191, 0.4);
  box-shadow: 0 0 0 2px rgba(51, 213, 213, 0.12);
}

.tf-field-label {
  grid-column: 1;
  grid-row: 1;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--frame-white);
}

.tf-field-hint {
  grid-column: 2;
  grid-row: 1;
  font-size: 0.58rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fx-teal-dim);
  padding: 0.12rem 0.4rem;
  border-radius: 6px;
  background: rgba(51, 213, 213, 0.1);
  border: 1px solid rgba(76, 194, 191, 0.2);
}

.tf-select-wrap {
  grid-column: 1 / -1;
  grid-row: 2;
  position: relative;
}

.tf-select-wrap::after {
  content: "";
  position: absolute;
  right: 0.75rem;
  top: 50%;
  width: 7px;
  height: 7px;
  border-right: 2px solid var(--fx-teal-dim);
  border-bottom: 2px solid var(--fx-teal-dim);
  transform: translateY(-65%) rotate(45deg);
  pointer-events: none;
}

.tf-pairs select {
  width: 100%;
  appearance: none;
  -webkit-appearance: none;
  padding: 0.55rem 2rem 0.55rem 0.65rem;
  border-radius: 9px;
  border: 1px solid rgba(76, 194, 191, 0.22);
  background-color: #000;
  color: var(--frame-white);
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

.tf-pairs select option {
  background-color: #000;
  color: var(--frame-white);
}

.tf-pairs select:hover {
  border-color: rgba(76, 194, 191, 0.4);
  background-color: #0a0a0a;
}

.tf-pairs select:focus {
  outline: none;
  border-color: rgba(51, 213, 213, 0.55);
  box-shadow: 0 0 0 2px rgba(51, 213, 213, 0.15);
}

.tf-field--action {
  display: flex;
  grid-template-columns: none;
  padding: 0.5rem;
  margin-top: 0.1rem;
}

.tf-field--action .btn-analyze--tf {
  width: 58%;
  min-width: 260px;
  margin: 0 auto;
  justify-content: center;
  min-height: 56px;
  padding: 0.7rem 1.15rem;
  border-radius: 10px;
  font-size: 1rem;
  letter-spacing: 0.04em;
  background: linear-gradient(180deg, #fbbf24, #f49a3a);
  color: #1a0f02;
  box-shadow: 0 6px 20px rgba(244, 154, 58, 0.35);
}

.tf-field--action .btn-analyze--tf:hover {
  box-shadow: 0 10px 28px rgba(244, 154, 58, 0.45);
}

.tf-field--action .btn-analyze--tf.signal-buy {
  background: linear-gradient(180deg, #4ade80, #22c55e);
  color: #03150a;
  box-shadow: 0 6px 20px rgba(34, 197, 94, 0.35);
}

.tf-field--action .btn-analyze--tf.signal-buy:hover {
  box-shadow: 0 10px 28px rgba(34, 197, 94, 0.45);
}

.tf-field--action .btn-analyze--tf.signal-sell {
  background: linear-gradient(180deg, #f87171, #ef4444);
  color: #1a0505;
  box-shadow: 0 6px 20px rgba(239, 68, 68, 0.35);
}

.tf-field--action .btn-analyze--tf.signal-sell:hover {
  box-shadow: 0 10px 28px rgba(239, 68, 68, 0.45);
}

.tf-field--progress {
  flex-direction: column;
  gap: 0.5rem;
  min-height: 72px;
  padding: 0.75rem 0.85rem;
  background: rgba(0, 0, 0, 0.38);
  border: 1px solid rgba(244, 154, 58, 0.22);
  border-radius: 12px;
  cursor: default;
  user-select: none;
}

.trade-progress-row {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  width: 100%;
}

.trade-progress-note {
  align-self: center;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 0.3rem;
  min-height: 34px;
  padding: 0.42rem 1rem;
  border-radius: 12px;
  border: 1px solid rgba(59, 130, 246, 0.9);
  background: linear-gradient(180deg, #dbeafe, #93c5fd);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: #0f172a;
  text-transform: uppercase;
  text-shadow: none;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.55),
    0 6px 14px rgba(59, 130, 246, 0.3);
}

.trade-progress-label {
  flex-shrink: 0;
  min-width: 1.75rem;
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  line-height: 1;
  text-align: center;
}

.trade-progress-label--sl {
  color: #f87171;
}

.trade-progress-label--tp {
  color: #4ade80;
}

.trade-progress {
  flex: 1;
  min-width: 0;
  height: 18px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  overflow: hidden;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.35);
}

.trade-progress-bar {
  height: 100%;
  width: 0%;
  border-radius: 999px;
  background: #ef4444;
  transition: width 0.3s ease, background 0.25s ease;
}

.tf-field--progress.is-up .trade-progress-bar {
  background: linear-gradient(90deg, #22c55e, #4ade80);
}

.tf-field--progress.is-down .trade-progress-bar {
  background: linear-gradient(90deg, #dc2626, #f87171);
}

.tf-field--progress.is-busy .trade-progress-bar {
  background: linear-gradient(90deg, #f49a3a, #fcd34d);
}

.trade-progress-text {
  margin: 0;
  text-align: center;
  font-size: 0.95rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  font-variant-numeric: tabular-nums;
  color: #fcd34d;
}

.tf-field--progress.is-up .trade-progress-text {
  color: #4ade80;
}

.tf-field--progress.is-down .trade-progress-text {
  color: #f87171;
}

.tf-field--countdown-only {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0.65rem 0.5rem;
  margin-top: 0.1rem;
  border-radius: 12px;
  background:
    linear-gradient(180deg, rgba(8, 14, 28, 0.92) 0%, rgba(0, 0, 0, 0.72) 100%);
  border: 1px solid rgba(244, 154, 58, 0.24);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    inset 0 -1px 0 rgba(0, 0, 0, 0.45),
    0 6px 20px rgba(0, 0, 0, 0.35);
  position: relative;
  overflow: hidden;
}

.tf-field--countdown-only::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    105deg,
    rgba(244, 154, 58, 0.1) 0%,
    transparent 42%,
    rgba(51, 213, 213, 0.07) 100%
  );
  pointer-events: none;
}

.tf-field--countdown-only .analyze-countdown {
  position: relative;
  z-index: 1;
  margin: 0;
  font-size: 1.65rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.06em;
  color: #fcd34d;
  text-shadow: 0 0 24px rgba(244, 154, 58, 0.35);
  line-height: 1;
}

.tf-field--countdown-only.is-busy .analyze-countdown {
  color: #33d5d5;
  animation: countdownPulse 1s ease-in-out infinite;
}

@keyframes countdownPulse {
  0%, 100% { opacity: 0.45; }
  50% { opacity: 1; }
}

.tf-field--action:focus-within {
  border-color: rgba(51, 213, 213, 0.35);
  box-shadow: 0 0 0 2px rgba(51, 213, 213, 0.1);
}

.tf-field--action .tf-field-hint {
  color: #7ee8b8;
  background: rgba(51, 213, 213, 0.12);
  border-color: rgba(51, 213, 213, 0.28);
}

.status {
  font-size: 0.7rem;
  text-align: center;
  color: var(--muted);
  padding: 0.5rem;
}

.status.live { color: var(--buy); }
.status.loading { color: var(--frame-white); }
.status.err { color: var(--sell); }
.status.warn { color: var(--orange); }

.btn-analyze.cooldown:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* Giải thích tín hiệu — cuối trang */
.trade-explain {
  margin-top: 1rem;
  padding: 1.15rem 1.25rem 1.1rem;
}

.trade-explain-title {
  margin: 0 0 0.85rem;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fx-teal-dim);
}

.trade-explain-head {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  margin-bottom: 1rem;
  padding-bottom: 0.85rem;
  border-bottom: 1px solid rgba(76, 194, 191, 0.15);
}

.trade-explain-badge {
  flex-shrink: 0;
  min-width: 3.5rem;
  padding: 0.35rem 0.65rem;
  border-radius: 10px;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-align: center;
}

.trade-explain-badge.buy {
  color: #031018;
  background: linear-gradient(135deg, #33d5d5, #51da73);
  box-shadow: 0 4px 16px rgba(51, 213, 213, 0.3);
}

.trade-explain-badge.sell {
  color: #fff;
  background: linear-gradient(135deg, #ef4444, #dc2626);
  box-shadow: 0 4px 16px rgba(239, 68, 68, 0.35);
}

.trade-explain-lead {
  margin: 0;
  font-size: 0.88rem;
  font-weight: 600;
  line-height: 1.55;
  color: #e5e7eb;
}

.trade-explain-body {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.explain-block h3 {
  margin: 0 0 0.45rem;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: #9bd2cc;
}

.explain-block p {
  margin: 0 0 0.45rem;
  font-size: 0.8rem;
  line-height: 1.6;
  color: #9ca3af;
}

.explain-block p:last-child {
  margin-bottom: 0;
}

.explain-block strong {
  color: #e5e7eb;
  font-weight: 700;
}

.explain-list {
  margin: 0.35rem 0 0;
  padding-left: 1.1rem;
  font-size: 0.78rem;
  line-height: 1.55;
  color: #9ca3af;
}

.explain-list li {
  margin-bottom: 0.3rem;
}

.explain-list.explain-metrics {
  list-style: none;
  padding-left: 0;
}

.explain-list.explain-metrics li {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.35rem 0.75rem;
  padding: 0.4rem 0.5rem;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(76, 194, 191, 0.12);
}

.explain-list.explain-metrics span {
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.explain-list.explain-metrics strong {
  font-size: 0.78rem;
  color: #e5e7eb;
}

.explain-note {
  font-size: 0.72rem !important;
  color: var(--muted) !important;
  font-style: italic;
}

.explain-warn {
  color: #fbbf24 !important;
}

.explain-ok {
  color: #86efac !important;
}

.trade-explain-checks {
  list-style: none;
  margin: 1rem 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.trade-explain-checks li {
  display: flex;
  align-items: flex-start;
  gap: 0.45rem;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.4rem 0.55rem;
  border-radius: 8px;
  border: 1px solid transparent;
}

.trade-explain-checks li.ok {
  color: #86efac;
  background: rgba(34, 197, 94, 0.08);
  border-color: rgba(34, 197, 94, 0.2);
}

.trade-explain-checks li.no {
  color: #fca5a5;
  background: rgba(239, 68, 68, 0.08);
  border-color: rgba(239, 68, 68, 0.2);
}

.trade-explain-checks .mark {
  flex-shrink: 0;
  font-weight: 800;
}

.app-footer {
  margin-top: 0.85rem;
  padding: 0.65rem 0.85rem;
  text-align: center;
}

.app-footer p {
  font-size: 0.62rem;
  color: var(--muted);
  line-height: 1.45;
}

.app-footer .footer-meta {
  margin-top: 0.25rem;
  font-size: 0.58rem;
  color: #64748b;
  letter-spacing: 0.04em;
}

/* Full-screen analyze — chuyên nghiệp (lam / trắng) */
.analyze-screen {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  background: rgba(3, 10, 7, 0.9);
  backdrop-filter: blur(20px) saturate(1.05);
  -webkit-backdrop-filter: blur(20px) saturate(1.05);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.32s ease, visibility 0.32s ease;
}

.analyze-screen.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.analyze-screen-bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  background:
    radial-gradient(ellipse 70% 45% at 50% 35%, rgba(74, 222, 128, 0.2), transparent 68%);
}

.analyze-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(56px);
  opacity: 0.45;
  animation: analyzeOrbFloat 6s ease-in-out infinite;
}

.analyze-orb--a {
  width: 240px;
  height: 240px;
  top: 14%;
  left: 18%;
  background: rgba(74, 222, 128, 0.34);
}

.analyze-orb--b {
  width: 200px;
  height: 200px;
  bottom: 16%;
  right: 14%;
  background: rgba(255, 255, 255, 0.22);
  animation-delay: -3s;
}

@keyframes analyzeOrbFloat {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(8px, -6px); }
}

.analyze-screen-inner {
  position: relative;
  z-index: 1;
  width: min(400px, 92vw);
  text-align: center;
  padding: 2rem 1.75rem 1.55rem;
  border-radius: 18px;
  border: 1px solid rgba(134, 239, 172, 0.38);
  background: linear-gradient(180deg, rgba(10, 24, 14, 0.98) 0%, rgba(4, 12, 8, 0.99) 100%);
  box-shadow:
    0 0 0 1px rgba(187, 247, 208, 0.16) inset,
    0 24px 64px rgba(0, 0, 0, 0.65),
    0 0 44px rgba(34, 197, 94, 0.24);
  transform: translateY(8px) scale(0.985);
  opacity: 0;
  overflow: hidden;
  transition:
    transform 0.5s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 0.4s ease;
}

.analyze-border-glow {
  position: absolute;
  inset: -1px;
  border-radius: 19px;
  pointer-events: none;
  z-index: 0;
  opacity: 0;
  box-shadow:
    0 0 0 1px rgba(134, 239, 172, 0.68),
    0 0 24px rgba(34, 197, 94, 0.34);
}

.analyze-screen.active .analyze-border-glow {
  opacity: 1;
}

.analyze-screen-inner > *:not(.analyze-border-glow) {
  position: relative;
  z-index: 1;
}

.analyze-screen.active .analyze-screen-inner {
  transform: translateY(0) scale(1);
  opacity: 1;
}

.analyze-screen.done .analyze-screen-inner {
  border-color: rgba(134, 239, 172, 0.5);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.08) inset,
    0 24px 64px rgba(0, 0, 0, 0.65),
    0 0 32px rgba(34, 197, 94, 0.24);
}

.analyze-scan {
  position: absolute;
  left: 0;
  right: 0;
  height: 1px;
  top: 0;
  background: linear-gradient(90deg, transparent, rgba(74, 222, 128, 0.62), rgba(255, 255, 255, 0.72), transparent);
  opacity: 0;
  pointer-events: none;
  z-index: 2;
}

.analyze-screen.active .analyze-scan {
  opacity: 1;
  animation: analyzeScan 2.8s cubic-bezier(0.35, 0.08, 0.2, 0.98) infinite;
}

@keyframes analyzeScan {
  0% { top: 0; opacity: 0; }
  10% { opacity: 0.85; }
  90% { opacity: 0.85; }
  100% { top: 100%; opacity: 0; }
}

.analyze-hero {
  position: relative;
  width: 148px;
  height: 148px;
  margin: 0 auto 1.1rem;
}

.analyze-hero-glow {
  position: absolute;
  inset: 10%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(74, 222, 128, 0.34) 0%, transparent 72%);
  animation: analyzeHeroPulse 2.8s ease-in-out infinite;
}

@keyframes analyzeHeroPulse {
  0%, 100% { opacity: 0.55; transform: scale(0.96); }
  50% { opacity: 0.9; transform: scale(1.02); }
}

.analyze-ring-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.analyze-ring-orbit {
  stroke: rgba(255, 255, 255, 0.12);
  stroke-width: 1.5;
  stroke-dasharray: 5 9;
  transform-origin: 70px 70px;
  animation: analyzeOrbitSpin 11s linear infinite;
}

@keyframes analyzeOrbitSpin {
  to { transform: rotate(360deg); }
}

.analyze-ring-track {
  stroke: rgba(134, 239, 172, 0.2);
  stroke-width: 6;
}

.analyze-ring-fill {
  stroke: url(#analyzeGrad);
  stroke-width: 6;
  stroke-linecap: round;
  stroke-dasharray: 364.42;
  stroke-dashoffset: 364.42;
  transition: stroke-dashoffset 0.14s ease-out;
  filter: drop-shadow(0 0 8px rgba(34, 197, 94, 0.45));
}

.analyze-brand-mark.lp-logo {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  line-height: 1;
  pointer-events: none;
}

.analyze-brand-mark.lp-logo .lp-logo__mark {
  width: 1.65rem;
  height: 1.65rem;
  font-size: 0.55rem;
}

.analyze-brand-mark.lp-logo .lp-logo__text {
  font-size: 0.8rem;
  color: #f8fafc;
}

.analyze-brand-mark.lp-logo .lp-logo__text em {
  color: var(--lp-green-light);
}

.analyze-screen-sub {
  margin-bottom: 0.5rem;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
}

.analyze-screen-pct {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 0.05em;
  font-size: 2.85rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  margin-bottom: 1.1rem;
  color: #f8fafc;
  text-shadow: 0 0 18px rgba(74, 222, 128, 0.35);
  letter-spacing: -0.02em;
}

.analyze-screen-pct .pct-sym {
  font-size: 1.35rem;
  font-weight: 700;
  opacity: 0.75;
}

.analyze-screen.active .analyze-screen-pct .pct-num {
  animation: pctTick 0.35s ease-out;
}

@keyframes pctTick {
  0% { transform: scale(1.08); filter: brightness(1.3); }
  100% { transform: scale(1); filter: brightness(1); }
}

.analyze-steps {
  list-style: none;
  text-align: left;
  margin: 0 0 0.85rem;
  padding: 0 0 0 0.35rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  position: relative;
}

.analyze-steps::before {
  content: "";
  position: absolute;
  left: 15px;
  top: 14px;
  bottom: 14px;
  width: 2px;
  border-radius: 2px;
  background: linear-gradient(180deg, rgba(74, 222, 128, 0.38), rgba(74, 222, 128, 0.06));
}

.analyze-step-item {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 0.7rem;
  font-weight: 500;
  color: #5c6b6a;
  padding: 0.4rem 0.55rem 0.4rem 0.45rem;
  border-radius: 10px;
  border: 1px solid transparent;
  transform: translateX(-4px);
  opacity: 0.72;
  transition:
    color 0.3s ease,
    background 0.3s ease,
    border-color 0.3s ease,
    transform 0.35s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 0.3s ease;
}

.analyze-step-item .step-dot {
  position: relative;
  z-index: 1;
  flex-shrink: 0;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  border: 2px solid rgba(255, 255, 255, 0.08);
  transition:
    width 0.25s ease,
    height 0.25s ease,
    background 0.25s ease,
    border-color 0.25s ease,
    box-shadow 0.25s ease;
}

.analyze-step-item.active {
  color: #f0fdf4;
  background: linear-gradient(90deg, rgba(74, 222, 128, 0.2), rgba(34, 197, 94, 0.1));
  border-color: rgba(134, 239, 172, 0.58);
  transform: translateX(0);
  opacity: 1;
}

.analyze-step-item.active .step-dot {
  background: #4ade80;
  border-color: rgba(255, 255, 255, 0.35);
  box-shadow: 0 0 0 3px rgba(74, 222, 128, 0.24);
  animation: none;
}

.analyze-step-item.done {
  color: #dcfce7;
  opacity: 1;
  transform: translateX(0);
}

.analyze-step-item.done .step-dot {
  width: 16px;
  height: 16px;
  background: linear-gradient(145deg, #bbf7d0, #4ade80);
  border-color: transparent;
  color: #031018;
  font-size: 10px;
  font-weight: 800;
  line-height: 16px;
  text-align: center;
  box-shadow: 0 0 10px rgba(74, 222, 128, 0.4);
  animation: none;
}

.analyze-screen-step {
  font-size: 0.82rem;
  font-weight: 600;
  color: #bbf7d0;
  min-height: 1.15em;
  margin-bottom: 0.7rem;
  transition: color 0.3s ease;
}

.analyze-screen.done .analyze-screen-step {
  color: #f0fdf4;
}

.analyze-screen-progress {
  position: relative;
  height: 7px;
  border-radius: 999px;
  background: rgba(134, 239, 172, 0.15);
  border: 1px solid rgba(134, 239, 172, 0.32);
  overflow: hidden;
  margin-bottom: 0.55rem;
}

.analyze-screen-bar {
  position: relative;
  height: 100%;
  width: 0%;
  border-radius: inherit;
  background: linear-gradient(90deg, #4ade80, #22c55e, #16a34a);
  transition: width 0.1s ease-out;
  box-shadow: 0 0 12px rgba(51, 213, 213, 0.35);
}

.analyze-screen-bar::after {
  content: "";
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 24px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.8));
  border-radius: inherit;
  opacity: 0.85;
}

.analyze-screen-timer {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(187, 247, 208, 0.92);
  font-variant-numeric: tabular-nums;
}

body.analyze-lock {
  overflow: hidden;
}

body.analyze-lock .app {
  filter: blur(2px) brightness(0.88);
  transition: filter 0.35s ease;
}

/* Chart overlay khi phân tích */
.chart-overlay {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  background: rgba(0, 0, 0, 0.78);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.28s ease, visibility 0.28s ease;
}

.chart-overlay-vignette {
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 85% 75% at 50% 50%, transparent 35%, rgba(0, 0, 0, 0.5) 100%);
  pointer-events: none;
}

.chart-overlay.active {
  opacity: 1;
  visibility: visible;
}

.panel.analyzing .chart-area {
  filter: brightness(0.55);
}

.chart-loader {
  position: relative;
  width: 72px;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.chart-loader-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px solid transparent;
}

.chart-loader-ring--outer {
  border-top-color: #33d5d5;
  border-right-color: rgba(255, 255, 255, 0.25);
  animation: chartLoaderOuter 1s cubic-bezier(0.5, 0, 0.5, 1) infinite;
}

.chart-loader-ring--inner {
  inset: 10px;
  border-bottom-color: rgba(125, 211, 252, 0.65);
  border-left-color: rgba(255, 255, 255, 0.2);
  animation: chartLoaderInner 0.75s cubic-bezier(0.5, 0, 0.5, 1) infinite reverse;
}

@keyframes chartLoaderOuter {
  to { transform: rotate(360deg); }
}

@keyframes chartLoaderInner {
  to { transform: rotate(360deg); }
}

.chart-loader-pct {
  position: relative;
  z-index: 1;
  font-size: 0.95rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  color: #ffffff;
}

.analyze-label {
  position: relative;
  z-index: 1;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.85);
}

.analyze-progress {
  position: relative;
  z-index: 1;
  width: 72%;
  max-width: 240px;
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  overflow: hidden;
}

.analyze-progress-bar {
  position: relative;
  height: 100%;
  width: 0%;
  border-radius: inherit;
  background: linear-gradient(90deg, #33d5d5, #7dd3fc);
  transition: width 0.1s ease-out;
}

@media (prefers-reduced-motion: reduce) {
  .analyze-orb,
  .analyze-screen.active .analyze-scan,
  .analyze-hero-glow,
  .analyze-ring-orbit,
  .chart-loader-ring--outer,
  .chart-loader-ring--inner {
    animation: none !important;
  }
}

.analyze-progress-bar::after {
  content: "";
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 20px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.45));
}

/* Topbar AI — căn giống nav trang chủ (fx-nav-bar) */
.topbar--home-nav .topbar-brand-tagline {
  display: none;
}

.topbar--home-nav .topbar-user-chip {
  max-width: 8rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* PC — layout chuẩn desktop (mobile ≤800px không đổi) */
@media (min-width: 801px) {
  .dashboard {
    grid-template-columns: 1fr;
  }

  #cardSignal {
    grid-column: 1 / -1;
    width: 100%;
  }

  .sidebar {
    grid-column: 1 / -1;
    width: 100%;
  }

  .app {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 1.25rem clamp(1rem, 2.5vw, 2.5rem) 2rem;
  }

  .topbar {
    padding: 0;
    margin-top: 0;
    margin-bottom: 1.15rem;
    overflow: visible;
  }

  .topbar--home-nav {
    border-radius: var(--fx-radius, 14px);
  }

  .topbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    width: 100%;
    min-height: 0;
    padding: 0.85rem clamp(1.25rem, 5vw, 3rem);
    box-sizing: border-box;
  }

  .topbar-zone--brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0;
    border: none;
    background: none;
    flex-shrink: 0;
  }

  .topbar-zone--center {
    display: flex;
    flex: 1;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    gap: 0.7rem;
    padding: 0 1rem;
    min-width: 0;
    border: none;
    background: none;
  }

  .topbar-price-hero {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    flex-wrap: nowrap;
    gap: 0.5rem;
    padding: 0;
    border-radius: 0;
    background: transparent;
    border: none;
    box-shadow: none;
  }

  .topbar-price-copy {
    display: flex;
    align-items: baseline;
    gap: 0.75rem;
  }

  .topbar-price-hero .spot-label {
    margin: 0;
    font-size: 0.68rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--fx-teal-dim);
  }

  .topbar-price-hero .spot-value {
    font-size: 1.25rem;
    line-height: 1.1;
    letter-spacing: -0.01em;
  }

  .topbar-price-hero .spot-meta {
    display: block;
    font-size: 0.62rem;
    color: var(--muted);
    white-space: nowrap;
  }

  .topbar-status-bar {
    display: none;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.45rem;
  }

  .session-pills {
    padding: 0.22rem 0.4rem;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.32);
    border: 1px solid rgba(76, 194, 191, 0.14);
  }

  .topbar--home-nav .topbar-zone--actions.fx-nav-actions {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-end;
    gap: 0.45rem;
    padding: 0;
    margin: 0;
    margin-top: 0 !important;
    border: none;
    background: none;
    flex-shrink: 0;
  }

  .topbar--home-nav .topbar-zone--actions .btn-user {
    padding: 0.55rem 1.15rem;
    border-radius: 8px;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #d1d5db;
    font-size: 0.875rem;
    font-weight: 600;
  }

  .topbar--home-nav .topbar-zone--actions .btn-user:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.2);
    color: #f3f4f6;
  }

  .topbar--home-nav .topbar-zone--actions .btn-user-avatar,
  .topbar--home-nav .topbar-zone--actions .btn-user-plan {
    display: none !important;
  }

  .topbar--home-nav .topbar-zone--actions .btn-user-text {
    color: inherit;
    font-weight: 600;
  }

  .dashboard {
    grid-template-columns: 1fr;
    align-items: stretch;
    gap: 1.25rem;
  }

  .sidebar {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    min-height: 100%;
  }

  .card-signal {
    display: flex;
    flex-direction: column;
    padding: 1.35rem 1.75rem 1.75rem;
    min-height: 0;
  }

  .card-signal.signal-awaiting {
    min-height: min(36rem, calc(100vh - 12rem));
  }

  .card-signal.signal-awaiting .signal-hero {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: min(28rem, 50vh);
    margin-bottom: 0;
    padding: 2rem 1.5rem;
  }

  .card-signal.signal-awaiting .signal-awaiting {
    max-width: 36rem;
    padding: 2rem 2.25rem;
  }

  .signal-hero {
    flex: 1;
    display: grid;
    grid-template-columns: minmax(168px, 200px) minmax(0, 1fr) minmax(180px, 240px);
    grid-template-rows: auto;
    align-items: center;
    column-gap: clamp(1rem, 2vw, 1.75rem);
    min-height: 18rem;
    margin-bottom: 1.5rem;
    padding-right: 0;
  }

  .signal-badge {
    grid-column: 1;
    grid-row: 1;
    justify-self: center;
    align-self: center;
    margin: 0;
  }

  .signal-medallion {
    width: min(200px, 14vw);
    height: min(200px, 14vw);
  }

  .signal-medallion-text {
    font-size: clamp(2.25rem, 3.5vw, 2.85rem);
  }

  .signal-medallion-ring {
    inset: -8px;
  }

  .signal-info {
    grid-column: 2;
    grid-row: 1;
    justify-self: stretch;
    align-self: start;
    width: 100%;
    max-width: none;
    flex: none;
    margin: 0;
    padding-top: 0.5rem;
  }

  .signal-info #signalText,
  .signal-info #signalChecks {
    margin-left: 0;
  }

  .signal-info .signal-title {
    font-size: clamp(1.65rem, 2.2vw, 2rem);
    margin-bottom: 0.85rem;
  }

  .signal-info .confidence-bar {
    height: 10px;
  }

  .signal-info .metrics-row {
    gap: 0.45rem;
    margin-bottom: 0.75rem;
  }

  .signal-info .metrics-row li {
    padding: 0.55rem 0.4rem;
  }

  .signal-info .checklist li {
    padding: 0.4rem 0;
    font-size: 0.78rem;
  }

  .signal-side-img {
    grid-column: 3;
    grid-row: 1;
    position: relative;
    top: auto;
    right: auto;
    left: auto;
    justify-self: end;
    align-self: center;
    width: min(220px, 100%);
    max-height: min(220px, 26vh);
    margin: 0;
    animation: signalSideFloat 2.6s ease-in-out infinite;
  }

  .rules {
    flex-shrink: 0;
    padding: 1.15rem 1.25rem;
    margin-top: auto;
  }

  .levels-three {
    gap: 0.55rem;
  }

  .levels-three .price-card {
    padding: 0.85rem 0.65rem;
  }

  .card-chart {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-height: min(360px, 40vh);
  }

  .card-chart .chart-area {
    flex: 1;
    min-height: min(300px, 34vh);
  }

  .chart-wrap {
    height: min(320px, 36vh);
    min-height: min(320px, 36vh);
  }

  .card-tf {
    display: flex;
    flex-direction: column;
    flex: 0 0 auto;
    min-height: 0;
    overflow: visible;
    background: linear-gradient(165deg, rgba(14, 16, 20, 0.98) 0%, rgba(8, 10, 12, 1) 100%);
  }

  .card-tf > .card-label {
    padding: 0.7rem 1.1rem 0.55rem;
    border-bottom: 1px solid rgba(76, 194, 191, 0.14);
    background: rgba(51, 213, 213, 0.05);
    letter-spacing: 0.14em;
  }

  .card-tf .tf-panel {
    display: flex;
    flex-direction: column;
    gap: 0;
    flex: none;
    min-height: 0;
    overflow: visible;
  }

  .card-tf .tf-section {
    padding: 0.85rem 1rem 0.95rem;
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    overflow: visible;
    border-bottom: 1px solid rgba(76, 194, 191, 0.1);
  }

  .card-tf .tf-section:last-child {
    border-bottom: none;
  }

  .card-tf .tf-section--chart {
    background: linear-gradient(90deg, rgba(51, 213, 213, 0.07) 0%, transparent 42%);
    border-left: 3px solid rgba(51, 213, 213, 0.55);
  }

  .card-tf .tf-section--analyze {
    background: linear-gradient(90deg, rgba(244, 154, 58, 0.06) 0%, transparent 45%);
    border-left: 3px solid rgba(244, 154, 58, 0.45);
    padding: 0.85rem 1rem 0.95rem;
    gap: 0.55rem;
    min-height: calc(100vh - 170px);
  }

  #cardSignal {
    min-height: calc(100vh - 170px);
  }

  .card-tf .tf-section--analyze .tf-section-desc {
    display: block;
  }

  .card-tf .tf-section--analyze .tf-scalp-pick-head {
    display: flex;
  }

  .card-tf .tf-section--analyze .tf-btn-countdown {
    display: block;
  }

  .card-tf .tf-section-head {
  margin-bottom: 0.25rem;
  }

  .card-tf .tf-section-icon--chart {
    border-color: rgba(51, 213, 213, 0.35);
    background: linear-gradient(145deg, rgba(51, 213, 213, 0.22), rgba(0, 0, 0, 0.45));
  }

  .card-tf .tf-section-icon--analyze {
    border-color: rgba(244, 154, 58, 0.35);
    background: linear-gradient(145deg, rgba(244, 154, 58, 0.2), rgba(0, 0, 0, 0.45));
  }

  .card-tf .tf-section-rule {
    display: block;
    margin: 0;
    height: 1px;
    background: rgba(76, 194, 191, 0.12);
  }

  .card-tf .tf-rail {
    flex: 0 0 auto;
    padding: 0.22rem;
    gap: 0.4rem;
    background: rgba(0, 0, 0, 0.42);
    border-color: rgba(51, 213, 213, 0.22);
    position: relative;
    z-index: 1;
  }

  .card-tf .tf-rail .tf-btn {
    min-height: 36px;
    padding: 0.35rem 0.5rem;
    font-size: 0.76rem;
    position: relative;
    z-index: 1;
  }

  .card-tf .tf-rail .tf-btn:focus-visible {
    outline: 2px solid rgba(51, 213, 213, 0.65);
    outline-offset: 2px;
  }

  .card-tf .tf-rail .tf-btn.active {
    background: linear-gradient(180deg, #5eead4, #33d5d5);
    color: #021018;
    box-shadow: 0 4px 14px rgba(51, 213, 213, 0.35);
  }

  .card-tf .tf-pairs {
    grid-template-columns: 1fr;
    gap: 0.55rem;
    position: relative;
    z-index: 2;
  }

  .card-tf .tf-field {
  padding: 0.45rem 0.55rem;
    background: rgba(0, 0, 0, 0.38);
    border-color: rgba(76, 194, 191, 0.18);
  }

  .card-tf .tf-field--progress {
    min-height: 72px;
    padding: 0.75rem 0.85rem;
    gap: 0.5rem;
  }

  .card-tf .trade-progress {
    height: 18px;
  }

  .card-tf .trade-progress-text {
    font-size: 0.95rem;
  }

  .card-tf .tf-field--action .btn-analyze--tf {
    min-height: 46px;
    font-size: 0.86rem;
    padding: 0.55rem 1rem;
    border-radius: 10px;
    box-shadow: 0 6px 20px rgba(51, 213, 213, 0.32);
  }

  .card-tf .tf-scalp-pick {
  margin-top: 0.5rem;
  margin-bottom: 0.55rem;
  }

  .card-tf .tf-rail--scalp {
    background: rgba(0, 0, 0, 0.42);
    border-color: rgba(244, 154, 58, 0.25);
  }

  /* Can chinh dung theo khung Analyze sidebar */
  .card-tf .tf-section--analyze #tfScalpRail {
    min-height: 66px;
    align-items: stretch;
  }

  .card-tf .tf-section--analyze #tradeProgressWrap {
    min-height: 75px;
  }

  .card-tf .tf-section--analyze #btnAnalyzeTf {
    min-height: 46px;
  }

  .card-tf .tf-field--countdown-only {
    min-height: 54px;
    background: linear-gradient(180deg, rgba(6, 12, 24, 0.95) 0%, rgba(0, 0, 0, 0.78) 100%);
    border-color: rgba(244, 154, 58, 0.28);
  }

  .card-tf .tf-pairs select {
    background-color: #000;
    border-color: rgba(76, 194, 191, 0.28);
    position: relative;
    z-index: 3;
  }

  .card-tf .tf-pairs select:hover {
    background-color: #0a0a0a;
    border-color: rgba(51, 213, 213, 0.45);
  }

  .card-tf .tf-pairs select:focus {
    border-color: rgba(51, 213, 213, 0.65);
    box-shadow: 0 0 0 3px rgba(51, 213, 213, 0.18);
  }

  .status {
    font-size: 0.72rem;
    padding: 0.7rem 0.9rem;
  }

  .trade-explain {
    margin-top: 1.25rem;
    padding: 1.35rem 1.75rem 1.5rem;
  }

  .trade-explain-head {
    align-items: center;
  }

  .trade-explain-lead {
    font-size: 0.92rem;
  }

  .trade-explain-body {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1rem;
  }

  .explain-block {
    padding: 0.85rem 1rem;
    border-radius: 12px;
    background: rgba(0, 0, 0, 0.22);
    border: 1px solid rgba(76, 194, 191, 0.12);
  }

  .app-footer {
    margin-top: 1rem;
    padding: 0.75rem 1.25rem;
  }
}

/* Mobile — UI trading app (desktop >800px không đổi) */
@media (min-width: 1400px) {
  .dashboard {
    grid-template-columns: 1fr;
  }

  .chart-wrap {
    height: min(360px, 38vh);
    min-height: min(360px, 38vh);
  }

  .signal-hero {
    grid-template-columns: 210px minmax(0, 1fr) 240px;
    column-gap: 2rem;
  }

  .signal-medallion {
    width: 210px;
    height: 210px;
  }

  .signal-side-img {
    width: 240px;
    max-height: 240px;
  }
}

/* Desktop lock: force topbar + content full width like home nav */
@media (min-width: 801px) {
  .app {
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .topbar--home-nav .topbar-inner {
    width: 100%;
    min-height: 68px;
    padding: 0.75rem 1.25rem;
  }

  #tfScalpRail {
    margin-left: 0;
  }
}

@media (max-width: 800px) {
  #tfScalpRail {
    margin-left: 0 !important;
  }

  .app {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: max(0.5rem, env(safe-area-inset-top))
      max(0.65rem, env(safe-area-inset-right))
      max(1.25rem, env(safe-area-inset-bottom))
      max(0.65rem, env(safe-area-inset-left));
  }

  .panel-frame {
    border-radius: 20px;
    box-shadow:
      0 12px 40px rgba(0, 0, 0, 0.55),
      inset 0 1px 0 rgba(255, 255, 255, 0.06);
  }

  .dashboard {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  /* Topbar — chỉ mobile */
  .topbar-inner,
  .topbar-zone--center,
  .topbar-status-bar {
    display: contents;
  }

  .topbar {
    display: grid;
    grid-template-columns: 1fr auto auto;
    grid-template-areas:
      "brand live user"
      "price price price"
      "home home home";
    gap: 0.5rem 0.45rem;
    padding: 0.85rem 0.9rem 0.95rem;
    margin-bottom: 0.85rem;
  }

  .brand,
  .topbar-zone--brand {
    grid-area: brand;
    align-self: center;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.15rem;
    min-width: 0;
  }

  .topbar--home-nav .topbar-brand-tagline {
    display: block;
    margin: 0;
    font-size: 0.62rem;
    font-weight: 600;
    color: var(--muted);
    line-height: 1.2;
  }

  .topbar--home-nav .lp-logo__text {
    font-size: 0.9375rem;
  }

  .topbar--home-nav .topbar-user-chip {
    display: none !important;
  }

  .topbar-mid {
    display: contents;
  }

  .api-pill,
  .session-pills {
    display: none;
  }

  .live-pill {
    grid-area: live;
    align-self: center;
    justify-self: end;
    padding: 0.28rem 0.55rem;
    font-size: 0.58rem;
  }

  .spot-box {
    grid-area: price;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    border-radius: 14px;
    text-align: left;
    background: linear-gradient(135deg, rgba(51, 213, 213, 0.14) 0%, rgba(0, 0, 0, 0.42) 55%);
    border: 1px solid rgba(76, 194, 191, 0.32);
    box-shadow:
      0 0 28px rgba(51, 213, 213, 0.1),
      inset 0 1px 0 rgba(255, 255, 255, 0.06);
  }

  .spot-label {
    font-size: 0.58rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--fx-teal-dim);
  }

  .spot-value {
    font-size: clamp(1.45rem, 6vw, 1.75rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1;
  }

  .spot-meta {
    display: none;
  }

  .topbar-actions {
    display: contents;
  }

  .topbar-actions > .topbar-link-home,
  .topbar-actions > .btn-ghost:first-of-type {
    grid-area: home;
    min-height: 46px;
    justify-content: center;
    font-size: 0.74rem;
    font-weight: 700;
    border-radius: 12px;
  }

  .topbar-actions .btn-user {
    grid-area: user;
    align-self: center;
    justify-self: end;
    padding: 0.15rem;
    min-width: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--frame-border);
  }

  .topbar-actions .btn-user-avatar {
    display: grid;
    place-items: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    font-size: 0.78rem;
    font-weight: 800;
    color: #031018;
    background: linear-gradient(135deg, #33d5d5, #51da73);
    box-shadow: 0 2px 10px rgba(51, 213, 213, 0.35);
  }

  .topbar--home-nav .topbar-actions .btn-user-text {
    display: none;
  }

  .card-tf .tf-field--action .btn-analyze--tf {
    min-height: 46px;
    border-radius: 12px;
    box-shadow: 0 8px 22px rgba(51, 213, 213, 0.3);
  }

  /* Signal card — mobile ref ~578×1109 (medallion trái · info giữa · mũi tên phải) */
  .card-signal {
    padding: 1rem 0.75rem 1.1rem;
    border-radius: 20px;
  }

  .card-signal.signal-awaiting .signal-hero {
    min-height: min(18rem, 44vh);
    padding: 1.75rem 1rem 1.5rem;
  }

  .card-signal.signal-awaiting .signal-awaiting {
    padding: 1.75rem 1.25rem;
  }

  .card-signal .card-label {
    margin-bottom: 0.65rem;
    padding: 0;
    font-size: 0.62rem;
  }

  .signal-hero-visual,
  .signal-hero-arrow {
    display: contents;
  }

  .signal-hero {
    position: relative;
    display: grid;
    grid-template-columns: min(128px, 22vw) 1fr;
    grid-template-rows: auto;
    align-items: start;
    column-gap: 0.5rem;
    row-gap: 0.4rem;
    width: 100%;
    margin-bottom: 1.1rem;
    padding-right: min(168px, 29vw);
    min-height: auto;
  }

  .signal-badge {
    grid-column: 1;
    grid-row: 1;
    margin-top: 2.75rem;
    position: static;
    transform: none;
  }

  .signal-medallion {
    width: min(128px, 22vw);
    height: min(128px, 22vw);
  }

  .signal-medallion-text {
    font-size: clamp(1.45rem, 5.2vw, 1.85rem);
  }

  .signal-side-img {
    position: absolute;
    top: calc(2.75rem + (min(128px, 22vw) - min(168px, 29vw)) / 2);
    right: 0.25rem;
    left: auto;
    width: min(168px, 29vw);
    max-height: min(168px, 29vw);
    margin: 0;
    object-fit: contain;
    object-position: center;
    transform: none;
    animation: signalSideFloat 2.6s ease-in-out infinite;
    filter: drop-shadow(0 8px 24px rgba(51, 213, 213, 0.45));
  }

  .signal-side-img.sell {
    filter: drop-shadow(0 8px 24px rgba(239, 68, 68, 0.45));
  }

  .signal-info {
    grid-column: 2;
    grid-row: 1;
    flex: none;
    width: auto;
    max-width: 100%;
    min-width: 8.25rem;
    margin-left: 1.15rem;
    padding: 0;
  }

  .signal-info .checklist,
  #signalChecks {
    display: none;
  }

  .signal-info .signal-title {
    font-size: clamp(1.15rem, 5vw, 1.5rem);
    text-align: left;
    margin-bottom: 0.65rem;
    line-height: 1.12;
    text-shadow: none;
  }

  .signal-info .confidence-wrap {
    margin-bottom: 0.65rem;
    padding: 0;
    background: transparent;
    border: none;
  }

  .signal-info .confidence-head strong {
    font-size: 0.85rem;
  }

  .signal-info .confidence-bar {
    height: 6px;
  }

  .signal-info .signal-meta {
    text-align: left;
    margin-bottom: 0.55rem;
    opacity: 1;
  }

  .signal-info .metrics-row {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.35rem;
    margin-bottom: 0.65rem;
  }

  .signal-info .metrics-row li {
    padding: 0.45rem 0.25rem;
    border-radius: 10px;
    background: rgba(0, 0, 0, 0.25);
    box-shadow: none;
  }

  .signal-info .metrics-row span {
    font-size: 0.55rem;
  }

  .signal-info .metrics-row strong {
    font-size: 0.72rem;
  }

  .rules {
    margin: 0;
    padding: 0.9rem 0.75rem;
    border-radius: 14px;
    background: rgba(0, 0, 0, 0.28);
    border: 1px solid rgba(76, 194, 191, 0.18);
  }

  .levels-heading {
    font-size: 0.58rem;
    letter-spacing: 0.08em;
    margin-bottom: 0.5rem;
  }

  .levels-three {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.35rem;
  }

  .price-card {
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 0.6rem 0.3rem;
    border-left: none;
    border-radius: 12px;
  }

  .price-card.entry strong {
    font-size: 0.88rem;
  }

  .price-card.entry {
    border-color: rgba(51, 213, 213, 0.5);
  }

  .price-card.sl {
    border-color: rgba(239, 68, 68, 0.45);
  }

  .price-card.tp {
    border-color: rgba(34, 197, 94, 0.45);
  }

  .price-card strong {
    font-size: 0.82rem;
  }

  .risk-hint {
    text-align: center;
    opacity: 1;
  }

  /* Chart & sidebar */
  .sidebar {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
  }

  .card-chart {
    border-radius: 20px;
    overflow: hidden;
  }

  .card-head {
    padding: 0.75rem 1rem;
    font-size: 0.78rem;
  }

  .chart-wrap {
    height: clamp(260px, 32vh, 340px);
    min-height: clamp(260px, 32vh, 340px);
  }

  .card-tf {
    border-radius: 20px;
  }

  .card-tf > .card-label {
    padding: 0.85rem 1rem 0.45rem;
  }

  .tf-section {
    padding: 0.8rem 0.9rem 0.9rem;
  }

  .tf-section-head {
    margin-bottom: 0.65rem;
  }

  .tf-pairs {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }

  .tf-rail {
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding: 0.3rem;
  }

  .tf-rail::-webkit-scrollbar {
    display: none;
  }

  .tf-btn {
    flex: 0 0 auto;
    min-width: 3.4rem;
    min-height: 44px;
  }

  #tfScalpRail {
    overflow: hidden;
  }

  #tfScalpRail .tf-btn {
    flex: 1 1 0;
    min-width: 0;
  }

  .tf-btn-refresh {
    min-width: 3.5rem;
  }

  .status {
    font-size: 0.65rem;
    padding: 0.65rem 0.85rem;
    border-radius: 14px;
  }

  /* Giải thích */
  .trade-explain {
    margin-top: 0;
    padding: 1rem 1rem 1.1rem;
    border-radius: 20px;
  }

  .trade-explain-title {
    font-size: 0.62rem;
  }

  .trade-explain-head {
    flex-direction: row;
    align-items: center;
    gap: 0.65rem;
    padding-bottom: 0.75rem;
  }

  .trade-explain-lead {
    font-size: 0.8rem;
    line-height: 1.5;
  }

  .explain-block {
    padding: 0.65rem 0.7rem;
    border-radius: 12px;
    background: rgba(0, 0, 0, 0.25);
    border: 1px solid rgba(76, 194, 191, 0.1);
  }

  .explain-list.explain-metrics li {
    flex-direction: row;
    align-items: center;
  }

  .app-footer {
    margin-top: 0.85rem;
    padding: 0.75rem;
    border-radius: 14px;
    line-height: 1.45;
  }

  .analyze-screen-inner {
    width: min(94vw, 380px);
    border-radius: 22px;
  }
}

/* Mobile dọc ~578×1109 — chart cao hơn như ảnh mẫu */
@media (max-width: 800px) and (min-height: 900px) {
  .chart-wrap {
    height: clamp(300px, 36vh, 400px);
    min-height: clamp(300px, 36vh, 400px);
  }

  .dashboard {
    gap: 0.85rem;
  }
}

/* Analyze Screen - simple blur + subtle rotate */
.analyze-screen {
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.04), transparent 44%),
    linear-gradient(180deg, rgba(0, 8, 3, 0.44), rgba(0, 6, 2, 0.5));
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.analyze-screen-inner {
  width: min(460px, 92vw);
  padding: 1.35rem 1.2rem 1.15rem;
  border-radius: 16px;
  border: 1px solid rgba(74, 222, 128, 0.35);
  background:
    repeating-linear-gradient(
      0deg,
      rgba(10, 22, 12, 0.98) 0px,
      rgba(10, 22, 12, 0.98) 10px,
      rgba(8, 18, 10, 0.98) 10px,
      rgba(8, 18, 10, 0.98) 20px
    );
  box-shadow:
    0 16px 40px rgba(0, 0, 0, 0.45),
    0 0 0 1px rgba(255, 255, 255, 0.03) inset,
    0 0 24px rgba(74, 222, 128, 0.2);
}

.analyze-screen.active .analyze-screen-inner {
  transform: translateY(0) scale(1);
}

.analyze-border-glow {
  border-radius: 16px;
  box-shadow: 0 0 0 1px rgba(74, 222, 128, 0.42);
}

.analyze-scan {
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(74, 222, 128, 0.95), transparent);
  opacity: 0.78;
}

.analyze-hero {
  width: 128px;
  height: 128px;
  margin: 0 auto 0.72rem;
  animation: analyzeHeroTilt 6s ease-in-out infinite;
}

@keyframes analyzeHeroTilt {
  0%, 100% { transform: rotate(0deg); }
  25% { transform: rotate(1.2deg); }
  75% { transform: rotate(-1.2deg); }
}

.analyze-ring-track {
  stroke-width: 6;
}

.analyze-ring-fill {
  stroke-width: 6;
}

.analyze-brand-supper {
  font-size: 0.56rem;
  letter-spacing: 0.3em;
  color: rgba(220, 252, 231, 0.85);
}

.analyze-brand-ai {
  font-size: 1.18rem;
  margin-top: 0.1rem;
  color: #ffffff;
  text-shadow: 0 0 10px rgba(74, 222, 128, 0.38);
}

.analyze-screen-sub {
  margin-bottom: 0.3rem;
  color: rgba(220, 252, 231, 0.72);
}

.analyze-screen-pct {
  margin-bottom: 0.55rem;
  font-size: 2.2rem;
  color: #ffffff;
}

.analyze-steps {
  margin: 0 0 0.55rem;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.28rem;
}

.analyze-steps::before {
  display: none;
}

.analyze-step-item {
  min-height: 30px;
  padding: 0.32rem 0.5rem;
  border-radius: 6px;
  transform: none;
  opacity: 0.8;
  color: rgba(220, 252, 231, 0.64);
  background: rgba(10, 24, 12, 0.65);
  border: 1px solid rgba(74, 222, 128, 0.14);
  font-size: 0.64rem;
}

.analyze-step-item.active {
  color: #f0fdf4;
  border-color: rgba(134, 239, 172, 0.65);
  background: rgba(22, 163, 74, 0.28);
  box-shadow: 0 0 10px rgba(22, 163, 74, 0.22);
}

.analyze-step-item.done {
  color: #ecfdf5;
  border-color: rgba(187, 247, 208, 0.46);
  background: rgba(21, 128, 61, 0.34);
}

.analyze-step-item .step-dot {
  width: 8px;
  height: 8px;
}

.analyze-step-item.done .step-dot {
  width: 12px;
  height: 12px;
  line-height: 12px;
}

.analyze-screen-step {
  margin-bottom: 0.45rem;
  font-size: 0.74rem;
  color: rgba(220, 252, 231, 0.9);
}

.analyze-screen-progress {
  height: 7px;
  margin-bottom: 0.38rem;
  background: rgba(3, 10, 4, 0.62);
  border: 1px solid rgba(74, 222, 128, 0.26);
}

.analyze-screen-bar {
  background: linear-gradient(90deg, #bbf7d0, #4ade80, #22c55e);
  box-shadow: 0 0 9px rgba(74, 222, 128, 0.32);
  transition: width 0.16s cubic-bezier(0.22, 1, 0.36, 1);
}

.analyze-screen-bar::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.42), transparent);
  mix-blend-mode: screen;
}

.analyze-screen-timer {
  font-size: 0.62rem;
  color: rgba(220, 252, 231, 0.86);
}

.analyze-ring-svg,
.analyze-hero-glow {
  opacity: 0.78;
}

/* Analyze Screen final - professional clean */
.analyze-screen {
  background: linear-gradient(180deg, rgba(2, 9, 6, 0.46), rgba(2, 8, 5, 0.54));
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.analyze-screen-inner {
  width: min(460px, 92vw);
  padding: 1.45rem 1.3rem 1.15rem;
  border-radius: 18px;
  border: 1px solid rgba(134, 239, 172, 0.32);
  background: linear-gradient(180deg, rgba(8, 18, 11, 0.96), rgba(6, 14, 9, 0.97));
  box-shadow:
    0 18px 46px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 0 22px rgba(34, 197, 94, 0.14);
}

.analyze-border-glow {
  border-radius: 18px;
  box-shadow: 0 0 0 1px rgba(134, 239, 172, 0.34);
}

.analyze-scan {
  height: 1px;
  top: 0;
  background: linear-gradient(90deg, transparent, rgba(74, 222, 128, 0.84), transparent);
  opacity: 0.7;
}

.analyze-hero {
  width: 132px;
  height: 132px;
  margin: 0 auto 0.8rem;
  animation: analyzeHeroTilt 6.5s ease-in-out infinite;
}

@keyframes analyzeHeroTilt {
  0%, 100% { transform: rotate(0deg); }
  25% { transform: rotate(0.8deg); }
  75% { transform: rotate(-0.8deg); }
}

.analyze-ring-track,
.analyze-ring-fill {
  stroke-width: 6;
}

.analyze-brand-supper {
  font-size: 0.62rem;
  letter-spacing: 0.26em;
  color: rgba(220, 252, 231, 0.9);
}

.analyze-brand-ai {
  font-size: 1.28rem;
  margin-top: 0.1rem;
  color: #ffffff;
  text-shadow: 0 0 12px rgba(74, 222, 128, 0.35);
}

.analyze-screen-sub {
  margin-bottom: 0.45rem;
  color: rgba(220, 252, 231, 0.82);
}

.analyze-screen-pct {
  margin-bottom: 0.85rem;
  font-size: 2.45rem;
  color: #ffffff;
}

.analyze-screen-step {
  margin-bottom: 0.55rem;
  color: #dcfce7;
}

.analyze-steps {
  margin: 0 0 0.65rem;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.32rem;
}

.analyze-steps::before {
  display: none;
}

.analyze-step-item {
  min-height: 32px;
  padding: 0.36rem 0.52rem;
  border-radius: 8px;
  transform: none;
  opacity: 0.88;
  color: rgba(220, 252, 231, 0.72);
  background: rgba(10, 24, 12, 0.55);
  border: 1px solid rgba(74, 222, 128, 0.18);
  font-size: 0.66rem;
}

.analyze-step-item.active {
  color: #f0fdf4;
  border-color: rgba(134, 239, 172, 0.62);
  background: rgba(22, 163, 74, 0.24);
  box-shadow: 0 0 10px rgba(22, 163, 74, 0.2);
}

.analyze-step-item.done {
  color: #ecfdf5;
  border-color: rgba(187, 247, 208, 0.5);
  background: rgba(21, 128, 61, 0.3);
}

.analyze-step-item .step-dot {
  width: 8px;
  height: 8px;
}

.analyze-step-item.done .step-dot {
  width: 12px;
  height: 12px;
  line-height: 12px;
}

.analyze-screen-progress {
  height: 8px;
  margin-bottom: 0.45rem;
  background: rgba(3, 10, 4, 0.62);
  border: 1px solid rgba(74, 222, 128, 0.26);
}

.analyze-screen-bar {
  background: linear-gradient(90deg, #bbf7d0, #4ade80, #22c55e);
  box-shadow: 0 0 9px rgba(74, 222, 128, 0.32);
  transition: width 0.16s cubic-bezier(0.22, 1, 0.36, 1);
}

.analyze-screen-bar::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.42), transparent);
  mix-blend-mode: screen;
}

.analyze-screen-timer {
  font-size: 0.62rem;
  color: rgba(220, 252, 231, 0.86);
}

@media (prefers-reduced-motion: reduce) {
  .signal-side-img {
    animation: none !important;
  }


  .analyze-screen.active .analyze-scan,
  .analyze-ring-orbit,
  .analyze-hero-glow,
  .chart-loader-ring {
    animation: none !important;
  }
}

/* Analyze Screen v8 - futuristic AI dashboard (final) */
.analyze-screen {
  background:
    radial-gradient(circle at 18% 15%, rgba(34, 211, 238, 0.16), transparent 36%),
    radial-gradient(circle at 82% 78%, rgba(34, 197, 94, 0.14), transparent 38%),
    linear-gradient(180deg, rgba(2, 10, 16, 0.76), rgba(2, 6, 10, 0.84)) !important;
  backdrop-filter: blur(10px) saturate(1.1) !important;
  -webkit-backdrop-filter: blur(10px) saturate(1.1) !important;
}

body.analyze-lock .app {
  filter: brightness(0.78) saturate(0.95) !important;
}

.analyze-screen-inner {
  width: min(520px, 92vw) !important;
  padding: 1.3rem 1.2rem 1rem !important;
  border-radius: 18px !important;
  border: 1px solid rgba(56, 189, 248, 0.32) !important;
  background: linear-gradient(180deg, rgba(6, 16, 28, 0.94), rgba(5, 12, 22, 0.96)) !important;
  box-shadow:
    0 24px 64px rgba(0, 0, 0, 0.58),
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 0 36px rgba(34, 211, 238, 0.18) !important;
}

.analyze-border-glow {
  display: block !important;
  opacity: 1 !important;
  border-radius: 18px !important;
  box-shadow:
    0 0 0 1px rgba(56, 189, 248, 0.34),
    0 0 22px rgba(34, 211, 238, 0.24) !important;
}

.analyze-screen-bg {
  display: block !important;
}

.analyze-scan {
  display: block !important;
  height: 2px !important;
  top: 0 !important;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(34, 211, 238, 0.9),
    rgba(255, 255, 255, 0.86),
    rgba(16, 185, 129, 0.85),
    transparent
  ) !important;
  opacity: 0.78 !important;
  animation: analyzeHudScan 2.5s cubic-bezier(0.35, 0.08, 0.2, 0.98) infinite !important;
}

@keyframes analyzeHudScan {
  0% { top: 0; opacity: 0; }
  10% { opacity: 0.78; }
  90% { opacity: 0.78; }
  100% { top: 100%; opacity: 0; }
}

.analyze-hero {
  width: 170px !important;
  height: 170px !important;
  margin: 0 auto 0.55rem !important;
  animation: analyzeHudSpin 7.4s linear infinite !important;
}

.analyze-hero::before,
.analyze-hero::after {
  display: none !important;
}

.analyze-ring-track {
  stroke: rgba(148, 163, 184, 0.24) !important;
  stroke-width: 6 !important;
}

.analyze-ring-fill {
  stroke: #e2e8f0 !important;
  stroke-width: 6 !important;
  filter: drop-shadow(0 0 10px rgba(34, 211, 238, 0.35)) !important;
}

.analyze-ring-orbit {
  stroke: rgba(34, 211, 238, 0.62) !important;
  stroke-width: 1.3 !important;
  stroke-dasharray: 6 8 !important;
  animation: analyzeHudOrbit 3.2s linear infinite !important;
}

.analyze-hero-glow {
  display: block !important;
  inset: 10% !important;
  opacity: 1 !important;
  background: radial-gradient(circle, rgba(34, 211, 238, 0.24) 0%, rgba(16, 185, 129, 0.08) 42%, transparent 72%) !important;
}

@keyframes analyzeHudSpin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes analyzeHudOrbit {
  from { transform: rotate(0deg); }
  to { transform: rotate(-360deg); }
}

.analyze-brand-mark,
.analyze-screen-sub,
.analyze-screen-timer {
  display: none !important;
}

.analyze-screen-pct {
  display: flex !important;
  margin-bottom: 0.45rem !important;
  justify-content: center !important;
  color: #e2e8f0 !important;
  font-size: 2rem !important;
  text-shadow:
    0 0 14px rgba(34, 211, 238, 0.3),
    0 0 28px rgba(16, 185, 129, 0.16) !important;
}

.analyze-screen-step {
  display: block !important;
  margin: 0 0 0.55rem !important;
  text-align: center !important;
  font-size: 0.84rem !important;
  font-weight: 700 !important;
  letter-spacing: 0.12em !important;
  text-transform: uppercase !important;
  color: rgba(186, 230, 253, 0.95) !important;
  text-shadow:
    0 0 10px rgba(34, 211, 238, 0.35),
    0 0 18px rgba(16, 185, 129, 0.2) !important;
}

.analyze-screen-step::before {
  content: none !important;
}

.analyze-steps {
  display: flex !important;
  flex-direction: column !important;
  margin: 0 0 0.55rem !important;
  gap: 0.28rem !important;
}

.analyze-step-item {
  min-height: 32px !important;
  padding: 0.35rem 0.52rem !important;
  border-radius: 8px !important;
  color: rgba(203, 213, 225, 0.9) !important;
  background: rgba(15, 23, 42, 0.62) !important;
  border: 1px solid rgba(56, 189, 248, 0.24) !important;
  font-size: 0.64rem !important;
}

.analyze-step-item.active {
  color: #ecfeff !important;
  border-color: rgba(56, 189, 248, 0.62) !important;
  background: linear-gradient(90deg, rgba(14, 165, 233, 0.26), rgba(16, 185, 129, 0.16)) !important;
  box-shadow: 0 0 10px rgba(14, 165, 233, 0.24) !important;
}

.analyze-step-item.done {
  color: #f0fdf4 !important;
  border-color: rgba(74, 222, 128, 0.56) !important;
  background: rgba(22, 163, 74, 0.24) !important;
}

.analyze-screen-progress {
  display: block !important;
  height: 8px !important;
  margin-bottom: 0 !important;
  background: rgba(2, 6, 23, 0.55) !important;
  border: 1px solid rgba(56, 189, 248, 0.3) !important;
}

.analyze-screen-bar {
  width: 0% !important;
  height: 100% !important;
  border-radius: inherit !important;
  background: linear-gradient(90deg, #22d3ee, #38bdf8, #10b981) !important;
  box-shadow: 0 0 10px rgba(34, 211, 238, 0.35) !important;
}

/* Logo SUPPER AI — đồng bộ landing */
.lp-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  text-decoration: none;
  flex-shrink: 0;
  font-family: "Plus Jakarta Sans", system-ui, -apple-system, sans-serif;
}

.lp-logo__mark {
  display: grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  border-radius: 8px;
  background: var(--lp-green);
  color: #fff;
  font-size: 0.625rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.lp-logo__text {
  font-size: 0.9375rem;
  font-weight: 700;
  color: #f9fafb;
  letter-spacing: -0.03em;
}

.lp-logo__text em {
  font-style: normal;
  color: var(--lp-green-light);
  font-weight: 800;
}

.topbar .lp-logo__text {
  color: #f9fafb;
}
