.aor-market {
  --market-bg: var(--aor-background, #0d0b12);
  --market-panel: rgba(28, 22, 40, 0.9);
  --market-panel-strong: #1c1628;
  --market-border: rgba(248, 245, 255, 0.12);
  --market-text: var(--aor-text, #f8f5ff);
  --market-muted: var(--aor-muted, #c9c2d8);
  --market-blue: var(--aor-secondary, #3c5ee6);
  --market-green: var(--aor-tertiary, #44c194);
  --market-red: #e65f79;
  position: relative;
  min-height: 75vh;
  overflow: hidden;
  padding: clamp(150px, 16vw, 220px) 0 clamp(90px, 10vw, 150px);
  color: var(--market-text);
  background:
    linear-gradient(rgba(13, 11, 18, 0.84), rgba(13, 11, 18, 0.97)),
    radial-gradient(circle at 85% 8%, rgba(60, 94, 230, 0.22), transparent 32%),
    var(--market-bg);
}

.aor-market *,
.aor-market *::before,
.aor-market *::after {
  box-sizing: border-box;
}

.aor-market__glow {
  position: absolute;
  top: 210px;
  left: -180px;
  width: 500px;
  height: 500px;
  border-radius: 50%;
  background: rgba(68, 193, 148, 0.08);
  filter: blur(90px);
  pointer-events: none;
}

.aor-market__container {
  position: relative;
  z-index: 1;
  width: min(1380px, calc(100% - 56px));
  margin: 0 auto;
}

.aor-market__hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 50px;
  align-items: end;
  margin-bottom: 50px;
}

.aor-market__eyebrow {
  display: block;
  margin-bottom: 13px;
  color: var(--market-green);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.aor-market__hero h1 {
  max-width: 820px;
  margin: 0;
  font-size: clamp(3.2rem, 7vw, 7rem);
  line-height: 0.9;
  letter-spacing: -0.055em;
}

.aor-market__hero p {
  max-width: 720px;
  margin: 28px 0 0;
  color: var(--market-muted);
  font-size: clamp(1rem, 1.5vw, 1.2rem);
}

.aor-market__status {
  display: flex;
  min-width: 265px;
  align-items: center;
  gap: 15px;
  padding: 18px 20px;
  border: 1px solid var(--market-border);
  background: rgba(23, 18, 33, 0.82);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.22);
}

.aor-market__status > span {
  width: 10px;
  height: 10px;
  flex: 0 0 10px;
  border-radius: 50%;
  background: var(--market-green);
  box-shadow: 0 0 0 6px rgba(68, 193, 148, 0.12);
}

.aor-market__status.is-stale > span {
  background: #f0aa4f;
  box-shadow: 0 0 0 6px rgba(240, 170, 79, 0.12);
}

.aor-market__status small,
.aor-market__status strong {
  display: block;
}

.aor-market__status small {
  margin-bottom: 3px;
  color: var(--market-muted);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.aor-market__status strong {
  font-size: 0.95rem;
}

.aor-market__tabs {
  display: flex;
  gap: 3px;
  margin-bottom: 30px;
  border-bottom: 1px solid var(--market-border);
}

.aor-market__tabs button {
  position: relative;
  min-width: 155px;
  padding: 16px 20px;
  border: 0;
  color: var(--market-muted);
  background: transparent;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

.aor-market__tabs button::after {
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--market-blue), var(--market-green));
  content: "";
  opacity: 0;
  transform: scaleX(0.45);
  transition: 180ms ease;
}

.aor-market__tabs button[aria-selected="true"] {
  color: var(--market-text);
}

.aor-market__tabs button[aria-selected="true"]::after {
  opacity: 1;
  transform: scaleX(1);
}

.aor-market__tabs button:focus-visible,
.aor-market__toolbar input:focus-visible,
.aor-market__toolbar select:focus-visible {
  outline: 2px solid var(--market-green);
  outline-offset: 3px;
}

.aor-market__tabs button span {
  display: inline-grid;
  min-width: 25px;
  height: 25px;
  place-items: center;
  margin-left: 8px;
  padding: 0 7px;
  border-radius: 999px;
  color: var(--market-text);
  background: rgba(60, 94, 230, 0.24);
  font-size: 0.72rem;
}

.aor-market__stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.aor-market__stat {
  position: relative;
  overflow: hidden;
  min-height: 155px;
  padding: 25px;
  border: 1px solid var(--market-border);
  background: linear-gradient(145deg, rgba(34, 27, 48, 0.94), rgba(20, 16, 29, 0.94));
}

.aor-market__stat::after {
  position: absolute;
  top: -34px;
  right: -34px;
  width: 110px;
  height: 110px;
  border-radius: 50%;
  background: var(--market-blue);
  content: "";
  opacity: 0.08;
}

.aor-market__stat--up::after { background: var(--market-green); }
.aor-market__stat--down::after { background: var(--market-red); }

.aor-market__stat > span,
.aor-market__stat > strong,
.aor-market__stat > small {
  display: block;
}

.aor-market__stat > span {
  color: var(--market-muted);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.aor-market__stat > strong {
  margin: 13px 0 8px;
  font-size: clamp(2rem, 3.4vw, 3rem);
  line-height: 1;
}

.aor-market__stat > small {
  color: var(--market-muted);
  font-size: 0.8rem;
}

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

.aor-market__mover-group,
.aor-market__empty,
.aor-market__table-wrap {
  border: 1px solid var(--market-border);
  background: var(--market-panel);
  box-shadow: 0 25px 80px rgba(0, 0, 0, 0.18);
}

.aor-market__mover-group > header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 25px 27px;
  border-bottom: 1px solid var(--market-border);
}

.aor-market__mover-group h2 {
  margin: 0;
  font-size: clamp(1.35rem, 2vw, 1.8rem);
}

.aor-market__mover-group header span {
  color: var(--market-muted);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
}

.aor-market__mover-group ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

.aor-market__mover-group li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 18px;
  min-height: 82px;
  padding: 14px 27px;
  border-bottom: 1px solid rgba(248, 245, 255, 0.07);
}

.aor-market__mover-group li:last-child { border-bottom: 0; }
.aor-market__mover-group li > strong { white-space: nowrap; font-size: 1rem; }
.aor-market__mover-group li > strong > span { margin-right: 5px; color: var(--market-green); }

.aor-market__mover-empty {
  margin: 0;
  padding: 35px 27px;
  color: var(--market-muted);
}

.aor-market__item {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 13px;
}

.aor-market__item-image {
  display: grid;
  width: 46px;
  height: 46px;
  flex: 0 0 46px;
  overflow: hidden;
  place-items: center;
  border: 1px solid rgba(248, 245, 255, 0.1);
  color: var(--market-green);
  background: linear-gradient(145deg, rgba(60, 94, 230, 0.19), rgba(68, 193, 148, 0.08));
  font-weight: 800;
}

.aor-market__item-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  image-rendering: pixelated;
}

.aor-market__item > span:last-child { min-width: 0; }
.aor-market__item strong,
.aor-market__item small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.aor-market__item strong { font-size: 0.95rem; }
.aor-market__item small { margin-top: 3px; color: var(--market-muted); font-size: 0.7rem; }

.aor-market__change {
  display: inline-flex;
  min-width: 76px;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 7px 10px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 800;
  white-space: nowrap;
}

.aor-market__change.is-up { border-color: rgba(68, 193, 148, 0.22); color: #71ddb5; background: rgba(68, 193, 148, 0.1); }
.aor-market__change.is-down { border-color: rgba(230, 95, 121, 0.22); color: #ff91a7; background: rgba(230, 95, 121, 0.1); }
.aor-market__change.is-flat,
.aor-market__change.is-new { border-color: rgba(248, 245, 255, 0.12); color: var(--market-muted); background: rgba(248, 245, 255, 0.04); }

.aor-market__empty {
  padding: clamp(50px, 8vw, 100px) 30px;
  text-align: center;
}

.aor-market__empty > span { display: block; margin-bottom: 14px; color: var(--market-green); font-size: 3rem; }
.aor-market__empty h2 { margin: 0 0 12px; }
.aor-market__empty p { margin: 0; color: var(--market-muted); }

.aor-market__toolbar {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) minmax(190px, auto) minmax(210px, auto);
  gap: 12px;
  margin-bottom: 18px;
}

.aor-market__toolbar label { display: block; }
.aor-market__search { position: relative; }
.aor-market__search svg { position: absolute; top: 50%; left: 18px; width: 20px; height: 20px; fill: none; stroke: var(--market-muted); stroke-width: 1.8; transform: translateY(-50%); pointer-events: none; }
.aor-market__toolbar input,
.aor-market__toolbar select {
  width: 100%;
  min-height: 54px;
  border: 1px solid var(--market-border);
  border-radius: 0;
  color: var(--market-text);
  background: rgba(28, 22, 40, 0.92);
  font: inherit;
  font-size: 0.9rem;
}
.aor-market__toolbar input { padding: 0 18px 0 50px; }
.aor-market__toolbar select { padding: 0 40px 0 16px; cursor: pointer; }
.aor-market__toolbar select option { color: #171221; background: #fff; }

.aor-market__table-wrap { overflow-x: auto; }
.aor-market__table { width: 100%; min-width: 970px; border-collapse: collapse; }
.aor-market__table th,
.aor-market__table td { padding: 17px 20px; border-bottom: 1px solid rgba(248, 245, 255, 0.07); text-align: left; vertical-align: middle; }
.aor-market__table th { height: 62px; color: var(--market-muted); background: rgba(13, 11, 18, 0.42); font-size: 0.68rem; font-weight: 800; letter-spacing: 0.09em; text-transform: uppercase; white-space: nowrap; }
.aor-market__table tbody tr { transition: background 160ms ease; }
.aor-market__table tbody tr:hover { background: rgba(60, 94, 230, 0.055); }
.aor-market__table tbody tr:last-child td { border-bottom: 0; }
.aor-market__table th:first-child { width: 29%; }
.aor-market__table th:nth-child(2) { width: 15%; }
.aor-market__category { display: inline-block; padding: 6px 9px; border: 1px solid var(--market-border); color: var(--market-muted); font-size: 0.72rem; white-space: nowrap; }
.aor-market__price { white-space: nowrap; }
.aor-market__price > span { margin-right: 6px; color: var(--market-green); }

.aor-market__trend { display: block; width: 112px; height: 34px; fill: none; overflow: visible; }
.aor-market__trend polyline { stroke: var(--market-green); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.aor-market__trend.is-down polyline { stroke: var(--market-red); }
.aor-market__trend-empty { color: var(--market-muted); font-size: 0.72rem; white-space: nowrap; }
.aor-market__no-results { margin: 0; padding: 45px 20px; color: var(--market-muted); text-align: center; }
.aor-market__result-count { margin: 15px 0 0; color: var(--market-muted); font-size: 0.78rem; text-align: right; }

@media (max-width: 1000px) {
  .aor-market__hero { grid-template-columns: 1fr; align-items: start; }
  .aor-market__status { width: fit-content; }
  .aor-market__stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .aor-market__toolbar { grid-template-columns: 1fr 1fr; }
  .aor-market__search { grid-column: 1 / -1; }
}

@media (max-width: 760px) {
  .aor-market { padding-top: 130px; }
  .aor-market__container { width: min(100% - 30px, 1380px); }
  .aor-market__hero { gap: 30px; margin-bottom: 36px; }
  .aor-market__hero h1 { font-size: clamp(3.1rem, 17vw, 5.5rem); }
  .aor-market__status { width: 100%; min-width: 0; }
  .aor-market__tabs button { min-width: 0; flex: 1; }
  .aor-market__stats,
  .aor-market__movers { grid-template-columns: 1fr; }
  .aor-market__stat { min-height: 130px; }
  .aor-market__toolbar { grid-template-columns: 1fr; }
  .aor-market__search { grid-column: auto; }
  .aor-market__mover-group li { grid-template-columns: minmax(0, 1fr) auto; padding: 14px 18px; }
  .aor-market__mover-group li > .aor-market__change { grid-column: 2; }
}

@media (prefers-reduced-motion: reduce) {
  .aor-market *,
  .aor-market *::before,
  .aor-market *::after { scroll-behavior: auto !important; transition-duration: 0.01ms !important; }
}
