/* ─────────────────────────────────────────────────────
   SpareRoom Tracker — style.css
   spareroomtrack.tonykumar.eu
───────────────────────────────────────────────────── */

:root {
  --bg:          #080c18;
  --bg2:         #0e1526;
  --bg3:         #141d30;
  --card:        rgba(255,255,255,0.035);
  --card-h:      rgba(255,255,255,0.06);
  --border:      rgba(255,255,255,0.07);
  --border-h:    rgba(139,92,246,0.45);
  --accent:      #8b5cf6;
  --accent2:     #6366f1;
  --accent-soft: rgba(139,92,246,0.15);
  --text1:       #f0f4ff;
  --text2:       #94a3b8;
  --text3:       #4b5768;
  --radius:      18px;
  --radius-sm:   11px;
  --shadow:      0 24px 60px rgba(0,0,0,0.5);
}

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

body {
  font-family:'Inter',sans-serif;
  background: var(--bg);
  color: var(--text1);
  min-height: 100vh;
  overflow-x: hidden;
}

/* Ambient glows */
body::before, body::after {
  content:''; position:fixed; border-radius:50%;
  pointer-events:none; z-index:0;
}
body::before {
  width:700px; height:700px;
  top:-250px; left:-250px;
  background: radial-gradient(circle, rgba(139,92,246,0.10) 0%, transparent 70%);
}
body::after {
  width:600px; height:600px;
  bottom:-200px; right:-200px;
  background: radial-gradient(circle, rgba(99,102,241,0.08) 0%, transparent 70%);
}

/* ─── LOADING SCREEN ─────────────────────────────── */
.loading-screen {
  position:fixed; inset:0; z-index:999;
  background:var(--bg);
  display:flex; flex-direction:column;
  align-items:center; justify-content:center; gap:12px;
  transition:opacity 0.4s;
}
.loader-logo  { animation:pulse 1.5s ease-in-out infinite; }
.loader-text  { font-size:1.4rem; font-weight:800; background:linear-gradient(135deg,#a78bfa,#6366f1); -webkit-background-clip:text; -webkit-text-fill-color:transparent; }
.loader-sub   { font-size:0.85rem; color:var(--text3); }
.loader-spinner {
  width:28px; height:28px; border-radius:50%;
  border:3px solid var(--border);
  border-top-color:var(--accent);
  animation:spin 0.8s linear infinite; margin-top:8px;
}
@keyframes spin  { to{transform:rotate(360deg)} }
@keyframes pulse { 0%,100%{transform:scale(1)} 50%{transform:scale(1.08)} }

/* ─── SETUP BANNER ───────────────────────────────── */
.setup-banner {
  background:linear-gradient(135deg,rgba(139,92,246,0.2),rgba(99,102,241,0.2));
  border-bottom:1px solid rgba(139,92,246,0.3);
  padding:12px 24px; z-index:90; position:relative;
  display:flex; align-items:center; justify-content:center;
}
.setup-inner { display:flex; align-items:center; gap:12px; max-width:900px; width:100%; }
.setup-icon  { font-size:1.3rem; flex-shrink:0; }
.setup-text  { font-size:0.875rem; color:var(--text2); flex:1; }
.setup-text strong { color:var(--text1); }
.btn-setup {
  padding:8px 18px; border-radius:50px;
  background:var(--accent); color:#fff;
  border:none; font-size:0.8rem; font-weight:600; font-family:inherit;
  cursor:pointer; white-space:nowrap;
  transition:opacity 0.2s;
}
.btn-setup:hover { opacity:0.85; }

/* ─── SETUP GUIDE OVERLAY ────────────────────────── */
.setup-guide-overlay {
  position:fixed; inset:0; z-index:300;
  background:rgba(0,0,0,0.75); backdrop-filter:blur(10px);
  display:flex; align-items:center; justify-content:center; padding:20px;
}
.setup-guide-modal {
  background:var(--bg3); border:1px solid var(--border);
  border-radius:var(--radius); padding:32px; max-width:580px; width:100%;
  max-height:90vh; overflow-y:auto;
  box-shadow:var(--shadow);
}
.setup-guide-modal h2 { font-size:1.3rem; margin-bottom:6px; }
.sg-sub { font-size:0.875rem; color:var(--text2); margin-bottom:24px; line-height:1.6; }
.sg-step {
  display:flex; gap:14px; align-items:flex-start;
  margin-bottom:16px; font-size:0.9rem; color:var(--text2); line-height:1.6;
}
.sg-num {
  width:26px; height:26px; border-radius:50%; flex-shrink:0;
  background:linear-gradient(135deg,var(--accent),var(--accent2));
  display:flex; align-items:center; justify-content:center;
  font-size:0.75rem; font-weight:700; color:#fff;
}
.sg-step strong { color:var(--text1); }
.sg-step a { color:var(--accent); }
.sg-step code { background:var(--bg2); padding:2px 6px; border-radius:4px; font-size:0.82rem; }
.sg-fields {
  display:grid; grid-template-columns:1fr 1fr;
  gap:12px; margin:16px 0;
}
.sg-fields label { display:flex; flex-direction:column; gap:5px; font-size:0.78rem; font-weight:600; color:var(--text2); text-transform:uppercase; letter-spacing:0.5px; }
.sg-input {
  background:var(--bg2); border:1px solid var(--border);
  border-radius:8px; padding:8px 12px;
  color:var(--text1); font-size:0.85rem; font-family:inherit; outline:none;
}
.sg-input:focus { border-color:var(--accent); }
.sg-save {
  width:100%; padding:12px;
  background:linear-gradient(135deg,var(--accent),var(--accent2));
  border:none; border-radius:50px;
  color:#fff; font-size:0.9rem; font-weight:700; font-family:inherit;
  cursor:pointer; margin-top:8px;
  transition:opacity 0.2s;
}
.sg-save:hover { opacity:0.88; }
.sg-note { font-size:0.77rem; color:var(--text3); text-align:center; margin-top:10px; }

/* ─── HEADER ──────────────────────────────────────── */
header {
  position:sticky; top:0; z-index:100;
  background:rgba(8,12,24,0.88);
  backdrop-filter:blur(24px);
  border-bottom:1px solid var(--border);
}
.header-inner {
  max-width:1440px; margin:0 auto;
  display:flex; align-items:center; gap:18px; height:70px; padding:0 28px;
}

.logo { display:flex; align-items:center; gap:10px; white-space:nowrap; }
.logo-text { font-size:1.15rem; font-weight:800; color:var(--text1); }
.logo-accent { background:linear-gradient(135deg,#a78bfa,#6366f1); -webkit-background-clip:text; -webkit-text-fill-color:transparent; }

.header-search { flex:1; max-width:420px; position:relative; }
.header-search input {
  width:100%; background:var(--card);
  border:1px solid var(--border);
  border-radius:50px; padding:10px 16px 10px 40px;
  color:var(--text1); font-size:0.875rem; font-family:inherit; outline:none;
  transition:border-color 0.2s, box-shadow 0.2s;
}
.header-search input:focus { border-color:var(--accent); box-shadow:0 0 0 3px var(--accent-soft); }
.search-icon { position:absolute; left:14px; top:50%; transform:translateY(-50%); color:var(--text3); pointer-events:none; }

.header-actions { margin-left:auto; display:flex; align-items:center; gap:12px; }

.live-dot {
  display:flex; align-items:center; gap:6px;
  font-size:0.75rem; color:var(--text3); font-weight:500;
}
.live-dot span {
  width:8px; height:8px; border-radius:50%; background:#10b981;
  box-shadow:0 0 6px #10b981;
  animation:livePulse 2s ease-in-out infinite;
}
@keyframes livePulse { 0%,100%{opacity:1} 50%{opacity:0.4} }

/* ─── BUTTONS ─────────────────────────────────────── */
.btn-primary {
  display:inline-flex; align-items:center; gap:7px;
  padding:10px 22px; border-radius:50px;
  background:linear-gradient(135deg,#8b5cf6,#6366f1);
  color:#fff; font-size:0.875rem; font-weight:700; font-family:inherit;
  border:none; cursor:pointer;
  box-shadow:0 4px 18px rgba(139,92,246,0.4);
  transition:opacity 0.2s, transform 0.2s, box-shadow 0.2s;
}
.btn-primary:hover { opacity:0.9; transform:translateY(-1px); box-shadow:0 6px 24px rgba(139,92,246,0.55); }

.btn-secondary {
  display:inline-flex; align-items:center; gap:7px;
  padding:10px 20px; border-radius:50px;
  background:var(--card); border:1px solid var(--border);
  color:var(--text2); font-size:0.875rem; font-weight:500; font-family:inherit;
  cursor:pointer; transition:all 0.2s;
}
.btn-secondary:hover { border-color:var(--accent); color:var(--text1); }

.btn-danger {
  display:inline-flex; align-items:center; gap:7px;
  padding:10px 20px; border-radius:50px;
  background:rgba(239,68,68,0.12); border:1px solid rgba(239,68,68,0.25);
  color:#ef4444; font-size:0.875rem; font-weight:500; font-family:inherit;
  cursor:pointer; transition:all 0.2s;
}
.btn-danger:hover { background:rgba(239,68,68,0.2); border-color:#ef4444; }

/* ─── MAIN LAYOUT ─────────────────────────────────── */
.app-layout {
  max-width:1440px; margin:0 auto;
  padding:32px 28px;
  position:relative; z-index:1;
}

/* ─── HERO BAND ───────────────────────────────────── */
.hero-band {
  display:flex; align-items:center; justify-content:space-between;
  flex-wrap:wrap; gap:12px;
  background:linear-gradient(135deg,rgba(139,92,246,0.12),rgba(99,102,241,0.08));
  border:1px solid rgba(139,92,246,0.18);
  border-radius:var(--radius); padding:24px 28px;
  margin-bottom:28px;
}
.hero-title { font-size:1.6rem; font-weight:900; letter-spacing:-0.5px; }
.hero-sub   { font-size:0.9rem; color:var(--text2); margin-top:4px; }
.hero-url   {
  font-size:0.78rem; font-weight:600;
  background:var(--accent-soft); border:1px solid rgba(139,92,246,0.3);
  border-radius:50px; padding:6px 16px; color:var(--accent);
  letter-spacing:0.3px;
}

/* ─── STATS BAR ───────────────────────────────────── */
.stats-bar {
  display:grid; grid-template-columns:repeat(6,1fr);
  gap:14px; margin-bottom:28px;
}
.stat-card {
  background:var(--card); border:1px solid var(--border);
  border-radius:var(--radius-sm); padding:18px 20px;
  display:flex; flex-direction:column; gap:4px;
  transition:border-color 0.2s, transform 0.2s;
}
.stat-card:hover { border-color:var(--border-h); transform:translateY(-2px); }
.stat-num {
  font-size:2rem; font-weight:900; line-height:1;
  background:linear-gradient(135deg,#a78bfa,#6366f1);
  -webkit-background-clip:text; -webkit-text-fill-color:transparent;
}
.stat-label { font-size:0.72rem; color:var(--text3); font-weight:600; text-transform:uppercase; letter-spacing:0.6px; }

/* ─── FILTER BAR ──────────────────────────────────── */
.filter-bar {
  display:flex; align-items:center; gap:8px; flex-wrap:wrap;
  margin-bottom:24px;
}
.filter-label { font-size:0.78rem; color:var(--text3); font-weight:600; text-transform:uppercase; letter-spacing:0.5px; margin-right:2px; }
.filter-btn {
  padding:7px 15px; border-radius:50px;
  border:1px solid var(--border); background:var(--card);
  color:var(--text2); font-size:0.8rem; font-weight:500; font-family:inherit;
  cursor:pointer; transition:all 0.2s;
}
.filter-btn:hover { border-color:var(--accent); color:var(--text1); }
.filter-btn.active {
  background:linear-gradient(135deg,#8b5cf6,#6366f1);
  border-color:transparent; color:#fff;
  box-shadow:0 2px 10px rgba(139,92,246,0.35);
}
.sort-select {
  margin-left:auto;
  background:var(--card); border:1px solid var(--border);
  color:var(--text2); border-radius:8px;
  padding:7px 12px; font-size:0.8rem; font-family:inherit; outline:none;
  cursor:pointer;
}

/* ─── CARDS GRID ──────────────────────────────────── */
.cards-grid {
  display:grid;
  grid-template-columns:repeat(auto-fill,minmax(330px,1fr));
  gap:20px;
}

/* ─── LANDLORD CARD ───────────────────────────────── */
.landlord-card {
  background:var(--card); border:1px solid var(--border);
  border-radius:var(--radius); padding:22px;
  cursor:pointer; position:relative; overflow:hidden;
  transition:border-color 0.25s, transform 0.25s, box-shadow 0.25s;
  animation:fadeUp 0.35s ease both;
}
.landlord-card::after {
  content:''; position:absolute; inset:0;
  background:linear-gradient(135deg,rgba(139,92,246,0.04),transparent);
  opacity:0; transition:opacity 0.25s; border-radius:var(--radius);
}
.landlord-card:hover {
  border-color:var(--border-h);
  transform:translateY(-5px);
  box-shadow:0 24px 50px rgba(0,0,0,0.35), 0 0 0 1px rgba(139,92,246,0.12);
}
.landlord-card:hover::after { opacity:1; }

/* Priority bar at top */
.card-priority-bar { position:absolute; top:0; left:0; right:0; height:3px; border-radius:var(--radius) var(--radius) 0 0; }

@keyframes fadeUp { from{opacity:0;transform:translateY(18px)} to{opacity:1;transform:translateY(0)} }

.card-header { display:flex; align-items:flex-start; gap:14px; margin-bottom:16px; }

.card-avatar {
  width:56px; height:56px; border-radius:50%; flex-shrink:0;
  overflow:hidden;
  background:linear-gradient(135deg,#8b5cf6,#6366f1);
  display:flex; align-items:center; justify-content:center;
  font-size:1.1rem; font-weight:800; color:#fff;
  border:2px solid var(--border);
  box-shadow:0 0 14px rgba(139,92,246,0.25);
}
.card-avatar img { width:100%; height:100%; object-fit:cover; }

.card-info { flex:1; min-width:0; }
.card-name  { font-size:1rem; font-weight:700; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; margin-bottom:3px; }
.card-location, .card-roomtype { font-size:0.78rem; color:var(--text3); margin-top:1px; }

.card-right { display:flex; flex-direction:column; align-items:flex-end; gap:6px; flex-shrink:0; }

/* ─── STATUS BADGE ────────────────────────────────── */
.status-badge {
  display:inline-flex; align-items:center; gap:4px;
  padding:4px 10px; border-radius:50px;
  font-size:0.72rem; font-weight:700; text-transform:uppercase; letter-spacing:0.4px;
  white-space:nowrap;
}
.s-interested { background:rgba(59,130,246,0.14); color:#60a5fa; }
.s-waiting    { background:rgba(245,158,11,0.14); color:#fbbf24; }
.s-viewing    { background:rgba(16,185,129,0.14); color:#34d399; }
.s-accepted   { background:rgba(34,197,94,0.14);  color:#4ade80; }
.s-rejected   { background:rgba(239,68,68,0.14);  color:#f87171; }
.s-noresp     { background:rgba(107,114,128,0.14);color:#9ca3af; }

.bills-badge {
  display:inline-block; padding:2px 8px; border-radius:50px;
  background:rgba(16,185,129,0.12); color:#34d399;
  font-size:0.68rem; font-weight:600; text-transform:uppercase; letter-spacing:0.4px;
}

/* ─── CARD META ───────────────────────────────────── */
.card-meta {
  display:grid; grid-template-columns:1fr 1fr 1fr;
  gap:10px; margin-bottom:12px;
}
.meta-item { display:flex; flex-direction:column; gap:2px; }
.meta-k { font-size:0.67rem; color:var(--text3); font-weight:600; text-transform:uppercase; letter-spacing:0.4px; }
.meta-v { font-size:0.875rem; font-weight:700; color:var(--text1); }
.rent-val { color:#a78bfa; font-size:1rem; }

.card-viewing {
  font-size:0.8rem; color:#34d399; font-weight:600;
  background:rgba(16,185,129,0.1); border-radius:8px;
  padding:7px 10px; margin-bottom:10px;
}

.card-notes {
  font-size:0.8rem; color:var(--text2);
  border-left:3px solid var(--accent);
  padding:8px 12px; border-radius:0 8px 8px 0;
  background:rgba(255,255,255,0.025);
  margin-bottom:12px;
  display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden;
}

.card-footer {
  display:flex; align-items:center; justify-content:space-between;
  padding-top:12px; border-top:1px solid var(--border);
}
.card-date { font-size:0.73rem; color:var(--text3); }

.card-actions { display:flex; gap:6px; }
.icon-btn {
  width:30px; height:30px; border-radius:8px;
  border:1px solid var(--border); background:var(--card);
  color:var(--text2); cursor:pointer;
  display:flex; align-items:center; justify-content:center;
  font-size:0.78rem;
  transition:all 0.2s; text-decoration:none;
}
.icon-btn:hover         { border-color:var(--accent); background:var(--accent-soft); }
.icon-btn.danger:hover  { border-color:#ef4444; background:rgba(239,68,68,0.12); }

/* ─── EMPTY STATE ─────────────────────────────────── */
.empty-state {
  grid-column:1/-1; text-align:center; padding:90px 24px;
  color:var(--text3);
}
.empty-icon { font-size:3.5rem; margin-bottom:14px; opacity:0.5; }
.empty-state h3 { font-size:1.2rem; color:var(--text2); margin-bottom:8px; }
.empty-state p  { font-size:0.9rem; line-height:1.6; }
.empty-state strong { color:var(--text1); }

/* ─── MODAL ───────────────────────────────────────── */
.modal-overlay {
  display:none; position:fixed; inset:0; z-index:200;
  background:rgba(0,0,0,0.72); backdrop-filter:blur(10px);
  align-items:center; justify-content:center; padding:20px;
}
.modal-overlay.open { display:flex; }

.modal {
  background:#111827;
  border:1px solid var(--border);
  border-radius:22px;
  width:100%; max-width:580px; max-height:92vh; overflow-y:auto;
  box-shadow:0 50px 100px rgba(0,0,0,0.65);
  animation:modalIn 0.28s cubic-bezier(.22,1,.36,1);
}
.modal-wide { max-width:640px; }

@keyframes modalIn { from{opacity:0;transform:scale(0.94) translateY(20px)} to{opacity:1;transform:scale(1) translateY(0)} }

.modal-header {
  display:flex; align-items:center; justify-content:space-between;
  padding:26px 30px 0;
}
.modal-title { font-size:1.15rem; font-weight:800; }
.modal-close {
  width:34px; height:34px; border-radius:50%;
  border:1px solid var(--border); background:var(--card);
  color:var(--text2); cursor:pointer; font-size:1rem;
  display:flex; align-items:center; justify-content:center;
  transition:all 0.2s;
}
.modal-close:hover { border-color:#ef4444; color:#ef4444; }
.modal-body   { padding:22px 30px; display:flex; flex-direction:column; gap:16px; }
.modal-footer { display:flex; justify-content:flex-end; gap:10px; padding:0 30px 28px; }

/* ─── FORM ELEMENTS ───────────────────────────────── */
.form-group { display:flex; flex-direction:column; gap:7px; }
.form-label {
  font-size:0.75rem; font-weight:700;
  color:var(--text2); text-transform:uppercase; letter-spacing:0.6px;
}
.form-input, .form-select, .form-textarea {
  background:var(--bg2); border:1px solid var(--border);
  border-radius:var(--radius-sm); padding:11px 14px;
  color:var(--text1); font-size:0.9rem; font-family:inherit; outline:none; width:100%;
  transition:border-color 0.2s, box-shadow 0.2s;
}
.form-input:focus, .form-select:focus, .form-textarea:focus {
  border-color:var(--accent); box-shadow:0 0 0 3px var(--accent-soft);
}
.form-select option { background:#1a2235; }
.form-textarea { resize:vertical; min-height:90px; line-height:1.6; }
.form-row { display:grid; grid-template-columns:1fr 1fr; gap:14px; }

/* ─── AVATAR UPLOAD ───────────────────────────────── */
.avatar-upload-row { display:flex; align-items:center; gap:16px; }
.avatar-upload-circle {
  width:76px; height:76px; border-radius:50%; flex-shrink:0;
  background:linear-gradient(135deg,#8b5cf6,#6366f1);
  border:2px dashed rgba(139,92,246,0.4);
  display:flex; align-items:center; justify-content:center;
  font-size:1.4rem; font-weight:800; color:#fff;
  cursor:pointer; overflow:hidden;
  transition:border-color 0.2s, box-shadow 0.2s;
}
.avatar-upload-circle:hover { border-color:var(--accent); box-shadow:0 0 14px var(--accent-soft); }
.avatar-upload-circle img { width:100%; height:100%; object-fit:cover; }
.avatar-hint p { font-size:0.83rem; color:var(--text2); line-height:1.5; }
.hint-sub { font-size:0.75rem; color:var(--text3) !important; }

/* ─── PRIORITY ROW ────────────────────────────────── */
.priority-row { display:flex; gap:10px; }
.priority-btn {
  flex:1; padding:9px; border-radius:var(--radius-sm);
  border:1px solid var(--border); background:var(--card);
  color:var(--text2); font-size:0.83rem; font-weight:600; font-family:inherit;
  cursor:pointer; transition:all 0.2s; text-align:center;
}
.priority-btn:hover { border-color:var(--accent); color:var(--text1); }
.priority-btn.active { border-color:var(--accent); background:var(--accent-soft); color:var(--text1); }

/* ─── DETAIL VIEW ─────────────────────────────────── */
.detail-top {
  display:flex; align-items:center; gap:18px;
  margin-bottom:4px;
}
.detail-avatar {
  width:88px; height:88px; border-radius:50%; flex-shrink:0;
  background:linear-gradient(135deg,#8b5cf6,#6366f1);
  border:3px solid var(--accent);
  box-shadow:0 0 24px rgba(139,92,246,0.3);
  display:flex; align-items:center; justify-content:center;
  font-size:1.8rem; font-weight:800; color:#fff; overflow:hidden;
}
.detail-avatar img { width:100%; height:100%; object-fit:cover; }
.detail-name { font-size:1.35rem; font-weight:800; margin-bottom:6px; }
.detail-loc  { font-size:0.82rem; color:var(--text3); margin-top:5px; }

.detail-grid {
  display:grid; grid-template-columns:1fr 1fr; gap:12px;
}
.detail-tile {
  background:var(--bg2); border:1px solid var(--border);
  border-radius:var(--radius-sm); padding:14px 16px;
}
.dt-k { font-size:0.7rem; color:var(--text3); text-transform:uppercase; letter-spacing:0.5px; font-weight:600; margin-bottom:5px; }
.dt-v { font-size:0.95rem; font-weight:700; color:var(--text1); }

.listing-link {
  display:inline-flex; align-items:center; gap:6px;
  color:var(--accent); font-size:0.85rem; font-weight:600;
  text-decoration:none; padding:8px 14px;
  background:var(--accent-soft); border-radius:50px;
  transition:opacity 0.2s;
}
.listing-link:hover { opacity:0.8; }

.detail-section-label {
  font-size:0.75rem; font-weight:700; text-transform:uppercase;
  letter-spacing:0.8px; color:var(--text3);
}
.detail-notes {
  background:var(--bg2); border-left:3px solid var(--accent);
  border-radius:0 var(--radius-sm) var(--radius-sm) 0;
  padding:14px 16px; font-size:0.875rem; color:var(--text2); line-height:1.7;
}
.detail-meta { font-size:0.73rem; color:var(--text3); }

/* ─── TOAST ───────────────────────────────────────── */
.toast-container { position:fixed; bottom:24px; right:24px; z-index:999; display:flex; flex-direction:column; gap:10px; }
.toast {
  background:#1a2235; border:1px solid var(--border);
  border-radius:12px; padding:13px 18px;
  font-size:0.875rem; font-weight:500;
  box-shadow:0 10px 30px rgba(0,0,0,0.5);
  animation:toastIn 0.3s ease;
  transition:opacity 0.4s; max-width:300px;
}
.toast.success { border-left:4px solid #10b981; }
.toast.error   { border-left:4px solid #ef4444; }
@keyframes toastIn { from{opacity:0;transform:translateX(24px)} to{opacity:1;transform:translateX(0)} }

/* ─── SCROLLBAR ───────────────────────────────────── */
::-webkit-scrollbar { width:5px; height:5px; }
::-webkit-scrollbar-track { background:transparent; }
::-webkit-scrollbar-thumb { background:rgba(139,92,246,0.3); border-radius:3px; }

/* ─── RESPONSIVE ──────────────────────────────────── */
@media (max-width:1100px) { .stats-bar { grid-template-columns:repeat(3,1fr); } }
@media (max-width:700px) {
  .header-inner    { padding:0 16px; gap:10px; }
  .logo-text       { display:none; }
  .live-dot        { display:none; }
  .app-layout      { padding:20px 16px; }
  .hero-band       { padding:18px 20px; }
  .hero-title      { font-size:1.2rem; }
  .hero-url        { display:none; }
  .stats-bar       { grid-template-columns:repeat(2,1fr); }
  .cards-grid      { grid-template-columns:1fr; }
  .form-row        { grid-template-columns:1fr; }
  .detail-grid     { grid-template-columns:1fr; }
  .sg-fields       { grid-template-columns:1fr; }
  .card-meta       { grid-template-columns:1fr 1fr; }
  .filter-bar      { gap:6px; }
  .filter-btn      { font-size:0.73rem; padding:5px 11px; }
}

/* ─── SETUP WIZARD ────────────────────────────────── */
.setup-wizard-overlay {
  position:fixed; inset:0; z-index:300;
  background:rgba(5,8,18,0.96); backdrop-filter:blur(14px);
  display:flex; align-items:center; justify-content:center; padding:20px;
  overflow-y:auto;
}
.setup-wizard {
  background:#0f1828;
  border:1px solid var(--border);
  border-radius:24px;
  width:100%; max-width:640px;
  box-shadow:0 50px 100px rgba(0,0,0,0.7);
  overflow:hidden;
  animation:modalIn 0.35s cubic-bezier(.22,1,.36,1);
}
.wizard-head {
  background:linear-gradient(135deg,rgba(139,92,246,0.18),rgba(99,102,241,0.1));
  border-bottom:1px solid var(--border);
  padding:28px 32px;
}
.wizard-logo {
  display:flex; align-items:center; gap:10px;
  font-size:1.2rem; font-weight:800; color:var(--text1); margin-bottom:8px;
}
.wizard-subtitle { font-size:0.85rem; color:var(--text2); }

/* Step indicators */
.wizard-steps {
  display:flex; align-items:center;
  padding:20px 32px; border-bottom:1px solid var(--border);
  gap:0;
}
.wstep {
  display:flex; align-items:center; gap:8px;
  font-size:0.8rem; font-weight:600; color:var(--text3);
  transition:color 0.2s;
}
.wstep span {
  width:26px; height:26px; border-radius:50%; flex-shrink:0;
  background:var(--bg3); border:1px solid var(--border);
  display:flex; align-items:center; justify-content:center;
  font-size:0.75rem; font-weight:700; transition:all 0.2s;
}
.wstep.active { color:var(--text1); }
.wstep.active span { background:linear-gradient(135deg,var(--accent),var(--accent2)); border-color:transparent; color:#fff; }
.wstep.done span   { background:#10b981; border-color:transparent; color:#fff; }
.wstep.done span::before { content:'✓'; }
.wstep.done span { font-size:0; }
.wstep.done span::before { font-size:0.75rem; }
.wstep-line { flex:1; height:1px; background:var(--border); margin:0 8px; }

/* Step body */
.wstep-body { padding:28px 32px; }
.wstep-icon { font-size:2.4rem; margin-bottom:12px; }
.wstep-body h3 { font-size:1.15rem; font-weight:800; margin-bottom:8px; }
.wstep-desc { font-size:0.875rem; color:var(--text2); margin-bottom:18px; line-height:1.6; }

.wstep-list {
  list-style:none; display:flex; flex-direction:column; gap:10px;
  counter-reset:li; margin-bottom:16px;
}
.wstep-list li {
  display:flex; gap:10px; align-items:flex-start;
  font-size:0.875rem; color:var(--text2); line-height:1.6;
  counter-increment:li;
}
.wstep-list li::before {
  content:counter(li);
  width:22px; height:22px; border-radius:50%; flex-shrink:0;
  background:var(--accent-soft); border:1px solid rgba(139,92,246,0.3);
  color:var(--accent); font-size:0.72rem; font-weight:700;
  display:flex; align-items:center; justify-content:center; margin-top:1px;
}
.wstep-list li strong { color:var(--text1); }
.wstep-list li a { color:var(--accent); text-decoration:none; font-weight:600; }
.wstep-list li a:hover { text-decoration:underline; }

.wstep-tip {
  background:rgba(139,92,246,0.08); border:1px solid rgba(139,92,246,0.2);
  border-radius:10px; padding:10px 14px;
  font-size:0.8rem; color:var(--text2); margin-bottom:20px; line-height:1.5;
}
.wstep-tip strong { color:var(--text1); }
.wstep-next { width:100%; justify-content:center; }

.link-btn {
  display:inline-flex; align-items:center; gap:5px;
  padding:5px 14px; border-radius:50px;
  background:linear-gradient(135deg,var(--accent),var(--accent2));
  color:#fff; font-size:0.82rem; font-weight:700; text-decoration:none;
  box-shadow:0 2px 10px rgba(139,92,246,0.35); transition:opacity 0.2s;
}
.link-btn:hover { opacity:0.85; }

/* Code block */
.code-block {
  position:relative;
  background:#07111e;
  border:1px solid var(--border);
  border-radius:var(--radius-sm);
  padding:14px 14px 14px 14px;
  margin-bottom:16px; overflow-x:auto;
}
.code-block pre {
  font-family:'Courier New', monospace;
  font-size:0.72rem; color:#7dd3fc; line-height:1.6;
  white-space:pre; overflow-x:auto;
  max-height:200px; overflow-y:auto;
}
.copy-btn {
  position:absolute; top:10px; right:10px;
  padding:5px 12px; border-radius:6px;
  background:var(--accent); color:#fff;
  border:none; font-size:0.75rem; font-weight:600; font-family:inherit;
  cursor:pointer; transition:opacity 0.2s; z-index:2;
}
.copy-btn:hover { opacity:0.85; }

/* Sync indicator */
.sync-indicator {
  display:flex; align-items:center; gap:6px;
  font-size:0.75rem; color:#10b981; font-weight:600;
  background:rgba(16,185,129,0.1); border:1px solid rgba(16,185,129,0.2);
  border-radius:50px; padding:5px 12px;
  transition:all 0.3s;
}
.live-dot-inner {
  width:7px; height:7px; border-radius:50%; background:#10b981;
  box-shadow:0 0 6px #10b981; flex-shrink:0;
  animation:livePulse 2s ease-in-out infinite;
}
@keyframes livePulse { 0%,100%{opacity:1} 50%{opacity:0.35} }

/* Hero right */
.hero-right { display:flex; align-items:center; gap:10px; flex-wrap:wrap; }
.btn-refresh {
  padding:7px 16px; border-radius:50px;
  background:var(--card); border:1px solid var(--border);
  color:var(--text2); font-size:0.8rem; font-weight:600; font-family:inherit;
  cursor:pointer; transition:all 0.2s;
}
.btn-refresh:hover { border-color:var(--accent); color:var(--text1); }

/* ─── SHARE BUTTON ────────────────────────────────── */
.btn-share {
  padding:9px 18px; border-radius:50px;
  background:rgba(16,185,129,0.12); border:1px solid rgba(16,185,129,0.3);
  color:#34d399; font-size:0.875rem; font-weight:600; font-family:inherit;
  cursor:pointer; transition:all 0.2s;
}
.btn-share:hover { background:rgba(16,185,129,0.2); border-color:#34d399; }

/* ─── HERO URL BADGE ──────────────────────────────── */
.hero-url-badge {
  font-size:0.78rem; font-weight:600;
  background:var(--accent-soft); border:1px solid rgba(139,92,246,0.3);
  border-radius:50px; padding:7px 16px; color:var(--accent);
  letter-spacing:0.3px; white-space:nowrap;
}

/* ─── SHARE MODAL ─────────────────────────────────── */
.share-info {
  text-align:center; padding:10px 0 4px;
}
.share-icon { font-size:2.5rem; margin-bottom:10px; }
.share-info p { font-size:0.875rem; color:var(--text2); line-height:1.6; }

.share-section { display:flex; flex-direction:column; gap:8px; }
.share-section-title {
  font-size:0.8rem; font-weight:700; text-transform:uppercase;
  letter-spacing:0.6px; color:var(--text2);
}
.share-desc { font-size:0.85rem; color:var(--text3); line-height:1.6; }
.share-action-btn { width:100%; justify-content:center; }

.share-divider {
  text-align:center; color:var(--text3);
  font-size:0.8rem; font-weight:600;
  display:flex; align-items:center; gap:12px;
}
.share-divider::before, .share-divider::after {
  content:''; flex:1; height:1px; background:var(--border);
}

.share-tip {
  background:rgba(139,92,246,0.08); border:1px solid rgba(139,92,246,0.2);
  border-radius:10px; padding:12px 14px;
  font-size:0.8rem; color:var(--text2); line-height:1.6;
}
.share-tip strong { color:var(--text1); }

/* ─── FULL-SCREEN SETUP ───────────────────────────── */
.fullscreen-setup {
  position:fixed; inset:0; z-index:400;
  background:var(--bg);
  display:flex; align-items:flex-start; justify-content:center;
  padding:24px 16px; overflow-y:auto;
}
.setup-card {
  background:#0f1828;
  border:1px solid var(--border);
  border-radius:24px;
  width:100%; max-width:600px;
  padding:32px;
  box-shadow:var(--shadow);
  animation:modalIn 0.3s ease;
  margin:auto;
}
.setup-logo {
  display:flex; align-items:center; gap:12px;
  font-size:1.3rem; font-weight:800; color:var(--text1);
  margin-bottom:20px;
}
.setup-card h2  { font-size:1.2rem; font-weight:800; margin-bottom:8px; }
.setup-sub      { font-size:0.875rem; color:var(--text2); line-height:1.6; margin-bottom:24px; }
.setup-sub strong { color:var(--text1); }

.setup-steps-mini { display:flex; flex-direction:column; gap:14px; margin-bottom:24px; }
.ssm {
  display:flex; gap:12px; align-items:flex-start;
  font-size:0.875rem; color:var(--text2); line-height:1.6;
}
.ssm-num {
  width:26px; height:26px; border-radius:50%; flex-shrink:0;
  background:linear-gradient(135deg,var(--accent),var(--accent2));
  color:#fff; font-size:0.75rem; font-weight:700;
  display:flex; align-items:center; justify-content:center;
}
.ssm strong { color:var(--text1); }
.ssm a { color:var(--accent); font-weight:600; }
.ssm code { background:var(--bg2); padding:1px 6px; border-radius:4px; font-size:0.82rem; }

.setup-fields    { display:flex; flex-direction:column; gap:12px; margin-bottom:20px; }

.setup-share-alt {
  background:rgba(255,255,255,0.025); border:1px solid var(--border);
  border-radius:var(--radius-sm); padding:16px; margin-bottom:20px;
}
.ssa-label { font-size:0.78rem; font-weight:700; color:var(--text3); text-transform:uppercase; letter-spacing:0.5px; margin-bottom:6px; }
.ssa-desc  { font-size:0.82rem; color:var(--text2); line-height:1.6; margin-bottom:10px; }
.ssa-desc strong { color:var(--text1); }

.setup-connect-btn {
  width:100%; justify-content:center; padding:14px;
  font-size:1rem; border-radius:14px; margin-bottom:10px;
}
.setup-note { font-size:0.75rem; color:var(--text3); text-align:center; }

/* ─── CONFIG DISPLAY BOX ──────────────────────────── */
.config-display {
  background:var(--bg2); border:1px solid var(--border);
  border-radius:var(--radius-sm); padding:12px 14px;
  font-family:'Courier New',monospace; font-size:0.72rem;
  color:#7dd3fc; word-break:break-all; line-height:1.6;
  max-height:80px; overflow-y:auto; margin-bottom:12px;
}

/* ─── SYNC PILL ───────────────────────────────────── */
.sync-pill {
  display:flex; align-items:center; gap:6px;
  font-size:0.75rem; font-weight:600;
  border-radius:50px; padding:5px 12px;
  border:1px solid rgba(16,185,129,0.3);
  background:rgba(16,185,129,0.1); color:#34d399;
  transition:all 0.3s;
}
.sync-pill.syncing { background:rgba(245,158,11,0.1); border-color:rgba(245,158,11,0.3); color:#fbbf24; }
.sync-pill.error   { background:rgba(239,68,68,0.1);  border-color:rgba(239,68,68,0.3);  color:#f87171; }
.sync-dot {
  width:7px; height:7px; border-radius:50%;
  background:#10b981; box-shadow:0 0 6px #10b981; flex-shrink:0;
  animation:livePulse 2s ease-in-out infinite;
}
