.admin-wrap {
  width: min(960px, calc(100% - 2rem));
}

.brand-hero-sm .logo-hero {
  width: min(140px, 40vw);
}

.admin-login {
  max-width: 420px;
  margin: 0 auto;
}

.admin-login code {
  font-size: 0.8em;
  color: #ffb4bc;
}

.back-link {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.9rem;
}

.back-link:hover {
  color: var(--text);
}

.topbar-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.admin-title {
  font-family: var(--display);
  font-size: 1.05rem;
}

.add-panel {
  margin-bottom: 1rem;
}

.add-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

.admin-check {
  flex-direction: row;
  align-items: center;
  gap: 0.55rem;
}

.admin-check code {
  color: #ffb4bc;
  font-size: 0.85em;
}

textarea {
  background: #0a0a0c;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.75rem 0.9rem;
  outline: none;
  resize: vertical;
  min-height: 88px;
  transition: border-color 0.2s, box-shadow 0.2s;
}

textarea:focus {
  border-color: var(--red);
  box-shadow: 0 0 0 3px var(--red-dim);
}

.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 0.75rem;
}

.tab {
  padding: 0.5rem 0.8rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--muted);
}

.tab:hover {
  color: var(--text);
}

.tab.active {
  color: #fff;
  border-color: rgba(155, 27, 42, 0.7);
  background: linear-gradient(135deg, rgba(196, 35, 56, 0.45), rgba(155, 27, 42, 0.35));
}

.tab-couple.active {
  border-color: rgba(232, 120, 160, 0.65);
  background: linear-gradient(135deg, rgba(196, 60, 110, 0.45), rgba(120, 40, 70, 0.4));
}

.tab-gender.active {
  border-color: rgba(120, 170, 255, 0.65);
  background: linear-gradient(135deg, rgba(80, 120, 220, 0.4), rgba(40, 60, 120, 0.35));
}

.tab-gender-f.active {
  border-color: rgba(232, 120, 160, 0.65);
  background: linear-gradient(135deg, rgba(196, 60, 110, 0.45), rgba(120, 40, 70, 0.4));
}

.list-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.85rem;
}

.list-head h2 {
  margin: 0;
  font-family: var(--display);
  font-size: 1.1rem;
}

.admin-search {
  margin-bottom: 0.75rem;
}

.admin-search input {
  width: 100%;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.card-admin-list,
.suggestions-admin-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  max-height: min(58vh, 640px);
  overflow: auto;
}

.suggestions-admin-list {
  max-height: min(42vh, 420px);
}

.card-admin-list li,
.suggestions-admin-list li {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.75rem 0.85rem;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--line);
}

.card-admin-list .body,
.suggestions-admin-list .body {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-width: 0;
}

.card-admin-list .text,
.suggestions-admin-list .text {
  font-size: 0.95rem;
  line-height: 1.35;
}

.sug-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
}

.tag-couple {
  border-color: rgba(232, 120, 160, 0.5);
  color: #ffb6c8;
}

.tag-level-ultra {
  border-color: rgba(180, 40, 90, 0.6);
  color: #ff8ab0;
}

.tag-level-hard {
  border-color: rgba(196, 35, 56, 0.5);
  color: #ff8a96;
}

.sug-score-pill {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.sug-admin-actions {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  flex-shrink: 0;
}

.suggestions-panel {
  margin-bottom: 1rem;
  border-color: rgba(232, 165, 75, 0.28);
  background:
    linear-gradient(120deg, rgba(232, 165, 75, 0.06), transparent 50%),
    var(--bg-panel);
}

.btn-delete {
  flex-shrink: 0;
  padding: 0.4rem 0.7rem;
  border-radius: 999px;
  border: 1px solid rgba(196, 35, 56, 0.45);
  color: #ff8a96;
  font-size: 0.78rem;
  font-weight: 600;
}

.btn-delete:hover {
  background: rgba(196, 35, 56, 0.15);
}

@media (max-width: 560px) {
  .add-grid {
    grid-template-columns: 1fr;
  }

  .suggestions-admin-list li,
  .card-admin-list li {
    flex-direction: column;
  }

  .sug-admin-actions {
    flex-direction: row;
    width: 100%;
  }
}
