.comp-wrap { flex: 1 0 auto; }

    /* -- Page layout -- */
    .comp-wrap {
      width: 100%;
      max-width: var(--max-content-width);
      margin: 0 auto;
      padding: 2.5rem 1.5rem 3rem;
      box-sizing: border-box;
    }
    .comp-head {
      display: flex;
      flex-direction: column;
      gap: 0.35rem;
      margin-bottom: 2rem;
      padding-bottom: 0.75rem;
      border-bottom: 1px solid rgba(255, 255, 255, 0.12);
    }
    .comp-crumbs {
      display: flex;
      align-items: center;
      gap: 0.45rem;
      font-size: 0.8rem;
      color: var(--color-text-muted);
      margin-bottom: 0.5rem;
    }
    .comp-crumbs a {
      color: var(--color-text-muted);
      text-decoration: none;
      transition: color 0.15s ease;
    }
    .comp-crumbs a:hover { color: var(--color-text); }
    .comp-crumbs i { font-size: 0.65rem; opacity: 0.5; }

    .comp-title {
      font-family: var(--font-display);
      font-size: clamp(2.25rem, 5vw, 3rem);
      font-weight: 600;
      letter-spacing: -0.015em;
      color: var(--color-text);
      margin: 0;
      line-height: 1.1;
    }
    .comp-subtitle {
      font-size: 0.95rem;
      color: var(--color-text-muted);
      margin: 0;
      line-height: 1.55;
    }
    .comp-subtitle strong { color: var(--color-text); font-weight: 500; }

    /* -- Shared card / panel -- */
    .comp-card {
      border: 1px solid rgba(255, 255, 255, 0.10);
      border-radius: 0.25rem;
      background: var(--color-bg-elevated);
      padding: 1.5rem;
      margin-bottom: 1.25rem;
    }
    .comp-card > *:first-child { margin-top: 0; }
    .comp-card > *:last-child { margin-bottom: 0; }

    /* -- Countdown strip -- */
    .comp-countdown-strip {
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: 0.35rem;
      padding: 1rem 1.25rem;
      margin-bottom: 1.25rem;
      border: 1px solid rgba(255, 255, 255, 0.10);
      border-radius: 0.25rem;
      background: var(--color-bg-elevated);
    }
    .comp-countdown-label {
      font-size: 0.72rem;
      font-weight: 600;
      text-transform: uppercase;
      letter-spacing: 0.1em;
      color: var(--color-text-muted);
    }
    .comp-countdown {
      font-family: var(--font-mono);
      font-size: clamp(1.5rem, 4vw, 2.25rem);
      font-weight: 600;
      color: var(--color-text);
      letter-spacing: 0.02em;
      line-height: 1;
    }

    /* -- Section label inside a card -- */
    .comp-section-label {
      font-size: 1.15rem;
      font-weight: 600;
      color: var(--color-text);
      margin: 0 0 0.4rem;
      letter-spacing: -0.01em;
    }
    .comp-section-text {
      font-size: 0.9rem;
      color: var(--color-text-secondary);
      margin: 0;
      line-height: 1.6;
      white-space: pre-wrap;
    }

    /* -- Promo video -- */
    .comp-promo-wrap {
      position: relative;
      border-radius: 0.25rem;
      overflow: hidden;
      background: #000;
      aspect-ratio: 16 / 9;
      margin: 0.5rem 0 1.25rem;
    }
    .comp-promo-wrap video {
      width: 100%;
      height: 100%;
      object-fit: cover;
      display: block;
      cursor: pointer;
    }
    .comp-promo-play {
      position: absolute;
      inset: 0;
      margin: auto;
      width: 4rem;
      height: 4rem;
      border-radius: 50%;
      border: 0;
      background: rgba(15, 15, 17, 0.82);
      color: #ffffff;
      font-size: 1.25rem;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      cursor: pointer;
      transition: background 0.15s ease, transform 0.15s ease;
    }
    .comp-promo-play:hover { background: rgba(15, 15, 17, 0.95); transform: scale(1.05); }
    .comp-promo-play.is-hidden { display: none; }

    /* -- Prize pool + rewards -- */
    .comp-prize {
      padding: 1.25rem 0 0;
      margin: 1.25rem 0 0;
      border-top: 1px solid rgba(255, 255, 255, 0.08);
      text-align: center;
    }
    .comp-prize-label {
      font-size: 0.7rem;
      font-weight: 600;
      letter-spacing: 0.1em;
      text-transform: uppercase;
      color: var(--color-text-muted);
      margin: 0 0 0.2rem;
    }
    .comp-prize-amount {
      font-size: clamp(1.75rem, 4vw, 2.5rem);
      font-weight: 600;
      color: var(--color-text);
      margin: 0;
      line-height: 1;
      letter-spacing: -0.02em;
    }
    .comp-reward-grid {
      display: flex;
      flex-wrap: wrap;
      justify-content: center;
      gap: 0.35rem 0.9rem;
      margin-top: 1rem;
    }
    .comp-reward-item {
      display: inline-flex;
      align-items: baseline;
      gap: 0.35rem;
      color: var(--color-text-secondary);
    }

    .comp-reward-item .rank-label {
      font-size: 0.7rem;
      color: var(--color-text-muted);
      text-transform: uppercase;
      letter-spacing: 0.06em;
      font-weight: 600;
    }
    .comp-reward-item .reward-value {
      font-family: var(--font-mono);
      font-size: 0.85rem;
      font-weight: 600;
      color: var(--color-text);
    }

    /* -- Divider + links -- */
    .comp-divider {
      border: 0;
      border-top: 1px solid rgba(255, 255, 255, 0.08);
      margin: 1.1rem 0;
    }
    .comp-link-label {
      display: inline-flex;
      align-items: center;
      gap: 0.35rem;
      font-size: 0.78rem;
      font-weight: 600;
      text-transform: uppercase;
      letter-spacing: 0.08em;
      color: var(--color-text-muted);
      margin-bottom: 0.65rem;
    }
    .comp-link-label i { color: #626cff; font-size: 0.7rem; }
    .comp-ext-link {
      display: inline-flex;
      align-items: center;
      gap: 0.4rem;
      padding: 0.45rem 0.75rem;
      border: 1px solid rgba(255, 255, 255, 0.14);
      background: var(--color-bg-elevated);
      color: var(--color-text-secondary);
      border-radius: 0.25rem;
      font-size: 0.8rem;
      text-decoration: none;
      transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease;
    }
    .comp-ext-link:hover {
      border-color: rgba(255, 255, 255, 0.3);
      background: var(--color-bg-hover);
      color: var(--color-text);
    }
    .comp-ext-link i { font-size: 0.65rem; opacity: 0.7; }

    /* -- Promo art -- */
    .comp-art {
      display: block;
      width: 100%;
      border-radius: 0.25rem;
    }

    /* -- Submit form -- */
    .comp-form-label {
      font-size: 0.72rem;
      font-weight: 600;
      text-transform: uppercase;
      letter-spacing: 0.08em;
      color: var(--color-text-muted);
      margin-bottom: 0.35rem;
      display: block;
    }
    .comp-form-input {
      width: 100%;
      padding: 0.6rem 0.75rem;
      background: var(--color-bg);
      border: 1px solid rgba(255, 255, 255, 0.15);
      border-radius: 0.25rem;
      color: var(--color-text);
      font-size: 0.88rem;
      outline: none;
      transition: border-color 0.15s ease;
    }
    .comp-form-input:focus { border-color: #626cff; }
    .comp-form-meta {
      display: flex;
      justify-content: space-between;
      align-items: center;
      font-size: 0.72rem;
      color: var(--color-text-muted);
      margin-top: 0.4rem;
    }
    .comp-char-count { font-family: var(--font-mono); }

    /* -- Alerts -- */
    .comp-alert {
      display: flex;
      gap: 0.75rem;
      align-items: flex-start;
      padding: 0.85rem 1rem;
      border: 1px solid rgba(255, 255, 255, 0.10);
      background: var(--color-bg-elevated);
      border-radius: 0.25rem;
      font-size: 0.88rem;
    }
    .comp-alert--warn {
      border-color: rgba(251, 191, 36, 0.30);
      background: rgba(251, 191, 36, 0.08);
    }
    .comp-alert .alert-icon {
      flex-shrink: 0;
      color: #fbbf24;
      margin-top: 0.1rem;
    }
    .comp-alert .alert-title { font-weight: 600; color: var(--color-text); margin: 0 0 0.1rem; }
    .comp-alert .alert-text { font-size: 0.82rem; color: var(--color-text-muted); margin: 0; line-height: 1.5; }

    /* -- Leaderboard -- */
    .comp-lb-head {
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      justify-content: space-between;
      gap: 0.75rem;
      margin-bottom: 1rem;
    }
    .comp-lb-title {
      display: inline-flex;
      align-items: center;
      gap: 0.5rem;
      font-size: 1.25rem;
      font-weight: 600;
      color: var(--color-text);
    }
    .comp-lb-title i { color: var(--color-icon); font-size: 1.1rem; }
    .comp-lb-subtitle {
      font-size: 0.82rem;
      color: var(--color-text-muted);
      width: 100%;
      margin: 0;
    }
    .comp-lb-count {
      display: inline-flex;
      align-items: center;
      gap: 0.5rem;
      font-size: 0.78rem;
      color: var(--color-text-muted);
    }
    .comp-lb-count .count-badge {
      padding: 0.15rem 0.55rem;
      background: var(--color-bg-elevated);
      border: 1px solid rgba(255, 255, 255, 0.12);
      border-radius: 0.25rem;
      font-family: var(--font-mono);
      font-size: 0.75rem;
      color: var(--color-text);
    }

    .comp-lb-table {
      width: 100%;
      border-collapse: separate;
      border-spacing: 0;
      font-size: 0.87rem;
    }
    .comp-lb-table,
    .comp-lb-table tbody,
    .comp-lb-table tr {
      display: block;
      width: 100%;
    }
    .comp-lb-table tr {
      display: grid;
      grid-template-columns: auto minmax(0, 1fr) auto auto;
      align-items: center;
      gap: 0.85rem;
      padding: 0.78rem 0;
      border: 0;
      border-top: 1px solid rgba(255, 255, 255, 0.08);
      background: transparent;
      border-radius: 0;
    }
    .comp-lb-table tr + tr {
      margin-top: 0;
    }
    .comp-lb-table td {
      display: block;
      min-width: 0;
      padding: 0;
      border-bottom: 0;
      color: var(--color-text-secondary);
      vertical-align: middle;
      text-align: left;
    }
    .comp-lb-table td[data-label="Rank"] {
      width: 2.5rem;
    }
    .comp-lb-table td[data-label="Competitor"] {
      overflow: hidden;
    }
    .comp-lb-table td[data-label="Reward"],
    .comp-lb-table td[data-label="Entry"] {
      text-align: right;
      white-space: nowrap;
    }
    .comp-lb-table td::before {
      display: none;
    }
    .comp-lb-table tbody tr:hover { background: transparent; }
    .comp-lb-table tbody tr.user-highlight {
      background: transparent;
    }
    .comp-rank-num {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 2.25rem;
      height: 2.25rem;
      border-radius: 0.25rem;
      background: var(--color-bg-elevated);
      font-family: var(--font-mono);
      color: var(--color-text);
      font-size: 0.76rem;
      font-weight: 700;
    }
    .comp-lb-table tbody tr.user-highlight .comp-rank-num {
      border: 1px solid rgba(98, 108, 255, 0.42);
      background: rgba(98, 108, 255, 0.14);
      color: var(--color-brand);
    }
    .comp-name {
      display: block;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
      color: var(--color-text);
      font-weight: 500;
    }
    .comp-name-gold   { color: #fde68a; }
    .comp-name-silver { color: #e5e7eb; }
    .comp-name-bronze { color: #fdba74; }
    .comp-name-anon { color: var(--color-text-muted); font-style: italic; font-weight: 400; }
    .comp-reward-cell { font-family: var(--font-mono); color: var(--color-text-secondary); font-size: 0.82rem; }

    .comp-watch-btn {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      gap: 0;
      width: 2.35rem;
      height: 2.35rem;
      padding: 0;
      border: 1px solid rgba(255, 255, 255, 0.14);
      background: var(--color-bg-elevated);
      color: var(--color-text-secondary);
      border-radius: 0.25rem;
      font-size: 0;
      font-weight: 500;
      text-decoration: none;
      transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease;
    }
    .comp-watch-btn:hover {
      border-color: rgba(255, 255, 255, 0.32);
      background: var(--color-bg-hover);
      color: var(--color-text);
    }
    .comp-watch-btn svg {
      width: 0.9rem;
      height: 0.9rem;
    }

    .comp-lb-empty {
      text-align: center;
      padding: 2rem 1rem;
      color: var(--color-text-muted);
    }
    .comp-lb-empty-icon {
      font-size: 2rem;
      margin-bottom: 0.5rem;
    }
    .comp-lb-empty-title {
      font-weight: 600;
      color: var(--color-text);
      margin: 0 0 0.25rem;
    }
    .comp-lb-empty-sub {
      font-size: 0.82rem;
      margin: 0;
    }

    /* -- Empty state (no competition) -- */
    .comp-empty-panel {
      padding: 2.5rem 1.5rem;
      border: 1px dashed rgba(255, 255, 255, 0.15);
      border-radius: 0.25rem;
      background: var(--color-bg-elevated);
      text-align: center;
      color: var(--color-text-muted);
    }

    /* Direct-child selector is critical: without the `>`, this rule also
       matches the icon inside any descendant button
       inside the "Join the Discord" btn-primary below), bumping that
       icon to 1.75rem + adding a 0.65rem bottom margin and breaking its
       alignment with the button's text. */
    .comp-empty-panel > i {
      display: block;
      font-size: 1.75rem;
      color: var(--color-text-muted);
      margin-bottom: 0.65rem;
    }
    .comp-empty-panel p { margin: 0; font-size: 0.95rem; }

.comp-empty-cta {
  margin-top: 1.25rem;
}

.comp-promo-external {
  margin-bottom: 1.25rem;
  width: 100%;
}

.comp-link-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.comp-art-card {
  padding: 0.5rem;
}

.comp-art-fallback {
  display: none;
  align-items: center;
  gap: 0.85rem;
  min-height: 8rem;
  padding: 1.1rem;
  border: 1px dashed rgba(255, 255, 255, 0.16);
  border-radius: 0.25rem;
  background: var(--color-bg);
  color: var(--color-text-muted);
}

.comp-art-card.is-missing-art .comp-art {
  display: none;
}

.comp-art-card.is-missing-art .comp-art-fallback {
  display: flex;
}

.comp-art-fallback i {
  flex: 0 0 auto;
  width: 2.5rem;
  height: 2.5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--color-bg-elevated);
  color: var(--color-icon);
}

.comp-art-fallback-title {
  margin: 0 0 0.15rem;
  color: var(--color-text);
  font-weight: 650;
}

.comp-art-fallback-text {
  margin: 0;
  font-size: 0.82rem;
  line-height: 1.5;
}

.comp-submit-copy {
  margin-bottom: 1rem;
}

.comp-submit-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.comp-full-width {
  width: 100%;
}

.comp-form-input[aria-invalid="true"] {
  border-color: rgba(248, 113, 113, 0.75);
}

.comp-alert--success {
  border-color: rgba(74, 222, 128, 0.3);
  background: rgba(74, 222, 128, 0.08);
}

.comp-alert--success .alert-icon {
  color: #4ade80;
}

.comp-submitted-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin-top: 0.75rem;
  color: var(--color-text);
  font-size: 0.86rem;
  font-weight: 650;
  text-decoration: none;
}

.comp-submitted-link:hover {
  color: var(--color-brand);
}

.comp-lb-scroll {
  overflow: visible;
}

@media (max-width: 640px) {
  .comp-wrap {
    padding: 1.75rem 1rem 2.25rem;
  }

  .comp-card {
    padding: 1rem;
  }

  .comp-form-meta {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.2rem;
  }

  .comp-lb-table tr {
    gap: 0.65rem;
    padding: 0.72rem 0;
  }

  .comp-reward-cell {
    font-size: 0.78rem;
  }

  .comp-watch-btn svg {
    width: 1rem;
    height: 1rem;
  }
}
