/* Wiki plugin detail pages */
.wiki-plugin-page main {
  --wp-cyan: #00e1fd;
  --wp-purple: #b026ff;
  --wp-glow: rgba(0, 225, 253, 0.14);
}

.wiki-plugin-hero__badge {
  background: linear-gradient(135deg, rgba(0, 225, 253, 0.12), rgba(176, 38, 255, 0.12));
  border: 1px solid rgba(0, 225, 253, 0.28);
  box-shadow: 0 0 24px rgba(0, 225, 253, 0.08);
}

.wiki-plugin-stat {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  padding: 0.85rem 1rem;
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  min-width: 5.5rem;
}

.wiki-plugin-stat__val {
  font-size: 1.35rem;
  font-weight: 800;
  line-height: 1;
  background: linear-gradient(135deg, var(--wp-cyan), var(--wp-purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.wiki-plugin-stat__lbl {
  font-size: 0.62rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
  font-weight: 700;
}

.wiki-plugin-feature-grid {
  display: grid;
  gap: 0.65rem;
}

.wiki-plugin-feature-card {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  padding: 0.85rem 1rem;
  border-radius: 1rem;
  background: linear-gradient(135deg, rgba(0, 225, 253, 0.05), rgba(176, 38, 255, 0.04));
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.wiki-plugin-feature-card:hover {
  border-color: rgba(0, 225, 253, 0.28);
  transform: translateY(-1px);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.25);
}

.wiki-plugin-feature-card__dot {
  flex-shrink: 0;
  width: 0.45rem;
  height: 0.45rem;
  margin-top: 0.45rem;
  border-radius: 999px;
  background: var(--wp-cyan);
  box-shadow: 0 0 10px rgba(0, 225, 253, 0.75);
}

.wiki-plugin-config-chip {
  font-size: 0.68rem;
  padding: 0.35rem 0.65rem;
  border-radius: 0.65rem;
  background: rgba(0, 225, 253, 0.07);
  border: 1px solid rgba(0, 225, 253, 0.18);
  color: #9de9ff;
  font-family: ui-monospace, monospace;
}

/* Perks gallery */
.wiki-perks-section {
  position: relative;
  overflow: hidden;
}

.wiki-perks-section::before {
  content: "";
  position: absolute;
  inset: -40% auto auto 50%;
  width: 28rem;
  height: 28rem;
  transform: translateX(-50%);
  background: radial-gradient(circle, rgba(176, 38, 255, 0.14), transparent 68%);
  pointer-events: none;
}

.wiki-perks-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.wiki-perks-search {
  flex: 1 1 14rem;
  max-width: 22rem;
  padding: 0.65rem 1rem 0.65rem 2.4rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(0, 0, 0, 0.35) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%23ffffff55' viewBox='0 0 24 24'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M21 21l-4.35-4.35M11 18a7 7 0 100-14 7 7 0 000 14z'/%3E%3C/svg%3E") 0.85rem center no-repeat;
  color: #fff;
  font-size: 0.85rem;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.wiki-perks-search:focus {
  border-color: rgba(176, 38, 255, 0.45);
  box-shadow: 0 0 0 3px rgba(176, 38, 255, 0.12);
}

.wiki-perks-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.wiki-perks-filter {
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.wiki-perks-filter:hover,
.wiki-perks-filter.is-active {
  color: #fff;
  border-color: rgba(176, 38, 255, 0.45);
  background: rgba(176, 38, 255, 0.14);
  box-shadow: 0 0 18px rgba(176, 38, 255, 0.15);
}

.wiki-perks-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(11.5rem, 1fr));
  gap: 0.85rem;
}

.wiki-perk-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  padding: 1rem;
  border-radius: 1.15rem;
  background: linear-gradient(160deg, rgba(12, 6, 28, 0.92), rgba(8, 4, 18, 0.88));
  border: 1px solid rgba(255, 255, 255, 0.09);
  overflow: hidden;
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.wiki-perk-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(0, 225, 253, 0.06), rgba(176, 38, 255, 0.08));
  opacity: 0;
  transition: opacity 0.22s ease;
  pointer-events: none;
}

.wiki-perk-card:hover {
  transform: translateY(-3px) scale(1.01);
  border-color: rgba(176, 38, 255, 0.35);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.35), 0 0 30px rgba(176, 38, 255, 0.1);
}

.wiki-perk-card:hover::after {
  opacity: 1;
}

.wiki-perk-card__top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem;
  position: relative;
  z-index: 1;
}

.wiki-perk-card__icon {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 0.75rem;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(0, 0, 0, 0.25)),
    #1a1028;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 4px 14px rgba(0, 0, 0, 0.35);
  display: grid;
  place-items: center;
  image-rendering: pixelated;
}

.wiki-perk-card__icon img {
  width: 1.65rem;
  height: 1.65rem;
  object-fit: contain;
}

.wiki-perk-card__id {
  font-size: 0.58rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-family: ui-monospace, monospace;
  color: rgba(176, 38, 255, 0.85);
  padding: 0.2rem 0.45rem;
  border-radius: 0.45rem;
  background: rgba(176, 38, 255, 0.1);
  border: 1px solid rgba(176, 38, 255, 0.2);
}

.wiki-perk-card__name {
  position: relative;
  z-index: 1;
  font-size: 0.95rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  color: #fff;
}

.wiki-perk-card__desc {
  position: relative;
  z-index: 1;
  font-size: 0.78rem;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.62);
  flex: 1;
}

.wiki-perk-card__cat {
  position: relative;
  z-index: 1;
  font-size: 0.58rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-weight: 700;
  color: rgba(0, 225, 253, 0.7);
}

.wiki-perk-card.is-hidden {
  display: none;
}

/* Commands & permissions cards */
.wiki-cmd-grid,
.wiki-perm-grid {
  display: grid;
  gap: 0.75rem;
}

.wiki-cmd-card,
.wiki-perm-card {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.75rem 1rem;
  align-items: center;
  padding: 1rem 1.15rem;
  border-radius: 1.1rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: border-color 0.2s ease, background 0.2s ease;
}

.wiki-cmd-card:hover,
.wiki-perm-card:hover {
  border-color: rgba(0, 225, 253, 0.22);
  background: rgba(0, 225, 253, 0.04);
}

.wiki-cmd-card__cmd {
  font-family: ui-monospace, monospace;
  font-size: 0.95rem;
  color: #7de9ff;
  font-weight: 700;
}

.wiki-cmd-card__desc,
.wiki-perm-card__desc {
  grid-column: 1 / -1;
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.68);
  line-height: 1.5;
}

.wiki-cmd-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  grid-column: 1;
}

.wiki-chip {
  font-size: 0.62rem;
  padding: 0.25rem 0.55rem;
  border-radius: 999px;
  letter-spacing: 0.08em;
  font-family: ui-monospace, monospace;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  color: rgba(255, 255, 255, 0.72);
}

.wiki-chip--perm {
  color: #d8b4fe;
  border-color: rgba(176, 38, 255, 0.25);
  background: rgba(176, 38, 255, 0.08);
}

.wiki-copy-btn {
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  border: 1px solid rgba(0, 225, 253, 0.35);
  background: rgba(0, 225, 253, 0.08);
  color: #7de9ff;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.wiki-copy-btn:hover {
  background: rgba(0, 225, 253, 0.18);
  box-shadow: 0 0 16px rgba(0, 225, 253, 0.15);
}

.wiki-copy-btn.is-copied {
  border-color: rgba(52, 211, 153, 0.45);
  color: #6ee7b7;
  background: rgba(52, 211, 153, 0.12);
}

.wiki-section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.wiki-section-head h2 {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.wiki-empty {
  padding: 1.25rem 1.5rem;
  border-radius: 1rem;
  border: 1px dashed rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.85rem;
}

@media (max-width: 640px) {
  .wiki-perks-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .wiki-cmd-card,
  .wiki-perm-card {
    grid-template-columns: 1fr;
  }
}
