/* ============================================================
   VibeRoom — neon nightlife design system
   Dark, premium, seductive. Not corporate. Not boring SaaS.
   ============================================================ */

:root {
  --bg: #07060f;
  --bg-2: #0d0b1e;
  --bg-3: #14102b;
  --card: rgba(255, 255, 255, 0.045);
  --card-border: rgba(168, 85, 247, 0.25);
  --purple: #a855f7;
  --purple-deep: #7c3aed;
  --magenta: #ff2ec4;
  --blue: #38bdf8;
  --teal: #2dd4bf;
  --gold: #fbbf24;
  --danger: #f43f5e;
  --text: #f4f1ff;
  --text-dim: #a89fc9;
  --text-faint: #6f6795;
  --grad-cta: linear-gradient(92deg, #d926a9 0%, #7c3aed 55%, #4f46e5 100%);
  --grad-neon: linear-gradient(92deg, #ff2ec4, #a855f7, #38bdf8);
  --glow-purple: 0 0 24px rgba(168, 85, 247, 0.45);
  --glow-magenta: 0 0 24px rgba(255, 46, 196, 0.35);
  --radius: 18px;
  --radius-sm: 12px;
  font-size: 16px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: "Outfit", -apple-system, "Segoe UI", Roboto, sans-serif;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* club-lighting ambient background */
body::before {
  content: "";
  position: fixed; inset: 0; z-index: -1;
  background:
    radial-gradient(600px 400px at 85% -5%, rgba(255, 46, 196, 0.16), transparent 60%),
    radial-gradient(700px 500px at -10% 20%, rgba(124, 58, 237, 0.20), transparent 60%),
    radial-gradient(500px 400px at 50% 110%, rgba(56, 189, 248, 0.10), transparent 60%),
    var(--bg);
}

h1, h2, h3 { font-weight: 800; letter-spacing: -0.02em; }
a { color: var(--purple); text-decoration: none; }
img { max-width: 100%; }
button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; }

.shell { max-width: 430px; margin: 0 auto; padding: 20px 18px 90px; position: relative; }
.shell-wide { max-width: 1100px; margin: 0 auto; padding: 24px 20px 60px; }

/* ---------- typography helpers ---------- */
.neon-title {
  background: var(--grad-neon);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.script-accent {
  font-family: "Pacifico", "Brush Script MT", cursive;
  font-weight: 400;
  color: var(--magenta);
  text-shadow: 0 0 18px rgba(255, 46, 196, 0.6);
}
.eyebrow {
  font-size: 0.72rem; font-weight: 700; letter-spacing: 0.22em;
  text-transform: uppercase; color: var(--text-dim);
}
.dim { color: var(--text-dim); }
.faint { color: var(--text-faint); font-size: 0.8rem; }
.tiny { font-size: 0.72rem; }
.center { text-align: center; }

/* ---------- cards ---------- */
.card {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  padding: 18px;
  backdrop-filter: blur(12px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.45);
}
.card-glow { box-shadow: var(--glow-purple), 0 8px 32px rgba(0,0,0,.5); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: none; border-radius: 999px;
  padding: 14px 26px;
  font-size: 1rem; font-weight: 700; color: #fff;
  background: var(--grad-cta);
  box-shadow: var(--glow-purple);
  transition: transform 0.12s ease, box-shadow 0.12s ease, filter 0.12s;
  width: 100%;
}
.btn:hover { transform: translateY(-1px); filter: brightness(1.1); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: 0.45; box-shadow: none; cursor: not-allowed; }
.btn-sm { padding: 9px 16px; font-size: 0.85rem; width: auto; }
.btn-ghost {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: none; color: var(--text);
}
.btn-ghost:hover { border-color: var(--purple); }
.btn-outline-neon {
  background: transparent; box-shadow: none;
  border: 1px solid var(--purple); color: var(--purple);
}
.btn-danger { background: linear-gradient(92deg, #be123c, #f43f5e); box-shadow: 0 0 20px rgba(244,63,94,.3); }
.btn-teal { background: linear-gradient(92deg, #0d9488, #2dd4bf); box-shadow: 0 0 20px rgba(45,212,191,.3); }

/* ---------- badges / pills ---------- */
.pill {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 11px; border-radius: 999px;
  font-size: 0.72rem; font-weight: 700;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--text);
}
.pill-live { background: rgba(34,197,94,.15); border-color: rgba(34,197,94,.5); color: #4ade80; }
.pill-live::before { content: ""; width: 7px; height: 7px; border-radius: 50%;
  background: #4ade80; box-shadow: 0 0 8px #4ade80; animation: pulse 1.6s infinite; }
.pill-scheduled { color: var(--blue); border-color: rgba(56,189,248,.4); }
.pill-ended, .pill-expired { color: var(--text-faint); }
.pill-vibe-Social  { background: rgba(124,58,237,.22); border-color: rgba(168,85,247,.6); color: #d8b4fe; }
.pill-vibe-Dance   { background: rgba(56,189,248,.18); border-color: rgba(56,189,248,.55); color: #7dd3fc; }
.pill-vibe-Flirt   { background: rgba(255,46,196,.16); border-color: rgba(255,46,196,.55); color: #ff8ad9; }
.pill-vibe-Friends { background: rgba(45,212,191,.14); border-color: rgba(45,212,191,.5); color: #5eead4; }
.pill-group { background: rgba(251,191,36,.14); border-color: rgba(251,191,36,.45); color: #fcd34d; }

@keyframes pulse { 50% { opacity: 0.4; } }

/* ---------- forms ---------- */
.field { margin-bottom: 15px; }
.field label { display: block; font-size: 0.8rem; font-weight: 600; color: var(--text-dim); margin-bottom: 6px; }
.field input, .field select, .field textarea {
  width: 100%; padding: 13px 15px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-sm);
  color: var(--text); font-size: 1rem;
  outline: none; transition: border-color 0.15s, box-shadow 0.15s;
}
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--purple); box-shadow: 0 0 0 3px rgba(168, 85, 247, 0.18);
}
.field select option { background: var(--bg-2); }

.check-row {
  display: flex; align-items: flex-start; gap: 10px;
  padding: 11px 13px; margin-bottom: 10px;
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: var(--radius-sm);
  font-size: 0.86rem; color: var(--text-dim);
  cursor: pointer; line-height: 1.4;
}
.check-row input { width: 18px; height: 18px; accent-color: var(--purple); flex-shrink: 0; margin-top: 1px; }
.check-row.important { border-color: var(--card-border); color: var(--text); }

/* segmented choice (solo/group, vibes) */
.seg { display: flex; gap: 8px; flex-wrap: wrap; }
.seg button {
  flex: 1; min-width: 72px;
  padding: 11px 10px; border-radius: var(--radius-sm);
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.14);
  color: var(--text-dim); font-weight: 700; font-size: 0.88rem;
  transition: all 0.12s;
}
.seg button.on {
  background: rgba(124,58,237,.28);
  border-color: var(--purple); color: #fff;
  box-shadow: 0 0 14px rgba(168,85,247,.35);
}

/* ---------- guest grid ---------- */
.room-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.guest-card {
  position: relative; border-radius: var(--radius); overflow: hidden;
  border: 1px solid rgba(255,255,255,.12);
  background: var(--bg-3);
  cursor: pointer;
  transition: transform 0.14s, border-color 0.14s, box-shadow 0.14s;
}
.guest-card:hover { transform: translateY(-3px); border-color: var(--purple); box-shadow: var(--glow-purple); }
.guest-card .photo {
  aspect-ratio: 4 / 4.6; width: 100%;
  display: flex; align-items: center; justify-content: center;
  font-size: 3rem; font-weight: 800; color: rgba(255,255,255,.9);
  background-size: cover; background-position: center;
}
.guest-card .meta {
  position: absolute; inset: auto 0 0 0;
  padding: 26px 10px 10px;
  background: linear-gradient(transparent, rgba(5,4,12,0.92) 55%);
}
.guest-card .name { font-weight: 800; font-size: 0.98rem; }
.guest-card .pills { display: flex; gap: 5px; margin-top: 5px; flex-wrap: wrap; }
.guest-card .pills .pill { padding: 2px 8px; font-size: 0.63rem; }

/* ---------- avatar ---------- */
.avatar {
  border-radius: 50%; overflow: hidden; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; color: #fff;
  border: 2px solid rgba(168,85,247,.6);
  box-shadow: 0 0 14px rgba(168,85,247,.35);
  background-size: cover; background-position: center;
}
.avatar-lg { width: 96px; height: 96px; font-size: 2.2rem; }
.avatar-md { width: 54px; height: 54px; font-size: 1.3rem; }
.avatar-sm { width: 38px; height: 38px; font-size: 0.95rem; }

/* ---------- tab bar (guest) ---------- */
.tabbar {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 40;
  display: flex; justify-content: space-around;
  max-width: 430px; margin: 0 auto;
  padding: 8px 6px calc(10px + env(safe-area-inset-bottom));
  background: rgba(10, 8, 22, 0.92);
  backdrop-filter: blur(16px);
  border-top: 1px solid rgba(168, 85, 247, 0.25);
}
.tabbar button {
  background: none; border: none; color: var(--text-faint);
  font-size: 0.62rem; font-weight: 700;
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  padding: 4px 10px; position: relative;
}
.tabbar button .ico { font-size: 1.25rem; }
.tabbar button.on { color: var(--purple); text-shadow: 0 0 12px rgba(168,85,247,.7); }
.tabbar .dot {
  position: absolute; top: 0; right: 4px;
  min-width: 16px; height: 16px; padding: 0 4px;
  border-radius: 999px; background: var(--magenta);
  color: #fff; font-size: 0.62rem; font-weight: 800;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 0 10px rgba(255,46,196,.8);
}

/* ---------- modals & sheets ---------- */
.overlay {
  position: fixed; inset: 0; z-index: 50;
  background: rgba(4, 3, 10, 0.75); backdrop-filter: blur(6px);
  display: flex; align-items: flex-end; justify-content: center;
}
.overlay.centered { align-items: center; padding: 20px; }
.sheet {
  width: 100%; max-width: 430px;
  background: var(--bg-2);
  border: 1px solid var(--card-border); border-bottom: none;
  border-radius: 24px 24px 0 0;
  padding: 20px 20px calc(24px + env(safe-area-inset-bottom));
  max-height: 88vh; overflow-y: auto;
  animation: slideUp 0.22s ease;
}
.overlay.centered .sheet { border-radius: 24px; border-bottom: 1px solid var(--card-border); }
@keyframes slideUp { from { transform: translateY(40px); opacity: 0; } }
.sheet-handle { width: 42px; height: 4px; border-radius: 2px; background: rgba(255,255,255,.2); margin: 0 auto 16px; }

/* ---------- toast / in-app notification ---------- */
#toast-zone { position: fixed; top: 14px; left: 0; right: 0; z-index: 90;
  display: flex; flex-direction: column; align-items: center; gap: 8px; pointer-events: none; }
.toast {
  pointer-events: auto; cursor: pointer;
  max-width: 380px; width: calc(100% - 32px);
  background: rgba(20, 16, 43, 0.97);
  border: 1px solid var(--card-border); border-radius: var(--radius-sm);
  padding: 12px 16px; font-size: 0.88rem;
  box-shadow: var(--glow-purple);
  display: flex; align-items: center; gap: 10px;
  animation: slideDown 0.25s ease;
}
@keyframes slideDown { from { transform: translateY(-20px); opacity: 0; } }
.toast.magenta { border-color: rgba(255,46,196,.5); box-shadow: var(--glow-magenta); }

/* ---------- quick reply chips ---------- */
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chips button {
  padding: 9px 14px; border-radius: 999px;
  background: rgba(56,189,248,.1);
  border: 1px solid rgba(56,189,248,.4);
  color: #9adcff; font-size: 0.82rem; font-weight: 600;
  transition: all 0.12s;
}
.chips button:hover { background: rgba(56,189,248,.22); }

/* ---------- connection messages ---------- */
.msg-list { display: flex; flex-direction: column; gap: 8px; padding: 12px 0; min-height: 120px; }
.msg { max-width: 78%; padding: 9px 14px; border-radius: 16px; font-size: 0.9rem; line-height: 1.35; }
.msg.me { align-self: flex-end; background: var(--grad-cta); border-bottom-right-radius: 4px; }
.msg.them { align-self: flex-start; background: rgba(255,255,255,.08); border-bottom-left-radius: 4px; }
.msg .qr-tag { display: block; font-size: 0.6rem; opacity: 0.7; margin-top: 2px; letter-spacing: 0.08em; text-transform: uppercase; }

/* ---------- invite request card ---------- */
.invite-card {
  border: 1px solid rgba(255,46,196,.4); border-radius: var(--radius);
  background: linear-gradient(160deg, rgba(255,46,196,.08), rgba(124,58,237,.08));
  padding: 16px; margin-bottom: 12px;
  box-shadow: 0 0 18px rgba(255,46,196,.12);
}
.invite-card .head { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.invite-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.invite-actions .btn-sm { width: 100%; }

/* ---------- option list (invite types) ---------- */
.option-list { display: flex; flex-direction: column; gap: 9px; }
.option-list button {
  display: flex; align-items: center; gap: 12px;
  width: 100%; padding: 14px 16px;
  border-radius: var(--radius-sm); text-align: left;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.13);
  color: var(--text); font-size: 0.95rem; font-weight: 600;
  transition: all 0.12s;
}
.option-list button:hover { border-color: var(--magenta); background: rgba(255,46,196,.08); }
.option-list .sub { display: block; font-size: 0.72rem; color: var(--text-faint); font-weight: 400; }

/* ---------- admin ---------- */
.stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.stat {
  background: var(--card); border: 1px solid rgba(255,255,255,.1);
  border-radius: var(--radius-sm); padding: 14px 16px;
}
.stat .num { font-size: 1.7rem; font-weight: 800; }
.stat .lbl { font-size: 0.72rem; color: var(--text-dim); font-weight: 600; letter-spacing: 0.04em; }
.stat.hot .num { color: var(--magenta); text-shadow: 0 0 14px rgba(255,46,196,.5); }

table.data { width: 100%; border-collapse: collapse; font-size: 0.86rem; }
table.data th { text-align: left; padding: 9px 10px; color: var(--text-dim); font-size: 0.72rem;
  text-transform: uppercase; letter-spacing: 0.08em; border-bottom: 1px solid rgba(255,255,255,.12); }
table.data td { padding: 10px; border-bottom: 1px solid rgba(255,255,255,.06); }

.admin-top {
  display: flex; align-items: center; justify-content: space-between;
  gap: 14px; flex-wrap: wrap; margin-bottom: 22px;
}
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.grow { flex: 1; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 720px) { .grid-2 { grid-template-columns: 1fr; } }

/* ---------- QR box ---------- */
.qr-box {
  background: #fff; border-radius: var(--radius-sm);
  padding: 10px; display: inline-block; line-height: 0;
  box-shadow: var(--glow-purple);
}
.qr-box img, .qr-box canvas { width: 150px; height: 150px; }

/* ---------- story card ---------- */
.story-card {
  aspect-ratio: 9 / 14; max-width: 300px; margin: 0 auto;
  border-radius: 22px; overflow: hidden; position: relative;
  border: 1px solid rgba(255,46,196,.5);
  background:
    radial-gradient(300px 220px at 80% 0%, rgba(255,46,196,.35), transparent 60%),
    radial-gradient(300px 260px at 10% 30%, rgba(124,58,237,.45), transparent 60%),
    radial-gradient(260px 200px at 50% 105%, rgba(56,189,248,.3), transparent 60%),
    #0a0818;
  box-shadow: var(--glow-magenta);
  display: flex; flex-direction: column; justify-content: space-between;
  padding: 26px 22px; text-align: center;
}

/* ---------- misc ---------- */
.divider { height: 1px; background: rgba(255,255,255,.08); margin: 18px 0; }
.spacer { height: 14px; }
.hidden { display: none !important; }
.footer-brand {
  text-align: center; padding: 22px 0 8px;
  font-size: 0.72rem; color: var(--text-faint);
}
.footer-brand b { background: var(--grad-neon); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }

.demo-banner {
  position: sticky; top: 0; z-index: 60;
  background: linear-gradient(90deg, rgba(251,191,36,.14), rgba(255,46,196,.12));
  border-bottom: 1px solid rgba(251,191,36,.3);
  color: #fcd34d; font-size: 0.72rem; font-weight: 600;
  text-align: center; padding: 6px 12px;
}

.screen { animation: fadeIn 0.25s ease; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } }

::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-thumb { background: rgba(168,85,247,.35); border-radius: 4px; }
