.hero {
  text-align: center;
  padding: 3rem 1rem 2rem;
}
.hero-title {
  font-size: clamp(3rem, 8vw, 6rem);
  font-family: var(--font-d);
  color: var(--accent);
  text-shadow: 0 0 40px rgba(200,134,10,.4), 0 2px 0 #5a3800;
  letter-spacing: .1em;
  line-height: 1;
}
.hero-sub {
  color: var(--text-2);
  margin-top: .75rem;
  font-size: 1.1rem;
  letter-spacing: .05em;
}
.hero-deco {
  display: flex;
  justify-content: center;
  gap: .5rem;
  margin: 1.5rem 0;
}
.deco-tile {
  width: 48px; height: 48px;
  border-radius: var(--r-sm);
  border: 1px solid var(--tile-border);
  position: relative;
  overflow: hidden;
  opacity: .7;
}
.deco-tile .center { position: absolute; inset: 12px; border-radius: 2px; }
.deco-tile .edge-n { position: absolute; top:0; left:10px; right:10px; height:12px; border-radius: 0 0 2px 2px; }
.deco-tile .edge-s { position: absolute; bottom:0; left:10px; right:10px; height:12px; border-radius: 2px 2px 0 0; }
.deco-tile .edge-e { position: absolute; right:0; top:10px; bottom:10px; width:12px; border-radius: 2px 0 0 2px; }
.deco-tile .edge-w { position: absolute; left:0; top:10px; bottom:10px; width:12px; border-radius: 0 2px 2px 0; }

.main-container {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 1rem 2rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}
@media (max-width: 640px) {
  .main-container { grid-template-columns: 1fr; }
}

.join-section { }
.form-tabs { margin-bottom: 1.25rem; }
.form-group { display: flex; flex-direction: column; gap: .4rem; margin-bottom: 1rem; }
.form-group label { font-size: .875rem; color: var(--text-2); font-family: var(--font-d); letter-spacing: .04em; }
.form-group input { font-size: 1rem; }
.room-code-input {
  text-transform: uppercase;
  letter-spacing: .15em;
  font-size: 1.3rem;
  text-align: center;
  font-family: var(--font-d);
}

.stats-section {}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: .75rem;
  margin-bottom: 1.25rem;
}
.stat-item {
  text-align: center;
  padding: .75rem .5rem;
  background: var(--bg-3);
  border-radius: var(--r-md);
  border: 1px solid var(--border);
}
.stat-value {
  font-size: 1.5rem;
  font-family: var(--font-d);
  color: var(--accent);
}
.stat-label { font-size: .75rem; color: var(--text-2); margin-top: .2rem; }

.highscore-list { display: flex; flex-direction: column; gap: .4rem; }
.hs-entry {
  display: flex;
  align-items: center;
  gap: .75rem;
  padding: .4rem .75rem;
  background: var(--bg-3);
  border-radius: var(--r-sm);
}
.hs-rank { font-family: var(--font-d); color: var(--accent); width: 1.5rem; flex-shrink: 0; }
.hs-name { flex: 1; }
.hs-score { font-family: var(--font-d); color: var(--text-1); }

.rules-toggle {
  background: none;
  color: var(--accent);
  font-size: .9rem;
  padding: .4rem 0;
  text-decoration: underline;
  text-underline-offset: 3px;
  border: none;
}
.rules-box {
  background: var(--bg-3);
  border-radius: var(--r-md);
  padding: 1rem;
  font-size: .875rem;
  color: var(--text-2);
  margin-top: .5rem;
  line-height: 1.7;
}
.rules-box h4 { font-family: var(--font-d); color: var(--text-1); font-size: .9rem; margin: .5rem 0 .2rem; }
