* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: #090d16;
  color: #f1f5f9;
  padding: 24px 16px;
  line-height: 1.5;
  min-height: 100vh;
}
.container {
  max-width: 860px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 8px;
  border-bottom: 1px solid #1e293b;
}
.header h1 {
  font-size: 24px;
  font-weight: 700;
  color: #e2e8f0;
  letter-spacing: -0.5px;
}
.subtitle {
  font-size: 13.5px;
  color: #94a3b8;
  margin-top: 4px;
}
.vip-badge-btn {
  background: #1e293b;
  color: #94a3b8;
  border: 1px solid #334155;
  border-radius: 20px;
  padding: 6px 14px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease;
}
.vip-badge-btn.active {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  border-color: rgba(16, 185, 129, 0.4);
}
.card {
  background: #111827;
  border: 1px solid #1f293d;
  border-radius: 12px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}
.section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 600;
  font-size: 14px;
  color: #cbd5e1;
}
.counter {
  font-size: 12px;
  color: #94a3b8;
  font-family: monospace;
  background: #090d16;
  padding: 3px 8px;
  border-radius: 4px;
  border: 1px solid #1f293d;
}
.counter.warn {
  color: #f59e0b;
  border-color: #f59e0b;
}
.counter.danger {
  color: #ef4444;
  border-color: #ef4444;
}
.tag-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.tag-label {
  font-size: 12px;
  color: #94a3b8;
  font-weight: 500;
}
.tag-btn {
  background: #1f293d;
  color: #93c5fd;
  border: 1px solid #334155;
  border-radius: 6px;
  padding: 4px 10px;
  font-size: 12px;
  font-family: monospace;
  cursor: pointer;
  transition: all 0.15s ease;
}
.tag-btn:hover {
  background: #3b82f6;
  color: #ffffff;
  border-color: #2563eb;
}
textarea {
  width: 100%;
  min-height: 220px;
  padding: 14px;
  border-radius: 8px;
  border: 1px solid #1f293d;
  background: #090d16;
  color: #f1f5f9;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 13.5px;
  line-height: 1.6;
  resize: vertical;
}
textarea:focus {
  outline: none;
  border-color: #6366f1;
  box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.25);
}
.action-bar {
  display: flex;
  align-items: center;
  gap: 14px;
}
.btn {
  padding: 10px 18px;
  border-radius: 8px;
  border: none;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.2s ease;
}
.primary-btn {
  background: #6366f1;
  color: #ffffff;
}
.primary-btn:hover:not(:disabled) {
  background: #4f46e5;
}
.secondary-btn {
  background: #0284c7;
  color: #ffffff;
}
.secondary-btn:hover:not(:disabled) {
  background: #0369a1;
}
.danger-btn {
  background: #dc2626;
  color: #ffffff;
}
.danger-btn:hover:not(:disabled) {
  background: #b91c1c;
}
.ghost-btn {
  background: transparent;
  color: #94a3b8;
  border: 1px solid #334155;
}
.ghost-btn:hover {
  color: #ffffff;
  border-color: #475569;
}
.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}
.status-indicator {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: #facc15;
}
.pulse-dot {
  width: 8px;
  height: 8px;
  background-color: #facc15;
  border-radius: 50%;
  animation: pulse 1.2s infinite ease-in-out;
}
@keyframes pulse {
  0% { transform: scale(0.8); opacity: 0.5; }
  50% { transform: scale(1.3); opacity: 1; }
  100% { transform: scale(0.8); opacity: 0.5; }
}
.feedback {
  font-size: 13px;
  color: #10b981;
}

/* Modal Styling */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 999;
  padding: 16px;
}
.modal-card {
  background: #111827;
  border: 1px solid #334155;
  border-radius: 14px;
  padding: 24px;
  max-width: 420px;
  width: 100%;
  box-shadow: 0 10px 25px rgba(0,0,0,0.5);
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.modal-title {
  font-size: 18px;
  font-weight: 700;
  color: #f1f5f9;
}
.modal-sub {
  font-size: 13px;
  color: #94a3b8;
  line-height: 1.4;
}
.vip-input {
  width: 100%;
  padding: 12px;
  border-radius: 8px;
  border: 1px solid #334155;
  background: #090d16;
  color: #f8fafc;
  font-size: 14px;
  margin-top: 6px;
}
.vip-input:focus {
  outline: none;
  border-color: #6366f1;
}
.modal-error {
  font-size: 12.5px;
  color: #ef4444;
  margin-top: 4px;
}
.modal-actions {
  display: flex;
  gap: 10px;
  margin-top: 8px;
}
.hidden { display: none !important; }
