/* =========================
   Core theme + layout
   ========================= */

:root{
  --bg:#0f1115;
  --card:#151923;
  --muted:#8a92a6;
  --text:#e6e9ef;
  --accent:#72a0ff;
  --accent-2:#61d4a8;
  --warn:#ffb86b;

  /* Brand tweaks for Reforged */
  --brand-orange:#f26b1d;
  --brand-amber:#ff8a2b;
  --brand-deep:#0b0d12;
}

*{
  box-sizing:border-box;
}

html,
body{
  margin:0;
  padding:0;
  background:var(--bg);
  color:var(--text);
  font:16px/1.55 system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, 'Helvetica Neue', Arial, 'Noto Sans', 'Apple Color Emoji','Segoe UI Emoji';
}

a{
  color:var(--accent);
  text-decoration:none;
}
a:hover{
  text-decoration:underline;
}

.container{
  max-width:1100px;
  margin:0 auto;
  padding:24px;
}

/* =========================
   Main nav + brand
   ========================= */

.nav{
  display:flex;
  gap:18px;
  align-items:center;
  justify-content:space-between;
  padding:16px 24px;
  border-bottom:1px solid #1e2430;
  background:#0e121a;
  position:sticky;
  top:0;
  z-index:10;
}

.brand{
  display:flex;
  gap:12px;
  align-items:center;
}

/* Logo in nav */
.brand .logo{
  width:28px;
  height:28px;
  border-radius:8px;
  background:linear-gradient(135deg,var(--accent),var(--accent-2));
  display:inline-block;
}

/* If using an actual image logo */
.brand img.logo-img{
  width:30px;
  height:30px;
  border-radius:6px;
  display:block;
}

.nav a{
  font-weight:600;
}

/* Center link group between brand and user menu */
.nav .links{
  display:flex;
  gap:24px;
  margin-left:auto;
  margin-right:auto;
}

/* Right side (user/login area) */
.nav-right{
  display:flex;
  align-items:center;
}

/* =========================
   Login pill (when logged out)
   ========================= */

.nav-login{
  color:#66fcf1;
  text-decoration:none;
  font-size:0.9rem;
  padding:6px 12px;
  border-radius:999px;
  border:1px solid #66fcf1;
  background:transparent;
}
.nav-login:hover{
  background:rgba(102,252,241,0.1);
}

/* =========================
   User dropdown
   ========================= */

.nav-user{
  position:relative;
  display:inline-flex;
  align-items:center;
  /* keeps the “gap” between pill and menu inside the hover area */
  padding-bottom:8px;
}

.nav-user-toggle{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:6px 14px;
  border-radius:999px;
  border:1px solid #2a2f3c;
  background:#05070d;
  color:#eee;
  font-size:0.85rem;
  cursor:pointer;
}
.nav-user-toggle:hover{
  border-color:#66fcf1;
}

.nav-user-avatar{
  width:22px;
  height:22px;
  border-radius:50%;
  object-fit:cover;
}

.nav-user-name{
  max-width:140px;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

.nav-user-caret{
  font-size:0.7rem;
  opacity:0.7;
}

.nav-user-menu{
  position:absolute;
  right:0;
  top:100%;
  margin-top:0;
  min-width:180px;
  padding:8px 0;
  background:#111319;
  border-radius:12px;
  border:1px solid #1f2833;
  box-shadow:0 12px 30px rgba(0,0,0,.6);
  opacity:0;
  transform:translateY(-4px);
  pointer-events:none;
  transition:opacity .15s ease, transform .15s ease;
  z-index:1000;
}

.nav-user-menu a{
  display:block;
  padding:8px 14px;
  font-size:0.9rem;
  color:#c5c6c7;
  white-space:nowrap;
  text-decoration:none;
}
.nav-user-menu a:hover{
  background:#1b1f28;
  color:#66fcf1;
}

/* Hover-based dropdown behaviour */
.nav-user:hover .nav-user-menu{
  opacity:1;
  transform:translateY(0);
  pointer-events:auto;
}

/* =========================
   Generic layout helpers
   ========================= */

.hero{
  padding:48px 0;
}

.grid{
  display:grid;
  grid-template-columns:repeat(auto-fill,minmax(260px,1fr));
  gap:16px;
  margin-top:28px;
}

/* Cards & badges used across the site */
.card{
  background:var(--card);
  border:1px solid #1e2430;
  border-radius:16px;
  padding:18px;
  box-shadow:0 8px 20px rgba(0,0,0,.4);
}
.card h3{
  margin:4px 0 8px 0;
}

.badge{
  display:inline-block;
  background:#1f2838;
  border:1px solid #273248;
  color:var(--muted);
  padding:2px 8px;
  border-radius:999px;
  font-size:12px;
}

.footer{
  border-top:1px solid #1e2430;
  color:var(--muted);
  padding:24px;
  margin-top:48px;
}

/* Buttons */
.btn{
  display:inline-block;
  padding:10px 14px;
  border-radius:10px;
  background:linear-gradient(135deg,var(--accent),#5b8dff);
  color:#0a0c12;
  font-weight:700;
}
.btn.secondary{
  background:#1b2230;
  color:var(--text);
  border:1px solid #263044;
}

/* Secondary button style */
.btn1{
  display:inline-block;
  padding:10px 14px;
  border-radius:10px;
  background:linear-gradient(135deg,#1b2230,#1b2230);
  font-weight:700;
}
.btn1.secondary{
  background:#1b2230;
  color:var(--text);
  border:1px solid #263044;
}
.btn1--primary{
  background:linear-gradient(90deg,var(--brand-2),var(--brand-2));
  color:#111;
  border-color:#000;
}

/* Two-column hero layout */
.kv{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:18px;
}
@media (max-width:800px){
  .kv{grid-template-columns:1fr;}
}

/* Table-of-contents layout */
.toc-wrap{
  display:grid;
  grid-template-columns:260px 1fr;
  gap:24px;
}
@media (max-width:1000px){
  .toc-wrap{grid-template-columns:1fr;}
  .toc{order:-1;}
}
.toc{
  position:sticky;
  top:78px;
  align-self:start;
  background:#101522;
  border:1px solid #1c2433;
  border-radius:14px;
  padding:12px;
}
.toc h4{
  margin:6px 0 10px 0;
}
.toc ul{
  list-style:none;
  padding:0;
  margin:0;
}
.toc li{
  margin:6px 0;
}

.hint{
  font-size:14px;
  color:var(--muted);
}

pre,
code{
  background:#0f1522;
  border:1px solid #1c283a;
  border-radius:8px;
  padding:2px 6px;
}

/* =========================
   Brand / hero sections
   ========================= */

.brand .logo{background:unset;} /* overridden by logo image above */

.hero-hero{
  background:
    radial-gradient(60% 60% at 60% 40%, rgba(242,107,29,0.12), transparent 60%),
    #0c0e13;
  padding:0;
}
.hero-banner{
  width:100%;
  display:block;
  border-bottom:1px solid #1e2430;
}

.section{
  padding:48px 0;
}
.section.dark{
  background:#0e1117;
  border-top:1px solid #1a1f2b;
  border-bottom:1px solid #1a1f2b;
}
.section h2{
  margin:0 0 12px 0;
}

/* Pills used in various sections */
.pills{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
}
.pill{
  background:#1b2230;
  border:1px solid #273248;
  border-radius:999px;
  padding:6px 10px;
  font-size:13px;
  color:var(--muted);
}

/* Generic “steps” / numbered blocks */
.steps{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(220px,1fr));
  gap:16px;
  margin-top:12px;
}
.step{
  display:flex;
  gap:10px;
  align-items:flex-start;
}

/* Layout rail: main + sidebar */
.rail{
  display:grid;
  grid-template-columns:2fr 1fr;
  gap:24px;
}
@media (max-width:900px){
  .rail{grid-template-columns:1fr;}
}

.cta{
  display:flex;
  gap:12px;
  flex-wrap:wrap;
  margin-top:8px;
}

.badge.wipe{
  background:#24160f;
  border:1px solid #3b2316;
  color:#ffb37a;
}

.statbox{
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(160px,1fr));
  gap:12px;
}
.stat{
  background:#111622;
  border:1px solid #1f2736;
  border-radius:12px;
  padding:12px;
}

.hero-title{
  font-size:40px;
  line-height:1.1;
  margin:18px 0 8px 0;
}
.subtitle{
  color:var(--muted);
}

/* Cards used as links to guides etc. */
.guide-card{
  display:block;
}

/* Footer CTA grid */
.footer-cta{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:18px;
}
@media (max-width:800px){
  .footer-cta{grid-template-columns:1fr;}
}

/* =========================
   Rules page numbering
   ========================= */

.rules{
  margin:0;
  padding-left:2rem;              /* indent for section numbers */
  list-style:decimal;
  counter-reset:section;
}
.rules > li{
  margin:1.5rem 0 2rem;
  counter-increment:section;
}

/* Section title <h2> inside rules */
.section-title{
  margin:0 0 0.5rem;
  font-size:1.6rem;
  line-height:1.2;
  font-weight:800;
}

/* Custom sub-rule numbering 1.1, 1.2, etc. */
.subrules{
  list-style:none;
  margin:0;
  padding-left:2.5rem;
  counter-reset:subrule;
}
.subrules > li{
  counter-increment:subrule;
  position:relative;
  margin:0.35rem 0;
}
.subrules > li::before{
  content:counter(section) "." counter(subrule) ". ";
  position:absolute;
  left:0;
  width:2.2rem;
  font-weight:700;
  opacity:0.9;
}

/* Style for top-level markers */
.rules > li::marker{
  font-weight:800;
}

/* =========================
   Voting page
   ========================= */

.hero--vote{
  padding-top:40px;
  padding-bottom:52px;
  border-bottom:1px solid #1e2430;
}

/* Slightly smaller title in voting hero */
.hero--vote .hero-title{
  font-size:32px;
}

.hero-subtitle{
  margin:0 0 6px 0;
  max-width:600px;
}

.hero-hint{
  margin:0;
  font-size:14px;
  color:var(--muted);
}

.vote-section{
  margin-top:32px;
}

.section-label{
  display:inline-block;
  padding:4px 12px;
  border-radius:999px;
  background:#151b29;
  border:1px solid #222b3b;
  font-size:11px;
  letter-spacing:0.16em;
  text-transform:uppercase;
  color:var(--muted);
  margin-bottom:16px;
}

.vote-grid .card{
  display:flex;
  flex-direction:column;
  gap:6px;
  transition:
    transform 0.18s ease,
    box-shadow 0.18s ease,
    border-color 0.18s ease;
}
.vote-grid .card:hover{
  transform:translateY(-4px);
  box-shadow:0 18px 40px rgba(0,0,0,0.65);
  border-color:var(--accent);
}

.vote-card .badge{
  border-color:#2f3b52;
  color:var(--accent);
}
.vote-card h3{
  margin-top:6px;
}
.vote-card .btn{
  margin-top:8px;
  align-self:flex-start;
}

/* Step number bubble used on vote page */
.step-number{
  flex-shrink:0;
  width:32px;
  height:32px;
  border-radius:999px;
  background:linear-gradient(135deg,var(--accent),var(--accent-2));
  display:flex;
  align-items:center;
  justify-content:center;
  font-weight:700;
  font-size:14px;
  color:#0b0d13;
  margin-top:2px; /* visually centers number against heading */
}

/* Facts list */
.facts{
  margin:8px 0 0 0;
  padding-left:20px;
  color:var(--accent-2);
  font-size:14px;
}
.facts li + li{
  margin-top:4px;
}

/* =========================
   Dashboard-specific bits
   ========================= */

.dash-shell{
  max-width:1100px;
  margin:24px auto 40px;
  padding:0 20px 40px;
}

.dash-header{
  display:flex;
  align-items:center;
  gap:16px;
  margin-bottom:24px;
}

.dash-header-avatar{
  width:64px;
  height:64px;
  border-radius:50%;
  object-fit:cover;
  box-shadow:0 0 0 2px #1f2833;
}

.dash-header-main{
  display:flex;
  flex-direction:column;
  gap:4px;
}

.dash-header-main h1{
  margin:0;
  font-size:1.6rem;
}

.dash-header-main small{
  color:#a9a9a9;
  font-size:0.8rem;
}

/* Role tagline under SteamID */
.role-tagline{
  margin-top:4px;
  font-size:0.85rem;
  color:#9da1aa;
}

/* Dashboard grid */
.dash-grid{
  display:grid;
  grid-template-columns:minmax(0,2fr) minmax(0,3fr);
  gap:20px;
}
@media (max-width:800px){
  .dash-grid{grid-template-columns:1fr;}
  .dash-header{flex-wrap:wrap;}
}

/* Slightly different card heading / text sizes on dashboard */
.card h2{
  margin-top:0;
  margin-bottom:8px;
  font-size:1.1rem;
}
.card p{
  margin-top:0;
  margin-bottom:8px;
  font-size:0.9rem;
  color:#c5c6c7;
}

.card ul{
  list-style:none;
  padding-left:0;
  margin:8px 0 0;
  font-size:0.9rem;
}
.card ul li{
  margin-bottom:6px;
}
.card ul li a{
  color:#66fcf1;
  text-decoration:none;
}
.card ul li a:hover{
  text-decoration:underline;
}

/* Muted helper text (used under cards) */
.muted{
  color:#9da1aa;
  font-size:0.8rem;
}

/* Pill-style links in dashboard cards */
.pill-links{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  margin-top:8px;
}
.pill-links a{
  display:inline-block;
  padding:4px 10px;
  border-radius:999px;
  border:1px solid #1f2833;
  background:#0f1118;
  color:#c5c6c7;
  font-size:0.8rem;
  text-decoration:none;
}
.pill-links a:hover{
  border-color:#66fcf1;
  color:#66fcf1;
}

.trigger-more-btn {
    background: none;
    border: none;
    padding: 0;
    margin: 2px 0 0 0;
    font-size: 0.75rem;      /* smaller text */
    line-height: 1;          /* no extra height */
    color: #72a0ff;          /* your accent color */
    cursor: pointer;
}

.trigger-more-btn:hover {
    text-decoration: underline;
}