:root {
  color-scheme: dark;
  --page: #0f172a;
  --page-deep: #0b1120;
  --surface: #172033;
  --surface-soft: rgba(30, 41, 59, 0.92);
  --text: #f8fafc;
  --muted: #cbd5e1;
  --accent: #38bdf8;
  --accent-light: #7dd3fc;
  --border: #475569;
  --focus: #fbbf24;
  --shadow: rgba(0, 0, 0, 0.35);
}

* {
  box-sizing: border-box;
}

html {
  font-size: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  background: linear-gradient(145deg, var(--page) 0%, var(--page-deep) 100%);
  color: var(--text);
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.65;
}

a {
  color: var(--accent-light);
  text-decoration-thickness: 0.12em;
  text-underline-offset: 0.18em;
}

a:hover {
  color: #bae6fd;
  text-decoration-thickness: 0.18em;
}

a:focus-visible {
  border-radius: 0.25rem;
  outline: 0.2rem solid var(--focus);
  outline-offset: 0.2rem;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -5rem;
  z-index: 20;
  background: var(--text);
  color: var(--page-deep);
  font-weight: 700;
  padding: 0.75rem 1rem;
}

.skip-link:focus {
  top: 1rem;
}

.page-container {
  width: min(94%, 64rem);
  margin: 0 auto;
  padding: 2rem 0;
}

.hero {
  margin: 0 auto 1.5rem;
  max-width: 52rem;
  text-align: center;
}

.brand {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  color: var(--accent);
  font-size: clamp(1.55rem, 4vw, 2.3rem);
  font-weight: 750;
  letter-spacing: 0.02em;
  text-decoration: none;
}

.eyebrow {
  margin: 0.75rem 0 0;
  color: var(--accent-light);
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero h1,
.prose h1 {
  color: var(--text);
  font-size: clamp(2rem, 5vw, 3.25rem);
  line-height: 1.12;
  margin: 0.35rem 0 0.8rem;
}

.hero > p:not(.eyebrow) {
  color: var(--muted);
  font-size: 1.1rem;
  margin: 0 auto;
  max-width: 48rem;
}

.chat-container {
  height: 64vh;
  min-height: 31.25rem;
  overflow: hidden;
  background: #ffffff;
  border: 0.125rem solid var(--border);
  border-radius: 1rem;
  box-shadow: 0 1rem 2.5rem var(--shadow);
}

.privacy-note {
  margin: 0 0 1rem;
  padding: 0.9rem 1rem;
  color: var(--text);
  background: var(--surface-soft);
  border-left: 0.3rem solid var(--accent);
  border-radius: 0.4rem;
}

iframe {
  width: 100%;
  height: 100%;
  border: 0;
  background: #ffffff;
}

.notice,
.prose {
  margin-top: 1.5rem;
  padding: clamp(1.25rem, 3vw, 2rem);
  background: var(--surface-soft);
  border: 0.0625rem solid var(--border);
  border-radius: 0.85rem;
  box-shadow: 0 0.7rem 1.8rem var(--shadow);
}

.notice h2,
.prose h2 {
  color: var(--accent-light);
  line-height: 1.25;
  margin: 0 0 0.65rem;
}

.notice p:last-child,
.prose > :last-child {
  margin-bottom: 0;
}

.prose {
  max-width: 52rem;
  margin-left: auto;
  margin-right: auto;
}

.prose h2 {
  margin-top: 2rem;
}

.prose li + li {
  margin-top: 0.55rem;
}

.effective-date {
  color: var(--muted);
  font-weight: 600;
}

code {
  color: #e0f2fe;
}

.site-footer {
  margin-top: 1.5rem;
  padding: 1.25rem;
  background: var(--surface);
  border: 0.0625rem solid var(--border);
  border-radius: 0.85rem;
  color: var(--muted);
  text-align: center;
}

.site-footer ul {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem 1rem;
  padding: 0;
  margin: 0;
  list-style: none;
}

.site-footer a {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  padding: 0.25rem;
  font-weight: 700;
}

.site-footer p {
  margin: 0.8rem 0 0;
}

@media (max-width: 40rem) {
  .page-container {
    width: min(96%, 38rem);
    padding: 1rem 0;
  }

  .chat-container {
    min-height: 28rem;
  }

  .site-footer ul {
    align-items: stretch;
    flex-direction: column;
  }

  .site-footer a {
    justify-content: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
  }
}

@media (forced-colors: active) {
  .chat-container,
  .notice,
  .prose,
  .site-footer {
    border: 0.125rem solid CanvasText;
  }
}
