.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  backdrop-filter: blur(4px);
  animation: fadeIn 0.15s ease-out;
}

.modal-container {
  background: var(--panel-strong);
  border: 1px solid var(--line);
  border-radius: 12px;
  width: 520px;
  max-width: 90%;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: slideUp 0.2s ease-out;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 24px 28px 16px;
  border-bottom: 1px solid var(--line-soft);
}

.modal-header h2 {
  margin: 0;
  font-size: 22px;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.2;
}

.modal-subtitle {
  margin: 8px 0 0;
  font-size: 13px;
  color: var(--muted);
  line-height: 1.4;
}

.modal-header .close-btn {
  background: transparent;
  border: none;
  color: var(--muted);
  cursor: pointer;
  padding: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: background 0.1s;
}

.modal-header .close-btn:hover {
  background: var(--bg);
  color: var(--ink);
}

.modal-body {
  padding: 24px 28px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  max-height: 60vh;
  overflow-y: auto;
}

.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  padding: 16px 28px;
  background: var(--bg);
  border-top: 1px solid var(--line-soft);
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

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