/* ================================================
   GCA 2026 — Galeria Cidade Aberta
   Design System & Styles
   ================================================ */

/* ===== CSS VARIABLES ===== */
:root {
  --bg: #080c18;
  --bg2: #0d1225;
  --bg3: #111827;
  --card: rgba(255, 255, 255, 0.04);
  --card-border: rgba(255, 255, 255, 0.07);
  --card-hover: rgba(255, 255, 255, 0.07);

  --cyan: #00c9ff;
  --cyan2: #0070f3;
  --green: #22c55e;
  --green2: #15803d;
  --amber: #f59e0b;
  --red: #ef4444;
  --gray: #6b7280;

  --text: #f0f4ff;
  --text2: #8892a4;
  --text3: #4a5568;

  --grad-primary: linear-gradient(135deg, #00c9ff 0%, #0070f3 100%);
  --grad-green: linear-gradient(135deg, #22c55e 0%, #15803d 100%);
  --grad-bg: linear-gradient(160deg, #0d1225 0%, #080c18 100%);

  --nav-h: 68px;
  --header-h: 150px;
  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 20px;
  --radius-full: 999px;

  --shadow: 0 4px 24px rgba(0,0,0,0.4);
  --shadow-glow: 0 0 24px rgba(0, 201, 255, 0.25);
  --shadow-green: 0 0 24px rgba(34, 197, 94, 0.25);

  --transition: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ===== RESET ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }
html { height: 100%; }
body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  height: 100%;
  overflow: hidden;
  position: fixed;
  width: 100%;
  -webkit-font-smoothing: antialiased;
}
button { cursor: pointer; font-family: inherit; border: none; background: none; }
input, select { font-family: inherit; font-size: 16px; }

/* ===== UTILITIES ===== */
.hidden { display: none !important; }

/* ===== SPLASH ===== */
.splash {
  position: fixed; inset: 0;
  background: var(--bg);
  display: flex; align-items: center; justify-content: center;
  z-index: 9999;
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.splash.fade-out { opacity: 0; transform: scale(1.04); pointer-events: none; }
.splash-logo { text-align: center; animation: splashIn 0.7s ease both; }

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

.splash-anim {
  position: relative;
  width: 96px; height: 96px;
  margin: 0 auto 20px;
  display: flex; align-items: center; justify-content: center;
}
.splash-ring {
  position: absolute; inset: 0;
  border-radius: 50%;
  border: 2px solid rgba(0,201,255,0.3);
  animation: ringPop 2s ease infinite;
}
.ring2 {
  border-color: rgba(0,112,243,0.3);
  animation-delay: 0.5s;
  inset: 8px;
}
@keyframes ringPop {
  0%, 100% { transform: scale(1); opacity: 0.5; }
  50% { transform: scale(1.1); opacity: 1; }
}
.splash-icon { font-size: 52px; line-height: 1; }
.splash-logo h1 {
  font-size: 34px; font-weight: 900; letter-spacing: -1px;
  background: var(--grad-primary);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
}
.splash-logo p {
  font-size: 13px; font-weight: 500; color: var(--text2);
  letter-spacing: 2px; text-transform: uppercase; margin-top: 6px;
}
.splash-city {
  display: inline-block;
  margin-top: 10px;
  font-size: 11px; font-weight: 600; color: var(--text3);
  letter-spacing: 1.5px; text-transform: uppercase;
  background: rgba(255,255,255,0.04);
  padding: 4px 12px; border-radius: var(--radius-full);
  border: 1px solid rgba(255,255,255,0.07);
}

/* ===== APP LAYOUT ===== */
.app {
  display: flex; flex-direction: column;
  height: 100%; width: 100%;
  max-width: 480px; margin: 0 auto;
  background: var(--bg);
  position: relative;
}

/* ===== HEADER ===== */
.header {
  flex-shrink: 0;
  padding: env(safe-area-inset-top, 44px) 16px 14px;
  background: var(--grad-bg);
  border-bottom: 1px solid var(--card-border);
  position: relative;
  overflow: hidden;
  z-index: 10;
}
.header::after {
  content: '';
  position: absolute;
  top: -60px; right: -60px;
  width: 200px; height: 200px;
  background: radial-gradient(circle, rgba(0,201,255,0.08) 0%, transparent 70%);
  pointer-events: none;
}
.header-top {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 10px;
}
.header-title {
  font-size: 20px; font-weight: 800; letter-spacing: -0.5px; color: var(--text);
}
.btn-icon {
  width: 38px; height: 38px; border-radius: var(--radius-full);
  background: var(--card); border: 1px solid var(--card-border);
  color: var(--text2);
  display: flex; align-items: center; justify-content: center;
  transition: all var(--transition);
  flex-shrink: 0;
}
.btn-icon:hover, .btn-icon:active {
  background: rgba(0,201,255,0.12);
  border-color: rgba(0,201,255,0.4);
  color: var(--cyan);
  transform: rotate(180deg);
}

/* === SYNC STATUS === */
.sync-status {
  color: var(--text3);
  transition: all 0.3s ease;
  display: flex; align-items: center; justify-content: center;
}
.sync-status.online {
  color: #10b981; /* Verde esmeralda */
  filter: drop-shadow(0 0 4px rgba(16,185,129,0.3));
}
.sync-status.offline {
  color: #ef4444; /* Vermelho */
  opacity: 0.6;
}
.sync-status.syncing {
  color: var(--cyan);
  animation: sync-pulse 1.5s infinite;
}
@keyframes sync-pulse {
  0% { opacity: 1; }
  50% { opacity: 0.4; }
  100% { opacity: 1; }
}

/* ===== DATE NAV ===== */
.date-nav {
  display: flex; align-items: center; gap: 6px;
  margin-bottom: 12px;
}
.date-arrow {
  flex-shrink: 0;
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--card); border: 1px solid var(--card-border);
  color: var(--text2);
  display: flex; align-items: center; justify-content: center;
  transition: all var(--transition);
}
.date-arrow:active {
  background: rgba(0,201,255,0.12);
  color: var(--cyan);
  transform: scale(0.92);
}
.date-center {
  flex: 1;
  display: flex; align-items: center; gap: 8px;
  background: var(--card); border: 1px solid var(--card-border);
  border-radius: var(--radius-full);
  padding: 6px 14px;
  cursor: pointer;
  transition: border-color var(--transition);
  min-width: 0;
}
.date-center:active { border-color: rgba(0,201,255,0.3); }
.date-badge {
  font-size: 10px; font-weight: 800; letter-spacing: 1.5px;
  text-transform: uppercase; color: var(--cyan);
  white-space: nowrap; flex-shrink: 0;
}
.date-badge.past { color: var(--amber); }
.date-full {
  font-size: 12px; font-weight: 500; color: var(--text2);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}


/* Progress Card */
.progress-card {
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  padding: 12px 14px;
}
.progress-label {
  display: flex; justify-content: space-between; align-items: center;
  font-size: 10px; font-weight: 700; letter-spacing: 1.5px;
  text-transform: uppercase; color: var(--text2);
  margin-bottom: 8px;
}
.progress-percent {
  font-size: 16px; font-weight: 800; color: var(--cyan) !important;
  letter-spacing: 0;
}
.progress-bar-wrap { margin-bottom: 8px; }
.progress-bar {
  height: 5px;
  background: rgba(255,255,255,0.06);
  border-radius: var(--radius-full);
  overflow: hidden;
}
.progress-fill {
  height: 100%;
  background: var(--grad-primary);
  border-radius: var(--radius-full);
  transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
}
.progress-fill::after {
  content: '';
  position: absolute; top: 0; right: 0; bottom: 0; width: 40px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4));
  animation: shimmer 2s ease infinite;
}
@keyframes shimmer { 0%, 100% { opacity: 0; } 50% { opacity: 1; } }
.progress-fill.all-done { background: var(--grad-green); }

.progress-sub {
  display: flex; justify-content: space-between; align-items: center;
  font-size: 11px; color: var(--text2);
}
.progress-sub strong { color: var(--text); }
.remaining { color: var(--amber); font-weight: 600; font-size: 11px; }

/* ===== MAIN CONTENT ===== */
.main-content { flex: 1; overflow: hidden; position: relative; }

.view {
  display: none; flex-direction: column;
  height: 100%; overflow: hidden;
}
.view.active { display: flex; }

/* ===== LISTA VIEW ===== */
.sort-bar {
  display: flex; gap: 8px;
  padding: 12px 16px 8px;
  flex-shrink: 0;
}
.sort-btn {
  flex: 1;
  display: flex; align-items: center; justify-content: center; gap: 6px;
  padding: 9px 12px;
  border-radius: var(--radius-full);
  font-size: 12px; font-weight: 600;
  color: var(--text2);
  background: var(--card);
  border: 1px solid var(--card-border);
  transition: all var(--transition);
}
.sort-btn.active {
  background: var(--grad-primary);
  border-color: transparent;
  color: #fff;
  box-shadow: var(--shadow-glow);
}

/* Location Banner */
.loc-banner {
  display: flex; align-items: center; gap: 8px;
  margin: 0 16px 8px;
  padding: 7px 12px;
  background: rgba(0,201,255,0.06);
  border: 1px solid rgba(0,201,255,0.18);
  border-radius: var(--radius-sm);
  font-size: 12px; color: var(--cyan);
}
.loc-dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--cyan); flex-shrink: 0;
  animation: blink 1.4s ease infinite;
}
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: 0.2; } }

/* Murals List */
.murals-list {
  flex: 1;
  overflow-y: auto;
  padding: 4px 16px calc(var(--nav-h) + 16px);
  -webkit-overflow-scrolling: touch;
}
.murals-list::-webkit-scrollbar { width: 2px; }
.murals-list::-webkit-scrollbar-track { background: transparent; }
.murals-list::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.08); border-radius: 2px; }

/* Neighborhood Header */
.hood-section { margin-bottom: 4px; }
.hood-header {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 0 6px;
}
.hood-header::before {
  content: '';
  width: 10px; height: 1px;
  background: var(--card-border);
}
.hood-header::after {
  content: '';
  flex: 1; height: 1px;
  background: var(--card-border);
}
.hood-name {
  font-size: 9px; font-weight: 800; letter-spacing: 2.5px;
  text-transform: uppercase; color: var(--text3);
  white-space: nowrap;
}
.hood-count {
  font-size: 9px; font-weight: 700; letter-spacing: 1px;
  background: rgba(255,255,255,0.05);
  color: var(--text3);
  padding: 1px 6px; border-radius: var(--radius-full);
}

/* Mural Card */
.mural-card {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  margin-bottom: 8px;
  overflow: hidden;
  transition: all var(--transition);
  position: relative;
  will-change: transform;
}
.mural-card:active { transform: scale(0.985); opacity: 0.9; }
.mural-card.captured {
  border-color: rgba(34, 197, 94, 0.28);
  background: rgba(34, 197, 94, 0.04);
}
.mural-card.captured::before {
  content: '';
  position: absolute; left: 0; top: 0; bottom: 0;
  width: 3px;
  background: var(--grad-green);
  border-radius: 3px 0 0 3px;
}

.mural-inner {
  display: flex; align-items: center;
  padding: 12px 12px 12px 14px;
  gap: 11px;
}

/* Check Button */
.check-btn {
  flex-shrink: 0;
  width: 32px; height: 32px;
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.18);
  background: transparent;
  display: flex; align-items: center; justify-content: center;
  transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  color: transparent;
}
.check-btn.on {
  background: var(--grad-green);
  border-color: transparent;
  color: #fff;
  box-shadow: var(--shadow-green);
  animation: popCheck 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}
@keyframes popCheck {
  0% { transform: scale(1); }
  40% { transform: scale(1.35); }
  70% { transform: scale(0.9); }
  100% { transform: scale(1); }
}

/* Card Info */
.mural-info { flex: 1; min-width: 0; }
.mural-artist {
  font-size: 14px; font-weight: 700; color: var(--text);
  margin-bottom: 2px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.mural-address {
  font-size: 11px; color: var(--text2); line-height: 1.4;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden;
}
.mural-tags {
  display: flex; align-items: center; gap: 5px; flex-wrap: wrap;
  margin-top: 4px;
}
.tag {
  font-size: 9px; font-weight: 700; letter-spacing: 0.5px;
  padding: 2px 7px; border-radius: var(--radius-full);
}
.tag-captured { background: rgba(34,197,94,0.12); color: var(--green); }
.tag-distance { background: rgba(0,201,255,0.1); color: var(--cyan); }
.tag-reserved { background: rgba(107,114,128,0.15); color: var(--gray); }

/* Media Controls */
.media-controls {
  display: flex;
  gap: 6px;
  margin-top: 6px;
  margin-bottom: 2px;
}
.media-btn {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 4px 8px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: var(--radius-sm);
  color: var(--text3);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all var(--transition);
}
.media-btn svg {
  opacity: 0.4;
  transition: transform 0.3s ease;
}
.media-btn:active {
  transform: scale(0.92);
}
.media-btn.active {
  background: rgba(255,255,255,0.07);
  border-color: rgba(255,255,255,0.12);
  color: var(--text);
}
.media-btn.active svg {
  opacity: 1;
  transform: scale(1.1);
}

/* Specific active colors */
.media-btn.active:nth-child(1) { color: var(--cyan); border-color: rgba(0,201,255,0.3); background: rgba(0,201,255,0.05); }
/* The software toggle is technically between the child 1 and child 2 buttons in the DOM, 
   but since it has its own class, I'll just style the children. */
.media-btn.active:nth-last-child(1) { color: var(--amber); border-color: rgba(245,158,11,0.3); background: rgba(245,158,11,0.05); }

/* Software Toggle */
.software-toggle {
  display: flex;
  gap: 3px;
  align-items: center;
  opacity: 0;
  width: 0;
  transform: translateX(-10px);
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: none;
}
.software-toggle.visible {
  opacity: 1;
  width: auto;
  transform: translateX(0);
  margin: 0 4px;
  pointer-events: auto;
}
.soft-btn {
  width: 20px; height: 20px;
  border-radius: 4px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  color: var(--text3);
  font-size: 9px; font-weight: 900;
  display: flex; align-items: center; justify-content: center;
  transition: all var(--transition);
}
.soft-btn.active {
  border-color: rgba(255,255,255,0.2);
  color: #fff;
}
.soft-btn.active[title="CapCut"] {
  background: #3ac6ff; color: #000; border-color: #fff;
  box-shadow: 0 0 8px rgba(58, 198, 255, 0.4);
}
.soft-btn.active[title="DaVinci Resolve"] {
  background: #ff8c00; color: #000; border-color: #fff;
  box-shadow: 0 0 8px rgba(255, 140, 0, 0.4);
}

/* Navigate Button */
.nav-go-btn {
  flex-shrink: 0;
  width: 38px; height: 38px; border-radius: 50%;
  background: rgba(0,201,255,0.08);
  border: 1px solid rgba(0,201,255,0.2);
  display: flex; align-items: center; justify-content: center;
  color: var(--cyan);
  transition: all var(--transition);
}
.nav-go-btn:hover, .nav-go-btn:active {
  background: var(--cyan);
  color: #000;
  box-shadow: var(--shadow-glow);
}

/* ===== MAPA VIEW ===== */
.map-view { position: relative; }

#map {
  position: absolute; inset: 0;
  z-index: 1;
}
.map-overlay-controls {
  position: absolute;
  bottom: calc(var(--nav-h) + 12px); right: 14px;
  z-index: 1000;
  display: flex; flex-direction: column; align-items: flex-end; gap: 8px;
}
.map-fab {
  width: 46px; height: 46px; border-radius: 50%;
  background: rgba(8,12,24,0.92);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,0.12);
  color: var(--text);
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow);
  transition: all var(--transition);
}
.map-fab:hover, .map-fab:active {
  background: var(--cyan); color: #000;
}
.map-legend {
  background: rgba(8,12,24,0.9);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: var(--radius);
  padding: 8px 12px;
  display: flex; flex-direction: column; gap: 5px;
}
.legend-row {
  display: flex; align-items: center; gap: 7px;
  font-size: 11px; font-weight: 500; color: var(--text2);
}
.ldot {
  width: 9px; height: 9px; border-radius: 50%; flex-shrink: 0;
}
.ldot.green { background: var(--green); }
.ldot.blue { background: var(--cyan); }
.ldot.gray { background: var(--gray); }

/* Leaflet Overrides */
.leaflet-container { background: #1a2035 !important; font-family: inherit !important; }
.leaflet-popup-content-wrapper {
  background: #0d1225 !important;
  border: 1px solid rgba(255,255,255,0.1) !important;
  border-radius: 12px !important;
  box-shadow: 0 8px 32px rgba(0,0,0,0.5) !important;
  color: #f0f4ff !important;
}
.leaflet-popup-tip { background: #0d1225 !important; }
.leaflet-popup-close-button { color: #8892a4 !important; top: 8px !important; right: 8px !important; }
.leaflet-control-zoom a {
  background: rgba(8,12,24,0.92) !important;
  backdrop-filter: blur(8px) !important;
  color: #f0f4ff !important;
  border-color: rgba(255,255,255,0.1) !important;
}
.leaflet-control-zoom a:hover { background: rgba(0,201,255,0.2) !important; }

/* Popup */
.popup-body { min-width: 180px; }
.popup-artist { font-size: 14px; font-weight: 700; margin-bottom: 4px; color: #f0f4ff; }
.popup-address { font-size: 11px; color: #8892a4; margin-bottom: 3px; line-height: 1.4; }
.popup-hood { font-size: 10px; font-weight: 600; color: #00c9ff; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 8px; }
.popup-note { font-size: 11px; color: #6b7280; margin-bottom: 8px; font-style: italic; }
.popup-actions { display: flex; gap: 6px; }
.popup-btn {
  flex: 1;
  display: inline-flex; align-items: center; justify-content: center; gap: 4px;
  padding: 7px 10px;
  border-radius: 8px;
  font-size: 11px; font-weight: 700;
  text-decoration: none;
  border: none; cursor: pointer;
  font-family: inherit;
  transition: opacity 0.2s;
}
.popup-btn:hover { opacity: 0.85; }
.popup-btn-nav { background: linear-gradient(135deg,#00c9ff,#0070f3); color: #fff; }
.popup-btn-check { background: rgba(34,197,94,0.15); color: #22c55e; border: 1px solid rgba(34,197,94,0.3); }
.popup-btn-check.done { background: rgba(34,197,94,0.25); }

/* ===== CADASTRO VIEW ===== */
.admin-wrap {
  flex: 1; overflow-y: auto;
  padding: 16px 16px calc(var(--nav-h) + 16px);
  -webkit-overflow-scrolling: touch;
}
.admin-wrap::-webkit-scrollbar { width: 2px; }
.admin-wrap::-webkit-scrollbar-track { background: transparent; }
.admin-wrap::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.08); }

.admin-header {
  display: flex; align-items: flex-start; justify-content: space-between;
  margin-bottom: 20px;
}
.admin-title { font-size: 20px; font-weight: 800; }
.admin-sub { font-size: 12px; color: var(--text2); margin-top: 2px; }
.btn-add {
  display: flex; align-items: center; gap: 6px;
  background: var(--grad-primary);
  color: #fff;
  padding: 9px 14px;
  border-radius: var(--radius-full);
  font-size: 13px; font-weight: 700;
  box-shadow: var(--shadow-glow);
  white-space: nowrap; flex-shrink: 0;
  transition: all var(--transition);
}
.btn-add:active { transform: scale(0.96); opacity: 0.9; }

/* Form */
.mural-form {
  background: var(--card);
  border: 1px solid rgba(0,201,255,0.2);
  border-radius: var(--radius-lg);
  padding: 16px;
  margin-bottom: 20px;
}
.form-header {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 16px;
}
.form-header h3 { font-size: 15px; font-weight: 700; color: var(--cyan); }
.btn-close-form {
  width: 28px; height: 28px; border-radius: var(--radius-full);
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--card-border);
  color: var(--text2);
  display: flex; align-items: center; justify-content: center;
}
.form-group { margin-bottom: 12px; }
.form-group label {
  display: block;
  font-size: 10px; font-weight: 700; letter-spacing: 1.5px;
  text-transform: uppercase; color: var(--text2);
  margin-bottom: 5px;
}
.form-input {
  width: 100%;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: var(--radius-sm);
  padding: 11px 13px;
  color: var(--text);
  transition: border-color var(--transition), box-shadow var(--transition);
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}
.form-input:focus {
  border-color: rgba(0,201,255,0.5);
  box-shadow: 0 0 0 3px rgba(0,201,255,0.08);
}
.form-input option { background: var(--bg2); color: var(--text); }
.form-input-coords {
  font-size: 13px;
  font-family: 'Courier New', monospace;
  letter-spacing: 0.3px;
  color: var(--cyan);
}
.form-hint {
  font-size: 11px;
  color: var(--text3);
  margin-top: 5px;
  line-height: 1.4;
}
.label-hint {
  font-size: 10px;
  font-weight: 500;
  color: var(--text3);
  text-transform: none;
  letter-spacing: 0;
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.form-actions { display: flex; gap: 8px; margin-top: 16px; }
.btn-cancel {
  flex: 1; padding: 11px;
  border-radius: var(--radius-full);
  font-size: 14px; font-weight: 600;
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--card-border);
  color: var(--text2);
  transition: all var(--transition);
}
.btn-save {
  flex: 1.5; padding: 11px;
  border-radius: var(--radius-full);
  font-size: 14px; font-weight: 700;
  background: var(--grad-primary); color: #fff;
  display: flex; align-items: center; justify-content: center; gap: 6px;
  box-shadow: var(--shadow-glow);
  transition: all var(--transition);
}
.btn-save:active { transform: scale(0.97); }

/* Admin List */
.admin-list { margin-bottom: 24px; }
.admin-item {
  display: flex; align-items: center; gap: 10px;
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  padding: 11px 12px;
  margin-bottom: 7px;
  transition: border-color var(--transition);
}
.admin-item:hover { border-color: rgba(255,255,255,0.12); }
.admin-item-info { flex: 1; min-width: 0; }
.admin-item-artist { font-size: 13px; font-weight: 700; margin-bottom: 2px; }
.admin-item-addr {
  font-size: 11px; color: var(--text2);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.admin-item-hood {
  font-size: 10px; font-weight: 700; letter-spacing: 0.5px;
  padding: 2px 8px; border-radius: var(--radius-full);
  background: rgba(0,201,255,0.08); color: var(--cyan);
  white-space: nowrap; flex-shrink: 0;
}
.btn-edit {
  width: 30px; height: 30px; border-radius: 50%;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--card-border);
  color: var(--text2);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  transition: all var(--transition);
}
.btn-edit:active { background: rgba(0,201,255,0.1); color: var(--cyan); }

/* Danger Zone */
.danger-zone {
  border-top: 1px solid var(--card-border);
  padding-top: 20px; margin-top: 8px;
}
.danger-label {
  font-size: 9px; font-weight: 800; letter-spacing: 2.5px;
  text-transform: uppercase; color: var(--red);
  margin-bottom: 12px;
}
.btn-danger {
  display: flex; align-items: center; gap: 8px;
  width: 100%; padding: 11px 14px;
  border-radius: var(--radius-sm);
  font-size: 13px; font-weight: 600;
  background: rgba(239,68,68,0.07);
  border: 1px solid rgba(239,68,68,0.18);
  color: var(--red);
  transition: all var(--transition);
  margin-bottom: 8px;
}
.btn-danger:active { background: rgba(239,68,68,0.14); }

.btn-danger-outline {
  display: flex; align-items: center; justify-content: center;
  width: 100%; padding: 11px 14px;
  border-radius: var(--radius-sm);
  font-size: 12px; font-weight: 700;
  background: transparent;
  border: 1px solid rgba(239,68,68,0.4);
  color: var(--red);
  text-transform: uppercase; letter-spacing: 1px;
  transition: all var(--transition);
}
.btn-danger-outline:active { background: rgba(239,68,68,0.1); }

/* Debug Panel */
.debug-panel {
  background: rgba(255,255,255,0.02);
  border: 1px dashed rgba(255,255,255,0.1);
  border-radius: var(--radius);
  padding: 12px; margin-bottom: 24px;
}
.debug-row {
  display: flex; justify-content: space-between;
  font-size: 11px; margin-bottom: 4px;
  color: var(--text2);
}
.debug-row strong { color: var(--cyan); word-break: break-all; text-align: right; margin-left: 10px; }

/* ===== CARD ACTIONS (navigate + edit buttons) ===== */
.card-actions {
  display: flex; flex-direction: column; gap: 5px;
  flex-shrink: 0;
}
.card-edit-btn {
  width: 38px; height: 30px; border-radius: var(--radius-sm);
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--card-border);
  display: flex; align-items: center; justify-content: center;
  color: var(--text3);
  transition: all var(--transition);
}
.card-edit-btn:active {
  background: rgba(0,201,255,0.1);
  color: var(--cyan);
  border-color: rgba(0,201,255,0.25);
}

/* ===== GLOBAL EDIT BOTTOM SHEET ===== */
.form-sheet-wrapper {
  position: fixed; inset: 0; z-index: 4000;
}
.form-sheet-overlay {
  position: absolute; inset: 0;
  background: rgba(0,0,0,0.65);
  backdrop-filter: blur(4px);
}
.form-sheet {
  position: absolute; bottom: 0; left: 0; right: 0;
  max-width: 480px; margin: 0 auto;
  background: var(--bg2);
  border: 1px solid rgba(255,255,255,0.1);
  border-bottom: none;
  border-radius: 20px 20px 0 0;
  padding: 0 16px calc(env(safe-area-inset-bottom, 8px) + 16px);
  max-height: 88vh;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  transform: translateY(100%);
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}
.form-sheet.open { transform: translateY(0); }
.form-sheet::-webkit-scrollbar { width: 2px; }
.form-sheet::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.08); }
.sheet-handle {
  width: 36px; height: 4px; border-radius: 2px;
  background: rgba(255,255,255,0.12);
  margin: 12px auto 16px;
}

/* ===== BOTTOM NAV ===== */
.bottom-nav {
  flex-shrink: 0;
  display: flex;
  background: rgba(8,12,24,0.96);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid var(--card-border);
  height: var(--nav-h);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
.nav-btn {
  flex: 1;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  color: var(--text3);
  transition: color var(--transition);
  position: relative; padding: 8px 4px;
}
.nav-btn span { font-size: 10px; font-weight: 600; letter-spacing: 0.3px; }
.nav-btn::before {
  content: '';
  position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  width: 0; height: 2px;
  background: var(--grad-primary);
  border-radius: 0 0 2px 2px;
  transition: width 0.3s cubic-bezier(0.4,0,0.2,1);
}
.nav-btn.active { color: var(--cyan); }
.nav-btn.active::before { width: 28px; }

/* ===== TOAST ===== */
.toast {
  position: fixed;
  bottom: calc(var(--nav-h) + 12px);
  left: 50%; transform: translateX(-50%) translateY(12px);
  background: rgba(13,18,37,0.95);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(255,255,255,0.12);
  color: var(--text);
  padding: 10px 18px;
  border-radius: var(--radius-full);
  font-size: 13px; font-weight: 500;
  z-index: 5000;
  white-space: nowrap;
  opacity: 0;
  transition: opacity 0.3s ease, transform 0.3s ease;
  pointer-events: none;
  max-width: calc(100% - 32px);
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ===== MODAL ===== */
.modal {
  position: fixed; inset: 0; z-index: 6000;
  display: flex; align-items: flex-end; justify-content: center;
  padding: 16px;
}
.modal-overlay { position: absolute; inset: 0; background: rgba(0,0,0,0.75); backdrop-filter: blur(4px); }
.modal-box {
  position: relative; z-index: 1;
  background: var(--bg2);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: var(--radius-lg);
  padding: 24px;
  width: 100%; max-width: 420px;
  animation: slideUp 0.3s cubic-bezier(0.4,0,0.2,1);
}
@keyframes slideUp { from { transform: translateY(24px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
.modal-box h3 { font-size: 17px; font-weight: 800; margin-bottom: 8px; }
.modal-box p { font-size: 13px; color: var(--text2); margin-bottom: 20px; line-height: 1.5; }
.modal-actions { display: flex; gap: 8px; }
.modal-actions .btn-cancel { flex: 1; }
.modal-confirm-btn {
  flex: 1; border-radius: var(--radius-full);
  justify-content: center; margin-bottom: 0;
}
