
:root{
  --rm-bg1:#0b1220;
  --rm-bg2:#0f2a4a;
  --rm-card:#101a2d;
  --rm-card2:#0f172a;
  --rm-border: rgba(255,255,255,.10);
  --rm-text:#ffffff;
  --rm-muted: rgba(255,255,255,.75);
  --rm-muted2: rgba(255,255,255,.60);
  --rm-accent:#22c55e;
  --rm-primary:#3b82f6;
  --rm-warn:#f59e0b;
  --rm-danger:#ef4444;
  --rm-shadow: 0 12px 40px rgba(0,0,0,.45);
}

.rm-app, .rm-app *{
  box-sizing:border-box;
  color: var(--rm-text) !important; /* force white text for readability */
}

.rm-app{
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  background: radial-gradient(1200px 600px at 20% 0%, rgba(59,130,246,.25), transparent 60%),
              radial-gradient(900px 700px at 90% 30%, rgba(34,197,94,.18), transparent 55%),
              linear-gradient(160deg, var(--rm-bg1), var(--rm-bg2));
  padding: 18px;
  border-radius: 18px;
  border: 1px solid var(--rm-border);
  box-shadow: var(--rm-shadow);
  max-width: 980px;
  margin: 18px auto;
}

.rm-topbar{
  display:flex;
  gap:12px;
  align-items:center;
  justify-content:space-between;
  margin-bottom:14px;
  flex-wrap:wrap;
}

.rm-brand{
  font-weight: 800;
  letter-spacing:.2px;
  font-size: 20px;
}
.rm-mini{ font-size: 12px; color: var(--rm-muted) !important; }
.rm-top-left{ display:flex; flex-direction:column; gap:2px; }
.rm-top-right{ display:flex; gap:10px; align-items:center; }

.rm-link{
  text-decoration:none;
  color: rgba(255,255,255,.90) !important;
  border-bottom: 1px dashed rgba(255,255,255,.35);
  padding-bottom:1px;
}

.rm-steps{
  display:flex;
  gap:8px;
  align-items:center;
}
.rm-step-pill{
  font-size: 12px;
  padding: 8px 10px;
  border-radius: 999px;
  border: 1px solid var(--rm-border);
  background: rgba(255,255,255,.06);
  color: var(--rm-muted) !important;
  white-space:nowrap;
}
.rm-step-pill.active{
  background: rgba(59,130,246,.22);
  border-color: rgba(59,130,246,.55);
  color:#fff !important;
}
.rm-step-pill.done{
  background: rgba(34,197,94,.18);
  border-color: rgba(34,197,94,.55);
  color:#fff !important;
}

.rm-screen{ animation: rmFade .18s ease-out; }
@keyframes rmFade{ from{opacity:.6; transform:translateY(4px);} to{opacity:1; transform:translateY(0);} }

.rm-card{
  background: linear-gradient(180deg, rgba(255,255,255,.06), rgba(255,255,255,.04));
  border: 1px solid var(--rm-border);
  border-radius: 16px;
  padding: 16px;
}
.rm-center{ text-align:center; }

.rm-title{ font-size: 18px; font-weight: 800; margin-bottom: 6px; }
.rm-sub{ font-size: 13px; color: var(--rm-muted) !important; margin-bottom: 12px; }
.rm-tight{ margin-bottom: 0; margin-top: 6px; }

.rm-row{ display:flex; gap:10px; align-items:center; }
.rm-gap{ margin-top: 10px; }
.rm-gap-top{ margin-top: 12px; }
.rm-actions{ display:flex; gap:10px; justify-content:flex-end; margin-top: 14px; flex-wrap:wrap; }

.rm-input{
  width: 100%;
  padding: 12px 12px;
  border-radius: 12px;
  border: 1px solid var(--rm-border);
  background: rgba(15,23,42,.55);
  outline:none;
  color:#fff !important;
}
.rm-input::placeholder{ color: rgba(255,255,255,.55) !important; }
.rm-input:focus{ border-color: rgba(59,130,246,.7); box-shadow: 0 0 0 4px rgba(59,130,246,.18); }
.rm-input-small{ max-width: 220px; }

.rm-btn{
  border-radius: 12px;
  border: 1px solid var(--rm-border);
  padding: 11px 14px;
  cursor:pointer;
  background: rgba(255,255,255,.07);
  font-weight: 700;
  font-size: 13px;
  text-decoration:none;
  display:inline-flex;
  align-items:center;
  gap:8px;
}
.rm-btn:disabled{ opacity:.45; cursor:not-allowed; }
.rm-primary{
  background: linear-gradient(180deg, rgba(59,130,246,.95), rgba(37,99,235,.95));
  border-color: rgba(59,130,246,.9);
}
.rm-secondary{
  background: linear-gradient(180deg, rgba(34,197,94,.92), rgba(22,163,74,.92));
  border-color: rgba(34,197,94,.85);
}
.rm-ghost{
  background: rgba(255,255,255,.05);
}

.rm-list{
  display:flex;
  flex-direction:column;
  gap:10px;
  margin-top: 12px;
}
.rm-item{
  display:flex;
  justify-content:space-between;
  gap:12px;
  padding: 12px;
  border-radius: 14px;
  border: 1px solid var(--rm-border);
  background: rgba(15,23,42,.45);
  cursor:pointer;
  transition: transform .06s ease, border-color .12s ease, background .12s ease;
}
.rm-item:hover{ transform: translateY(-1px); border-color: rgba(255,255,255,.22); background: rgba(15,23,42,.55); }
.rm-item.selected{ border-color: rgba(59,130,246,.8); background: rgba(59,130,246,.18); }
.rm-item .rm-a{ display:flex; flex-direction:column; gap:3px; min-width: 0; }
.rm-item .rm-b{ display:flex; flex-direction:column; align-items:flex-end; gap:6px; }
.rm-item .rm-strong{ font-weight: 800; }
.rm-item .rm-small{ font-size: 12px; color: var(--rm-muted) !important; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; max-width: 620px; }

.rm-badge{
  font-size: 11px;
  font-weight: 800;
  padding: 6px 8px;
  border-radius: 999px;
  border: 1px solid var(--rm-border);
  background: rgba(255,255,255,.06);
  white-space:nowrap;
}
.rm-ok{ background: rgba(34,197,94,.20); border-color: rgba(34,197,94,.55); }
.rm-warn{ background: rgba(245,158,11,.18); border-color: rgba(245,158,11,.55); }

.rm-panel{
  border: 1px solid var(--rm-border);
  border-radius: 14px;
  padding: 12px;
  background: rgba(2,6,23,.25);
}
.rm-kv{ display:flex; justify-content:space-between; gap:12px; padding: 8px 0; border-bottom: 1px dashed rgba(255,255,255,.14); }
.rm-kv:last-child{ border-bottom:0; }
.rm-kv .k{ font-size: 12px; color: var(--rm-muted2) !important; }
.rm-kv .v{ font-size: 13px; }

.rm-code{
  padding: 3px 8px;
  border-radius: 10px;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.12);
  display:inline-block;
}

.rm-hint{ margin-top:10px; font-size: 12px; color: var(--rm-muted) !important; }

@media (max-width: 720px){
  .rm-app{ padding: 14px; }
  .rm-item .rm-small{ max-width: 220px; }
  .rm-input-small{ max-width: 100%; }
  .rm-row{ flex-wrap:wrap; }
  .rm-actions{ justify-content:stretch; }
  .rm-btn{ flex:1; justify-content:center; }
}
