/* Landing extras — pairs with js/landing-extras.js.
 * Removing both files (and the matching markup) restores the previous landing page. */

/* ===== Hero: fewer stacked layers ===== */
/* .hero::before duplicated .hero-aurora (same red radial, same drift) — one is enough */
.hero::before { display: none; }

/* ===== Hero: "horizon" ===== */
/* The lit edge of a dark planet rising under the buttons. Replaces the old aurora blobs.
   It's a wide ellipse rather than a circle: the arc stays flat enough to run out to both
   screen edges before the hero ends, at any screen size. */
.hero .hero-aurora { display: none; }

/* the backdrop only fades out in its last few percent, so the planet's lower part
   blends into the page instead of stopping at a hard line where the hero ends */
.hero .hero-backdrop {
  -webkit-mask-image: linear-gradient(180deg, #000 0%, #000 95%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 0%, #000 95%, transparent 100%);
}
.hero .hero-grid { opacity: 0.25; }

/* measured from the bottom: the hero keeps 120px of padding under the stat pills, so the
   edge always lands between the pills and the scroll arrow, whatever the screen height */
.hero-horizon {
  --horizon-top: calc(100% - 90px);
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.hero-horizon::before {
  content: '';
  position: absolute;
  left: 50%;
  top: var(--horizon-top);
  width: 140vw;
  height: 44vh;
  transform: translateX(-50%);
  border-radius: 50%;
  background: #06070b;
  box-shadow:
    0 -1px 0 rgba(210, 198, 255, 0.85),
    0 -18px 60px rgba(134, 110, 247, 0.55),
    0 -70px 180px rgba(104, 78, 235, 0.32),
    inset 0 1px 0 rgba(210, 198, 255, 0.6),
    inset 0 40px 80px -40px rgba(134, 110, 247, 0.45);
  animation: heroHorizonRise 1600ms cubic-bezier(0.16, 1, 0.3, 1) 300ms both;
}

/* atmosphere above the edge */
.hero-horizon::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(70% 28% at 50% var(--horizon-top), rgba(134,110,247, 0.22), transparent 70%);
  animation: heroHorizonGlow 1800ms ease 500ms both;
}

/* phones stack the metric pills, so they reach lower: the horizon sits under them and the
   scroll arrow (which is lower still) lands inside the planet */
@media (max-width: 768px) {
  body > .hero { padding-bottom: 130px; }
  .hero-horizon { --horizon-top: calc(100% - 82px); }
  .hero-horizon::before { width: 190vw; height: 40vh; }
  .hero .hero-backdrop {
    -webkit-mask-image: linear-gradient(180deg, #000 0%, #000 97%, transparent 100%);
    mask-image: linear-gradient(180deg, #000 0%, #000 97%, transparent 100%);
  }
  .scroll-indicator { bottom: 22px; }
}

@keyframes heroHorizonRise {
  from { opacity: 0; transform: translateX(-50%) translateY(60px); }
}

@keyframes heroHorizonGlow {
  from { opacity: 0; }
}

/* ===== Hero: "Completely." ===== */
/* A fixed red gradient (lighter at the top, deeper at the bottom) with a soft light that
   sweeps across now and then — replaces the endlessly panning pink/red hue shift. */
.hero-line-2 {
  background:
    linear-gradient(100deg, transparent 38%, rgba(235, 229, 255, 0.9) 50%, transparent 62%) no-repeat,
    linear-gradient(180deg, #b8aafb 0%, #866ef7 50%, #593de0 100%);
  background-size: 260% 100%, 100% 100%;
  background-position: 160% 0, 0 0;
  -webkit-background-clip: text;
  background-clip: text;
  animation:
    heroWordUpGlow 1000ms var(--apple-ease) both,
    heroSheen 7s cubic-bezier(0.45, 0, 0.2, 1) 1.6s infinite;
  animation-delay: 460ms, 1.6s;
}

@keyframes heroSheen {
  0%       { background-position: 160% 0, 0 0; }
  32%, 100% { background-position: -60% 0, 0 0; }
}

@media (prefers-reduced-motion: reduce) {
  .hero-horizon::before,
  .hero-horizon::after,
  .hero-line-2 { animation: none !important; }
  .hero-line-2 { opacity: 1; }
}
/* ===== Header: logged-in avatar chip ===== */
/* Without the name next to it, the chip's padding (5px 10px 5px 5px, room for the name)
   made it a 45×40 oval. Equal padding keeps it a circle. */
.nav-user-name:empty { display: none; }
.nav-user-chip:has(.nav-user-name:empty) { padding: 5px; }

@media (max-width: 520px) {
  .nav-user-chip { padding: 5px; }
}

/* ===== Hero: CTA buttons ===== */
.hero-cta .btn-ghost {
  background: rgba(255, 255, 255, 0.03);
  color: rgba(255, 255, 255, 0.82);
  border-color: rgba(255, 255, 255, 0.16);
}

.hero-cta .btn-ghost:hover {
  background: rgba(255, 255, 255, 0.07);
  color: #fff;
}

@property --glow-a {
  syntax: '<angle>';
  initial-value: 0deg;
  inherits: false;
}

.btn-glow {
  isolation: isolate;
  box-shadow: 0 10px 30px rgba(134,110,247, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

.btn-glow > span { position: relative; z-index: 1; }

/* rotating light running around the border */
.btn-glow::before {
  content: '';
  position: absolute;
  inset: -1.5px;
  border-radius: 11.5px;
  padding: 1.5px;
  background: conic-gradient(from var(--glow-a), transparent 0deg 220deg, rgba(255, 255, 255, 0.95) 280deg, #cfc4ff 310deg, transparent 350deg);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
  animation: btnGlowSpin 3.2s linear infinite;
  pointer-events: none;
}

/* soft halo that breathes behind the button */
.btn-glow::after {
  content: '';
  position: absolute;
  inset: 4px;
  border-radius: inherit;
  background: #866ef7;
  filter: blur(18px);
  opacity: 0.45;
  z-index: -1;
  transition: opacity 280ms ease;
}

.btn-glow:hover::after { opacity: 0.8; }

@keyframes btnGlowSpin {
  to { --glow-a: 360deg; }
}

/* ===== Section separators ===== */
/* The hairline the translate explainer already had, now between every section. The hero and
   the translate showcase (pulled up into the hero) stay without one; the footer has its own. */
body > section:not(.hero):not(.showcase-v3) {
  border-top: 1px solid var(--border);
}

/* keep at least ~120px between content and the line below it */
.explainer-section { padding-bottom: 130px; }
.cmx-section { padding-bottom: 150px; }

/* the proof strip already draws a line on both edges */
body > .proof-strip + section:not(.hero):not(.showcase-v3) { border-top: 0; }

/* ===== Command marquee ===== */
.cmd-marquee {
  position: relative;
  z-index: 2;
  padding: 44px 0;
  display: grid;
  gap: 12px;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}

.cmd-marquee-track {
  display: flex;
  gap: 12px;
  width: max-content;
  animation: cmdMarquee 70s linear infinite;
}

.cmd-marquee-row--rev .cmd-marquee-track {
  animation-direction: reverse;
  animation-duration: 82s;
}

.cmd-marquee:hover .cmd-marquee-track { animation-play-state: paused; }

@keyframes cmdMarquee {
  from { transform: translate3d(0, 0, 0); }
  to   { transform: translate3d(-50%, 0, 0); }
}

.cmd-marquee-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(14, 15, 20, 0.7);
  white-space: nowrap;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.5);
}

.cmd-marquee-pill b {
  font-family: 'JetBrains Mono', ui-monospace, Consolas, monospace;
  font-weight: 700;
  color: #a28efb;
}

/* ===== Control center: the real dashboard (pages/dashboard-demo.html) in an iframe ===== */
.cc-section {
  position: relative;
  z-index: 2;
  padding: 110px 0 120px;
  text-align: center;
}

.cc-stage {
  --cc-p: 0;
  max-width: 1380px;
  margin: 44px auto 0;
  padding: 0 24px;
  perspective: 1800px;
  text-align: left;
}

.cc-window {
  position: relative;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: #09090d;
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.6), 0 30px 90px -30px rgba(134,110,247, 0.35);
  transform: none;
  opacity: 1;
  overflow: hidden;
}

/* red light along the top edge */
.cc-window::before {
  content: '';
  position: absolute;
  left: 15%;
  right: 15%;
  top: 0;
  height: 1px;
  z-index: 2;
  background: linear-gradient(90deg, transparent, rgba(172,154,251, 0.9), transparent);
}

.cc-titlebar {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.03);
}

.cc-url {
  margin: 0 auto;
  padding: 4px 14px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  font-size: 12px;
  color: rgba(255, 255, 255, 0.45);
}

.cc-frame-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9.6;
  height: auto;
  min-height: 760px;
  max-height: 86vh;
  background: #09090d;
}

.cc-frame {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  background: #09090d;
  opacity: 0;
  transition: opacity 500ms ease;
}

.cc-stage.is-ready .cc-frame { opacity: 1; }

.cc-loading {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  pointer-events: none;
  transition: opacity 400ms ease;
}

.cc-loading span {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 3px solid rgba(134,110,247, 0.2);
  border-top-color: #866ef7;
  animation: ccSpin 0.9s linear infinite;
}

.cc-stage.is-ready .cc-loading { opacity: 0; }

@keyframes ccSpin { to { transform: rotate(360deg); } }

/* touch screens: the frame stays inert until tapped, so swiping over it scrolls the page */
.cc-touch-lock { display: none; }

@media (hover: none) {
  .cc-touch-lock {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding-bottom: 96px;
    border: 0;
    background: linear-gradient(180deg, transparent 55%, rgba(0, 0, 0, 0.55));
    color: #fff;
    font: inherit;
    cursor: pointer;
    transition: opacity 300ms ease;
  }

  .cc-stage.is-unlocked .cc-touch-lock { opacity: 0; pointer-events: none; }
}

.cc-touch-lock-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 18px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 700;
  background: #866ef7;
  box-shadow: 0 10px 30px rgba(134,110,247, 0.45);
}

.cc-demo-note {
  margin-top: 16px;
  text-align: center;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.4);
}
/* ===== Card border glow that follows the cursor (uses --spotlight-x/y set in landing-animations.js) ===== */
.feature-card > .card-ring,
.customcmd-card > .card-ring {
  position: absolute;
  inset: 0;
  z-index: 3;
  border-radius: inherit;
  padding: 1px;
  background: radial-gradient(260px circle at var(--spotlight-x, 50%) var(--spotlight-y, 50%), rgba(164,145,251, 0.85), rgba(134,110,247, 0.15) 45%, transparent 70%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
  opacity: 0;
  transition: opacity 320ms ease;
  pointer-events: none;
}

.feature-card.spotlight-active > .card-ring,
.customcmd-card.spotlight-active > .card-ring { opacity: 1; }

/* ===== Control center fallback (frame blocked or never ready) ===== */
.cc-fallback {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 24px;
  text-align: center;
  background: radial-gradient(60% 50% at 50% 40%, rgba(134,110,247, 0.12), transparent 70%), #09090d;
}

.cc-fallback[hidden] { display: none; }
.cc-fallback img { border-radius: 12px; margin-bottom: 6px; }
.cc-fallback strong { font-size: 18px; }
.cc-fallback span { max-width: 380px; font-size: 14px; color: rgba(255, 255, 255, 0.55); }
.cc-fallback .btn { margin-top: 10px; }

.cc-stage.is-failed .cc-frame-wrap { height: 360px; }
.cc-stage.is-failed .cc-loading,
.cc-stage.is-failed .cc-touch-lock,
.cc-stage.is-failed .cc-demo-note { display: none; }

/* ===== Features: numbered rows, each with a small real result =====
   Left: number, name, one sentence. Right: what you actually see in Discord.
   Hairlines between rows; the result sits on a quiet panel, no glow, no icons. */
.fx-head {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  align-items: end;
  gap: 48px;
  margin-bottom: 40px;
}
.fx-head .section-label { text-align: left; }
.fx-title {
  font-size: clamp(34px, 4.4vw, 52px);
  font-weight: 800;
  line-height: 1.04;
  letter-spacing: -0.035em;
  color: #fff;
  text-wrap: balance;
}
.fx-lede {
  max-width: 44ch;
  font-size: 17px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.7);
}

.fx-list {
  list-style: none;
  margin: 0;
  padding: 0;
  text-align: left;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}
.fx-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 24px 64px;
  align-items: center;
  padding: 36px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.fx-text {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 10px 0;
  align-items: baseline;
}
.fx-n {
  font-family: 'JetBrains Mono', ui-monospace, Consolas, monospace;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.35);
  transition: color 160ms ease-out;
}
.fx-row h3 {
  margin: 0;
  font-size: 24px;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: #fff;
}
.fx-text p {
  grid-column: 2;
  margin: 0;
  max-width: 46ch;
  font-size: 16px;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.65);
}
.fx-text kbd {
  padding: 1px 5px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.07);
  font-family: 'JetBrains Mono', ui-monospace, Consolas, monospace;
  font-size: 0.86em;
  color: #fff;
}

/* the result panel */
.fx-demo {
  display: grid;
  gap: 10px;
  padding: 18px 20px;
  border-radius: 10px;
  background: #111114;
  border: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 14px;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.82);
}

/* a Discord-style message */
.fx-msg { display: grid; grid-template-columns: 34px minmax(0, 1fr); gap: 12px; }
.fx-av {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: hsl(var(--h) 45% 32%);
  font-size: 14px;
  font-weight: 700;
  color: #fff;
}
.fx-meta { font-size: 12px; color: rgba(255, 255, 255, 0.4); margin-bottom: 2px; }
.fx-meta b { font-size: 14px; font-weight: 600; color: #fff; margin-right: 6px; }
.fx-said { color: rgba(255, 255, 255, 0.85); }
.fx-said em { font-style: normal; color: #c9cdfb; background: rgba(88, 101, 242, 0.25); padding: 0 2px; border-radius: 3px; }
.fx-orig { color: rgba(255, 255, 255, 0.4); text-decoration: line-through; text-decoration-color: rgba(255, 255, 255, 0.2); }
.fx-note { margin-top: 4px; font-size: 11px; color: rgba(255, 255, 255, 0.35); }

/* the slash-command menu */
.fx-menu { display: grid; gap: 2px; }
.fx-menu-q {
  margin-bottom: 6px;
  font-family: 'JetBrains Mono', ui-monospace, Consolas, monospace;
  font-size: 13px;
  color: #fff;
}
.fx-menu-q::after { content: ''; display: inline-block; width: 1px; height: 1em; margin-left: 2px; vertical-align: -2px; background: #fff; }
.fx-menu-i { display: flex; gap: 12px; align-items: baseline; padding: 6px 8px; border-radius: 5px; }
.fx-menu-i.is-on { background: rgba(255, 255, 255, 0.06); }
.fx-menu-i b { min-width: 86px; font-weight: 600; color: #fff; }
.fx-menu-i span { font-size: 13px; color: rgba(255, 255, 255, 0.45); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* automations */
.fx-toggles { list-style: none; margin: 0; padding: 0; display: grid; }
.fx-toggles li { display: flex; justify-content: space-between; align-items: center; padding: 9px 0; }
.fx-toggles li + li { border-top: 1px solid rgba(255, 255, 255, 0.06); }
.fx-toggles i {
  position: relative;
  width: 30px;
  height: 17px;
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.14);
}
.fx-toggles i::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: #fff;
}
.fx-toggles i.is-on { background: #3ba55d; }
.fx-toggles i.is-on::after { left: 15px; }

/* custom command template */
.fx-tpl {
  padding-bottom: 10px;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.1);
  font-family: 'JetBrains Mono', ui-monospace, Consolas, monospace;
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.45);
}
.fx-tpl span { color: #fff; margin-right: 8px; }

@media (hover: hover) {
  .fx-row:hover .fx-n { color: var(--accent, #866ef7); }
}

/* ===== Commands: tags + one live preview ===== */
.cmx {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  align-items: center;
  gap: 64px;
}

.cmx-text,
.cmx-text .section-label,
.cmx-text .section-title,
.cmx-text .section-subtitle { text-align: left; }
.cmx-text .section-title { font-size: clamp(36px, 4vw, 50px); text-wrap: wrap; }
.cmx-text .section-subtitle { margin: 0; font-size: 17px; }
.cmx-slash { color: #866ef7; -webkit-text-fill-color: #866ef7; }

.cmx-tabs {
  display: inline-flex;
  gap: 4px;
  margin-top: 32px;
  padding: 4px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
}

.cmx-tab {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: rgba(255, 255, 255, 0.55);
  font: 700 13px 'Manrope', sans-serif;
  cursor: pointer;
  transition: background 240ms ease, color 240ms ease;
}

.cmx-tab span {
  min-width: 20px;
  padding: 1px 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  font-size: 11px;
}

.cmx-tab:hover { color: #fff; }
.cmx-tab.is-active { background: #866ef7; color: #fff; }
.cmx-tab.is-active span { background: rgba(0, 0, 0, 0.2); }

.cmx-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
  min-height: 92px;
  align-content: flex-start;
}

.cmx-pill {
  padding: 7px 12px;
  border-radius: 9px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.025);
  color: rgba(255, 255, 255, 0.7);
  font: 600 13px 'JetBrains Mono', ui-monospace, Consolas, monospace;
  cursor: pointer;
  transition: color 200ms ease, border-color 200ms ease, background 200ms ease;
  animation: cmxIn 360ms cubic-bezier(0.16, 1, 0.3, 1) both;
}

.cmx-pill:hover { color: #fff; border-color: rgba(255, 255, 255, 0.22); }

.cmx-pill.is-active {
  color: #fff;
  border-color: rgba(134,110,247, 0.6);
  background: rgba(134,110,247, 0.14);
  box-shadow: 0 0 0 3px rgba(134,110,247, 0.08);
}

.cmx-more { margin-top: 22px; font-size: 13px; color: rgba(255, 255, 255, 0.4); }
.cmx-more strong { color: rgba(255, 255, 255, 0.7); font-weight: 700; }

.cmx-preview { position: relative; }

/* soft red light behind the card */
.cmx-preview::before {
  content: '';
  position: absolute;
  inset: 10% 8%;
  background: radial-gradient(closest-side, rgba(134,110,247, 0.22), transparent);
  filter: blur(40px);
  pointer-events: none;
}

.cmx-card {
  position: relative;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  background: linear-gradient(180deg, rgba(22, 23, 30, 0.96), rgba(12, 13, 18, 0.98));
  /* same red glow underneath as the Message recovery card */
  box-shadow: 0 40px 100px rgba(0, 0, 0, 0.55), 0 30px 80px -40px rgba(134,110,247, 0.35);
  overflow: hidden;
}

.cmx-card-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 13px 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  font-weight: 800;
  font-size: 14px;
}

.cmx-hash { font-size: 20px; font-weight: 500; line-height: 1; color: rgba(255, 255, 255, 0.35); }

.cmx-stage {
  height: 380px;
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 14px;
  overflow: hidden;
}

.cmx-msg {
  display: grid;
  grid-template-rows: 1fr;
  animation: cmxIn 420ms cubic-bezier(0.16, 1, 0.3, 1) both;
  transition: grid-template-rows 450ms cubic-bezier(0.22, 1, 0.36, 1), opacity 300ms ease, margin 450ms ease;
}
.cmx-msg > * { min-height: 0; }
.cmx-msg-main { display: flex; gap: 12px; min-height: 0; overflow: hidden; }
/* deleted messages (purge, ghost ping) fold away */
.cmx-msg.is-gone { grid-template-rows: 0fr; opacity: 0; margin-top: -14px; }
.cmx-msg.is-gone .cmx-msg-main { min-height: 0; }

/* Discord's "You used /command" line above a command reply */
.cmx-used {
  position: relative;
  display: flex;
  align-items: center;
  gap: 5px;
  margin: 0 0 4px 50px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.45);
  white-space: nowrap;
}
.cmx-used b { color: rgba(255, 255, 255, 0.8); font-weight: 600; }
.cmx-used-av { width: 16px; height: 16px; display: grid; place-items: center; border-radius: 50%; background: #5865f2; color: #fff; font-size: 9px; font-weight: 800; }
.cmx-used-cmd { color: #8ab4ff; }
.cmx-used-curve { position: absolute; left: -31px; top: 8px; width: 26px; height: 10px; border: 2px solid rgba(255, 255, 255, 0.15); border-right: 0; border-bottom: 0; border-radius: 6px 0 0 0; }
.cmx-av {
  width: 38px;
  height: 38px;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #5865f2;
  color: #fff;
  font-weight: 800;
  overflow: hidden;
}

.cmx-av--other { background: #3ba55d; }
.cmx-msg--bot .cmx-av { background: rgba(134,110,247, 0.12); }
.cmx-av img { width: 26px; height: 26px; }

.cmx-col { flex: 1; min-width: 0; }
.cmx-head { display: flex; align-items: center; gap: 7px; margin-bottom: 3px; }
.cmx-name { font-weight: 800; font-size: 14.5px; }
.cmx-msg--bot .cmx-name { color: #a28efb; }
.cmx-app { padding: 1px 5px; border-radius: 4px; background: #5865f2; color: #fff; font-size: 9px; font-weight: 800; }
.cmx-time { font-size: 11px; color: rgba(255, 255, 255, 0.3); }

.cmx-line { font-size: 14.5px; line-height: 1.45; color: rgba(255, 255, 255, 0.86); overflow-wrap: anywhere; }
.cmx-line + .cmx-line { margin-top: 2px; }
.cmx-muted { color: rgba(255, 255, 255, 0.5); font-style: italic; }
.cmx-spam { animation: cmxIn 300ms ease both; }
.cmx-spam:nth-child(3) { animation-delay: 80ms; }
.cmx-spam:nth-child(4) { animation-delay: 160ms; }
.cmx-spam:nth-child(5) { animation-delay: 240ms; }
.cmx-zalgo { line-height: 2.2; overflow: hidden; }

.cmx-chip { display: inline-block; padding: 1px 7px; border-radius: 5px; background: rgba(88, 101, 242, 0.24); color: #c9cdfb; font-weight: 700; }
.cmx-mention { display: inline-block; padding: 1px 4px; border-radius: 4px; background: rgba(88, 101, 242, 0.25); color: #c9cdfb; }
.cmx-ghost { animation: cmxGhost 1.6s ease 0.6s both; }

@keyframes cmxGhost {
  to { opacity: 0.25; text-decoration: line-through; filter: blur(1px); }
}

/* embed, laid out like the bot's createUserEmbed(): author, title, description,
   "|  Label" fields (inline ones three to a row), optional thumbnail, footer */
.cmx-embed {
  --ec: #866ef7;
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 4px;
  max-width: 440px;
  margin-top: 4px;
  padding: 10px 14px 10px 16px;
  border-radius: 6px;
  border-left: 4px solid var(--ec);
  background: rgba(255, 255, 255, 0.045);
}
.cmx-embed.has-thumb { grid-template-columns: minmax(0, 1fr) 44px; column-gap: 12px; }
.cmx-embed > :not(.cmx-embed-thumb) { grid-column: 1; }
.cmx-embed-thumb {
  grid-column: 2;
  grid-row: 1 / span 3;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font-size: 14px;
  font-weight: 800;
}
.cmx-embed-author { display: flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; color: #fff; }
.cmx-embed-icon {
  width: 16px;
  height: 16px;
  flex: none;
  border-radius: 50%;
  background: url('../assets/logos/primary.png') center / 80% no-repeat, rgba(134,110,247, 0.15);
}
.cmx-embed-icon.is-discord { background: #5865f2; }
.cmx-embed-title { font-weight: 800; font-size: 14px; color: #fff; }
.cmx-embed-desc { font-size: 13px; line-height: 1.45; color: rgba(255, 255, 255, 0.8); overflow-wrap: anywhere; }
.cmx-embed-code {
  margin: 2px 0 0;
  padding: 6px 9px;
  border-radius: 5px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(0, 0, 0, 0.3);
  font: 500 12px/1.45 'JetBrains Mono', ui-monospace, Consolas, monospace;
  color: rgba(255, 255, 255, 0.85);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.cmx-fields { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px 12px; margin-top: 2px; }
.cmx-field { min-width: 0; }
.cmx-field.is-full { grid-column: 1 / -1; }
.cmx-field-name { font-size: 12px; font-weight: 700; color: #fff; white-space: pre; }
.cmx-field-value { font-size: 12.5px; line-height: 1.45; color: rgba(255, 255, 255, 0.78); overflow-wrap: anywhere; }
.cmx-embed-footer { display: flex; align-items: center; gap: 6px; margin-top: 3px; font-size: 11px; color: rgba(255, 255, 255, 0.42); }
.cmx-embed-footer .cmx-embed-icon { width: 14px; height: 14px; }
.cmx-code { padding: 0 4px; border-radius: 4px; background: rgba(0, 0, 0, 0.35); font: 500 0.9em 'JetBrains Mono', ui-monospace, Consolas, monospace; }
.cmx-quote { display: block; padding-left: 10px; border-left: 3px solid rgba(255, 255, 255, 0.25); }

.cmx-buttons { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.cmx-btn { padding: 6px 14px; border-radius: 4px; background: #5865f2; color: #fff; font-size: 13px; font-weight: 600; }
.cmx-btn.is-link { background: #4e5058; }

.cmx-file {
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: 320px;
  margin-top: 6px;
  padding: 9px 12px;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
}
.cmx-file-icon {
  flex: none;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 7px;
  background: rgba(88, 101, 242, 0.25);
  color: #c9cdfb;
  font: 700 11px 'JetBrains Mono', ui-monospace, Consolas, monospace;
}
.cmx-file--audio .cmx-file-icon { border-radius: 50%; background: #5865f2; color: #fff; font-size: 12px; }
.cmx-file-meta { display: grid; min-width: 0; }
.cmx-file-meta b { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 13px; font-weight: 600; color: #8ab4ff; }
.cmx-file-meta small { font-size: 11px; color: rgba(255, 255, 255, 0.42); }

.cmx-thinking { display: flex; align-items: center; gap: 8px; font-size: 13.5px; font-style: italic; color: rgba(255, 255, 255, 0.5); }
.cmx-thinking .cmx-typing { padding-left: 0; }

.cmx-typingbar { display: flex; align-items: center; gap: 6px; margin-top: -4px; font-size: 12px; color: rgba(255, 255, 255, 0.55); animation: cmxIn 300ms ease both; }
.cmx-typingbar b { color: #fff; }
.cmx-typingbar .cmx-typing { padding-left: 0; }

.cmx-group { font-size: 15px; line-height: 1; }

.cmx-reacts { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 6px; }

/* phones: the same messages, tighter, so the tallest replies still fit the preview */
@media (max-width: 640px) {
  .cmx-stage { gap: 10px; }
  .cmx-msg-main { gap: 10px; }
  .cmx-av { width: 32px; height: 32px; font-size: 13px; }
  .cmx-av img { width: 22px; height: 22px; }
  .cmx-used { margin-left: 42px; font-size: 11px; }
  .cmx-used-curve { left: -27px; width: 22px; }
  .cmx-name { font-size: 13.5px; }
  .cmx-line { font-size: 13.5px; }
  .cmx-zalgo { line-height: 1.8; }
  .cmx-embed { gap: 3px; padding: 8px 10px 8px 12px; }
  .cmx-embed.has-thumb { grid-template-columns: minmax(0, 1fr) 34px; column-gap: 8px; }
  .cmx-embed-thumb { width: 34px; height: 34px; font-size: 12px; }
  .cmx-embed-author { font-size: 11px; }
  .cmx-embed-icon { width: 14px; height: 14px; }
  .cmx-embed-title { font-size: 13px; }
  .cmx-embed-desc { font-size: 12px; line-height: 1.4; }
  .cmx-embed-code { padding: 4px 7px; font-size: 11px; }
  .cmx-fields { gap: 4px 10px; }
  .cmx-field-name { font-size: 11px; }
  .cmx-field-value { font-size: 11.5px; }
  .cmx-embed-footer { margin-top: 1px; font-size: 10px; }
  .cmx-embed-footer .cmx-embed-icon { width: 12px; height: 12px; }
  .cmx-buttons { gap: 6px; margin-top: 6px; }
  .cmx-btn { padding: 5px 11px; font-size: 12px; }
  .cmx-file { margin-top: 4px; padding: 7px 10px; }
}
.cmx-react {
  padding: 2px 8px;
  border-radius: 8px;
  border: 1px solid rgba(88, 101, 242, 0.5);
  background: rgba(88, 101, 242, 0.15);
  font-size: 12px;
  animation: cmxPop 380ms cubic-bezier(0.34, 1.56, 0.64, 1) 0.9s both;
}

.cmx-react:nth-child(2) { animation-delay: 1s; }
.cmx-react:nth-child(3) { animation-delay: 1.1s; }

.cmx-typing { display: flex; gap: 4px; padding-left: 50px; }
.cmx-typing i { width: 6px; height: 6px; border-radius: 50%; background: rgba(255, 255, 255, 0.45); animation: cmxDot 0.9s ease-in-out infinite; }
.cmx-typing i:nth-child(2) { animation-delay: 0.15s; }
.cmx-typing i:nth-child(3) { animation-delay: 0.3s; }

@keyframes cmxIn {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: none; }
}

@keyframes cmxPop {
  from { opacity: 0; transform: scale(0.6); }
  to   { opacity: 1; transform: none; }
}

@keyframes cmxDot { 50% { transform: translateY(-3px); opacity: 0.4; } }

.cmx-foot { position: relative; margin-top: 16px; }
.cmx-caption { min-height: 21px; font-size: 14px; color: rgba(255, 255, 255, 0.55); }
.cmx-caption b { font-family: 'JetBrains Mono', ui-monospace, Consolas, monospace; color: #fff; }

.cmx-progress {
  height: 2px;
  margin-top: 12px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.cmx-progress span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #866ef7, #baacfc);
  transform: scaleX(0);
  transform-origin: left;
}

.cmx.is-paused .cmx-progress span { opacity: 0.45; }

/* giveaway radar: server icons and the logo scale with the radar (--size), so a smaller
   radar on phones doesn't leave them overlapping each other and the edge */
.gw-blip {
  --blip: max(26px, calc(var(--size, 300px) * 0.1));
  width: var(--blip);
  height: var(--blip);
  margin: calc(var(--blip) / -2) 0 0 calc(var(--blip) / -2);
  font-size: max(9px, calc(var(--blip) * 0.34));
}
.gw-core {
  width: calc(var(--size, 300px) * 0.155);
  height: calc(var(--size, 300px) * 0.155);
  border-radius: calc(var(--size, 300px) * 0.047);
}
.gw-core img { width: 65%; height: 65%; }

/* gradient numbers (background-clip: text) with line-height 1 would cut the "/" in 24/7 */
.stat-number { padding-bottom: 0.08em; }

/* ===== Message recovery: text beside a Discord channel that plays two short scenes ===== */
.rc-section {
  position: relative;
  z-index: 2;
  padding: 120px 0;
}

.rc {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  align-items: center;
  gap: 64px;
}

.rc-text,
.rc-text .section-label,
.rc-text .section-title,
.rc-text .section-subtitle { text-align: left; }
.rc-text .section-title { font-size: clamp(36px, 4vw, 50px); padding-bottom: 0.06em; }
.rc-text .section-subtitle { margin: 0; font-size: 17px; }

/* the two things it recovers; the one playing is lit and shows its progress */
.rc-modes {
  list-style: none;
  display: grid;
  gap: 10px;
  margin-top: 32px;
}

.rc-mode {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.02);
  overflow: hidden;
  transition: border-color 400ms ease, background-color 400ms ease;
}

.rc-mode-icon {
  flex: none;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.05);
  color: rgba(255, 255, 255, 0.45);
  transition: background-color 400ms ease, color 400ms ease, box-shadow 400ms ease;
}

.rc-mode-copy { display: grid; gap: 2px; min-width: 0; }
.rc-mode-copy b { font-size: 15px; color: rgba(255, 255, 255, 0.55); transition: color 400ms ease; }
.rc-mode-copy small { font-size: 13px; color: rgba(255, 255, 255, 0.4); }
.rc-mode-copy code,
.rc-text code {
  padding: 1px 6px;
  border-radius: 5px;
  background: rgba(134,110,247, 0.12);
  font: 600 0.9em 'JetBrains Mono', ui-monospace, Consolas, monospace;
  color: #baacfc;
}

.rc-mode-bar {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: rgba(255, 255, 255, 0.04);
}
.rc-mode-bar i {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #866ef7, #baacfc);
  transform: scaleX(0);
  transform-origin: left;
}

.rc-mode.is-on { border-color: rgba(134,110,247, 0.3); background: rgba(134,110,247, 0.06); }
.rc-mode.is-on .rc-mode-icon { background: #866ef7; color: #fff; box-shadow: 0 8px 22px -8px rgba(134,110,247, 0.8); }
.rc-mode.is-on .rc-mode-copy b { color: #fff; }
.rc-mode.is-on .rc-mode-bar i { animation: rcBar var(--rc-dur, 9s) linear forwards; }
.rc.is-paused .rc-mode-bar i { animation-play-state: paused; }

@keyframes rcBar { to { transform: scaleX(1); } }

/* ---- the channel ---- */
.rc-card {
  display: flex;
  flex-direction: column;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  background: linear-gradient(180deg, rgba(22, 23, 30, 0.96), rgba(12, 13, 18, 0.98));
  box-shadow: 0 40px 100px rgba(0, 0, 0, 0.55), 0 30px 80px -40px rgba(134,110,247, 0.35);
  overflow: hidden;
  text-align: left;
}

.rc-head {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 14px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 15px;
  font-weight: 700;
}
.rc-hash { color: rgba(255, 255, 255, 0.35); font-size: 20px; font-weight: 500; line-height: 1; }
.rc-saved {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-left: auto;
  font-size: 12px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.4);
}
.rc-saved i { width: 7px; height: 7px; border-radius: 50%; background: #43b581; box-shadow: 0 0 0 3px rgba(67, 181, 129, 0.18); }

/* messages stack from the bottom, like a real channel; the height never changes */
.rc-log {
  height: 340px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 10px 18px 6px;
  overflow: hidden;
  transition: opacity 400ms ease;
}
.rc-log.is-clearing { opacity: 0; }

/* every row opens and closes its own height, so nothing jumps */
.rc-row {
  display: grid;
  grid-template-rows: 1fr;
  transition: grid-template-rows 520ms cubic-bezier(0.22, 1, 0.36, 1), opacity 380ms ease;
}
.rc-row-in { min-height: 0; overflow: hidden; }
.rc-row.is-new { animation: rcIn 520ms cubic-bezier(0.22, 1, 0.36, 1) both; }
.rc-row.is-gone { grid-template-rows: 0fr; opacity: 0; }

@keyframes rcIn {
  from { grid-template-rows: 0fr; opacity: 0; }
  to { grid-template-rows: 1fr; opacity: 1; }
}

.rc-msg { display: flex; gap: 12px; padding: 8px 0; }

.rc-av {
  flex: none;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--c, #5865f2);
  color: #fff;
  font-size: 15px;
  font-weight: 800;
}
.rc-av--bot { background: rgba(134,110,247, 0.12); }

.rc-body { flex: 1; min-width: 0; }
.rc-meta { display: flex; align-items: center; gap: 7px; margin-bottom: 2px; font-size: 11.5px; color: rgba(255, 255, 255, 0.32); }
.rc-meta b { font-size: 15px; font-weight: 700; color: var(--n, #fff); }
.rc-meta .rc-bot { color: #a28efb; }
.rc-app { padding: 1px 5px; border-radius: 4px; background: #5865f2; color: #fff; font-size: 9px; font-weight: 800; }

.rc-line {
  position: relative;
  font-size: 15px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.88);
  transition: color 350ms ease;
}
.rc-edited { margin-left: 4px; font-size: 11px; color: rgba(255, 255, 255, 0.35); }

/* the message about to be deleted flushes red and strikes through */
.rc-line s {
  text-decoration: none;
  background: linear-gradient(currentColor, currentColor) 0 55% / 0 1.5px no-repeat;
  transition: background-size 450ms cubic-bezier(0.65, 0, 0.35, 1);
}
.rc-row.is-deleting .rc-line { color: #baacfc; }
.rc-row.is-deleting .rc-line s { background-size: 100% 1.5px; }

/* the edited text swaps in place */
.rc-swap { display: inline-grid; }
.rc-swap > span { grid-area: 1 / 1; transition: opacity 350ms ease, transform 350ms ease, filter 350ms ease; }
.rc-swap > span:last-child { opacity: 0; transform: translateY(6px); filter: blur(3px); }
.rc-row.is-edited .rc-swap > span:first-child { opacity: 0; transform: translateY(-6px); filter: blur(3px); }
.rc-row.is-edited .rc-swap > span:last-child { opacity: 1; transform: none; filter: none; }

.rc-note {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 4px 0 4px 50px;
  font-size: 12.5px;
  font-style: italic;
  color: rgba(255, 255, 255, 0.35);
}

.rc-cmd {
  display: inline-block;
  padding: 1px 7px;
  border-radius: 6px;
  background: rgba(88, 101, 242, 0.24);
  color: #c9cdfb;
  font-weight: 600;
}

.rc-embed {
  position: relative;
  display: grid;
  gap: 5px;
  margin-top: 4px;
  padding: 11px 14px 12px 17px;
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.045);
}
.rc-embed::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  border-radius: 7px 0 0 7px;
  background: #866ef7;
}
.rc-embed-title { font-size: 14px; font-weight: 800; color: #fff; }
.rc-embed-text { font-size: 14.5px; line-height: 1.5; color: rgba(255, 255, 255, 0.88); }
.rc-embed-meta { font-size: 12px; color: rgba(255, 255, 255, 0.42); }
.rc-embed-row { display: grid; grid-template-columns: 52px minmax(0, 1fr); gap: 8px; font-size: 14px; line-height: 1.5; }
.rc-embed-row > span:first-child { font-size: 11px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: rgba(255, 255, 255, 0.35); padding-top: 2px; }
.rc-embed-row--old > span:last-child { color: rgba(255, 255, 255, 0.55); }

/* the recovered text lights up as it lands */
.rc-row.is-new .rc-embed { animation: rcGlow 1.4s ease-out 250ms both; }
@keyframes rcGlow {
  from { box-shadow: 0 0 0 0 rgba(134,110,247, 0.45); background: rgba(134,110,247, 0.12); }
  to { box-shadow: 0 0 0 10px rgba(134,110,247, 0); background: rgba(255, 255, 255, 0.045); }
}

/* ---- composer: the command is typed here before it's sent ---- */
.rc-composer {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 6px 14px 14px;
  padding: 11px 14px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.05);
  color: rgba(255, 255, 255, 0.4);
}
.rc-plus { display: grid; }
.rc-input { position: relative; display: flex; align-items: center; min-height: 22px; font-size: 14.5px; }
.rc-typed { color: #fff; font-family: 'JetBrains Mono', ui-monospace, Consolas, monospace; font-size: 14px; }
.rc-caret { display: none; width: 2px; height: 17px; margin-left: 1px; background: #fff; animation: rcBlink 1s steps(1) infinite; }
.rc-composer.is-typing .rc-caret { display: block; }
.rc-composer.is-typing .rc-placeholder { display: none; }
@keyframes rcBlink { 50% { opacity: 0; } }

@media (max-width: 900px) {
  .rc { grid-template-columns: minmax(0, 1fr); gap: 32px; }
  .rc-text,
  .rc-text .section-label,
  .rc-text .section-title,
  .rc-text .section-subtitle { text-align: center; }
  .rc-text .section-subtitle { margin: 0 auto; max-width: 560px; }
  .rc-modes { grid-template-columns: repeat(2, minmax(0, 1fr)); margin-top: 24px; text-align: left; }
  .rc-card { width: min(600px, 100%); margin: 0 auto; }
}

@media (max-width: 640px) {
  .rc-section { padding: 80px 0 100px; }
  .rc { gap: 22px; }
  .rc-text .section-title { font-size: clamp(30px, 8.4vw, 36px); line-height: 1.2; }
  .rc-text .section-subtitle { font-size: 15px; }
  .rc-modes { gap: 8px; margin-top: 18px; }
  .rc-mode { flex-direction: column; align-items: flex-start; gap: 8px; padding: 12px; }
  .rc-mode-icon { width: 32px; height: 32px; border-radius: 9px; }
  .rc-mode-copy b { font-size: 13.5px; }
  .rc-mode-copy small { font-size: 12px; }
  .rc-head { padding: 12px 14px; }
  .rc-saved { font-size: 11px; }
  .rc-log { height: 300px; padding: 8px 14px 4px; }
  .rc-av { width: 34px; height: 34px; font-size: 14px; }
  .rc-msg { gap: 10px; }
  .rc-note { margin-left: 44px; }
  .rc-line { font-size: 14.5px; }
  .rc-composer { margin: 4px 10px 10px; }
}

@media (prefers-reduced-motion: reduce) {
  .rc-row,
  .rc-row.is-new,
  .rc-row.is-new .rc-embed,
  .rc-swap > span,
  .rc-line s,
  .rc-caret { animation: none !important; transition: none !important; }
  .rc-mode.is-on .rc-mode-bar i { animation: none; transform: scaleX(1); }
}

/* ===== Responsive ===== */
/* below ~1070px the frame is narrower than 1025px, so the dashboard inside switches to
   its own tablet layout (top tab bar, full-bleed) — same as opening magcord.bond/dashboard there */
@media (max-width: 1100px) {
  .cc-frame-wrap { aspect-ratio: auto; min-height: 0; max-height: none; height: 760px; }
}

@media (max-width: 1024px) {
  .cmx { gap: 40px; }
}

@media (max-width: 900px) {
  .cmx { grid-template-columns: minmax(0, 1fr); }
  .cmx-text,
  .cmx-text .section-label,
  .cmx-text .section-title,
  .cmx-text .section-subtitle { text-align: center; }
  .cmx-text .section-subtitle { margin: 0 auto; }
  .cmx-pills { justify-content: center; min-height: 0; }
}

@media (max-width: 700px) {
  .fx-head { grid-template-columns: minmax(0, 1fr); gap: 16px; margin-bottom: 28px; }
  .fx-row { grid-template-columns: minmax(0, 1fr); gap: 18px; padding: 26px 0; }
  .fx-text { grid-template-columns: 36px minmax(0, 1fr); }
  .fx-row h3 { font-size: 20px; }
  .fx-demo { margin-left: 36px; padding: 14px 16px; }
}

@media (max-width: 768px) {
  .cmd-marquee { padding: 32px 0; }
  .cmd-marquee-pill { padding: 8px 13px; font-size: 12px; }
  .cc-section { padding: 80px 0 110px; }
  /* phones: same rule, at least ~110px between content and the next line */
  body > .explainer-section { padding-bottom: 140px; }
  body > .cmx-section { padding-bottom: 130px; }
  body > .giveaway-section { padding-bottom: 116px; }
  body > .ocr-section { padding-bottom: 125px; }
  body > .gp-section { padding-bottom: 120px; }
  .cc-stage { margin-top: 36px; padding: 0 16px; }
  .cc-url { font-size: 11px; }
  .cmx-tab { padding: 8px 11px; }
  .cmx-stage { height: 360px; padding: 16px; }
}

/* phones: the frame is rendered at the visitor's own screen size and scaled down to fit
   (--cc-w/--cc-h/--cc-s from landing-extras.js), so the dashboard inside lays out exactly
   like magcord.bond/dashboard on that phone, a full screen tall */
@media (max-width: 640px) {
  .cc-stage { max-width: 420px; }
  .cc-window { border-radius: 30px; border-color: rgba(255, 255, 255, 0.14); }
  .cc-titlebar { display: none; }
  .cc-frame-wrap { height: min(760px, 78svh); overflow: hidden; }
  .cc-stage.is-scaled .cc-window { width: calc(var(--cc-w) * var(--cc-s)); margin: 0 auto; border-radius: 24px; }
  .cc-stage.is-scaled .cc-frame-wrap { height: calc(var(--cc-h) * var(--cc-s)); }
  .cc-stage.is-scaled .cc-frame {
    width: var(--cc-w);
    height: var(--cc-h);
    transform: scale(var(--cc-s));
    transform-origin: 0 0;
  }
}

/* ===== Phones: the hero is exactly the first screen =====
   100vh is the screen with Safari's bars hidden, so at the top of the page (bars shown,
   e.g. 393x659 on an iPhone 15 Pro) the buttons and metrics were below the fold.
   100svh is the visible part; the content is laid out to fit it. */
@media (max-width: 640px) {
  body .hero {
    min-height: 0;
    height: 100vh;
    height: 100svh;
    padding: calc(64px + env(safe-area-inset-top)) 0 20px;
  }
  body .hero-inner { display: flex; flex-direction: column; align-items: center; }
  body .hero-badge { margin-bottom: clamp(14px, 3svh, 26px); padding: 7px 16px; font-size: 12px; }
  body .hero-headline { margin-bottom: clamp(12px, 2.4svh, 20px); font-size: clamp(40px, 12vw, 52px); line-height: 1.05; }
  body .hero-subtitle { margin-bottom: clamp(18px, 3.6svh, 32px); font-size: 15.5px; line-height: 1.5; }
  body .hero-cta { flex-direction: row; gap: 10px; width: 100%; }
  body .hero-cta .btn-lg { flex: 1 1 0; max-width: 180px; padding: 13px 10px; font-size: 15px; }
  body .hero-metrics { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; width: 100%; margin-top: clamp(18px, 3.6svh, 32px); padding: 0; }
  body .hero-metric { min-width: 0; padding: 9px 4px; border-radius: 16px; }
  body .hero-metric strong { font-size: 18px; }
  body .hero-metric span { font-size: 9px; letter-spacing: 0.06em; }
  body .scroll-indicator { display: none; }
}

/* ===== Phones: sections that only make sense seen whole fit one screen =====
   The demo dashboard and the live previews (commands, giveaway radar, OCR scan, ghost
   ping, custom commands) are a heading plus one visual; on phones they stay within 100svh
   (checked at 375x812 and 375x667). Every other section keeps its normal length. */
@media (max-width: 640px) {
  body > :is(.cc-section, .cmx-section, .giveaway-section, .ocr-section, .gp-section, .cmd-section) {
    padding-top: 64px !important;
    padding-bottom: 40px !important;
  }
  :is(.cc-section, .cmx-section, .giveaway-section, .ocr-section, .gp-section, .cmd-section) .section-label { margin-bottom: 8px; font-size: 11px; }
  :is(.cc-section, .cmx-section, .giveaway-section, .ocr-section, .gp-section, .cmd-section) .section-title {
    margin-bottom: 8px;
    /* gradient text (background-clip: text) is cut at the box edge, so leave room for descenders */
    padding-bottom: 0.08em;
    font-size: clamp(26px, 7.4vw, 32px);
    line-height: 1.2;
  }
  :is(.cc-section, .cmx-section, .giveaway-section, .ocr-section, .gp-section, .cmd-section) .section-subtitle { margin-bottom: 22px; font-size: 14.5px; line-height: 1.5; }

  /* control center: the subtitle is the demo note's job on phones */
  .cc-section .section-subtitle { display: none; }
  .cc-stage { margin-top: 18px; }
  .cc-demo-note { margin-top: 10px; font-size: 12px; }

  /* commands: tags + a shorter preview */
  .cmx { gap: 20px; }
  .cmx-text .section-subtitle,
  .cmx-more { display: none; }
  .cmx-tabs { margin-top: 4px; }
  /* the command tags as one swipeable row instead of three wrapped lines */
  body .cmx-pills {
    flex-wrap: nowrap;
    justify-content: flex-start;
    margin: 12px -16px 0;
    padding: 2px 16px 4px;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 16px, #000 calc(100% - 16px), transparent);
            mask-image: linear-gradient(90deg, transparent, #000 16px, #000 calc(100% - 16px), transparent);
  }
  body .cmx-pills::-webkit-scrollbar { display: none; }
  body .cmx-pill { flex: none; }
  body .cmx-stage { height: clamp(300px, 42svh, 350px); padding: 14px 14px; }

  /* giveaway joiner: smaller radar, entries capped */
  body .gw-radar { --size: min(220px, 60vw); }
  body .gw-radar-wrap { padding: 18px 16px 14px; }
  body .gw-tickets-wrap { padding: 14px 16px; }
  body .gw-tickets { height: 150px; }
  .giveaway-section .section-subtitle,
  .gw-speed-text { display: none; }
  body .gw-speed { padding: 12px 16px; gap: 10px; }

  /* OCR: shorter scan, compact stats */
  body .ocr-scan-frame { height: clamp(236px, 32svh, 280px); }
  /* four lines of text below the corner labels, in a size that fits a phone */
  body .ocr-layer-copy { padding: 44px 6% 12px; gap: 6px; }
  body .ocr-text-line { gap: 10px; padding: 3px 8px 3px 0; font-size: 13px; }
  body .ocr-text-line--selected { background: linear-gradient(90deg, transparent 0 26px, rgba(134,110,247, 0.28) 26px); }
  body .ocr-flyer-line { font-size: 24px; }
  body .ocr-flyer-line--lg { font-size: 36px; }
  body .ocr-flyer-line--sm { font-size: 12.5px; }
  body .ocr-corner-label { top: 12px; left: 12px; padding: 4px 8px; font-size: 10px; }
  body .ocr-corner-label--right { left: auto; right: 12px; }
  body .ocr-scan-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  body .ocr-stat { padding: 10px 12px; }

  /* ghost ping: smaller phone, timeline without the extras */
  body .gp-stage { gap: 16px; }
  body .gp-device { zoom: 0.62; }
  .gp-channel,
  .gp-tags,
  .gp-timeline-head,
  .gp-step-note { display: none !important; }
  body .gp-timeline { padding: 14px 16px; }
  .gp-section .section-subtitle { margin-bottom: 12px; }

  /* custom commands: the command list becomes a row of chips */
  .cmd-section .section-subtitle,
  .cx-suggest-head,
  .cx-suggest-row span,
  .cx-flow,
  .cx-legend { display: none !important; }
  body .cx { gap: 12px; }
  body .cx-composer { gap: 8px; }
  /* the four commands as one segmented switch, like the Commands section's tabs */
  body .cx-suggest {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 4px;
    padding: 4px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    background: #111114;
    box-shadow: none;
  }
  body .cx-suggest-row {
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 0;
    min-height: 36px;
    padding: 0 4px;
    border-radius: 10px;
    transition: background-color 250ms ease, color 250ms ease;
  }
  body .cx-suggest-row b { font-size: 12.5px; font-weight: 700; color: rgba(255, 255, 255, 0.6); transition: color 250ms ease; }
  body .cx-suggest-row b::before { content: '/'; color: rgba(255, 255, 255, 0.3); }
  body .cx-suggest-row.is-active { background: #866ef7; box-shadow: 0 6px 18px -6px rgba(134,110,247, 0.7); }
  body .cx-suggest-row.is-active b,
  body .cx-suggest-row.is-active b::before { color: #fff; }
  body .cx-input { border-radius: 14px; }
  body .cx-split { gap: 0; }
  body .cx-pane { gap: 10px; padding: 14px; }
  .cx-out-note { display: none !important; }
}

/* short phones (iPhone SE and similar): the same sections, a notch tighter */
@media (max-width: 640px) and (max-height: 760px) {
  body > :is(.cc-section, .cmx-section, .giveaway-section, .ocr-section, .gp-section, .cmd-section) {
    padding-top: 56px !important;
    padding-bottom: 24px !important;
  }
  .gp-section .section-subtitle { display: none; }

  body .cmx-stage { height: 340px; }
  .cmx { gap: 12px; }
  body .cmx-pills { margin-top: 8px; }
  .cmx-card-head { padding-top: 9px; padding-bottom: 9px; }
  .cmx-foot { display: none; }

  body .gw-radar { --size: 180px; }

  body .ocr-scan-frame { height: 220px; }
  body .ocr-layer-copy { padding-top: 40px; }
  body .gw-tickets { height: 120px; }
  .gw-tickets-head { display: none; }

  body .gp-device { zoom: 0.52; }

  .cx-pane-head,
  .cx-input { display: none !important; }
}

@media (prefers-reduced-motion: reduce) {
  .btn-glow::before,
  .cmd-marquee-track,
  .cc-loading span,
  .cmx-msg,
  .cmx-pill,
  .cmx-ghost {
    animation: none !important;
  }
  .cc-window { transform: none; opacity: 1; }
}

/* Lenis (js/smooth-scroll.js) smooths the wheel; native smooth scroll would fight it */
html.lenis { scroll-behavior: auto; }

/* Modules */
.modules-section{padding:110px 0 40px}
.modules-section .section-title{margin-bottom:14px}
.mod-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(168px,1fr));gap:12px;margin-top:40px}
.mod-card{display:flex;flex-direction:column;align-items:flex-start;gap:6px;padding:16px;border-radius:14px;background:var(--surface);border:1px solid var(--border);transition:transform .25s ease,border-color .25s ease,box-shadow .25s ease}
.mod-card:hover{transform:translateY(-3px);border-color:var(--accent);box-shadow:0 8px 28px var(--accent-dim)}
.mod-ico{font-size:22px;line-height:1}
.mod-card b{font-size:15px;color:var(--text-primary);font-weight:700}
.mod-card code{font-size:12px;color:var(--accent);background:var(--accent-dim);padding:2px 8px;border-radius:6px;font-family:ui-monospace,SFMono-Regular,Menlo,monospace}
@media (max-width:520px){.mod-grid{grid-template-columns:repeat(2,1fr);gap:10px}.modules-section{padding-top:80px}}

/* V4 */
.v4-section{padding:100px 0 40px}
.v4-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:16px;margin-top:40px}
.v4-card{padding:24px;border-radius:16px;background:var(--surface);border:1px solid var(--border)}
.v4-card h3{font-size:17px;font-weight:700;margin:0 0 14px;color:var(--text-primary)}
.v4-card ul{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:9px}
.v4-card li{position:relative;padding-left:24px;font-size:14px;line-height:1.5;color:var(--text-secondary)}
.v4-card li::before{content:"";position:absolute;left:0;top:5px;width:13px;height:13px;border-radius:50%;background:var(--accent-dim);border:1px solid var(--accent)}
.v4-card li::after{content:"";position:absolute;left:4.5px;top:8px;width:4px;height:2.5px;border-left:1.5px solid var(--accent);border-bottom:1.5px solid var(--accent);transform:rotate(-45deg)}
.v4-card li b{color:var(--text-primary)}
.v4-card--note li::before{background:rgba(255,200,80,.12);border-color:rgba(255,200,80,.6)}
.v4-card--note li::after{display:none}
.v4-why-title{margin-top:80px;text-align:center}
.v4-why-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:14px;margin-top:32px}
.v4-why{display:flex;flex-direction:column;gap:6px;padding:20px;border-radius:14px;background:var(--surface);border:1px solid var(--border)}
.v4-why b{color:var(--text-primary);font-size:15px}.v4-why span{color:var(--text-secondary);font-size:13.5px;line-height:1.5}
.v4-after{padding-top:20px}
.v4-cta{margin-top:56px;text-align:center;padding:48px 24px;border-radius:20px;background:linear-gradient(180deg,var(--accent-dim),transparent);border:1px solid var(--border)}
.v4-cta h2{font-size:clamp(22px,3vw,32px);margin:0 0 12px;color:var(--text-primary)}
.v4-cta p{max-width:560px;margin:0 auto 24px;color:var(--text-secondary);line-height:1.6}
@media (max-width:820px){.v4-grid{grid-template-columns:1fr}.v4-why-grid{grid-template-columns:1fr 1fr}}
@media (max-width:520px){.v4-why-grid{grid-template-columns:1fr}.v4-section{padding-top:70px}}

/* All commands */
.ac-section{padding:100px 0 40px}
.ac-search{max-width:460px;margin:36px auto 0}
.ac-search input{width:100%;box-sizing:border-box;padding:14px 18px;border-radius:12px;border:1px solid var(--border);background:var(--surface);color:var(--text-primary);font:inherit;font-size:15px;outline:none;transition:border-color .2s,box-shadow .2s}
.ac-search input:focus{border-color:var(--accent);box-shadow:0 0 0 3px var(--accent-dim)}
.ac-grid{display:flex;flex-wrap:wrap;gap:8px;margin-top:28px;justify-content:center}
.ac-pill{padding:6px 12px;border-radius:8px;background:var(--surface);border:1px solid var(--border);color:var(--text-secondary);font-size:13px;font-family:ui-monospace,SFMono-Regular,Menlo,monospace}
.ac-pill:hover{color:var(--accent);border-color:var(--accent)}
.ac-empty{text-align:center;color:var(--text-secondary);margin-top:24px}
.ac-more-wrap{text-align:center;margin-top:28px}

.v4-card--min{padding:14px 18px;align-self:start}
.v4-card--min h3{font-size:14px;margin-bottom:8px}
.v4-card--min ul{gap:5px}
.v4-card--min li{font-size:13px;padding-left:20px}
.v4-card--min{grid-column:1/-1;display:flex;align-items:center;flex-wrap:wrap;gap:10px 28px;padding:14px 20px}
.v4-card--min h3{margin:0}
.v4-card--min ul{flex-direction:row;flex-wrap:wrap;gap:6px 22px}
@media (max-width:820px){.v4-card--min ul{flex-direction:column}}

/* Selfmodes */
.sm-section{padding:96px 0 40px}
.sm-section .container{max-width:960px}
.sm-section code{font-family:ui-monospace,SFMono-Regular,Menlo,monospace;color:var(--accent);background:var(--accent-dim);padding:2px 8px;border-radius:6px;font-size:.92em}
.sm-cmdbar{display:flex;align-items:center;gap:10px;max-width:520px;margin:34px auto 0;padding:14px 18px;border-radius:12px;background:var(--surface);border:1px solid var(--border);font-size:15px}
.sm-cmd-prompt{color:var(--text-secondary);opacity:.7}
.sm-cmd-text{color:var(--text-primary);font-family:ui-monospace,SFMono-Regular,Menlo,monospace;font-weight:600}
.sm-cmd-caret{width:2px;height:18px;background:var(--accent);animation:smblink 1s steps(1) infinite}
@keyframes smblink{50%{opacity:0}}
.sm-shots{display:grid;grid-template-columns:repeat(2,minmax(0,360px));gap:22px;justify-content:center;margin-top:32px}
.sm-shot{margin:0;text-align:center}
.sm-zoom{display:block;width:100%;padding:0;border:1px solid var(--border);border-radius:16px;overflow:hidden;background:var(--surface);cursor:zoom-in;transition:border-color .25s,transform .25s,box-shadow .25s}
.sm-zoom:hover{border-color:var(--accent);transform:translateY(-3px);box-shadow:0 12px 36px var(--accent-dim)}
.sm-zoom img{display:block;width:100%;height:auto;max-height:560px;object-fit:cover;object-position:top}
.sm-shot figcaption{margin-top:10px;font-size:13px;color:var(--text-secondary)}
.sm-pick-title{text-align:center;margin:64px 0 22px;font-size:20px;color:var(--text-primary)}
.sm-picker{display:grid;grid-template-columns:minmax(0,1fr) 332px;gap:14px;align-items:stretch}
.sm-chips{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;align-self:start}
.sm-chip{display:flex;align-items:center;gap:8px;text-align:left;padding:11px 11px;border-radius:9px;background:var(--surface);border:1px solid var(--border);color:var(--text-secondary);font:inherit;font-size:12px;line-height:1.26;cursor:pointer;transition:border-color .2s,background .2s,color .2s}
.sm-chip b{flex:none;width:22px;height:22px;display:grid;place-items:center;border-radius:6px;background:var(--accent-dim);color:var(--accent);font-size:11px}
.sm-chip:hover{border-color:var(--accent);color:var(--text-primary)}
.sm-chip.is-active{border-color:var(--accent);background:var(--accent-dim);color:var(--text-primary)}
.sm-preview{position:relative;display:flex;flex-direction:column;padding:10px;border-radius:14px;background:var(--surface);border:1px solid var(--border);width:100%;max-width:332px;margin:0;box-sizing:border-box}
.sm-preview-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:8px;min-height:42px;flex-wrap:nowrap;flex-shrink:0}
.sm-preview-head-left{display:flex;align-items:center;gap:10px;min-width:0}
.sm-private-btn{display:inline-flex;align-items:center;gap:7px;padding:6px 10px;border-radius:8px;border:1px solid var(--border);background:rgba(255,255,255,.04);color:var(--text-secondary);font:inherit;font-size:11.5px;font-weight:700;cursor:pointer;transition:border-color .2s,background .2s,color .2s}
.sm-private-btn[hidden]{display:none}
.sm-private-btn:hover{border-color:var(--accent);color:var(--text-primary)}
.sm-private-btn.is-on{border-color:rgba(134,110,247,.7);background:rgba(88,101,242,.22);color:#fff}
.sm-private-dot{width:7px;height:7px;border-radius:50%;background:rgba(255,255,255,.35)}
.sm-private-btn.is-on .sm-private-dot{background:#5865f2;box-shadow:0 0 8px #5865f2}
.sm-preview-transcript{flex:1;min-height:0;border-radius:10px;overflow:hidden;border:1px solid rgba(255,255,255,.07);background:#313338;width:100%;max-width:100%}
.sm-preview-head b{display:block;color:var(--text-primary);font-size:14px;margin-bottom:3px}
.sm-preview-num{flex:none;width:32px;height:32px;display:grid;place-items:center;border-radius:9px;background:var(--accent);color:#fff;font-weight:800;font-size:14px}
.sm-preview-media{min-height:220px;border-radius:12px;background:rgba(255,255,255,.03);border:1px dashed var(--border);display:grid;place-items:center;overflow:hidden}
.sm-mode-img{display:block;width:100%;height:auto}
.sm-soon{color:var(--text-secondary);font-size:13px;opacity:.8;padding:40px 16px;text-align:center}
.sm-lightbox{position:fixed;inset:0;z-index:9999;display:none;align-items:center;justify-content:center;padding:24px;background:rgba(5,5,10,.88);cursor:zoom-out}
.sm-lightbox.open{display:flex}
.sm-lightbox img{max-width:min(94vw,820px);max-height:92vh;border-radius:12px}
@media (max-width:860px){.sm-picker{grid-template-columns:1fr}.sm-preview{position:static;order:-1;height:520px}}
@media (max-width:560px){.sm-shots{grid-template-columns:1fr}.sm-chips{grid-template-columns:1fr}.sm-section{padding-top:80px}}

/* ===== Random RPCs showcase (Dashboard card look + moving marquee) ===== */
.rpc-showcase-section {
  padding: 110px 0;
  position: relative;
  z-index: 1;
}

.rpc-showcase-header {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 38px;
}

.rpc-showcase-actions {
  margin-top: 22px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.rpc-autorotate-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.rpc-autorotate-btn.is-on {
  border-color: rgba(134, 110, 247, 0.45);
  background: rgba(134, 110, 247, 0.14);
  color: #fff;
}

.rpc-autorotate-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.35);
}

.rpc-autorotate-btn.is-on .rpc-autorotate-dot {
  background: #23a55a;
  box-shadow: 0 0 8px #23a55a;
}

.rpc-shuffle-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.rpc-shuffle-btn svg {
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}

.rpc-shuffle-btn:hover svg {
  transform: rotate(180deg);
}

.rpc-marquee {
  position: relative;
  display: grid;
  gap: 18px;
  overflow: hidden;
  padding: 8px 0 12px;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}

.rpc-marquee-row {
  overflow: hidden;
}

.rpc-marquee-track {
  display: flex;
  align-items: stretch;
  gap: 18px;
  width: max-content;
  will-change: transform;
  animation: rpcMarqueeRight 56s linear infinite;
}

.rpc-marquee-row--rev .rpc-marquee-track {
  animation-name: rpcMarqueeLeft;
  animation-duration: 60s;
}

@keyframes rpcMarqueeRight {
  from { transform: translate3d(-50%, 0, 0); }
  to   { transform: translate3d(0, 0, 0); }
}

@keyframes rpcMarqueeLeft {
  from { transform: translate3d(0, 0, 0); }
  to   { transform: translate3d(-50%, 0, 0); }
}

/* Match dashboard .discord-activity-card & .discord-rpc-btn */
.rpc-dash-card {
  flex: none;
  width: 390px;
  background: #1e1f22;
  border-radius: 16px;
  padding: 18px 20px;
  color: #dbdee1;
  border: 1px solid rgba(255, 255, 255, 0.08);
  font-family: 'gg sans', 'Noto Sans', 'Manrope', sans-serif;
  box-shadow: 0 10px 36px rgba(0, 0, 0, 0.4);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-sizing: border-box;
  transition: border-color 0.22s ease, transform 0.22s ease;
}

.rpc-dash-card:hover {
  border-color: rgba(149, 134, 250, 0.35);
  transform: translateY(-2px);
}

.rpc-dash-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}

.rpc-dash-head-left {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  overflow: hidden;
}

.rpc-dash-verb {
  font-size: 0.84rem;
  font-weight: 700;
  color: #dbdee1;
  white-space: nowrap;
}

.rpc-dash-type-icon {
  display: inline-flex;
  align-items: center;
  color: #949ba4;
  flex-shrink: 0;
}

.rpc-dash-dots {
  color: #949ba4;
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}

.rpc-dash-body {
  display: flex;
  gap: 14px;
  align-items: center;
}

.rpc-dash-art-wrap {
  position: relative;
  width: 78px;
  height: 78px;
  flex-shrink: 0;
}

.rpc-dash-large-img {
  width: 78px;
  height: 78px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  overflow: hidden;
  object-fit: cover;
  background: #2b2d31;
}

.rpc-dash-large-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.rpc-dash-small-img {
  position: absolute;
  bottom: -4px;
  right: -4px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 3px solid #1e1f22;
  background: #111214;
  display: grid;
  place-items: center;
  font-size: 9px;
  font-weight: 800;
  color: #f2f3f5;
  overflow: hidden;
}

.rpc-dash-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
  min-width: 0;
  flex: 1;
}

.rpc-dash-name {
  font-weight: 700;
  color: #f2f3f5;
  font-size: 1.02rem;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rpc-dash-details {
  font-size: 0.85rem;
  color: #dbdee1;
  line-height: 1.35;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rpc-dash-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 3px;
  flex-wrap: wrap;
  font-size: 0.82rem;
  line-height: 1.35;
  color: #dbdee1;
}

.rpc-dash-state {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rpc-dash-state-text {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rpc-dash-timer {
  font-size: 0.82rem;
  color: #23a55a;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-weight: 600;
  flex-shrink: 0;
  font-variant-numeric: tabular-nums;
}

.rpc-dash-seekbar {
  display: flex;
  align-items: center;
  width: 100%;
  margin-top: 8px;
  gap: 8px;
  font-size: 0.78rem;
  font-variant-numeric: tabular-nums;
}

.rpc-dash-seek-cur {
  color: #dbdee1;
  min-width: 34px;
}

.rpc-dash-seek-track {
  flex: 1;
  height: 4px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 2px;
  overflow: hidden;
}

.rpc-dash-seek-fill {
  height: 100%;
  background: #ffffff;
  border-radius: 2px;
  transition: width 0.6s linear;
}

.rpc-dash-seek-total {
  color: #949ba4;
  min-width: 34px;
  text-align: right;
}

.rpc-dash-btns {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 14px;
}

.rpc-dash-btn {
  background: #2b2d31;
  border-radius: 6px;
  padding: 8px 14px;
  min-height: 35px;
  text-align: center;
  font-weight: 700;
  font-size: 0.84rem;
  color: #f2f3f5;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.17s ease, color 0.17s ease;
  user-select: none;
}

.rpc-dash-btn:hover {
  background: #35373c;
  color: #ffffff;
}

@media (max-width: 780px) {
  .rpc-showcase-section {
    padding: 80px 0;
  }
  .rpc-dash-card {
    width: 320px;
    padding: 16px;
  }
  .rpc-dash-art-wrap,
  .rpc-dash-large-img {
    width: 66px;
    height: 66px;
  }
}

/* ===== Cart, Crypto (LTC/USDT/SOL), FamPay UPI & Login Modals ===== */
.pm-cart-modal { max-width: 520px; }
.cart-plan-tabs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 14px;
}
.cart-plan-tab {
  padding: 9px 10px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.03);
  color: rgba(255,255,255,0.7);
  font: inherit;
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  transition: border-color 0.2s, background 0.2s, color 0.2s;
}
.cart-plan-tab b { color: #fff; font-size: 13.5px; }
.cart-plan-tab.is-active {
  border-color: rgba(134,110,247,0.6);
  background: rgba(134,110,247,0.16);
  color: #fff;
}
.cart-item-card { gap: 12px; }
.cart-qty-control {
  display: inline-flex;
  align-items: center;
  border-radius: 9px;
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(0,0,0,0.35);
  overflow: hidden;
}
.cart-qty-btn {
  width: 28px;
  height: 30px;
  border: 0;
  background: transparent;
  color: #fff;
  font-size: 16px;
  cursor: pointer;
}
.cart-qty-btn:hover { background: rgba(134,110,247,0.22); }
.cart-qty-input {
  width: 34px;
  height: 30px;
  border: 0;
  background: transparent;
  color: #fff;
  text-align: center;
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  outline: none;
}
.cart-qty-input::-webkit-inner-spin-button,
.cart-qty-input::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.cart-coupon-row {
  display: flex;
  gap: 8px;
  align-items: stretch;
}
.cart-coupon-row .pm-input { flex: 1; }
.cart-apply-btn { flex: none; padding: 0 16px; white-space: nowrap; }
.cart-summary-box {
  margin: 14px 0 16px;
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.07);
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
}
.cart-summary-row {
  display: flex;
  justify-content: space-between;
  color: rgba(255,255,255,0.72);
}
.cart-discount-row { color: #34d399; }
.cart-total-row {
  padding-top: 6px;
  border-top: 1px solid rgba(255,255,255,0.08);
  color: #fff;
  font-size: 15px;
}
.cart-total-row small { color: rgba(255,255,255,0.55); font-weight: 600; }
.cart-summary-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 14px;
  margin-bottom: 14px;
  border-radius: 10px;
  background: rgba(134,110,247,0.12);
  border: 1px solid rgba(134,110,247,0.28);
  font-size: 13px;
  color: #fff;
}
.pay-method-switch {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 14px;
}
.pay-method-tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.03);
  color: rgba(255,255,255,0.75);
  font: inherit;
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
}
.pay-method-tab svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}
.pay-method-tab.is-active {
  border-color: rgba(134,110,247,0.65);
  background: rgba(134,110,247,0.18);
  color: #fff;
}
.pm-invoice-cmd {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 12.5px;
  color: rgba(255,255,255,0.75);
  line-height: 1.45;
}
.pm-invoice-cmd code {
  display: inline-block;
  padding: 2px 7px;
  border-radius: 6px;
  background: rgba(134,110,247,0.16);
  color: #e4ddff;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12px;
}
.pm-coins--three {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}
.pm-coin-badge {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 16px;
  color: #fff;
  flex: none;
}
.pm-coin-badge--ltc { background: #345d9d; }
.pm-coin-badge--usdt { background: #26a17b; }
.pm-coin-badge--sol { background: linear-gradient(135deg, #9945ff, #14f195); }
.upi-info-card, .upi-verify-box {
  padding: 14px;
  border-radius: 12px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.upi-info-card strong { font-size: 14px; color: #fff; }
.upi-info-card p { font-size: 12.5px; color: rgba(255,255,255,0.68); line-height: 1.5; margin: 0 0 6px; }
.upi-verify-box { margin: 12px 0; }
.upi-verify-box label { font-size: 12.5px; font-weight: 700; color: #fff; }
.pm-action-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
}
.pm-sim-btn {
  padding: 7px 12px;
  border-radius: 8px;
  border: 1px solid rgba(134,110,247,0.45);
  background: rgba(134,110,247,0.14);
  color: #fff;
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}
.pm-sim-btn:hover { background: rgba(134,110,247,0.26); }
