:root {
  color-scheme: dark;
  --bg: #06111a;
  --bg2: #081b2a;
  --panel: rgba(12, 27, 40, 0.86);
  --panel2: rgba(15, 35, 52, 0.9);
  --line: rgba(104, 139, 170, 0.28);
  --line2: rgba(57, 143, 255, 0.45);
  --text: #f3f8ff;
  --muted: #9aaabd;
  --blue: #2f8cff;
  --blue2: #0d4a94;
  --green: #3bd978;
  --red: #ff5b64;
  --gold: #b97820;
  --purple: #7b34c7;
  --shadow: 0 16px 48px rgba(0, 0, 0, 0.38);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 50% 0%, rgba(52, 137, 255, 0.16), transparent 28%),
    radial-gradient(circle at 0% 28%, rgba(30, 125, 186, 0.13), transparent 34%),
    linear-gradient(180deg, #03070d 0%, #061321 40%, #07111a 100%);
  color: var(--text);
  font-family: "Microsoft YaHei", "Segoe UI", Arial, sans-serif;
}

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

.web-notification-toast {
  position: fixed;
  top: 76px;
  right: 20px;
  z-index: 140;
  width: min(390px, calc(100vw - 40px));
  padding: 12px 12px 17px;
  overflow: hidden;
  pointer-events: none;
  opacity: 0;
  transform: translate3d(28px, -12px, 0);
  border: 1px solid rgba(47, 140, 255, 0.65);
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(11, 33, 55, 0.98), rgba(4, 15, 27, 0.98));
  box-shadow: 0 18px 54px rgba(0, 0, 0, 0.48), 0 0 24px rgba(47, 140, 255, 0.16);
  transition: opacity 180ms ease, transform 180ms ease;
}

.web-notification-toast.show {
  pointer-events: auto;
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

.web-notification-head {
  display: grid;
  grid-template-columns: 1fr 24px;
  align-items: center;
  padding: 0 2px 9px;
  border-bottom: 1px solid rgba(104, 139, 170, 0.22);
}

.web-notification-head strong {
  display: block;
  color: #eaf4ff;
  font-size: 14px;
}

.web-notification-list {
  max-height: 340px;
  overflow: auto;
  padding: 3px 2px 0;
}

.web-notification-item {
  padding: 10px 4px;
  border-bottom: 1px solid rgba(104, 139, 170, 0.16);
}

.web-notification-item:last-child {
  border-bottom: 0;
}

.web-notification-item strong {
  display: block;
  color: #eaf4ff;
  font-size: 13px;
}

.web-notification-item p {
  margin: 5px 0;
  color: #aebfd2;
  font-size: 12px;
  line-height: 1.5;
}

.web-notification-item small {
  color: #70869c;
  font-size: 11px;
}

.web-notification-item.warning strong { color: #ffc45c; }
.web-notification-item.danger strong { color: #ff7c83; }
.web-notification-item.success strong { color: #66e89a; }

.web-notification-empty {
  padding: 24px 4px;
  color: #8195a9;
  text-align: center;
  font-size: 12px;
}

.web-notification-close {
  width: 24px;
  height: 24px;
  padding: 0;
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: #a7b8ca;
  font-size: 20px;
  line-height: 1;
}

.web-notification-close:hover {
  background: rgba(255, 255, 255, 0.09);
  color: #fff;
}

.web-notification-progress {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 2px;
  background: #2f8cff;
  transform: scaleX(0);
  transform-origin: left;
}

.web-notification-toast.show .web-notification-progress {
  animation: web-notification-countdown 60s linear forwards;
}

@keyframes web-notification-countdown {
  from { transform: scaleX(1); }
  to { transform: scaleX(0); }
}

@media (max-width: 900px) {
  .web-notification-toast {
    display: none;
  }
}

.login-screen {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 20px;
  background:
    radial-gradient(circle at 50% 10%, rgba(47, 140, 255, 0.2), transparent 32%),
    rgba(2, 7, 13, 0.96);
  backdrop-filter: blur(20px);
}

.login-screen.hidden {
  display: none;
}

.login-card {
  width: min(420px, 100%);
  border: 1px solid rgba(84, 151, 220, 0.32);
  border-radius: 10px;
  padding: 28px;
  background: linear-gradient(145deg, rgba(14, 33, 50, 0.96), rgba(5, 15, 26, 0.96));
  box-shadow: 0 30px 100px rgba(0, 0, 0, 0.55);
}

.login-logo {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 24px;
}

.login-logo strong {
  display: block;
  font-size: 25px;
}

.login-card label span {
  display: block;
  color: var(--muted);
  font-size: 13px;
}

.login-card label {
  display: grid;
  gap: 8px;
  margin-top: 14px;
}

.login-card input {
  width: 100%;
  height: 44px;
}

.login-button {
  width: 100%;
  height: 44px;
  margin-top: 18px;
}

#loginError {
  min-height: 20px;
  margin: 10px 0 0;
  color: var(--red);
}

.mobile-shell {
  display: none;
}

.mobile-nav {
  display: none;
}

.mobile-menu-panel {
  display: none;
}

.mobile-userbar {
  display: none;
}

.app-shell {
  display: grid;
  grid-template-columns: 232px minmax(0, 1fr) 260px;
  grid-template-rows: 66px minmax(0, 1fr);
  min-height: 100vh;
}

.desktop-topbar {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: 250px 1fr 310px;
  align-items: center;
  border-bottom: 1px solid rgba(60, 118, 164, 0.26);
  background: rgba(3, 8, 15, 0.82);
  backdrop-filter: blur(18px);
}

.desktop-brand,
.mobile-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-left: 28px;
}

.desktop-brand strong,
.mobile-brand strong {
  font-size: 22px;
  letter-spacing: 0;
}

.logo-mark {
  position: relative;
  display: inline-block;
  width: 34px;
  height: 34px;
  clip-path: polygon(50% 0, 94% 25%, 94% 75%, 50% 100%, 6% 75%, 6% 25%);
  background: linear-gradient(145deg, #55a7ff, #1265de);
  box-shadow: 0 0 28px rgba(47, 140, 255, 0.55);
}

.logo-mark::after {
  content: "";
  position: absolute;
  inset: 9px;
  border: 4px solid rgba(2, 10, 20, 0.82);
  border-top: 0;
}

.main-nav {
  display: flex;
  height: 100%;
}

.main-nav button {
  min-width: 102px;
  border: 0;
  border-left: 1px solid transparent;
  border-right: 1px solid transparent;
  background: transparent;
  color: #c9d5e4;
}

.main-nav button.active {
  color: #55a7ff;
  border-color: rgba(56, 132, 255, 0.38);
  background: linear-gradient(180deg, rgba(31, 113, 215, 0.18), rgba(13, 74, 148, 0.13));
  box-shadow: inset 0 -2px 0 var(--blue);
}

.operator-area {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 14px;
  padding-right: 22px;
  color: #cfd9e7;
}

.logout-button {
  height: 28px;
  border: 1px solid rgba(85, 167, 255, 0.35);
  border-radius: 6px;
  background: rgba(47, 140, 255, 0.12);
  color: #b9d9ff;
}

.operator-area small {
  color: var(--muted);
  font-size: 11px;
}

.notification-bell {
  position: relative;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  background: transparent;
}

.topbar-refresh {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  height: 34px;
  padding: 0 12px;
  border: 1px solid rgba(210, 164, 81, 0.48);
  border-radius: 7px;
  background: rgba(210, 164, 81, 0.08);
  color: #e9cb8e;
  font-size: 12px;
  white-space: nowrap;
}

.topbar-refresh:hover {
  border-color: rgba(235, 196, 117, 0.78);
  background: rgba(210, 164, 81, 0.16);
  color: #fff0ce;
}

.notification-bell:hover .bell {
  border-color: #fff;
  box-shadow: 0 0 14px rgba(85, 167, 255, 0.45);
}

.bell {
  position: relative;
  display: block;
  width: 18px;
  height: 18px;
  margin: 8px auto;
  border: 2px solid #d9e5f5;
  border-radius: 9px 9px 4px 4px;
}

.notification-bell-count {
  position: absolute;
  top: 0;
  right: 0;
  display: grid;
  place-items: center;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  border-radius: 50%;
  background: #ff3046;
  color: #fff;
  font-size: 10px;
}

.avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: linear-gradient(135deg, #d8e7ff, #52657d);
  border: 2px solid rgba(255, 255, 255, 0.28);
}

.sidebar,
.rightbar,
.workspace {
  min-width: 0;
}

.sidebar {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 16px 12px;
  border-right: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(4, 18, 31, 0.86), rgba(4, 15, 25, 0.84));
}

.side-panel,
.server-panel,
.ops-panel,
.risk-panel,
.account-board,
.command-log-panel,
.metric-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(145deg, rgba(15, 35, 52, 0.9), rgba(7, 19, 31, 0.9));
  box-shadow: var(--shadow);
}

.side-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 14px 10px;
  color: #dbe8f8;
}

.side-title button {
  border: 0;
  background: transparent;
  color: #cfe0f2;
  font-size: 22px;
}

.studio-list {
  display: grid;
  gap: 8px;
  padding: 0 10px 10px;
}

.studio-item {
  border: 1px solid rgba(47, 140, 255, 0.2);
  border-radius: 7px;
  padding: 10px 12px;
  background: rgba(47, 140, 255, 0.07);
  color: #dfeaff;
  text-align: left;
}

.studio-item.active {
  border-color: var(--blue);
  background: linear-gradient(90deg, rgba(28, 111, 220, 0.45), rgba(17, 51, 86, 0.28));
}

.studio-item strong,
.studio-item span {
  display: block;
}

.studio-item span,
.server-panel span,
.group-menu b {
  color: #90a5b9;
  font-size: 12px;
}

.group-menu {
  display: grid;
  padding: 2px 0 14px;
}

.group-menu button {
  display: flex;
  justify-content: space-between;
  height: 42px;
  border: 0;
  border-left: 3px solid transparent;
  background: transparent;
  color: #c8d4e2;
  padding: 0 16px;
}

.group-menu button.active {
  color: #76b7ff;
  border-left-color: var(--blue);
  background: rgba(47, 140, 255, 0.16);
}

.server-panel {
  padding: 14px;
}

.server-panel strong {
  display: block;
  margin-bottom: 12px;
}

.server-panel p {
  display: flex;
  justify-content: space-between;
  margin: 8px 0;
  padding: 9px 10px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.04);
}

.server-panel b {
  color: var(--green);
}

.workspace {
  padding: 16px;
  overflow: auto;
}

.mobile-metrics-title {
  display: flex;
  gap: 10px;
  margin-bottom: 14px;
}

input,
select {
  height: 36px;
  border: 1px solid rgba(91, 132, 168, 0.32);
  border-radius: 6px;
  background: rgba(4, 14, 24, 0.82);
  color: var(--text);
  padding: 0 12px;
  outline: 0;
}

select option {
  background: #071827;
}

.button {
  height: 38px;
  border: 1px solid rgba(85, 167, 255, 0.45);
  border-radius: 7px;
  padding: 0 14px;
  color: #eaf4ff;
  background: linear-gradient(180deg, rgba(24, 102, 208, 0.76), rgba(9, 54, 112, 0.76));
  white-space: nowrap;
}

.button.ghost {
  background: rgba(255, 255, 255, 0.06);
}

.button.primary {
  border-color: rgba(55, 217, 120, 0.38);
  background: linear-gradient(180deg, rgba(22, 124, 78, 0.82), rgba(10, 66, 46, 0.82));
}

.button.danger {
  color: #59aaff;
  background: rgba(16, 57, 104, 0.28);
}

.button.small {
  height: 29px;
  padding: 0 12px;
  font-size: 12px;
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 12px;
  margin-bottom: 14px;
}

.metric-card {
  position: relative;
  min-height: 124px;
  padding: 20px 18px 12px 68px;
  overflow: hidden;
}

.metric-card::before {
  position: absolute;
  top: 27px;
  left: 24px;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: var(--blue);
  font-size: 25px;
  font-weight: 700;
}

.icon-users::before {
  content: "♟";
  color: var(--blue);
}

.icon-wallet::before {
  content: "▣";
  color: #47d498;
}

.icon-chart::before {
  content: "⌁";
  border: 1px solid var(--blue);
}

.icon-profit::before {
  content: "$";
  border: 3px solid rgba(59, 217, 120, 0.56);
  border-radius: 50%;
  color: var(--green);
}

.icon-price::before {
  content: "Au";
  border: 1px solid rgba(255, 191, 83, 0.62);
  color: #ffd17b;
  background: linear-gradient(145deg, rgba(185, 120, 32, 0.3), rgba(47, 140, 255, 0.12));
}

.metric-card span {
  color: #c8d4e1;
  font-size: 14px;
}

.metric-card strong {
  display: block;
  margin-top: 12px;
  font-size: 28px;
  line-height: 1;
}

.metric-card small {
  display: block;
  margin-top: 8px;
  color: #a9b5c5;
}

.price-card {
  border-color: rgba(255, 191, 83, 0.28);
  background:
    radial-gradient(circle at 82% 12%, rgba(255, 191, 83, 0.14), transparent 34%),
    linear-gradient(145deg, rgba(18, 42, 58, 0.92), rgba(7, 19, 31, 0.92));
}

.price-card strong {
  color: #ffd17b;
  text-shadow: 0 0 22px rgba(255, 191, 83, 0.28);
}

.price-card small {
  display: flex;
  gap: 8px;
  align-items: center;
}

.price-card small b {
  color: #dceeff;
}

.price-card em {
  margin-left: auto;
  font-style: normal;
  font-size: 12px;
}

.price-extra {
  position: absolute;
  right: 16px;
  bottom: 14px;
  left: 16px;
  display: flex;
  justify-content: space-between;
  color: #98abc0;
  font-size: 12px;
}

.price-extra b {
  color: #e8f4ff;
}

.price-card small[hidden],
.price-extra[hidden] {
  display: none !important;
}

.sparkline {
  position: absolute;
  right: 16px;
  bottom: 12px;
  left: 16px;
  width: calc(100% - 32px);
  height: 34px;
  opacity: 0.92;
}

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

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

.mobile-group-tabs {
  display: none;
}

.desk-tools {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border: 1px solid var(--line);
  border-bottom: 0;
  border-radius: 8px 8px 0 0;
  padding: 12px 14px;
  background: rgba(9, 25, 39, 0.84);
}

h2 {
  margin: 0;
  font-size: 16px;
}

.tool-right {
  display: flex;
  gap: 8px;
  align-items: center;
}

.search-box {
  position: relative;
}

.search-box input {
  width: 260px;
  padding-right: 34px;
}

.search-box span {
  position: absolute;
  right: 10px;
  top: 7px;
  color: #b6c6d8;
}

.view-toggle {
  width: 34px;
  height: 34px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.04);
  color: #a9bdd3;
}

.view-toggle.active {
  color: var(--blue);
  background: rgba(47, 140, 255, 0.18);
}

.account-board {
  border-radius: 0 0 8px 8px;
  overflow: hidden;
}

.table-wrap {
  overflow-x: auto;
}

table {
  width: 100%;
  min-width: 980px;
  border-collapse: collapse;
}

th,
td {
  padding: 11px 14px;
  border-bottom: 1px solid rgba(95, 128, 158, 0.18);
  text-align: left;
}

th {
  color: #9fb0c3;
  font-size: 12px;
  font-weight: 500;
  background: rgba(35, 60, 83, 0.42);
}

td {
  color: #dce7f4;
  font-size: 13px;
}

td strong {
  display: inline-block;
  margin-left: 10px;
  font-size: 15px;
  font-weight: 600;
}

td small {
  display: block;
  margin-left: 58px;
  color: #8292a5;
  font-size: 11px;
}

.platform-tag {
  display: inline-grid;
  place-items: center;
  min-width: 38px;
  height: 26px;
  border: 1px solid rgba(72, 213, 123, 0.62);
  border-radius: 6px;
  color: #76de92;
  background: rgba(33, 165, 89, 0.12);
  font-weight: 700;
}

.platform-tag.mt5 {
  border-color: rgba(47, 140, 255, 0.7);
  color: #7eb7ff;
  background: rgba(47, 140, 255, 0.12);
}

.status-dot {
  display: inline-block;
  width: 9px;
  height: 9px;
  margin-right: 8px;
  border-radius: 50%;
  background: #637180;
}

.status-dot.online {
  background: var(--green);
  box-shadow: 0 0 14px rgba(59, 217, 120, 0.58);
}

.status-dot.offline {
  background: var(--red);
}

.account-cards {
  display: none;
}

.command-log-panel,
.admin-panel {
  margin-top: 12px;
  overflow: hidden;
}

.admin-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(145deg, rgba(15, 35, 52, 0.9), rgba(7, 19, 31, 0.9));
  box-shadow: var(--shadow);
}

.panel-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
}

.panel-head a {
  color: #4da2ff;
  text-decoration: none;
  font-size: 13px;
}

.panel-head span {
  color: #78baff;
  font-size: 13px;
}

.admin-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  padding: 14px 16px;
}

.admin-stats article,
.admin-form,
.admin-row {
  border: 1px solid rgba(92, 132, 168, 0.22);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.admin-stats article {
  padding: 12px;
}

.admin-stats span,
.admin-row span {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

.admin-stats strong {
  display: block;
  margin-top: 8px;
  font-size: 24px;
}

.admin-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 12px;
  padding: 0 16px 14px;
}

.admin-form {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.admin-form h3 {
  margin: 0 0 4px;
  font-size: 15px;
}

.form-hint {
  margin: 0;
  color: #91a5b9;
  font-size: 12px;
  line-height: 1.55;
}

.admin-form input,
.admin-form select {
  width: 100%;
}

.admin-form label {
  display: grid;
  gap: 6px;
}

.admin-form label span {
  color: var(--muted);
  font-size: 12px;
}

.alert-settings-form {
  margin: 16px;
  grid-template-columns: repeat(4, minmax(150px, 1fr)) auto;
  align-items: end;
}

.alert-settings-form h3 {
  grid-column: 1 / -1;
}

.form-status {
  grid-column: 1 / -1;
  min-height: 18px;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.form-status.pending {
  color: #ffd166;
}

.form-status.success {
  color: #41e38a;
}

.form-status.failed {
  color: #ff727a;
}

.admin-list {
  display: grid;
  gap: 8px;
  padding: 0 16px 16px;
}

.admin-row {
  display: grid;
  grid-template-columns: minmax(180px, 1.2fr) minmax(140px, 0.7fr) minmax(210px, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 12px;
}

.admin-row.compact {
  grid-template-columns: 1.2fr 0.8fr 1fr;
}

.studio-agent-select {
  display: block;
  width: 100%;
  max-width: 300px;
  margin-top: 5px;
}

.studio-agent-current {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 11px;
}

.admin-section-title {
  margin-top: 10px;
  padding: 10px 2px 2px;
  color: #78baff;
  font-weight: 700;
}

.push-record-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.push-record-head .button {
  min-height: 34px;
  padding: 7px 12px;
}

.row-actions,
.manage-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.manage-actions {
  justify-content: stretch;
}

.manage-actions .button {
  flex: 1;
}

.admin-row code {
  display: block;
  max-width: 100%;
  overflow: hidden;
  color: #76b7ff;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.command-log {
  display: grid;
}

.log-item {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 12px;
  padding: 10px 16px;
  border-bottom: 1px solid rgba(95, 128, 158, 0.18);
}

.log-item strong {
  display: block;
  color: #dbe7f6;
}

.log-item span,
.log-item b {
  display: block;
  margin-top: 5px;
  color: #9badc1;
  font-size: 12px;
  font-weight: 500;
}

.empty {
  padding: 28px;
  color: #8fa0b3;
  text-align: center;
}

.rightbar {
  display: grid;
  align-content: start;
  gap: 14px;
  padding: 16px 12px 16px 0;
}

.ops-panel,
.risk-panel {
  padding: 14px;
}

.ops-panel h2,
.risk-panel h2 {
  margin-bottom: 14px;
}

.action-card {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 66px;
  margin-top: 12px;
  border-radius: 7px;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.16);
}

.action-card span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  margin-left: 14px;
  font-size: 24px;
}

.action-card.blue {
  background: linear-gradient(135deg, #1a72d7, #0d4088);
}

.action-card.gold {
  background: linear-gradient(135deg, #a66a22, #6f4210);
}

.action-card.purple {
  background: linear-gradient(135deg, #7b35ce, #3d196d);
}

.gauge {
  position: relative;
  display: grid;
  place-items: center;
  height: 170px;
}

.gauge-ring {
  position: absolute;
  width: 140px;
  height: 140px;
  border-radius: 50%;
  background:
    conic-gradient(from 235deg, #74e48d 0 36%, #4c98ff 36% 68%, rgba(77, 100, 125, 0.28) 68% 100%);
  mask: radial-gradient(circle, transparent 54%, #000 56%);
}

.gauge strong {
  margin-top: 28px;
  font-size: 38px;
}

.gauge span {
  margin-top: -24px;
  color: #80e99a;
}

.risk-list {
  display: grid;
  gap: 6px;
}

.risk-list p {
  display: flex;
  justify-content: space-between;
  margin: 0;
  padding: 11px 4px;
  border-bottom: 1px solid rgba(95, 128, 158, 0.16);
  color: #9fb0c4;
  font-size: 13px;
}

.risk-list b {
  color: #87e799;
}

.mobile-action-bar {
  display: none;
}

.sub-head {
  border-top: 1px solid var(--line);
}

.login-record-list {
  padding: 16px;
}

#pageSubTitle {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.page-section {
  display: none;
}

.page-section.active {
  display: block;
}

.panel-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: linear-gradient(145deg, rgba(15, 35, 52, 0.9), rgba(7, 19, 31, 0.9));
  box-shadow: var(--shadow);
  overflow: hidden;
}

.quick-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(95, 128, 158, 0.18);
}

.gold-button {
  border-color: rgba(255, 184, 75, 0.45);
  background: linear-gradient(180deg, rgba(173, 105, 28, 0.82), rgba(94, 57, 14, 0.82));
}

.purple-button {
  border-color: rgba(164, 103, 255, 0.45);
  background: linear-gradient(180deg, rgba(121, 54, 199, 0.82), rgba(66, 26, 111, 0.82));
}

.manage-grid,
.risk-cards,
.report-cards,
.ea-access-list {
  display: grid;
  gap: 12px;
  padding: 16px;
}

.manage-grid {
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
}

.manage-card,
.risk-card,
.report-card,
.ea-access-card {
  border: 1px solid rgba(92, 132, 168, 0.24);
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.035);
}

.manage-card {
  display: grid;
  gap: 10px;
  padding: 14px;
}

.manage-card > div {
  display: flex;
  align-items: center;
  gap: 10px;
}

.manage-card strong {
  display: block;
  font-size: 18px;
}

.manage-card small,
.ea-access-card small {
  color: var(--muted);
}

.manage-card p,
.report-card p {
  display: flex;
  justify-content: space-between;
  margin: 0;
  color: #a9b9ca;
}

.manage-card b,
.report-card b {
  color: #edf6ff;
}

.command-badge,
.status-pill {
  display: inline-grid;
  place-items: center;
  min-width: 68px;
  height: 26px;
  border-radius: 6px;
  font-size: 12px;
}

.command-badge {
  border: 1px solid rgba(47, 140, 255, 0.5);
  color: #7eb7ff;
  background: rgba(47, 140, 255, 0.14);
}

.status-pill.pending {
  color: #ffd076;
  background: rgba(255, 184, 75, 0.13);
}

.status-pill.success {
  color: #66e895;
  background: rgba(59, 217, 120, 0.13);
}

.status-pill.failed {
  color: #ff727a;
  background: rgba(255, 91, 100, 0.13);
}

.status-pill.expired {
  color: #aab4c3;
  background: rgba(170, 180, 195, 0.12);
}

.risk-cards,
.report-cards {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.risk-card,
.report-card {
  padding: 16px;
}

.risk-card h3,
.report-card h3,
.ea-access-card h3 {
  margin: 0 0 12px;
  font-size: 16px;
}

.risk-card strong {
  display: block;
  font-size: 34px;
}

.risk-card span {
  display: block;
  margin: 4px 0 12px;
  color: var(--muted);
  font-size: 13px;
}

.risk-card div {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.risk-card em {
  border: 1px solid rgba(85, 167, 255, 0.25);
  border-radius: 999px;
  padding: 4px 8px;
  color: #9ccaff;
  background: rgba(47, 140, 255, 0.08);
  font-style: normal;
  font-size: 12px;
}

.ea-access-card {
  display: grid;
  gap: 14px;
  padding: 16px;
}

.push-form {
  display: grid;
  grid-template-columns: repeat(3, minmax(160px, 1fr));
  gap: 12px;
  padding: 16px;
  border-bottom: 1px solid rgba(95, 128, 158, 0.18);
}

.push-form label {
  display: grid;
  gap: 7px;
}

.push-form label span {
  color: var(--muted);
  font-size: 12px;
}

.push-form textarea {
  min-height: 88px;
  border: 1px solid rgba(91, 132, 168, 0.32);
  border-radius: 6px;
  background: rgba(4, 14, 24, 0.82);
  color: var(--text);
  padding: 10px 12px;
  outline: 0;
  resize: vertical;
}

.push-title-field,
.push-body-field {
  grid-column: span 3;
}

.push-form .button {
  width: max-content;
}

.push-overview {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  padding: 0 16px 14px;
}

.push-overview article {
  border: 1px solid rgba(92, 132, 168, 0.22);
  border-radius: 8px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.035);
}

.push-overview span,
.push-item span {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

.push-overview strong {
  display: block;
  margin-top: 8px;
  font-size: 24px;
}

.push-columns {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 14px;
  padding: 0 16px 16px;
}

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

.push-item {
  display: grid;
  grid-template-columns: 1fr 0.85fr;
  gap: 12px;
  align-items: center;
  border: 1px solid rgba(92, 132, 168, 0.22);
  border-radius: 8px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.035);
}

.push-item strong,
.push-item b {
  display: block;
  color: #edf6ff;
}

.push-item.message strong {
  color: #ffd17b;
}

.push-error {
  display: block;
  margin-top: 6px;
  color: #ff727a;
  font-size: 12px;
  font-style: normal;
  word-break: break-word;
}

.news-layout {
  display: grid;
  grid-template-columns: minmax(320px, 0.82fr) minmax(420px, 1.18fr);
  gap: 16px;
  padding: 16px;
}

.news-form,
.news-records {
  min-width: 0;
  border: 1px solid rgba(92, 132, 168, 0.22);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.025);
  padding: 16px;
}

.news-form {
  display: grid;
  gap: 13px;
  align-content: start;
}

.news-form label {
  display: grid;
  gap: 7px;
}

.news-form label span {
  color: var(--muted);
  font-size: 12px;
}

.news-form textarea {
  min-height: 154px;
  border: 1px solid rgba(91, 132, 168, 0.32);
  border-radius: 7px;
  background: rgba(4, 14, 24, 0.82);
  color: var(--text);
  padding: 11px 12px;
  outline: 0;
  resize: vertical;
}

.news-form-footer {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
}

.news-form-footer small {
  color: var(--muted);
  line-height: 1.55;
}

.news-record-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.news-record-head b {
  color: #71c9ff;
  font-size: 12px;
}

.news-list {
  display: grid;
  gap: 9px;
  max-height: 650px;
  overflow: auto;
  padding-right: 3px;
}

.news-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  border: 1px solid rgba(92, 132, 168, 0.22);
  border-radius: 9px;
  padding: 13px;
  background: linear-gradient(145deg, rgba(12, 31, 48, 0.82), rgba(7, 20, 33, 0.82));
}

.news-item-main {
  min-width: 0;
}

.news-item-title {
  display: flex;
  gap: 9px;
  align-items: center;
}

.news-item-title strong {
  overflow: hidden;
  color: #edf6ff;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.news-item p {
  margin: 8px 0;
  color: #b6c9da;
  font-size: 13px;
  line-height: 1.55;
  white-space: pre-wrap;
  word-break: break-word;
}

.news-item small {
  color: var(--muted);
}

.news-type {
  flex: 0 0 auto;
  border: 1px solid rgba(239, 191, 76, 0.34);
  border-radius: 999px;
  padding: 3px 7px;
  color: #ffd270;
  background: rgba(239, 191, 76, 0.1);
  font-size: 11px;
}

.news-type.market_news {
  border-color: rgba(75, 160, 255, 0.38);
  color: #82bdff;
  background: rgba(75, 160, 255, 0.1);
}

.news-type.breaking_news {
  border-color: rgba(255, 91, 105, 0.42);
  color: #ff9099;
  background: rgba(255, 91, 105, 0.1);
}

.ea-access-card code {
  color: #7eb7ff;
  word-break: break-all;
}

.ea-credential-list {
  display: grid;
  gap: 9px;
}

.copy-field {
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid rgba(92, 132, 168, 0.22);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.copy-field span { color: var(--muted); font-size: 12px; }

.copy-value-button {
  min-width: 56px;
  min-height: 32px;
  border: 1px solid rgba(74, 151, 230, 0.42);
  border-radius: 7px;
  background: rgba(35, 111, 188, 0.14);
  color: #a9d3ff;
  cursor: pointer;
}

.copy-value-button:hover { border-color: rgba(98, 174, 250, 0.72); background: rgba(35, 111, 188, 0.25); }
.copy-value-button:disabled { cursor: not-allowed; opacity: 0.45; }

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

.endpoint-list p {
  margin: 0;
  padding: 10px;
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.04);
}

.endpoint-list span {
  display: block;
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 12px;
}

body.card-view .table-wrap {
  display: none;
}

body.card-view .account-cards {
  display: grid;
  gap: 10px;
  padding: 12px;
}

@media (max-width: 1100px) {
  .app-shell {
    grid-template-columns: 210px minmax(0, 1fr);
  }

  .rightbar {
    display: none;
  }

  .desktop-topbar {
    grid-template-columns: 220px 1fr 220px;
  }

  .main-nav button {
    min-width: 88px;
  }
}

@media (max-width: 760px) {
  body {
    background:
      radial-gradient(circle at 50% 0%, rgba(47, 140, 255, 0.17), transparent 30%),
      linear-gradient(180deg, #03080e 0%, #061827 100%);
  }

  .desktop-topbar,
  .sidebar,
  .rightbar,
  .desk-tools {
    display: none;
  }

  .mobile-shell {
    display: block;
    position: sticky;
    top: 0;
    z-index: 30;
    border-bottom: 1px solid rgba(60, 118, 164, 0.24);
    background: rgba(2, 8, 14, 0.9);
    backdrop-filter: blur(18px);
  }

  .mobile-top {
    display: grid;
    grid-template-columns: 42px 1fr auto 42px;
    align-items: center;
    min-height: 64px;
    padding: 0 12px;
  }

  .mobile-menu-panel {
    display: block;
    position: absolute;
    top: 64px;
    left: 10px;
    width: min(260px, calc(100vw - 20px));
    padding: 10px;
    border: 1px solid rgba(60, 118, 164, 0.36);
    border-radius: 14px;
    background: linear-gradient(145deg, rgba(5, 17, 28, 0.98), rgba(8, 31, 50, 0.96));
    box-shadow: 0 22px 52px rgba(0, 0, 0, 0.42), 0 0 28px rgba(47, 140, 255, 0.12);
    opacity: 0;
    transform: translateY(-8px) scale(0.98);
    pointer-events: none;
    transition: opacity 0.18s ease, transform 0.18s ease;
  }

  .mobile-menu-panel.open {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
  }

  .mobile-nav {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
    padding: 0;
  }

  .mobile-nav button {
    min-height: 44px;
    border: 1px solid rgba(62, 121, 170, 0.35);
    border-radius: 10px;
    background: linear-gradient(145deg, rgba(11, 31, 48, 0.88), rgba(5, 18, 30, 0.92));
    color: #b9c7d8;
    text-align: left;
    padding: 0 14px;
    font-size: 15px;
    font-weight: 700;
  }

  .mobile-nav button.active {
    color: #fff;
    border-color: rgba(47, 140, 255, 0.85);
    background: linear-gradient(135deg, rgba(31, 113, 215, 0.72), rgba(9, 54, 106, 0.88));
    box-shadow: 0 0 18px rgba(47, 140, 255, 0.22), inset 0 0 0 1px rgba(116, 183, 255, 0.12);
  }

  .icon-button {
    border: 0;
    background: transparent;
    color: #fff;
    font-size: 30px;
  }

  .mobile-brand {
    justify-content: center;
    padding-left: 0;
  }

  .mobile-brand .logo-mark {
    width: 30px;
    height: 30px;
  }

  .mobile-state {
    display: flex;
    align-items: center;
    gap: 7px;
    color: #79e892;
    font-size: 14px;
  }

  .mobile-state span {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: #43da78;
  }

  .mobile-userbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 0 12px 10px;
    color: #b9c7d8;
    font-size: 13px;
  }

  .mobile-userbar span {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .mobile-userbar button {
    height: 30px;
    min-width: 58px;
    border: 1px solid rgba(47, 140, 255, 0.55);
    border-radius: 8px;
    background: rgba(10, 45, 88, 0.62);
    color: #78baff;
    font-weight: 700;
  }

  .app-shell {
    display: block;
    min-height: auto;
  }

  .workspace {
    padding: 12px;
    padding-bottom: 88px;
    overflow: visible;
  }

  .mobile-metrics-title {
    margin-top: 4px;
  }

  .mobile-metrics-title input {
    flex: 1;
    min-width: 0;
  }

  .metric-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    margin: 8px 0 10px;
    padding: 0;
    overflow: visible;
    scroll-snap-type: none;
  }

  .metric-card {
    min-width: 0;
    min-height: 88px;
    padding: 9px 8px 7px;
    scroll-snap-align: none;
    border-radius: 10px;
  }

  .metric-card::before {
    position: absolute;
    top: 10px;
    left: 10px;
    width: 22px;
    height: 22px;
    margin-bottom: 0;
    font-size: 14px;
    border-radius: 7px;
  }

  .metric-card span {
    display: block;
    margin: 1px 0 0 30px;
    overflow: hidden;
    color: #aeb9c7;
    font-size: 12px;
    line-height: 1.2;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .metric-card strong {
    display: block;
    margin-top: 12px;
    overflow: hidden;
    font-size: clamp(15px, 4.2vw, 18px);
    line-height: 1.1;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .metric-card small {
    display: block;
    margin-top: 3px;
    overflow: hidden;
    font-size: 10px;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .sparkline {
    height: 16px;
    margin-top: 4px;
  }

  .mobile-group-tabs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    margin: 12px 0;
    border: 1px solid rgba(75, 125, 163, 0.34);
    border-radius: 8px;
    overflow: hidden;
    background: rgba(10, 25, 38, 0.86);
  }

  .mobile-group-tabs button {
    height: 58px;
    border: 0;
    border-right: 1px solid rgba(75, 125, 163, 0.34);
    background: transparent;
    color: #d9e5f4;
    font-size: 17px;
  }

  .mobile-group-tabs button.active {
    color: #fff;
    border: 1px solid var(--blue);
    background: linear-gradient(100deg, rgba(23, 93, 174, 0.52), rgba(13, 48, 80, 0.68));
  }

  .mobile-group-tabs b {
    display: inline-grid;
    place-items: center;
    width: 30px;
    height: 30px;
    margin-left: 8px;
    border-radius: 50%;
    background: linear-gradient(135deg, #5ab0ff, #176bd4);
    font-size: 14px;
  }

  .account-board {
    border-radius: 8px;
    background: transparent;
    border: 0;
    box-shadow: none;
  }

  .account-board .table-wrap {
    display: none;
  }

  .page-section:not(#page-monitor) .table-wrap {
    display: block;
    overflow-x: auto;
  }

  .page-section:not(#page-monitor) table {
    min-width: 720px;
  }

  .account-cards {
    display: grid;
    gap: 8px;
  }

  .account-card {
    border: 1px solid rgba(111, 145, 172, 0.34);
    border-radius: 8px;
    background: linear-gradient(145deg, rgba(13, 33, 50, 0.92), rgba(6, 18, 28, 0.94));
    overflow: hidden;
  }

  .card-head {
    display: grid;
    grid-template-columns: 34px 66px 1fr 72px 124px;
    align-items: center;
    min-height: 86px;
    gap: 10px;
    padding: 14px;
    border-bottom: 1px solid rgba(90, 125, 154, 0.2);
  }

  .card-head input {
    width: 28px;
    height: 28px;
    accent-color: var(--blue);
  }

  .card-head strong {
    display: block;
    font-size: 23px;
  }

  .card-head small {
    color: #b5c1cf;
    font-size: 15px;
  }

  .card-head em {
    color: #dfe9f8;
    font-style: normal;
    font-size: 17px;
  }

  .card-head em::before {
    content: "";
    display: inline-block;
    width: 10px;
    height: 10px;
    margin-right: 8px;
    border-radius: 50%;
    background: currentColor;
  }

  .platform-tag {
    min-width: 58px;
    height: 42px;
    font-size: 20px;
  }

  .card-metrics {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
    padding: 18px 22px;
  }

  .card-metrics span {
    color: #aeb9c7;
    font-size: 15px;
  }

  .card-metrics strong {
    display: block;
    margin-top: 6px;
    color: var(--text);
    font-size: 18px;
  }

  .card-foot {
    display: none;
  }

  .button.small {
    height: 44px;
    color: #45a4ff;
    border-color: rgba(47, 140, 255, 0.68);
    background: rgba(13, 60, 123, 0.22);
    font-size: 17px;
  }

  .command-log-panel {
    margin-top: 12px;
  }

  .panel-head {
    padding: 10px 16px;
  }

  .command-log {
    max-height: 132px;
    overflow: auto;
  }

  .log-item {
    grid-template-columns: 1fr 1fr;
    padding: 8px 16px;
  }

  .mobile-action-bar {
    position: fixed;
    right: 12px;
    bottom: 12px;
    left: 12px;
    z-index: 22;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 8px;
  }

  .mobile-action-bar .button {
    height: 54px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 700;
  }

  .mobile-blue {
    background: linear-gradient(135deg, #1c78df, #0d4b96);
  }

  .mobile-gold {
    background: linear-gradient(135deg, #a86a24, #6e430f);
  }

  .mobile-purple {
    background: linear-gradient(135deg, #7a35cb, #451978);
  }

  .admin-stats,
  .admin-grid,
  .admin-row,
  .alert-settings-form,
  .risk-cards,
  .report-cards,
  .ea-access-card,
  .push-form,
  .push-overview,
  .push-columns,
  .push-item,
  .news-layout,
  .news-item {
    grid-template-columns: 1fr;
  }

  .admin-panel {
    margin-top: 12px;
  }

  .manage-grid,
  .risk-cards,
  .report-cards,
  .ea-access-list,
  .push-columns {
    padding: 12px;
  }

  .news-layout {
    padding: 12px;
  }

  .news-form-footer {
    align-items: stretch;
    flex-direction: column;
  }

  .push-title-field,
  .push-body-field {
    grid-column: auto;
  }

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

  .panel-card {
    margin-top: 12px;
  }
}

/* XAUUSD real 1-minute candle chart ------------------------------------ */
.xau-chart-panel {
  display: grid;
  grid-template-columns: minmax(220px, 285px) minmax(0, 1fr);
  min-height: 292px;
  margin: 0 0 13px;
  overflow: hidden;
  border: 1px solid rgba(210, 164, 81, 0.48);
  border-radius: 15px;
  background: radial-gradient(circle at 14% 20%, rgba(210, 164, 81, 0.1), transparent 30%), linear-gradient(110deg, rgba(11, 29, 43, 0.98), rgba(4, 16, 27, 0.98));
  box-shadow: inset 0 1px 0 rgba(255, 240, 205, 0.05), 0 16px 36px rgba(0, 0, 0, 0.22);
}
.xau-chart-quote { display: flex; flex-direction: column; justify-content: center; padding: 26px 25px; border-right: 1px solid rgba(131, 160, 188, 0.14); }
.xau-chart-title { display: flex; align-items: center; gap: 9px; color: #efc66e; font-size: 17px; font-weight: 700; letter-spacing: 0.04em; }
.xau-chart-title b { padding: 3px 7px; border-radius: 5px; background: rgba(210, 164, 81, 0.12); color: #c9a45c; font-size: 10px; }
.xau-chart-quote > strong { margin: 13px 0 7px; color: #f1c15c; font-size: clamp(35px, 3.4vw, 52px); line-height: 1; letter-spacing: -0.025em; text-shadow: 0 6px 24px rgba(210, 164, 81, 0.16); }
.xau-chart-change { display: flex; gap: 14px; margin-bottom: 20px; font-size: 15px; font-weight: 700; }
.xau-chart-change .positive { color: #ed5260; }
.xau-chart-change .negative { color: #35d281; }
.xau-chart-quote small { color: #778ca0; font-size: 11px; }
.xau-chart-quote small b { color: #9eb0c0; font-weight: 500; }
.xau-chart-quote > em { width: fit-content; margin-top: 12px; padding: 5px 9px; border-radius: 14px; font-size: 10px; font-style: normal; }
.xau-chart-quote > em.online { background: rgba(45, 207, 119, 0.1); color: #43da89; }
.xau-chart-quote > em.offline { background: rgba(237, 82, 96, 0.1); color: #ed6975; }
.xau-chart-stage { position: relative; min-width: 0; padding: 17px 14px 8px; }
#xauChartCanvas { display: block; width: 100%; height: 258px; }
.xau-chart-count { position: absolute; top: 12px; right: 18px; padding: 3px 7px; border-radius: 5px; background: rgba(4, 16, 27, 0.72); color: #75899d; font-size: 10px; }

@media (min-width: 901px) {
  .app-shell-v3 .metric-grid { grid-template-columns: repeat(5, minmax(150px, 1fr)); }
  .app-shell-v3 .metric-grid .price-card { display: none; }
}
@media (max-width: 900px) {
  .xau-chart-panel { display: none; }
  .position-direction-card { display: none !important; }
}

.position-direction-card { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 16px 14px; }
.position-total { min-width: 0; }
.position-total > span { display: block; color: #8fa3b7; font-size: 11px; }
.position-total > strong { display: block; margin-top: 7px; color: #eef6ff; font-size: 28px; line-height: 1; }
.position-total > small { display: block; margin-top: 6px; color: #55d994; font-size: 9px; white-space: nowrap; }
.position-total > small.has-unknown { color: #e6b65b; }
.position-side-grid { display: grid; gap: 7px; min-width: 78px; }
.position-side-grid span { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 6px 8px; border: 1px solid rgba(112, 145, 177, 0.18); border-radius: 6px; background: rgba(4, 17, 28, 0.48); font-size: 10px; }
.position-side-grid b { font-size: 16px; }
.position-buy { color: #ed6672; }
.position-sell { color: #3bd184; }
.table-position-directions { display: flex; align-items: center; gap: 7px; white-space: nowrap; }
.table-position-directions span { padding: 5px 7px; border: 1px solid rgba(117, 148, 178, 0.18); border-radius: 5px; background: rgba(5, 18, 29, 0.5); font-size: 10px; }
.table-position-directions span.buy { color: #ed6672; }
.table-position-directions span.sell { color: #3bd184; }
.table-position-directions b { margin-left: 4px; font-size: 13px; }
.table-position-directions small { margin: 0; color: #d3a856; font-size: 9px; }
.position-direction-unknown { display: inline-flex; padding: 5px 8px; border-radius: 5px; background: rgba(210, 164, 81, 0.1); color: #d3a856; font-size: 10px; white-space: nowrap; }

@media (max-width: 520px) {
  .card-head {
    grid-template-columns: 34px 58px 1fr 58px;
  }

  .card-head .button {
    grid-column: 1 / -1;
    width: 100%;
  }

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

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

/* V2 desktop control-room presentation */
.app-shell-v2 {
  grid-template-rows: 72px minmax(0, 1fr);
  background: radial-gradient(circle at 72% 0%, rgba(31, 117, 225, 0.12), transparent 26%), linear-gradient(135deg, rgba(4, 14, 25, 0.9), rgba(5, 20, 34, 0.72));
}

.app-shell-v2 .desktop-topbar {
  height: 72px;
  border-bottom-color: rgba(114, 158, 203, 0.2);
  background: rgba(3, 11, 20, 0.9);
  backdrop-filter: blur(20px);
}

.app-shell-v2 .desktop-brand strong { letter-spacing: 0.04em; }
.app-shell-v2 .main-nav { gap: 3px; }
.app-shell-v2 .main-nav button { min-height: 38px; padding: 0 12px; border-radius: 8px; }
.app-shell-v2 .main-nav button.active { background: linear-gradient(135deg, rgba(20, 97, 177, 0.62), rgba(15, 56, 102, 0.66)); box-shadow: inset 0 -2px 0 #2f8cff, 0 8px 20px rgba(8, 70, 139, 0.2); }

.workspace-context { display: flex; align-items: center; justify-content: space-between; min-height: 54px; margin: 0 0 12px; padding: 0 2px; }
.workspace-context > div { display: grid; gap: 5px; }
.workspace-context strong { color: #e8f2fe; font-size: 15px; font-weight: 650; }
.eyebrow { color: #5d9fe9; font-size: 10px; font-weight: 700; letter-spacing: 0.14em; }
.workspace-health { display: flex !important; grid-auto-flow: column; align-items: center; gap: 13px; color: #a9b9cc; font-size: 12px; }
.workspace-health > span { display: inline-flex; align-items: center; gap: 7px; color: #79e4a0; }
.workspace-health small { color: #71859b; }
.workspace-health b { color: #b8cce1; font-weight: 500; }
.pulse-dot { width: 7px; height: 7px; border-radius: 50%; background: #32db78; box-shadow: 0 0 0 0 rgba(50, 219, 120, 0.56); animation: v2-pulse 2s infinite; }
@keyframes v2-pulse { 70% { box-shadow: 0 0 0 7px rgba(50, 219, 120, 0); } 100% { box-shadow: 0 0 0 0 rgba(50, 219, 120, 0); } }

.app-shell-v2 .metric-grid { gap: 12px; margin-bottom: 13px; }
.app-shell-v2 .metric-card { min-height: 128px; overflow: hidden; border-radius: 13px; border-color: rgba(111, 147, 184, 0.26); background: linear-gradient(145deg, rgba(13, 33, 51, 0.94), rgba(8, 22, 35, 0.94)); box-shadow: inset 0 1px 0 rgba(209, 234, 255, 0.04), 0 12px 30px rgba(0, 0, 0, 0.18); }
.app-shell-v2 .metric-card strong { letter-spacing: -0.025em; }

.command-hero { position: relative; display: flex; min-height: 150px; align-items: center; justify-content: space-between; gap: 28px; margin: 0 0 13px; padding: 24px 26px; overflow: hidden; border: 1px solid rgba(47, 140, 255, 0.34); border-radius: 15px; background: linear-gradient(90deg, rgba(9, 35, 62, 0.96) 0%, rgba(6, 23, 40, 0.93) 52%, rgba(9, 34, 55, 0.84) 100%); box-shadow: inset 0 1px 0 rgba(219, 238, 255, 0.06), 0 16px 38px rgba(0, 0, 0, 0.2); }
.command-hero::before, .command-hero::after { position: absolute; content: ""; pointer-events: none; }
.command-hero::before { top: -120px; right: 8%; width: 340px; height: 340px; border: 1px solid rgba(47, 140, 255, 0.24); border-radius: 50%; box-shadow: 0 0 0 34px rgba(47, 140, 255, 0.035), 0 0 0 68px rgba(47, 140, 255, 0.02); }
.command-hero::after { right: 0; bottom: 0; width: 42%; height: 1px; background: linear-gradient(90deg, transparent, #2f8cff, #b97820); }
.command-hero-copy, .command-hero-stats { position: relative; z-index: 1; }
.command-hero-copy { max-width: 590px; }
.command-hero h1 { margin: 7px 0; color: #f2f8ff; font-size: clamp(22px, 2vw, 30px); letter-spacing: 0.02em; }
.command-hero p { margin: 0; color: #9bb2ca; font-size: 13px; }
.command-hero-stats { display: grid; grid-template-columns: repeat(2, minmax(94px, 1fr)) auto; align-items: stretch; min-width: 360px; border: 1px solid rgba(128, 164, 197, 0.2); border-radius: 11px; background: rgba(2, 13, 25, 0.36); }
.command-hero-stats article { display: grid; align-content: center; gap: 7px; min-height: 84px; padding: 14px 17px; border-right: 1px solid rgba(128, 164, 197, 0.18); }
.command-hero-stats article span { color: #879db5; font-size: 11px; }
.command-hero-stats article strong { color: #f0c26b; font-size: 19px; }
.command-hero-stats article:first-child strong { color: #63e491; }
.hero-link { min-width: 105px; border: 0; border-radius: 0 10px 10px 0; background: linear-gradient(180deg, rgba(21, 89, 162, 0.9), rgba(9, 47, 91, 0.9)); color: #d9ecff; font-size: 12px; font-weight: 700; }
.hero-link b { display: block; margin-top: 5px; color: #5db1ff; font-size: 18px; }
.hero-link:hover { background: linear-gradient(180deg, #2078cf, #0a4e99); }

.app-shell-v2 .account-board, .app-shell-v2 .command-log-panel, .app-shell-v2 .panel-card, .app-shell-v2 .admin-panel { border-radius: 14px; border-color: rgba(110, 145, 178, 0.25); box-shadow: inset 0 1px 0 rgba(222, 241, 255, 0.035), 0 14px 34px rgba(0, 0, 0, 0.16); }
.app-shell-v2 .table-wrap table thead { background: rgba(34, 72, 105, 0.26); }
.app-shell-v2 .table-wrap tbody tr:hover { background: rgba(46, 129, 220, 0.08); }
.table-actions { display: flex; align-items: center; justify-content: flex-end; gap: 6px; }
.account-close-button { min-width: 72px; min-height: 40px; padding: 9px 18px; font-size: 14px; font-weight: 700; }
.account-runtime-status { display: grid; gap: 5px; justify-items: start; }
.account-runtime-status > span { display: inline-flex; gap: 6px; align-items: center; }
.ea-control-state { display: inline-flex; align-items: center; border: 1px solid rgba(109, 143, 176, 0.28); border-radius: 999px; padding: 2px 7px; color: #9eafbf; background: rgba(109, 143, 176, 0.09); font-size: 10px; white-space: nowrap; }
.ea-control-state.running { border-color: rgba(45, 211, 139, 0.34); color: #55e0a2; background: rgba(45, 211, 139, 0.09); }
.ea-control-state.paused { border-color: rgba(255, 181, 60, 0.38); color: #ffd077; background: rgba(255, 181, 60, 0.1); }
.ea-control-button { min-width: 76px; border-color: rgba(255, 181, 60, 0.44); color: #ffd077; background: rgba(255, 181, 60, 0.09); }
.ea-control-button:hover { border-color: rgba(255, 197, 94, 0.75); background: rgba(255, 181, 60, 0.17); }
.ea-control-button.resume { border-color: rgba(45, 211, 139, 0.45); color: #62e6a9; background: rgba(45, 211, 139, 0.1); }
.ea-control-button.resume:hover { border-color: rgba(72, 231, 161, 0.78); background: rgba(45, 211, 139, 0.18); }
.account-remark { display: inline-block; max-width: 140px; margin-left: 9px; padding: 2px 7px; overflow: hidden; border: 1px solid rgba(210, 164, 81, 0.3); border-radius: 5px; color: #e4c57f; font-size: 11px; line-height: 18px; text-overflow: ellipsis; vertical-align: middle; white-space: nowrap; }
.account-remark-button { margin-left: 7px; padding: 2px 5px; border: 0; background: transparent; color: #5aaeff; font-size: 11px; cursor: pointer; }
.account-remark-button:hover { color: #9bd0ff; text-decoration: underline; }
.daily-drawdown-panel { margin-top: 14px; }
.daily-drawdown-head { align-items: center; }
.daily-drawdown-head > div { display: grid; gap: 4px; }
.daily-drawdown-head label { display: inline-flex; align-items: center; gap: 8px; color: #8fa5bc; font-size: 12px; }
.daily-drawdown-head select { min-width: 106px; height: 32px; padding: 0 8px; border: 1px solid rgba(105, 151, 199, 0.35); border-radius: 7px; background: rgba(7, 24, 40, 0.88); color: #d7e7f7; }
.daily-drawdown-table td:nth-child(2) { white-space: nowrap; }
.daily-drawdown-table .platform-tag { margin-right: 7px; }
.drawer-drawdown-callout { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 8px 14px; margin: 0 0 14px; padding: 15px; border: 1px solid rgba(255, 101, 111, 0.28); border-radius: 10px; background: linear-gradient(135deg, rgba(114, 23, 42, 0.22), rgba(15, 25, 37, 0.7)); }
.drawer-drawdown-callout > span { color: #c0cedd; font-size: 12px; }
.drawer-drawdown-callout strong { font-size: 21px; }
.drawer-drawdown-callout b { color: #ed9ba3; font-size: 12px; }
.drawer-drawdown-callout small { grid-column: 1 / -1; color: #879cb2; font-size: 11px; }
.app-shell-v2 .report-card, .app-shell-v2 .risk-card, .app-shell-v2 .push-item, .app-shell-v2 .admin-row { border-radius: 11px; border-color: rgba(102, 144, 183, 0.24); background: linear-gradient(145deg, rgba(12, 31, 48, 0.86), rgba(7, 20, 33, 0.86)); }
.app-shell-v2 .report-card:hover, .app-shell-v2 .risk-card:hover, .app-shell-v2 .admin-row:hover { border-color: rgba(47, 140, 255, 0.48); transform: translateY(-1px); }
.app-shell-v2 .push-overview article, .app-shell-v2 .admin-stats article { border-radius: 11px; background: linear-gradient(145deg, rgba(15, 42, 65, 0.85), rgba(7, 21, 35, 0.85)); }

.account-drawer { position: fixed; inset: 0; z-index: 180; display: grid; grid-template-columns: minmax(0, 1fr) min(480px, 100%); visibility: hidden; opacity: 0; transition: opacity 180ms ease, visibility 180ms ease; }
.account-drawer.open { visibility: visible; opacity: 1; }
.account-drawer-backdrop { border: 0; background: rgba(0, 5, 12, 0.64); }
.account-drawer-panel { height: 100%; padding: 28px; overflow: auto; border-left: 1px solid rgba(71, 146, 226, 0.35); background: radial-gradient(circle at 100% 0%, rgba(38, 126, 234, 0.18), transparent 34%), linear-gradient(160deg, #0a1d2e, #040d17 72%); box-shadow: -22px 0 55px rgba(0, 0, 0, 0.4); transform: translateX(100%); transition: transform 220ms ease; }
.account-drawer.open .account-drawer-panel { transform: translateX(0); }
.account-drawer-panel header { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 24px; }
.account-drawer-panel h2 { margin: 7px 0 0; font-size: 23px; }
.drawer-close { width: 34px; height: 34px; border: 1px solid rgba(132, 164, 197, 0.3); border-radius: 9px; background: rgba(255, 255, 255, 0.04); color: #c8d8e8; font-size: 22px; line-height: 1; }
.drawer-close:hover { border-color: #2f8cff; color: #fff; }
.drawer-account-summary { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 17px; border: 1px solid rgba(96, 143, 191, 0.27); border-radius: 12px; background: rgba(11, 33, 51, 0.72); }
.drawer-account-summary > div { display: grid; gap: 4px; }
.drawer-account-summary strong { font-size: 20px; }
.drawer-account-summary small { color: #92a8bf; font-size: 12px; }
.drawer-account-summary em { font-style: normal; font-size: 13px; }
.drawer-account-summary .status-dot { display: inline-block; margin-right: 6px; }
.drawer-metric-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin: 14px 0; }
.drawer-metric-grid article { display: grid; gap: 8px; min-height: 92px; padding: 14px; border: 1px solid rgba(105, 143, 181, 0.2); border-radius: 10px; background: rgba(7, 22, 37, 0.76); }
.drawer-metric-grid span { color: #859bb2; font-size: 12px; }
.drawer-metric-grid strong { font-size: 18px; letter-spacing: -0.02em; }
.drawer-status-list { border: 1px solid rgba(105, 143, 181, 0.2); border-radius: 10px; background: rgba(5, 17, 29, 0.58); }
.drawer-status-list p { display: flex; justify-content: space-between; gap: 16px; margin: 0; padding: 13px 14px; border-bottom: 1px solid rgba(105, 143, 181, 0.15); color: #8da1b7; font-size: 12px; }
.drawer-status-list p:last-child { border-bottom: 0; }
.drawer-status-list b { max-width: 63%; color: #d4e1ee; text-align: right; overflow-wrap: anywhere; }
.drawer-actions { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 16px; }
.drawer-actions .button { min-height: 42px; }

@media (max-width: 1240px) { .app-shell-v2 .main-nav button { padding: 0 8px; font-size: 12px; } .command-hero { align-items: flex-start; flex-direction: column; } .command-hero-stats { width: 100%; } }
@media (max-width: 900px) { .workspace-context, .command-hero { display: none; } .account-drawer { grid-template-columns: 1fr; } .account-drawer-backdrop { display: none; } .account-drawer-panel { padding: 22px 16px 108px; border-left: 0; transform: translateY(100%); } .account-drawer.open .account-drawer-panel { transform: translateY(0); } }
@media (max-width: 900px) { .account-remark, .account-remark-button { display: none; } }
.is-hidden {
  display: none !important;
}
+/* V3 Business Edition --------------------------------------------------- */
.app-shell-v3 {
  --v3-navy: #071522;
  --v3-panel: rgba(8, 24, 38, 0.94);
  --v3-panel-soft: rgba(12, 33, 51, 0.88);
  --v3-line: rgba(131, 160, 188, 0.2);
  --v3-gold: #d2a451;
  --v3-gold-soft: #f0ce88;
  grid-template-rows: 78px minmax(0, 1fr);
  background:
    radial-gradient(circle at 48% -10%, rgba(43, 126, 218, 0.14), transparent 34%),
    radial-gradient(circle at 96% 12%, rgba(210, 164, 81, 0.07), transparent 24%),
    linear-gradient(135deg, #030b13 0%, #061522 50%, #06111b 100%);
}

.app-shell-v3::after {
  position: fixed;
  right: 0;
  bottom: 0;
  z-index: 0;
  width: 320px;
  height: 320px;
  border-right: 1px solid rgba(210, 164, 81, 0.08);
  border-bottom: 1px solid rgba(210, 164, 81, 0.08);
  background: linear-gradient(135deg, transparent 48%, rgba(210, 164, 81, 0.025) 49%, transparent 50%);
  content: "";
  pointer-events: none;
}

.app-shell-v3 .desktop-topbar {
  position: relative;
  z-index: 30;
  height: 78px;
  grid-template-columns: 250px minmax(0, 1fr) 300px;
  border-bottom: 1px solid rgba(210, 164, 81, 0.2);
  background: linear-gradient(90deg, rgba(3, 11, 18, 0.98), rgba(6, 20, 32, 0.96) 52%, rgba(4, 13, 22, 0.98));
  box-shadow: 0 12px 38px rgba(0, 0, 0, 0.22);
}

.edition-rail {
  position: absolute;
  top: 0;
  left: 28px;
  display: flex;
  align-items: center;
  gap: 6px;
  height: 18px;
  color: #8fa0b1;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.16em;
}

.edition-rail span {
  padding: 2px 5px;
  border-radius: 0 0 4px 4px;
  background: linear-gradient(135deg, #e2bd73, #9a6929);
  color: #111820;
  letter-spacing: 0.05em;
}

.app-shell-v3 .desktop-brand { padding-top: 9px; }
.app-shell-v3 .desktop-brand strong { color: #f4f7fa; font-size: 20px; letter-spacing: 0.06em; }
.app-shell-v3 .logo-mark { background: linear-gradient(145deg, #f0cb7e, #996527); box-shadow: 0 0 24px rgba(210, 164, 81, 0.28); }
.app-shell-v3 .main-nav { align-items: center; justify-content: center; gap: 2px; padding-top: 3px; }
.app-shell-v3 .main-nav button { min-width: auto; min-height: 40px; padding: 0 11px; border: 1px solid transparent; border-radius: 8px; color: #99aabc; font-size: 12px; }
.app-shell-v3 .main-nav button:hover { color: #e7eef6; background: rgba(255, 255, 255, 0.035); }
.app-shell-v3 .main-nav button.active { border-color: rgba(210, 164, 81, 0.22); background: linear-gradient(135deg, rgba(210, 164, 81, 0.15), rgba(34, 82, 132, 0.16)); color: var(--v3-gold-soft); box-shadow: inset 0 -2px 0 var(--v3-gold), 0 10px 24px rgba(0, 0, 0, 0.2); }
.app-shell-v3 .operator-area { gap: 10px; padding-top: 3px; }
.app-shell-v3 .operator-area strong { max-width: 105px; overflow: hidden; color: #d7e0e9; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.app-shell-v3 .avatar { width: 30px; height: 30px; border-color: rgba(210, 164, 81, 0.44); background: linear-gradient(135deg, #d8c294, #445568); }
.app-shell-v3 .logout-button { border-color: rgba(210, 164, 81, 0.25); background: rgba(210, 164, 81, 0.07); color: #d8c399; }

.app-shell-v3 .sidebar {
  position: relative;
  z-index: 2;
  padding: 18px 13px;
  border-right-color: rgba(210, 164, 81, 0.16);
  background: linear-gradient(180deg, rgba(5, 17, 28, 0.98), rgba(4, 14, 23, 0.96));
}

.app-shell-v3 .side-panel,
.app-shell-v3 .server-panel,
.app-shell-v3 .ops-panel,
.app-shell-v3 .risk-panel {
  border-color: var(--v3-line);
  border-radius: 12px;
  background: linear-gradient(150deg, rgba(12, 31, 47, 0.94), rgba(5, 17, 28, 0.94));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035), 0 18px 35px rgba(0, 0, 0, 0.2);
}

.app-shell-v3 .side-title { border-bottom: 1px solid rgba(131, 160, 188, 0.13); color: #e3eaf1; font-size: 12px; letter-spacing: 0.04em; }
.app-shell-v3 .side-title button { color: var(--v3-gold-soft); }
.app-shell-v3 .studio-item.active,
.app-shell-v3 .group-item.active { border-color: rgba(210, 164, 81, 0.22); background: linear-gradient(90deg, rgba(210, 164, 81, 0.14), rgba(27, 78, 127, 0.13)); color: #f1d598; }

.app-shell-v3 .workspace { position: relative; z-index: 1; padding: 18px; }
.app-shell-v3 .workspace-context { min-height: 42px; margin-bottom: 10px; }
.app-shell-v3 .workspace-context .eyebrow { color: var(--v3-gold); }

.business-status-strip {
  display: grid;
  grid-template-columns: 1.2fr repeat(3, 1fr);
  margin-bottom: 12px;
  overflow: hidden;
  border: 1px solid rgba(131, 160, 188, 0.18);
  border-radius: 11px;
  background: linear-gradient(90deg, rgba(11, 31, 48, 0.9), rgba(6, 20, 32, 0.88));
}

.business-status-strip article { position: relative; display: grid; gap: 4px; min-height: 58px; align-content: center; padding: 9px 16px; border-right: 1px solid rgba(131, 160, 188, 0.14); }
.business-status-strip article:first-child::before { position: absolute; top: 0; bottom: 0; left: 0; width: 3px; background: linear-gradient(#f0ce88, #976425); content: ""; }
.business-status-strip article:last-child { border-right: 0; }
.business-status-strip span { color: #6f8296; font-size: 8px; font-weight: 700; letter-spacing: 0.13em; }
.business-status-strip strong { color: #dce6ef; font-size: 12px; font-weight: 600; }
.business-status-strip article:first-child strong { color: var(--v3-gold-soft); }
.business-status-strip .status-online { color: #65df93; }
.business-status-strip .status-online::before { display: inline-block; width: 6px; height: 6px; margin-right: 7px; border-radius: 50%; background: #47d982; box-shadow: 0 0 10px rgba(71, 217, 130, 0.6); content: ""; }

.app-shell-v3 .metric-grid { grid-template-columns: repeat(5, minmax(150px, 1fr)); gap: 10px; }
.app-shell-v3 .metric-card { min-height: 116px; padding: 18px 14px 12px 61px; border-color: rgba(131, 160, 188, 0.2); border-radius: 12px; background: linear-gradient(148deg, rgba(12, 32, 49, 0.95), rgba(6, 19, 31, 0.94)); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035), 0 14px 30px rgba(0, 0, 0, 0.18); transition: border-color 160ms ease, transform 160ms ease, box-shadow 160ms ease; }
.app-shell-v3 .metric-card:hover { border-color: rgba(210, 164, 81, 0.32); transform: translateY(-2px); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05), 0 19px 38px rgba(0, 0, 0, 0.25); }
.app-shell-v3 .metric-card::after { position: absolute; right: 0; bottom: 0; left: 0; height: 2px; background: linear-gradient(90deg, transparent, rgba(57, 143, 255, 0.48), transparent); content: ""; }
.app-shell-v3 .metric-card::before { top: 23px; left: 19px; width: 30px; height: 30px; font-size: 20px; }
.app-shell-v3 .metric-card span { color: #8fa1b4; font-size: 11px; letter-spacing: 0.04em; }
.app-shell-v3 .metric-card strong { margin-top: 11px; color: #eef3f8; font-size: clamp(22px, 1.8vw, 27px); }
.app-shell-v3 .metric-card small { color: #61778c; font-size: 10px; }
.app-shell-v3 .price-card { border-color: rgba(210, 164, 81, 0.3); background: radial-gradient(circle at 88% 10%, rgba(210, 164, 81, 0.12), transparent 34%), linear-gradient(148deg, rgba(22, 37, 46, 0.96), rgba(8, 21, 32, 0.95)); }
.app-shell-v3 .price-card::after { background: linear-gradient(90deg, transparent, rgba(210, 164, 81, 0.8), transparent); }
.app-shell-v3 .price-card strong { color: #f0ce88; }

.app-shell-v3 .command-hero { min-height: 132px; border-color: rgba(210, 164, 81, 0.24); background: radial-gradient(circle at 75% 30%, rgba(45, 119, 201, 0.13), transparent 30%), linear-gradient(100deg, rgba(10, 31, 48, 0.97), rgba(5, 19, 31, 0.96)); }
.app-shell-v3 .command-hero::after { background: linear-gradient(90deg, transparent, #d2a451, #2f8cff); }
.app-shell-v3 .command-hero .eyebrow { color: var(--v3-gold); }
.app-shell-v3 .command-hero h1 { font-size: clamp(22px, 2vw, 28px); font-weight: 600; }
.app-shell-v3 .command-hero-stats { border-color: rgba(210, 164, 81, 0.18); }
.app-shell-v3 .command-hero-stats article strong { color: var(--v3-gold-soft); }
.app-shell-v3 .hero-link { background: linear-gradient(180deg, rgba(167, 113, 43, 0.82), rgba(91, 58, 19, 0.86)); color: #fff0cd; }
.app-shell-v3 .hero-link b { color: #f4d38e; }

.app-shell-v3 .account-board,
.app-shell-v3 .command-log-panel,
.app-shell-v3 .panel-card,
.app-shell-v3 .admin-panel { border-color: rgba(131, 160, 188, 0.2); border-radius: 12px; background: linear-gradient(150deg, rgba(10, 28, 43, 0.94), rgba(5, 18, 29, 0.94)); }
.app-shell-v3 .desk-tools h2,
.app-shell-v3 .panel-head h2 { color: #e7edf3; font-size: 15px; font-weight: 600; letter-spacing: 0.02em; }
.app-shell-v3 .desk-tools small,
.app-shell-v3 .panel-head span { color: #71869a; }
.app-shell-v3 input,
.app-shell-v3 select,
.app-shell-v3 textarea { border-color: rgba(131, 160, 188, 0.24); border-radius: 8px; background: rgba(3, 14, 23, 0.74); }
.app-shell-v3 input:focus,
.app-shell-v3 select:focus,
.app-shell-v3 textarea:focus { border-color: rgba(210, 164, 81, 0.5); box-shadow: 0 0 0 3px rgba(210, 164, 81, 0.07); }
.app-shell-v3 .table-wrap table thead { background: rgba(21, 46, 67, 0.62); }
.app-shell-v3 .table-wrap th { color: #8fa2b5; font-size: 10px; font-weight: 600; letter-spacing: 0.06em; }
.app-shell-v3 .table-wrap td { border-bottom-color: rgba(131, 160, 188, 0.11); }
.app-shell-v3 .table-wrap tbody tr:hover { background: linear-gradient(90deg, rgba(210, 164, 81, 0.06), rgba(47, 140, 255, 0.055)); }
.app-shell-v3 .button { border-radius: 8px; }
.app-shell-v3 .button.primary { border-color: rgba(210, 164, 81, 0.34); background: linear-gradient(180deg, rgba(173, 119, 48, 0.88), rgba(102, 66, 22, 0.88)); color: #fff1d0; }
.app-shell-v3 .view-toggle.active { border-color: rgba(210, 164, 81, 0.42); color: #f0ce88; background: rgba(210, 164, 81, 0.1); }

.login-card-v3 { position: relative; overflow: hidden; border-color: rgba(210, 164, 81, 0.32); border-radius: 16px; background: radial-gradient(circle at 100% 0%, rgba(210, 164, 81, 0.12), transparent 32%), linear-gradient(145deg, rgba(10, 29, 45, 0.98), rgba(4, 15, 25, 0.98)); }
.login-card-v3::after { position: absolute; top: 0; right: 0; left: 0; height: 2px; background: linear-gradient(90deg, transparent, #d2a451, transparent); content: ""; }
.login-edition { margin: -4px 0 22px; color: #8294a6; font-size: 9px; font-weight: 700; letter-spacing: 0.15em; }
.login-edition span { display: inline-block; margin-right: 7px; padding: 3px 7px; border-radius: 4px; background: linear-gradient(135deg, #e3bd72, #9b6827); color: #111820; letter-spacing: 0.05em; }
.login-card-v3 .login-logo .logo-mark { background: linear-gradient(145deg, #f0cb7e, #996527); box-shadow: 0 0 26px rgba(210, 164, 81, 0.3); }
.login-card-v3 .login-button { border-color: rgba(210, 164, 81, 0.45); background: linear-gradient(135deg, #bd883b, #76501f); color: #fff3d8; font-weight: 700; }

@media (max-width: 1380px) {
  .app-shell-v3 { grid-template-columns: 220px minmax(0, 1fr) 240px; }
  .app-shell-v3 .desktop-topbar { grid-template-columns: 230px minmax(0, 1fr) 265px; }
  .app-shell-v3 .main-nav button { padding: 0 7px; font-size: 11px; }
  .app-shell-v3 .metric-grid { grid-template-columns: repeat(3, minmax(170px, 1fr)); }
}

@media (max-width: 1100px) {
  .business-status-strip { grid-template-columns: repeat(2, 1fr); }
  .business-status-strip article:nth-child(2) { border-right: 0; }
  .business-status-strip article:nth-child(-n+2) { border-bottom: 1px solid rgba(131, 160, 188, 0.14); }
}

@media (max-width: 900px) {
  .business-status-strip { display: none; }
  .mobile-top { border-bottom-color: rgba(210, 164, 81, 0.22); background: linear-gradient(90deg, rgba(4, 16, 27, 0.98), rgba(10, 29, 45, 0.98)); }
  .mobile-brand .logo-mark { background: linear-gradient(145deg, #f0cb7e, #996527); box-shadow: 0 0 20px rgba(210, 164, 81, 0.25); }
  .mobile-brand::after { content: "V3"; padding: 2px 5px; border-radius: 4px; background: rgba(210, 164, 81, 0.14); color: #e5c37e; font-size: 9px; font-weight: 700; }
}

@media (max-width: 760px) {
  .app-shell-v3 .metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .app-shell-v3 .metric-card { min-width: 0; min-height: 116px; }
  .app-shell-v3 .price-card { grid-column: 1 / -1; }
  .app-shell-v3 .workspace { max-width: 100%; overflow: hidden; }
}
