:root {
  --bg: #050707;
  --bg-soft: #0a0f0f;
  --panel: rgba(10, 15, 15, 0.94);
  --panel-2: #0d1414;
  --line: rgba(216, 221, 224, 0.18);
  --line-strong: rgba(216, 221, 224, 0.34);
  --text: #e8e1d4;
  --muted: #7f8783;
  --dim: #5f6865;
  --titanium: #d8dde0;
  --titanium-soft: #9ca6aa;
  --green: #6ed486;
  --red: #c76860;
  --blue-black: #071112;
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  background:
    radial-gradient(circle at 70% 0%, rgba(62, 88, 82, 0.16), transparent 35%),
    linear-gradient(145deg, rgba(12, 14, 14, 0.8), rgba(3, 5, 5, 0.98)),
    var(--bg);
  color: var(--text);
}

body {
  min-width: 1180px;
  letter-spacing: 0.02em;
}

button,
a {
  font: inherit;
}

.terminal-shell {
  display: grid;
  grid-template-columns: 172px 1fr;
  min-height: 100vh;
}

.sidebar {
  position: sticky;
  top: 0;
  display: flex;
  flex-direction: column;
  height: 100vh;
  border-right: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(13, 20, 20, 0.96) 0%, rgba(5, 8, 8, 0.98) 52%, rgba(2, 4, 4, 1) 100%),
    linear-gradient(90deg, rgba(216, 221, 224, 0.08), transparent 42%, rgba(0, 0, 0, 0.5)),
    var(--bg);
}

.brand-mark {
  display: flex;
  align-items: center;
  gap: 9px;
  height: 70px;
  padding: 0 12px;
  text-transform: uppercase;
}

.brand-icon {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border: 1px solid var(--titanium);
  color: #f0eadf;
  font-size: 16px;
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0;
  box-shadow: inset 0 0 0 1px rgba(216, 221, 224, 0.12);
}

.brand-mark strong {
  display: block;
  color: #f0eadf;
  font-size: 14px;
  font-weight: 900;
  line-height: 1.1;
  letter-spacing: 0.08em;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.9);
}

.side-nav {
  padding: 18px 0;
}

.side-nav a {
  display: flex;
  align-items: center;
  min-height: 42px;
  padding: 0 22px;
  border-left: 3px solid transparent;
  border-bottom: 1px solid rgba(216, 221, 224, 0.14);
  color: #d8ddda;
  text-decoration: none;
  text-transform: uppercase;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.9);
}

.side-nav a:first-child {
  border-top: 1px solid rgba(216, 221, 224, 0.14);
}

.side-nav a.active,
.side-nav a:hover {
  border-left-color: var(--titanium);
  background: linear-gradient(90deg, rgba(216, 221, 224, 0.28), rgba(216, 221, 224, 0.08) 48%, transparent);
  color: #ffffff;
}

.sidebar-art {
  margin-top: auto;
  display: flex;
  align-items: flex-end;
  min-height: 315px;
  padding: 0 14px 30px;
  border-top: 0;
  background:
    linear-gradient(180deg, rgba(2, 4, 4, 0), rgba(216, 221, 224, 0.06)),
    rgba(4, 7, 7, 0.18);
  text-transform: uppercase;
}

.sidebar-art p {
  margin: 0;
  color: #f0eadf;
  font-size: 17px;
  font-weight: 900;
  line-height: 1.18;
  letter-spacing: 0.18em;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.9);
}

.workspace {
  min-width: 0;
}

.topbar {
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  height: 70px;
  border-bottom: 1px solid var(--line);
  background: rgba(7, 12, 12, 0.94);
}

.topline {
  display: flex;
  align-items: center;
  margin: 0 0 0 18px;
  color: #dfe5e4;
  font-family: Corbel, "Avenir Next", "Segoe UI", sans-serif;
  font-size: 22px;
  font-weight: 300;
  letter-spacing: 0.08em;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.72);
}

.wallet {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-right: 24px;
}

.fuel-balance,
.wallet button {
  height: 30px;
  padding: 0 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.12em;
}

.fuel-balance {
  display: grid;
  place-items: center;
  border-color: rgba(110, 212, 134, 0.45);
  background: rgba(110, 212, 134, 0.12);
  color: var(--green);
  text-transform: uppercase;
  letter-spacing: 0.16em;
}

.wallet .avatar {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(110, 212, 134, 0.16);
  color: var(--green);
  font-size: 10px;
  box-shadow: 0 0 0 0 rgba(110, 212, 134, 0.42), inset 0 0 0 1px rgba(110, 212, 134, 0.35);
  animation: wallet-pulse 2.4s ease-out infinite;
}

@keyframes wallet-pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(110, 212, 134, 0.42), inset 0 0 0 1px rgba(110, 212, 134, 0.42);
  }

  70% {
    box-shadow: 0 0 0 8px rgba(110, 212, 134, 0), inset 0 0 0 1px rgba(110, 212, 134, 0.42);
  }

  100% {
    box-shadow: 0 0 0 0 rgba(110, 212, 134, 0), inset 0 0 0 1px rgba(110, 212, 134, 0.42);
  }
}

.ticker-grid {
  display: grid;
  grid-template-columns: 1.1fr repeat(5, 1fr) 1.35fr;
  min-height: 62px;
  border-bottom: 1px solid var(--line);
  background: rgba(7, 10, 10, 0.9);
}

.ticker-grid article {
  padding: 12px 18px;
  border-right: 1px solid var(--line);
}

.ticker-grid span {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  text-transform: uppercase;
  font-size: 8px;
  font-weight: 900;
  letter-spacing: 0.16em;
}

.ticker-grid strong {
  color: var(--text);
  font-family: "Arial Narrow", Arial, sans-serif;
  font-size: 17px;
  letter-spacing: 0.09em;
}

.ticker-grid em {
  margin-left: 6px;
  color: var(--green);
  font-size: 10px;
  font-style: normal;
  font-weight: 900;
}

.ticker-grid small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
}

.mini-bar {
  height: 7px;
  margin-top: 6px;
  background: #222927;
}

.mini-bar i {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--titanium-soft), var(--titanium));
}

.mini-bar.danger i {
  background: var(--red);
}

.status-card strong {
  color: var(--red);
  text-transform: uppercase;
  font-size: 12px;
}

.content-grid {
  display: grid;
  grid-template-columns: minmax(450px, 1.45fr) 185px 185px 300px;
  grid-template-rows: auto 195px auto;
  gap: 8px;
  padding: 14px;
}

.panel {
  border: 1px solid var(--line-strong);
  background:
    linear-gradient(180deg, rgba(14, 21, 21, 0.94), rgba(6, 10, 10, 0.98)),
    var(--panel);
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.03);
}

.panel h2 {
  margin: 0;
  color: #d8d0c2;
  text-transform: uppercase;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.14em;
}

.asset-card {
  grid-column: 1 / 4;
  grid-row: 1;
}

.asset-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: 14px;
  border-bottom: 1px solid var(--line);
}

h1 {
  margin: 0;
  color: var(--green);
  font-family: "Arial Narrow", "Avenir Next Condensed", Arial, sans-serif;
  font-size: 28px;
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0.04em;
}

.asset-head p {
  margin: 8px 0 0;
  color: #9ea8a4;
  text-transform: uppercase;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.12em;
}

.asset-head p span {
  display: block;
  margin-top: 3px;
  color: #a7afa9;
  font-weight: 700;
}

.badge {
  display: inline-grid;
  place-items: center;
  height: 26px;
  padding: 0 14px;
  border: 1px solid rgba(110, 212, 134, 0.45);
  background: rgba(110, 212, 134, 0.12);
  color: var(--green);
  text-transform: uppercase;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.16em;
}

.asset-body {
  display: grid;
  grid-template-columns: minmax(420px, 1.15fr) minmax(320px, 0.85fr);
  min-height: 310px;
}

.rig-photo {
  min-height: 310px;
  border-right: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(5, 8, 8, 0.04), rgba(4, 5, 5, 0.42)),
    url("./assets/featured-well.jpg") center 52% / cover;
  filter: saturate(0.78) contrast(1.08) brightness(0.82);
}

.spec-list {
  margin: 0;
  padding: 12px 16px;
}

.spec-list div {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 18px;
  min-height: 23px;
  border-bottom: 1px solid rgba(216, 221, 224, 0.12);
  align-items: center;
}

dt {
  color: var(--muted);
  text-transform: uppercase;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: 0.16em;
}

dd {
  margin: 0;
  color: #dfd8ca;
  font-family: "Arial Narrow", Arial, sans-serif;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.06em;
}

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

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

.right-rail {
  grid-column: 4;
  grid-row: 1;
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 8px;
}

.right-rail .panel {
  padding: 12px;
}

.right-rail button,
.panel-head button,
.map-card button {
  width: 100%;
  min-height: 28px;
  margin-top: 8px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.02);
  color: #d4d9d8;
  text-transform: uppercase;
  font-size: 8px;
  font-weight: 900;
  letter-spacing: 0.12em;
}

.right-rail button:hover,
.panel-head button:hover,
.map-card button:hover {
  border-color: var(--titanium);
  color: #ffffff;
}

.timeline ol {
  position: relative;
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
}

.timeline li {
  display: grid;
  grid-template-columns: 14px 1fr auto;
  align-items: center;
  gap: 5px;
  min-height: 21px;
  color: #9da6a2;
  font-size: 10px;
}

.timeline li span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #7bd15e;
  box-shadow: 0 0 10px rgba(123, 209, 94, 0.55);
}

.timeline li.muted span {
  background: #777d78;
  box-shadow: none;
}

.timeline li.live strong {
  color: var(--green);
}

.timeline strong {
  font-size: 9px;
}

.timeline em {
  color: var(--muted);
  font-style: normal;
  font-size: 9px;
}

.chart-panel {
  grid-column: 1;
  grid-row: 2;
  height: 195px;
  padding: 12px;
  overflow: hidden;
}

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

.panel-head button {
  width: auto;
  min-width: 74px;
  margin-top: 0;
}

#productionChart {
  display: block;
  width: 100%;
  height: 118px;
  margin-top: 12px;
}

.map-card {
  display: grid;
  grid-column: 2 / 4;
  grid-row: 2;
  grid-template-columns: 1.15fr 0.85fr;
  height: 195px;
  padding: 0;
  overflow: hidden;
}

.map-image {
  position: relative;
  min-height: 0;
  overflow: hidden;
  background: #050808;
}

.map-image::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(5, 8, 8, 0.42), rgba(5, 8, 8, 0.66)),
    url("./assets/location-terrain.jpg") center / cover;
  filter: saturate(0.48) contrast(1.2) brightness(0.52);
}

.map-marker,
.map-marker::before,
.map-marker::after {
  position: absolute;
  left: 55%;
  top: 52%;
  border-radius: 50%;
  transform: translate(-50%, -50%);
}

.map-marker {
  z-index: 2;
  width: 7px;
  height: 7px;
  background: var(--red);
  box-shadow:
    0 0 0 1px rgba(255, 216, 210, 0.86),
    0 0 16px rgba(199, 104, 96, 0.95),
    0 0 28px rgba(199, 104, 96, 0.72);
}

.map-marker::before,
.map-marker::after {
  content: "";
  inset: 50% auto auto 50%;
  width: 26px;
  height: 26px;
  border: 1px solid rgba(199, 104, 96, 0.8);
  background: rgba(199, 104, 96, 0.24);
  animation: map-marker-pulse 2s ease-out infinite;
}

.map-marker::after {
  animation-delay: 0.75s;
}

@keyframes map-marker-pulse {
  0% {
    opacity: 0.9;
    transform: translate(-50%, -50%) scale(0.72);
  }

  70% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(1.8);
  }

  100% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(1.8);
  }
}

.map-info {
  padding: 12px;
  border-left: 1px solid var(--line);
}

.map-info span {
  display: block;
  color: #d8d0c2;
  text-transform: uppercase;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.16em;
}

.map-info strong {
  display: block;
  margin-top: 8px;
  color: var(--green);
  font-size: 15px;
  font-weight: 900;
}

.map-info p {
  margin: 3px 0 28px;
  color: #aaa39a;
  font-size: 11px;
}

.portfolio {
  grid-column: 1 / 4;
  grid-row: 3;
  padding: 12px;
}

.tabs {
  display: flex;
  gap: 14px;
  color: #9ba29f;
  font-size: 10px;
}

table {
  width: 100%;
  margin-top: 12px;
  border-collapse: collapse;
  color: #b8bdb9;
  font-size: 10px;
}

th {
  padding: 8px 10px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  text-align: left;
  text-transform: uppercase;
  font-size: 8px;
  letter-spacing: 0.14em;
}

td {
  padding: 8px 10px;
  border-bottom: 1px solid rgba(216, 221, 224, 0.1);
}

tr.selected {
  background: rgba(216, 221, 224, 0.08);
}

.activity {
  grid-column: 4;
  grid-row: 2;
  height: 195px;
  padding: 12px;
  overflow: hidden;
}

.activity ul {
  display: grid;
  gap: 6px;
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
}

.activity li {
  position: relative;
  display: grid;
  grid-template-columns: 34px 1fr;
  gap: 8px;
  min-height: 24px;
  align-items: center;
  padding: 0 8px 0 10px;
  border-left: 3px solid rgba(216, 221, 224, 0.36);
  background: rgba(216, 221, 224, 0.045);
  color: #b7bcb8;
  font-size: 9px;
}

.activity li:nth-child(even) {
  border-left-color: rgba(110, 212, 134, 0.72);
  background: rgba(110, 212, 134, 0.12);
}

.activity time {
  color: var(--muted);
  font-weight: 900;
}

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

  .terminal-shell {
    grid-template-columns: 74px 1fr;
  }

  .brand-mark div,
  .side-nav a:not(.active),
  .sidebar-art {
    display: none;
  }

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

  .side-nav a {
    padding: 0;
    font-size: 0;
  }

  .side-nav a.active {
    font-size: 0;
  }

  .topline {
    margin-left: 20px;
    font-size: 13px;
    letter-spacing: 0.02em;
  }

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

  .asset-card,
  .portfolio {
    grid-column: 1 / -1;
  }

  .right-rail {
    grid-column: 1 / -1;
    grid-template-columns: 1fr 1fr;
  }
}
