/* ══════════════════════════════════════
   panel.css — Properties Panel (Right)
   Big Band Space Planner
══════════════════════════════════════ */

#properties-panel { overflow-y: auto; }

/* ── Panel Sections ─────────────────── */
.panel-section {
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
}

.section-title {
  font-size: 10px;
  font-weight: 600;
  color: var(--text-3);
  text-transform: uppercase;
  letter-spacing: 0.7px;
  margin-bottom: 8px;
  margin-top: 12px;
}
.panel-section .section-title:first-child { margin-top: 0; }

/* ── Stats Grid ─────────────────────── */
.stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin-bottom: 10px;
}

.stat-card {
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 8px 10px;
  transition: border-color 0.2s;
}
.stat-card.highlight { border-color: rgba(91,141,248,0.3); background: var(--bg-4); }
.stat-card:hover { border-color: var(--border-strong); }

.stat-label {
  font-size: 10px;
  color: var(--text-3);
  margin-bottom: 4px;
  white-space: nowrap;
}
.stat-value {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-1);
  font-feature-settings: 'tnum';
}
.stat-card.highlight .stat-value { color: var(--accent-text); }

/* ── Usage Bar ──────────────────────── */
.usage-bar-wrap { margin-bottom: 12px; }
.usage-bar-bg {
  height: 5px;
  background: var(--bg-1);
  border-radius: 3px;
  overflow: hidden;
}
.usage-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--success), var(--accent));
  border-radius: 3px;
  transition: width 0.4s ease, background 0.3s;
}
.usage-bar-fill.warn { background: linear-gradient(90deg, var(--warning), var(--danger)); }

/* ── Property Rows ──────────────────── */
.prop-group {
  display: flex;
  flex-direction: column;
  gap: 5px;
  margin-bottom: 8px;
}
.prop-row {
  display: flex;
  align-items: center;
  gap: 8px;
}
.prop-label {
  font-size: 11px;
  color: var(--text-2);
  width: 50px;
  flex-shrink: 0;
}
.prop-input-wrap {
  display: flex;
  align-items: center;
  gap: 4px;
  flex: 1;
}
.prop-input-wrap.full { flex: 1; }
.prop-input-wrap input { flex: 1; }
.prop-unit {
  font-size: 11px;
  color: var(--text-3);
  flex-shrink: 0;
}

/* ── Selected Component Header ────── */
.selected-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  margin-bottom: 12px;
}
.selected-swatch {
  width: 28px; height: 28px;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
  box-shadow: 0 0 8px currentColor;
}
.selected-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-1);
}
.selected-type {
  font-size: 11px;
  color: var(--text-3);
}

/* ── Action Buttons ─────────────────── */
.btn-group {
  display: flex;
  gap: 6px;
  margin-bottom: 6px;
}
.action-btn {
  flex: 1;
  padding: 6px 10px;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 500;
  color: var(--text-2);
  transition: all 0.15s;
  text-align: center;
}
.action-btn:hover { background: var(--bg-4); color: var(--text-1); border-color: var(--border-strong); }
.action-btn.accent { color: var(--accent-text); border-color: var(--accent-dim); }
.action-btn.accent:hover { background: var(--accent-dim); color: #fff; }
.action-btn.danger { color: var(--danger); border-color: rgba(248,113,113,0.3); }
.action-btn.danger:hover { background: rgba(248,113,113,0.15); }
.action-btn.full { flex: unset; width: 100%; }

/* ── Collision Alert ─────────────────── */
.collision-alert {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  background: rgba(248,113,113,0.1);
  border: 1px solid rgba(248,113,113,0.3);
  border-radius: var(--radius-sm);
  font-size: 12px;
  color: var(--danger);
  margin-top: 8px;
  animation: pulseAlert 2s ease infinite;
}
@keyframes pulseAlert {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

/* ── Presets ─────────────────────────── */
.preset-list { display: flex; flex-direction: column; gap: 6px; }

.preset-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  text-align: left;
  transition: all 0.18s;
  width: 100%;
}
.preset-btn:hover {
  background: var(--bg-4);
  border-color: var(--accent-dim);
  transform: translateX(2px);
}
.preset-btn.danger:hover {
  border-color: var(--danger-dim);
  background: rgba(248,113,113,0.08);
  transform: translateX(2px);
}
.preset-icon { font-size: 20px; flex-shrink: 0; }
.preset-text { display: flex; flex-direction: column; }
.preset-text strong { font-size: 12px; font-weight: 600; color: var(--text-1); }
.preset-text small { font-size: 10px; color: var(--text-3); margin-top: 1px; }
