/* ============================================
   LANDING PAGE ONLY (public_html/index.php)
   Everything is scoped under .lp / lp-* so nothing
   leaks into the dashboard, panel, commands or error pages.
   ============================================ */

.lp {
  --lp-red: #c65050;
  --lp-red-hi: #e87272;
  --lp-red-soft: rgba(198, 80, 80, 0.14);
  --lp-red-line: rgba(198, 80, 80, 0.35);
  --lp-red-glow: rgba(198, 80, 80, 0.45);
  --lp-text: #ececf1;
  --lp-muted: #9a9cab;
  --lp-surface: rgba(255, 255, 255, 0.03);
  --lp-surface-2: rgba(255, 255, 255, 0.055);
  --lp-line: rgba(255, 255, 255, 0.08);
  --lp-body-font: "Inter", system-ui, sans-serif;
  --lp-mono: "IBM Plex Mono", ui-monospace, monospace;

  color: var(--lp-text);
  overflow-x: clip;
}

/* :where() keeps the reset at zero specificity so lp-* classes can set their own margins */
:where(.lp) :where(h1, h2, h3, p, ul, ol) {
  margin: 0;
}

:where(.lp) :where(ul, ol) {
  padding: 0;
  list-style: none;
}

.lp a:not(.lp-btn) {
  color: var(--lp-red-hi);
  text-decoration: underline;
  text-decoration-color: var(--lp-red-line);
  text-underline-offset: 3px;
}

.lp a:not(.lp-btn):hover {
  color: #fff;
  text-decoration-color: currentColor;
}

.lp-wrap {
  width: 100%;
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: 1.5rem;
}

/* ---------- buttons ---------- */

.lp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55em;
  padding: 0.85rem 1.5rem;
  border-radius: 10px;
  font-family: var(--primary-font);
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-decoration: none;
  white-space: nowrap;
  transition: transform 0.15s ease-out, box-shadow 0.2s ease-out, background-color 0.2s, border-color 0.2s, color 0.2s;
}

.lp-btn:active {
  transform: scale(0.97);
}

.lp-btn-primary {
  color: #fff;
  background: linear-gradient(135deg, #d85c5c 0%, #a83b3b 100%);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.08) inset, 0 8px 30px -8px var(--lp-red-glow);
}

.lp-btn-primary:hover {
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.14) inset, 0 14px 40px -8px rgba(198, 80, 80, 0.7);
}

.lp-btn-ghost {
  color: var(--lp-text);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(6px);
}

.lp-btn-ghost:hover {
  color: #fff;
  border-color: var(--lp-red-line);
  background: var(--lp-red-soft);
  transform: translateY(-2px);
}

.lp-btn:focus-visible {
  outline: 2px solid var(--lp-red-hi);
  outline-offset: 3px;
}

.lp-btn-lg {
  padding: 1rem 1.8rem;
  font-size: 1.15rem;
}

/* ---------- hero ---------- */

.lp-hero {
  position: relative;
  padding: clamp(3rem, 8vw, 6.5rem) 0 clamp(3rem, 7vw, 5.5rem);
  isolation: isolate;
}

.lp-hero-bg {
  position: absolute;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  background:
    radial-gradient(60% 55% at 78% 40%, rgba(198, 80, 80, 0.22), transparent 70%),
    radial-gradient(45% 50% at 10% 10%, rgba(198, 80, 80, 0.1), transparent 70%);
}

.lp-hero-bg::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("/media/assets/drek-hero-bg.webp") center bottom / cover no-repeat;
  opacity: 0.32;
  filter: saturate(0.6) hue-rotate(-25deg);
  mask-image: linear-gradient(180deg, #000 30%, transparent 100%);
}

.lp-hero-bg::after {
  /* fine grid, fades out toward the edges */
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(70% 70% at 50% 40%, #000 30%, transparent 100%);
}

.lp-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
}

.lp-hero-copy {
  animation: lp-rise 0.7s ease-out both;
}

.lp-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.35rem 0.85rem 0.35rem 0.7rem;
  margin-bottom: 1.4rem;
  border-radius: 999px;
  border: 1px solid var(--lp-red-line);
  background: var(--lp-red-soft);
  color: #f3c9c9;
  font-family: var(--lp-mono);
  font-size: 0.8rem;
  letter-spacing: 0.02em;
}

.lp-pill-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #3ddc84;
  box-shadow: 0 0 0 0 rgba(61, 220, 132, 0.6);
  animation: lp-ping 2s ease-out infinite;
}

.lp-title {
  font-size: clamp(2.4rem, 5.6vw, 4.3rem);
  line-height: 1.02;
  letter-spacing: -0.01em;
  color: #fff;
  margin-bottom: 1.3rem;
}

.lp-title-icon {
  font-size: 0.8em;
  margin-right: 0.15em;
  color: #8f9cff;
  vertical-align: 0.02em;
}

.lp-title-accent {
  display: block;
  background: linear-gradient(100deg, #ff9b9b 0%, var(--lp-red) 45%, #ff6b6b 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lp-lead {
  max-width: 34rem;
  font-family: var(--lp-body-font);
  font-size: clamp(1rem, 1.4vw, 1.15rem);
  line-height: 1.7;
  color: var(--lp-muted);
  margin-bottom: 2rem;
}

.lp-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
}

.lp-actions-center {
  justify-content: center;
}

.lp-checks {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.4rem;
  margin-top: 1.6rem;
  font-family: var(--lp-body-font);
  font-size: 0.88rem;
  color: var(--lp-muted);
}

.lp-checks :is(i, svg) {
  color: var(--lp-red-hi);
  margin-right: 0.35rem;
}

/* ---------- fake discord chat ---------- */

.lp-chat {
  position: relative;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(30, 31, 38, 0.92), rgba(18, 19, 24, 0.95));
  border: 1px solid rgba(255, 255, 255, 0.09);
  box-shadow:
    0 30px 80px -20px rgba(0, 0, 0, 0.8),
    0 0 0 1px rgba(198, 80, 80, 0.08),
    0 0 90px -30px var(--lp-red-glow);
  font-family: var(--lp-body-font);
  font-size: 0.9rem;
  overflow: hidden;
  animation: lp-rise 0.8s 0.15s ease-out both;
}

.lp-chat::before {
  /* red edge highlight */
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(232, 114, 114, 0.7), transparent);
}

.lp-chat-head {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--lp-line);
  background: rgba(0, 0, 0, 0.2);
}

.lp-chat-dots {
  display: flex;
  gap: 6px;
}

.lp-chat-dots i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.14);
}

.lp-chat-dots i:first-child {
  background: var(--lp-red);
}

.lp-chat-channel {
  color: #c9cad3;
  font-weight: 600;
}

.lp-chat-channel :is(i, svg) {
  color: var(--lp-muted);
  font-size: 0.85em;
}

.lp-chat-body {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1.2rem 1.1rem 0.6rem;
}

.lp-msg {
  display: flex;
  gap: 0.8rem;
  align-items: flex-start;
  opacity: 0;
  animation: lp-pop 0.45s var(--d, 0s) cubic-bezier(0.2, 0.9, 0.3, 1.2) both;
}

.lp-msg-main {
  min-width: 0;
  flex: 1;
}

.lp-avatar {
  flex: none;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-family: var(--primary-font);
  font-weight: 700;
  color: #fff;
}

.lp-avatar-user {
  background: linear-gradient(135deg, #5865f2, #3b44b5);
}

.lp-avatar-bot {
  background: linear-gradient(135deg, #e06a6a, #8f2a2a);
  box-shadow: 0 0 18px -4px var(--lp-red-glow);
}

.lp-msg-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.4rem;
  font-size: 0.78rem;
  color: #7c7e8c;
  margin-bottom: 0.2rem;
}

.lp-msg-meta b {
  font-size: 0.92rem;
  color: #e4e5ea;
}

.lp-msg-meta .lp-bot-name {
  color: var(--lp-red-hi);
}

.lp-bot-tag {
  padding: 0 0.3rem;
  border-radius: 4px;
  background: #5865f2;
  color: #fff;
  font-size: 0.62rem;
  font-weight: 700;
  line-height: 1.5;
}

.lp-msg-text {
  color: #d6d7de;
}

.lp-msg-text code {
  font-family: var(--lp-mono);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 5px;
  padding: 0.05em 0.4em;
  font-size: 0.85rem;
}

.lp-embed {
  margin-top: 0.3rem;
  padding: 0.75rem 0.9rem;
  border-radius: 6px;
  border-left: 4px solid var(--lp-red);
  background: rgba(0, 0, 0, 0.28);
}

.lp-embed-title {
  font-weight: 600;
  color: #fff;
  margin-bottom: 0.55rem;
}

.lp-embed-title :is(i, svg) {
  color: var(--lp-red-hi);
  margin-right: 0.3rem;
}

.lp-embed-fields {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.5rem;
}

.lp-embed-fields span {
  display: block;
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #8a8c99;
}

.lp-embed-fields b {
  font-family: var(--lp-mono);
  font-size: 0.88rem;
  color: #f1f1f4;
}

.lp-slots {
  display: inline-flex;
  gap: 0.35rem;
  padding: 0.4rem 0.55rem;
  margin: 0.3rem 0 0.35rem;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--lp-line);
  font-size: 1.35rem;
  line-height: 1;
}

.lp-slots span {
  display: inline-block;
  animation: lp-spin 0.6s calc(var(--d, 0s) + 0.1s) ease-out both;
}

.lp-win b {
  color: #3ddc84;
  font-family: var(--lp-mono);
}

.lp-chat-input {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 0.6rem 1rem 1rem;
  padding: 0.65rem 0.9rem;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
  color: #6d6f7c;
}

.lp-typing {
  display: flex;
  gap: 4px;
}

.lp-typing i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #7c7e8c;
  animation: lp-bounce 1.2s ease-in-out infinite;
}

.lp-typing i:nth-child(2) { animation-delay: 0.15s; }
.lp-typing i:nth-child(3) { animation-delay: 0.3s; }

/* ---------- command marquee ---------- */

.lp-marquee {
  position: relative;
  overflow: hidden;
  padding: 1.1rem 0;
  border-block: 1px solid var(--lp-line);
  background: rgba(0, 0, 0, 0.25);
  mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
}

.lp-marquee-track {
  display: flex;
  width: max-content;
  animation: lp-scroll 60s linear infinite;
}

.lp-marquee:hover .lp-marquee-track {
  animation-play-state: paused;
}

.lp-marquee-list {
  display: flex;
  gap: 0.75rem;
  padding-right: 0.75rem;
}

.lp-marquee-list li {
  padding: 0.35rem 0.8rem;
  border-radius: 8px;
  border: 1px solid var(--lp-line);
  background: var(--lp-surface);
  font-family: var(--lp-mono);
  font-size: 0.85rem;
  color: #b9bac6;
  white-space: nowrap;
}

/* ---------- stats ---------- */

.lp-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
  padding-block: clamp(3rem, 6vw, 4.5rem);
}

.lp-stat {
  text-align: center;
  padding: 1.25rem 0.75rem;
}

.lp-stat b,
.lp-stat > span {
  font-family: var(--lp-mono);
  font-size: clamp(2rem, 4vw, 2.8rem);
  font-weight: 700;
  line-height: 1.1;
  color: #fff;
}

.lp-stat > span {
  color: var(--lp-red-hi);
}

.lp-stat p {
  margin-top: 0.4rem;
  font-family: var(--lp-body-font);
  font-size: 0.9rem;
  color: var(--lp-muted);
}

/* ---------- section heads ---------- */

.lp-section {
  padding-block: clamp(3.5rem, 8vw, 6rem);
}

/* nav links (#features, #lab) land below the fixed navbar */
.lp [id] {
  scroll-margin-top: 90px;
}

.lp-section-tight {
  padding-top: 0;
}

.lp-head {
  max-width: 44rem;
  margin: 0 auto clamp(2.2rem, 5vw, 3.5rem);
  text-align: center;
}

.lp-eyebrow {
  font-family: var(--lp-mono);
  font-size: 0.85rem;
  color: var(--lp-red-hi);
  margin-bottom: 0.75rem;
}

.lp-head h2 {
  font-size: clamp(1.9rem, 4vw, 3rem);
  line-height: 1.1;
  color: #fff;
}

.lp-head h2 span {
  color: var(--lp-muted);
}

.lp-head > p:last-child:not(.lp-eyebrow) {
  margin-top: 0.9rem;
  font-family: var(--lp-body-font);
  color: var(--lp-muted);
}

/* ---------- feature bento ---------- */

.lp-bento {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.lp-card {
  position: relative;
  padding: 1.6rem;
  border-radius: 16px;
  border: 1px solid var(--lp-line);
  background: linear-gradient(180deg, var(--lp-surface-2), var(--lp-surface));
  overflow: hidden;
  transition: border-color 0.25s, transform 0.25s ease-out, box-shadow 0.25s;
}

.lp-card::after {
  /* soft red glow that shows up on hover */
  content: "";
  position: absolute;
  inset: auto -30% -60% auto;
  width: 70%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(198, 80, 80, 0.25), transparent 70%);
  opacity: 0;
  transition: opacity 0.35s;
  pointer-events: none;
}

.lp-card:hover {
  border-color: var(--lp-red-line);
  transform: translateY(-4px);
  box-shadow: 0 20px 50px -25px rgba(0, 0, 0, 0.9);
}

.lp-card:hover::after {
  opacity: 1;
}

.lp-card h3 {
  font-size: 1.35rem;
  color: #fff;
  margin: 1rem 0 0.4rem;
}

.lp-card p {
  font-family: var(--lp-body-font);
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--lp-muted);
}

.lp-icon {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 12px;
  border: 1px solid var(--lp-red-line);
  background: var(--lp-red-soft);
  color: var(--lp-red-hi);
  font-size: 1.15rem;
}

.lp-card-wide {
  grid-column: span 2;
  grid-row: span 2;
  display: grid;
  grid-template-rows: auto 1fr;
  padding: 0;
}

.lp-card-wide .lp-card-text {
  padding: 1.8rem 1.8rem 1.2rem;
}

.lp-card-wide h3 {
  font-size: 1.7rem;
}

.lp-card-media {
  position: relative;
  min-height: 200px;
  margin: 0 1.2rem 1.2rem;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--lp-line);
}

.lp-econ {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}

.lp-econ-coin {
  transform-box: fill-box;
  transform-origin: center;
  animation: lp-float 5s ease-in-out infinite;
}

.lp-econ-chip {
  animation: lp-float 4s ease-in-out infinite;
}

.lp-econ-chip-2 {
  animation-delay: -2s;
}

/* chart draws itself once the card scrolls in (only when landing.js runs) */
.lp-js .lp-econ-line {
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  transition: stroke-dashoffset 1.6s 0.3s ease-out;
}

.lp-js .is-in .lp-econ-line {
  stroke-dashoffset: 0;
}

.lp-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 1rem;
}

.lp-tags li {
  padding: 0.2rem 0.6rem;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--lp-line);
  font-family: var(--lp-mono);
  font-size: 0.8rem;
  color: #d3d4dc;
}

/* full-width last card in the bento */
.lp-card-banner {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 1.2rem;
}

.lp-card-banner .lp-icon {
  flex: none;
}

.lp-card-banner h3 {
  margin-top: 0;
}

/* ---------- live lab (driven by js/landing-lab.js) ---------- */

.lab {
  --lab-ok: #3ddc84;
  --lab-warn: #f5c542;
  --lab-err: #ee4b4b;
  --lab-info: #8ab4ff;
  --lab-dim: #6d6f7c;
  --lab-ink: #d3d4dc;

  border: 1px solid var(--lp-line);
  border-radius: 20px;
  background: linear-gradient(180deg, var(--lp-surface-2), var(--lp-surface));
  overflow: hidden;
}

.lab label {
  padding-inline: 0;
}

.lab code {
  border: 0;
}

.lab button {
  font: inherit;
}

.lab button:focus-visible {
  outline: 2px solid var(--lp-red-hi);
  outline-offset: 2px;
}

/* tabs */

.lab-tabs {
  display: flex;
  gap: 0.35rem;
  padding: 0.6rem;
  border-bottom: 1px solid var(--lp-line);
  background: rgba(0, 0, 0, 0.22);
  overflow-x: auto;
  scrollbar-width: none;
}

.lab-tabs::-webkit-scrollbar {
  display: none;
}

.lab-tabs [role="tab"] {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  padding: 0.6rem 1rem;
  border-radius: 10px;
  border: 1px solid transparent;
  background: none;
  color: var(--lp-muted);
  font-family: var(--primary-font);
  font-size: 0.98rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: color 0.2s, background-color 0.2s, border-color 0.2s;
}

.lab-tabs [role="tab"]:hover {
  color: #fff;
  background: var(--lp-surface-2);
}

.lab-tabs [aria-selected="true"] {
  color: #fff;
  background: var(--lp-red-soft);
  border-color: var(--lp-red-line);
}

.lab-tabs [aria-selected="true"] :is(i, svg) {
  color: var(--lp-red-hi);
}

/* panel: intro on the left, fake discord window on the right */

.lab-panel {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(1.2rem, 3vw, 2.5rem);
  padding: clamp(1.2rem, 3vw, 2.2rem);
  animation: lp-pop 0.35s ease-out;
}

.lab-panel[hidden] {
  display: none;
}

.lab-intro h3 {
  font-size: 1.7rem;
  line-height: 1.15;
  color: #fff;
  margin-bottom: 0.6rem;
}

.lab-intro p {
  font-family: var(--lp-body-font);
  line-height: 1.65;
  color: var(--lp-muted);
}

.lab-points {
  display: grid;
  gap: 0.5rem;
  margin-top: 1.1rem;
}

.lab-points li {
  position: relative;
  padding-left: 1.4rem;
  font-family: var(--lp-body-font);
  font-size: 0.95rem;
  color: var(--lab-ink);
}

.lab-points li::before {
  content: "";
  position: absolute;
  left: 0.1rem;
  top: 0.55em;
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 2px;
  background: var(--lp-red);
  transform: rotate(45deg);
}

.lab-intro .lab-note {
  margin-top: 1.2rem;
  padding-left: 0.8rem;
  border-left: 2px solid var(--lp-red-line);
  font-size: 0.8rem;
  color: var(--lab-dim);
}

.lab-win {
  display: flex;
  flex-direction: column;
  min-width: 0;
  border: 1px solid var(--lp-line);
  border-radius: 14px;
  background: #111015;
  overflow: hidden;
  box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.8);
}

.lab-win-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.7rem 1rem;
  border-bottom: 1px solid var(--lp-line);
  background: rgba(255, 255, 255, 0.03);
  font-family: var(--lp-body-font);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--lab-ink);
}

.lab-win-head :is(i, svg) {
  margin-right: 0.25em;
  color: var(--lp-muted);
}

.lab-state {
  flex: none;
  padding: 0.25rem 0.55rem;
  border-radius: 999px;
  border: 1px solid var(--lp-line);
  background: rgba(255, 255, 255, 0.04);
  font-family: var(--lp-mono);
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  color: var(--lp-muted);
  transition: color 0.2s, background-color 0.2s, border-color 0.2s;
}

.lab-state.is-ok {
  color: var(--lab-ok);
  border-color: rgba(61, 220, 132, 0.35);
  background: rgba(61, 220, 132, 0.08);
}

.lab-state.is-warn {
  color: var(--lab-warn);
  border-color: rgba(245, 197, 66, 0.35);
  background: rgba(245, 197, 66, 0.08);
}

.lab-state.is-err {
  color: var(--lab-err);
  border-color: rgba(238, 75, 75, 0.4);
  background: rgba(238, 75, 75, 0.1);
}

.lab-win-body {
  display: grid;
  gap: 1rem;
  padding: 1.1rem;
}

.lab-log {
  height: 118px;
  padding: 0.6rem 0.9rem;
  overflow-y: auto;
  border-top: 1px solid var(--lp-line);
  background: rgba(0, 0, 0, 0.35);
  font-family: var(--lp-mono);
  font-size: 0.76rem;
  line-height: 1.6;
  color: #a9abb8;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.15) transparent;
}

.lab-log-line {
  display: flex;
  gap: 0.7rem;
}

.lab-log-line time {
  flex: none;
  color: #55576a;
}

.lab-log-line.is-ok span { color: var(--lab-ok); }
.lab-log-line.is-warn span { color: var(--lab-warn); }
.lab-log-line.is-err span { color: var(--lab-err); }
.lab-log-line.is-info span { color: var(--lab-info); }
.lab-log-line.is-hot span { color: var(--lp-red-hi); font-weight: 700; }

/* shared controls */

.lab-btns {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.lab-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45em;
  padding: 0.55rem 0.95rem;
  border-radius: 9px;
  border: 1px solid var(--lp-line);
  background: var(--lp-surface-2);
  color: #e6e6ee;
  font-family: var(--lp-body-font) !important;
  font-size: 0.88rem !important;
  font-weight: 600 !important;
  cursor: pointer;
  transition: transform 0.15s, background-color 0.2s, border-color 0.2s, color 0.2s, opacity 0.2s;
}

.lab-btn:hover:not(:disabled) {
  border-color: var(--lp-red-line);
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.lab-btn:active:not(:disabled) {
  transform: scale(0.97);
}

.lab-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.lab-btn-primary {
  border-color: transparent;
  background: linear-gradient(135deg, #d85c5c 0%, #a83b3b 100%);
  color: #fff;
}

.lab-btn-primary:hover:not(:disabled) {
  border-color: transparent;
  background: linear-gradient(135deg, #e46a6a 0%, #b84545 100%);
}

.lab-btn-danger {
  border-color: rgba(238, 75, 75, 0.4);
  background: rgba(238, 75, 75, 0.08);
  color: var(--lab-err);
}

.lab-btn[aria-pressed="true"] {
  border-color: rgba(61, 220, 132, 0.45);
  background: rgba(61, 220, 132, 0.1);
  color: var(--lab-ok);
}

.lab-chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
}

.lab-chips > span {
  font-family: var(--lp-mono);
  font-size: 0.78rem;
  color: var(--lab-dim);
}

.lab-chips button {
  padding: 0.3rem 0.7rem;
  border-radius: 999px;
  border: 1px solid var(--lp-line);
  background: rgba(0, 0, 0, 0.3);
  color: var(--lab-ink);
  font-family: var(--lp-mono) !important;
  font-size: 0.78rem !important;
  cursor: pointer;
  transition: background-color 0.2s, border-color 0.2s, color 0.2s;
}

.lab-chips button:hover,
.lab-chips button.is-active {
  border-color: var(--lp-red-line);
  background: var(--lp-red-soft);
  color: #fff;
}

.lab input[type="text"],
.lab input[type="number"] {
  min-width: 0;
  padding: 0.55rem 0.75rem;
  border-radius: 9px;
  border: 1px solid var(--lp-line);
  background: rgba(0, 0, 0, 0.35);
  color: #fff;
  font-family: var(--lp-mono);
  font-size: 0.9rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.lab input[type="text"]:focus,
.lab input[type="number"]:focus {
  outline: none;
  border-color: var(--lp-red-line);
  box-shadow: 0 0 0 3px var(--lp-red-soft);
}

.lab input[type="range"],
.lab input[type="checkbox"] {
  accent-color: var(--lp-red);
}

.lab-hint {
  font-family: var(--lp-body-font);
  font-size: 0.9rem;
  color: var(--lp-muted);
}

.lab-sub {
  margin-bottom: 0.5rem !important;
  font-family: var(--lp-mono);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--lp-muted);
}

.lab-av {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: hsl(var(--h, 0) 50% 42%);
  color: #fff;
  font-family: var(--primary-font);
  font-size: 0.85rem;
  font-weight: 700;
}

/* little stat boxes reused by economy, gate, ml, nuke */
.eco-top > div,
.gate-user,
.ml-meter,
.nuke-meter {
  padding: 0.8rem 0.9rem;
  border-radius: 10px;
  border: 1px solid var(--lp-line);
  background: rgba(255, 255, 255, 0.03);
}

/* economy */

.eco-top {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.6rem;
}

.eco-top span,
.nuke-meter span:not([id]),
.vc-field > span {
  display: block;
  font-family: var(--lp-mono);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--lp-muted);
}

.eco-top b {
  font-size: 1.5rem;
  color: #fff;
}

.eco-top small {
  color: var(--lp-muted);
}

#ecoNet.is-up { color: var(--lab-ok); }
#ecoNet.is-down { color: var(--lab-err); }
#ecoBal.is-up { animation: lab-flash-up 0.7s; }
#ecoBal.is-down { animation: lab-flash-down 0.7s; }

.slots {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.6rem;
  padding: 0.7rem;
  border-radius: 14px;
  border: 1px solid var(--lp-red-line);
  background: radial-gradient(circle at 50% 0, rgba(198, 80, 80, 0.2), transparent 70%), #0b0a0e;
}

.reel {
  --cell: 76px;
  position: relative;
  height: var(--cell);
  border-radius: 10px;
  border: 1px solid var(--lp-line);
  background: linear-gradient(180deg, #1c1a21, #141217);
  overflow: hidden;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.reel::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.45), transparent 30%, transparent 70%, rgba(0, 0, 0, 0.45));
  pointer-events: none;
}

.reel-cell {
  display: grid;
  place-items: center;
  height: var(--cell);
  font-size: 2.3rem;
  line-height: 1;
}

.reel.is-spinning .reel-strip {
  filter: blur(1px);
}

.reel.is-win {
  border-color: var(--lab-ok);
  box-shadow: 0 0 0 1px var(--lab-ok), 0 0 26px -6px var(--lab-ok);
}

.slots-msg {
  min-height: 1.5em;
  text-align: center;
  font-family: var(--lp-body-font);
  font-size: 0.95rem;
  color: var(--lab-ink);
}

.slots-msg.is-win { color: var(--lab-ok); font-weight: 600; }
.slots-msg.is-loss { color: var(--lab-err); }

.bet-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem;
}

.bet-row > label {
  font-family: var(--lp-mono);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--lp-muted);
}

.bet-row input {
  width: 6.5rem;
}

/* join gate */

.gate-user {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.gate-user > div {
  flex: 1;
  min-width: 0;
}

.gate-user b {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--lp-body-font);
  color: #fff;
}

.gate-user small {
  font-family: var(--lp-body-font);
  font-size: 0.78rem;
  color: var(--lp-muted);
}

.gate-timer {
  flex: none;
  width: 46px;
  height: 46px;
}

.gate-timer circle {
  fill: none;
  stroke-width: 3;
}

.gate-timer-track {
  stroke: rgba(255, 255, 255, 0.08);
}

.gate-timer-ring {
  stroke: var(--lp-red-hi);
  stroke-dasharray: 97.4;
  stroke-linecap: round;
  transform: rotate(-90deg);
  transform-origin: center;
  transform-box: fill-box;
  transition: stroke-dashoffset 1s linear, stroke 0.3s;
}

.gate-timer text {
  fill: #fff;
  font-family: var(--lp-mono);
  font-size: 9px;
  font-weight: 700;
}

.gate-prompt {
  text-align: center;
  font-family: var(--lp-body-font);
  font-size: 1.05rem;
  color: var(--lab-ink);
}

.gate-prompt strong {
  font-size: 1.25em;
  color: #fff;
}

.gate-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.6rem;
}

.gate-btn {
  height: 56px;
  border-radius: 10px;
  border: 2px solid transparent;
  background: var(--swatch);
  box-shadow: inset 0 -4px 0 rgba(0, 0, 0, 0.25);
  cursor: pointer;
  transition: transform 0.15s, opacity 0.25s, box-shadow 0.2s, border-color 0.2s;
}

.gate-btn:hover:not(:disabled) {
  transform: translateY(-2px);
}

.gate-btn:disabled {
  cursor: default;
}

.gate-btn.is-wrong {
  opacity: 0.3;
  animation: lab-shake 0.4s;
}

.gate-btn.is-faded {
  opacity: 0.18;
}

.gate-btn.is-target {
  opacity: 1;
  border-color: #fff;
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.18), 0 0 26px -4px var(--swatch);
}

/* ml name scan */

.ml-input {
  display: flex;
  gap: 0.5rem;
}

.ml-input input {
  flex: 1;
}

.ml-meter {
  --verdict: var(--lab-dim);
}

.ml-meter:has(.is-ok) { --verdict: var(--lab-ok); }
.ml-meter:has(.is-warn) { --verdict: var(--lab-warn); }
.ml-meter:has(.is-err) { --verdict: var(--lab-err); }

.ml-meter-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  font-family: var(--lp-body-font);
  font-size: 0.9rem;
  color: var(--lp-muted);
}

.ml-meter-top b {
  font-family: var(--primary-font);
  font-size: 1.6rem;
  color: #fff;
}

.ml-bar {
  height: 10px;
  margin-top: 0.4rem;
  border-radius: 99px;
  background: linear-gradient(90deg,
    rgba(61, 220, 132, 0.16) 0 35%,
    rgba(245, 197, 66, 0.16) 35% 68%,
    rgba(238, 75, 75, 0.16) 68%);
  overflow: hidden;
}

.ml-bar i {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: var(--verdict);
  transition: width 0.4s ease-out, background-color 0.3s;
}

.ml-scale {
  display: grid;
  grid-template-columns: 35fr 33fr 32fr;
  margin-top: 0.3rem;
  font-family: var(--lp-mono);
  font-size: 0.62rem;
  letter-spacing: 0.06em;
  color: var(--lab-dim);
}

.ml-verdict {
  margin-top: 0.5rem !important;
  font-family: var(--lp-mono);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--verdict);
}

.ml-signals {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.55rem 1rem;
}

.ml-signal-head {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  font-family: var(--lp-mono);
  font-size: 0.74rem;
  color: var(--lp-muted);
}

.ml-signal-head b {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 600;
  color: #e6e6ee;
}

.ml-signal-bar {
  height: 4px;
  margin-top: 0.3rem;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.07);
  overflow: hidden;
}

.ml-signal-bar i {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: var(--lab-ok);
  transition: width 0.5s ease-out, background-color 0.3s;
}

.ml-signal.is-warm i { background: var(--lab-warn); }
.ml-signal.is-hot i { background: var(--lab-err); }

/* anti-nuke */

.nuke-meter {
  --meter: var(--lab-ok);
  position: relative;
  display: flex;
  align-items: center;
  gap: 1.2rem;
}

.nuke-meter.is-warn { --meter: var(--lab-warn); }
.nuke-meter.is-crit { --meter: var(--lab-err); }
.nuke-meter.is-locked { --meter: var(--lab-ok); }

.nuke-gauge {
  flex: none;
  width: 110px;
  height: 110px;
}

.nuke-track,
.nuke-ring {
  fill: none;
  stroke-width: 8;
}

.nuke-track {
  stroke: rgba(255, 255, 255, 0.07);
}

.nuke-ring {
  stroke: var(--meter);
  stroke-dasharray: 326.7;
  stroke-dashoffset: 326.7;
  stroke-linecap: round;
  transform: rotate(-90deg);
  transform-origin: center;
  transform-box: fill-box;
  transition: stroke-dashoffset 0.35s ease-out, stroke 0.3s;
}

.nuke-shield {
  position: absolute;
  left: calc(0.9rem + 55px);
  top: 50%;
  translate: -50% -50%;
  font-size: 2rem;
  color: var(--meter);
  transition: color 0.3s;
}

.nuke-meter.is-locked .nuke-shield {
  animation: lab-pulse 1.4s ease-in-out infinite;
}

.nuke-meter b {
  display: block;
  font-size: 2.2rem;
  line-height: 1.1;
  color: #fff;
}

.nuke-meter b small {
  font-size: 0.9rem;
  color: var(--lp-muted);
}

.nuke-meter > div > small {
  font-family: var(--lp-body-font);
  font-size: 0.8rem;
  color: var(--lp-muted);
}

/* agent ai */

.agent-plan {
  display: grid;
  align-content: start;
  gap: 0.5rem;
  min-height: 120px;
}

.agent-step {
  display: grid;
  grid-template-columns: 10.5rem minmax(0, 1fr) auto;
  align-items: start;
  gap: 0.8rem;
  padding: 0.65rem 0.8rem;
  border-radius: 10px;
  border: 1px solid var(--lp-line);
  background: rgba(255, 255, 255, 0.025);
  animation: lp-pop 0.35s ease-out both;
  transition: border-color 0.2s, background-color 0.2s;
}

.agent-step-tool {
  justify-self: start;
  padding: 0.15rem 0.45rem;
  border-radius: 6px;
  background: rgba(138, 180, 255, 0.1);
  font-family: var(--lp-mono);
  font-size: 0.72rem;
  font-weight: 600;
  white-space: nowrap;
  color: var(--lab-info);
}

.agent-step-body {
  display: grid;
  gap: 0.15rem;
  font-family: var(--lp-body-font);
}

.agent-step-body b {
  font-size: 0.9rem;
  color: #fff;
}

.agent-step-body span {
  font-size: 0.8rem;
  color: var(--lp-muted);
}

.agent-step-body code {
  justify-self: start;
  padding: 0;
  background: none;
  font-size: 0.74rem;
}

.agent-step-body .is-add { color: var(--lab-ok); }
.agent-step-body .is-mod { color: var(--lab-warn); }

.agent-step-state {
  font-family: var(--lp-mono);
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--lab-dim);
}

.agent-step.is-running {
  border-color: var(--lp-red-line);
  background: var(--lp-red-soft);
}

.agent-step.is-running .agent-step-state { color: var(--lp-red-hi); }
.agent-step.is-done .agent-step-state { color: var(--lab-ok); }

/* custom vc */

.vc-controls {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.8rem;
}

.vc-field {
  display: grid;
  gap: 0.35rem;
}

.vc-field > span {
  display: flex;
  justify-content: space-between;
}

.vc-field small {
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0;
  color: var(--lab-dim);
}

.vc-field b {
  color: #fff;
}

.vc-toggles {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 1.1rem;
}

.vc-toggles label {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--lp-body-font);
  font-size: 0.88rem;
  color: var(--lab-ink);
  cursor: pointer;
}

.vc-preview {
  padding: 0.8rem 0.9rem;
  border-radius: 10px;
  border: 1px solid var(--lp-line);
  background: #0b0a0e;
}

.vc-channel {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--lp-body-font);
  font-weight: 600;
  color: var(--lab-ink);
}

.vc-ico {
  color: var(--lp-muted);
}

/* swap the speaker icon for a padlock when the room is locked
   (the FA kit renders <svg>s, so hide/show instead of swapping ::before) */
.vc-ico > :last-child,
.vc-channel.is-locked .vc-ico > :first-child {
  display: none;
}

.vc-channel.is-locked .vc-ico > :last-child {
  display: inline-block;
  color: var(--lab-warn);
}

.vc-channel.is-hidden > b {
  font-style: italic;
  opacity: 0.6;
}

.vc-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
}

.vc-badge {
  padding: 0.12rem 0.4rem;
  border-radius: 5px;
  border: 1px solid var(--lp-red-line);
  background: var(--lp-red-soft);
  font-family: var(--lp-mono);
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--lp-red-hi);
}

.vc-members {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  min-height: 28px;
  margin-top: 0.7rem;
  padding-left: 1.4rem;
}

.vc-member {
  width: 28px;
  height: 28px;
  font-size: 0.75rem;
  animation: lp-pop 0.3s ease-out both;
}

.vc-sub {
  font-family: var(--lp-body-font);
  font-size: 0.8rem;
  color: var(--lp-muted);
}

.vc-sub b {
  color: #fff;
}

.vc-access {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.45rem;
  margin-top: -0.4rem;
}

.vc-chip {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-width: 0;
  padding: 0.45rem 0.55rem;
  border-radius: 10px;
  border: 1px solid var(--lp-line);
  background: rgba(255, 255, 255, 0.03);
  color: var(--lab-ink);
  text-align: left;
  cursor: pointer;
  transition: border-color 0.2s, background-color 0.2s;
}

.vc-chip:hover:not(:disabled) {
  border-color: var(--lp-red-line);
}

.vc-chip:disabled {
  cursor: default;
}

.vc-chip .lab-av {
  width: 26px;
  height: 26px;
  font-size: 0.72rem;
  transition: filter 0.2s, opacity 0.2s;
}

.vc-chip-text {
  display: grid;
  min-width: 0;
  font-family: var(--lp-body-font);
  line-height: 1.3;
}

.vc-chip-text b {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.8rem;
  color: #fff;
}

.vc-chip-text small {
  font-size: 0.7rem;
  color: var(--lab-ok);
}

.vc-chip.is-blocked {
  border-color: rgba(238, 75, 75, 0.4);
  background: rgba(238, 75, 75, 0.07);
}

.vc-chip.is-blocked small {
  color: var(--lab-err);
}

.vc-chip.is-blocked .lab-av {
  filter: grayscale(1);
  opacity: 0.5;
}

/* leveling */

.lvl-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  border-radius: 12px;
  border: 1px solid var(--lp-red-line);
  background: linear-gradient(120deg, rgba(198, 80, 80, 0.2), rgba(255, 255, 255, 0.02) 60%), #0b0a0e;
}

.lvl-av {
  width: 58px;
  height: 58px;
  font-size: 1.4rem;
  box-shadow: 0 0 0 3px #0b0a0e, 0 0 0 5px var(--lp-red);
}

.lvl-card-main {
  flex: 1;
  min-width: 0;
}

.lvl-card-top {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.2rem 1rem;
  font-family: var(--lp-mono);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--lp-muted);
}

.lvl-card-top > b {
  margin-right: auto;
  font-family: var(--lp-body-font);
  font-size: 1.05rem;
  letter-spacing: 0;
  color: #fff;
}

.lvl-card-top span b {
  font-family: var(--primary-font);
  font-size: 1.3rem;
  color: #fff;
}

.lvl-bar {
  height: 10px;
  margin-top: 0.4rem;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.lvl-bar i {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #a83b3b, var(--lp-red-hi));
  transition: width 0.3s ease-out;
}

.lvl-card-foot {
  display: flex;
  justify-content: space-between;
  margin-top: 0.35rem;
  font-family: var(--lp-mono);
  font-size: 0.74rem;
  color: var(--lp-muted);
}

.lvl-card-foot b {
  color: #fff;
}

.lvl-cooldown {
  height: 2px;
  margin-top: 0.4rem;
}

.lvl-cooldown i {
  display: block;
  width: 0;
  height: 100%;
  background: var(--lab-warn);
}

.lvl-split {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.lvl-rewards,
.lvl-board {
  display: grid;
  gap: 0.35rem;
}

.lvl-reward {
  display: grid;
  grid-template-columns: 3rem minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.6rem;
  border-radius: 8px;
  border: 1px solid var(--lp-line);
  font-family: var(--lp-mono);
  font-size: 0.76rem;
  color: var(--lab-dim);
  transition: border-color 0.3s, background-color 0.3s, color 0.3s;
}

.lvl-reward b {
  font-family: var(--lp-body-font);
  color: #8c8e9b;
}

.lvl-reward small {
  font-size: 0.64rem;
  text-transform: uppercase;
}

.lvl-reward.is-on {
  border-color: hsl(var(--h) 60% 50% / 0.45);
  background: hsl(var(--h) 60% 50% / 0.1);
  color: var(--lab-ink);
}

.lvl-reward.is-on b { color: hsl(var(--h) 70% 68%); }
.lvl-reward.is-on small { color: var(--lab-ok); }

.lvl-board li {
  display: grid;
  grid-template-columns: 1.8rem auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.6rem;
  border-radius: 8px;
  border: 1px solid transparent;
  font-family: var(--lp-mono);
  font-size: 0.76rem;
  color: var(--lp-muted);
}

.lvl-board li i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: hsl(var(--h) 55% 50%);
}

.lvl-board li b {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--lp-body-font);
  color: #e6e6ee;
}

.lvl-board li small {
  font-size: 0.7rem;
}

.lvl-board li.is-me {
  border-color: var(--lp-red-line);
  background: var(--lp-red-soft);
}

/* github */

.gh-stats {
  font-family: var(--lp-mono);
  font-size: 0.78rem;
  color: var(--lp-muted);
}

.gh-stats b {
  color: #fff;
}

.lab .gh-add { color: var(--lab-ok); }
.lab .gh-del { color: var(--lab-err); }

.gh-feed {
  display: grid;
  gap: 0.6rem;
  max-height: 340px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.15) transparent;
}

.gh-feed:empty::before {
  content: "Feed is empty. Push something.";
  font-family: var(--lp-body-font);
  font-size: 0.88rem;
  color: var(--lab-dim);
}

.gh-commit {
  padding: 0.8rem 0.9rem;
  border-radius: 10px;
  border: 1px solid var(--lp-line);
  border-left: 3px solid var(--lp-red);
  background: rgba(255, 255, 255, 0.025);
  animation: lp-pop 0.35s ease-out both;
}

.gh-commit-head {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--lp-body-font);
  font-size: 0.85rem;
  color: var(--lp-muted);
}

.gh-commit-head .lab-av {
  width: 26px;
  height: 26px;
  font-size: 0.72rem;
}

.gh-commit-head b {
  color: #fff;
}

.gh-commit-head time {
  margin-left: auto;
  font-family: var(--lp-mono);
  font-size: 0.72rem;
  color: var(--lab-dim);
}

.gh-msg {
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
  margin-top: 0.5rem;
  font-family: var(--lp-body-font);
  font-size: 0.92rem;
  font-weight: 600;
  color: #fff;
}

.gh-msg code {
  flex: none;
  padding: 0.1rem 0.4rem;
  background: rgba(138, 180, 255, 0.1);
  font-size: 0.74rem;
  font-weight: 400;
  color: var(--lab-info);
}

.gh-body {
  margin-top: 0.3rem !important;
  font-family: var(--lp-body-font);
  font-size: 0.82rem;
  color: var(--lp-muted);
}

.gh-files {
  display: grid;
  gap: 0.2rem;
  margin-top: 0.6rem !important;
  font-family: var(--lp-mono);
  font-size: 0.74rem;
}

.gh-files li {
  display: grid;
  grid-template-columns: 1.3rem minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.5rem;
}

.gh-status {
  padding: 0.05rem 0;
  border-radius: 4px;
  text-align: center;
  font-size: 0.66rem;
  font-weight: 700;
}

.gh-status.is-A { color: var(--lab-ok); background: rgba(61, 220, 132, 0.12); }
.gh-status.is-M { color: var(--lab-warn); background: rgba(245, 197, 66, 0.12); }
.gh-status.is-D { color: var(--lab-err); background: rgba(238, 75, 75, 0.12); }

.gh-path {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #c9cad3;
}

.gh-counts {
  display: flex;
  gap: 0.4rem;
}

.gh-bin {
  color: var(--lab-dim);
}

.gh-foot {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  margin-top: 0.6rem;
  padding-top: 0.5rem;
  border-top: 1px dashed var(--lp-line);
  font-family: var(--lp-mono);
  font-size: 0.74rem;
  color: var(--lp-muted);
}

.gh-foot > span:last-child {
  margin-left: auto;
}

.gh-diffbar {
  display: inline-flex;
  gap: 2px;
}

.gh-diffbar i {
  width: 8px;
  height: 8px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.1);
}

.gh-diffbar .is-add { background: var(--lab-ok); }
.gh-diffbar .is-del { background: var(--lab-err); }

/* ---------- steps ---------- */

.lp-steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  counter-reset: none;
}

.lp-steps li {
  position: relative;
  padding: 1.6rem;
  border-radius: 16px;
  border: 1px dashed rgba(255, 255, 255, 0.12);
}

.lp-step-num {
  font-family: var(--lp-mono);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--lp-red-hi);
}

.lp-steps h3 {
  font-size: 1.3rem;
  color: #fff;
  margin: 0.4rem 0 0.35rem;
}

.lp-steps p {
  font-family: var(--lp-body-font);
  font-size: 0.95rem;
  color: var(--lp-muted);
  line-height: 1.6;
}

/* ---------- final cta ---------- */

.lp-cta-wrap {
  padding-bottom: 1rem;
}

.lp-cta {
  position: relative;
  padding: clamp(2.5rem, 6vw, 4.5rem) clamp(1.25rem, 4vw, 3rem);
  border-radius: 24px;
  border: 1px solid var(--lp-red-line);
  background:
    radial-gradient(80% 120% at 50% 0%, rgba(198, 80, 80, 0.28), transparent 70%),
    linear-gradient(180deg, rgba(40, 18, 20, 0.6), rgba(12, 12, 16, 0.8));
  text-align: center;
  overflow: hidden;
  isolation: isolate;
}

.lp-cta::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 36px 36px;
  mask-image: radial-gradient(60% 80% at 50% 0%, #000, transparent 80%);
}

.lp-cta h2 {
  font-size: clamp(1.9rem, 4.5vw, 3.1rem);
  line-height: 1.1;
  color: #fff;
}

.lp-cta > p:not(.lp-cta-foot) {
  margin: 0.9rem auto 2rem;
  max-width: 34rem;
  font-family: var(--lp-body-font);
  color: #c9c3c6;
}

.lp-cta > p span {
  display: block;
  margin-top: 0.2rem;
  font-family: var(--lp-mono);
  font-size: 0.78rem;
  color: var(--lp-muted);
}

.lp-cta-foot {
  margin-top: 1.4rem;
  font-family: var(--lp-mono);
  font-size: 0.8rem;
  color: var(--lp-muted);
}

/* ---------- scroll reveal (only when landing.js is running) ---------- */

.lp-js [data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
  transition-delay: var(--reveal-delay, 0s);
}

.lp-js [data-reveal].is-in {
  opacity: 1;
  transform: none;
}

/* the card hover lift needs to win over the reveal transform once revealed */
.lp-js .lp-card.is-in:hover {
  transform: translateY(-4px);
}

/* ---------- keyframes ---------- */

@keyframes lp-rise {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: none; }
}

@keyframes lp-pop {
  from { opacity: 0; transform: translateY(10px) scale(0.98); }
  to { opacity: 1; transform: none; }
}

@keyframes lp-spin {
  0% { transform: translateY(-60%); opacity: 0; filter: blur(3px); }
  100% { transform: none; opacity: 1; filter: none; }
}

@keyframes lp-ping {
  0% { box-shadow: 0 0 0 0 rgba(61, 220, 132, 0.6); }
  80%, 100% { box-shadow: 0 0 0 8px rgba(61, 220, 132, 0); }
}

@keyframes lp-bounce {
  0%, 60%, 100% { transform: none; opacity: 0.5; }
  30% { transform: translateY(-4px); opacity: 1; }
}

@keyframes lp-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

@keyframes lp-scroll {
  to { transform: translateX(-50%); }
}

@keyframes lab-shake {
  0%, 100% { transform: none; }
  20%, 60% { transform: translateX(-5px); }
  40%, 80% { transform: translateX(5px); }
}

@keyframes lab-flash-up {
  0% { color: var(--lab-ok); text-shadow: 0 0 18px rgba(61, 220, 132, 0.7); }
}

@keyframes lab-flash-down {
  0% { color: var(--lab-err); text-shadow: 0 0 18px rgba(238, 75, 75, 0.7); }
}

@keyframes lab-pulse {
  0%, 100% { scale: 1; filter: drop-shadow(0 0 0 transparent); }
  50% { scale: 1.08; filter: drop-shadow(0 0 10px rgba(61, 220, 132, 0.7)); }
}

/* ---------- responsive ---------- */

@media (max-width: 960px) {
  .lp-hero-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .lp-hero-copy {
    text-align: center;
  }

  .lp-lead {
    margin-inline: auto;
  }

  .lp-actions,
  .lp-checks {
    justify-content: center;
  }

  .lp-chat {
    max-width: 520px;
    width: 100%;
    margin-inline: auto;
  }

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

  .lp-card-wide {
    grid-row: auto;
  }

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

  .lab-panel {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 640px) {
  .lp-wrap {
    padding-inline: 1rem;
  }

  .lp-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .lp-bento,
  .lp-steps {
    grid-template-columns: minmax(0, 1fr);
  }

  .lp-card-wide {
    grid-column: auto;
  }

  .lp-card-wide .lp-card-text {
    padding: 1.5rem 1.4rem 1rem;
  }

  .lp-card-media {
    min-height: 170px;
    margin: 0 1rem 1rem;
  }

  .lp-chat {
    font-size: 0.85rem;
  }

  .lp-embed-fields b {
    font-size: 0.8rem;
  }

  .lp-stats {
    gap: 0.5rem;
  }

  .lp-card-banner {
    flex-direction: column;
    align-items: flex-start;
  }

  .lab {
    border-radius: 16px;
  }

  .lab-panel {
    padding: 1rem;
  }

  .lab-win-body {
    padding: 0.9rem;
  }

  .reel {
    --cell: 64px;
  }

  .reel-cell {
    font-size: 1.9rem;
  }

  .vc-controls,
  .lvl-split,
  .ml-signals {
    grid-template-columns: minmax(0, 1fr);
  }

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

  .agent-step {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .agent-step-tool {
    grid-column: 1 / -1;
    justify-self: start;
  }

  .nuke-gauge {
    width: 90px;
    height: 90px;
  }

  .nuke-shield {
    left: calc(0.9rem + 45px);
    font-size: 1.6rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .lp-marquee-track {
    animation: none;
  }

  .lp-marquee {
    overflow-x: auto;
  }

  .lp-js [data-reveal] {
    opacity: 1;
    transform: none;
  }
}
