@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,600;9..144,700&family=Manrope:wght@400;500;600;700;800&display=swap');

:root {
  --bg-top: #080f22;
  --bg-bottom: #060b18;
  --surface-1: #122446;
  --surface-2: #0d1c38;
  --surface-3: #0a162f;
  --line: #2d4c83;
  --text: #f2f6ff;
  --muted: #a4b8de;
  --accent: #eb8754;
  --accent-soft: #ffc9a9;
  --accent-strong: #ca5f28;
  --accent-ink: #2f1204;
  --ok: #79f3bb;
  --warn: #ffd27d;
  --error: #ff9b9b;
  --radius-xl: 26px;
  --radius-lg: 18px;
  --radius-md: 12px;
  --shadow: 0 24px 56px rgba(1, 7, 24, 0.5);
  --shell: 1160px;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: Manrope, sans-serif;
  color: var(--text);
  background:
    radial-gradient(1100px 620px at -5% -12%, rgba(239, 146, 98, 0.28), transparent 58%),
    radial-gradient(960px 560px at 102% -8%, rgba(127, 171, 255, 0.26), transparent 56%),
    linear-gradient(180deg, var(--bg-top) 0%, #070f21 52%, var(--bg-bottom) 100%);
  min-height: 100vh;
}

a {
  color: inherit;
}

img {
  max-width: 100%;
  display: block;
}

.bg-orb {
  position: fixed;
  width: 320px;
  height: 320px;
  border-radius: 999px;
  filter: blur(72px);
  opacity: 0.34;
  pointer-events: none;
  z-index: 0;
}

.bg-orb.a {
  top: -130px;
  right: -110px;
  background: #f39a67;
}

.bg-orb.b {
  bottom: -130px;
  left: -110px;
  background: #7ca5ff;
}

.bg-grid {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.13;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.22) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.22) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(circle at center, black 25%, transparent 76%);
}

.shell {
  width: min(var(--shell), calc(100vw - 28px));
  margin-inline: auto;
  position: relative;
  z-index: 1;
}

.site-header {
  margin-top: 14px;
  padding: 10px 12px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 14px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(12, 24, 52, 0.86);
  backdrop-filter: blur(12px);
  position: sticky;
  top: 10px;
  z-index: 60;
  box-shadow: var(--shadow);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text);
}

.brand img {
  width: 34px;
  height: 34px;
}

.brand strong {
  display: block;
  font-family: Fraunces, serif;
  font-size: 1.08rem;
  line-height: 1;
}

.brand span {
  display: block;
  font-size: 0.74rem;
  color: var(--muted);
}

.site-nav {
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}

.site-nav a {
  text-decoration: none;
  color: var(--text);
  font-size: 0.82rem;
  font-weight: 700;
  padding: 8px 10px;
  border-radius: 999px;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  background: rgba(157, 185, 255, 0.18);
}

.page-shell {
  display: grid;
  gap: 14px;
  padding-top: 18px;
  padding-bottom: 110px;
}

.panel {
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background: linear-gradient(180deg, rgba(18, 36, 70, 0.95) 0%, rgba(11, 24, 50, 0.95) 100%);
  padding: clamp(15px, 2.3vw, 24px);
  box-shadow: var(--shadow);
}

.panel h2,
.panel h3 {
  margin-top: 0;
}

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

.kicker {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.72rem;
  color: var(--accent-soft);
  font-weight: 800;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 14px;
}

.hero-title {
  margin: 10px 0 10px;
  font-family: Fraunces, serif;
  font-size: clamp(2rem, 5.3vw, 4.2rem);
  line-height: 0.96;
}

.hero-lede {
  margin: 0;
  color: var(--muted);
  max-width: 64ch;
  line-height: 1.58;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 15px;
}

.hero-meta {
  margin-top: 13px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-meta span {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 0.75rem;
  color: var(--muted);
  background: rgba(9, 18, 38, 0.74);
}

.hero-proof {
  display: grid;
  gap: 10px;
}

.proof-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.proof-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface-3);
  padding: 11px;
}

.proof-card span {
  display: block;
  font-size: 0.72rem;
  color: var(--muted);
}

.proof-card strong {
  font-size: clamp(1.25rem, 2.8vw, 2rem);
}

.proof-note {
  margin: 0;
  font-size: 0.82rem;
  color: var(--muted);
}

.signal-band {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(13, 26, 54, 0.82);
  padding: 10px 14px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: center;
}

.signal-band p {
  margin: 0;
  font-weight: 700;
}

.signal-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.signal-tags span {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 10px;
  font-size: 0.72rem;
  color: var(--muted);
  background: rgba(7, 15, 33, 0.72);
}

.split-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 14px;
  margin-bottom: 10px;
}

.section-head p {
  margin: 0;
  color: var(--muted);
}

.stack {
  display: grid;
  gap: 10px;
}

label {
  display: grid;
  gap: 6px;
  font-size: 0.86rem;
  font-weight: 600;
}

label small {
  font-size: 0.75rem;
  color: var(--muted);
  font-weight: 500;
}

input,
textarea,
select,
button {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 11px 12px;
  font: inherit;
  color: var(--text);
  background: rgba(7, 14, 31, 0.88);
}

textarea {
  min-height: 94px;
  resize: vertical;
}

input::placeholder,
textarea::placeholder {
  color: #8397c2;
}

input:focus-visible,
textarea:focus-visible,
select:focus-visible,
button:focus-visible,
a:focus-visible {
  outline: 2px solid rgba(255, 206, 176, 0.9);
  outline-offset: 2px;
}

.checkbox-line {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.88rem;
  color: var(--muted);
}

.checkbox-line input {
  width: 18px;
  height: 18px;
  margin: 0;
  accent-color: var(--accent);
}

.btn {
  border: 1px solid rgba(244, 151, 101, 0.44);
  background: rgba(244, 151, 101, 0.14);
  color: var(--text);
  text-decoration: none;
  display: inline-grid;
  place-items: center;
  min-height: 44px;
  border-radius: 12px;
  font-weight: 800;
  cursor: pointer;
  padding: 0 14px;
  transition: transform 140ms ease, background 140ms ease, border-color 140ms ease;
}

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

.btn:disabled {
  opacity: 0.62;
  cursor: wait;
  transform: none;
}

.btn-primary {
  border-color: rgba(255, 212, 190, 0.84);
  background: linear-gradient(135deg, #ffd3b7 0%, #eb8754 52%, #ca5f28 100%);
  color: var(--accent-ink);
}

.btn-ghost {
  border-color: rgba(170, 193, 255, 0.45);
  background: rgba(151, 176, 255, 0.12);
}

.btn-inline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: auto;
}

.text-link {
  color: var(--accent-soft);
  font-weight: 700;
  text-decoration: none;
}

.text-link:hover,
.text-link:focus-visible {
  text-decoration: underline;
}

.tool-output {
  white-space: pre-wrap;
  word-break: break-word;
  min-height: 80px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: #07122a;
  color: var(--ok);
  padding: 12px;
  overflow: auto;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, 'Liberation Mono', 'Courier New', monospace;
  font-size: 0.82rem;
}

.tool-output.is-error {
  color: var(--error);
}

.workflow-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.workflow-step {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 12px;
  background: var(--surface-3);
}

.workflow-step .step-num {
  display: inline-grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 800;
  color: var(--accent-ink);
  background: linear-gradient(135deg, #ffd6bb 0%, #eb8754 100%);
  margin-bottom: 8px;
}

.workflow-step h3 {
  margin: 0;
  font-size: 1rem;
}

.workflow-step p {
  margin: 8px 0 0;
  font-size: 0.89rem;
  color: var(--muted);
  line-height: 1.5;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.feature-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 12px;
  background: var(--surface-3);
}

.feature-card h3 {
  margin: 0;
  font-size: 0.99rem;
}

.feature-card p {
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.5;
}

.objection-list {
  display: grid;
  gap: 8px;
}

.objection-list details {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface-3);
  padding: 10px 12px;
}

.objection-list summary {
  cursor: pointer;
  font-weight: 700;
}

.objection-list p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.5;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.plan-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 12px;
  background: var(--surface-3);
  display: grid;
  gap: 8px;
}

.plan-card.featured {
  border-color: rgba(255, 211, 184, 0.86);
  box-shadow: inset 0 0 0 1px rgba(255, 211, 184, 0.38);
}

.plan-card h3 {
  margin: 0;
  font-size: 0.99rem;
}

.plan-price {
  font-size: 2rem;
  font-weight: 800;
  line-height: 1;
}

.plan-price small {
  font-size: 0.74rem;
  color: var(--muted);
}

.plan-note {
  margin: 0;
  color: var(--muted);
  font-size: 0.84rem;
}

.plan-points {
  margin: 0;
  padding-left: 18px;
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 0.84rem;
}

.addon-list {
  margin: 10px 0 0;
  padding-left: 18px;
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 0.85rem;
}

.auth-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.auth-feedback {
  margin: 10px 0 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px;
  color: var(--muted);
  background: rgba(8, 16, 35, 0.78);
  font-size: 0.88rem;
}

.auth-feedback.error {
  color: var(--error);
  border-color: rgba(255, 155, 155, 0.5);
}

.auth-feedback.success {
  color: var(--ok);
  border-color: rgba(121, 243, 187, 0.5);
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 0.74rem;
  font-weight: 700;
  border: 1px solid var(--line);
  background: rgba(9, 18, 38, 0.74);
}

.status-pill.good {
  border-color: rgba(121, 243, 187, 0.48);
  color: var(--ok);
}

.status-pill.warn {
  border-color: rgba(255, 210, 125, 0.46);
  color: var(--warn);
}

.status-pill.bad {
  border-color: rgba(255, 155, 155, 0.52);
  color: var(--error);
}

.app-hero {
  display: grid;
  gap: 8px;
}

.app-hero h1 {
  margin: 0;
  font-size: clamp(1.5rem, 4vw, 2.4rem);
  font-family: Fraunces, serif;
}

.summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.summary-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface-3);
  padding: 11px;
}

.summary-card span {
  display: block;
  font-size: 0.74rem;
  color: var(--muted);
}

.summary-card strong {
  display: block;
  margin-top: 4px;
  font-size: 1.15rem;
  overflow-wrap: anywhere;
}

.workspace-grid {
  display: grid;
  gap: 14px;
}

.actions-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.form-shell {
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 12px;
  background: var(--surface-3);
}

.form-shell h3 {
  margin: 0 0 8px;
  font-size: 0.97rem;
}

.records-stack {
  display: grid;
  gap: 10px;
}

.records-block h3 {
  margin: 0 0 8px;
  font-size: 0.95rem;
}

.table-wrap {
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 12px;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 640px;
}

th,
td {
  padding: 10px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

th {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.69rem;
  color: var(--muted);
  background: rgba(8, 16, 34, 0.92);
}

tr:last-child td {
  border-bottom: 0;
}

.status-log {
  margin: 0;
  white-space: pre-wrap;
  word-break: break-word;
  min-height: 78px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #061028;
  color: var(--muted);
  padding: 11px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, 'Liberation Mono', 'Courier New', monospace;
  font-size: 0.82rem;
}

.status-log.is-success {
  color: var(--ok);
}

.status-log.is-error {
  color: var(--error);
  border-color: rgba(255, 155, 155, 0.44);
}

.status-log.is-info {
  color: var(--muted);
}

.site-footer {
  margin-top: 10px;
  border-top: 1px solid var(--line);
  padding: 18px 0 100px;
  text-align: center;
}

.site-footer nav {
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.site-footer a {
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
}

.site-footer a:hover,
.site-footer a:focus-visible {
  text-decoration: underline;
}

.mobile-dock {
  display: none;
}

.reveal {
  animation: rise 420ms ease both;
}

.reveal-delay-1 {
  animation-delay: 80ms;
}

.reveal-delay-2 {
  animation-delay: 140ms;
}

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

body.legal-page {
  min-height: 100vh;
}

.legal-shell {
  width: min(940px, calc(100vw - 24px));
  margin: 24px auto;
  display: grid;
  gap: 12px;
  position: relative;
  z-index: 1;
}

.legal-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background: linear-gradient(180deg, rgba(18, 36, 70, 0.96) 0%, rgba(10, 22, 46, 0.96) 100%);
  padding: clamp(16px, 2.5vw, 24px);
  box-shadow: var(--shadow);
}

.legal-card h1 {
  margin: 0;
  font-family: Fraunces, serif;
  font-size: clamp(1.8rem, 4.5vw, 2.8rem);
}

.legal-card h2 {
  margin-bottom: 8px;
  margin-top: 0;
  font-size: 1.1rem;
}

.legal-card p,
.legal-card li {
  color: var(--muted);
  line-height: 1.55;
}

.legal-card ul {
  margin: 0;
  padding-left: 18px;
  display: grid;
  gap: 6px;
}

.legal-meta {
  margin-top: 10px;
  font-size: 0.84rem;
  color: var(--muted);
}

.back-row {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.back-link {
  text-decoration: none;
  color: var(--accent-soft);
  font-weight: 700;
}

.back-link:hover,
.back-link:focus-visible {
  text-decoration: underline;
}

@media (max-width: 1080px) {
  .hero-grid,
  .split-grid,
  .pricing-grid,
  .actions-grid,
  .summary-grid,
  .workflow-grid,
  .feature-grid {
    grid-template-columns: 1fr;
  }

  .signal-band {
    border-radius: var(--radius-lg);
    grid-template-columns: 1fr;
  }

  .site-header {
    grid-template-columns: 1fr;
    border-radius: 24px;
  }

  .site-nav {
    justify-content: flex-start;
  }
}

@media (max-width: 760px) {
  .shell {
    width: min(var(--shell), calc(100vw - 16px));
  }

  .hero-title {
    font-size: clamp(1.75rem, 9vw, 2.4rem);
    line-height: 1.02;
  }

  .page-shell {
    padding-bottom: 128px;
  }

  .site-nav {
    display: none;
  }

  .mobile-dock {
    position: fixed;
    left: 8px;
    right: 8px;
    bottom: calc(8px + env(safe-area-inset-bottom));
    border: 1px solid var(--line);
    border-radius: 18px;
    background: rgba(8, 18, 38, 0.96);
    backdrop-filter: blur(10px);
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    z-index: 80;
    box-shadow: var(--shadow);
  }

  .mobile-dock a {
    text-decoration: none;
    color: var(--text);
    font-size: 0.78rem;
    font-weight: 700;
    min-height: 46px;
    display: grid;
    place-items: center;
    border-right: 1px solid var(--line);
  }

  .mobile-dock a:last-child {
    border-right: 0;
  }

  .site-footer {
    padding-bottom: calc(114px + env(safe-area-inset-bottom));
  }

  .auth-grid {
    grid-template-columns: 1fr;
  }
}
