/* ═══════════════════════════════════════════════════════════════
   CRUISER+ MOBILE APP — CSS
   Dark mode, purple/magenta/blue palette, mobile-first
   ═══════════════════════════════════════════════════════════════ */

:root {
  --bg-primary: #0a0a14;
  --bg-secondary: #10101e;
  --bg-card: #14142a;
  --bg-elevated: #1a1a35;
  --bg-input: #1e1e38;

  --purple: #7c3aed;
  --purple-light: #9d5ff5;
  --blue: #2563eb;
  --blue-light: #3b82f6;
  --magenta: #d946ef;
  --magenta-light: #e879f9;
  --pink: #ec4899;
  --gold: #f59e0b;
  --ruby: #ef4444;

  --gradient-main: linear-gradient(135deg, #7c3aed, #d946ef);
  --gradient-blue: linear-gradient(135deg, #2563eb, #7c3aed);
  --gradient-hot: linear-gradient(135deg, #d946ef, #ef4444);
  --gradient-gold: linear-gradient(135deg, #f59e0b, #ef4444);
  --gradient-card: linear-gradient(135deg, rgba(124,58,237,0.15), rgba(217,70,239,0.08));

  --text-primary: #f0f0ff;
  --text-secondary: #8888bb;
  --text-muted: #555580;

  --border: rgba(124,58,237,0.25);
  --border-light: rgba(255,255,255,0.08);

  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 22px;
  --radius-xl: 30px;
  --radius-full: 9999px;

  --shadow-glow: 0 0 20px rgba(124,58,237,0.4);
  --shadow-magenta: 0 0 20px rgba(217,70,239,0.35);
  --shadow-card: 0 4px 20px rgba(0,0,0,0.5);

  --nav-height: 70px;
  --header-height: 60px;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

/* ── Reset & Base ──────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; overflow: hidden; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  -webkit-font-smoothing: antialiased;
  overscroll-behavior: none;
  touch-action: manipulation;
}

#app {
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  position: relative;
}

/* ── Screen System ─────────────────────────────────────────────── */
.screen {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  background: var(--bg-primary);
  overflow: hidden;
  transform: translateX(100%);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.screen.active {
  transform: translateX(0);
}
.screen.slide-left {
  transform: translateX(-30%);
}

/* ── Splash Screen ─────────────────────────────────────────────── */
#screen-splash {
  justify-content: center;
  align-items: center;
  background: radial-gradient(ellipse at center, #1a0a2e 0%, #0a0a14 70%);
}
.splash-logo {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  animation: splashIn 0.8s ease-out;
}
.splash-icon {
  width: 100px;
  height: 100px;
  border-radius: 28px;
  background: var(--gradient-main);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 44px;
  box-shadow: 0 0 60px rgba(124,58,237,0.6), 0 0 120px rgba(217,70,239,0.3);
  animation: iconFloat 3s ease-in-out infinite;
}
.splash-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 42px;
  font-weight: 700;
  background: var(--gradient-main);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  letter-spacing: -1px;
}
.splash-subtitle {
  color: var(--text-secondary);
  font-size: 15px;
  letter-spacing: 2px;
  text-transform: uppercase;
}
.splash-loader {
  width: 48px;
  height: 4px;
  background: rgba(255,255,255,0.1);
  border-radius: 2px;
  overflow: hidden;
  margin-top: 20px;
}
.splash-loader-bar {
  height: 100%;
  background: var(--gradient-main);
  border-radius: 2px;
  animation: loaderBar 1.8s ease-in-out forwards;
}
@keyframes splashIn {
  from { opacity: 0; transform: scale(0.8) translateY(30px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}
@keyframes iconFloat {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
}
@keyframes loaderBar {
  from { width: 0; }
  to { width: 100%; }
}

/* ── Auth Screens ──────────────────────────────────────────────── */
#screen-login, #screen-register {
  justify-content: flex-end;
  background: radial-gradient(ellipse at top, #1a0a2e 0%, #0a0a14 60%);
  overflow-y: auto;
}
.auth-header {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 30px 20px;
  min-height: 200px;
}
.auth-logo {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 36px;
  font-weight: 700;
  background: var(--gradient-main);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 8px;
}
.auth-tagline {
  color: var(--text-secondary);
  font-size: 14px;
  text-align: center;
}
.auth-card {
  background: var(--bg-card);
  border-radius: 28px 28px 0 0;
  border-top: 1px solid var(--border);
  padding: 32px 24px calc(var(--safe-bottom) + 40px);
}
.auth-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 24px;
  font-weight: 600;
  margin-bottom: 6px;
}
.auth-subtitle {
  color: var(--text-secondary);
  font-size: 14px;
  margin-bottom: 28px;
}

/* ── Form Elements ─────────────────────────────────────────────── */
.form-group { margin-bottom: 16px; }
.form-label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  margin-bottom: 8px;
}
.form-input {
  width: 100%;
  background: var(--bg-input);
  border: 1.5px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  color: var(--text-primary);
  font-size: 16px;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  -webkit-appearance: none;
}
.form-input:focus {
  border-color: var(--purple-light);
  box-shadow: 0 0 0 3px rgba(124,58,237,0.2);
}
.form-input::placeholder { color: var(--text-muted); }
.input-icon-wrap { position: relative; }
.input-icon-wrap .form-input { padding-left: 44px; }
.input-icon-wrap .input-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 16px;
}
.input-eye {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  cursor: pointer;
  font-size: 16px;
}

/* ── Buttons ───────────────────────────────────────────────────── */
.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 16px 24px;
  border: none;
  border-radius: var(--radius-full);
  font-size: 16px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.2s;
  -webkit-tap-highlight-color: transparent;
  outline: none;
}
.btn:active { transform: scale(0.97); }
.btn-primary {
  background: var(--gradient-main);
  color: white;
  box-shadow: 0 4px 20px rgba(124,58,237,0.4);
}
.btn-primary:hover { box-shadow: 0 4px 30px rgba(124,58,237,0.6); }
.btn-secondary {
  background: var(--bg-elevated);
  color: var(--text-primary);
  border: 1px solid var(--border);
}
.btn-ghost {
  background: transparent;
  color: var(--purple-light);
  font-size: 14px;
}
.btn-sm {
  padding: 10px 18px;
  font-size: 14px;
  width: auto;
}

/* ── Main App Layout ───────────────────────────────────────────── */
#screen-main {
  display: flex;
  flex-direction: column;
}
.app-header {
  flex-shrink: 0;
  height: var(--header-height);
  padding-top: var(--safe-top);
  background: rgba(10,10,20,0.95);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-left: 20px;
  padding-right: 20px;
  z-index: 100;
}
.header-logo {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 22px;
  font-weight: 700;
  background: var(--gradient-main);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.header-actions { display: flex; align-items: center; gap: 12px; }
.header-btn {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-full);
  background: var(--bg-elevated);
  border: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  font-size: 16px;
  cursor: pointer;
  position: relative;
}
.header-badge {
  position: absolute;
  top: -3px;
  right: -3px;
  width: 16px;
  height: 16px;
  border-radius: var(--radius-full);
  background: var(--magenta);
  font-size: 9px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--bg-primary);
}
.content-area {
  flex: 1;
  overflow: hidden;
  position: relative;
}
.tab-content {
  position: absolute;
  inset: 0;
  overflow-y: auto;
  display: none;
  padding-bottom: calc(var(--nav-height) + 20px);
  -webkit-overflow-scrolling: touch;
}
.tab-content.active { display: block; }

/* ── Bottom Nav ────────────────────────────────────────────────── */
.bottom-nav {
  flex-shrink: 0;
  height: calc(var(--nav-height) + var(--safe-bottom));
  padding-bottom: var(--safe-bottom);
  background: rgba(10,10,20,0.97);
  backdrop-filter: blur(20px);
  border-top: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding-left: 4px;
  padding-right: 4px;
  z-index: 100;
}
.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 8px 14px;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.2s;
  -webkit-tap-highlight-color: transparent;
  position: relative;
}
.nav-item i {
  font-size: 20px;
  color: var(--text-muted);
  transition: all 0.2s;
}
.nav-item span {
  font-size: 10px;
  font-weight: 500;
  color: var(--text-muted);
  transition: all 0.2s;
}
.nav-item.active i { color: var(--purple-light); }
.nav-item.active span { color: var(--purple-light); }
.nav-item.active::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 30px;
  height: 3px;
  background: var(--gradient-main);
  border-radius: 0 0 3px 3px;
}
.nav-checkin {
  width: 60px;
  height: 60px;
  border-radius: var(--radius-full);
  background: var(--gradient-main);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  color: white;
  box-shadow: 0 0 25px rgba(124,58,237,0.5);
  cursor: pointer;
  transition: all 0.2s;
  -webkit-tap-highlight-color: transparent;
}
.nav-checkin:active { transform: scale(0.92); }
.nav-checkin.pulsing {
  animation: navCheckinPulse 2s ease-in-out infinite;
}
@keyframes navCheckinPulse {
  0%, 100% { box-shadow: 0 0 25px rgba(124,58,237,0.5); }
  50% { box-shadow: 0 0 40px rgba(217,70,239,0.7), 0 0 60px rgba(124,58,237,0.3); }
}
.nav-badge {
  position: absolute;
  top: 4px;
  right: 8px;
  width: 16px;
  height: 16px;
  border-radius: var(--radius-full);
  background: var(--magenta);
  font-size: 9px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--bg-primary);
}

/* ── Nearby Tab ────────────────────────────────────────────────── */
.nearby-header {
  padding: 16px 20px 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nearby-count {
  font-size: 13px;
  color: var(--text-secondary);
}
.nearby-count span {
  color: var(--purple-light);
  font-weight: 600;
}
.filter-chips {
  display: flex;
  gap: 8px;
  padding: 0 20px 12px;
  overflow-x: auto;
  scrollbar-width: none;
}
.filter-chips::-webkit-scrollbar { display: none; }
.chip {
  flex-shrink: 0;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 600;
  border: 1.5px solid var(--border);
  color: var(--text-secondary);
  background: transparent;
  cursor: pointer;
  transition: all 0.2s;
  -webkit-tap-highlight-color: transparent;
}
.chip.active {
  background: rgba(124,58,237,0.2);
  border-color: var(--purple-light);
  color: var(--purple-light);
}
.view-toggle {
  display: flex;
  margin: 0 20px 12px;
  background: var(--bg-elevated);
  border-radius: var(--radius-sm);
  padding: 3px;
}
.view-btn {
  flex: 1;
  padding: 7px;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
  -webkit-tap-highlight-color: transparent;
}
.view-btn.active {
  background: var(--gradient-main);
  color: white;
}

/* ── User Cards ────────────────────────────────────────────────── */
.user-list { padding: 0 12px; display: flex; flex-direction: column; gap: 10px; }
.user-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
  padding: 16px;
  display: flex;
  gap: 14px;
  align-items: center;
  cursor: pointer;
  transition: all 0.2s;
  -webkit-tap-highlight-color: transparent;
  animation: cardSlideIn 0.4s ease-out;
}
.user-card:active { transform: scale(0.98); background: var(--bg-elevated); }
@keyframes cardSlideIn {
  from { opacity: 0; transform: translateX(-20px); }
  to { opacity: 1; transform: translateX(0); }
}
.user-avatar {
  width: 62px;
  height: 62px;
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 18px;
  color: white;
  flex-shrink: 0;
  position: relative;
}
.avatar-av { background: linear-gradient(135deg, #7c3aed, #d946ef); }
.avatar-lf { background: linear-gradient(135deg, #ec4899, #f43f5e); }
.avatar-ln { background: linear-gradient(135deg, #2563eb, #7c3aed); }
.avatar-ip { background: linear-gradient(135deg, #d97706, #dc2626); }
.avatar-gs { background: linear-gradient(135deg, #0891b2, #2563eb); }
.avatar-ml { background: linear-gradient(135deg, #4d7c0f, #0891b2); }
.avatar-pa { background: linear-gradient(135deg, #be185d, #7c3aed); }
.avatar-ds { background: linear-gradient(135deg, #0f766e, #0891b2); }
.avatar-tc { background: linear-gradient(135deg, #92400e, #d97706); }
.avatar-cr { background: linear-gradient(135deg, #1d4ed8, #0891b2); }
.avatar-me { background: linear-gradient(135deg, #5b21b6, #7c3aed); }
.online-dot {
  position: absolute;
  bottom: 3px;
  right: 3px;
  width: 13px;
  height: 13px;
  border-radius: var(--radius-full);
  background: #22c55e;
  border: 2px solid var(--bg-card);
}
.offline-dot {
  position: absolute;
  bottom: 3px;
  right: 3px;
  width: 13px;
  height: 13px;
  border-radius: var(--radius-full);
  background: var(--text-muted);
  border: 2px solid var(--bg-card);
}
.user-info { flex: 1; min-width: 0; }
.user-name-row {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 3px;
}
.user-name {
  font-weight: 600;
  font-size: 15px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.verified-icon { color: var(--blue-light); font-size: 12px; }
.user-meta {
  font-size: 12px;
  color: var(--text-secondary);
  margin-bottom: 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.user-tags { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.plan-badge {
  padding: 3px 8px;
  border-radius: var(--radius-full);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.badge-ilimitado { background: rgba(124,58,237,0.25); color: var(--purple-light); }
.badge-cruiser { background: rgba(37,99,235,0.25); color: var(--blue-light); }
.badge-voyeur { background: rgba(100,100,140,0.25); color: var(--text-secondary); }
.distance-badge {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  color: var(--text-muted);
}
.distance-badge i { font-size: 10px; color: var(--magenta); }
.user-card-action {
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex-shrink: 0;
}
.action-msg-btn {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-full);
  background: rgba(124,58,237,0.2);
  border: 1px solid rgba(124,58,237,0.4);
  color: var(--purple-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.2s;
  -webkit-tap-highlight-color: transparent;
}
.action-msg-btn:active { background: rgba(124,58,237,0.4); }

/* ── Map View ──────────────────────────────────────────────────── */
.map-container {
  margin: 0 12px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  position: relative;
  height: 260px;
  background: var(--bg-card);
}
.map-placeholder {
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #0d0d1a, #141430);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 12px;
  position: relative;
  overflow: hidden;
}
.map-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(124,58,237,0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124,58,237,0.08) 1px, transparent 1px);
  background-size: 40px 40px;
}
.map-dot {
  position: absolute;
  width: 10px;
  height: 10px;
  border-radius: var(--radius-full);
  background: var(--magenta);
  box-shadow: 0 0 12px rgba(217,70,239,0.8);
  animation: mapPulse 2s ease-in-out infinite;
}
.map-dot::after {
  content: '';
  position: absolute;
  inset: -6px;
  border-radius: var(--radius-full);
  border: 2px solid rgba(217,70,239,0.4);
  animation: mapRipple 2s ease-out infinite;
}
@keyframes mapPulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.2); opacity: 0.8; }
}
@keyframes mapRipple {
  0% { transform: scale(1); opacity: 0.6; }
  100% { transform: scale(2.5); opacity: 0; }
}
.map-me-dot {
  position: absolute;
  width: 16px;
  height: 16px;
  border-radius: var(--radius-full);
  background: var(--purple-light);
  border: 3px solid white;
  box-shadow: 0 0 20px rgba(124,58,237,0.8);
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}
.map-label {
  position: absolute;
  bottom: 12px;
  left: 12px;
  background: rgba(0,0,0,0.7);
  padding: 4px 10px;
  border-radius: var(--radius-full);
  font-size: 11px;
  color: var(--text-secondary);
  backdrop-filter: blur(8px);
}

/* ── Check-in Screen ───────────────────────────────────────────── */
.checkin-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.85);
  backdrop-filter: blur(10px);
  z-index: 500;
  display: flex;
  align-items: flex-end;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}
.checkin-overlay.open {
  opacity: 1;
  pointer-events: all;
}
.checkin-sheet {
  width: 100%;
  background: var(--bg-card);
  border-radius: 28px 28px 0 0;
  border-top: 1px solid var(--border);
  padding: 32px 24px calc(var(--safe-bottom) + 40px);
  transform: translateY(100%);
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}
.checkin-overlay.open .checkin-sheet { transform: translateY(0); }
.sheet-handle {
  width: 40px;
  height: 4px;
  border-radius: 2px;
  background: var(--text-muted);
  margin: 0 auto 24px;
}
.checkin-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 24px;
  font-weight: 600;
  text-align: center;
  margin-bottom: 6px;
}
.checkin-subtitle {
  text-align: center;
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 28px;
}
.checkin-btn-wrap {
  display: flex;
  justify-content: center;
  margin-bottom: 24px;
}
.checkin-big-btn {
  width: 130px;
  height: 130px;
  border-radius: var(--radius-full);
  background: var(--gradient-main);
  border: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 600;
  color: white;
  cursor: pointer;
  position: relative;
  box-shadow: 0 0 40px rgba(124,58,237,0.5);
  transition: all 0.2s;
  -webkit-tap-highlight-color: transparent;
}
.checkin-big-btn i { font-size: 36px; }
.checkin-big-btn:active { transform: scale(0.95); }
.checkin-big-btn.checking {
  animation: checkinPulse 0.8s ease-in-out infinite;
}
.checkin-ripple {
  position: absolute;
  inset: -20px;
  border-radius: var(--radius-full);
  border: 2px solid rgba(217,70,239,0.5);
  animation: checkinRipple 1.5s ease-out infinite;
  pointer-events: none;
}
.checkin-ripple:nth-child(2) {
  inset: -40px;
  animation-delay: 0.5s;
}
.checkin-ripple:nth-child(3) {
  inset: -60px;
  animation-delay: 1s;
}
@keyframes checkinPulse {
  0%, 100% { box-shadow: 0 0 40px rgba(124,58,237,0.5); }
  50% { box-shadow: 0 0 70px rgba(217,70,239,0.8); }
}
@keyframes checkinRipple {
  0% { transform: scale(0.9); opacity: 0.8; }
  100% { transform: scale(1.4); opacity: 0; }
}
.checkin-info {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-secondary);
  justify-content: center;
  margin-bottom: 20px;
}
.checkin-info i { color: var(--purple-light); }
.checkin-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.checkin-stat {
  background: var(--bg-elevated);
  border-radius: var(--radius-md);
  padding: 14px;
  text-align: center;
}
.checkin-stat-val {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 24px;
  font-weight: 700;
  background: var(--gradient-main);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.checkin-stat-lbl {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 3px;
}

/* ── Messages Tab ──────────────────────────────────────────────── */
.section-header {
  padding: 16px 20px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.section-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 20px;
  font-weight: 600;
}
.conv-list { padding: 0 12px; display: flex; flex-direction: column; gap: 2px; }
.conv-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px;
  border-radius: var(--radius-lg);
  cursor: pointer;
  transition: all 0.2s;
  -webkit-tap-highlight-color: transparent;
}
.conv-item:active { background: var(--bg-elevated); }
.conv-avatar-wrap { position: relative; flex-shrink: 0; }
.conv-avatar {
  width: 54px;
  height: 54px;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 17px;
  color: white;
}
.conv-info { flex: 1; min-width: 0; }
.conv-name-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4px;
}
.conv-name { font-weight: 600; font-size: 15px; }
.conv-time { font-size: 11px; color: var(--text-muted); }
.conv-last-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.conv-last { font-size: 13px; color: var(--text-secondary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 200px; }
.conv-unread {
  min-width: 20px;
  height: 20px;
  border-radius: var(--radius-full);
  background: var(--magenta);
  font-size: 11px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 6px;
  flex-shrink: 0;
}

/* ── Chat Screen ───────────────────────────────────────────────── */
#screen-chat {
  display: flex;
  flex-direction: column;
  background: var(--bg-primary);
}
.chat-header {
  flex-shrink: 0;
  height: calc(var(--header-height) + var(--safe-top));
  padding-top: var(--safe-top);
  background: rgba(10,10,20,0.97);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  gap: 12px;
  padding-left: 16px;
  padding-right: 16px;
}
.chat-back {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--purple-light);
  font-size: 18px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.chat-user-info { flex: 1; }
.chat-user-name { font-weight: 600; font-size: 15px; }
.chat-user-status { font-size: 12px; color: var(--text-secondary); }
.chat-user-status.online { color: #22c55e; }
.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px 16px 8px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  -webkit-overflow-scrolling: touch;
}
.msg-bubble {
  max-width: 75%;
  padding: 10px 14px;
  border-radius: 18px;
  font-size: 14px;
  line-height: 1.5;
  animation: msgIn 0.25s ease-out;
  position: relative;
}
@keyframes msgIn {
  from { opacity: 0; transform: translateY(8px) scale(0.95); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.msg-bubble.mine {
  background: var(--gradient-main);
  color: white;
  align-self: flex-end;
  border-bottom-right-radius: 4px;
}
.msg-bubble.theirs {
  background: var(--bg-card);
  color: var(--text-primary);
  align-self: flex-start;
  border-bottom-left-radius: 4px;
  border: 1px solid var(--border-light);
}
.msg-bubble.photo {
  background: var(--bg-elevated);
  padding: 8px;
}
.msg-photo-placeholder {
  width: 160px;
  height: 110px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(124,58,237,0.3), rgba(217,70,239,0.2));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
}
.msg-time {
  font-size: 10px;
  opacity: 0.6;
  margin-top: 3px;
  text-align: right;
}
.chat-input-area {
  flex-shrink: 0;
  padding: 12px 16px calc(var(--safe-bottom) + 12px);
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-light);
  display: flex;
  align-items: flex-end;
  gap: 10px;
}
.chat-input {
  flex: 1;
  background: var(--bg-input);
  border: 1.5px solid var(--border-light);
  border-radius: 22px;
  padding: 12px 16px;
  color: var(--text-primary);
  font-size: 15px;
  font-family: inherit;
  outline: none;
  resize: none;
  min-height: 46px;
  max-height: 120px;
  -webkit-appearance: none;
  transition: border-color 0.2s;
}
.chat-input:focus { border-color: var(--purple-light); }
.chat-send-btn {
  width: 46px;
  height: 46px;
  border-radius: var(--radius-full);
  background: var(--gradient-main);
  border: none;
  color: white;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  -webkit-tap-highlight-color: transparent;
  transition: all 0.2s;
}
.chat-send-btn:active { transform: scale(0.92); }
.chat-photo-btn {
  width: 46px;
  height: 46px;
  border-radius: var(--radius-full);
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  -webkit-tap-highlight-color: transparent;
}
.photo-locked {
  position: relative;
}
.photo-locked-overlay {
  position: absolute;
  inset: 0;
  border-radius: var(--radius-full);
  background: rgba(0,0,0,0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  color: var(--gold);
}

/* ── Heatmap Tab ───────────────────────────────────────────────── */
.heatmap-container {
  margin: 0 12px 16px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  height: 280px;
  position: relative;
  background: #0d0d1a;
}
.heatmap-svg-wrap {
  width: 100%;
  height: 100%;
  position: relative;
}
.heatmap-title {
  padding: 16px 20px 4px;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 18px;
  font-weight: 600;
}
.heatmap-legend {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 20px 12px;
  font-size: 11px;
  color: var(--text-muted);
}
.legend-bar {
  flex: 1;
  height: 6px;
  border-radius: 3px;
  background: linear-gradient(90deg, #7c3aed, #d946ef, #ef4444);
}
.hotspots-list {
  padding: 0 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.hotspot-item {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 14px;
  border: 1px solid var(--border-light);
}
.hotspot-rank {
  width: 28px;
  height: 28px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 12px;
  flex-shrink: 0;
}
.rank-1 { background: rgba(239,68,68,0.2); color: #ef4444; }
.rank-2 { background: rgba(217,70,239,0.2); color: var(--magenta); }
.rank-3 { background: rgba(124,58,237,0.2); color: var(--purple-light); }
.rank-other { background: var(--bg-elevated); color: var(--text-muted); }
.hotspot-info { flex: 1; }
.hotspot-name { font-weight: 600; font-size: 14px; }
.hotspot-city { font-size: 12px; color: var(--text-secondary); }
.hotspot-density {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.density-bar-wrap {
  width: 60px;
  height: 4px;
  background: rgba(255,255,255,0.1);
  border-radius: 2px;
}
.density-bar {
  height: 100%;
  border-radius: 2px;
  background: var(--gradient-main);
}
.density-num {
  font-size: 13px;
  font-weight: 600;
  color: var(--magenta-light);
  min-width: 24px;
  text-align: right;
}

/* ── Profile Tab ───────────────────────────────────────────────── */
.profile-hero {
  background: linear-gradient(180deg, rgba(124,58,237,0.15) 0%, transparent 100%);
  padding: 24px 20px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}
.profile-avatar-wrap { position: relative; }
.profile-avatar {
  width: 90px;
  height: 90px;
  border-radius: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 26px;
  color: white;
  border: 3px solid rgba(124,58,237,0.5);
}
.profile-edit-btn {
  position: absolute;
  bottom: -4px;
  right: -4px;
  width: 28px;
  height: 28px;
  border-radius: var(--radius-full);
  background: var(--gradient-main);
  border: 2px solid var(--bg-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  cursor: pointer;
}
.profile-name {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 22px;
  font-weight: 600;
}
.profile-username { color: var(--text-secondary); font-size: 14px; }
.profile-plan-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 14px;
  border-radius: var(--radius-full);
  font-size: 12px;
  font-weight: 700;
  background: rgba(124,58,237,0.2);
  border: 1px solid rgba(124,58,237,0.4);
  color: var(--purple-light);
}
.profile-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  margin: 0 12px;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
  overflow: hidden;
  margin-bottom: 16px;
}
.profile-stat {
  padding: 14px 8px;
  text-align: center;
  border-right: 1px solid var(--border-light);
}
.profile-stat:last-child { border-right: none; }
.stat-val {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 20px;
  font-weight: 700;
  background: var(--gradient-main);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.stat-lbl { font-size: 11px; color: var(--text-muted); margin-top: 2px; }
.menu-list {
  padding: 0 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.menu-section-title {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 8px 4px 4px;
}
.menu-item {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  display: flex;
  align-items: center;
  gap: 14px;
  cursor: pointer;
  border: 1px solid var(--border-light);
  transition: all 0.2s;
  -webkit-tap-highlight-color: transparent;
}
.menu-item:active { background: var(--bg-elevated); }
.menu-icon {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}
.icon-purple { background: rgba(124,58,237,0.2); color: var(--purple-light); }
.icon-blue { background: rgba(37,99,235,0.2); color: var(--blue-light); }
.icon-magenta { background: rgba(217,70,239,0.2); color: var(--magenta-light); }
.icon-gold { background: rgba(245,158,11,0.2); color: var(--gold); }
.icon-ruby { background: rgba(239,68,68,0.2); color: var(--ruby); }
.menu-item-text { flex: 1; }
.menu-item-title { font-size: 14px; font-weight: 500; }
.menu-item-sub { font-size: 12px; color: var(--text-muted); margin-top: 1px; }
.menu-item-right {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--text-muted);
  font-size: 14px;
}

/* ── Subscription Screen ───────────────────────────────────────── */
#screen-subscription {
  overflow-y: auto;
}
.sub-hero {
  background: radial-gradient(ellipse at top, rgba(124,58,237,0.2) 0%, transparent 70%);
  padding: 40px 20px 24px;
  text-align: center;
}
.sub-hero-icon { font-size: 48px; margin-bottom: 12px; }
.sub-hero-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 28px;
  font-weight: 700;
  background: var(--gradient-main);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 8px;
}
.sub-hero-sub { color: var(--text-secondary); font-size: 14px; }
.plan-cards { padding: 0 12px 20px; display: flex; flex-direction: column; gap: 14px; }
.plan-card {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  border: 1.5px solid var(--border-light);
  padding: 22px 20px;
  position: relative;
  overflow: hidden;
  transition: all 0.2s;
}
.plan-card.featured {
  border-color: var(--purple);
  background: linear-gradient(135deg, rgba(124,58,237,0.15) 0%, rgba(217,70,239,0.08) 100%);
}
.plan-featured-badge {
  position: absolute;
  top: 16px;
  right: 16px;
  background: var(--gradient-main);
  padding: 4px 12px;
  border-radius: var(--radius-full);
  font-size: 11px;
  font-weight: 700;
  color: white;
}
.plan-name {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 4px;
}
.plan-price {
  display: flex;
  align-items: baseline;
  gap: 4px;
  margin-bottom: 16px;
}
.price-value {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 36px;
  font-weight: 700;
}
.plan-free .price-value { color: var(--text-secondary); }
.plan-mid .price-value, .plan-card.featured .price-value { background: var(--gradient-main); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.price-currency { font-size: 16px; font-weight: 600; color: var(--text-secondary); align-self: flex-start; margin-top: 6px; }
.price-period { font-size: 13px; color: var(--text-muted); }
.plan-features { list-style: none; display: flex; flex-direction: column; gap: 9px; margin-bottom: 20px; }
.plan-feature {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
}
.feature-check { color: #22c55e; font-size: 13px; }
.feature-x { color: var(--text-muted); font-size: 13px; }
.plan-feature.locked { color: var(--text-muted); }
.plan-btn {
  width: 100%;
  padding: 14px;
  border-radius: var(--radius-full);
  border: none;
  font-size: 15px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.2s;
  -webkit-tap-highlight-color: transparent;
}
.plan-btn.current {
  background: var(--bg-elevated);
  color: var(--text-secondary);
  border: 1px solid var(--border);
}
.plan-btn.upgrade {
  background: var(--gradient-main);
  color: white;
  box-shadow: 0 4px 20px rgba(124,58,237,0.4);
}
.plan-btn.upgrade-gold {
  background: var(--gradient-gold);
  color: white;
  box-shadow: 0 4px 20px rgba(245,158,11,0.3);
}

/* ── Profile Detail Screen ─────────────────────────────────────── */
#screen-user-profile {
  overflow-y: auto;
}
.user-profile-hero {
  padding: 20px 20px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  position: relative;
}
.user-profile-back {
  position: absolute;
  top: 20px;
  left: 20px;
  width: 38px;
  height: 38px;
  border-radius: var(--radius-full);
  background: rgba(0,0,0,0.4);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 16px;
  cursor: pointer;
  z-index: 10;
}
.user-profile-actions {
  position: absolute;
  top: 20px;
  right: 20px;
  display: flex;
  gap: 8px;
}
.user-profile-action {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-full);
  background: rgba(0,0,0,0.4);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  cursor: pointer;
}
.user-profile-avatar {
  width: 100px;
  height: 100px;
  border-radius: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 28px;
  color: white;
  border: 3px solid rgba(124,58,237,0.5);
  margin-top: 30px;
}
.user-profile-name-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-direction: column;
}
.user-profile-name {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 24px;
  font-weight: 600;
}
.user-profile-meta {
  color: var(--text-secondary);
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.user-profile-meta span { display: flex; align-items: center; gap: 4px; }
.user-profile-bio {
  text-align: center;
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.6;
  padding: 0 30px;
}
.user-profile-cta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  padding: 16px 20px;
}
.user-profile-info {
  padding: 0 20px 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.info-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  border: 1px solid var(--border-light);
}
.info-chip i { color: var(--purple-light); font-size: 14px; width: 18px; text-align: center; }
.info-chip-label { font-size: 12px; color: var(--text-muted); }
.info-chip-val { font-size: 14px; font-weight: 500; }
.photo-album {
  padding: 0 20px 30px;
}
.album-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.album-lock { color: var(--gold); font-size: 14px; }
.album-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
}
.album-photo {
  aspect-ratio: 1;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  background: var(--bg-elevated);
  border: 1px solid var(--border-light);
}
.album-photo.locked {
  background: rgba(245,158,11,0.1);
  border-color: rgba(245,158,11,0.2);
}

/* ── Toast Notifications ───────────────────────────────────────── */
.toast {
  position: fixed;
  top: calc(var(--header-height) + var(--safe-top) + 12px);
  left: 50%;
  transform: translateX(-50%) translateY(-80px);
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  padding: 12px 20px;
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
  z-index: 999;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: var(--shadow-card);
}
.toast.show { transform: translateX(-50%) translateY(0); }
.toast.success { border-color: rgba(34,197,94,0.4); }
.toast.success i { color: #22c55e; }
.toast.error { border-color: rgba(239,68,68,0.4); }
.toast.error i { color: var(--ruby); }
.toast.info { border-color: var(--border); }
.toast.info i { color: var(--purple-light); }

/* ── Utilities ─────────────────────────────────────────────────── */
.divider {
  height: 1px;
  background: var(--border-light);
  margin: 8px 20px;
}
.mt-4 { margin-top: 16px; }
.mb-2 { margin-bottom: 8px; }
.px-20 { padding: 0 20px; }
.text-muted { color: var(--text-muted); }
.text-secondary { color: var(--text-secondary); }
.text-gradient {
  background: var(--gradient-main);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.hidden { display: none !important; }
.lock-banner {
  margin: 0 12px;
  background: rgba(245,158,11,0.1);
  border: 1px solid rgba(245,158,11,0.3);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  cursor: pointer;
}
.lock-banner i { color: var(--gold); font-size: 16px; }
.lock-banner-text { flex: 1; color: var(--text-secondary); }
.lock-banner strong { color: var(--gold); }
.lock-banner-arrow { color: var(--gold); }

/* Scrollbar */
::-webkit-scrollbar { width: 0; display: none; }

/* ── Responsive — telas maiores ────────────────────────────────── */
@media (min-width: 430px) {
  #app {
    max-width: 430px;
    margin: 0 auto;
    box-shadow: 0 0 80px rgba(0,0,0,0.8);
  }
}
