:root {
  color-scheme: dark;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-top: env(safe-area-inset-top, 0px);
  --nav-height: 98px;

  --bg-a: #02060f;
  --bg-b: #07122b;
  --card: rgba(9, 20, 45, 0.9);
  --card-2: rgba(6, 16, 38, 0.96);
  --line: rgba(94, 149, 245, 0.34);
  --line-soft: rgba(94, 149, 245, 0.2);
  --text: #eaf2ff;
  --text-soft: #93abc9;
  --brand-1: #4b8df2;
  --brand-2: #23d5d8;
  --ok: #37da89;
  --danger: #ff6883;
  --warn: #ffd173;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  width: 100%;
  min-height: 100%;
}

body {
  font-family: "Manrope", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at 14% 6%, rgba(58, 112, 213, 0.32), transparent 44%),
    radial-gradient(circle at 84% 90%, rgba(28, 171, 192, 0.16), transparent 38%),
    linear-gradient(180deg, #02060f 0%, #020815 52%, #01040b 100%);
  color: var(--text);
  overflow-x: hidden;
}

.bg-layer {
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 50% 45%, rgba(57, 121, 228, 0.14), transparent 52%),
    radial-gradient(circle at 50% 92%, rgba(35, 213, 216, 0.12), transparent 30%);
  z-index: 0;
}

.app-shell {
  position: relative;
  z-index: 1;
  width: min(100%, 920px);
  margin: 0 auto;
  min-height: 100dvh;
  padding: calc(8px + var(--safe-top)) 14px calc(var(--nav-height) + var(--safe-bottom) + 20px);
}

.brand-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 0 0 10px;
}

.brand-logo {
  margin: 0;
  font-size: clamp(34px, 5.8vw, 56px);
  letter-spacing: 0.02em;
  font-weight: 800;
  color: #40a4ff;
}

.brand-logo span {
  color: #eff6ff;
}

.top-btn {
  height: 38px;
  min-width: 48px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(8, 18, 39, 0.82);
  color: #c9dcf8;
  font-size: 18px;
  cursor: pointer;
}

.screen {
  display: none;
  width: 100%;
}

.screen.active {
  display: block;
  animation: screenFadeIn 260ms ease;
}

.card {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: linear-gradient(160deg, var(--card), var(--card-2));
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.46);
  padding: 18px;
  margin-bottom: 14px;
  transition: transform 180ms ease, border-color 220ms ease, box-shadow 220ms ease;
}

.screen.active .card {
  animation: cardEnter 220ms ease;
}

.card::before {
  content: "";
  position: absolute;
  left: -30%;
  top: -30%;
  width: 70%;
  height: 60%;
  background: radial-gradient(circle, rgba(67, 138, 241, 0.2), transparent 62%);
  pointer-events: none;
}

.card-primary {
  border-color: rgba(80, 156, 248, 0.45);
  box-shadow:
    0 18px 44px rgba(0, 0, 0, 0.5),
    0 0 0 1px rgba(88, 151, 244, 0.12) inset;
}

.card-secondary {
  border-color: rgba(80, 132, 213, 0.34);
  background: linear-gradient(165deg, rgba(8, 19, 43, 0.9), rgba(5, 14, 33, 0.96));
}

.card-status {
  border-color: rgba(90, 156, 231, 0.28);
  background: linear-gradient(160deg, rgba(8, 18, 41, 0.86), rgba(6, 14, 33, 0.92));
}

#signalsScreen .card {
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
}

.welcome-hero-card {
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
}

.welcome-kicker {
  margin: 0;
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid rgba(109, 162, 241, 0.3);
  color: #97b5dd;
  background: rgba(10, 24, 52, 0.62);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.welcome-hero-card h2 {
  margin: 10px 0 0;
  font-size: clamp(34px, 6vw, 56px);
  line-height: 1.06;
}

.welcome-subtitle {
  margin: 10px 0 0;
  color: #9eb7d9;
  font-size: 16px;
  line-height: 1.45;
  max-width: 640px;
}

.welcome-points {
  margin: 12px 0 0;
  padding-left: 18px;
  color: #d8e9ff;
  line-height: 1.46;
  display: grid;
  gap: 4px;
}

.welcome-hero-media {
  margin-top: 12px;
  border: 1px solid rgba(99, 149, 230, 0.34);
  border-radius: 16px;
  overflow: hidden;
  background: #02050c;
}

.welcome-hero-media video {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  opacity: 0.92;
}

.btn-welcome-start {
  margin-top: 14px;
  width: 100%;
  min-height: 56px;
  font-size: clamp(20px, 3.4vw, 30px);
  font-weight: 800;
}

.access-card {
  border-color: rgba(239, 95, 133, 0.4);
}

.access-step {
  margin: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid rgba(111, 157, 236, 0.28);
  background: rgba(13, 31, 63, 0.76);
  color: #aec4e4;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.03em;
}

.access-card h3 {
  margin: 10px 0 0;
  font-size: clamp(26px, 5vw, 40px);
  line-height: 1.06;
}

.access-card p {
  margin: 8px 0 0;
  color: var(--text-soft);
  line-height: 1.45;
  font-size: 14px;
}

.access-actions {
  margin-top: 12px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

.selectors-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.selectors-card {
  overflow: visible;
}

.selector-pill {
  min-height: 58px;
  border-radius: 16px;
  border: 1px solid var(--line-soft);
  background: rgba(3, 9, 24, 0.8);
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
}

.selector-icon {
  font-size: 20px;
  flex: 0 0 auto;
}

.pair-picker {
  position: relative;
  padding: 0;
  z-index: 60;
}

.selector-trigger {
  width: 100%;
  min-height: 58px;
  border: 0;
  outline: none;
  background: transparent;
  color: #edf5ff;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 12px;
  border-radius: 16px;
  cursor: pointer;
  font-family: inherit;
}

.selector-trigger:disabled {
  cursor: not-allowed;
  opacity: 0.7;
}

.selector-trigger-label {
  flex: 1 1 auto;
  min-width: 0;
  text-align: left;
  font-weight: 700;
  font-size: clamp(18px, 3.3vw, 28px);
  color: #edf5ff;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.selector-trigger-caret {
  font-size: 24px;
  line-height: 1;
  color: #9eb8dd;
  transform: translateY(-1px);
  transition: transform 180ms ease, color 180ms ease;
}

.selector-trigger[aria-expanded="true"] .selector-trigger-caret {
  transform: rotate(180deg) translateY(1px);
  color: #75b6ff;
}

.pair-menu {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  width: min(440px, calc(100vw - 46px));
  border-radius: 16px;
  border: 1px solid rgba(90, 145, 238, 0.42);
  background:
    radial-gradient(circle at 72% 8%, rgba(56, 128, 233, 0.18), transparent 48%),
    linear-gradient(180deg, rgba(7, 20, 46, 0.98) 0%, rgba(4, 13, 33, 0.99) 100%);
  box-shadow: 0 24px 52px rgba(2, 7, 18, 0.7), 0 0 0 1px rgba(64, 131, 237, 0.2) inset;
  overflow: hidden;
  z-index: 90;
}

.pair-search-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-bottom: 1px solid rgba(92, 142, 223, 0.2);
  background: rgba(7, 20, 45, 0.86);
}

.pair-search-icon {
  font-size: 18px;
  opacity: 0.9;
}

.pair-search-input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: none;
  color: #e9f3ff;
  background: transparent;
  font: inherit;
  font-weight: 600;
  font-size: 19px;
}

.pair-search-input::placeholder {
  color: #89a5cd;
}

.pair-menu-kicker {
  margin: 0;
  padding: 8px 12px 6px;
  color: #89a7d1;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.pair-options {
  max-height: 330px;
  overflow: auto;
  padding-bottom: 4px;
}

.pair-options::-webkit-scrollbar {
  width: 8px;
}

.pair-options::-webkit-scrollbar-thumb {
  border-radius: 8px;
  background: rgba(104, 155, 237, 0.46);
}

.pair-option {
  width: 100%;
  border: 0;
  outline: none;
  background: transparent;
  color: #e5f0ff;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  text-align: left;
  cursor: pointer;
  border-top: 1px solid rgba(83, 132, 207, 0.08);
  transition: background-color 150ms ease, color 150ms ease;
}

.pair-option:hover {
  background: rgba(34, 72, 136, 0.34);
}

.pair-option.active {
  background: rgba(47, 88, 164, 0.52);
  color: #6eb3ff;
}

.pair-option-flag {
  font-size: 24px;
  line-height: 1;
}

.pair-option-label {
  font-size: clamp(18px, 3.2vw, 34px);
  font-weight: 700;
  line-height: 1.1;
}

.pair-option-payout {
  color: #8cdcc8;
  font-size: 14px;
  font-weight: 700;
}

.pair-option-empty {
  padding: 14px 12px 16px;
  color: #9fb8dc;
  font-size: 16px;
}

.expiry-picker {
  position: relative;
  padding: 0;
  z-index: 58;
}

.expiry-menu {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  width: min(280px, calc(100vw - 46px));
  border-radius: 16px;
  border: 1px solid rgba(90, 145, 238, 0.42);
  background:
    radial-gradient(circle at 72% 8%, rgba(56, 128, 233, 0.18), transparent 48%),
    linear-gradient(180deg, rgba(7, 20, 46, 0.98) 0%, rgba(4, 13, 33, 0.99) 100%);
  box-shadow: 0 24px 52px rgba(2, 7, 18, 0.7), 0 0 0 1px rgba(64, 131, 237, 0.2) inset;
  overflow: hidden;
  z-index: 90;
}

.expiry-options {
  max-height: 430px;
  overflow: auto;
  padding: 6px 8px 8px;
}

.expiry-options::-webkit-scrollbar {
  width: 8px;
}

.expiry-options::-webkit-scrollbar-thumb {
  border-radius: 8px;
  background: rgba(104, 155, 237, 0.46);
}

.expiry-option {
  width: 100%;
  border: 0;
  outline: none;
  background: transparent;
  color: #e5f0ff;
  display: block;
  padding: 10px 14px;
  text-align: left;
  font: inherit;
  font-weight: 700;
  font-size: clamp(18px, 3.1vw, 31px);
  line-height: 1.1;
  border-radius: 14px;
  cursor: pointer;
  transition: background-color 150ms ease, color 150ms ease;
}

.expiry-option:hover {
  background: rgba(34, 72, 136, 0.34);
}

.expiry-option.active {
  color: #0b1a32;
  background: linear-gradient(98deg, #1f8ea0 0%, #29cfd5 100%);
}

.selector-select {
  width: 100%;
  border: 0;
  outline: none;
  background: transparent;
  color: #edf5ff;
  font: inherit;
  font-weight: 700;
  font-size: clamp(18px, 3.3vw, 28px);
  appearance: none;
  cursor: pointer;
}

.selector-select option {
  background: #06142c;
  color: #ebf3ff;
}

.meta-box {
  margin-top: 10px;
  border: 1px solid var(--line-soft);
  border-radius: 16px;
  min-height: 82px;
  padding: 16px;
  display: grid;
  place-items: center;
  text-align: center;
  background: rgba(8, 21, 46, 0.5);
}

.signal-meta {
  margin: 0;
  color: #93abc9;
  font-size: clamp(16px, 2.2vw, 22px);
  font-weight: 500;
  line-height: 1.35;
  letter-spacing: 0.01em;
}

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

.signal-flow-step {
  min-height: 40px;
  border: 1px solid rgba(90, 136, 212, 0.24);
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #94adcd;
  background: rgba(9, 21, 45, 0.52);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.02em;
  transition: all 180ms ease;
}

.signal-flow-step.active {
  color: #eff8ff;
  border-color: rgba(95, 166, 255, 0.45);
  background: linear-gradient(100deg, rgba(67, 127, 224, 0.66), rgba(39, 188, 205, 0.55));
  box-shadow: 0 0 18px rgba(62, 152, 242, 0.2);
}

.winrate-wrap {
  margin-top: 8px;
}

.winrate-label {
  margin: 0;
  text-align: center;
  color: var(--text-soft);
  font-size: clamp(18px, 2.8vw, 28px);
  font-weight: 600;
}

.winrate-ring-wrap {
  width: 190px;
  height: 190px;
  margin: 8px auto 0;
  position: relative;
}

.winrate-ring {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.ring-bg,
.ring-value {
  fill: none;
  stroke-width: 10;
  stroke-linecap: round;
}

.ring-bg {
  stroke: rgba(118, 156, 219, 0.25);
}

.ring-value {
  stroke: url(#ringGradient);
  stroke: #2dd8d4;
  stroke-dasharray: 314.16;
  stroke-dashoffset: 31.41;
  transition: stroke-dashoffset 420ms ease;
}

.winrate-ring-wrap::before {
  content: "";
  position: absolute;
  inset: 18px;
  border-radius: 50%;
  border: 1px solid rgba(114, 165, 249, 0.24);
  background: radial-gradient(circle at 38% 18%, rgba(65, 127, 240, 0.35), rgba(6, 16, 36, 0.86));
}

.winrate-value {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-size: 58px;
  font-weight: 800;
  color: #f2f8ff;
}

.btn {
  border: 0;
  border-radius: 14px;
  min-height: 44px;
  font-family: inherit;
  font-weight: 700;
  cursor: pointer;
  transition: transform 120ms ease, box-shadow 180ms ease, filter 160ms ease, opacity 180ms ease;
}

.btn:hover {
  filter: brightness(1.05);
}

.btn:active {
  transform: translateY(1px) scale(0.995);
}

.btn-primary {
  color: #f6fbff;
  background: linear-gradient(95deg, #4d82e5 0%, #41a2f1 45%, #2ad6d7 100%);
  box-shadow: 0 12px 28px rgba(57, 130, 231, 0.32);
}

.btn-ghost {
  color: #acc4e8;
  border: 1px solid var(--line);
  background: rgba(8, 18, 38, 0.58);
}

.btn-success {
  color: #eafff2;
  background: linear-gradient(100deg, #1d925d, #2dd676);
}

.btn-danger {
  color: #fff0f4;
  background: linear-gradient(100deg, #a72b4f, #db5073);
}

.btn-xl {
  margin-top: 12px;
  width: 100%;
  min-height: 66px;
  font-size: clamp(28px, 4.6vw, 46px);
  font-weight: 800;
}

.live-card {
  border-color: rgba(85, 215, 176, 0.3);
}

.live-card.generating {
  border-color: rgba(83, 165, 255, 0.56);
  box-shadow:
    0 16px 40px rgba(0, 0, 0, 0.46),
    0 0 0 1px rgba(70, 161, 255, 0.18) inset,
    0 0 24px rgba(54, 165, 255, 0.22);
  animation: cardPulse 1.55s ease-in-out infinite;
}

.live-card.generating::after {
  content: "";
  position: absolute;
  inset: -30% -40%;
  background: linear-gradient(
    110deg,
    rgba(65, 161, 255, 0) 35%,
    rgba(75, 177, 255, 0.26) 49%,
    rgba(54, 211, 215, 0.22) 53%,
    rgba(65, 161, 255, 0) 67%
  );
  transform: translateX(-68%);
  pointer-events: none;
  animation: scanSweep 1.35s linear infinite;
}

.live-card.signal-reveal .live-direction {
  animation: directionReveal 560ms cubic-bezier(0.2, 0.78, 0.18, 1);
}

.live-card.signal-reveal {
  animation: signalCardReveal 560ms cubic-bezier(0.18, 0.84, 0.22, 1);
}

.live-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}

.live-kicker {
  margin: 0;
  font-size: 11px;
  letter-spacing: 0.16em;
  color: #7ea8df;
}

.live-head h2 {
  margin: 6px 0 0;
  font-size: clamp(34px, 5.8vw, 56px);
  line-height: 1.02;
  font-weight: 700;
  word-break: break-word;
}

.live-direction-wrap {
  margin-top: 14px;
}

.live-direction-label {
  margin: 0 0 4px;
  color: #86a3ca;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 0 16px;
  border-radius: 999px;
  border: 1px solid var(--line-soft);
  font-size: 13px;
  font-weight: 800;
  white-space: nowrap;
}

.badge-live {
  border-color: rgba(76, 221, 161, 0.45);
  color: #94ffd0;
  background: rgba(10, 41, 30, 0.62);
}

.badge-loss {
  border-color: rgba(255, 111, 141, 0.5);
  color: #ffc0cf;
  background: rgba(57, 16, 28, 0.62);
}

.badge-warn,
.badge-wait {
  border-color: rgba(255, 209, 115, 0.45);
  color: #ffe6ae;
  background: rgba(58, 45, 17, 0.62);
}

.live-direction {
  margin: 0;
  font-size: clamp(34px, 6.5vw, 64px);
  font-weight: 800;
  line-height: 1.03;
  word-break: break-word;
}

.live-direction.up {
  color: #38d58f;
}

.live-direction.down {
  color: #ff708f;
}

.live-direction.teaser {
  color: #b7cbe8;
}

.live-direction.generating {
  color: #c8dbf8;
  background: linear-gradient(90deg, #e3f0ff 12%, #80c6ff 44%, #d6f8ff 76%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  text-shadow: 0 0 20px rgba(76, 180, 255, 0.22);
  animation: textPulse 900ms ease-in-out infinite;
}

.search-state-box {
  margin-top: 12px;
  border-color: rgba(75, 152, 245, 0.34);
  background: linear-gradient(160deg, rgba(7, 19, 43, 0.86), rgba(8, 20, 46, 0.75));
}

.search-state-title {
  margin: 0;
  color: #d8eaff;
  font-size: 17px;
  font-weight: 800;
}

.search-state-line {
  margin-top: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: #a9c2e1;
  font-size: 15px;
}

.search-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #2fd7d7;
  box-shadow: 0 0 14px rgba(47, 215, 215, 0.7);
  animation: searchPulse 920ms ease-in-out infinite;
}

.search-state-steps {
  margin-top: 10px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.search-step-item {
  min-height: 32px;
  border: 1px solid rgba(86, 131, 204, 0.25);
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(9, 23, 49, 0.72);
  color: #86a7d0;
  font-size: 12px;
  font-weight: 700;
}

.search-step-item.active {
  color: #ebf6ff;
  border-color: rgba(103, 169, 251, 0.54);
  background: rgba(44, 138, 216, 0.32);
}

.trend-box {
  margin-top: 12px;
  border: 1px solid var(--line-soft);
  border-radius: 16px;
  background: rgba(6, 17, 41, 0.72);
  padding: 12px;
}

.trend-head {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
  color: #93afd2;
  font-size: 14px;
  font-weight: 600;
}

.trend-head strong {
  color: #dceeff;
  font-size: 15px;
  font-weight: 800;
}

.trend-track {
  margin-top: 10px;
  height: 14px;
  border-radius: 999px;
  border: 1px solid rgba(82, 123, 190, 0.42);
  background: rgba(10, 25, 56, 0.76);
  overflow: hidden;
}

.trend-fill {
  display: block;
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #33bd7f, #2ed4d4);
  transition: width 260ms ease;
}

.trend-scale {
  margin-top: 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  color: #8da8cc;
  font-size: 13px;
  font-weight: 600;
}

.trend-scale strong {
  color: #e5f4ff;
  font-size: 18px;
  font-weight: 800;
}

.trend-reco-box {
  margin-top: 12px;
  background: rgba(7, 18, 40, 0.7);
}

.trend-reco-title {
  margin-bottom: 6px !important;
  color: #e2edf9 !important;
  font-size: 18px !important;
  font-weight: 800 !important;
}

.pro-direction-gate {
  margin-top: 12px;
  border: 1px solid rgba(88, 142, 224, 0.42);
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(9, 21, 48, 0.82), rgba(6, 14, 33, 0.78));
  padding: 12px;
}

.pro-direction-text {
  margin: 0;
  text-align: center;
  color: #bccde7;
  font-size: clamp(28px, 3.5vw, 42px);
  font-weight: 700;
  line-height: 1.16;
}

.pro-access-btn {
  margin-top: 10px;
  min-height: 46px;
  width: min(420px, 100%);
  display: block;
  margin-left: auto;
  margin-right: auto;
  border-radius: 999px;
  font-size: clamp(18px, 2.5vw, 30px);
  font-weight: 800;
}

.btn-find-signal {
  margin-top: 12px;
  width: 100%;
  min-height: 70px;
  border-radius: 20px;
  font-size: clamp(28px, 4.1vw, 48px);
  font-weight: 800;
  letter-spacing: 0.01em;
  background: linear-gradient(96deg, #375ba9 0%, #3c6fbe 48%, #4d8fd6 100%);
  box-shadow:
    0 16px 34px rgba(28, 77, 154, 0.32),
    0 0 0 1px rgba(112, 162, 255, 0.2) inset;
}

.btn-find-signal:disabled {
  opacity: 0.92;
  cursor: not-allowed;
}

.timer-box {
  margin-top: 12px;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 14px;
  align-items: center;
}

.timer-ring-wrap {
  position: relative;
  width: 92px;
  height: 92px;
  flex: 0 0 auto;
}

.timer-ring {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.timer-ring-bg,
.timer-ring-value {
  fill: none;
  stroke-width: 8;
  stroke-linecap: round;
}

.timer-ring-bg {
  stroke: rgba(104, 141, 201, 0.3);
}

.timer-ring-value {
  stroke: #35d5d7;
  stroke-dasharray: 326.73;
  stroke-dashoffset: 326.73;
  transition: stroke-dashoffset 250ms linear;
}

.timer-ring-text {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-size: 20px;
  font-weight: 800;
  color: #f2f8ff;
}

.timer-content {
  min-width: 0;
}

.timer-row {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
  color: #9bb2d2;
  font-size: 16px;
}

.timer-row strong {
  font-size: 34px;
  color: #f2f8ff;
  letter-spacing: 0.01em;
}

.timer-track {
  margin-top: 7px;
  height: 13px;
  border-radius: 999px;
  border: 1px solid rgba(92, 134, 200, 0.42);
  background: rgba(13, 32, 66, 0.7);
  overflow: hidden;
}

.timer-track.generating {
  border-color: rgba(92, 186, 255, 0.5);
  box-shadow: 0 0 0 1px rgba(60, 163, 255, 0.14) inset;
}

.timer-fill {
  display: block;
  height: 100%;
  width: 100%;
  background: linear-gradient(90deg, #47a0ff, #2ad8d6);
  transition: width 230ms linear;
}

.timer-fill.generating {
  background:
    linear-gradient(
      110deg,
      rgba(255, 255, 255, 0.22) 8%,
      rgba(255, 255, 255, 0.04) 22%,
      rgba(255, 255, 255, 0.22) 32%,
      rgba(39, 208, 211, 0.95) 52%,
      rgba(70, 165, 255, 0.95) 82%
    );
  background-size: 220% 100%;
  animation: timerFlow 980ms linear infinite;
}

@keyframes cardPulse {
  0%, 100% {
    transform: translateZ(0);
    box-shadow:
      0 16px 40px rgba(0, 0, 0, 0.46),
      0 0 0 1px rgba(70, 161, 255, 0.18) inset,
      0 0 24px rgba(54, 165, 255, 0.18);
  }
  50% {
    transform: translateY(-1px);
    box-shadow:
      0 19px 46px rgba(0, 0, 0, 0.5),
      0 0 0 1px rgba(70, 161, 255, 0.28) inset,
      0 0 32px rgba(54, 165, 255, 0.28);
  }
}

@keyframes scanSweep {
  from {
    transform: translateX(-62%);
  }
  to {
    transform: translateX(64%);
  }
}

@keyframes textPulse {
  0%, 100% {
    opacity: 0.95;
    transform: translateY(0);
  }
  50% {
    opacity: 1;
    transform: translateY(-0.5px);
  }
}

@keyframes timerFlow {
  from {
    background-position: 0% 50%;
  }
  to {
    background-position: 210% 50%;
  }
}

@keyframes directionReveal {
  0% {
    opacity: 0;
    transform: translateY(8px) scale(0.97);
    filter: blur(1px);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
}

@keyframes signalCardReveal {
  0% {
    opacity: 0;
    transform: translateY(14px) scale(0.96);
    filter: blur(1px);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
}

@keyframes scanRingPulse {
  0% {
    opacity: 0.54;
    transform: translate(-50%, -50%) scale(0.28);
  }
  80% {
    opacity: 0.1;
    transform: translate(-50%, -50%) scale(1.02);
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(1.1);
  }
}

@keyframes scanCorePulse {
  0%, 100% {
    transform: translate(-50%, -50%) scale(0.94);
    opacity: 0.76;
  }
  50% {
    transform: translate(-50%, -50%) scale(1.08);
    opacity: 1;
  }
}

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

@keyframes scanDotOrbitA {
  0% { transform: translate(0, 0) scale(0.9); }
  33% { transform: translate(10px, -8px) scale(1); }
  66% { transform: translate(-9px, 7px) scale(0.82); }
  100% { transform: translate(0, 0) scale(0.9); }
}

@keyframes scanDotOrbitB {
  0% { transform: translate(0, 0) scale(0.82); }
  33% { transform: translate(-10px, -8px) scale(1); }
  66% { transform: translate(8px, 9px) scale(0.88); }
  100% { transform: translate(0, 0) scale(0.82); }
}

@keyframes scanDotOrbitC {
  0% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(8px, 9px) scale(0.84); }
  66% { transform: translate(-10px, -7px) scale(0.92); }
  100% { transform: translate(0, 0) scale(1); }
}

@keyframes searchPulse {
  0%, 100% {
    opacity: 0.5;
    transform: scale(0.9);
  }
  50% {
    opacity: 1;
    transform: scale(1);
  }
}

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

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

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

.status-box {
  margin-top: 12px;
  border: 1px solid var(--line-soft);
  border-radius: 16px;
  background: rgba(6, 17, 39, 0.66);
  padding: 12px;
}

.status-box p {
  margin: 0;
  color: #a6bddc;
  font-size: 15px;
  line-height: 1.4;
}

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

.result-actions .btn {
  min-height: 48px;
  font-size: 16px;
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}

.section-head h2 {
  margin: 0;
  font-size: clamp(30px, 4.8vw, 46px);
  font-weight: 800;
}

.history-tools {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 8px;
  margin-bottom: 10px;
}

.history-tools input,
.history-tools select,
.faq-search-input,
.uid-row input,
.chat-compose input {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line-soft);
  border-radius: 12px;
  background: rgba(3, 9, 24, 0.8);
  color: #e8f2ff;
  font: inherit;
  padding: 0 12px;
  outline: none;
}

.history-tools input::placeholder,
.faq-search-input::placeholder,
.uid-row input::placeholder,
.chat-compose input::placeholder {
  color: #708cb3;
}

.history-list {
  display: grid;
  gap: 8px;
}

.history-item {
  border: 1px solid var(--line-soft);
  border-radius: 14px;
  background: rgba(5, 14, 33, 0.74);
  padding: 11px;
}

.history-item-head {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
}

.history-item-head strong {
  font-size: 15px;
}

.history-item-meta {
  margin-top: 6px;
  color: #9ab2d3;
  font-size: 13px;
}

.profile-sections {
  display: grid;
  gap: 12px;
}

.profile-section {
  border: 1px solid var(--line-soft);
  border-radius: 16px;
  background: rgba(7, 17, 39, 0.58);
  padding: 12px;
}

.profile-section-account {
  border-color: rgba(105, 164, 247, 0.38);
  background: linear-gradient(160deg, rgba(9, 23, 52, 0.82), rgba(7, 16, 38, 0.74));
}

.profile-section-title {
  margin: 0 0 8px;
  color: #d9ebff;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.profile-main-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.profile-cell {
  border: 1px solid var(--line-soft);
  border-radius: 14px;
  padding: 12px;
  background: rgba(7, 17, 39, 0.66);
}

.profile-cell span {
  display: block;
  color: #8fa9ca;
  font-size: 12px;
  margin-bottom: 4px;
}

.profile-cell strong {
  font-size: 24px;
}

.profile-section-account .profile-cell strong {
  font-size: clamp(26px, 4.5vw, 36px);
}

.profile-register-box,
.deposit-box {
  margin-top: 8px;
  border: 1px solid var(--line-soft);
  border-radius: 14px;
  background: rgba(7, 17, 39, 0.66);
  padding: 12px;
}

.profile-register-box p,
.box-title {
  margin: 0;
}

.profile-register-box p {
  color: #95afcf;
  font-size: 14px;
}

.box-title {
  font-size: 14px;
  font-weight: 700;
  color: #d7e8ff;
}

.inline-actions,
.uid-row {
  margin-top: 9px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.uid-row .btn,
.inline-actions .btn {
  min-height: 44px;
  font-size: 14px;
}

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

.stat-box {
  border: 1px solid var(--line-soft);
  border-radius: 14px;
  padding: 12px 6px;
  text-align: center;
  background: rgba(7, 17, 39, 0.66);
}

.stat-box b {
  display: block;
  font-size: clamp(30px, 5vw, 40px);
  line-height: 1;
  color: #dcecff;
}

.stat-box span {
  margin-top: 6px;
  display: block;
  color: #8ea8cb;
  font-size: 14px;
}

.stat-box-win b {
  color: #36dc89;
}

.lang-wrap {
  margin-top: 8px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.profile-settings-grid {
  margin-top: 8px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.profile-setting-cell {
  min-height: 100%;
}

.lang-btn {
  min-height: 44px;
  border-radius: 12px;
  border: 1px solid var(--line-soft);
  background: rgba(5, 14, 33, 0.74);
  color: #b4c9e8;
  font: inherit;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
}

.lang-btn.active {
  color: #f4fbff;
  border-color: rgba(104, 164, 246, 0.5);
  background: linear-gradient(115deg, rgba(67, 116, 223, 0.9), rgba(62, 151, 238, 0.9));
}

.chat-card {
  min-height: calc(100dvh - var(--nav-height) - var(--safe-bottom) - 130px);
  display: flex;
  flex-direction: column;
}

.quick-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.assistant-intro {
  border: 1px solid rgba(86, 132, 203, 0.3);
  border-radius: 14px;
  background: rgba(8, 19, 44, 0.62);
  padding: 12px;
}

.assistant-intro-title {
  margin: 0;
  color: #e3f0ff;
  font-size: 16px;
  font-weight: 800;
}

.assistant-intro-subtitle {
  margin: 6px 0 10px;
  color: #93afcf;
  font-size: 14px;
  line-height: 1.4;
}

.assistant-demo-card {
  margin-top: 10px;
  border: 1px solid rgba(84, 134, 207, 0.3);
  border-radius: 12px;
  background: rgba(9, 24, 53, 0.62);
  padding: 10px;
}

.assistant-demo-label {
  margin: 0;
  color: #9cb9db;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.assistant-demo-text {
  margin: 6px 0 0;
  color: #d8e9ff;
  font-size: 14px;
  line-height: 1.43;
}

.quick-chip {
  border-radius: 999px;
  border: 1px solid var(--line-soft);
  background: rgba(9, 20, 45, 0.7);
  color: #b8cde9;
  padding: 8px 12px;
  font-size: 13px;
  cursor: pointer;
}

.chat-list {
  margin-top: 10px;
  border: 1px solid var(--line-soft);
  border-radius: 14px;
  background: rgba(5, 14, 33, 0.74);
  padding: 10px;
  display: grid;
  gap: 8px;
  max-height: 340px;
  overflow: auto;
}

.msg {
  max-width: 86%;
  border-radius: 14px;
  padding: 10px;
  font-size: 14px;
  line-height: 1.4;
  animation: messageFadeIn 180ms ease;
}

.msg.bot {
  justify-self: start;
  border: 1px solid rgba(91, 140, 214, 0.28);
  background: linear-gradient(165deg, rgba(12, 30, 60, 0.8), rgba(9, 24, 50, 0.84));
}

.msg.user {
  justify-self: end;
  border: 1px solid rgba(95, 147, 241, 0.5);
  background: linear-gradient(125deg, rgba(67, 110, 210, 0.9), rgba(56, 135, 229, 0.8));
}

.chat-compose {
  margin-top: auto;
  display: grid;
  grid-template-columns: 1fr 56px;
  gap: 8px;
  padding-top: 10px;
}

.chat-compose .btn {
  min-height: 44px;
  font-size: 18px;
}

.support-top-card {
  border: 1px solid var(--line-soft);
  border-radius: 16px;
  padding: 14px;
  background: rgba(103, 128, 173, 0.18);
}

.support-top-card h3 {
  margin: 0;
  font-size: clamp(24px, 4vw, 36px);
}

.support-top-card p {
  margin: 8px 0 0;
  color: #b4cae9;
  line-height: 1.35;
}

.support-top-card .btn {
  margin-top: 10px;
  width: 100%;
}

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

.support-mini {
  min-height: 112px;
  border: 1px solid var(--line-soft);
  border-radius: 14px;
  background: rgba(10, 24, 52, 0.62);
  color: #e5f0ff;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 10px;
}

.support-mini span {
  font-size: 24px;
}

.support-mini b {
  font-size: 18px;
}

.support-mini small {
  color: #8ea8cb;
  font-size: 13px;
}

.faq-list {
  margin-top: 12px;
}

.faq-title {
  margin: 0 0 10px;
  font-size: 34px;
  line-height: 1;
}

#faqItems {
  display: grid;
  gap: 7px;
  margin-top: 8px;
}

.faq-item {
  width: 100%;
  min-height: 52px;
  border: 1px solid var(--line-soft);
  border-radius: 14px;
  padding: 0 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(4, 11, 28, 0.78);
  color: #e0ecff;
  font: inherit;
  font-size: 15px;
  cursor: pointer;
  text-align: left;
}

.faq-answer {
  display: none;
  border: 1px solid rgba(84, 139, 232, 0.26);
  border-radius: 12px;
  background: rgba(7, 17, 39, 0.72);
  color: #9fb7d7;
  font-size: 14px;
  line-height: 1.4;
  padding: 10px 12px;
}

.faq-answer.show {
  display: block;
}

.faq-no-help-btn {
  margin-top: 8px;
  width: 100%;
}

.bottom-nav {
  position: fixed !important;
  left: 50%;
  transform: translateX(-50%);
  width: min(calc(100vw - 14px), 920px);
  bottom: calc(var(--safe-bottom) + 4px);
  border: 1px solid rgba(93, 144, 236, 0.46);
  border-radius: 28px;
  background: linear-gradient(180deg, rgba(8, 19, 43, 0.96), rgba(5, 13, 31, 0.98));
  box-shadow:
    0 20px 52px rgba(0, 0, 0, 0.56),
    inset 0 1px 0 rgba(120, 170, 246, 0.2);
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 6px;
  padding: 8px 9px 10px;
  z-index: 9999;
}

.tab-btn {
  min-height: 72px;
  border: 1px solid transparent;
  border-radius: 16px;
  background: transparent;
  color: #87a3c9;
  display: grid;
  align-content: end;
  justify-items: center;
  gap: 5px;
  padding: 7px 4px;
  font: inherit;
  cursor: pointer;
}

.tab-btn .tab-icon {
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
}

.tab-btn .tab-icon svg {
  width: 24px;
  height: 24px;
  stroke: currentColor;
  stroke-width: 2.1;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

.tab-btn b {
  font-size: 13px;
  font-weight: 700;
}

.tab-btn.active:not(.center) {
  color: #6cc0ff;
  border-color: rgba(108, 171, 247, 0.5);
  background: linear-gradient(160deg, rgba(19, 44, 86, 0.74), rgba(10, 27, 58, 0.84));
  box-shadow: 0 0 22px rgba(56, 152, 255, 0.28);
}

.tab-btn.center {
  min-height: 92px;
  margin-top: -26px;
  color: #57beff;
}

.tab-icon-circle {
  width: 86px;
  height: 86px;
  border-radius: 50%;
  border: 1px solid rgba(108, 189, 246, 0.42);
  background: radial-gradient(circle at 30% 20%, #5aaeff 0%, #29d7d7 75%);
  display: grid;
  place-items: center;
  color: #d8f4ff;
  box-shadow: 0 0 30px rgba(59, 164, 247, 0.56);
}

.tab-icon-circle svg {
  width: 30px;
  height: 30px;
  stroke-width: 2.1;
}

.tab-btn.center b {
  font-size: 17px;
  color: #68c0ff;
}

.tab-btn.center.active .tab-icon-circle {
  box-shadow: 0 0 36px rgba(59, 164, 247, 0.62), 0 10px 24px rgba(27, 117, 208, 0.4);
}

.toast {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: calc(var(--nav-height) + var(--safe-bottom) + 10px);
  width: min(calc(100vw - 20px), 620px);
  border: 1px solid rgba(95, 147, 241, 0.46);
  border-radius: 14px;
  background: rgba(6, 18, 42, 0.96);
  color: #d7e9ff;
  font-size: 14px;
  line-height: 1.4;
  padding: 10px 12px;
  z-index: 10001;
}

.signal-search-overlay {
  position: fixed;
  inset: 0;
  z-index: 10020;
  display: grid;
  place-items: center;
  padding: 14px;
  background:
    radial-gradient(circle at 50% 36%, rgba(62, 145, 248, 0.17), transparent 54%),
    linear-gradient(180deg, rgba(1, 7, 19, 0.9), rgba(2, 9, 24, 0.94));
  backdrop-filter: blur(8px);
}

.signal-search-dialog {
  width: min(100%, 560px);
  border: 1px solid rgba(98, 156, 246, 0.5);
  border-radius: 24px;
  background:
    radial-gradient(circle at 50% 10%, rgba(73, 149, 250, 0.2), transparent 56%),
    linear-gradient(160deg, rgba(8, 20, 46, 0.96), rgba(4, 13, 33, 0.98));
  box-shadow:
    0 32px 68px rgba(0, 0, 0, 0.58),
    0 0 0 1px rgba(93, 167, 255, 0.16) inset;
  padding: 20px;
  text-align: center;
}

.signal-scan-wrap {
  position: relative;
  width: min(76vw, 260px);
  height: min(76vw, 260px);
  margin: 2px auto 0;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 50%, rgba(26, 68, 144, 0.34), rgba(2, 8, 22, 0.82) 64%);
  overflow: hidden;
}

.scan-ring {
  position: absolute;
  inset: 50%;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 1px solid rgba(118, 177, 255, 0.16);
  transform: translate(-50%, -50%) scale(0.3);
}

.scan-ring-1 {
  animation: scanRingPulse 1.9s ease-out infinite;
}

.scan-ring-2 {
  animation: scanRingPulse 1.9s ease-out 0.45s infinite;
}

.scan-ring-3 {
  animation: scanRingPulse 1.9s ease-out 0.9s infinite;
}

.scan-pulse {
  position: absolute;
  inset: 50%;
  width: 28%;
  height: 28%;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, rgba(110, 192, 255, 0.52), rgba(26, 125, 238, 0.16) 68%, transparent 100%);
  box-shadow: 0 0 38px rgba(88, 176, 255, 0.4);
  animation: scanCorePulse 1.4s ease-in-out infinite;
}

.scan-sweep {
  position: absolute;
  inset: -12%;
  border-radius: 50%;
  background: conic-gradient(
    from 0deg,
    rgba(61, 154, 251, 0) 0deg,
    rgba(67, 164, 255, 0.34) 56deg,
    rgba(48, 215, 214, 0.3) 84deg,
    rgba(61, 154, 251, 0) 114deg
  );
  animation: scanSweepRotate 2.4s linear infinite;
}

.scan-dot {
  position: absolute;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #67deff;
  box-shadow: 0 0 14px rgba(84, 215, 255, 0.7);
}

.scan-dot-a {
  top: 23%;
  left: 62%;
  animation: scanDotOrbitA 2.2s linear infinite;
}

.scan-dot-b {
  top: 65%;
  left: 22%;
  animation: scanDotOrbitB 2.6s linear infinite;
}

.scan-dot-c {
  top: 72%;
  left: 66%;
  animation: scanDotOrbitC 2.1s linear infinite;
}

.scan-core-label {
  position: absolute;
  inset: 50%;
  transform: translate(-50%, -50%);
  width: 34%;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  display: grid;
  place-items: center;
  border: 1px solid rgba(130, 185, 253, 0.42);
  background: radial-gradient(circle at 30% 20%, rgba(86, 158, 252, 0.48), rgba(14, 35, 78, 0.9));
  color: #e8f4ff;
  font-size: clamp(24px, 7vw, 34px);
  font-weight: 800;
  letter-spacing: 0.04em;
}

.signal-search-stage-text {
  margin: 16px 0 0;
  color: #dcecff;
  font-size: clamp(22px, 4.4vw, 32px);
  font-weight: 800;
  line-height: 1.2;
}

.signal-search-progress-head {
  margin-top: 14px;
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
  color: #9eb9dd;
  font-size: 14px;
  font-weight: 700;
}

.signal-search-progress-head strong {
  color: #ecf7ff;
  font-size: 20px;
  font-weight: 800;
}

.signal-search-progress-track {
  margin-top: 8px;
  width: 100%;
  height: 14px;
  border-radius: 999px;
  border: 1px solid rgba(98, 153, 237, 0.44);
  background: rgba(8, 21, 46, 0.82);
  overflow: hidden;
}

.signal-search-progress-fill {
  display: block;
  width: 0%;
  height: 100%;
  border-radius: inherit;
  background:
    linear-gradient(
      110deg,
      rgba(255, 255, 255, 0.2) 8%,
      rgba(255, 255, 255, 0.04) 26%,
      rgba(55, 173, 247, 0.95) 56%,
      rgba(45, 216, 214, 0.96) 88%
    );
  background-size: 220% 100%;
  animation: timerFlow 1s linear infinite;
  transition: width 190ms ease;
}

.modal {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(2, 8, 19, 0.8);
  backdrop-filter: blur(8px);
  z-index: 10000;
  padding: 12px;
}

.modal-dialog {
  width: min(100%, 820px);
  border: 1px solid rgba(89, 142, 236, 0.44);
  border-radius: 22px;
  background: linear-gradient(160deg, rgba(10, 23, 52, 0.96), rgba(5, 13, 32, 0.98));
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.6);
  padding: 16px;
  position: relative;
}

.modal-close {
  position: absolute;
  top: 8px;
  right: 10px;
  border: 0;
  background: transparent;
  color: #9cb6da;
  font-size: 36px;
  line-height: 1;
  cursor: pointer;
}

.modal-kicker {
  margin: 0;
  color: #7fa7dd;
  font-size: 14px;
  font-weight: 700;
}

.modal-dots {
  margin-top: 10px;
  display: flex;
  justify-content: center;
  gap: 8px;
}

.modal-dot {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: rgba(109, 154, 228, 0.35);
}

.modal-dot.active {
  width: 30px;
  background: linear-gradient(95deg, #4f89f2, #2fd7d7);
}

.modal-body {
  margin-top: 12px;
  border: 1px solid var(--line-soft);
  border-radius: 16px;
  background: rgba(8, 19, 43, 0.74);
  padding: 14px;
}

.welcome-video-dialog {
  width: min(100%, 760px);
}

.welcome-video-frame {
  margin-top: 12px;
  border: 1px solid var(--line-soft);
  border-radius: 16px;
  overflow: hidden;
  background: #000;
}

.welcome-video-player {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}

.welcome-video-copy {
  margin-top: 12px;
  border: 1px solid var(--line-soft);
  border-radius: 16px;
  background: rgba(8, 19, 43, 0.74);
  padding: 14px;
}

.welcome-video-copy h3 {
  margin: 0;
  font-size: clamp(28px, 4.8vw, 40px);
  line-height: 1.1;
}

.welcome-video-copy p {
  margin: 8px 0 0;
  color: #9db7da;
  font-size: 16px;
  line-height: 1.42;
}

.modal-body h3 {
  margin: 8px 0 0;
  font-size: clamp(34px, 5vw, 50px);
  line-height: 1.05;
}

.modal-body p {
  margin: 9px 0 0;
  color: #9db7da;
  font-size: 16px;
  line-height: 1.42;
}

.modal-body ul {
  margin: 10px 0 0;
  padding-left: 18px;
  color: #dceaff;
  line-height: 1.42;
}

.onboarding-icon {
  margin: 0;
  font-size: 32px;
}

.onboarding-gallery {
  margin-top: 8px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  max-height: 300px;
  overflow: auto;
  padding-right: 2px;
}

.onboarding-gallery img {
  width: 100%;
  aspect-ratio: 9 / 16;
  object-fit: cover;
  border-radius: 12px;
  border: 1px solid var(--line-soft);
  background: #000;
}

.modal-actions {
  margin-top: 12px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

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

.modal-actions-1 {
  grid-template-columns: 1fr;
}

.hidden {
  display: none !important;
}

@media (max-width: 820px) {
  .brand-logo {
    font-size: clamp(26px, 9vw, 44px);
  }

  .section-head h2 {
    font-size: clamp(28px, 8.2vw, 40px);
  }

  .signal-meta {
    font-size: clamp(15px, 4.2vw, 18px);
  }

  .winrate-ring-wrap {
    width: 160px;
    height: 160px;
  }

  .winrate-value {
    font-size: 42px;
  }

  .btn-xl {
    min-height: 60px;
    font-size: clamp(24px, 6.8vw, 36px);
  }

  .live-head h2 {
    font-size: clamp(28px, 7vw, 44px);
  }

  .live-direction {
    font-size: clamp(28px, 7.2vw, 46px);
  }

  .pro-direction-text {
    font-size: clamp(22px, 5.2vw, 34px);
  }

  .pro-access-btn {
    font-size: clamp(17px, 4.6vw, 24px);
  }

  .btn-find-signal {
    min-height: 62px;
    font-size: clamp(23px, 6vw, 34px);
  }

  .timer-row strong {
    font-size: 28px;
  }
}

@media (max-width: 640px) {
  .app-shell {
    padding: calc(6px + var(--safe-top)) 10px calc(var(--nav-height) + var(--safe-bottom) + 16px);
  }

  .selectors-grid,
  .signal-flow,
  .search-state-steps,
  .history-tools,
  .profile-main-grid,
  .profile-settings-grid,
  .lang-wrap,
  .stats-grid,
  .inline-actions,
  .uid-row,
  .support-mini-grid,
  .modal-actions,
  .modal-actions-2,
  .result-actions {
    grid-template-columns: 1fr;
  }

  .timer-box {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
  }

  .timer-content {
    width: 100%;
  }

  .tab-btn {
    min-height: 64px;
  }

  .tab-btn b {
    font-size: 11px;
  }

  .tab-btn.center {
    min-height: 82px;
    margin-top: -20px;
  }

  .tab-icon-circle {
    width: 72px;
    height: 72px;
  }

  .tab-btn.center b {
    font-size: 14px;
  }

  .bottom-nav {
    border-radius: 22px;
    padding: 7px 6px 8px;
  }

  .modal {
    padding: 8px;
  }

  .modal-dialog {
    padding: 12px;
    border-radius: 18px;
  }

  .modal-body {
    padding: 12px;
  }

  .welcome-video-copy h3 {
    font-size: clamp(24px, 7vw, 32px);
  }

  .welcome-video-copy p {
    font-size: 14px;
  }

  .modal-body h3 {
    font-size: clamp(26px, 8.8vw, 36px);
  }

  .modal-body p {
    font-size: 14px;
  }

  .modal-body ul {
    font-size: 14px;
  }

  .signal-search-overlay {
    padding: 10px;
  }

  .signal-search-dialog {
    padding: 16px;
    border-radius: 18px;
  }

  .signal-scan-wrap {
    width: min(78vw, 220px);
    height: min(78vw, 220px);
  }

  .signal-search-stage-text {
    font-size: clamp(20px, 7vw, 28px);
  }
}
