/* Phoenix AI — /terms/ (direct-URL only until blessed) */
:root {
  --ink: #090909;
  --cream: #f8f4e9;
  --cream-muted: #c8c0b4;
  --purple: #6B4FC8;
  --purple-light: #E0D0FF;
  --sky: #5A9FD8;
  --wine: #A81830;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --pad-x: clamp(1.25rem, 3vw, 2.5rem);
  --shell-max: 63rem;
  --rule: rgba(248, 244, 233, 0.12);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  min-height: 100%;
  background: var(--ink);
  color: var(--cream);
  font-family: "Plus Jakarta Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  scroll-behavior: smooth;
}

.terms-world {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 42% 48% at 12% 28%, rgba(107, 79, 200, 0.16), transparent 60%),
    radial-gradient(ellipse 50% 46% at 88% 42%, rgba(74, 127, 212, 0.14), transparent 64%),
    url("../assets/world-bc-datacenter.jpg?v=1789147200") 82% 38% / cover no-repeat,
    #090909;
  filter: brightness(0.88) contrast(1.06) saturate(1.04);
}

.terms-veil {
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    linear-gradient(
      105deg,
      rgba(9, 9, 9, 0.92) 0%,
      rgba(9, 9, 9, 0.86) 36%,
      rgba(9, 9, 9, 0.72) 62%,
      rgba(9, 9, 9, 0.55) 100%
    ),
    linear-gradient(
      180deg,
      rgba(9, 9, 9, 0.55) 0%,
      rgba(9, 9, 9, 0.25) 14%,
      rgba(9, 9, 9, 0.4) 60%,
      rgba(9, 9, 9, 0.92) 100%
    );
}

.terms-shell {
  position: relative;
  z-index: 2;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}

.terms-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: 100%;
  margin: 0;
  padding: 1rem var(--pad-x);
  box-sizing: border-box;
}

.terms-top__brand {
  display: block;
  line-height: 0;
  --lockup-w: clamp(9.5rem, 22vw, 12.5rem);
  margin-left: calc(var(--lockup-w) * -37 / 623);
}

.terms-top__brand img {
  display: block;
  width: var(--lockup-w);
  height: auto;
  filter: drop-shadow(0 8px 24px rgba(74, 40, 160, 0.35));
}

.terms-top__nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 1.1rem 1.35rem;
}

.terms-top__nav a {
  font-size: 0.78rem;
  font-weight: 650;
  letter-spacing: 0.01em;
  text-decoration: none;
  color: var(--cream);
  border-bottom: 1px solid color-mix(in srgb, var(--sky) 45%, transparent);
  padding-bottom: 1px;
  transition: color 0.2s var(--ease-out), border-color 0.2s var(--ease-out);
}

.terms-top__nav a:hover,
.terms-top__nav a:focus-visible {
  color: var(--purple-light);
  border-bottom-color: color-mix(in srgb, var(--purple) 55%, transparent);
  outline: none;
}

.terms-main {
  width: min(100%, calc(var(--shell-max) + 2 * var(--pad-x)));
  margin: 0 auto;
  padding: 1.25rem var(--pad-x) 4rem;
  flex: 1;
}

.terms-kicker {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--sky);
  margin-bottom: 0.75rem;
}

.terms-main h1 {
  font-size: clamp(1.75rem, 4vw, 2.35rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.15;
  margin-bottom: 0.55rem;
}

.terms-lede {
  font-size: 0.92rem;
  line-height: 1.5;
  color: var(--cream-muted);
  margin: 0 0 1.75rem;
}

.terms-draft {
  margin: 0 0 1.75rem;
  padding: 0.85rem 1rem;
  border-radius: 10px;
  border: 1px solid color-mix(in srgb, var(--wine) 55%, var(--rule));
  background: color-mix(in srgb, var(--wine) 14%, rgba(17, 17, 17, 0.85));
  color: var(--cream);
  font-size: 0.92rem;
  line-height: 1.45;
  font-weight: 550;
}

.terms-section {
  margin: 0 0 1.65rem;
  padding: 1.35rem 1.4rem 1.45rem;
  background: rgba(17, 17, 17, 0.72);
  border: 1px solid var(--rule);
  border-radius: 12px;
}

.terms-section h2 {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--purple-light);
  margin-bottom: 0.75rem;
}

.terms-section p,
.terms-section li {
  font-size: 0.98rem;
  line-height: 1.65;
  color: color-mix(in srgb, var(--cream) 92%, var(--cream-muted));
}

.terms-section p + p { margin-top: 0.85rem; }

.terms-section ul {
  margin: 0.7rem 0 0 1.15rem;
}

.terms-section li { margin: 0.45rem 0; }

.terms-section a {
  color: var(--sky);
  text-decoration: none;
  border-bottom: 1px solid color-mix(in srgb, var(--sky) 40%, transparent);
}

.terms-section a:hover,
.terms-section a:focus-visible {
  color: var(--purple-light);
  border-bottom-color: color-mix(in srgb, var(--purple) 50%, transparent);
  outline: none;
}

.terms-meta {
  font-size: 0.82rem;
  color: var(--cream-muted);
  margin-top: 0.45rem;
}

.terms-foot {
  width: min(100%, calc(var(--shell-max) + 2 * var(--pad-x)));
  margin: 0 auto;
  padding: 0.5rem var(--pad-x) 2.5rem;
  color: var(--cream-muted);
  font-size: 0.78rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem 0.55rem;
}
.terms-foot__pipe {
  opacity: 0.55;
}
.terms-foot a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid color-mix(in srgb, var(--sky) 45%, transparent);
  padding-bottom: 0.08rem;
  transition: color 0.25s ease, border-color 0.25s ease;
}
.terms-foot a:hover,
.terms-foot a:focus-visible {
  color: var(--sky);
  border-bottom-color: var(--sky);
  outline: none;
}

@media (max-width: 640px) {
  .terms-top {
    flex-direction: column;
    align-items: flex-start;
  }
  .terms-top__nav {
    justify-content: flex-start;
  }
  .terms-main {
    padding: 1rem var(--pad-x) 3rem;
  }
  .terms-lede {
    margin-bottom: 1.35rem;
  }
  .terms-section {
    margin-bottom: 1.25rem;
    padding: 1.15rem 1.1rem 1.2rem;
  }
  .terms-section p,
  .terms-section li {
    font-size: 0.95rem;
    line-height: 1.6;
  }
}
