@import url("https://fonts.googleapis.com/css2?family=Rajdhani:wght@500;600;700;800;900&display=swap");

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

:root {
  color-scheme: dark;
  --panel: rgba(18, 22, 27, 0.88);
  --panel-strong: rgba(7, 10, 12, 0.92);
  --text: #f3f1e8;
  --muted: #a9abb0;
  --gold: #d9af42;
  --gold-soft: #f0d06d;
  --border: rgba(217, 175, 66, 0.38);
  --line: rgba(255, 255, 255, 0.09);
  --green: #66f15c;
  --red: #ff425b;
  --orange: #e8bb68;
}

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

body {
  min-height: 100vh;
  padding-top: 0;
  color: var(--text);
  background-color: #0b0f13;
  background-image: url("/img/wallpaper.png");
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  background-attachment: fixed;
  font-family: "Rajdhani", "Arial Narrow", Arial, sans-serif;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background: rgba(4, 7, 10, 0.42);
}

button,
select,
input {
  font: inherit;
}

.mode-pill,
.status,
.state {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--gold-soft);
  background: rgba(5, 8, 10, 0.7);
  font-weight: 900;
}

.mode-pill {
  min-height: 34px;
  padding: 0 13px;
  font-size: 12px;
  letter-spacing: 0.14em;
}

.shell {
  width: min(100% - 42px, 1180px);
  margin: 0 auto;
  padding: 34px 0 58px;
}

.hero {
  display: grid;
  justify-items: center;
  padding: 18px 0 28px;
  text-align: center;
}

.brand-logo {
  display: block;
  width: 272px;
  max-width: 72vw;
  height: auto;
  margin-bottom: 26px;
}

.hero-content {
  width: min(760px, 100%);
}

.eyebrow,
.panel-kicker {
  color: var(--gold);
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

h1 {
  margin-top: 7px;
  color: #fff;
  font-size: clamp(29px, 4vw, 46px);
  font-weight: 900;
  line-height: 1;
}

.hero-copy {
  max-width: 650px;
  margin: 13px auto 18px;
  color: #bec0c4;
  font-size: 17px;
  font-weight: 600;
  line-height: 1.55;
}

.status {
  min-height: 36px;
  padding: 0 15px;
  font-size: 13px;
  letter-spacing: 0.04em;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(6, minmax(135px, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.metrics article,
.toolbar,
.decision-panel,
.safety-strip article,
.performance-grid article,
.panel {
  border: 1px solid var(--border);
  border-radius: 8px;
  background: linear-gradient(145deg, var(--panel), var(--panel-strong));
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.28);
}

.metrics article {
  min-height: 92px;
  padding: 17px;
}

.metrics span {
  display: block;
  margin-bottom: 7px;
  color: rgba(255, 255, 255, 0.62);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.metrics strong {
  color: #fff;
  font-size: 27px;
  font-weight: 900;
  line-height: 1;
}

.performance-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(130px, 1fr));
  gap: 12px;
  padding: 18px;
}

.performance-grid article {
  min-height: 82px;
  padding: 15px;
  box-shadow: none;
}

.performance-grid span {
  display: block;
  margin-bottom: 7px;
  color: rgba(255, 255, 255, 0.62);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.performance-grid strong {
  color: #fff;
  font-size: 23px;
  font-weight: 900;
}

.equity-panel {
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr);
  align-items: center;
  gap: 18px;
  padding: 0 18px 18px;
}

.equity-panel strong {
  display: block;
  margin-top: 7px;
  color: #fff;
  font-size: 25px;
  font-weight: 900;
}

.equity-panel svg {
  width: 100%;
  min-height: 160px;
  border: 1px solid rgba(217, 175, 66, 0.28);
  border-radius: 8px;
  background: rgba(5, 8, 10, 0.55);
}

.equity-panel .curve-line {
  fill: none;
  stroke: var(--gold-soft);
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 4;
}

.equity-panel .curve-fill {
  fill: rgba(217, 175, 66, 0.16);
}

.equity-panel circle {
  fill: var(--green);
  stroke: rgba(5, 8, 10, 0.95);
  stroke-width: 3;
}

.toolbar {
  display: grid;
  grid-template-columns: minmax(210px, 1fr) repeat(5, minmax(130px, auto));
  align-items: end;
  gap: 10px;
  margin-top: 18px;
  padding: 8px;
}

.decision-panel {
  display: grid;
  grid-template-columns: minmax(220px, 0.34fr) minmax(0, 1fr);
  align-items: center;
  gap: 20px;
  margin-top: 18px;
  padding: 18px 20px;
}

.decision-panel h2 {
  margin-top: 5px;
  color: #fff;
  font-size: 24px;
  font-weight: 900;
}

.decision-grid {
  display: grid;
  gap: 6px;
}

.decision-grid span {
  width: max-content;
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.decision-grid span.approved {
  border-color: rgba(102, 241, 92, 0.44);
  color: var(--green);
}

.decision-grid span.waiting {
  border-color: rgba(232, 187, 104, 0.52);
  color: var(--orange);
}

.decision-grid span.rejected {
  border-color: rgba(255, 66, 91, 0.46);
  color: #ff9daa;
}

.decision-grid strong {
  color: #fff;
  font-size: 18px;
  font-weight: 900;
}

.decision-grid p {
  color: rgba(255, 255, 255, 0.64);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.35;
}

label {
  display: grid;
  gap: 6px;
  color: rgba(255, 255, 255, 0.62);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

select,
input,
button {
  min-height: 48px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 900;
}

select,
input {
  width: 100%;
  border: 1px solid rgba(217, 175, 66, 0.55);
  color: #fff;
  background: rgba(5, 8, 10, 0.72);
  padding: 0 14px;
}

input {
  color-scheme: dark;
}

.safety-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(150px, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.safety-strip article {
  min-height: 70px;
  padding: 14px 16px;
  box-shadow: none;
}

.safety-strip span {
  display: block;
  margin-bottom: 5px;
  color: rgba(255, 255, 255, 0.62);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.safety-strip strong {
  color: var(--green);
  font-size: 22px;
  font-weight: 900;
}

.settings-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(130px, 1fr)) minmax(150px, auto);
  align-items: end;
  gap: 12px;
  padding: 18px;
}

button {
  border: 1px solid #efcd66;
  color: #111318;
  background: linear-gradient(180deg, #efd369 0%, #c99b2a 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.34), 0 8px 18px rgba(190, 146, 53, 0.16);
  cursor: pointer;
  letter-spacing: 0.06em;
  padding: 0 18px;
  text-transform: uppercase;
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

button.ghost {
  color: var(--gold-soft);
  background: rgba(5, 8, 10, 0.72);
}

button:hover,
button:focus-visible {
  transform: translateY(-2px);
  border-color: #f6d66d;
  box-shadow: 0 0 0 1px rgba(246, 214, 109, 0.18), 0 10px 24px rgba(217, 175, 66, 0.22);
}

button:active {
  transform: translateY(0) scale(0.99);
}

button:disabled {
  opacity: 0.62;
  cursor: wait;
}

.mini-button {
  min-height: 30px;
  padding: 0 12px;
  font-size: 12px;
}

.panel {
  margin-top: 18px;
  overflow: hidden;
}

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

.panel-title h2 {
  margin-top: 5px;
  color: #fff;
  font-size: 24px;
  font-weight: 900;
}

time {
  color: rgba(255, 255, 255, 0.58);
  font-size: 13px;
  font-weight: 800;
}

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

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

th,
td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: middle;
}

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

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

th {
  color: var(--gold);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}

td {
  color: #f7f7f7;
  font-size: 15px;
  font-weight: 700;
}

.state {
  min-width: 104px;
  min-height: 28px;
  padding: 0 10px;
  font-size: 11px;
  letter-spacing: 0.05em;
}

.state.NO_TRADE {
  border-color: rgba(255, 66, 91, 0.46);
  color: #ff9daa;
  background: rgba(72, 18, 28, 0.55);
}

.state.OBSERVATION {
  border-color: rgba(232, 187, 104, 0.52);
  color: var(--orange);
  background: rgba(67, 51, 16, 0.48);
}

.state.WATCH,
.state.SIGNAL_POTENTIAL,
.state.SIGNAL_PRIORITY {
  border-color: rgba(102, 241, 92, 0.44);
  color: var(--green);
  background: rgba(20, 51, 38, 0.5);
}

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

  .settings-grid,
  .equity-panel {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  body {
    padding-top: 0;
    background-attachment: scroll;
  }

  .shell {
    width: min(100% - 24px, 1180px);
    padding-top: 24px;
  }

  .brand-logo {
    width: 218px;
    margin-bottom: 20px;
  }

  h1 {
    font-size: 31px;
  }

  .hero-copy {
    font-size: 16px;
  }

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

  .toolbar {
    grid-template-columns: 1fr;
    padding: 12px;
  }

  .decision-panel {
    grid-template-columns: 1fr;
  }

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

  .safety-strip,
  .settings-grid,
  .equity-panel {
    grid-template-columns: 1fr;
  }

  .panel-title {
    align-items: flex-start;
    flex-direction: column;
  }
}
