.member-journal-items { display: grid; gap: 20px; }
.member-journal-items p { line-height: 1.65; overflow-wrap: anywhere; }
.member-journal-items summary { cursor: pointer; padding: 12px 0; font-weight: 600; }

/* Status remains legible through text and symbols as well as color. */
#member-milestones .milestone-card {
  --milestone-color: #b0bfd5;
  --milestone-rgb: 150, 172, 204;
  border-left: 3px solid var(--milestone-color);
}
#member-milestones .milestone-in-progress { --milestone-color: #f2c66d; --milestone-rgb: 242, 198, 109; }
#member-milestones .milestone-complete {
  --milestone-color: #70e3b5;
  --milestone-rgb: 112, 227, 181;
  border-color: rgba(112, 227, 181, .3);
  border-left-color: var(--milestone-color);
  background: linear-gradient(115deg, rgba(40, 112, 86, .2), transparent 70%), var(--panel);
}
#member-milestones .milestone-card .milestone-status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 14px;
  padding: 6px 11px;
  border: 1px solid rgba(var(--milestone-rgb), .3);
  border-radius: 999px;
  color: var(--milestone-color);
  background: rgba(var(--milestone-rgb), .09);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .07em;
  line-height: 1.4;
  text-transform: uppercase;
}
.milestone-status-icon { font-size: 15px; line-height: 1; letter-spacing: 0; }

:root {
  color-scheme: dark;
  --bg: #080a0e;
  --bg-elevated: #0d1117;
  --panel: rgba(17, 22, 30, 0.84);
  --panel-strong: #111720;
  --line: rgba(255, 255, 255, 0.085);
  --line-strong: rgba(255, 255, 255, 0.15);
  --text: #f4f7fb;
  --muted: #8994a4;
  --muted-2: #667282;
  --accent: #59e6bd;
  --accent-soft: rgba(89, 230, 189, 0.11);
  --warning: #f4c264;
  --danger: #ff7272;
  --success: #59e6bd;
  --radius: 18px;
  --shadow: 0 28px 80px rgba(0, 0, 0, 0.32);
  --font: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
          "Segoe UI", sans-serif;
  --display: Georgia, "Times New Roman", serif;
  --mono: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
}

body {
  min-height: 100vh;
  overflow-x: hidden;
}

button, input { font: inherit; }

button { color: inherit; }

.hidden { display: none !important; }

.ambient {
  position: fixed;
  width: 560px;
  height: 560px;
  border-radius: 50%;
  pointer-events: none;
  filter: blur(120px);
  opacity: 0.10;
  z-index: 0;
}

.ambient-one {
  top: -260px;
  right: -180px;
  background: #35f3a2;
}

.ambient-two {
  bottom: -350px;
  left: -220px;
  background: #4b6fff;
}

#app {
  position: relative;
  z-index: 1;
  min-height: 100vh;
}

.panel {
  background: linear-gradient(180deg, rgba(21, 27, 36, 0.92), rgba(13, 17, 23, 0.92));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}


.login-shell.login-v012 {
  width: min(1540px, calc(100% - 48px));
  min-height: 100vh;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 375px;
  gap: 26px;
  align-items: center;
  padding: 34px 0;
}

.login-hero {
  position: relative;
  width: 100%;
  aspect-ratio: 1672 / 941;
  overflow: hidden;
  border: 1px solid rgba(123, 238, 207, 0.17);
  border-radius: 24px;
  background: #04070a;
  box-shadow:
    0 30px 90px rgba(0, 0, 0, 0.38),
    0 0 0 1px rgba(89, 230, 189, 0.025) inset;
}

.hero-banner {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  background: #04070a;
}

.login-access {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
}

.login-card {
  position: relative;
  width: 100%;
  padding: 34px;
  border-color: rgba(89,230,189,.16);
  background:
    radial-gradient(circle at 88% 0%, rgba(89,230,189,.075), transparent 36%),
    linear-gradient(180deg, rgba(18,24,31,.97), rgba(9,13,18,.99));
}

.login-card::before {
  content: "";
  display: block;
  width: 44px;
  height: 1px;
  margin-bottom: 24px;
  background: linear-gradient(90deg, var(--accent), transparent);
  box-shadow: 0 0 12px rgba(89,230,189,.5);
}

.login-card-heading h2 {
  font-family: var(--display);
  font-size: 31px;
  font-weight: 400;
  letter-spacing: -.025em;
}

.login-card-heading p:last-child {
  line-height: 1.65;
}

.login-card form {
  display: grid;
  gap: 18px;
  margin-top: 30px;
}

.login-meta {
  display: grid;
  gap: 9px;
  margin-top: 24px;
  padding-top: 19px;
  border-top: 1px solid var(--line);
  color: var(--muted-2);
  font-family: var(--mono);
  font-size: 10px;
}

.login-meta span {
  display: flex;
  align-items: center;
  gap: 8px;
}

.login-meta i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 8px rgba(89,230,189,.65);
}

.brand-block,
.brand-mark,
.security-note {
  display: none;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

h1, h2, p { margin-top: 0; }

h1 {
  margin-bottom: 18px;
  font-family: var(--display);
  font-size: clamp(38px, 5vw, 68px);
  font-weight: 400;
  line-height: 1.02;
  letter-spacing: -0.042em;
}

h2 {
  margin-bottom: 8px;
  font-family: var(--display);
  font-size: 24px;
  font-weight: 400;
  letter-spacing: -0.025em;
}

.hero-copy {
  max-width: 650px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.75;
}

.muted { color: var(--muted); }
.small-text { font-size: 13px; }

.login-card {
  padding: 34px;
}

.login-card form {
  display: grid;
  gap: 18px;
  margin-top: 28px;
}

label {
  display: grid;
  gap: 8px;
  color: #cbd3dd;
  font-size: 13px;
  font-weight: 600;
}

input {
  width: 100%;
  border: 1px solid rgba(151, 178, 175, 0.20);
  border-radius: 9px;
  padding: 14px 14px;
  background: rgba(3, 6, 9, 0.72);
  color: var(--text);
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}

input:focus {
  border-color: rgba(100, 244, 182, 0.6);
  box-shadow: 0 0 0 3px rgba(100, 244, 182, 0.08);
}

.button {
  border: 1px solid var(--line-strong);
  border-radius: 11px;
  padding: 11px 16px;
  background: transparent;
  cursor: pointer;
  font-weight: 700;
  transition: transform .12s, border-color .12s, background .12s, opacity .12s;
}

.button:hover:not(:disabled) {
  transform: translateY(-1px);
  border-color: rgba(255, 255, 255, 0.25);
}

.button:disabled {
  cursor: not-allowed;
  opacity: .45;
}

.button.primary {
  border-color: rgba(89, 230, 189, 0.48);
  background:
    linear-gradient(180deg, rgba(98,239,200,.98), rgba(67,205,171,.98));
  color: #04110d;
  box-shadow: 0 9px 30px rgba(41, 201, 159, .12);
}

.button.ghost {
  color: #cad2dc;
  background: rgba(255, 255, 255, 0.025);
}

.security-note {
  margin: 20px 0 0;
  color: var(--muted-2);
  font-size: 12px;
  line-height: 1.6;
}

.message {
  margin: 16px 0 0;
  padding: 11px 13px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255,255,255,.035);
  color: #cad3df;
  font-size: 13px;
}

.message.error {
  border-color: rgba(255, 114, 114, .25);
  color: #ff9a9a;
  background: rgba(255, 114, 114, .06);
}

.message.success {
  border-color: rgba(100, 244, 182, .25);
  color: var(--success);
  background: rgba(100, 244, 182, .06);
}

.dashboard {
  min-height: 100vh;
}

.topbar {
  height: 74px;
  padding: 0 26px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
  background: rgba(8, 10, 14, 0.82);
  backdrop-filter: blur(18px);
  position: sticky;
  top: 0;
  z-index: 20;
}

.brand-inline {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-inline > div:last-child {
  display: grid;
  gap: 2px;
}

.brand-inline strong { font-size: 14px; }
.brand-inline span { color: var(--muted); font-size: 12px; }

.top-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.locale-switcher {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(4, 7, 10, .58);
}

.locale-switcher button {
  min-width: 34px;
  min-height: 32px;
  padding: 0 8px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .08em;
  cursor: pointer;
}

.locale-switcher button:hover,
.locale-switcher button:focus-visible {
  color: var(--text);
  outline: 1px solid rgba(89, 230, 189, .35);
}

.locale-switcher button[aria-pressed="true"] {
  color: #06110e;
  background: var(--accent);
  box-shadow: 0 0 16px rgba(89, 230, 189, .18);
}

.auth-locale-switcher {
  position: absolute;
  top: 22px;
  right: 24px;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  gap: 22px;
  width: min(1500px, calc(100% - 32px));
  margin: 18px auto 0;
  padding-bottom: 34px;
}

.sidebar {
  min-height: calc(100vh - 108px);
  padding: 18px;
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 92px;
  align-self: start;
}

.account-block {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 12px 10px 18px;
  border-bottom: 1px solid var(--line);
}

.account-block > div {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.account-block strong,
.account-block span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account-block strong { font-size: 13px; }
.account-block span { color: var(--muted); font-size: 11px; }

.status-dot {
  width: 8px;
  height: 8px;
  flex: 0 0 8px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 14px rgba(100, 244, 182, .8);
}

.sidebar nav {
  display: grid;
  gap: 6px;
  margin-top: 18px;
}

.nav-item {
  width: 100%;
  border: 0;
  border-radius: 10px;
  padding: 11px 12px;
  text-align: left;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-weight: 650;
}

.nav-item:hover,
.nav-item.active {
  color: var(--text);
  background: rgba(255, 255, 255, .05);
}

.nav-item.active {
  box-shadow: inset 2px 0 0 var(--accent);
}

.sidebar-footer {
  margin-top: auto;
  padding: 18px 10px 4px;
  border-top: 1px solid var(--line);
  display: grid;
  gap: 4px;
  color: var(--muted-2);
  font-size: 11px;
}

.sidebar-footer strong {
  color: var(--muted);
  font-weight: 600;
}

.content {
  min-width: 0;
  padding: 20px 8px 0 0;
}

.content-section {
  animation: enter .18s ease-out;
}

@keyframes enter {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

.section-heading {
  display: flex;
  justify-content: space-between;
  gap: 30px;
  align-items: flex-start;
  margin-bottom: 22px;
}

.section-heading h1 {
  margin-bottom: 8px;
  font-size: clamp(32px, 4vw, 48px);
}

.section-heading p:last-child {
  max-width: 720px;
  margin-bottom: 0;
  line-height: 1.6;
}

.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  padding: 6px 10px;
  color: #cbd4df;
  background: rgba(255,255,255,.035);
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.pill.accent,
.pill.succeeded,
.pill.active,
.pill.sandbox {
  color: var(--accent);
  border-color: rgba(100, 244, 182, .25);
  background: var(--accent-soft);
}

.pill.failed {
  color: #ff9494;
  border-color: rgba(255, 114, 114, .25);
  background: rgba(255, 114, 114, .07);
}

.pill.running,
.pill.queued {
  color: var(--warning);
  border-color: rgba(244, 194, 100, .25);
  background: rgba(244, 194, 100, .07);
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.metric-card {
  padding: 20px;
  display: grid;
  gap: 7px;
}

.metric-card span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 650;
}

.metric-card strong {
  font-size: 25px;
  letter-spacing: -0.035em;
}

.metric-card small {
  color: var(--muted-2);
  font-size: 11px;
}

.overview-split {
  margin-top: 14px;
  display: grid;
  grid-template-columns: 1.25fr .75fr;
  gap: 14px;
}

.feature-panel,
.latest-panel {
  padding: 24px;
}

.feature-panel {
  min-height: 310px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.feature-panel p:not(.eyebrow) {
  max-width: 650px;
  color: var(--muted);
  line-height: 1.7;
}

.feature-status,
.feature-actions,
.card-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.feature-actions {
  justify-content: space-between;
  border-top: 1px solid var(--line);
  padding-top: 18px;
}

.card-title-row {
  justify-content: space-between;
  align-items: flex-start;
}

.telemetry-list {
  display: grid;
  gap: 0;
  margin: 24px 0 0;
}

.telemetry-list > div {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 13px 0;
  border-top: 1px solid var(--line);
}

.telemetry-list dt {
  color: var(--muted);
  font-size: 12px;
}

.telemetry-list dd {
  margin: 0;
  font-family: var(--mono);
  font-size: 12px;
}

.agent-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.agent-card {
  padding: 22px;
  min-height: 260px;
  display: flex;
  flex-direction: column;
}

.agent-card .agent-top {
  display: flex;
  justify-content: space-between;
  gap: 14px;
}

.agent-card h2 { margin-top: 18px; }
.agent-card p {
  color: var(--muted);
  line-height: 1.65;
  font-size: 13px;
}

.agent-card footer {
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--muted-2);
  font-size: 11px;
}

.table-panel {
  overflow: hidden;
}

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

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}

th, td {
  padding: 14px 16px;
  text-align: left;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

th {
  color: var(--muted-2);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .09em;
}

td { color: #ccd4de; }
tbody tr:hover { background: rgba(255,255,255,.018); }

.table-button {
  border: 0;
  background: transparent;
  color: var(--accent);
  cursor: pointer;
  font-weight: 700;
  font-size: 11px;
}

.empty-state {
  padding: 42px;
  text-align: center;
  color: var(--muted);
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: 26px;
  background: rgba(0,0,0,.72);
  backdrop-filter: blur(10px);
}

.modal {
  width: min(1080px, 100%);
  max-height: calc(100vh - 52px);
  padding: 22px;
  display: flex;
  flex-direction: column;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.icon-button {
  border: 1px solid var(--line);
  border-radius: 9px;
  width: 36px;
  height: 36px;
  background: rgba(255,255,255,.03);
  color: var(--muted);
  cursor: pointer;
  font-size: 22px;
}

.modal-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin: 6px 0 18px;
  color: var(--muted);
  font-size: 12px;
}

.log-header {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 0;
  border-top: 1px solid var(--line);
}

.run-log {
  margin: 0;
  min-height: 280px;
  max-height: 60vh;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 16px;
  background: #06080b;
  color: #bec9d5;
  font: 11px/1.55 var(--mono);
  white-space: pre-wrap;
  word-break: break-word;
}

@media (max-width: 1050px) {
  .login-shell {
    grid-template-columns: 1fr;
    gap: 42px;
    max-width: 700px;
  }

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

  .sidebar {
    min-height: unset;
    position: static;
  }

  .sidebar nav {
    grid-template-columns: repeat(3, 1fr);
  }

  .sidebar-footer { display: none; }

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

  .overview-split {
    grid-template-columns: 1fr;
  }

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

  .content { padding-right: 0; }
}

@media (max-width: 620px) {
  .login-shell {
    width: min(100% - 28px, 700px);
    padding: 30px 0;
  }

  .brand-block {
    display: grid;
  }

  h1 { font-size: 40px; }

  .topbar {
    height: auto;
    padding: 12px 14px;
  }

  .top-actions {
    flex-wrap: wrap;
    justify-content: flex-end;
  }

  .top-actions .button {
    padding-inline: 12px;
  }

  .locale-switcher button {
    min-width: 30px;
    min-height: 30px;
    padding-inline: 6px;
  }

  .brand-inline span { display: none; }

  .dashboard-grid {
    width: min(100% - 20px, 1500px);
    margin-top: 10px;
  }

  .sidebar { padding: 10px; }
  .account-block { display: none; }
  .sidebar nav { margin-top: 0; }
  .nav-item { text-align: center; font-size: 11px; }

  .section-heading {
    display: grid;
  }

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

  .feature-actions {
    align-items: flex-start;
    flex-direction: column;
  }

  .modal-backdrop { padding: 10px; }
  .modal { max-height: calc(100vh - 20px); }
}


.dashboard::before {
  content: "";
  position: fixed;
  inset: 74px 0 0 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(89,230,189,.015) 1px, transparent 1px),
    linear-gradient(90deg, rgba(89,230,189,.015) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: radial-gradient(circle at 60% 20%, black 0, transparent 72%);
  opacity: .75;
}

.dashboard-masthead {
  min-height: 160px;
  position: relative;
  overflow: hidden;
  margin-bottom: 20px;
  border-color: rgba(89,230,189,.14);
}

.dashboard-masthead-art {
  position: absolute;
  inset: 0;
  background-image: url("/assets/rs-prediction-labs-hero.png");
  background-size: cover;
  background-position: 55% 48%;
  opacity: .28;
  filter: saturate(.88) contrast(1.05);
}

.dashboard-masthead::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(8,10,14,.98) 0%, rgba(8,10,14,.75) 44%, rgba(8,10,14,.20) 100%),
    linear-gradient(0deg, rgba(8,10,14,.5), transparent);
}

.dashboard-masthead-copy,
.dashboard-system {
  position: relative;
  z-index: 2;
}

.dashboard-masthead-copy {
  height: 100%;
  min-height: 160px;
  padding: 26px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 7px;
}

.dashboard-masthead-copy strong {
  max-width: 720px;
  font-family: var(--display);
  font-size: clamp(24px, 3vw, 36px);
  font-weight: 400;
  letter-spacing: -.025em;
}

.dashboard-masthead-copy > span:last-child {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.dashboard-system {
  position: absolute;
  right: 22px;
  top: 20px;
}

.metric-card,
.feature-panel,
.latest-panel,
.agent-card,
.table-panel {
  border-color: rgba(134, 170, 165, .11);
}

.metric-card strong {
  font-family: var(--display);
  font-weight: 400;
}

.topbar {
  border-bottom-color: rgba(89,230,189,.09);
}

.section-heading h1 {
  font-weight: 400;
}

@media (max-width: 1050px) {
  .login-shell.login-v012 {
    grid-template-columns: 1fr;
    width: min(100% - 28px, 1000px);
    padding: 20px 0 28px;
  }

  .login-card {
    max-width: 640px;
  }
}

/* Lab Observer portal - 0.7.1 */

.portal-content {
  min-width: 0;
}

.portal-masthead {
  border-color: rgba(89, 230, 189, .18);
}

.portal-metrics {
  margin-bottom: 14px;
}

.portal-experiment-grid,
.portal-venue-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.portal-experiment-card,
.portal-venue-card,
.portal-detail-card {
  padding: 24px;
  min-width: 0;
}

.portal-card-header,
.portal-venue-card > div {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.portal-card-header h2,
.portal-venue-card h2,
.portal-detail-card h2 {
  margin: 7px 0 0;
  font-size: 22px;
}

.portal-card-metrics {
  margin: 22px 0 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
  background: var(--line);
}

.portal-card-metrics div {
  padding: 13px;
  background: rgba(10, 13, 18, .96);
}

.portal-card-metrics dt {
  color: var(--muted-2);
  font-size: 10px;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.portal-card-metrics dd {
  margin: 6px 0 0;
  color: var(--text);
  font-family: var(--mono);
  font-size: 13px;
}

.portal-experiment-card footer {
  margin-top: 18px;
  color: var(--muted-2);
  font-size: 11px;
}

.portal-disclosure {
  margin: 14px 0 0;
  padding: 18px 22px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}

.portal-two-column {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.portal-detail-card > label {
  display: block;
  margin: 25px 0 8px;
  color: var(--muted);
  font-size: 12px;
}

.portal-detail-card select {
  width: 100%;
  min-height: 44px;
  padding: 0 12px;
  color: var(--text);
  background: #090d12;
  border: 1px solid var(--line);
  border-radius: 9px;
}

.portal-detail-card > .button {
  margin-top: 14px;
}

.portal-check-list {
  margin: 22px 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 12px;
}

.portal-check-list li {
  position: relative;
  padding-left: 24px;
  color: var(--muted);
  line-height: 1.5;
}

.portal-check-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--accent);
}

.portal-event-list {
  margin-top: 18px;
  display: grid;
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--line);
}

.portal-event-list > div {
  padding: 13px 15px;
  background: rgba(10, 13, 18, .96);
}

.portal-event-list strong,
.portal-event-list span {
  display: block;
}

.portal-event-list strong {
  font-size: 13px;
}

.portal-event-list span {
  margin-top: 5px;
  color: var(--muted-2);
  font-family: var(--mono);
  font-size: 10px;
}

.portal-venue-card p {
  min-height: 66px;
  color: var(--muted);
  line-height: 1.6;
}

.portal-venue-card .button:disabled {
  opacity: .42;
  cursor: not-allowed;
}

@media (max-width: 1180px) {
  .portal-experiment-grid,
  .portal-venue-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .portal-experiment-grid,
  .portal-venue-grid,
  .portal-two-column {
    grid-template-columns: 1fr;
  }

  .portal-card-header,
  .portal-venue-card > div {
    align-items: flex-start;
  }
}

@media (max-width: 620px) {
  .login-shell.login-v012 {
    width: min(100% - 16px, 1000px);
    padding: 8px 0 20px;
    gap: 14px;
  }

  .login-hero {
    border-radius: 16px;
  }

  .login-card {
    padding: 26px 22px;
  }

  .auth-locale-switcher {
    top: 16px;
    right: 18px;
  }

  .dashboard-masthead {
    min-height: 132px;
  }

  .dashboard-masthead-copy {
    min-height: 132px;
    padding: 20px;
  }

  .dashboard-system {
    display: none;
  }
}


@media (max-width: 1250px) and (min-width: 1051px) {
  .login-shell.login-v012 {
    grid-template-columns: minmax(0, 1fr) 350px;
    gap: 18px;
    width: min(100% - 28px, 1280px);
  }

  .login-card {
    padding: 28px;
  }
}


/* v0.1.3 — interactive controls embedded in the hero artwork.
   Percent coordinates map directly to the original 1672×941 banner. */
.hero-image-action {
  position: absolute;
  z-index: 6;
  display: block;
  padding: 0;
  border: 1px solid transparent;
  border-radius: 5px;
  background: transparent;
  cursor: pointer;
  outline: none;
  transition:
    background .16s ease,
    box-shadow .16s ease,
    border-color .16s ease,
    transform .16s ease;
}

.hero-image-action-explore {
  left: 4.75%;
  top: 82.70%;
  width: 17.05%;
  height: 5.20%;
}

.hero-image-action-research {
  left: 23.65%;
  top: 82.70%;
  width: 13.45%;
  height: 5.20%;
}

.hero-image-action:hover,
.hero-image-action:focus-visible {
  border-color: rgba(89, 230, 189, .42);
  background: rgba(89, 230, 189, .045);
  box-shadow:
    0 0 0 1px rgba(89, 230, 189, .08) inset,
    0 0 24px rgba(89, 230, 189, .14);
}

.hero-image-action:active {
  transform: translateY(1px);
  background: rgba(89, 230, 189, .075);
}

.hero-image-action-research:hover,
.hero-image-action-research:focus-visible {
  border-color: rgba(210, 223, 224, .28);
  background: rgba(255, 255, 255, .035);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, .05) inset,
    0 0 20px rgba(255, 255, 255, .055);
}

@media (max-width: 620px) {
  .hero-image-action {
    border-radius: 3px;
  }
}


/* Weather.Cal research UI */
.research-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}

.research-back {
  border: 0;
  padding: 0;
  margin: 0 0 16px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}

.research-back:hover {
  color: #e8f1f2;
}

.weather-research-card {
  cursor: pointer;
  transition: transform .16s ease, border-color .16s ease, background .16s ease;
}

.weather-research-card:hover,
.weather-research-card:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(89,230,189,.28);
  background: rgba(89,230,189,.025);
  outline: none;
}

.research-metrics {
  margin-bottom: 14px;
}

.research-split {
  margin-top: 0;
  margin-bottom: 14px;
}

.research-table {
  margin-top: 14px;
}

.research-table-head {
  padding: 20px 22px 16px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  border-bottom: 1px solid var(--line);
}

.research-table-head h2 {
  margin: 4px 0 0;
}

.research-empty {
  padding: 28px 22px;
  color: var(--muted);
  font-size: 12px;
}

.research-positive {
  color: #59e6bd;
  font-family: var(--mono);
}

.research-negative {
  color: #ff8791;
  font-family: var(--mono);
}

@media (max-width: 620px) {
  .research-actions,
  .research-table-head {
    align-items: flex-start;
    flex-direction: column;
  }
}

/* Weather.Cal explicit research action */
.weather-research-card .weather-research-cta {
  margin-top: 14px;
  padding-top: 13px;
  border-top: 1px solid rgba(89,230,189,.14);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #8df0d4;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.weather-research-card .weather-research-cta span:last-child {
  font-size: 16px;
  line-height: 1;
  transition: transform .16s ease;
}
.weather-research-card:hover .weather-research-cta span:last-child,
.weather-research-card:focus-visible .weather-research-cta span:last-child {
  transform: translateX(4px);
}
.weather-research-card:hover .weather-research-cta,
.weather-research-card:focus-visible .weather-research-cta {
  color: #b8f8e6;
}

/* Weather.Cal stronger interaction affordance */
.weather-research-card,
.weather-research-card * {
  cursor: pointer !important;
  user-select: none;
}

.weather-research-card {
  position: relative;
  border-color: rgba(89,230,189,.18) !important;
  transition:
    transform .18s ease,
    border-color .18s ease,
    box-shadow .18s ease,
    background .18s ease;
}

.weather-research-card::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  opacity: 0;
  box-shadow:
    0 0 0 1px rgba(89,230,189,.18) inset,
    0 12px 32px rgba(0,0,0,.22),
    0 0 28px rgba(89,230,189,.07);
  transition: opacity .18s ease;
}

.weather-research-card:hover,
.weather-research-card:focus-visible {
  transform: translateY(-4px);
  border-color: rgba(89,230,189,.52) !important;
  background: linear-gradient(
    180deg,
    rgba(89,230,189,.055),
    rgba(89,230,189,.018)
  );
}

.weather-research-card:hover::after,
.weather-research-card:focus-visible::after {
  opacity: 1;
}

.weather-research-card .weather-research-cta {
  margin-top: 14px;
  padding: 11px 12px;
  border: 1px solid rgba(89,230,189,.22);
  border-radius: 8px;
  background: rgba(89,230,189,.055);
  color: #8df0d4;
  transition:
    border-color .18s ease,
    background .18s ease,
    color .18s ease;
}

.weather-research-card:hover .weather-research-cta,
.weather-research-card:focus-visible .weather-research-cta {
  border-color: rgba(89,230,189,.52);
  background: rgba(89,230,189,.11);
  color: #c4ffef;
}

/* Weather.Cal grouped signal history */
.research-signal-summary-row {
  cursor: pointer;
  transition: background-color 140ms ease;
}
.research-signal-summary-row:hover,
.research-signal-summary-row:focus-visible {
  background: rgba(255, 255, 255, 0.035);
  outline: none;
}
.research-signal-summary-row td {
  vertical-align: middle;
}
.research-signal-market {
  max-width: 440px;
}
.research-signal-chevron {
  display: inline-block;
  margin-right: 8px;
  font-size: 18px;
  line-height: 1;
  transition: transform 140ms ease;
}
.research-signal-summary-row.is-open .research-signal-chevron {
  transform: rotate(90deg);
}
.research-signal-observation-count {
  font-variant-numeric: tabular-nums;
  opacity: 0.72;
  white-space: nowrap;
}
.research-signal-detail-row > td {
  padding: 0 !important;
  border-top: 0 !important;
}
.research-signal-detail-wrap {
  margin: 0 12px 14px;
  padding: 12px 14px 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.14);
}
.research-signal-detail-header {
  margin-bottom: 9px;
  font-size: 12px;
  opacity: 0.65;
  letter-spacing: 0.02em;
}
.research-signal-detail-scroller {
  overflow-x: auto;
}
.research-signal-detail-table {
  width: 100%;
  min-width: 620px;
  border-collapse: collapse;
  font-size: 12px;
}
.research-signal-detail-table th,
.research-signal-detail-table td {
  padding: 8px 10px;
  text-align: left;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.research-signal-detail-table th {
  font-size: 11px;
  font-weight: 600;
  opacity: 0.55;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.research-signal-detail-table tbody tr:last-child td {
  border-bottom: 0;
}

/* Weather.Cal experiment health — static shell */
.research-health-strip {
  display: grid;
  grid-template-columns: 1.25fr 1fr 1fr 1fr;
  gap: 1px;
  margin: 0 0 16px;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--border);
}

.research-health-item {
  min-width: 0;
  padding: 14px 16px;
  background: var(--panel);
}

.research-health-label {
  display: block;
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.research-health-value {
  display: block;
  overflow: hidden;
  color: var(--text);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.research-health-primary .research-health-value::before {
  content: "";
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 8px;
  border-radius: 50%;
  vertical-align: 1px;
  background: var(--muted);
}

@media (max-width: 980px) {
  .research-health-strip {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 620px) {
  .research-health-strip {
    grid-template-columns: 1fr;
  }
}

/* Weather.Cal semantic health colors */
#research-health-strip[data-health="healthy"] .research-health-primary .research-health-value {
  color: #5fe0b7;
}
#research-health-strip[data-health="healthy"] .research-health-primary .research-health-value::before {
  background: #5fe0b7;
}

#research-health-strip[data-health="degraded"] .research-health-primary .research-health-value,
#research-health-strip[data-health="starting"] .research-health-primary .research-health-value {
  color: #e9bd65;
}
#research-health-strip[data-health="degraded"] .research-health-primary .research-health-value::before,
#research-health-strip[data-health="starting"] .research-health-primary .research-health-value::before {
  background: #e9bd65;
}

#research-health-strip[data-health="stopped"] .research-health-primary .research-health-value {
  color: #f06f72;
}
#research-health-strip[data-health="stopped"] .research-health-primary .research-health-value::before {
  background: #f06f72;
}


/* Frontend v0.2.0 — Weather.Cal v0.8 Autopilot research dashboard */

.weather-version-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 240px));
  gap: 10px;
  margin: 0 0 18px;
}
.weather-version-tab {
  min-width: 0;
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  column-gap: 10px;
  row-gap: 2px;
  padding: 13px 15px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255,255,255,.018);
  color: var(--muted);
  text-align: left;
  cursor: pointer;
  transition: border-color .16s ease, background .16s ease, transform .16s ease;
}
.weather-version-tab > span {
  grid-row: 1 / 3;
  align-self: center;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--muted-2);
}
.weather-version-tab strong { font-size: 13px; color: #dce5ec; }
.weather-version-tab small {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 10px;
  color: var(--muted-2);
}
.weather-version-tab:hover,
.weather-version-tab:focus-visible {
  border-color: rgba(89,230,189,.28);
  outline: none;
  transform: translateY(-1px);
}
.weather-version-tab.active {
  border-color: rgba(89,230,189,.42);
  background: rgba(89,230,189,.065);
  box-shadow: 0 0 24px rgba(89,230,189,.045);
}
.weather-version-tab.active > span,
.weather-version-tab.active strong { color: var(--accent); }
.live-dot {
  width: 6px;
  height: 6px;
  display: inline-block;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 10px rgba(89,230,189,.8);
}
.weather-version-panel { animation: enter .16s ease-out; }

.v08-status-strip {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr 1fr;
  gap: 1px;
  margin-bottom: 14px;
  overflow: hidden;
  padding: 0;
  background: rgba(255,255,255,.065);
}
.v08-status-strip > div {
  min-width: 0;
  padding: 15px 17px;
  background: linear-gradient(180deg, rgba(17,22,30,.98), rgba(12,16,22,.98));
}
.v08-status-strip span {
  display: block;
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.v08-status-strip strong {
  display: block;
  overflow: hidden;
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.v08-status-primary strong::before {
  content: "";
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 8px;
  border-radius: 50%;
  background: var(--muted);
  vertical-align: 1px;
}
.v08-status-strip[data-health="healthy"] .v08-status-primary strong { color: var(--success); }
.v08-status-strip[data-health="healthy"] .v08-status-primary strong::before {
  background: var(--success);
  box-shadow: 0 0 10px rgba(89,230,189,.65);
}
.v08-status-strip[data-health="degraded"] .v08-status-primary strong,
.v08-status-strip[data-health="starting"] .v08-status-primary strong { color: var(--warning); }
.v08-status-strip[data-health="degraded"] .v08-status-primary strong::before,
.v08-status-strip[data-health="starting"] .v08-status-primary strong::before { background: var(--warning); }

.v08-two-column {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-bottom: 14px;
}
.v08-card { min-height: 315px; padding: 22px; }
.v08-reason-list { display: grid; gap: 15px; margin-top: 22px; }
.v08-reason-row { display: grid; gap: 7px; }
.v08-reason-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  font-size: 11px;
}
.v08-reason-head span { color: #c9d2dc; }
.v08-reason-head strong {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 10px;
}
.v08-reason-track {
  height: 5px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255,255,255,.055);
}
.v08-reason-track i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, rgba(89,230,189,.55), rgba(89,230,189,.95));
  box-shadow: 0 0 10px rgba(89,230,189,.16);
}
.v08-pipeline-list { margin-top: 16px; }
.v08-market-panel { margin-top: 0; }
.v08-table-copy {
  max-width: 680px;
  margin: 7px 0 0;
  font-size: 11px;
  line-height: 1.55;
}
.v08-market-table { min-width: 1180px; }
.v08-market-row td { vertical-align: middle; }
.v08-market-question {
  width: 330px;
  max-width: 330px;
  white-space: normal;
}
.v08-market-question strong,
.v08-market-question span { display: block; }
.v08-market-question strong {
  margin-bottom: 4px;
  color: #e7edf3;
  font-size: 11px;
}
.v08-market-question span {
  color: var(--muted);
  font-size: 10px;
  line-height: 1.45;
}
.v08-model-summary {
  max-width: 270px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 10px;
  white-space: normal;
  line-height: 1.5;
}
.v08-safety-note {
  margin: 14px 2px 0;
  color: var(--muted-2);
  font-family: var(--mono);
  font-size: 9px;
  line-height: 1.6;
  letter-spacing: .02em;
}
.v08-market-modal-card {
  width: min(1240px, 100%);
  overflow-y: auto;
}
.v08-detail-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}
.v08-detail-block {
  display: grid;
  gap: 6px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: rgba(255,255,255,.022);
}
.v08-detail-block span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.v08-detail-block strong {
  font-family: var(--display);
  font-size: 25px;
  font-weight: 400;
}
.v08-detail-block small {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 10px;
}
.v08-detail-section {
  margin-top: 12px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(0,0,0,.10);
}
.v08-detail-heading { padding-top: 15px; padding-bottom: 12px; }
.v08-model-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  padding: 14px;
}
.v08-model-card {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255,255,255,.02);
}
.v08-model-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.v08-model-card-head strong { font-size: 11px; }
.v08-model-card b {
  font-family: var(--display);
  font-size: 24px;
  font-weight: 400;
}
.v08-model-card small { color: var(--muted); font-size: 10px; }

@media (max-width: 980px) {
  .v08-status-strip,
  .v08-two-column { grid-template-columns: 1fr 1fr; }
  .v08-model-grid { grid-template-columns: 1fr; }
}
@media (max-width: 620px) {
  .weather-version-tabs,
  .v08-status-strip,
  .v08-two-column,
  .v08-detail-grid { grid-template-columns: 1fr; }
  .weather-version-tabs { max-width: none; }
  .v08-market-modal-card { padding: 16px; }
}

/* Weather.Cal v0.8 Paper Trading */

.weather-version-tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.paper-version-tab {
  position: relative;
  overflow: hidden;
}

.paper-version-tab::after {
  content: "";
  position: absolute;
  inset: auto 14px 0 14px;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(89, 230, 189, .58),
    transparent
  );
  opacity: .45;
}

.paper-version-tab.active {
  border-color: rgba(89, 230, 189, .48);
  background:
    linear-gradient(
      180deg,
      rgba(89, 230, 189, .10),
      rgba(89, 230, 189, .025)
    );
  box-shadow:
    inset 0 0 0 1px rgba(89, 230, 189, .05),
    0 16px 42px rgba(0, 0, 0, .18);
}

.paper-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 5px;
  border-radius: 50%;
  background: var(--warning);
  box-shadow: 0 0 10px rgba(244, 194, 100, .62);
  vertical-align: 1px;
}

.paper-status-strip {
  display: grid;
  grid-template-columns:
    minmax(0, 1.2fr)
    minmax(0, 1fr)
    minmax(0, 1fr);
  gap: 1px;
  margin-bottom: 14px;
  overflow: hidden;
  border-color: rgba(89, 230, 189, .15);
}

.paper-status-strip > div {
  min-width: 0;
  padding: 18px 20px;
  display: grid;
  gap: 6px;
  background: rgba(255, 255, 255, .012);
}

.paper-status-strip span {
  color: var(--muted);
  font-size: 10px;
  font-weight: 650;
  letter-spacing: .09em;
  text-transform: uppercase;
}

.paper-status-strip strong {
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 650;
  letter-spacing: .02em;
}

.paper-control-panel {
  margin-bottom: 14px;
  padding: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  border-color: rgba(89, 230, 189, .15);
  background:
    radial-gradient(
      circle at 80% 30%,
      rgba(89, 230, 189, .055),
      transparent 34%
    ),
    linear-gradient(
      180deg,
      rgba(21, 27, 36, .94),
      rgba(13, 17, 23, .94)
    );
}

.paper-control-copy {
  min-width: 0;
  max-width: 720px;
}

.paper-control-copy h2 {
  margin: 5px 0 8px;
}

.paper-control-copy p:last-child {
  line-height: 1.65;
}

.paper-control-actions {
  display: flex;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 9px;
}

.paper-control-actions .button {
  min-width: 112px;
}

.button.paper-danger {
  border-color: rgba(255, 114, 114, .28);
  color: #ffaaaa;
  background: rgba(255, 114, 114, .045);
}

.button.paper-danger:hover:not(:disabled) {
  border-color: rgba(255, 114, 114, .58);
  background: rgba(255, 114, 114, .10);
}

.paper-metrics {
  margin-bottom: 14px;
}

.paper-metrics .metric-card {
  min-height: 122px;
}

.paper-metrics .metric-card strong {
  font-family: var(--display);
}

.paper-detail-grid {
  display: grid;
  grid-template-columns:
    repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 14px;
}

.paper-detail-panel {
  min-width: 0;
  padding: 24px;
}

.paper-detail-panel .telemetry-list {
  margin-top: 18px;
}

.paper-window-panel {
  margin-top: 0;
}

.paper-window-panel tbody td:first-child {
  font-family: var(--mono);
  color: var(--accent);
}

.paper-window-panel tbody td:nth-child(4),
.paper-window-panel tbody td:nth-child(5) {
  font-family: var(--mono);
  font-size: 11px;
}

.paper-safety-note {
  margin-top: 14px;
  border-color: rgba(244, 194, 100, .14);
  background: rgba(244, 194, 100, .025);
}

#paper-run-status.armed {
  color: var(--warning);
  border-color: rgba(244, 194, 100, .30);
  background: rgba(244, 194, 100, .07);
}

#paper-run-status.running {
  color: var(--success);
  border-color: rgba(89, 230, 189, .32);
  background: rgba(89, 230, 189, .075);
}

#paper-run-status.paused {
  color: var(--warning);
  border-color: rgba(244, 194, 100, .28);
  background: rgba(244, 194, 100, .065);
}

#paper-run-status.stopped {
  color: var(--danger);
  border-color: rgba(255, 114, 114, .26);
  background: rgba(255, 114, 114, .06);
}

#weather-paper-panel .empty-state {
  padding: 28px 22px;
}

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

.auth-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 18px;
}

.text-button {
  border: 0;
  padding: 4px 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font-size: 12px;
  font-weight: 650;
  text-align: left;
}

.text-button:hover,
.text-button:focus-visible {
  color: var(--text);
}

.text-button.accent {
  color: var(--accent);
  text-align: right;
}

.auth-back {
  display: block;
  margin-top: 18px;
}

.checkbox-label {
  grid-template-columns: 18px minmax(0, 1fr);
  align-items: start;
  gap: 10px;
  color: var(--muted);
  font-weight: 400;
  line-height: 1.5;
}

.checkbox-label input {
  width: 16px;
  height: 16px;
  margin: 2px 0 0;
  accent-color: var(--accent);
}

.checkbox-label a,
.support-link {
  color: var(--accent);
}

label small {
  color: var(--muted-2);
  font-size: 11px;
  font-weight: 400;
}

.support-link {
  display: block;
  margin-top: 24px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  font-size: 11px;
  text-decoration: none;
}

.support-link:hover,
.support-link:focus-visible {
  text-decoration: underline;
}

#section-weather-research .weather-version-tabs {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.portfolio-comparison-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.portfolio-compare-card {
  min-width: 0;
  padding: 24px;
}

.portfolio-compare-card.dynamic {
  border-color: rgba(89, 230, 189, .22);
  background:
    linear-gradient(145deg, rgba(89, 230, 189, .045), transparent 58%),
    var(--panel);
}

.portfolio-compare-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 20px;
}

.portfolio-compare-metrics div {
  display: grid;
  gap: 5px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255, 255, 255, .018);
}

.portfolio-compare-metrics span {
  color: var(--muted-2);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .08em;
}

.portfolio-compare-metrics strong {
  color: var(--text);
  font-family: var(--display);
  font-size: 18px;
}

.portfolio-run-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  max-width: 760px;
  margin: 0 0 18px;
}

.portfolio-run-panel,
#weather-paper-panel {
  animation: enter .18s ease-out;
}

#paper-run001-host:empty {
  display: none;
}

#sizing-run-status.running,
#portfolio-run002-status.running {
  color: var(--success);
  border-color: rgba(89, 230, 189, .32);
  background: rgba(89, 230, 189, .075);
}

@media (max-width: 980px) {
  .weather-version-tabs {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

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

  .paper-control-actions {
    justify-content: flex-start;
  }

  .paper-status-strip {
    grid-template-columns: 1fr;
  }

  .portfolio-comparison-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 700px) {
  .weather-version-tabs {
    grid-template-columns: 1fr;
  }

  .paper-detail-grid {
    grid-template-columns: 1fr;
  }

  #section-weather-research .weather-version-tabs,
  .portfolio-run-tabs,
  .portfolio-compare-metrics {
    grid-template-columns: 1fr;
  }

  .paper-control-actions {
    width: 100%;
    display: grid;
    grid-template-columns:
      repeat(2, minmax(0, 1fr));
  }

  .paper-control-actions .button {
    width: 100%;
    min-width: 0;
  }
}

@media (max-width: 460px) {
  .paper-control-actions {
    grid-template-columns: 1fr;
  }

  .paper-control-panel,
  .paper-detail-panel {
    padding: 19px;
  }
}

/* Weather.Cal paper portfolios - 0.5.1 monitor */

.paper-performance-metrics {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.paper-performance-metrics .metric-card {
  min-width: 0;
  min-height: 126px;
}

.paper-performance-metrics .metric-card strong {
  font-size: clamp(24px, 2.2vw, 34px);
  letter-spacing: -.025em;
}

.paper-performance-metrics .metric-card small {
  line-height: 1.45;
}

.paper-activity-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 14px;
}

.paper-activity-card {
  min-width: 0;
  min-height: 104px;
  padding: 20px 22px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.paper-activity-card > span {
  color: var(--muted);
  font-size: 12px;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.paper-activity-card strong {
  margin-top: 7px;
  font-family: var(--display);
  font-size: 28px;
  line-height: 1;
}

.paper-activity-card small {
  margin-top: 8px;
  color: var(--muted);
}

.paper-monitor-table {
  margin-top: 14px;
}

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

.paper-monitor-table table {
  min-width: 920px;
}

.paper-monitor-table th,
.paper-monitor-table td {
  vertical-align: middle;
}

.paper-monitor-table th {
  white-space: nowrap;
}

.paper-monitor-table td {
  white-space: nowrap;
}

.paper-monitor-table td:nth-child(2) {
  min-width: 250px;
  white-space: normal;
  line-height: 1.45;
}

.paper-monitor-table tbody tr:last-child td {
  border-bottom: 0;
}

.paper-monitor-table .empty-state {
  padding: 26px 22px;
}

/*
 * Lifecycle controls:
 * inactive actions must look inactive.
 * In ARMED state Start is therefore the obvious primary action.
 */
.paper-control-actions .button:disabled {
  opacity: .34;
  cursor: not-allowed;
  filter: saturate(.35);
  box-shadow: none;
}

#paper-pause:disabled,
#paper-resume:disabled {
  color: var(--muted);
  border-color: var(--line);
  background: transparent;
}

#paper-start:not(:disabled) {
  opacity: 1;
}

#paper-stop:not(:disabled) {
  opacity: 1;
}

/* Long market questions must remain readable. */
#paper-position-body td:first-child,
#paper-signal-body td:nth-child(2),
#paper-execution-body td:nth-child(2),
#paper-settlement-body td:nth-child(2) {
  min-width: 280px;
  max-width: 420px;
  white-space: normal;
  line-height: 1.45;
}

/* Audit data benefits from monospace identifiers/states. */
#paper-event-body td:first-child,
#paper-event-body td:nth-child(3),
#paper-event-body td:nth-child(4),
#paper-event-body td:nth-child(5),
#paper-event-body td:nth-child(6) {
  font-family: var(--mono);
  font-size: 11px;
}

@media (max-width: 1180px) {
  .paper-performance-metrics,
  .paper-activity-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 620px) {
  .paper-performance-metrics,
  .paper-activity-grid {
    grid-template-columns: 1fr;
  }

  .paper-performance-metrics .metric-card,
  .paper-activity-card {
    min-height: 0;
  }
}

.adaptive-run {padding:24px;margin:20px 0;min-width:0;}
.adaptive-run summary {cursor:pointer;font-weight:600;padding:12px 0;}
.adaptive-run p {overflow-wrap:anywhere;}
.adaptive-decision {border-top:1px solid var(--border, #263449);padding:14px 0;}
.adaptive-decision h3 {font-size:15px;}
#adaptive-paper {margin-bottom:28px;}
.run-workspace {max-width:1440px;margin:0 auto;min-width:0;}
.member-run-workspace {width:100%;display:block;}
.member-run-card {margin:18px 0;}
.run-intro {max-width:880px;color:var(--text-muted,#a4b1c4);line-height:1.7;margin:12px 0 20px;}
.run-status {font-size:12px;color:var(--text-muted,#a4b1c4);border-left:3px solid #6caeb0;padding:8px 12px;margin-bottom:24px;}
.run-selector {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;margin:20px 0;}
.run-choice {display:flex;flex-direction:column;gap:10px;text-align:left;border:1px solid var(--border,#293645);border-radius:14px;padding:22px;background:rgba(16,29,43,.6);color:inherit;cursor:pointer;min-width:0;}
.run-choice[aria-pressed="true"] {border-color:#71beb6;background:linear-gradient(125deg,rgba(62,122,120,.2),rgba(21,34,48,.7));box-shadow:inset 0 0 0 1px rgba(113,190,182,.2);}
.run-choice strong {font-size:20px;overflow-wrap:anywhere;}
.run-choice small,.run-metric small,.run-footnote {color:var(--text-muted,#a4b1c4);font-size:12px;line-height:1.6;}
.run-detail {padding:26px;min-width:0;}
.run-detail h2 {margin-top:0;font-size:22px;}
.run-metrics {display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin:24px 0 12px;}
.run-metric {padding:18px;border:1px solid var(--border,#293645);border-radius:10px;display:flex;flex-direction:column;gap:12px;min-width:0;}
.run-metric>span {font-size:12px;color:var(--text-muted,#a4b1c4);}
.run-metric strong {font-size:21px;font-variant-numeric:tabular-nums;overflow-wrap:anywhere;}
.run-positive strong,td.run-positive {color:#8dd0b4;}
.run-negative strong,td.run-negative {color:#f0a7a7;}
.run-controls {display:flex;flex-wrap:wrap;gap:8px;margin:22px 0;}
.run-tabs {display:flex;gap:20px;overflow-x:auto;border-bottom:1px solid var(--border,#293645);margin-top:24px;}
.run-tab {background:none;color:var(--text-muted,#a4b1c4);border:0;border-bottom:2px solid transparent;white-space:nowrap;padding:16px 0;font:inherit;cursor:pointer;}
.run-tab[aria-selected="true"] {color:#a2dbd0;border-bottom-color:#a2dbd0;}
.run-table-region,.run-table-scroll {min-width:0;max-width:100%;}
.run-table-scroll {overflow-x:auto;}
.run-table {width:100%;border-collapse:collapse;font-size:13px;}
.run-table th,.run-table td {padding:18px 12px;border-bottom:1px solid var(--border,#293645);text-align:left;vertical-align:top;}
.run-table th {font-size:11px;font-weight:500;color:var(--text-muted,#a4b1c4);white-space:normal;}
.run-table td:first-child {min-width:115px;}
.run-table td:nth-child(2) {min-width:210px;max-width:360px;white-space:normal;line-height:1.55;}
.run-table td small {display:block;color:var(--text-muted,#a4b1c4);margin-top:7px;}
.run-evidence {min-width:190px;max-width:350px;white-space:normal;line-height:1.6;}
.run-workspace summary {cursor:pointer;line-height:1.6;}
.run-workspace p {overflow-wrap:anywhere;}
.run-empty {padding:36px 12px;color:var(--text-muted,#a4b1c4);line-height:1.6;}
.run-learning {padding:22px 26px;margin:20px 0;}
.run-learning>summary {font-weight:600;}
.run-learning details,.run-reasons {border-top:1px solid var(--border,#293645);padding:16px 0;}
.run-footnote {margin:16px 0 0;overflow-wrap:anywhere;}
.run-workspace button:focus-visible,.run-workspace summary:focus-visible {outline:2px solid #a2dbd0;outline-offset:4px;}
#legacy-paper-host[hidden] {display:none!important;}
@media(max-width:1100px){.run-metrics{grid-template-columns:repeat(2,minmax(0,1fr));}}
@media(max-width:620px){.run-selector{grid-template-columns:1fr;gap:10px;}.run-choice{padding:18px;}.run-detail,.run-learning{padding:18px;}.run-metrics{gap:8px;}.run-metric{padding:12px;}.run-metric strong{font-size:17px;}.run-tabs{gap:18px;font-size:13px;}}
@media(max-width:600px){.adaptive-run{padding:16px;} .adaptive-run .paper-control-actions{flex-wrap:wrap;}}
