:root {
  color-scheme: dark;
  --bg: #0b0e14;
  --surface: #10151e;
  --surface-alt: #141b25;
  --line: #293342;
  --muted: #8290a2;
  --text: #dce5ef;
  --emerald: #10b981;
  --cyan: #00d6e6;
  --red: #ee7889;
  --green: #62d5a4;
  --purple: #b499e9;
  --pink: #ec8db2;
  --yellow: #dbc773;
  --mono: "JetBrains Mono", monospace;
}


* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--bg);
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: var(--mono);
  text-transform: lowercase;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: 0;
  background-image: linear-gradient(rgba(97, 123, 149, .045) 1px, transparent 1px), linear-gradient(90deg, rgba(97, 123, 149, .045) 1px, transparent 1px);
  background-size: 32px 32px;
  pointer-events: none;
  content: "";
}

button,
input {
  font: inherit;
  text-transform: lowercase;
}

button {
  color: inherit;
}

.app-shell {
  position: relative;
  z-index: 1;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 40px;
}

.topbar {
  min-height: 54px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  border-bottom: 1px solid var(--line);
}

.topbar-right {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.notification-button {
  background: transparent;
  border: none;
  color: inherit;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem;
}

.notification-center {
  position: relative;
}

.notification-count {
  position: absolute;
  top: -3px;
  right: -4px;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  border-radius: 9px;
  background: var(--emerald);
  color: #07120e;
  font-size: 14px;
  line-height: 17px;
  text-align: center;
  pointer-events: none;
}

.notification-panel {
  position: absolute;
  z-index: 20;
  top: calc(100% + 12px);
  right: -8px;
  width: min(360px, calc(100vw - 32px));
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
  box-shadow: 0 16px 44px #0009;
}

.notification-panel>header {
  display: flex;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
}

.notification-panel>header span,
.notification-item time {
  color: var(--muted);
  font-size: 14px;
}

.notification-list {
  max-height: 360px;
  overflow-y: auto;
}

.notification-item {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 13px 16px;
  border-bottom: 1px solid var(--line);
}

.notification-item.read {
  opacity: .65;
}

.notification-item strong {
  color: var(--emerald);
  font-size: 14px;
}

.notification-item p {
  margin: 5px 0;
  font-size: 14px;
  line-height: 1.5;
}

.notification-item time {
  display: block;
}

.notification-remove {
  align-self: flex-start;
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-size: 20px;
}

.notification-empty {
  margin: 0;
  padding: 22px 16px;
  color: var(--muted);
  font-size: 14px;
  text-align: center;
}

.friends-panel {
  margin: 20px 0;
  padding: 18px;
}

.friend-search-form {
  max-width: 600px;
}

.friend-search-form>label {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 14px;
}

.friend-search-row {
  display: flex;
  gap: 8px;
}

.friend-search-row input {
  flex: 1;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 10px;
  background: var(--bg);
  color: var(--text);
}

.friend-search-row .primary-button {
  width: auto;
  margin: 0;
  padding: 0 16px;
}

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

.friend-card {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 9px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface-alt);
}

.friend-avatar {
  display: grid;
  flex: 0 0 32px;
  width: 32px;
  height: 32px;
  place-items: center;
  border: 1px solid var(--emerald);
  color: var(--emerald);
}

.friend-card-info {
  display: grid;
  flex: 1;
  min-width: 0;
  gap: 3px;
}

.friend-card-info strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 14px;
}

.friend-card-info span {
  color: var(--muted);
  font-size: 14px;
}

.friend-card-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 5px;
}

.friend-action {
  border: 1px solid color-mix(in srgb, var(--emerald) 45%, var(--line));
  border-radius: 4px;
  padding: 5px 8px;
  background: transparent;
  color: var(--emerald);
  cursor: pointer;
  font-size: 14px;
}

.friend-action.danger {
  border-color: color-mix(in srgb, var(--red) 45%, var(--line));
  color: var(--red);
}

.friends-columns {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 22px;
}

.friends-columns h3 {
  margin: 0 0 10px;
  font-size: 18px;
}

.friends-columns .empty-line {
  color: var(--muted);
  font-size: 14px;
}

.notification-actions {
  display: flex;
  gap: 6px;
  margin-top: 8px;
}

.users-directory-panel {
  padding: 20px;
}

.users-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 10px;
  margin-top: 18px;
}

.directory-user {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 9px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--surface-alt);
}

.directory-user .friend-card-info {
  flex-basis: 120px;
}

.relation-label {
  padding: 5px 8px;
  color: var(--muted);
  font-size: 16px;
}

.public-profile-card {
  margin-top: 18px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--surface-alt);
}

.public-profile-heading {
  display: flex;
  align-items: center;
  gap: 14px;
}

.public-profile-heading h2 {
  margin: 5px 0;
}

.public-profile-heading p,
.public-profile-bio {
  color: var(--muted);
}

.public-profile-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin: 14px 0;
  color: var(--muted);
  font-size: 14px;
}

.profile-identity.external-profile {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
}

.profile-identity-copy {
  min-width: 0;
}

.public-profile-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 150px;
}

.public-profile-actions .primary-button {
  width: auto;
  min-width: 130px;
  margin: 0;
}

.public-profile-actions .relation-label {
  text-align: center;
}

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

@media (max-width: 560px) {
  .profile-identity.external-profile {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .public-profile-actions {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }
}

.brand {
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--text);
  text-decoration: none;
  white-space: nowrap;
}

.brand-icon {
  width: 20px;
  height: 20px;
  display: grid;
  grid-template-columns: repeat(2, 5px);
  grid-template-rows: repeat(2, 5px);
  align-content: center;
  justify-content: center;
  gap: 2px;
  border: 1px solid #397a64;
}

.brand-icon span {
  background: var(--emerald);
}

.brand-icon span:nth-child(2),
.brand-icon span:nth-child(3) {
  background: var(--cyan);
}

.brand-name {
  font: 1.2rem var(--mono);
}

.brand-name i {
  color: var(--emerald);
  font-style: normal;
}

.brand-name b {
  color: #cad4e0;
  font-weight: 400;
}

.account-button {
  display: flex;
  align-items: center;
  gap: 7px;
  border: 0;
  background: transparent;
  color: var(--text);
  font: 1rem var(--mono);
  cursor: pointer;
}

.account-avatar {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border: 1px solid #397a64;
  color: var(--emerald);
}

.ticker-window {
  width: 100%;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background: #0d1118;
}

.ticker-track {
  width: max-content;
  min-height: 30px;
  display: flex;
  align-items: center;
  animation: ticker-scroll 44s linear infinite;
}

.ticker-group {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 21px;
  padding-right: 21px;
}

.ticker-window:hover .ticker-track {
  animation-play-state: paused;
}

.ticker-item {
  display: flex;
  align-items: center;
  gap: 7px;
  color: #9cabbc;
  font: 0.875em var(--mono);
  white-space: nowrap;
}

.ticker-item b {
  color: var(--text);
  font-weight: 400;
}

.ticker-item strong {
  text-align: center;
  font-weight: 400;
}

.ticker-item .ticker-volume {
  color: #718095;
}

.ticker-separator {
  color: #526273;
  font: 14px var(--mono);
}

.main-nav {
  display: flex;
  justify-content: center;
  gap: 0;
  min-height: 36px;
  padding: 0.5rem;
  border-bottom: 1px solid var(--line);
  font: 1rem var(--mono);
}

.nav-link {
  min-height: 35px;
  padding: 0 1.8rem;
  border: 0;
  border-right: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  transition: 0.1s;
}

.nav-link:first-child {
  border-left: 1px solid var(--line);
}

.nav-link.active,
.nav-link:hover {
  color: var(--emerald);
  background: #101a19;
  transition: 0.1s;
}

.auth-layout {
  min-height: calc(100vh - 91px);
  max-width: 1050px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 370px;
  gap: 65px;
  align-items: center;
  margin: 0 auto;
  padding: 50px 0 60px;
}

.eyebrow {
  color: #8392a5;
  font: 14px var(--mono);
}

.hero-copy h1,
.market-heading h1,
.view-heading h1 {
  margin: 16px 0 12px;
  color: #e4ebf3;
  font-size: clamp(45px, 6vw, 69px);
  font-weight: 500;
  line-height: 1.12;
  letter-spacing: -.065em;
}

.hero-copy h1 span,
.market-heading h1 span {
  color: var(--emerald);
}

.hero-copy h1 {
  margin-bottom: 3rem;
}

.market-heading h1 span {
  animation: 2s glowing-green alternate infinite;
}

@keyframes glowing-green {
  0% {
    text-shadow: 0px 0px 5px #10b98177;
  }

  100% {
    text-shadow: 0px 0px 15px #10b98177;
  }
}

.hero-subtitle {
  max-width: 460px;
  margin: 0;
  color: #9ba9b9;
  font-size: 14px;
  line-height: 1.8;
}

.mini-chart-card {
  max-width: 490px;
  margin-top: 24px;
  padding: 13px 14px 10px;
  border: 1px solid var(--line);
  background: #0e131b;
  border-radius: 12px;
}

.chart-card-top,
.chart-value-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.chart-card-top>div {
  display: grid;
  gap: 4px;
}

.chart-card-top strong {
  color: #cbd5e0;
  font-size: 1.5rem;
  font-weight: 700;
}

.chart-live {
  color: var(--emerald);
  font: 14px var(--mono);
}

.chart-value-row {
  justify-content: flex-start;
  gap: 10px;
  margin-top: 10px;
}

.chart-value-row>strong {
  color: var(--text);
  font: 15px var(--mono);
}

.chart-change {
  color: var(--green);
  font: 14px var(--mono);
}

.mini-chart {
  width: 100%;
  display: block;
  overflow: visible;
}

.mini-chart #chart-area {
  fill: rgba(16, 185, 129, .07);
}

.mini-chart #chart-line {
  fill: none;
  stroke: var(--emerald);
  stroke-width: 2;
  stroke-linecap: square;
  stroke-linejoin: bevel;
}

.mini-chart #chart-dot {
  fill: var(--emerald);
}

.chart-axis {
  display: flex;
  justify-content: space-between;
  color: #718095;
  font: 14px var(--mono);
}

.hero-benefits {
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
  margin-top: 18px;
}

.hero-benefits>div {
  display: flex;
  align-items: center;
  gap: 9px;
}

.benefit-icon {
  color: var(--cyan);
  font: 14px var(--mono);
}

.hero-benefits>div>span:last-child {
  display: grid;
  gap: 2px;
}

.hero-benefits b {
  color: #cbd5e0;
  font-size: 14px;
  font-weight: 400;
}

.hero-benefits small {
  color: #8290a2;
  font-size: 14px;
}

.auth-card {
  padding: 23px 24px 19px;
  border: 1px solid #384555;
  background: rgba(15, 21, 30, .96);
  box-shadow: 0px 0px 108px #10b9812b;
  border-radius: 12px;
}

.card-live {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: #8593a4;
  font: 14px var(--mono);
}

.card-live {
  justify-content: flex-end;
  color: var(--emerald);
}

.auth-heading {
  margin: 0px 0 23px;
}

.auth-heading h2,
.panel-heading h2 {
  margin: 0;
  color: #e1e8f0;
  font-size: 2.2rem;
  font-weight: 500;
  letter-spacing: -.03em;
}

.auth-heading p {
  margin: 5px 0 0;
  color: #8796a8;
  font-size: 1rem;
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin-bottom: 17px;
  border: 1px solid var(--line);
  background: #0b0f15;
  border-radius: 8px;
}

.auth-tab {
  min-height: 34px;
  padding: 12px 0 12px;
  border: 0;
  border-right: 1px solid var(--line);
  background: transparent;
  color: #8694a5;
  font: 1rem var(--mono);
  cursor: pointer;
}

.auth-tab:last-child {
  border-right: 0;
}

.auth-tab.active {
  background: #14221e;
  color: var(--emerald);
}

form label,
.order-panel label,
.detail-order-panel label {
  display: block;
  margin: 12px 0 12px;
  ;
  color: #9cabbc;
  font: 1rem var(--mono);
}

.input-wrap {
  height: 39px;
  display: flex;
  align-items: center;
  border: 1px solid #303c4b;
  background: #0a0e14;
  padding: 22px 0 22px;
  border-radius: 8px;
}

.input-wrap:focus-within,
.detail-share-input:focus {
  border-color: var(--cyan);
  outline: 1px solid rgba(0, 214, 230, .25);
}

.input-prefix {
  padding-left: 11px;
  color: var(--cyan);
  font: 14px var(--mono);
}

.password-prefix {
  color: var(--emerald);
}

.input-wrap input {
  width: 100%;
  min-width: 0;
  padding: 0 12px;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text);
  font: 1rem var(--mono);
}

.input-wrap input::placeholder {
  color: #637184;
}

.password-toggle {
  padding: 7px 9px;
  border: 0;
  background: transparent;
  color: #8b99aa;
  font: 14px var(--mono);
  cursor: pointer;
}

.form-message {
  min-height: 15px;
  margin: 6px 0 0;
  color: var(--red);
  font-size: 14px;
}

.primary-button {
  width: 100%;
  height: 39px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 22px;
  border: 1px solid #148c68;
  background: #10251e;
  color: #69d9ac;
  font: 1rem var(--mono);
  cursor: pointer;
  transition: background .15s, border-color .15s;
  border-radius: 8px;
}

.primary-button:hover {
  border-color: var(--emerald);
  background: #153329;
}

.primary-button:disabled {
  opacity: .6;
  cursor: wait;
}

.card-note {
  margin: 14px 0 0;
  color: #8593a5;
  font-size: 14px;
}

.hidden {
  display: none !important;
}

.trading-view,
.content-view {
  margin: 30px 0px 30px;
}

.market-heading,
.view-heading {
  display: flex;
  justify-content: space-between;
  align-items: end;
  margin-bottom: 21px;
}

.market-heading h1,
.view-heading h1 {
  font-size: 3rem;
}

.market-status {
  color: var(--emerald);
  font: 14px var(--mono);
}

.market-time {
  font-size: 3rem;
  color: #77869a;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(270px, .8fr);
  gap: 13px;
  align-items: start;
}

.market-panel,
.balance-panel,
.order-panel,
.portfolio-panel,
.terminal-panel {
  border: 1px solid #2b3745;
  border-radius: 8px;
  background: rgba(15, 21, 30, .97);
  border-left: 2px solid var(--emerald);
  transition: 0.1s;
}

.market-panel:hover,
.balance-panel:hover,
.order-panel:hover,
.portfolio-panel:hover,
.terminal-panel:hover {
  border: 1px solid #414f5f;
  border-left: 2px solid rgb(57, 211, 121);
  transition: 0.1s;
}

.market-panel {
  min-width: 0;
}

.panel-heading {
  min-height: 62px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 11px 14px;
}

.panel-heading span {
  color: var(--green);
  font-size: 1rem;
}

.panel-cash span {
  font-size: unset;
}

.panel-cash {
  padding: 0px 0px;
}

.panel-heading h2 {
  margin-top: 4px;
  font-size: 2rem;
}

.stock-table-header,
.stock-row {
  display: grid;
  grid-template-columns: 1fr .8fr 0.8fr 1.1fr 2.8rem;
  align-items: center;
  column-gap: 8px;
  padding: 0 14px;
}

.stock-table-header {
  padding: 0.5rem 0rem 0.5rem 0.8rem;
  min-height: 27px;
  border-block: 1px solid var(--line);
  background: #0c1118;
  color: #8290a2;
  font: 1rem var(--mono);
}

.stock-row {
  padding: 1em;
  width: 100%;
  min-height: 58px;
  border: 0;
  border-bottom: 1px solid #222c38;
  background: transparent;
  text-align: left;
  cursor: pointer;
  transition: 0.1s;
}

.stock-row:hover {
  background: #121c22;
  box-shadow: inset 2px 0 var(--cyan);
  transition: 0.1s;
}

.stock-identity {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.stock-icon {
  width: 45px;
  height: 45px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border: 1px solid currentColor;
  color: var(--cyan);
  font: 1rem var(--mono);
}

.color-green {
  color: var(--emerald);
}

.color-purple {
  color: var(--purple);
}

.color-pink {
  color: var(--pink);
}

.color-yellow {
  color: var(--yellow);
}

.color-cyan {
  color: var(--cyan);
}

.stock-name {
  min-width: 0;
}

.stock-name strong {
  display: block;
  color: #d8e1ec;
  font: 1rem var(--mono);
}

.stock-name small {
  display: block;
  margin-top: 3px;
  overflow: hidden;
  color: #8795a7;
  font-size: 0.875rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.stock-price {
  --price-color: #d8e1ec;
  color: var(--price-color);
  font: 1rem var(--mono);
}

.stock-change {
  color: var(--green);
  font: 1rem var(--mono);
}

.positive {
  color: var(--green);
}

.negative {
  color: var(--red);
}

.stock-behavior {
  color: #a0adbc;
  font-size: 1rem;
}

.stock-arrow {
  padding: 13px 15px;
  background-color: #131920;
  border: 1px solid #3a625f;
  border-radius: 8px;
  display: flex;
  transition: ease 0.1s;
}

.stock-arrow:hover {
  background-color: #212c38;
  transform: scale(1.05);
  transition: ease 0.1s;
}

.side-column {
  display: grid;
  gap: 13px;
}

.balance-panel {
  padding: 0px 14px 14px 14px;
  border-left: 2px solid var(--emerald);
}

.balance-label {
  display: flex;
  justify-content: space-between;
  margin-top: 19px;
  color: #a0adbc;
  font: 14px var(--mono);
}

.balance-label span {
  color: var(--emerald);
}

.balance-amount {
  margin: 2px 0 14px;
  color: #a9edc9;
  font: 1.8rem var(--mono);
}

.balance-amount span {
  font-size: 14px;
  color: #8290a2;
}

.balance-rule {
  height: 1px;
  background: var(--line);
}

.balance-foot {
  display: flex;
  justify-content: space-between;
  margin-top: 10px;
  color: #8795a7;
  font: 1rem var(--mono);
}

.balance-foot span:last-child {
  color: #d6e0eb;
}

.order-panel {
  padding: 0 14px 13px;
}

.order-heading {
  padding: 11px 0 4px;
}

.order-symbol {
  color: var(--cyan);
  font: 14px var(--mono);
}

.share-input {
  padding: 0.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border: 1px solid #303c4b;
  background: #0a0e14;
  border-radius: 8px;
}

.step-button {
  border: 0;
  background: transparent;
  color: #a0adbc;
  font-size: 2rem;
  cursor: pointer;
  width: 40px;
}

.step-button:hover {
  color: var(--cyan);
}

.share-input input {
  width: 80px;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text);
  text-align: center;
  font: 1rem var(--mono);
  appearance: textfield;
}

.share-input input::-webkit-inner-spin-button,
.share-input input::-webkit-outer-spin-button {
  appearance: none;
}

.order-estimate {
  display: flex;
  justify-content: space-between;
  margin: 11px 0;
  color: #8694a5;
  font: 1rem var(--mono);
}

.order-estimate strong {
  color: var(--text);
  font: 1rem var(--mono);
}

.trade-buttons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
}

.buy-button,
.sell-button {
  min-height: 34px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 9px;
  border: 1px solid #248462;
  background: #10251e;
  color: #70d9ad;
  font: 0.875rem var(--mono);
  cursor: pointer;
  border-radius: 8px;
  padding: 8px 14px;
}

.buy-button:hover {
  background: #153329;
}

.sell-button {
  border-color: #2e6970;
  background: #0c1c21;
  color: #7adce3;
}

.sell-button:hover {
  background: #11282d;
}

.sell-all-button {
  width: 100%;
  min-height: 31px;
  margin-top: 7px;
  border: 1px solid #633744;
  background: #21151b;
  color: #ee9aa8;
  font: 0.875rem var(--mono);
  cursor: pointer;
  padding: 8px 14px;
  border-radius: 8px;
}

.sell-all-button:hover:not(:disabled) {
  border-color: var(--red);
  background: #2b1920;
}

.sell-all-button:disabled,
.sell-all-position:disabled {
  opacity: .45;
  cursor: not-allowed;
}

.portfolio-panel {
  margin-top: 13px;
}

.portfolio-heading {
  min-height: 55px;
}

.portfolio-content {
  border-top: 1px solid var(--line);
}

.portfolio-empty,
.empty-line {
  margin: 0;
  padding: 14px;
  color: #94a1b1;
  font-size: 1rem;
}

.dashboard-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  padding: 13px 1px;
  color: #8290a2;
  font: 1rem var(--mono);
}

.dashboard-footer button,
.back-link {
  border: 0;
  background: transparent;
  color: var(--cyan);
  font: 1rem var(--mono);
  cursor: pointer;
}

.dashboard-footer button:hover,
.back-link:hover {
  color: var(--emerald);
}

.view-heading {
  align-items: center;
}

.back-link {
  padding: 8px 0 8px 12px;
}

.stock-detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(270px, .8fr);
  gap: 13px;
  align-items: start;
}

.stock-chart-panel,
.detail-order-panel {
  padding: 0 14px 13px;
}

.detail-last-tick {
  color: var(--emerald);
  font: 14px var(--mono);
}

.detail-price-row {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 0 14px;
}

.detail-price-row strong {
  --price-color: #dce5ef;
  color: var(--price-color);
  font: 24px var(--mono);
}

.detail-price-row span {
  color: var(--green);
  font: 14px var(--mono);
}

.chart-wrap {
  position: relative;
}

.chart-axis {
  margin: 0.5rem;
}

.chart-axis span {
  font-size: 1rem;
}

.detail-chart {
  width: 100%;
  height: 225px;
  margin-top: 8px;
  overflow: visible;
  touch-action: pan-y;
}

#detail-chart-grid {
  fill: none;
  stroke: #273341;
  stroke-width: 1;
  stroke-dasharray: 3 6;
}

#detail-chart-line {
  fill: none;
  stroke: var(--emerald);
  stroke-width: 2;
  stroke-linejoin: bevel;
  stroke-linecap: square;
}

#chart-hit-area {
  fill: transparent;
  pointer-events: all;
}

#chart-crosshair-x,
#chart-crosshair-y {
  stroke: #92a1b3;
  stroke-width: 1;
  stroke-dasharray: 3 4;
  opacity: 0;
  pointer-events: none;
}

#chart-crosshair-x.visible,
#chart-crosshair-y.visible {
  opacity: .7;
}

#chart-hover-dot {
  fill: var(--text);
  stroke: var(--emerald);
  stroke-width: 2;
  opacity: 0;
  pointer-events: none;
}

#chart-hover-dot.visible {
  opacity: 1;
}

#chart-hover-readout {
  font-size: 0.875rem;
}

.chart-tooltip {
  position: absolute;
  top: 6px;
  right: 8px;
  z-index: 2;
  display: grid;
  gap: 4px;
  padding: 7px 9px;
  border: 1px solid #3a4b5f;
  background: rgba(11, 14, 20, .95);
  color: var(--text);
  font: 14px var(--mono);
  pointer-events: none;
}

.chart-tooltip {
  top: 0;
  right: auto;
  left: 0;
  max-width: min(230px, calc(100% - 12px));
}

.chart-tooltip strong {
  color: var(--emerald);
  font-weight: 400;
}

.chart-tooltip span {
  color: #8795a7;
}

.chart-hover-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin: 2px 14px 0;
  color: #8795a7;
  font: 16px var(--mono);
}

.chart-hover-controls button {
  padding: 12px 20px;
  border: 1px solid var(--line);
  background: #0c1118;
  color: var(--cyan);
  font: 16px var(--mono);
  cursor: pointer;
  border-radius: 8px;
  transition: 0.1s;
}

.chart-hover-controls button:hover {
  border-color: var(--emerald);
  color: var(--emerald);
  transition: 0.1s;
}

#detail-chart.pinned #chart-hover-dot {
  fill: var(--emerald);
  stroke: #e4fff4;
}

.chart-stats {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  margin: 8px 14px 0;
  border: 1px solid var(--line);
  background: #0c1118;
  border-radius: 8px;
}

.chart-stats>div {
  display: grid;
  gap: 5px;
  padding: 16px;
  border-right: 1px solid var(--line);
}

.chart-stats>div:last-child {
  border-right: 0;
}

.chart-stats span {
  color: #8492a4;
  font: 1.2rem var(--mono);
}

.chart-stats strong {
  color: #dce5ef;
  font: 1rem var(--mono);
  font-weight: 400;
}

.detail-order-panel {
  padding-top: 14px;
}

.detail-description {
  min-height: 46px;
  color: #9aa8b9;
  font-size: 14px;
  line-height: 1.7;
}

.detail-metrics {
  border-top: 1px solid var(--line);
}

.detail-metrics>div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 9px 0;
  border-bottom: 1px solid #222c38;
  font: 14px var(--mono);
}

#assetprofile {
  margin-bottom: 7px;
}

.detail-metrics span {
  font-size: 1rem;
  color: #8795a7;
}

.panel-index {
  font-size: 1.5rem;
}

.detail-metrics strong {
  color: var(--text);
  font-weight: 400;
  text-align: right;
}

.position-performance {
  margin-top: 12px;
  padding: 12px;
  border: 1px solid #2b5548;
  border-radius: 7px;
  background: linear-gradient(135deg, rgba(16, 185, 129, .08), rgba(12, 17, 24, .92) 55%);
}

.position-performance-heading,
.position-performance-total {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
}

.position-performance-heading {
  padding-bottom: 9px;
  border-bottom: 1px solid var(--line);
  color: #9cabbc;
  font-size: 14px;
}

.position-performance-heading > span:last-child {
  color: var(--text);
  font-size: 1rem;
}

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

.position-performance-grid > div {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.position-performance-grid span,
.position-performance-total span {
  color: #8795a7;
  font-size: 12px;
}

.position-performance-grid strong {
  overflow-wrap: anywhere;
  color: var(--text);
  font-size: 14px;
  font-weight: 400;
}

.position-performance-total {
  padding-top: 9px;
  border-top: 1px solid var(--line);
}

.position-performance-total strong {
  font-size: 1rem;
  font-weight: 500;
  text-align: right;
}

.position-profit-note {
  margin: 8px 0 0;
  color: #718095;
  font-size: 11px;
  line-height: 1.5;
}

.positive-text {
  color: var(--green) !important;
}

.negative-text {
  color: var(--red) !important;
}

.detail-share-input {
  width: 100%;
  height: 35px;
  padding: 0 9px;
  border: 1px solid #303c4b;
  outline: 0;
  background: #0a0e14;
  color: var(--text);
  font: 14px var(--mono);
}

.detail-share-input:focus {
  border-color: var(--cyan);
  outline: 1px solid rgba(0, 214, 230, .25);
}

.asset-tabs {
  display: flex;
  gap: 1px;
  padding: 0 14px 10px;
  border-bottom: 1px solid var(--line);
  gap: 12px;
}

.asset-tab {
  padding: 8px 14px;
  border: 1px solid var(--line);
  background: #0c1118;
  color: #8795a7;
  font: 0.875rem var(--mono);
  cursor: pointer;
  border-radius: 8px;
  transition: 0.1s;
}

.asset-tab.active,
.asset-tab:hover {
  border-color: #248462;
  background: #10251e;
  color: var(--emerald);
  transition: 0.1s;
}

.activity-summary {
  margin-top: 10px;

}

.activity-summary>div {
  display: flex;
  justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px solid #222c38;
  font: 14px var(--mono);
}

.activity-summary span {
  color: #8795a7;
}

.activity-summary div:first-child strong {
  color: var(--green);
  font-weight: 400;
}

.activity-summary div:last-child strong {
  color: var(--red);
  font-weight: 400;
}

.activity-panel {
  margin-top: 15px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.activity-bars {
  display: grid;
  gap: 6px;
  margin-top: 10px;
}

.activity-meter {
  display: grid;
  grid-template-columns: 45px 1fr 35px;
  align-items: center;
  gap: 6px;
  color: #91a0b2;
  font: 14px var(--mono);
}

.activity-meter b {
  color: #aeb9c7;
  font-weight: 400;
  text-align: right;
}

.activity-meter meter {
  width: 100%;
  height: 8px;
  appearance: none;
  background: #202a35;
}

.activity-meter meter::-webkit-meter-bar {
  border: 0;
  border-radius: 0;
  background: #202a35;
}

.activity-meter .buy-meter::-webkit-meter-optimum-value {
  background: var(--green);
}

.activity-meter .sell-meter::-webkit-meter-optimum-value {
  background: var(--red);
}

.activity-meter .buy-meter::-moz-meter-bar {
  background: var(--green);
}

.activity-meter .sell-meter::-moz-meter-bar {
  background: var(--red);
}

.activity-feed {
  max-height: 225px;
  margin-top: 7px;
  overflow-y: auto;
  border-top: 1px solid #222c38;
}

.activity-event {
  min-height: 29px;
  display: grid;
  grid-template-columns: .8fr .9fr 1fr .8fr;
  align-items: center;
  gap: 4px;
  border-bottom: 1px solid #202a35;
  color: #9daabb;
  font: 14px var(--mono);
}

.activity-event.buy>span:first-child {
  color: var(--green);
}

.activity-event.sell>span:first-child {
  color: var(--red);
}

.activity-event>span:nth-child(3),
.activity-event time {
  text-align: right;
}

.activity-event time {
  color: #718095;
}

.line-green {
  stroke: var(--emerald) !important;
}

.line-cyan {
  stroke: var(--cyan) !important;
}

.line-purple {
  stroke: var(--purple) !important;
}

.line-pink {
  stroke: var(--pink) !important;
}

.line-yellow {
  stroke: var(--yellow) !important;
}

.profile-identity {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 15px;
}

.profile-avatar {
  width: 60px;
  height: 60px;
  display: grid;
  place-items: center;
  border: 1px solid var(--emerald);
  color: var(--emerald);
  font: 2rem var(--mono);
}

.profile-identity h2 {
  margin: 4px 0;
  color: var(--text);
  font: 2rem var(--mono);
}

.profile-identity p {
  color: #8492a4;
  font: 1rem var(--mono);
}

.profile-identity .profile-bio {
  max-width: 620px;
  margin: 7px 0;
  color: #a0adbc;
  font: 1rem var(--mono);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.profile-bio-wrap {
  border-radius: 8px;
  background-color: #0b0e14;
  border: 1px solid var(--line);
  width: 380px;
  padding: 0.5rem 0.5rem 0.5rem 1rem;
}

.profile-identity #profile-handle-label {
  color: #00d6e6;
}

.profile-menu {
  position: relative;
  width: max-content;
  margin: 10px 0;
  color: var(--cyan);
  font: 1rem var(--mono);
}

.profile-users {
  display: flex;
  align-items: center;
  gap: 1em;
  margin: 0px 0 12px 0;
}

.profile-menu summary {
  padding: 12px 16px;
  border: 1px solid var(--line);
  background: #0f151e;
  cursor: pointer;
  list-style: none;
  border-radius: 8px;
  transition: 0.1s;
}

.profile-menu summary:hover {
  border: 1px solid #3a475c;
  transition: 0.1s;
}

.profile-menu summary::-webkit-details-marker {
  display: none;
}


.profile-menu[open] summary {
  border-color: #3b5366;
}

.profile-menu>button {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  z-index: 3;
  min-width: 120px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  background: #101720;
  color: var(--text);
  text-align: left;
  font: 1rem var(--mono);
  cursor: pointer;
  border-radius: 8px;
  box-shadow: 0 0 8px #000000;
}

.profile-menu>button:hover {
  color: var(--emerald);
}

.profile-editor {
  margin-top: 0;
  padding-bottom: 14px;
}

.profile-form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 12px;
  padding: 0 14px;
}

.profile-form label {
  display: block;
  margin: 11px 0 5px;
  color: #9cabbc;
  font: 1rem var(--mono);
}

.profile-form label span {
  color: #718095;
}

.profile-form input,
.profile-form textarea {
  width: 100%;
  min-height: 34px;
  padding: 8px;
  border: 1px solid #303c4b;
  outline: 0;
  background: #0a0e14;
  color: var(--text);
  font: 1rem var(--mono);
}

.profile-form textarea {
  min-height: 68px;
  resize: vertical;
}

.profile-form input:focus,
.profile-form textarea:focus {
  border-color: var(--cyan);
  outline: 1px solid rgba(0, 214, 230, .25);
}

.profile-form label[for="profile-bio"],
#profile-bio,
.profile-form label[for="current-password"],
#current-password,
.profile-form label[for="new-password"],
#new-password,
.profile-form .form-message,
.profile-form .primary-button {
  grid-column: 1 / -1;
}

.profile-form .form-message {
  margin: 5px 0 0;
}

.player-name {
  display: inline-block;
  color: var(--text);
}

.name-emerald {
  color: #10b981 !important;
}

.name-cyan {
  color: #00d6e6 !important;
}

.name-amber {
  color: #dbc773 !important;
}

.name-spectrum {
  background: linear-gradient(90deg, #00d6e6 0%, #b499e9 16.66%, #ec8db2 33.33%, #00d6e6 50%, #b499e9 66.66%, #ec8db2 83.33%, #00d6e6 100%);
  background-size: 200% 100%;
  background-position: var(--micalab-shimmer-position, 0%) center;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent !important;
  text-shadow: none;
  animation: micalab-shimmer 4s linear infinite;
}

.name-rose {
  color: #ec8db2 !important;
}

.name-violet {
  color: #b499e9 !important;
}

@property --micalab-pulse-blur {
  syntax: "<length>";
  inherits: false;
  initial-value: 0px;
}

@property --micalab-shimmer-position {
  syntax: "<percentage>";
  inherits: false;
  initial-value: 0%;
}

@property --micalab-blink-opacity {
  syntax: "<number>";
  inherits: false;
  initial-value: 1;
}

@property --micalab-bounce-y {
  syntax: "<length>";
  inherits: false;
  initial-value: 0px;
}

@property --micalab-wave-spacing {
  syntax: "<length>";
  inherits: false;
  initial-value: 0px;
}

@property --micalab-tilt-angle {
  syntax: "<angle>";
  inherits: false;
  initial-value: 0deg;
}

@property --micalab-glow-blur {
  syntax: "<length>";
  inherits: false;
  initial-value: 0px;
}

@property --micalab-rainbow-hue {
  syntax: "<angle>";
  inherits: false;
  initial-value: 0deg;
}

@property --micalab-float-y {
  syntax: "<length>";
  inherits: false;
  initial-value: 0px;
}

@property --micalab-sway-angle {
  syntax: "<angle>";
  inherits: false;
  initial-value: 0deg;
}

@property --micalab-flicker-opacity {
  syntax: "<number>";
  inherits: false;
  initial-value: 1;
}

@property --micalab-tracking-spacing {
  syntax: "<length>";
  inherits: false;
  initial-value: 0px;
}

@property --micalab-sparkle-blur {
  syntax: "<length>";
  inherits: false;
  initial-value: 0px;
}

@property --micalab-prism-hue {
  syntax: "<angle>";
  inherits: false;
  initial-value: 0deg;
}

.terminal-forest {
  --emerald: #73d69b;
  --cyan: #a0d6a8;
}

.terminal-amber {
  --emerald: #e0b75f;
  --cyan: #e9a276;
  --green: #c9bd77;
}

.terminal-ice {
  --emerald: #8bd6e6;
  --cyan: #a9cbff;
  --green: #76d9c0;
}

.store-amber {
  color: #e0b75f !important;
}

.store-ice {
  color: #8bd6e6 !important;
}

.store-item h2.terminal-forest {
  color: #73d69b;
}

.store-item h2.terminal-amber {
  color: #e0b75f;
}

.store-item h2.terminal-ice {
  color: #8bd6e6;
}

.store-wallet {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px;
}

.store-wallet strong {
  color: var(--emerald);
  font: 15px var(--mono);
}

.store-categories {
  display: flex;
  gap: 6px;
  margin: 12px 0;
  overflow-x: auto;
}

.store-categories button {
  padding: 8px 12px;
  border: 1px solid var(--line);
  background: #0e131b;
  color: #9cabbc;
  font: 14px var(--mono);
  cursor: pointer;
  white-space: nowrap;
}

.store-categories button.active,
.store-categories button:hover {
  border-color: var(--emerald);
  color: var(--emerald);
}

.store-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 12px;
  margin-top: 13px;
}

.store-item {
  min-width: 0;
  overflow: hidden;
}

.store-item-copy {
  display: flex;
  min-height: 138px;
  flex-direction: column;
  padding: 13px;
}

.store-item h2 {
  margin: 12px 0 5px;
  color: var(--text);
  font-size: 16px;
  font-weight: 500;
}

.panel-index {
  font-size: 18px
}

.panel-index-store {
  font-size: 14px
}

.store-item p {
  margin: 0 0 12px;
  color: #96a4b5;
  font-size: 14px;
  line-height: 1.6;
}

.store-item-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px solid var(--line);
  font: 14px var(--mono);
}

.store-item-foot strong {
  color: #cbd5e0;
  font-weight: 400;
}

.store-action {
  padding: 6px 10px;
  border: 1px solid #248462;
  background: #10251e;
  color: var(--emerald);
  font: 14px var(--mono);
  cursor: pointer;
}

.store-action:hover {
  background: #153329;
}

.item-status {
  color: var(--green);
}

.inventory-summary {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 12px;
}

.inventory-summary .store-wallet {
  min-height: 60px;
}

.shop-preview,
.theme-preview {
  --emerald: #10b981;
  --cyan: #00d6e6;
}

.shop-preview {
  height: 168px;
  min-height: 116px;
  padding: 12px;
  border-bottom: 1px solid var(--line);
  background: #0b1017;
}

.name-shop-preview {
  display: flex;
  height: 168px;
  align-items: center;
  gap: 10px;
}

.name-shop-preview>span:nth-child(2) {
  display: grid;
  gap: 6px;
}

.name-shop-preview small {
  color: #8492a4;
  font: 14px var(--mono);
  text-transform: uppercase;
}

.name-shop-preview strong {
  color: #e0e8ef;
  font-size: 17px;
  font-weight: 600;
}

.name-shop-preview>b {
  margin-left: auto;
  color: #8292a3;
  font: 14px var(--mono);
}

.name-preview-avatar {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid #344253;
  border-radius: 50%;
  background: #121b25;
  color: var(--cyan);
  font: 14px var(--mono);
}

.theme-preview {
  display: grid;
  gap: 10px;
  padding: 11px;
  border: 1px solid #2b3745;
  background: #101720;
  color: #aab7c6;
  font: 14px var(--mono);
}

.theme-preview header,
.theme-preview footer {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  padding-bottom: 7px;
  border-bottom: 1px solid #2b3745;
  color: var(--emerald);
}

.theme-preview header b,
.theme-preview footer b {
  color: var(--cyan);
  font-weight: 400;
}

.theme-preview-main {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.theme-preview-name,
.theme-preview-quote {
  display: grid;
  gap: 5px;
  align-content: center;
  min-height: 51px;
  padding: 7px;
  border: 1px solid #2b3745;
  background: #0b1017;
}

.theme-preview-name small,
.theme-preview-quote small {
  color: #8492a4;
}

.theme-preview-name strong:not(.player-name) {
  color: #e0e8ef;
  font-size: 14px;
}

.theme-preview-code {
  color: #74869a;
}

.theme-preview-price {
  color: var(--cyan);
  font-size: 14px;
}

.theme-preview-change {
  color: var(--emerald);
}

.theme-preview-bars {
  height: 26px;
  display: flex;
  align-items: end;
  gap: 4px;
  padding: 0 2px;
}

.theme-preview-bars i {
  flex: 1;
  height: 35%;
  background: var(--emerald);
  opacity: .75;
}

.theme-preview-bars i:nth-child(2n) {
  height: 68%;
  background: #eb7187;
}

.theme-preview-bars i:nth-child(3n) {
  height: 48%;
}

.theme-preview footer {
  padding: 6px 0 0;
  border-top: 1px solid #2b3745;
  border-bottom: 0;
  color: #8492a4;
}

.store-item .theme-preview {
  border: 0;
  border-bottom: 1px solid var(--line);
}

.profile-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 12px;
  border: 1px solid #2b3745;
  background: #0e131b;
  font-size: 100px var(--mono);
  border-radius: 8px;
}

.profile-stat {
  min-height: 61px;
  display: grid;
  align-content: center;
  gap: 6px;
  padding: 16px 20px;
  border-right: 1px solid #273341;
  border-bottom: 1px solid #273341;
}

.profile-stat span {
  color: #8492a4;
  font: 1rem var(--mono);
}

.profile-stat strong {
  color: #dce5ef;
  font: 1rem var(--mono);
  font-weight: 400;
}

.profile-content-grid {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(0, 1.3fr);
  gap: 13px;
  margin-top: 13px;
}

.profile-content-grid .terminal-panel {
  min-width: 0;
}

.profile-holding {
  width: 100%;
  min-height: 38px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 6px;
  border-bottom: 1px solid #222c38;
}

.profile-holding .holding-open {
  width: 100%;
  min-height: 38px;
  display: grid;
  grid-template-columns: .7fr 1fr 1fr;
  align-items: center;
  gap: 6px;
  padding: 0 12px;
  border: 0;
  background: transparent;
  text-align: left;
  font: 14px var(--mono);
  cursor: pointer;
}

.holding-row .holding-open {
  width: 100%;
  min-height: 38px;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  align-items: center;
  padding: 0 12px;
  border: 0;
  background: transparent;
  text-align: left;
  font: 14px var(--mono);
  cursor: pointer;
}

.holding-row {
  width: 100%;
  min-height: 38px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  border-bottom: 1px solid #222c38;
}

.holding-row .holding-open:hover,
.profile-holding .holding-open:hover {
  background: #121c22;
}

.holding-open strong {
  color: var(--cyan);
  font-weight: 400;
}

.holding-open span {
  color: #9daabb;
}

.holding-open span:last-child {
  color: var(--text);
  text-align: right;
}

.sell-all-position {
  align-self: stretch;
  padding: 0 12px;
  border: 0;
  border-left: 1px solid #303947;
  background: transparent;
  color: #ee9aa8;
  font: 14px var(--mono);
  cursor: pointer;
}

.sell-all-position:hover {
  background: #21151b;
}

.trade-record {
  min-height: 40px;
  display: grid;
  grid-template-columns: .55fr .9fr 1fr 1.25fr;
  align-items: center;
  gap: 8px;
  padding: 0 11px;
  border-bottom: 1px solid #222c38;
  color: #9eacbd;
  font: 14px var(--mono);
}

.trade-record:last-child {
  border-bottom: 0;
}

.trade-record>span:nth-child(3) {
  color: var(--text);
  text-align: right;
}

.trade-record time {
  color: #7f8da0;
  text-align: right;
}

.trade-side.buy {
  color: var(--green);
}

.trade-side.sell {
  color: var(--red);
}

.admin-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 12px 0;
  border: 1px solid var(--line);
  background: #0e131b;
}

.admin-stat {
  display: grid;
  gap: 6px;
  min-height: 60px;
  padding: 10px 13px;
  border-right: 1px solid var(--line);
}

.admin-stat:last-child {
  border-right: 0;
}

.admin-stat span {
  color: #8795a7;
  font: 14px var(--mono);
}

.admin-stat strong {
  color: var(--emerald);
  font: 14px var(--mono);
  font-weight: 400;
}

.admin-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  align-items: start;
}

.admin-panel {
  min-width: 0;
  padding-bottom: 12px;
}

.admin-assets {
  max-height: 350px;
  overflow-y: auto;
}

.admin-asset-row {
  min-height: 48px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(90px, .55fr) auto;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-top: 1px solid #222c38;
}

.admin-asset-name {
  min-width: 0;
  display: grid;
  gap: 4px;
  overflow: hidden;
}

.admin-asset-name strong {
  color: var(--cyan);
  font: 14px var(--mono);
  font-weight: 400;
}

.admin-asset-name small {
  overflow: hidden;
  color: #8795a7;
  font: 14px var(--mono);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-asset-row input,
.admin-form input,
.admin-form select {
  width: 100%;
  min-width: 0;
  height: 32px;
  padding: 0 8px;
  border: 1px solid #303c4b;
  outline: 0;
  background: #0a0e14;
  color: var(--text);
  font: 14px var(--mono);
}

.admin-asset-row input:focus,
.admin-form input:focus,
.admin-form select:focus {
  border-color: var(--cyan);
  outline: 1px solid rgba(0, 214, 230, .2);
}

.admin-asset-row .store-action {
  white-space: nowrap;
}

.admin-item-row {
  grid-template-columns: minmax(0, 1fr) auto;
}

.admin-item-price {
  color: #b9c5d2;
  font: 14px var(--mono);
  white-space: nowrap;
}

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

.admin-form label {
  min-width: 0;
  display: grid;
  gap: 6px;
  margin: 9px 0 0;
  color: #9cabbc;
  font: 14px var(--mono);
}

.admin-form input,
.admin-form select {
  display: block;
}

.admin-form .admin-wide,
.admin-form .primary-button,
.admin-form .form-message {
  grid-column: 1 / -1;
}

.admin-form .primary-button {
  margin-top: 12px;
}

.admin-form .form-message {
  min-height: 12px;
  margin: 3px 0 0;
}

.admin-behavior-help {
  margin: 2px 0 6px;
  color: #8492a4;
  font-size: 12px;
  line-height: 1.5;
}

.admin-form input[type="color"] {
  padding: 3px;
}

.gradient-colors {
  min-width: 0;
  margin: 12px 0 0;
  padding: 9px 10px;
  border: 1px solid var(--line);
}

.gradient-colors legend {
  padding: 0 5px;
  color: #9cabbc;
  font: 14px var(--mono);
}

.admin-theme-colors {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 12px;
}

.admin-theme-colors label {
  min-width: 0;
  display: grid;
  gap: 5px;
  color: #9cabbc;
  font: 14px var(--mono);
}

.gradient-color-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(115px, 1fr));
  gap: 8px;
}

.gradient-color-list label {
  min-width: 0;
  display: grid;
  gap: 5px;
  margin: 0;
  color: #9cabbc;
  font: 14px var(--mono);
}

.gradient-stop-control {
  display: flex;
  align-items: center;
  gap: 5px;
}

.gradient-stop-control input[type="color"] {
  flex: 1;
  min-width: 0;
  height: 34px;
  padding: 3px;
}

.gradient-stop-control button {
  min-width: 34px;
  min-height: 34px;
  padding: 5px;
}

.gradient-stop-control button:disabled {
  opacity: .4;
  cursor: not-allowed;
}

.gradient-colors>button {
  min-height: 34px;
  margin-top: 9px;
}

.admin-form .admin-check {
  display: flex;
  align-items: center;
  gap: 8px;
}

.admin-form .admin-check input,
.admin-animations input {
  width: auto;
  height: auto;
  accent-color: var(--emerald);
}

.admin-animations {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  margin: 12px 0 0;
  padding: 8px 10px;
  border: 1px solid var(--line);
}

.admin-animations legend {
  padding: 0 5px;
  color: #9cabbc;
  font: 14px var(--mono);
}

.admin-animations label {
  display: flex;
  align-items: center;
  gap: 5px;
  color: #9cabbc;
  font: 14px var(--mono);
}

.admin-style-preview {
  display: grid;
  gap: 8px;
  margin-top: 10px;
  padding: 12px;
  border: 1px dashed #3a4b5f;
  background: #0a0e14;
}

.preview-label {
  color: #76879b;
  font: 14px var(--mono);
  letter-spacing: .08em;
  text-transform: uppercase;
}

.admin-style-preview .theme-preview {
  width: 100%;
}

.name-preview {
  min-height: 57px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px;
  border: 1px solid #2b3745;
  background: #101720;
}

.name-preview>span:nth-child(2) {
  display: grid;
  gap: 4px;
}

.name-preview small {
  color: #8492a4;
  font: 14px var(--mono);
  text-transform: uppercase;
}

.name-preview strong {
  color: #e0e8ef;
  font-size: 14px;
}

.name-preview>b {
  margin-left: auto;
  color: #8292a3;
  font: 14px var(--mono);
}

.admin-asset-preview {
  min-height: 58px;
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  padding: 9px;
  border: 1px solid #2b3745;
  background: #0a0e14;
}

.asset-preview-symbol {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid #326c74;
  background: #10232a;
  color: var(--cyan);
  font: 14px var(--mono);
  text-transform: uppercase;
}

.admin-asset-preview>span:nth-child(2) {
  display: grid;
  gap: 4px;
}

.admin-asset-preview small {
  color: #8492a4;
  font: 14px var(--mono);
  text-transform: uppercase;
}

.asset-preview-name {
  color: #dce5ef;
  font-size: 14px;
  font-weight: 500;
}

.asset-preview-price {
  margin-left: auto;
  color: var(--emerald);
  font: 14px var(--mono);
}

.admin-asset-preview.crypto-preview {
  border-color: #6b4d8c;
  box-shadow: inset 3px 0 #b499e9;
}

.crypto-preview .asset-preview-symbol {
  border-color: #6b4d8c;
  background: #20162c;
  color: #c6a5ef;
}

.admin-note {
  padding: 0 12px;
  color: #8795a7;
  font: 14px var(--mono);
}

.admin-edit-form {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  margin: 8px;
  padding: 9px;
  border: 1px solid #222c38;
}

.admin-edit-form label {
  display: grid;
  gap: 4px;
  color: #8795a7;
  font: 14px var(--mono);
}

.admin-edit-form input,
.admin-edit-form select {
  width: 100%;
  min-width: 0;
  height: 29px;
  padding: 0 6px;
  border: 1px solid #303c4b;
  background: #0a0e14;
  color: var(--text);
  font: 14px var(--mono);
}

.admin-edit-form .admin-wide,
.admin-edit-form button {
  grid-column: 1 / -1;
}

.admin-user-card {
  margin: 8px;
  padding: 10px;
  border: 1px solid #273341;
}

.admin-user-card>header {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 9px;
  color: var(--cyan);
  font: 14px var(--mono);
}

.admin-user-holdings {
  margin: 6px 0;
  color: #9cabbc;
  font: 14px var(--mono);
}

.admin-user-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

.admin-user-form label {
  display: grid;
  gap: 4px;
  color: #8795a7;
  font: 14px var(--mono);
}

.admin-user-form input,
.admin-user-form select {
  width: 100%;
  min-width: 0;
  height: 29px;
  padding: 0 6px;
  border: 1px solid #303c4b;
  background: #0a0e14;
  color: var(--text);
  font: 14px var(--mono);
}

.admin-user-form button {
  grid-column: 1 / -1;
}

.price-up {
  animation: price-up .55s ease-out;
}

.price-down {
  animation: price-down .55s ease-out;
}

@keyframes price-up {
  0% {
    color: #70d9ad;
    text-shadow: 0 0 12px rgba(16, 185, 129, .7);
  }

  100% {
    color: var(--price-color, #dce5ef);
    text-shadow: none;
  }
}

@keyframes price-down {
  0% {
    color: #ee8c9d;
    text-shadow: 0 0 12px rgba(238, 140, 157, .65);
  }

  100% {
    color: var(--price-color, #dce5ef);
    text-shadow: none;
  }
}

.toast {
  position: fixed;
  right: 20px;
  bottom: 18px;
  z-index: 10;
  max-width: calc(100vw - 40px);
  padding: 10px 13px;
  border: 1px solid #248462;
  background: #10251e;
  color: #70d9ad;
  font: 14px var(--mono);
  opacity: 0;
  transform: translateY(5px);
  transition: .18s;
  pointer-events: none;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}

.toast.error {
  border-color: #7b3947;
  background: #26171e;
  color: var(--red);
}

@keyframes ticker-scroll {
  to {
    transform: translateX(-50%);
  }
}

@keyframes micalab-pulse {
  50% {
    --micalab-pulse-blur: 7px;
  }
}

@keyframes micalab-shimmer {
  from {
    --micalab-shimmer-position: 0%;
  }

  to {
    --micalab-shimmer-position: 100%;
  }
}

@keyframes micalab-blink {
  50% {
    --micalab-blink-opacity: .45;
  }
}

@keyframes micalab-bounce {
  50% {
    --micalab-bounce-y: -3px;
  }
}

@keyframes micalab-wave {
  50% {
    --micalab-wave-spacing: .12em;
  }
}

@keyframes micalab-tilt {
  0%, 100% {
    --micalab-tilt-angle: -2deg;
  }

  50% {
    --micalab-tilt-angle: 2deg;
  }
}

@keyframes micalab-glow {
  50% {
    --micalab-glow-blur: 5px;
  }
}

@keyframes micalab-rainbow {
  to {
    --micalab-rainbow-hue: 360deg;
  }
}

@keyframes micalab-float {
  50% {
    --micalab-float-y: -5px;
  }
}

@keyframes micalab-sway {
  0%, 100% {
    --micalab-sway-angle: -4deg;
  }

  50% {
    --micalab-sway-angle: 4deg;
  }
}

@keyframes micalab-flicker {
  0%, 100% {
    --micalab-flicker-opacity: 1;
  }

  38% {
    --micalab-flicker-opacity: .55;
  }

  42% {
    --micalab-flicker-opacity: .9;
  }

  47% {
    --micalab-flicker-opacity: .65;
  }
}

@keyframes micalab-tracking {
  50% {
    --micalab-tracking-spacing: .08em;
  }
}

@keyframes micalab-sparkle {
  25%, 75% {
    --micalab-sparkle-blur: 5px;
  }

  50% {
    --micalab-sparkle-blur: 1px;
  }
}

@keyframes micalab-prism {
  to {
    --micalab-prism-hue: 360deg;
  }
}

@media (max-width: 850px) {
  .app-shell {
    padding-inline: 22px;
  }

  .auth-layout {
    grid-template-columns: minmax(0, 1fr) 350px;
    gap: 30px;
  }

  .dashboard-grid,
  .stock-detail-grid {
    grid-template-columns: minmax(0, 1.4fr) minmax(245px, .8fr);
  }

  .stock-table-header,
  .stock-row {
    grid-template-columns: 1.15fr .8fr .8fr 13px;
  }

  .stock-table-header span:nth-child(4),
  .stock-behavior {
    display: none;
  }

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

@media (max-width: 700px) {
  .app-shell {
    padding-left: max(15px, env(safe-area-inset-left));
    padding-right: max(15px, env(safe-area-inset-right));
  }

  .topbar {
    min-height: unset;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    padding: 8px 0;
  }

  .ticker-track {
    min-height: 27px;
  }

  .main-nav {
    min-height: 0;
    overflow-x: auto;
    overflow-y: hidden;
    overscroll-behavior-x: contain;
    scrollbar-width: thin;
    -webkit-overflow-scrolling: touch;
  }

  .nav-link {
    min-height: 44px;
    flex: 0 0 auto;
    padding-inline: 12px;
  }

  .nav-current {
    display: none;
  }

  .auth-layout {
    min-height: unset;
    grid-template-columns: 1fr;
    gap: 25px;
    padding: 35px 0;
  }

  .hero-copy h1 {
    font-size: clamp(38px, 11vw, 50px);
  }

  .auth-card {
    width: 100%;
    max-width: 420px;
    justify-self: center;
  }

  .dashboard-grid,
  .stock-detail-grid {
    grid-template-columns: 1fr;
  }

  .side-column {
    grid-template-columns: 1fr 1fr;
  }

  .balance-amount {
    font-size: 19px;
  }

  .profile-content-grid {
    grid-template-columns: 1fr;
  }

  .profile-form {
    grid-template-columns: 1fr;
  }

  .trading-view,
  .content-view {
    padding-top: 22px;
  }

  .market-heading,
  .view-heading {
    gap: 10px;
  }

  .detail-chart {
    height: 190px;
  }

  .step-button {
    width: 44px;
    height: 42px;
  }

  .buy-button,
  .sell-button,
  .sell-all-button,
  .store-action {
    min-height: 40px;
  }

  .chart-hover-controls button,
  .store-categories button {
    min-height: 40px;
  }

  .admin-form,
  .admin-edit-form,
  .admin-user-form {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 470px) {
  .app-shell {
    padding-left: max(10px, env(safe-area-inset-left));
    padding-right: max(10px, env(safe-area-inset-right));
  }

  .brand-name {
    font-size: 14px;
  }

  .ticker-group {
    gap: 14px;
    padding-right: 14px;
  }

  .ticker-item {
    gap: 5px;
    font-size: 14px;
  }

  .nav-link {
    padding-inline: 10px;
    font-size: 14px;
  }

  .market-heading h1,
  .view-heading h1 {
    font-size: 35px;
  }

  .market-heading,
  .view-heading {
    align-items: start;
  }

  .market-status {
    font-size: 14px;
  }

  .stock-table-header,
  .stock-row {
    grid-template-columns: 1.1fr .77fr .78fr 12px;
    padding-inline: 8px;
    gap: 4px;
  }

  .stock-row {
    min-height: 62px;
  }

  .stock-icon {
    width: 22px;
    height: 22px;
  }

  .stock-identity {
    gap: 5px;
  }

  .stock-name strong,
  .stock-price {
    font-size: 14px;
  }

  .stock-name small,
  .stock-change {
    font-size: 14px;
  }

  .stock-table-header {
    font-size: 14px;
  }

  .side-column {
    grid-template-columns: 1fr;
  }

  .balance-amount {
    font-size: 24px;
  }

  .inventory-summary {
    grid-template-columns: 1fr 1fr;
    gap: 6px;
  }

  .inventory-summary .store-wallet {
    padding: 10px;
  }

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

  .trade-record {
    grid-template-columns: .5fr .8fr .9fr;
  }

  .trade-record time {
    display: none;
  }

  .chart-stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

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

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

  .admin-stat:nth-child(2) {
    border-right: 0;
  }

  .admin-stat:nth-child(-n + 2) {
    border-bottom: 1px solid var(--line);
  }

  .dashboard-footer {
    align-items: start;
    gap: 5px;
    font-size: 14px;
  }

  .detail-price-row {
    flex-wrap: wrap;
    gap: 6px 10px;
  }

  .detail-price-row strong {
    font-size: 20px;
  }

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

  .chart-stats>div:nth-child(2n) {
    border-right: 0;
  }

  .profile-identity {
    align-items: flex-start;
    padding: 12px;
  }

  .trade-buttons {
    gap: 8px;
  }

  .activity-event {
    grid-template-columns: .75fr .8fr 1fr .7fr;
    font-size: 14px;
  }
}

@media (max-width: 360px) {
  .nav-link {
    padding-inline: 9px;
  }

  .market-heading h1,
  .view-heading h1 {
    font-size: 31px;
  }

  .stock-table-header,
  .stock-row {
    grid-template-columns: minmax(0, 1fr) .75fr .72fr 10px;
  }

  .stock-table-header,
  .stock-row {
    padding-inline: 6px;
    gap: 3px;
  }

  .stock-name strong,
  .stock-price {
    font-size: 14px;
  }

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

@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}

.profile-privacy-option {
  display: flex;
  align-items: center;
  gap: 8px;
  grid-column: 1 / -1;
}

.profile-privacy-option input {
  width: auto;
}

.profile-privacy-option span {
  color: var(--muted);
}

.friend-name-link {
  display: block;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-weight: 700;
  text-align: left;
  cursor: pointer;
}

.friend-name-link:hover {
  color: var(--accent);
}

/* Mobile layout refinements */
button,
input,
select,
textarea {
  touch-action: manipulation;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 2px;
}

@media (max-width: 760px) {
  .app-shell,
  main,
  .trading-view,
  .content-view {
    min-width: 0;
  }

  .auth-layout {
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
  }

  .dashboard-grid,
  .stock-detail-grid,
  .profile-content-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .detail-chart {
    height: clamp(160px, 48vw, 210px);
  }

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

  .chart-stats > div:nth-child(2n) {
    border-right: 0;
  }

  .chart-stats > div:last-child {
    border-right: 0;
  }

  .chart-hover-controls {
    align-items: stretch;
    flex-direction: column;
    margin-inline: 0;
  }

  .chart-hover-controls > span {
    overflow-wrap: anywhere;
  }

  .chart-hover-controls button {
    align-self: flex-start;
  }

  .profile-bio-wrap {
    width: 100%;
    min-width: 0;
  }

  .admin-asset-row {
    grid-template-columns: minmax(0, 1fr) minmax(90px, .7fr);
  }

  .admin-asset-row .store-action {
    grid-column: 1 / -1;
  }
}

@media (max-width: 560px) {
  .app-shell {
    padding-left: max(12px, env(safe-area-inset-left));
    padding-right: max(12px, env(safe-area-inset-right));
  }

  .topbar {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 6px;
  }

  .topbar-right {
    align-items: center;
    gap: 4px;
  }

  .brand {
    gap: 6px;
  }

  .brand-name {
    font-size: clamp(12px, 3.7vw, 15px);
  }

  .notification-button,
  .account-button {
    min-width: 44px;
    min-height: 44px;
  }

  .account-button {
    max-width: 138px;
    gap: 5px;
    padding: 0 2px;
    font-size: 12px;
  }

  #account-name {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .account-avatar {
    flex: 0 0 28px;
    width: 28px;
    height: 28px;
  }

  .account-caret svg {
    width: 13px;
    height: 13px;
  }

  .notification-panel {
    right: -4px;
    width: min(360px, calc(100vw - 24px));
  }

  .main-nav {
    justify-content: flex-start;
    padding-inline: 0;
  }

  .nav-link {
    min-height: 44px;
  }

  .auth-layout {
    padding: 25px 0 32px;
  }

  .hero-copy h1 {
    margin-bottom: 1.5rem;
    font-size: clamp(34px, 10vw, 46px);
  }

  .auth-card {
    padding: 20px 16px 17px;
  }

  .auth-heading h2,
  .panel-heading h2 {
    font-size: clamp(1.35rem, 6vw, 1.8rem);
  }

  .market-heading,
  .view-heading {
    align-items: flex-start;
    flex-wrap: wrap;
    margin-bottom: 15px;
  }

  .market-heading h1,
  .view-heading h1 {
    margin-top: 8px;
    font-size: clamp(28px, 8vw, 36px);
    overflow-wrap: anywhere;
  }

  .market-time {
    font-size: 1rem;
  }

  .market-status {
    padding-top: 10px;
  }

  .back-link {
    min-height: 44px;
    padding: 8px 0;
    white-space: nowrap;
  }

  .stock-table-header,
  .stock-row {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas: "identity price" "identity change";
    column-gap: 10px;
  }

  .stock-table-header {
    grid-template-areas: "asset price";
    align-items: center;
    padding: 8px 10px;
    font-size: 12px;
  }

  .stock-table-header span:first-child {
    grid-area: asset;
  }

  .stock-table-header span:nth-child(2) {
    grid-area: price;
    text-align: right;
  }

  .stock-table-header span:nth-child(n + 3) {
    display: none;
  }

  .stock-row {
    min-height: 68px;
    padding: 9px 10px;
  }

  .stock-identity {
    grid-area: identity;
    gap: 8px;
  }

  .stock-icon {
    width: 32px;
    height: 32px;
    font-size: 12px;
  }

  .stock-name strong,
  .stock-price {
    font-size: 13px;
  }

  .stock-name small,
  .stock-change {
    font-size: 12px;
  }

  .stock-price {
    grid-area: price;
    justify-self: end;
    white-space: nowrap;
  }

  .stock-change {
    grid-area: change;
    justify-self: end;
    white-space: nowrap;
  }

  .stock-arrow {
    display: none;
  }

  .asset-tabs {
    flex-wrap: wrap;
    padding-inline: 10px;
  }

  .asset-tab {
    min-height: 42px;
  }

  .side-column {
    grid-template-columns: minmax(0, 1fr);
  }

  .balance-amount {
    font-size: clamp(20px, 7vw, 24px);
  }

  .detail-metrics > div {
    align-items: baseline;
  }

  .detail-metrics span,
  .detail-metrics strong {
    min-width: 0;
    overflow-wrap: anywhere;
  }

  .detail-metrics strong {
    max-width: 58%;
  }

  .profile-identity {
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr);
    align-items: start;
    gap: 10px;
    padding: 12px;
  }

  .profile-avatar {
    width: 44px;
    height: 44px;
    font-size: 1.4rem;
  }

  .profile-identity-copy {
    min-width: 0;
  }

  .profile-users {
    flex-wrap: wrap;
    gap: 2px 10px;
    margin-bottom: 6px;
  }

  .profile-identity h2 {
    font-size: 1.35rem;
    overflow-wrap: anywhere;
  }

  .profile-identity p {
    margin-block: 5px;
    font-size: 12px;
  }

  .profile-bio-wrap {
    padding: 6px 8px;
  }

  .profile-identity.external-profile .public-profile-actions {
    grid-column: 1 / -1;
  }

  .public-profile-actions .primary-button {
    width: 100%;
  }

  .friends-panel,
  .users-directory-panel,
  .public-profile-card {
    padding: 12px;
  }

  .friend-search-row {
    flex-direction: column;
  }

  .friend-search-row .primary-button {
    width: 100%;
    min-height: 44px;
  }

  .friend-card {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .friend-card-actions {
    width: 100%;
    justify-content: flex-start;
  }

  .friend-action {
    min-height: 40px;
  }

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

  .profile-stat {
    padding: 12px;
    overflow-wrap: anywhere;
  }

  .profile-stat:nth-child(2n) {
    border-right: 0;
  }

  .profile-form {
    padding-inline: 12px;
  }

  .profile-form input,
  .profile-form textarea,
  .admin-form input,
  .admin-form select,
  .admin-edit-form input,
  .admin-edit-form select,
  .admin-user-form input,
  .admin-user-form select,
  .detail-share-input,
  .friend-search-row input,
  .input-wrap input {
    font-size: 16px;
  }

  .store-categories {
    padding-bottom: 3px;
    scrollbar-width: thin;
    -webkit-overflow-scrolling: touch;
  }

  .store-categories button {
    min-height: 44px;
  }

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

  .store-grid,
  .users-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .trade-record {
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    gap: 5px;
    padding: 8px 10px;
    font-size: 12px;
  }

  .trade-record > span:nth-child(3) {
    overflow-wrap: anywhere;
  }

  .activity-event {
    min-height: 40px;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 2px 8px;
    padding: 5px 0;
    font-size: 12px;
  }

  .activity-event > span:nth-child(3) {
    grid-column: 2;
    grid-row: 1;
  }

  .activity-event time {
    grid-column: 2;
    grid-row: 2;
  }

  .dashboard-footer {
    flex-wrap: wrap;
    font-size: 12px;
  }

  .dashboard-footer > span:nth-child(2) {
    margin-left: auto;
  }

  .dashboard-footer button {
    min-height: 44px;
  }

  .toast {
    right: max(12px, env(safe-area-inset-right));
    bottom: max(12px, env(safe-area-inset-bottom));
    left: max(12px, env(safe-area-inset-left));
    max-width: none;
  }
}

@media (max-width: 380px) {
  body {
    min-width: 0;
  }

  .app-shell {
    padding-left: max(10px, env(safe-area-inset-left));
    padding-right: max(10px, env(safe-area-inset-right));
  }

  .topbar-right {
    gap: 0;
  }

  .account-button {
    max-width: 112px;
  }

  .account-caret {
    display: none;
  }

  .stock-table-header,
  .stock-row {
    column-gap: 6px;
    padding-inline: 8px;
  }

  .stock-icon {
    width: 28px;
    height: 28px;
  }

  .admin-edit-form {
    grid-template-columns: minmax(0, 1fr);
  }

  .inventory-summary {
    grid-template-columns: minmax(0, 1fr);
  }

  .chart-stats > div {
    padding: 11px;
  }
}

/* Admin workspace and compact card previews */
.theme-preview {
  min-width: 0;
  grid-template-rows: auto 1fr auto auto;
  gap: 9px;
  overflow: hidden;
}

.theme-preview header,
.theme-preview footer {
  min-width: 0;
  align-items: center;
}

.theme-preview header > span,
.theme-preview header > b,
.theme-preview footer > span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.theme-preview-main {
  min-width: 0;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.theme-preview-name,
.theme-preview-quote {
  min-width: 0;
  overflow: hidden;
}

.theme-preview-name > *,
.theme-preview-quote > * {
  min-width: 0;
  overflow-wrap: anywhere;
}

.shop-preview.theme-preview {
  height: auto;
  min-height: 0;
  padding: 12px;
}

.shop-preview.theme-preview .theme-preview-main {
  min-height: 116px;
}

.shop-preview.theme-preview .theme-preview-bars {
  height: 24px;
}

.store-item .theme-preview {
  border: 0;
  border-bottom: 1px solid var(--line);
}

.admin-stats {
  overflow: hidden;
  border-radius: 8px;
}

.admin-stat {
  min-width: 0;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.admin-stat span {
  letter-spacing: .05em;
  text-transform: uppercase;
}

.admin-grid {
  gap: 14px;
  align-items: stretch;
}

.admin-grid.single-panel {
  grid-template-columns: minmax(0, 1fr);
}

.admin-panel {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-radius: 9px;
}

.admin-panel > .panel-heading {
  min-height: 70px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(90deg, rgba(16, 185, 129, .07), transparent 70%);
}

.admin-panel > .panel-heading .panel-index {
  color: var(--emerald);
  font-size: 12px;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.admin-panel > .panel-heading h2 {
  margin-top: 4px;
  font-size: clamp(1.25rem, 2vw, 1.65rem);
}

.admin-assets {
  flex: 0 0 auto;
  max-height: 720px;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-color: #344556 transparent;
}

.admin-asset-entry + .admin-asset-entry {
  border-top: 1px solid var(--line);
}

.admin-asset-row {
  grid-template-columns: minmax(0, 1fr) minmax(110px, .45fr) auto;
  padding: 10px 14px;
  border-top: 0;
  border-bottom: 1px solid var(--line);
}

.admin-asset-row .store-action,
.admin-edit-form .store-action,
.admin-form > .store-action,
.admin-user-form .store-action {
  min-height: 40px;
}

.admin-form {
  gap: 2px 14px;
  padding: 4px 16px 14px;
}

.admin-form label,
.admin-edit-form label,
.admin-user-form label {
  line-height: 1.45;
}

.admin-form input,
.admin-form select,
.admin-edit-form input,
.admin-edit-form select,
.admin-user-form input,
.admin-user-form select,
.admin-asset-row input {
  min-height: 40px;
  border-radius: 5px;
}

.admin-form .primary-button {
  min-height: 44px;
}

.admin-edit-form {
  gap: 9px;
  margin: 10px 12px;
  padding: 12px;
  border-color: #2b3745;
  border-radius: 7px;
  background: rgba(10, 14, 20, .42);
}

.admin-edit-form .admin-asset-name {
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
}

.admin-user-card {
  border-color: #2b3745;
  border-radius: 7px;
  background: rgba(10, 14, 20, .42);
}

.admin-user-card > header {
  align-items: center;
  flex-wrap: wrap;
}

.admin-asset-preview {
  min-width: 0;
}

.admin-asset-preview > span:nth-child(2) {
  min-width: 0;
}

.admin-asset-preview .asset-preview-name,
.admin-asset-preview .asset-preview-price {
  overflow-wrap: anywhere;
}

.gradient-colors,
.admin-animations {
  border-radius: 6px;
}

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

  .admin-stat {
    border-bottom: 1px solid var(--line);
  }

  .admin-stat:nth-child(2n) {
    border-right: 0;
  }

  .admin-stat:nth-last-child(-n + 2) {
    border-bottom: 0;
  }

  .admin-grid,
  .admin-grid.single-panel {
    grid-template-columns: minmax(0, 1fr);
  }

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

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

@media (max-width: 560px) {
  .shop-preview.theme-preview {
    gap: 8px;
    padding: 10px;
  }

  .shop-preview.theme-preview header {
    font-size: 12px;
  }

  .shop-preview.theme-preview .theme-preview-main {
    min-height: 0;
  }

  .shop-preview.theme-preview .theme-preview-name,
  .shop-preview.theme-preview .theme-preview-quote {
    min-height: 96px;
    padding: 7px;
    font-size: 12px;
  }

  .shop-preview.theme-preview .theme-preview-name small,
  .shop-preview.theme-preview .theme-preview-quote small {
    font-size: 11px;
    line-height: 1.35;
  }

  .shop-preview.theme-preview .theme-preview-price {
    font-size: 13px;
  }

  .shop-preview.theme-preview footer {
    font-size: 11px;
  }

  .admin-panel > .panel-heading {
    min-height: 64px;
    padding-inline: 12px;
  }

  .admin-form,
  .admin-edit-form,
  .admin-user-form {
    grid-template-columns: minmax(0, 1fr);
  }

  .admin-form input,
  .admin-form select,
  .admin-edit-form input,
  .admin-edit-form select,
  .admin-user-form input,
  .admin-user-form select,
  .admin-asset-row input {
    min-height: 44px;
    font-size: 16px;
  }

  .admin-form .primary-button,
  .admin-edit-form .store-action,
  .admin-user-form .store-action,
  .admin-asset-row .store-action {
    min-height: 44px;
  }

  .admin-form {
    gap: 2px;
    padding-inline: 12px;
  }

  .admin-asset-row {
    grid-template-columns: minmax(0, 1fr) minmax(90px, .7fr);
    gap: 8px;
    padding: 10px 12px;
  }

  .admin-asset-row .store-action {
    grid-column: 1 / -1;
  }

  .admin-edit-form {
    margin-inline: 8px;
    padding: 10px;
  }

  .admin-asset-preview {
    flex-wrap: wrap;
  }

  .admin-asset-preview .asset-preview-price {
    margin-left: auto;
  }
}

@media (max-width: 360px) {
  .shop-preview.theme-preview header {
    font-size: 11px;
  }

  .shop-preview.theme-preview .theme-preview-main {
    grid-template-columns: minmax(0, 1fr);
  }

  .shop-preview.theme-preview .theme-preview-name,
  .shop-preview.theme-preview .theme-preview-quote {
    min-height: 76px;
  }

  .admin-stat {
    padding: 9px;
  }
}

/* One-page admin workspace and destructive-action cues */
.admin-intro {
  max-width: 760px;
  margin: -2px 0 12px;
  color: #9cabbc;
  font-size: 14px;
  line-height: 1.6;
}

.admin-panel[id] {
  scroll-margin-top: 18px;
}

#admin-style-editor,
#admin-store-catalog,
#admin-user-management {
  grid-column: 1 / -1;
}

.admin-asset-actions,
.admin-user-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.admin-asset-actions button,
.admin-user-actions button {
  flex: 1 1 160px;
  min-height: 42px;
}

.admin-danger {
  border-color: #713b46 !important;
  color: #f08b9a !important;
}

.admin-danger:hover,
.admin-danger:focus-visible {
  border-color: #e45f75 !important;
  background: rgba(228, 95, 117, .11) !important;
  color: #ffabb6 !important;
}

.admin-warning {
  border-color: #786032 !important;
  color: #e8c477 !important;
}

.admin-warning:hover,
.admin-warning:focus-visible {
  border-color: #d3a84e !important;
  background: rgba(211, 168, 78, .1) !important;
  color: #f5d58e !important;
}

.admin-user-card > header {
  align-items: center;
  flex-wrap: wrap;
}

.admin-user-status {
  margin-left: auto;
  padding: 4px 8px;
  border: 1px solid #275c49;
  border-radius: 999px;
  color: #7edbb4;
  font-size: 11px;
  text-transform: uppercase;
}

.admin-user-status.suspended {
  border-color: #713b46;
  color: #f08b9a;
}

.admin-user-status:not(.active):not(.suspended) {
  border-color: #394b63;
  color: #91a5bf;
}

.admin-user-actions {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}

.admin-footnote {
  margin: 2px 14px 10px;
  color: #8492a4;
  font-size: 12px;
  line-height: 1.55;
}

@media (max-width: 760px) {
  #admin-style-editor,
  #admin-store-catalog,
  #admin-user-management {
    grid-column: auto;
  }
}

@media (max-width: 560px) {
  .admin-asset-actions,
  .admin-user-actions {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
  }

  .admin-asset-actions button,
  .admin-user-actions button {
    width: 100%;
  }
}