/* Sovereign LM — v0 journey lab mockup suite */
@import url('https://fonts.googleapis.com/css2?family=Instrument+Serif:ital@0;1&family=Source+Sans+3:ital,wght@0,400;0,600;0,700;1,400&family=Source+Code+Pro:wght@400;500&display=swap');

:root {
  --bg0: #0c1118;
  --bg1: #121a24;
  --bg2: #182232;
  --panel: rgba(18, 26, 36, 0.92);
  --line: rgba(232, 196, 140, 0.18);
  --text: #e8eef6;
  --muted: #93a4b8;
  --amber: #e8c48c;
  --amber-hot: #f0d4a8;
  --teal: #5ec4b0;
  --danger: #e88a7a;
  --ok: #7dcea0;
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
  --radius: 14px;
  --font-display: "Instrument Serif", Georgia, serif;
  --font-ui: "Source Sans 3", "Segoe UI", sans-serif;
  --font-code: "Source Code Pro", ui-monospace, monospace;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  font-family: var(--font-ui);
  color: var(--text);
  background:
    radial-gradient(1200px 700px at 12% -10%, rgba(232, 196, 140, 0.14), transparent 55%),
    radial-gradient(900px 600px at 88% 8%, rgba(94, 196, 176, 0.10), transparent 50%),
    linear-gradient(165deg, var(--bg0), var(--bg1) 45%, #0a0f15);
  line-height: 1.5;
}

a { color: var(--amber); }
a:hover { color: var(--amber-hot); }

.slm-mock-banner {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  padding: 0.55rem 1.25rem;
  background: rgba(8, 12, 18, 0.88);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(10px);
  font-size: 0.85rem;
  color: var(--muted);
}
.slm-mock-banner strong { color: var(--amber); font-weight: 600; }
.slm-mock-banner a { margin-left: 0.85rem; text-decoration: none; border-bottom: 1px solid transparent; }
.slm-mock-banner a:hover { border-bottom-color: var(--amber); }
.slm-mock-banner a.is-active { color: var(--amber-hot); border-bottom-color: var(--amber); }

.slm-shell {
  max-width: 1280px;
  margin: 0 auto;
  padding: 1.25rem 1.25rem 3rem;
}

.slm-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1.25rem;
}
.slm-brand {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}
.slm-brand .name {
  font-family: var(--font-display);
  font-size: 1.85rem;
  letter-spacing: 0.01em;
  color: var(--amber-hot);
  line-height: 1.1;
}
.slm-brand .tag {
  color: var(--muted);
  font-size: 0.92rem;
}
.slm-nav-pills {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
}
.slm-nav-pills a {
  text-decoration: none;
  color: var(--muted);
  border: 1px solid var(--line);
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  font-size: 0.88rem;
  background: rgba(255,255,255,0.02);
}
.slm-nav-pills a:hover,
.slm-nav-pills a.is-active {
  color: var(--bg0);
  background: var(--amber);
  border-color: var(--amber);
}

.slm-crumb {
  color: var(--muted);
  font-size: 0.9rem;
  margin: 0 0 1rem;
}
.slm-crumb strong { color: var(--text); font-weight: 600; }

.slm-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(280px, 0.85fr);
  gap: 1.1rem;
  align-items: start;
}
@media (max-width: 960px) {
  .slm-layout { grid-template-columns: 1fr; }
}

.slm-panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.15rem 1.25rem;
}
.slm-panel h1 {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 400;
  margin: 0 0 0.35rem;
  color: var(--text);
}
.slm-panel h2 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 400;
  margin: 1.35rem 0 0.55rem;
  color: var(--amber-hot);
}
.slm-panel h3 {
  margin: 1rem 0 0.4rem;
  font-size: 0.95rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--teal);
  font-weight: 700;
}
.slm-lede { color: var(--muted); margin: 0 0 1rem; max-width: 62ch; }
.slm-bullets { margin: 0.4rem 0 0.8rem; padding-left: 1.2rem; color: var(--text); }
.slm-bullets li { margin: 0.25rem 0; }

.slm-fulltext {
  color: var(--text);
  border-left: 2px solid rgba(94, 196, 176, 0.35);
  padding-left: 0.9rem;
  margin: 0.75rem 0;
}
.slm-fulltext p { margin: 0.55rem 0; color: #c9d5e4; }

.slm-code {
  margin: 0.75rem 0 0;
  background: #070b10;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 10px;
  overflow: auto;
  max-height: 280px;
}
.slm-code .bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.45rem 0.75rem;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  color: var(--muted);
  font-size: 0.8rem;
  font-family: var(--font-code);
}
.slm-code pre {
  margin: 0;
  padding: 0.9rem 1rem 1.1rem;
  font-family: var(--font-code);
  font-size: 0.82rem;
  line-height: 1.45;
  color: #d7e2ef;
}

.slm-run-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-top: 1rem;
}
.slm-btn {
  appearance: none;
  border: none;
  cursor: pointer;
  font-family: var(--font-ui);
  font-weight: 700;
  font-size: 0.95rem;
  padding: 0.65rem 1.2rem;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--amber-hot), #c9964e);
  color: #1a1208;
  box-shadow: 0 8px 24px rgba(232, 196, 140, 0.25);
}
.slm-btn:hover { filter: brightness(1.05); }
.slm-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  filter: none;
  box-shadow: none;
}
.slm-btn-ghost {
  background: transparent;
  color: var(--muted);
  border: 1px solid var(--line);
  box-shadow: none;
}
.slm-meta {
  color: var(--muted);
  font-size: 0.88rem;
}
.slm-meta b { color: var(--teal); font-weight: 600; }

.slm-output {
  margin-top: 1rem;
  background: #070b10;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 10px;
  min-height: 140px;
  padding: 0.75rem 0.9rem;
  font-family: var(--font-code);
  font-size: 0.8rem;
  color: #b7c7d8;
  white-space: pre-wrap;
}
.slm-output .phase { color: var(--teal); }
.slm-output .ok { color: var(--ok); }

.slm-tutor h2 { margin-top: 0; }
.slm-chat {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  max-height: 420px;
  overflow: auto;
  margin: 0.75rem 0 1rem;
  padding-right: 0.25rem;
}
.slm-bubble {
  border-radius: 12px;
  padding: 0.65rem 0.8rem;
  font-size: 0.92rem;
  max-width: 95%;
}
.slm-bubble.user {
  align-self: flex-end;
  background: rgba(232, 196, 140, 0.15);
  border: 1px solid rgba(232, 196, 140, 0.28);
}
.slm-bubble.assistant {
  align-self: flex-start;
  background: rgba(94, 196, 176, 0.08);
  border: 1px solid rgba(94, 196, 176, 0.22);
}
.slm-tutor-form {
  display: flex;
  gap: 0.5rem;
}
.slm-tutor-form input {
  flex: 1;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #0a1018;
  color: var(--text);
  padding: 0.65rem 0.9rem;
  font-family: var(--font-ui);
  font-size: 0.92rem;
}
.slm-tutor-form input:focus {
  outline: 2px solid rgba(232, 196, 140, 0.35);
  border-color: var(--amber);
}

.slm-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
}
.slm-table th,
.slm-table td {
  text-align: left;
  padding: 0.65rem 0.5rem;
  border-bottom: 1px solid var(--line);
}
.slm-table th { color: var(--muted); font-weight: 600; font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.04em; }
.slm-table a { text-decoration: none; }
.slm-badge {
  display: inline-block;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
}
.slm-badge.ready { background: rgba(125, 206, 160, 0.18); color: var(--ok); }
.slm-badge.stub { background: rgba(147, 164, 184, 0.15); color: var(--muted); }
.slm-badge.running { background: rgba(94, 196, 176, 0.18); color: var(--teal); }
.slm-badge.done { background: rgba(232, 196, 140, 0.18); color: var(--amber); }

/* Poster */
.slm-poster {
  min-height: calc(100vh - 42px);
  display: grid;
  place-items: center;
  padding: 2rem 1.25rem 3rem;
  position: relative;
  overflow: hidden;
}
.slm-poster::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(120deg, rgba(12,17,24,0.55), rgba(12,17,24,0.82)),
    radial-gradient(circle at 30% 40%, rgba(232,196,140,0.2), transparent 45%),
    radial-gradient(circle at 70% 60%, rgba(94,196,176,0.15), transparent 40%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160' viewBox='0 0 160 160'%3E%3Cpath fill='none' stroke='%23e8c48c' stroke-opacity='0.07' d='M0 80h160M80 0v160'/%3E%3C/svg%3E");
  z-index: 0;
}
.slm-poster-inner {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 720px;
}
.slm-poster-inner .name {
  font-family: var(--font-display);
  font-size: clamp(3rem, 8vw, 5rem);
  color: var(--amber-hot);
  margin: 0;
  line-height: 1;
}
.slm-poster-inner .headline {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 3vw, 2rem);
  margin: 1rem 0 0.75rem;
  font-weight: 400;
}
.slm-poster-inner .support {
  color: var(--muted);
  margin: 0 auto 1.75rem;
  max-width: 42ch;
  font-size: 1.05rem;
}
.slm-poster-actions { display: flex; gap: 0.75rem; justify-content: center; flex-wrap: wrap; }

.slm-footer-note {
  margin-top: 1.5rem;
  color: var(--muted);
  font-size: 0.82rem;
}

.slm-flash { padding: 0.65rem 0.85rem; border-radius: 10px; margin: 0.75rem 0; }
.slm-flash.err { background: rgba(232,138,122,0.15); border: 1px solid rgba(232,138,122,0.35); color: #f0c4bc; }
.slm-flash.ok { background: rgba(125,206,160,0.12); border: 1px solid rgba(125,206,160,0.3); color: var(--ok); }
.slm-inline-status { font-size: 0.85rem; color: var(--muted); }
