/* ============================================================
   EloureRP — Rules page. Loaded after the shared stylesheet: reuses
   --bg/--ink/--pink/--muted/--font-display/--font-body, everything else
   here is new and scoped to .rules to avoid touching anything shared.
   ============================================================ */

.rules {
  padding-top: 96px;
  position: relative;
  background-image: radial-gradient(ellipse 700px 420px at 50% 0%, rgba(43, 230, 200, 0.08), transparent 65%);
}

.rules__hero {
  max-width: 900px; margin: 0 auto; padding: 20px clamp(20px, 5vw, 64px) 40px;
  text-align: center;
}
.rules__kicker {
  display: inline-block;
  font-family: var(--font-mono, var(--font-body)); font-weight: 400;
  font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--pink); background: transparent;
  border: 1px solid rgba(43, 230, 200, 0.35);
  text-shadow: 0 0 8px var(--glow-teal, rgba(43, 230, 200, .4));
  border-radius: 3px; padding: 5px 14px; margin-bottom: 18px;
}
.rules__title {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(34px, 5vw, 58px); line-height: 1.05;
  color: var(--ink); margin: 0 0 14px;
}
.rules__lede { color: var(--muted); font-size: 15px; line-height: 1.6; max-width: 640px; margin: 0 auto 20px; }
.rules__stamp {
  display: inline-block;
  font-family: var(--font-display); font-weight: 700;
  font-size: 15px; letter-spacing: 0.16em; text-indent: 0.16em; text-transform: uppercase;
  color: #ff8091;
  border: 3px double #ff8091;
  border-radius: 8px;
  padding: 6px 16px;
  transform: rotate(-6deg);
  text-shadow: 0 0 8px rgba(255, 128, 145, 0.5);
  box-shadow: 0 0 20px rgba(255, 128, 145, 0.2);
}

.rules__layout {
  display: grid; grid-template-columns: 240px 1fr; gap: 48px;
  max-width: 1200px; margin: 0 auto; padding: 0 clamp(20px, 5vw, 64px) 100px;
  align-items: start;
}

.rules__toc {
  position: sticky; top: 96px;
  border: 1px solid rgba(247, 242, 238, 0.12);
  border-radius: 16px;
  padding: 20px;
  max-height: calc(100vh - 130px);
  overflow-y: auto;
}
.rules__tocTitle {
  font-family: var(--font-mono, var(--font-body));
  font-size: 10px; font-weight: 400; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--pink); margin-bottom: 12px;
}
.rules__toc a {
  display: block; font-size: 13.5px; color: var(--muted); text-decoration: none;
  padding: 6px 0; border-left: 2px solid transparent; padding-left: 10px;
  transition: color 0.2s, border-color 0.2s;
}
.rules__toc a:hover, .rules__toc a.is-active { color: var(--ink); border-left-color: var(--pink); }
.rules__toc .rules__tocSub a { font-size: 12.5px; padding-left: 20px; opacity: 0.85; }

.rules__content { min-width: 0; }
.rules__section {
  border-bottom: 1px solid rgba(247, 242, 238, 0.1);
  padding: 36px 0;
}
.rules__section:first-child { padding-top: 0; }
.rules__section h2 {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(22px, 2.6vw, 30px); color: var(--ink);
  margin: 0 0 16px;
  display: flex; align-items: center; gap: 10px;
}
.rules__section h3 {
  font-family: var(--font-display); font-weight: 700;
  font-size: 18px; color: var(--pink);
  margin: 28px 0 10px;
}
.rules__section p { color: var(--muted); font-size: 14.5px; line-height: 1.7; margin: 0 0 14px; }
.rules__section p strong, .rules__section li strong { color: var(--ink); }

.rules__list { margin: 0 0 14px; padding: 0; list-style: none; counter-reset: rulenum; }
.rules__list > li {
  counter-increment: rulenum;
  position: relative;
  padding: 10px 0 10px 40px;
  font-size: 14.5px; color: var(--muted); line-height: 1.6;
  border-top: 1px solid rgba(247, 242, 238, 0.06);
}
.rules__list > li:first-child { border-top: none; }
.rules__list > li::before {
  content: counter(rulenum);
  position: absolute; left: 0; top: 10px;
  width: 26px; height: 26px; border-radius: 8px;
  background: rgba(43, 230, 200, 0.12); color: var(--pink);
  border: 1px solid rgba(43, 230, 200, 0.3);
  text-shadow: 0 0 6px var(--glow-teal, rgba(43, 230, 200, .4));
  font-family: var(--font-mono, var(--font-body)); font-weight: 400; font-size: 11px;
  display: flex; align-items: center; justify-content: center;
}
.rules__list--plain { counter-reset: none; }
.rules__list--plain > li { padding-left: 20px; }
.rules__list--plain > li::before { content: "—"; background: none; width: auto; height: auto; color: var(--muted); font-weight: 400; }

.rules__sub { margin: 0 0 14px; padding-left: 20px; }
.rules__sub li { font-size: 14px; color: var(--muted); line-height: 1.6; margin-bottom: 6px; }

.rules__note {
  border-left: 3px solid var(--pink);
  background: rgba(43, 230, 200, 0.06);
  border-radius: 0 10px 10px 0;
  padding: 14px 18px;
  font-family: var(--font-mono, var(--font-body));
  font-size: 12.5px; color: var(--muted); line-height: 1.6;
  margin: 16px 0;
}
.rules__note strong { color: var(--pink); }

.rules__tableWrap { overflow-x: auto; margin: 16px 0 24px; border: 1px solid rgba(247, 242, 238, 0.12); border-radius: 12px; }
.rules__table { border-collapse: collapse; width: 100%; min-width: 900px; font-size: 12.5px; }
.rules__table th, .rules__table td {
  padding: 10px 12px; text-align: left; white-space: nowrap;
  border-bottom: 1px solid rgba(247, 242, 238, 0.08);
}
.rules__table th {
  font-family: var(--font-mono, var(--font-body)); font-weight: 400; letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--pink); background: rgba(43, 230, 200, 0.08);
  position: sticky; top: 0;
}
.rules__table td { color: var(--muted); }
.rules__table tr:last-child td { border-bottom: none; }

@media (max-width: 900px) {
  .rules__layout { grid-template-columns: 1fr; }
  .rules__toc { position: static; max-height: none; }
}
