/* ══════════════════════════════════════════════════════════════════════
   Profile Banners — CSS-only cosmetic banners for user profiles
   ══════════════════════════════════════════════════════════════════════ */

/* ── Base ──────────────────────────────────────────────────────────── */

.profile-banner {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  border-radius: inherit;
  pointer-events: none;
}

/* ── COMMON ────────────────────────────────────────────────────────── */

.banner-default {
  background: transparent;
}

.banner-mist::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 50%, rgba(180, 180, 200, 0.12), transparent 70%);
}

.banner-dusk::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(200, 120, 80, 0.2), rgba(80, 100, 160, 0.2));
}

/* ── UNCOMMON ──────────────────────────────────────────────────────── */

.banner-rose-garden::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(180, 60, 80, 0.15), rgba(220, 120, 140, 0.1), rgba(140, 40, 60, 0.12));
}
.banner-rose-garden::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 30% 70%, rgba(220, 80, 100, 0.08), transparent 50%),
              radial-gradient(circle at 70% 30%, rgba(200, 60, 90, 0.06), transparent 50%);
}

.banner-twilight::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(60, 20, 120, 0.25), rgba(30, 60, 140, 0.2));
}

.banner-ember::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(200, 120, 40, 0.2), rgba(180, 80, 20, 0.15));
}
.banner-ember::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 200, 100, 0.06), transparent);
  animation: banner-shimmer 4s ease-in-out infinite;
}

/* ── RARE ──────────────────────────────────────────────────────────── */

.banner-aurora::before {
  content: '';
  position: absolute;
  inset: -50%;
  background: linear-gradient(
    45deg,
    rgba(40, 180, 120, 0.15),
    rgba(80, 120, 200, 0.12),
    rgba(160, 60, 180, 0.15),
    rgba(40, 180, 120, 0.15)
  );
  background-size: 300% 300%;
  animation: banner-aurora-shift 8s ease-in-out infinite;
}

.banner-stardust::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(20, 20, 40, 0.6), rgba(40, 20, 60, 0.5));
}
.banner-stardust::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(1px 1px at 10% 20%, rgba(255, 255, 255, 0.6), transparent),
    radial-gradient(1px 1px at 30% 60%, rgba(255, 255, 255, 0.5), transparent),
    radial-gradient(1px 1px at 50% 30%, rgba(255, 255, 255, 0.4), transparent),
    radial-gradient(1px 1px at 70% 70%, rgba(255, 255, 255, 0.6), transparent),
    radial-gradient(1px 1px at 90% 40%, rgba(255, 255, 255, 0.5), transparent),
    radial-gradient(1px 1px at 20% 80%, rgba(255, 255, 255, 0.3), transparent),
    radial-gradient(1px 1px at 60% 10%, rgba(255, 255, 255, 0.4), transparent),
    radial-gradient(1px 1px at 80% 90%, rgba(255, 255, 255, 0.5), transparent);
  animation: banner-twinkle 3s ease-in-out infinite alternate;
}

.banner-ocean::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(20, 60, 100, 0.25), rgba(10, 40, 80, 0.3));
}
.banner-ocean::after {
  content: '';
  position: absolute;
  inset: -20%;
  background: linear-gradient(
    90deg,
    transparent 20%,
    rgba(40, 140, 180, 0.1) 40%,
    rgba(60, 160, 200, 0.08) 60%,
    transparent 80%
  );
  animation: banner-wave 6s ease-in-out infinite;
}

.banner-discord::before {
  content: '';
  position: absolute;
  inset: -30%;
  background: linear-gradient(
    135deg,
    rgba(88, 101, 242, 0.2),
    rgba(114, 137, 218, 0.15),
    rgba(88, 101, 242, 0.2)
  );
  background-size: 200% 200%;
  animation: banner-discord-shift 5s ease-in-out infinite;
}
.banner-discord::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(114, 137, 218, 0.08), transparent);
  animation: banner-shimmer 3s ease-in-out infinite;
}

/* ── EPIC ──────────────────────────────────────────────────────────── */

.banner-nebula::before {
  content: '';
  position: absolute;
  inset: -30%;
  background: radial-gradient(ellipse at 30% 50%, rgba(120, 40, 160, 0.2), transparent 60%),
              radial-gradient(ellipse at 70% 50%, rgba(200, 60, 120, 0.15), transparent 60%);
  animation: banner-nebula-drift 10s ease-in-out infinite;
}
.banner-nebula::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 50%, rgba(160, 80, 200, 0.08), transparent 70%);
}

.banner-inferno::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    0deg,
    rgba(200, 60, 20, 0.2),
    rgba(220, 120, 40, 0.15),
    rgba(180, 40, 10, 0.18)
  );
  background-size: 100% 300%;
  animation: banner-fire 4s ease-in-out infinite;
}
.banner-inferno::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 100%, rgba(255, 100, 20, 0.12), transparent 60%);
}

.banner-crystal::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(100, 200, 255, 0.1),
    rgba(200, 100, 255, 0.08),
    rgba(255, 200, 100, 0.1),
    rgba(100, 255, 200, 0.08)
  );
  background-size: 400% 400%;
  animation: banner-prismatic 6s ease-in-out infinite;
}
.banner-crystal::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.04), transparent);
  animation: banner-shimmer 3s ease-in-out infinite;
}

/* ── LEGENDARY ─────────────────────────────────────────────────────── */

.banner-celestial::before {
  content: '';
  position: absolute;
  inset: -50%;
  background:
    radial-gradient(1.5px 1.5px at 15% 25%, rgba(255, 255, 255, 0.7), transparent),
    radial-gradient(1px 1px at 35% 65%, rgba(255, 255, 255, 0.5), transparent),
    radial-gradient(2px 2px at 55% 15%, rgba(255, 220, 150, 0.6), transparent),
    radial-gradient(1px 1px at 75% 45%, rgba(255, 255, 255, 0.4), transparent),
    radial-gradient(1.5px 1.5px at 25% 85%, rgba(200, 220, 255, 0.6), transparent),
    radial-gradient(1px 1px at 85% 75%, rgba(255, 255, 255, 0.5), transparent),
    radial-gradient(2px 2px at 45% 55%, rgba(255, 200, 100, 0.4), transparent),
    radial-gradient(1px 1px at 65% 35%, rgba(200, 200, 255, 0.5), transparent);
  animation: banner-starfield 20s linear infinite;
}
.banner-celestial::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 50%, rgba(40, 40, 80, 0.4), rgba(10, 10, 30, 0.6));
}

.banner-void::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 50%, rgba(10, 10, 20, 0.8), rgba(5, 5, 10, 0.95));
}
.banner-void::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    transparent 30%,
    rgba(200, 160, 60, 0.08) 45%,
    rgba(200, 160, 60, 0.04) 55%,
    transparent 70%
  );
  background-size: 200% 200%;
  animation: banner-void-gold 5s ease-in-out infinite;
}

/* ── LIMITED ────────────────────────────────────────────────────────── */

.banner-founders::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(200, 160, 60, 0.2),
    rgba(200, 100, 120, 0.15),
    rgba(200, 160, 60, 0.2)
  );
  background-size: 200% 200%;
  animation: banner-founders-shift 4s ease-in-out infinite;
}
.banner-founders::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 220, 140, 0.06), transparent);
  animation: banner-shimmer 3s ease-in-out infinite;
}

/* ── Animations ────────────────────────────────────────────────────── */

@keyframes banner-shimmer {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

@keyframes banner-aurora-shift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

@keyframes banner-twinkle {
  0% { opacity: 0.4; }
  100% { opacity: 1; }
}

@keyframes banner-wave {
  0%, 100% { transform: translateX(-10%); }
  50% { transform: translateX(10%); }
}

@keyframes banner-nebula-drift {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  33% { transform: translate(5%, -3%) rotate(2deg); }
  66% { transform: translate(-3%, 5%) rotate(-1deg); }
}

@keyframes banner-fire {
  0%, 100% { background-position: 0% 0%; }
  50% { background-position: 0% 100%; }
}

@keyframes banner-prismatic {
  0%, 100% { background-position: 0% 0%; }
  25% { background-position: 100% 0%; }
  50% { background-position: 100% 100%; }
  75% { background-position: 0% 100%; }
}

@keyframes banner-starfield {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

@keyframes banner-void-gold {
  0%, 100% { background-position: 0% 0%; }
  50% { background-position: 100% 100%; }
}

@keyframes banner-founders-shift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

@keyframes banner-discord-shift {
  0%, 100% { background-position: 0% 50%; transform: rotate(0deg); }
  50% { background-position: 100% 50%; transform: rotate(2deg); }
}

/* ── Banner selector grid (profile) ───────────────────────────────── */

.banner-selector-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 12px;
  padding: 12px 16px 16px;
}

.banner-selector-item {
  position: relative;
  border-radius: 10px;
  height: 80px;
  cursor: pointer;
  border: 2px solid transparent;
  transition: border-color 0.2s, opacity 0.2s;
  background: var(--surface);
}
.banner-selector-item .profile-banner { border-radius: 8px; overflow: hidden }

.banner-selector-item:hover:not(.locked) {
  border-color: var(--rose-30);
}

.banner-selector-item.equipped {
  border-color: var(--rose);
}

.banner-selector-item.locked {
  opacity: 0.35;
  cursor: default;
}

.banner-sel-info {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 4px 8px;
  background: rgba(0, 0, 0, 0.5);
  border-radius: 0 0 8px 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 1;
}

.banner-sel-name {
  font-size: 11px;
  color: var(--cream);
  font-weight: 500;
}

.banner-sel-tier {
  font-size: 10px;
  text-transform: capitalize;
}

/* ── Banner preview box (profile) ─────────────────────────────────── */

.banner-preview-box {
  position: relative;
  width: 100%;
  max-width: 320px;
  height: 100px;
  border-radius: 12px;
  overflow: hidden;
  background: var(--surface);
}
