/* Site-wide legal footer: logo (no background), copyright, terms link */

.site-foot {
  border-top: 1px solid var(--line, rgba(255, 255, 255, 0.08));
  padding: 1.25rem clamp(1rem, 4vw, 2rem) 1.5rem;
  margin-top: auto;
}

.site-foot__inner {
  max-width: var(--max, 70rem);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem 1rem;
  text-align: center;
  font-size: 0.8rem;
  color: var(--ink-muted, #a1a1aa);
}

@media (min-width: 640px) {
  .site-foot__inner {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    text-align: left;
  }
}

.site-foot__mark {
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 0;
  flex-shrink: 0;
}

.site-foot__logo {
  display: block;
  width: 28px;
  height: 28px;
  object-fit: contain;
}

.site-foot__copy {
  margin: 0;
  line-height: 1.4;
  color: var(--ink-muted, #a1a1aa);
}

.site-foot__terms {
  color: var(--ink-paper, #e4e4e7);
  text-decoration: underline;
  text-underline-offset: 3px;
  font-weight: 500;
  white-space: nowrap;
}

.site-foot__terms:hover {
  color: var(--link-hover, #f472b6);
}

/* Marketing (index) — :root in index provides --mute, --link, --paper; optional override: */
.index-page .site-foot {
  --ink-muted: var(--mute, #9ca3af);
  --ink-paper: var(--paper, #f4f4f5);
}

/* Auth pages */
.auth-body .site-foot {
  margin-top: 2rem;
  padding-bottom: 2rem;
  border-top: 1px solid var(--line);
  --ink-muted: #a1a1aa;
  --ink-paper: #e4e4e7;
  --line: rgba(255, 255, 255, 0.1);
  --link-hover: #f472b6;
}

/* Dashboard: pin footer below scroll area */
.dash-content .site-foot,
.dash-panel .site-foot {
  margin-top: 2.5rem;
  padding: 1.25rem 1.25rem 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  --ink-muted: #9ca3af;
  --ink-paper: #e4e4e7;
  --link-hover: #f472b6;
  --line: rgba(255, 255, 255, 0.08);
  --max: none;
}

/* Public / 404 */
.public-page .public-shell .site-foot {
  margin-top: 2rem;
  --ink-muted: #a1a1aa;
  --ink-paper: #d4d4d8;
  --line: rgba(255, 255, 255, 0.08);
  --link-hover: #f472b6;
  --max: 32rem;
}

/* Terms of service document */
.terms-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.terms-page .auth-page,
.terms-page main {
  flex: 1;
}
.terms-doc {
  max-width: 40rem;
  margin: 0 auto;
  padding: 0 0 2rem;
  color: var(--ink-paper, #e4e4e7);
  font-size: 0.92rem;
  line-height: 1.65;
}
.terms-doc h1 {
  font-family: var(--display, "Syne", sans-serif);
  font-size: 1.5rem;
  font-weight: 800;
  margin: 0 0 0.5rem;
  color: #fafafa;
}
.terms-doc p {
  margin: 0.75rem 0;
  color: #c4c4c8;
}
.terms-doc h2 {
  font-size: 1.05rem;
  font-weight: 700;
  margin: 1.5rem 0 0.5rem;
  color: #e4e4e7;
}
.terms-lead {
  font-size: 0.9rem;
  color: #a1a1aa;
  margin: 0 0 1.25rem;
}

/* Marketing header: full-bleed bar, don’t squish LOG IN / START / Discord */
.site-top {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  left: 0;
  right: 0;
}
.site-top__inner {
  min-width: 0;
}
@media (min-width: 900px) {
  .site-top__end {
    flex-wrap: nowrap;
  }
}
.site-top .mark,
.site-top .actions,
.site-top__end {
  flex-shrink: 0;
}
.site-top .actions .btn,
.site-top__end .actions .btn {
  flex-shrink: 0;
  white-space: nowrap;
}

/* Marketing nav: underlined text links (no pill chrome) */
.site-top .nav {
  flex-wrap: wrap;
  align-items: center;
  align-content: center;
  row-gap: 0.4rem;
  column-gap: 0.65rem;
}
.site-top .nav a.nav__link {
  display: inline;
  box-sizing: border-box;
  padding: 0;
  margin: 0;
  font-size: 0.68rem;
  font-weight: 600;
  line-height: 1.4;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  text-decoration: underline;
  text-decoration-color: rgba(244, 63, 94, 0.55);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.25em;
  color: #9ca3af;
  color: var(--mute, #9ca3af);
  border: none;
  border-radius: 0;
  background: none;
  transition: color 0.2s, text-decoration-color 0.2s;
}
.site-top .nav a.nav__link:hover {
  color: #fda4af;
  color: var(--link-hover, #fda4af);
  text-decoration-color: rgba(251, 113, 133, 0.95);
}
.site-top .nav a.nav__link[aria-current="page"] {
  color: #f4f4f5;
  color: var(--paper, #f4f4f5);
  text-decoration-color: #f43f5e;
  text-decoration-thickness: 2px;
  pointer-events: none;
}

.site-top .site-top__end {
  align-items: center;
}
.site-top .site-top__end > .actions,
.site-top .site-top__end > .site-discord,
.site-top .site-top__end > .burger {
  align-self: center;
}

/* Mobile drawer section links as bordered controls (not bare text) */
.site-top .drawer a.drawer__nav {
  display: flex;
  align-items: center;
  box-sizing: border-box;
  width: calc(100% - 1.7rem);
  margin: 0.35rem 0.85rem 0;
  padding: 0.7rem 0.85rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--btn-radius, 0.5rem);
  background: rgba(255, 255, 255, 0.04);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-decoration: none;
  color: #9ca3af;
  color: var(--mute, #9ca3af);
  transition: background 0.2s, border-color 0.2s, color 0.2s;
}
.site-top .drawer a.drawer__nav:first-of-type {
  margin-top: 0.65rem;
}
.site-top .drawer a.drawer__nav:hover {
  color: #fda4af;
  color: var(--link-hover, #fda4af);
  border-color: rgba(244, 63, 94, 0.35);
}
.site-top .drawer a.drawer__nav[aria-current="page"] {
  color: #f4f4f5;
  color: var(--paper, #f4f4f5);
  border-color: rgba(244, 63, 94, 0.45);
  background: rgba(244, 63, 94, 0.12);
}

/* Mobile hamburger menu: space below last actions (Log in / Start) and home indicator */
@media (max-width: 899px) {
  .site-top .drawer {
    box-sizing: border-box;
    padding-bottom: max(1.75rem, calc(env(safe-area-inset-bottom, 0px) + 1.15rem));
  }
  /* Section links (drawer__nav) use margin; CTAs are full-bleed a.btn and only had 1px border — add real vertical rhythm */
  .site-top .drawer > a.btn.btn-discord {
    margin-top: 0.75rem;
  }
  .site-top .drawer > a.btn + a.btn,
  .site-top .drawer > a.btn + .btn-start-wrap {
    margin-top: 0.6rem;
  }
  .site-top .drawer > .btn-start-wrap {
    display: block;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    padding: 0 0.85rem;
  }
  .site-top .drawer > .btn-start-wrap .btn.btn-fill {
    display: flex;
    width: 100%;
    box-sizing: border-box;
    justify-content: center;
  }
}

/* Start CTA when registration is closed */
.btn-start-wrap {
  position: relative;
  display: inline-flex;
  flex-shrink: 0;
  align-items: center;
  vertical-align: middle;
}
.btn-start-wrap .btn.btn-fill {
  pointer-events: none;
  cursor: not-allowed;
  opacity: 0.9;
}
.btn-start-soon {
  position: absolute;
  top: -0.4rem;
  right: -0.15rem;
  z-index: 2;
  padding: 0.12rem 0.38rem;
  font-size: 0.5rem;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #fff;
  background: linear-gradient(140deg, #fda4af, #e11d48 90%);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 0.25rem;
  transform: rotate(10deg);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35);
  white-space: nowrap;
  pointer-events: none;
}
.btn-start-wrap--block {
  display: flex;
  max-width: 100%;
  box-sizing: border-box;
}
.btn-start-wrap--block .btn {
  flex: 1;
  justify-content: center;
  text-align: center;
}
.btn-start-wrap--block .btn-start-soon {
  right: 0.35rem;
  top: -0.5rem;
}
.btn-start-wrap--block .btn.btn-fill {
  opacity: 0.9;
}
