:root {
  color-scheme: dark;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #101418;
  color: #f8fafc;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: #101418;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

.home-shell {
  min-height: 100vh;
}

.hero {
  isolation: isolate;
  min-height: 88vh;
  overflow: hidden;
  padding: 28px clamp(20px, 5vw, 64px) 56px;
  position: relative;
}

.hero-media {
  background:
    linear-gradient(90deg, rgba(16, 20, 24, 0.94) 0%, rgba(16, 20, 24, 0.78) 44%, rgba(16, 20, 24, 0.34) 100%),
    linear-gradient(180deg, rgba(16, 20, 24, 0.12) 0%, #101418 100%),
    url('./host/host-bg.jpg') center/cover no-repeat;
  inset: 0;
  position: absolute;
  z-index: -1;
}

.home-nav {
  align-items: center;
  display: flex;
  justify-content: space-between;
  margin: 0 auto;
  max-width: 1180px;
}

.brand {
  align-items: center;
  color: #f8c537;
  display: flex;
  font-size: 22px;
  gap: 10px;
  font-weight: 900;
}

.brand img {
  background: rgba(248, 250, 252, 0.96);
  border: 1px solid rgba(248, 250, 252, 0.72);
  border-radius: 8px;
  display: block;
  flex: 0 0 auto;
  height: 64px;
  max-height: 96px;
  max-width: 96px;
  object-fit: contain;
  padding: 4px;
  width: 64px;
}

.nav-actions {
  display: flex;
  gap: 12px;
}

.nav-actions a {
  border: 1px solid rgba(203, 213, 225, 0.32);
  border-radius: 8px;
  color: #f8fafc;
  font-weight: 800;
  padding: 10px 16px;
}

.hero-content {
  align-items: start;
  display: grid;
  gap: 22px;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 380px);
  margin: 12vh auto 0;
  max-width: 1180px;
}

.hero-main {
  display: grid;
  gap: 22px;
}

.eyebrow {
  color: #8bd3dd;
  font-size: 14px;
  font-weight: 900;
  letter-spacing: 0;
  margin: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1 {
  font-size: clamp(44px, 7vw, 92px);
  letter-spacing: 0;
  line-height: 0.96;
  max-width: 980px;
}

.explore-panel {
  background: rgba(17, 24, 39, 0.82);
  border: 1px solid rgba(71, 85, 105, 0.78);
  border-radius: 8px;
  display: grid;
  gap: 16px;
  padding: 18px;
}

.explore-panel h2 {
  font-size: 28px;
  line-height: 1;
  margin-top: 6px;
}

.featured-profiles {
  display: grid;
  gap: 10px;
}

.featured-card {
  background: #1f2937;
  border: 1px solid #334155;
  border-radius: 8px;
  display: grid;
  gap: 8px;
  padding: 14px;
}

.featured-card:hover {
  border-color: #f8c537;
}

.featured-card-top {
  align-items: center;
  display: flex;
  gap: 10px;
}

.featured-logo {
  background: #f8fafc;
  border-radius: 6px;
  display: none;
  height: 42px;
  object-fit: contain;
  padding: 4px;
  width: 42px;
}

.featured-logo.active {
  display: block;
}

.featured-card strong {
  color: #f8fafc;
  display: block;
  font-size: 17px;
}

.featured-card p,
.featured-empty {
  color: #cbd5e1;
  font-size: 14px;
  line-height: 1.45;
}

.featured-card span {
  color: #8bd3dd;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.hero-copy {
  color: #cbd5e1;
  font-size: clamp(18px, 2.1vw, 24px);
  font-weight: 700;
  line-height: 1.45;
  max-width: 720px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.primary-link,
.secondary-link,
.pin-form button {
  border: 0;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 900;
  min-height: 56px;
  padding: 16px 22px;
}

.primary-link,
.pin-form button {
  background: #f8c537;
  color: #111827;
}

.secondary-link {
  background: #1f2937;
  border: 1px solid #475569;
  color: #f8fafc;
}

.pin-form {
  display: grid;
  gap: 8px;
  margin-top: 8px;
  max-width: 520px;
}

.pin-form label {
  color: #cbd5e1;
  font-size: 14px;
  font-weight: 800;
  text-transform: uppercase;
}

.pin-form div {
  display: grid;
  gap: 10px;
  grid-template-columns: 1fr auto;
}

.pin-form input {
  background: #111827;
  border: 1px solid #475569;
  border-radius: 8px;
  color: #f8fafc;
  font-size: 22px;
  font-weight: 900;
  min-height: 56px;
  padding: 0 16px;
}

.pin-message {
  color: #fca5a5;
  min-height: 20px;
}

.quick-links {
  display: grid;
  gap: 1px;
  grid-template-columns: repeat(3, 1fr);
  background: #334155;
}

.link-panel {
  background: #111827;
  display: grid;
  gap: 8px;
  min-height: 170px;
  padding: clamp(24px, 5vw, 56px);
}

.link-panel span {
  color: #8bd3dd;
  font-size: 14px;
  font-weight: 900;
  text-transform: uppercase;
}

.link-panel strong {
  font-size: clamp(26px, 4vw, 46px);
  line-height: 1.05;
}

.host-panel {
  border-top: 6px solid #f8c537;
}

.play-panel {
  border-top: 6px solid #38bdf8;
}

.register-panel {
  border-top: 6px solid #22c55e;
}

.account-section {
  align-items: start;
  display: grid;
  gap: 34px;
  grid-template-columns: minmax(0, 0.85fr) minmax(360px, 1fr);
  margin: 0 auto;
  max-width: 1180px;
  padding: 72px clamp(20px, 5vw, 64px) 24px;
}

.account-copy {
  display: grid;
  gap: 18px;
}

.account-copy h2 {
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1;
}

.account-copy p {
  color: #cbd5e1;
  font-size: 18px;
  line-height: 1.55;
}

.host-register-link {
  justify-self: start;
}

.account-panel {
  background: #111827;
  border: 1px solid #334155;
  border-radius: 8px;
  padding: 18px;
}

.player-auth-forms {
  display: grid;
  gap: 16px;
  grid-template-columns: 1fr 1fr;
}

.account-form {
  display: grid;
  gap: 10px;
}

.account-form h3,
.player-account-summary h3 {
  font-size: 24px;
}

.account-form input {
  background: #1f2937;
  border: 1px solid #475569;
  border-radius: 8px;
  color: #f8fafc;
  min-height: 48px;
  padding: 0 12px;
}

.account-form button,
#player-logout {
  background: #f8c537;
  border: 0;
  border-radius: 8px;
  color: #111827;
  cursor: pointer;
  font-weight: 900;
  min-height: 48px;
  padding: 0 16px;
}

.account-message {
  color: #fca5a5;
  font-size: 14px;
  min-height: 20px;
}

.player-account-summary {
  display: none;
  gap: 18px;
}

.player-account-summary.active {
  display: grid;
}

.summary-head {
  align-items: center;
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.player-games {
  display: grid;
  gap: 10px;
}

.player-game-card {
  background: #1f2937;
  border: 1px solid #334155;
  border-radius: 8px;
  display: grid;
  gap: 6px;
  padding: 14px;
}

.player-game-card strong {
  font-size: 18px;
}

.player-game-card span,
.player-games-empty {
  color: #cbd5e1;
  font-size: 14px;
}

.feature-band {
  display: grid;
  gap: 34px;
  margin: 0 auto;
  max-width: 1180px;
  padding: 72px clamp(20px, 5vw, 64px);
}

.feature-band h2 {
  font-size: clamp(34px, 5vw, 60px);
  line-height: 1;
  margin-top: 8px;
}

.feature-grid {
  display: grid;
  gap: 1px;
  grid-template-columns: repeat(4, 1fr);
}

.feature-grid article {
  background: #1f2937;
  border: 1px solid #334155;
  min-height: 210px;
  padding: 22px;
}

.feature-grid h3 {
  color: #f8fafc;
  font-size: 22px;
  margin-bottom: 12px;
}

.feature-grid p {
  color: #cbd5e1;
  font-size: 16px;
  line-height: 1.55;
}

.not-found-shell {
  align-items: center;
  background:
    linear-gradient(90deg, rgba(16, 20, 24, 0.96), rgba(16, 20, 24, 0.72)),
    url('./host/host-bg.jpg') center/cover no-repeat;
  display: flex;
  min-height: 100vh;
  padding: clamp(20px, 5vw, 64px);
}

.not-found-panel {
  display: grid;
  gap: 22px;
  max-width: 820px;
}

.not-found-panel h1 {
  font-size: clamp(46px, 7vw, 88px);
}

.not-found-panel p {
  color: #cbd5e1;
  font-size: clamp(18px, 2.2vw, 24px);
  font-weight: 700;
  line-height: 1.45;
  max-width: 700px;
}

@media (max-width: 820px) {
  .hero {
    min-height: 92vh;
  }

  .home-nav {
    align-items: flex-start;
    gap: 14px;
  }

  .hero-content {
    margin-top: 10vh;
    grid-template-columns: 1fr;
  }

  .quick-links,
  .feature-grid,
  .account-section,
  .player-auth-forms {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  .brand img {
    height: 52px;
    width: 52px;
  }

  .nav-actions a {
    padding: 9px 12px;
  }

  .pin-form div {
    grid-template-columns: 1fr;
  }

  .pin-form button {
    width: 100%;
  }
}
