:root {
  /* Sampled from the SorAI app icon: deep navy canvas, ice-blue to lavender mascot. */
  --bg0: #050814;
  --surface-2: #141a2c;
  --surface-3: #1c2438;
  --text: #ffffff;
  --muted: #8e8e93;
  --accent: #9fe4ff;
  --accent-end: #c9b6ff;
  --accent-ink: #061018;
  --glow: rgba(110, 180, 255, 0.22);
  --radius: 20px;
  --radius-group: 26px;
  --radius-pill: 999px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

html,
body {
  margin: 0;
  min-height: 100%;
  color: var(--text);
  font-family: var(--font);
  background: var(--bg0);
  -webkit-font-smoothing: antialiased;
}

body {
  position: relative;
  overflow-x: hidden;
}

/* Atmospheric wash — cyan and violet from the icon glow */
body::before {
  content: "";
  position: fixed;
  inset: -20% -10% auto;
  height: 70vh;
  background:
    radial-gradient(ellipse 70% 55% at 50% 0%, rgba(126, 200, 255, 0.18), transparent 70%),
    radial-gradient(ellipse 45% 40% at 85% 18%, rgba(168, 140, 255, 0.16), transparent 65%),
    radial-gradient(ellipse 40% 35% at 8% 28%, rgba(90, 160, 255, 0.12), transparent 60%);
  pointer-events: none;
  z-index: 0;
  animation: washDrift 18s var(--ease) infinite alternate;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

@keyframes washDrift {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to { transform: translate3d(0, 2.5%, 0) scale(1.04); }
}

.shell {
  position: relative;
  z-index: 2;
  width: min(720px, calc(100% - 40px));
  margin: 0 auto;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.shell-narrow {
  width: min(440px, calc(100% - 40px));
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 0 8px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  color: var(--text);
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  text-decoration: none;
}

.brand:hover {
  color: var(--text);
}

.brand-mark,
.hero-mark {
  display: block;
  object-fit: cover;
  border-radius: 22%;
}

.brand-mark {
  width: 36px;
  height: 36px;
}

.hero-mark {
  width: 112px;
  height: 112px;
  margin: 0 0 20px;
}

.topbar-link {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

.topbar-link:hover {
  color: var(--text);
}

.hero {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 32px 0 40px;
  min-height: calc(100svh - 140px);
  animation: riseIn 0.9s var(--ease) both;
}

@keyframes riseIn {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.eyebrow {
  margin: 0 0 12px;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}

.hero h1,
.page-title {
  margin: 0 0 16px;
  font-size: clamp(2rem, 7vw, 2.75rem);
  line-height: 1.15;
  letter-spacing: -0.03em;
  font-weight: 700;
}

.lede {
  margin: 0 0 32px;
  max-width: 28rem;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.45;
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 56px;
  padding: 14px 22px;
  border-radius: var(--radius-pill);
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem;
  letter-spacing: -0.01em;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), background 0.25s var(--ease);
}

.btn:hover {
  transform: translateY(-1px);
}

.btn:focus-visible,
.brand:focus-visible,
.topbar-link:focus-visible,
.footer-links a:focus-visible,
.footer-features a:focus-visible,
.site-footer a:focus-visible,
.crumbs a:focus-visible,
.related a:focus-visible,
.sitemap-group a:focus-visible,
.beat h2 a:focus-visible,
.legal a:focus-visible,
.feature-article a:focus-visible,
.field input:focus-visible,
.field select:focus-visible,
.field textarea:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.btn-primary {
  background: linear-gradient(180deg, var(--accent), var(--accent-end));
  color: var(--accent-ink);
  box-shadow: 0 12px 40px var(--glow);
}

.btn-primary:hover {
  box-shadow: 0 16px 48px rgba(159, 228, 255, 0.32);
}

.btn-secondary {
  background: var(--surface-3);
  color: var(--text);
  border: 1px solid rgba(255, 255, 255, 0.14);
}

.btn-secondary:hover {
  border-color: rgba(255, 255, 255, 0.28);
  background: #243049;
}

.beats {
  display: grid;
  gap: 12px;
  padding: 8px 0 48px;
}

.beat {
  display: grid;
  gap: 8px;
  padding: 16px 20px;
  background: var(--surface-2);
  border-radius: var(--radius-group);
  animation: riseIn 0.9s var(--ease) both;
}

.beat:nth-child(1) { animation-delay: 0.08s; }
.beat:nth-child(2) { animation-delay: 0.16s; }
.beat:nth-child(3) { animation-delay: 0.24s; }

.beat h2 {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.beat h2 a {
  color: inherit;
  text-decoration: none;
}

.beat h2 a:hover {
  color: var(--accent);
}

.beat p {
  margin: 0;
  color: var(--muted);
  line-height: 1.45;
  font-size: 0.95rem;
}

/* Template landing */
.page {
  padding: 12px 0 40px;
  animation: riseIn 0.75s var(--ease) both;
}

.card {
  margin-bottom: 24px;
}

.poster {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: var(--radius);
  background: var(--surface-2);
  margin-bottom: 18px;
}

.poster.skeleton {
  background: linear-gradient(90deg, #141a2c, #1c2438, #141a2c);
  background-size: 200% 100%;
  animation: shimmer 1.35s ease-in-out infinite;
}

@keyframes shimmer {
  0% { background-position: 100% 0; }
  100% { background-position: -100% 0; }
}

.page h1 {
  margin: 0 0 8px;
  font-size: clamp(1.5rem, 5vw, 1.85rem);
  letter-spacing: -0.03em;
  line-height: 1.2;
  font-weight: 700;
}

.meta {
  margin: 0 0 8px;
  font-size: 0.95rem;
}

.muted {
  color: var(--muted);
}

.site-footer {
  margin-top: auto;
  padding: 28px 0 36px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  flex-direction: column;
  gap: 18px;
  color: var(--muted);
  font-size: 0.85rem;
}

.footer-features {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
}

.footer-features a {
  color: var(--muted);
  text-decoration: none;
}

.footer-features a:hover {
  color: var(--accent);
}

.footer-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 18px;
  align-items: center;
  justify-content: space-between;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.footer-links a,
.site-footer a {
  color: var(--muted);
  text-decoration: none;
}

.footer-links a:hover,
.site-footer a:hover {
  color: var(--accent);
}

/* Legal prose */
.legal-shell {
  width: min(40rem, calc(100% - 40px));
}

.legal {
  padding: 28px 0 48px;
  animation: riseIn 0.7s var(--ease) both;
}

.legal h1 {
  margin: 0 0 8px;
  font-size: clamp(1.75rem, 5vw, 2.15rem);
  letter-spacing: -0.03em;
  line-height: 1.15;
  font-weight: 700;
}

.legal .meta-line {
  margin: 0 0 28px;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.5;
}

.legal h2 {
  margin: 28px 0 10px;
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.legal p,
.legal li {
  color: rgba(255, 255, 255, 0.88);
  line-height: 1.6;
  font-size: 1rem;
}

.legal p {
  margin: 0 0 12px;
}

.legal ul {
  margin: 0 0 12px;
  padding-left: 1.2rem;
}

.legal a {
  color: var(--accent);
}

.legal code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 0.92em;
}

.legal table {
  width: 100%;
  border-collapse: collapse;
  margin: 12px 0 18px;
  font-size: 0.92rem;
}

.legal th,
.legal td {
  border: 1px solid rgba(255, 255, 255, 0.12);
  padding: 10px 12px;
  text-align: left;
  vertical-align: top;
}

.legal th {
  background: var(--surface-2);
  color: var(--text);
  font-weight: 600;
}

.legal td {
  color: var(--muted);
}

.contact-form {
  display: grid;
  gap: 16px;
  margin-top: 8px;
}

.field {
  display: grid;
  gap: 8px;
}

.field label {
  font-size: 0.92rem;
  font-weight: 600;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 52px;
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: var(--surface-2);
  color: var(--text);
  font: inherit;
  font-size: 1rem;
}

.field textarea {
  min-height: 140px;
  resize: vertical;
}

.field select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%),
    linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 18px) 22px, calc(100% - 12px) 22px;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
}

.field-error {
  margin: 0;
  color: #ff8a84;
  font-size: 0.88rem;
}

.form-banner {
  margin: 0 0 16px;
  padding: 16px 20px;
  background: var(--surface-2);
  border-radius: var(--radius-group);
  line-height: 1.45;
}

.form-banner.error {
  color: #ff8a84;
}

.btn-block {
  width: 100%;
}

.hp {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

[hidden] {
  display: none !important;
}

.feature {
  padding: 12px 0 8px;
  animation: riseIn 0.75s var(--ease) both;
}

.feature .lede {
  max-width: 40rem;
  margin-bottom: 1.5rem;
}

.feature .actions {
  margin: 1.75rem 0 0.5rem;
}

.feature-article h2 {
  margin: 2rem 0 0.65rem;
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.3;
}

.feature-article h3 {
  margin: 0 0 0.35rem;
  font-size: 1.02rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.feature-article p,
.feature-article li {
  color: rgba(255, 255, 255, 0.88);
  line-height: 1.65;
  font-size: 1.02rem;
}

.feature-article p {
  margin: 0 0 1rem;
}

.feature-article a {
  color: var(--accent);
}

.feature-article ol {
  margin: 0 0 1rem;
  padding-left: 1.25rem;
}

.feature-article li {
  margin: 0 0 0.55rem;
}

.feature-article li:last-child {
  margin-bottom: 0;
}

.feature-article .faq {
  margin: 0 0 1.25rem;
}

.crumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin: 12px 0 20px;
  color: var(--muted);
  font-size: 0.85rem;
}

.crumbs a {
  color: var(--muted);
  text-decoration: none;
}

.crumbs a:hover {
  color: var(--accent);
}

.related {
  margin: 8px 0 36px;
}

.related h2 {
  margin: 0 0 12px;
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.related-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
}

.related-links a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
}

.related-links a:hover {
  text-decoration: underline;
}

.sitemap-group {
  margin: 0 0 28px;
}

.sitemap-group ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.sitemap-group a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
}

.sitemap-group a:hover {
  text-decoration: underline;
}

.sitemap-note {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 0.92rem;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }

  html {
    scroll-behavior: auto;
  }
}
