/* =========================================================
   try.html — browser-side KUBORA menu.
   Reuses tokens from style.css (accent / glass / text)
   and adds layout-only rules for the world-picker.
   ========================================================= */

.try-body {
  min-height: 100vh;
  /* Slightly warmer base than the landing — the menu is where
     the *player* lives, the landing is where the *marketer*
     lives. A touch of KUBORA-orange radial fade makes the menu
     feel like an antechamber to the cube. */
  background:
    radial-gradient(60% 80% at 50% 0%, rgba(255, 154, 54, 0.10), transparent 70%),
    radial-gradient(40% 60% at 80% 100%, rgba(179, 110, 255, 0.10), transparent 70%),
    #0a0b14;
  padding-bottom: 80px;
}

/* ── Top bar ──────────────────────────────────────────────── */

.try-nav {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 40px;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  background: rgba(10, 11, 20, 0.6);
  border-bottom: 1px solid var(--glass-stroke);
}
.try-back {
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: 3px;
  border: 1px solid var(--glass-stroke);
  transition: color 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}
.try-back:hover {
  color: var(--text);
  border-color: var(--glass-stroke-strong);
  background: var(--glass);
}

/* ── Shell ────────────────────────────────────────────────── */

.try-shell {
  max-width: 1100px;
  margin: 40px auto 0;
  padding: 0 40px;
}

/* ── Identity strip ───────────────────────────────────────── */

.try-identity {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 18px 24px;
  background: var(--glass);
  border: 1px solid var(--glass-stroke-strong);
  border-radius: 6px;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}
.try-avatar {
  flex: 0 0 auto;
  filter: drop-shadow(0 4px 12px rgba(255, 155, 54, 0.4));
}
.try-identity-text { flex: 1; }
.try-identity-tag {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}
.try-identity-name {
  font-size: 20px;
  font-weight: 800;
  color: var(--text);
  margin-top: 2px;
}
.try-identity-id {
  color: #ff9b36;
  font-family: "JetBrains Mono", monospace;
  font-weight: 600;
  margin-left: 6px;
  font-size: 16px;
}
.try-identity-sub {
  font-size: 13px;
  color: var(--text-muted);
  margin-top: 4px;
}
.try-identity-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
}
.try-chip {
  font-size: 11px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 2px;
  letter-spacing: 0.04em;
}
.try-chip-web {
  background: linear-gradient(135deg, #ffb45c, #ff7a14);
  color: #1a0d00;
  text-transform: uppercase;
}
.try-chip-soon {
  background: rgba(179, 110, 255, 0.15);
  color: #b36eff;
  border: 1px solid rgba(179, 110, 255, 0.3);
}

/* ── Title ────────────────────────────────────────────────── */

.try-title {
  font-size: clamp(32px, 5vw, 52px);
  font-weight: 900;
  letter-spacing: -0.02em;
  margin: 44px 0 12px;
}
.try-lead {
  font-size: 16px;
  line-height: 1.6;
  color: var(--text-muted);
  max-width: 640px;
  margin-bottom: 28px;
}
.try-lead strong { color: var(--text); }

/* ── Web playground hero card ─────────────────────────────── */

.try-webcard {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 0;
  margin: 0 0 32px;
  background: linear-gradient(135deg, rgba(255, 155, 54, 0.12), rgba(255, 122, 20, 0.06) 60%);
  border: 1px solid rgba(255, 155, 54, 0.35);
  border-radius: 8px;
  overflow: hidden;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
}
.try-webcard-body {
  padding: 28px 30px 30px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  align-items: flex-start;
}
.try-webcard-tag {
  display: inline-block;
  padding: 4px 10px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #1a0d00;
  background: linear-gradient(135deg, #ffcc7a, #ff9b36);
  border-radius: 2px;
}
.try-webcard-title {
  margin: 0;
  font-size: clamp(22px, 3vw, 30px);
  font-weight: 900;
  letter-spacing: -0.01em;
}
.try-webcard-blurb {
  margin: 0;
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-muted);
  max-width: 440px;
}
.try-webcard-art {
  position: relative;
  min-height: 180px;
  background:
    radial-gradient(60% 80% at 70% 40%, rgba(255, 180, 92, 0.35), transparent 70%),
    linear-gradient(135deg, #2a1f3d 0%, #1a1029 60%, #281432 100%);
  overflow: hidden;
}
.try-webcard-grid {
  position: absolute;
  inset: -10%;
  background:
    repeating-linear-gradient(90deg, transparent 0 38px, rgba(255, 255, 255, 0.05) 38px 39px),
    repeating-linear-gradient(0deg, transparent 0 38px, rgba(255, 255, 255, 0.05) 38px 39px);
  transform: perspective(600px) rotateX(48deg);
  transform-origin: 50% 80%;
  opacity: 0.8;
}
@media (max-width: 720px) {
  .try-webcard { grid-template-columns: 1fr; }
  .try-webcard-art { min-height: 120px; order: -1; }
}

/* ── World grid ───────────────────────────────────────────── */

.try-worlds {
  margin-bottom: 40px;
}
.try-worlds-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 18px;
}
.try-worlds-status {
  margin: 14px 0 0;
  font-size: 12px;
  color: var(--text-dim);
  letter-spacing: 0.03em;
}
.world-card {
  display: flex;
  flex-direction: column;
  background: var(--glass);
  border: 1px solid var(--glass-stroke-strong);
  border-radius: 6px;
  overflow: hidden;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}
.world-card:hover {
  transform: translateY(-3px);
  border-color: rgba(255, 155, 54, 0.4);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}
.world-card-featured {
  grid-column: 1 / -1;
  flex-direction: row;
  min-height: 220px;
}
.world-card-featured .world-thumb {
  flex: 0 0 40%;
  min-height: 220px;
}
.world-card-featured .world-body {
  flex: 1;
}

/* Thumbs use pure CSS gradients (no image assets) so the page
   stays a single static drop. Each world gets a distinct palette
   so cards are distinguishable even before the label loads. */
.world-thumb {
  position: relative;
  height: 140px;
  display: flex;
  align-items: flex-end;
  padding: 12px 14px;
  overflow: hidden;
}
.world-thumb-parkour {
  background:
    radial-gradient(120% 80% at 20% 20%, rgba(255, 180, 92, 0.55), transparent 60%),
    linear-gradient(135deg, #2a1f3d 0%, #1a1029 50%, #281432 100%);
}
.world-thumb-sandbox {
  background:
    radial-gradient(120% 80% at 80% 20%, rgba(77, 210, 122, 0.45), transparent 60%),
    linear-gradient(135deg, #132433 0%, #0e1a25 50%, #1a2f2a 100%);
}
.world-thumb-ai {
  background:
    radial-gradient(120% 80% at 50% 20%, rgba(179, 110, 255, 0.55), transparent 60%),
    linear-gradient(135deg, #1e1338 0%, #140b2a 50%, #2a1a44 100%);
}
.world-thumb-overlay {
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(90deg, transparent 0 38px, rgba(255, 255, 255, 0.03) 38px 39px),
    repeating-linear-gradient(0deg, transparent 0 38px, rgba(255, 255, 255, 0.03) 38px 39px);
  pointer-events: none;
}
.world-thumb-label {
  position: relative;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 4px 10px;
  background: rgba(0, 0, 0, 0.5);
  color: #fff;
  border-radius: 2px;
  backdrop-filter: blur(4px);
}
.world-body {
  padding: 18px 20px 22px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.world-title {
  font-size: 20px;
  font-weight: 800;
  margin: 0;
}
.world-blurb {
  font-size: 14px;
  line-height: 1.55;
  color: var(--text-muted);
  margin: 0;
}
.world-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
}
.world-players {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #4dd27a;
  font-weight: 600;
}
.world-players .pulse {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #4dd27a;
  box-shadow: 0 0 8px #4dd27a;
  animation: pulse 1.8s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 0.4; }
  50%      { opacity: 1; }
}
.world-dot { color: var(--text-dim); }
.world-note {
  font-size: 12px;
  color: var(--text-dim);
  margin: 8px 0 0;
  font-style: italic;
}

.btn-disabled {
  opacity: 0.55;
  cursor: not-allowed;
  pointer-events: none;
}

/* Skeleton cards shown while the Supabase snapshot is inflight.
   Use the same card geometry as the real ones so the layout
   doesn't pop when data arrives. */
.world-card-skel {
  pointer-events: none;
}
.world-thumb-skel {
  background: linear-gradient(90deg,
    rgba(255,255,255,0.02) 0%,
    rgba(255,255,255,0.08) 50%,
    rgba(255,255,255,0.02) 100%);
  background-size: 200% 100%;
  animation: skel-shimmer 1.4s linear infinite;
}
.world-skel-line {
  height: 12px;
  border-radius: 3px;
  background: linear-gradient(90deg,
    rgba(255,255,255,0.04) 0%,
    rgba(255,255,255,0.12) 50%,
    rgba(255,255,255,0.04) 100%);
  background-size: 200% 100%;
  animation: skel-shimmer 1.4s linear infinite;
}
.world-skel-line-l { width: 72%; }
.world-skel-line-m { width: 90%; height: 10px; }
.world-skel-line-s { width: 48%; height: 10px; }
@keyframes skel-shimmer {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* Empty / error card. Spans full row so the "no worlds" or
   "offline" state reads as the page's main message, not one
   card among many. */
.world-card-empty {
  grid-column: 1 / -1;
  padding: 20px 24px;
  text-align: left;
}
.world-card-empty .world-body {
  gap: 12px;
}

/* ── Status card ─────────────────────────────────────────── */

.try-status {
  display: flex;
  gap: 20px;
  padding: 24px 28px;
  background: linear-gradient(135deg, rgba(179, 110, 255, 0.08), rgba(76, 141, 255, 0.06));
  border: 1px solid var(--glass-stroke-strong);
  border-radius: 6px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.try-status-icon {
  flex: 0 0 auto;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  background: rgba(255, 155, 54, 0.15);
  border: 1px solid rgba(255, 155, 54, 0.35);
  color: #ff9b36;
  border-radius: 4px;
}
.try-status-title {
  font-size: 18px;
  font-weight: 800;
  margin-bottom: 6px;
}
.try-status-text {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-muted);
  margin: 0 0 14px;
}
.try-status-text code {
  background: var(--glass);
  padding: 1px 6px;
  border-radius: 2px;
  font-family: "JetBrains Mono", monospace;
  font-size: 12px;
}
.try-status-cta {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* ── Footer ──────────────────────────────────────────────── */

.try-foot {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  margin-top: 60px;
  font-size: 12px;
  color: var(--text-dim);
  letter-spacing: 0.04em;
}
.try-foot-dot { color: var(--text-dim); opacity: 0.5; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ── Small screens ───────────────────────────────────────── */

@media (max-width: 720px) {
  .try-shell { padding: 0 20px; }
  .try-nav { padding: 12px 20px; }
  .try-identity {
    flex-wrap: wrap;
    gap: 14px;
  }
  .try-identity-actions {
    flex-direction: row;
    align-self: flex-start;
  }
  .world-card-featured {
    flex-direction: column;
  }
  .world-card-featured .world-thumb {
    flex: none;
    min-height: 140px;
    width: 100%;
  }
  .try-status {
    flex-direction: column;
  }
}
