:root {
  --bg0: #070812;
  --bg1: #0b1030;
  --card: #0e1638cc;
  --text: #e9ecff;
  --muted: #a7b0da;
  --accent: #7c5cff;
  --accent2: #5fe2b6;
  --good: #3ee6a8;
  --shadow: 0 30px 80px rgba(0, 0, 0, 0.45);
  --radius: 18px;
  --radius2: 14px;
}

* {
  box-sizing: border-box;
}

html,
body {
  overflow-x: hidden;
  margin: 0;
}
body {
  font-family:
    ui-sans-serif,
    system-ui,
    -apple-system,
    Segoe UI,
    Roboto,
    Helvetica,
    Arial;
  color: var(--text);
  background:
    radial-gradient(1200px 600px at 15% 20%, rgba(124, 92, 255, 0.35), transparent 60%), radial-gradient(900px 500px at 85% 35%, rgba(255, 138, 61, 0.18), transparent 60%), radial-gradient(700px 450px at 40% 90%, rgba(62, 230, 168, 0.1), transparent 60%),
    linear-gradient(180deg, var(--bg0), var(--bg1) 60%, #060716);
  min-height: 100vh;
}

body:before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.18;
  background-image: linear-gradient(rgba(255, 255, 255, 0.06) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, 0.06) 1px, transparent 1px);
  background-size: 54px 54px;
  mask-image: radial-gradient(circle at 50% 20%, black 0%, transparent 70%);
}

.container {
  width: min(1100px, 92vw);
  margin: 0 auto;
  padding: 28px 0 60px;
}

.hero {
  margin-top: 26px;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 22px;
  align-items: start;
}
.hero .headline {
  padding: 26px 8px 10px;
}
.hero .headline .kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
  color: var(--muted);
  font-size: 13px;
}
.hero .headline .kdot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--good);
  box-shadow: 0 0 0 4px rgba(62, 230, 168, 0.12);
}
.hero .headline h1 {
  margin: 16px 0 10px;
  font-size: clamp(36px, 4.2vw, 56px);
  line-height: 1.05;
  letter-spacing: -0.8px;
}
.hero .headline h1 .grad {
  background: linear-gradient(135deg, #ffffff, #cdd5ff 45%, #7c5cff 70%, #ff8a3d);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero .headline .sub {
  color: var(--muted);
  font-size: 16px;
  line-height: 1.6;
  max-width: 56ch;
}
.hero .headline .mini {
  margin-top: 18px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  color: var(--muted);
  font-size: 13px;
}
.hero .headline .mini span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 10px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(9, 12, 32, 0.35);
  border-radius: 999px;
}
.hero .headline .mini span .icon {
  width: 18px;
  height: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  font-size: 12px;
  font-weight: 800;
  border-radius: 6px;
  color: #cfd6ff;
}
.hero .rightCol {
  display: grid;
  gap: 14px;
}
.hero .rightCol .side {
  padding: 16px;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(9, 12, 32, 0.42);
  backdrop-filter: blur(10px);
}
.hero .rightCol .side h3 {
  margin: 0 0 8px;
  font-size: 14px;
  letter-spacing: 0.2px;
}
.hero .rightCol .side p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}
.hero .rightCol .side .steps {
  margin-top: 10px;
  display: grid;
  gap: 8px;
}
.hero .rightCol .side .steps .step {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 10px 10px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
}
.hero .rightCol .side .steps .step .num {
  width: 22px;
  height: 22px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: rgba(255, 138, 61, 0.14);
  border: 1px solid rgba(255, 138, 61, 0.18);
  color: #ffd8c0;
  font-size: 12px;
  font-weight: 800;
  flex: 0 0 auto;
  margin-top: 1px;
}

.hero > *,
.hero .rightCol > *,
.card,
.rcaBlock,
.unlockCard {
  min-width: 0;
}

.footer {
  margin-top: 18px;
  color: rgba(255, 255, 255, 0.45);
  font-size: 12px;
  text-align: center;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 14px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(9, 12, 32, 0.55);
  border-radius: 16px;
  backdrop-filter: blur(12px);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.25);
}
.nav .brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  letter-spacing: 0.2px;
}
.nav .brand .logo {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  background: radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.25), transparent 45%), linear-gradient(135deg, var(--accent), var(--accent2));
  box-shadow: 0 12px 30px rgba(124, 92, 255, 0.25);
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.nav .brand .logo:after {
  content: "";
  position: absolute;
  inset: -20%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.22), transparent);
  transform: rotate(25deg);
  animation: shine 3.5s ease-in-out infinite;
}
@keyframes shine {
  0% {
    transform: translateX(-60%) rotate(25deg);
  }
  55% {
    transform: translateX(60%) rotate(25deg);
  }
  100% {
    transform: translateX(60%) rotate(25deg);
  }
}
.brandLink {
  text-decoration: none;
  color: inherit;
  display: inline-flex;
}
.brandLink:hover {
  opacity: 0.9;
}

.nav .navlinks {
  display: flex;
  gap: 14px;
  align-items: center;
  color: var(--muted);
  font-size: 13px;
}
.nav .navlinks a {
  color: inherit;
  text-decoration: none;
  padding: 8px 10px;
  border-radius: 12px;
}
.nav .navlinks a:hover {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
}
.nav .cta {
  display: flex;
  gap: 10px;
  align-items: center;
}

.btn {
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  padding: 10px 12px;
  border-radius: 14px;
  cursor: pointer;
  font-weight: 600;
  font-size: 13px;
}
.btn:hover {
  background: rgba(255, 255, 255, 0.1);
}
.btn.primary {
  border: none;
  background: linear-gradient(135deg, var(--accent), #5fe2b6);
  color: #0b0f26;
  box-shadow: 0 18px 45px rgba(124, 92, 255, 0.22);
}
.btn.primary:hover {
  filter: brightness(1.04);
}

.uBtn {
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
  color: rgba(233, 236, 255, 0.92);
  padding: 10px 12px;
  border-radius: 14px;
  cursor: pointer;
  font-weight: 900;
  font-size: 13px;
}
.uBtn:hover {
  background: rgba(255, 255, 255, 0.1);
}
.uBtn.primary {
  border: none;
  background: linear-gradient(135deg, #7c5cff, #5fe2b6);
  color: #0b0f26;
  box-shadow: 0 18px 45px rgba(124, 92, 255, 0.22);
}
.uBtn.primary:hover {
  filter: brightness(1.04);
}

.generateBtn {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #0a0f25;
  text-shadow: 0 1px 1px rgba(255, 255, 255, 0.2);

  width: 100%;
  padding: 14px 22px;
  font-size: 16px;
  font-weight: 800;
  border-radius: 18px;

  background: linear-gradient(110deg, #7c5cff 0%, #6a6dff 35%, #5fe2b6 75%, #4fd1c5 100%);

  box-shadow:
    0 18px 45px rgba(124, 92, 255, 0.35),
    0 6px 18px rgba(0, 0, 0, 0.35);

  transition:
    transform 0.15s ease,
    box-shadow 0.15s ease,
    filter 0.15s ease;
}
.generateBtn:hover {
  transform: translateY(-2px);
  box-shadow:
    0 18px 45px rgba(124, 92, 255, 0.45),
    0 6px 18px rgba(0, 0, 0, 0.35);
  filter: brightness(1.05);
}
.generateBtn:active {
  transform: translateY(0);
  box-shadow:
    0 8px 20px rgba(124, 92, 255, 0.35),
    0 3px 8px rgba(0, 0, 0, 0.25);
}
.generateBtn::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 16px;
  background: radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.2), transparent 60%);
  opacity: 0;
  transition: opacity 0.3s ease;
}
.generateBtn:hover::after {
  opacity: 1;
}

.card {
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: linear-gradient(180deg, rgba(14, 22, 56, 0.75), rgba(10, 15, 38, 0.55));
  backdrop-filter: blur(12px);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.card .cardHeader {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 16px 16px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(90deg, rgba(124, 92, 255, 0.1), transparent 60%);
}
.card .cardHeader strong {
  font-size: 14px;
}
.card .cardHeader .hint {
  color: var(--muted);
  font-size: 12px;
}

.form {
  padding: 16px;
  display: grid;
  gap: 12px;
}
textarea,
input {
  width: 100%;
  border-radius: var(--radius2);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(6, 9, 22, 0.55);
  color: var(--text);
  outline: none;
  padding: 12px 12px;
  font-size: 14px;
}
textarea {
  min-height: 220px;
  resize: vertical;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  line-height: 1.5;
}
textarea:focus,
input:focus {
  border-color: rgba(124, 92, 255, 0.55);
  box-shadow: 0 0 0 4px rgba(124, 92, 255, 0.12);
}

.form .row {
  display: block;
}

.form .actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}
.form .actions .actionsLeft {
  flex: 1 1 320px;
}
.form .actions .actionsLeft .small {
  font-size: 12px;
  color: var(--muted);
  margin-right: auto;
}
.form .actions .actionsRight {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.08);
  margin: 2px 0;
}

.outputWrap {
  padding: 16px;
  display: grid;
  gap: 12px;
}
.out {
  border-radius: var(--radius2);
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(6, 9, 22, 0.45);
  padding: 14px;
  min-height: 120px;
  white-space: pre-wrap;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  color: #dbe0ff;
  line-height: 1.55;
  font-size: 13px;
}

.outWrap {
  display: grid;
  gap: 12px;
}
.outWrap .rcaBlock {
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(6, 9, 22, 0.45);
  padding: 14px;
  overflow: hidden;
  position: relative;
}
.outWrap .rcaBlock .rcaHead {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
  margin-bottom: 10px;
}
.outWrap .rcaBlock .rcaHead .rcaTitle {
  display: flex;
  gap: 10px;
  align-items: center;
  font-weight: 800;
  letter-spacing: 0.2px;
  font-size: 13px;
  color: rgba(233, 236, 255, 0.95);
}
.outWrap .rcaBlock .rcaHead .rcaBadge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.85);
}
.outWrap .rcaBlock .rcaHead .rcaBadge .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #3ee6a8;
  box-shadow: 0 0 0 4px rgba(62, 230, 168, 0.12);
}
.outWrap .rcaBlock .rcaHead .rcaMeta {
  color: rgba(167, 176, 218, 0.95);
  font-size: 12px;
  line-height: 1.5;
  max-width: 58ch;
}
.outWrap .rcaBlock .rcaText {
  white-space: pre-wrap;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  color: #dbe0ff;
  line-height: 1.55;
  font-size: 13px;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.outWrap .rcaBlock .rcaSection {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}
.outWrap .rcaBlock .secHead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}
.outWrap .rcaBlock .secHead .secTitle {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 800;
  font-size: 12px;
  letter-spacing: 0.25px;
  text-transform: uppercase;
  color: rgba(233, 236, 255, 0.92);
}
.outWrap .rcaBlock .secHead .lockPill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  border: 1px solid rgba(124, 92, 255, 0.25);
  background: rgba(124, 92, 255, 0.12);
  color: rgba(233, 236, 255, 0.92);
}

.locked {
  position: relative;
  border-radius: 12px;
  border: 1px dashed rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.04);
  overflow: hidden;
}
.locked .rcaText {
  padding: 12px;
  filter: blur(7px);
  opacity: 0.55;
  user-select: none;
}

.lockOverlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 14px;
  background: linear-gradient(180deg, rgba(6, 9, 22, 0.15), rgba(6, 9, 22, 0.75));
}
.lockOverlay .unlockCard {
  width: min(520px, 100%);
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: linear-gradient(180deg, rgba(14, 22, 56, 0.78), rgba(10, 15, 38, 0.6));
  box-shadow: 0 26px 70px rgba(0, 0, 0, 0.45);
  padding: 14px;
  backdrop-filter: blur(12px);
}
.lockOverlay .unlockCard .unlockTop {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}
.lockOverlay .unlockCard .unlockTop .unlockTitle {
  font-weight: 900;
  font-size: 14px;
  letter-spacing: 0.2px;
  color: rgba(233, 236, 255, 0.98);
}
.lockOverlay .unlockCard .unlockTop .unlockSub {
  margin-top: 4px;
  font-size: 12px;
  color: rgba(167, 176, 218, 0.95);
  line-height: 1.5;
}
.lockOverlay .unlockCard .unlockTop .priceTag {
  flex: 0 0 auto;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
  color: rgba(233, 236, 255, 0.92);
  font-weight: 900;
  font-size: 12px;
  letter-spacing: 0.2px;
}
.lockOverlay .unlockCard .unlockActions {
  display: flex;
  gap: 10px;
  margin-top: 12px;
  flex-wrap: wrap;
  align-items: center;
}
.lockOverlay .unlockCard .unlockActions .trustRow {
  font-size: 12px;
  color: rgba(167, 176, 218, 0.95);
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.lockOverlay .unlockCard .unlockActions .trustRow span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(9, 12, 32, 0.35);
}

.unlocked .lockOverlay {
  display: none;
}
.unlocked.locked .rcaText {
  filter: none;
  opacity: 1;
  user-select: text;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 18px;
  transform: translateX(-50%);
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.9);
  font-size: 13px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease;
  backdrop-filter: blur(10px);
}
.toast.show {
  opacity: 1;
}

.spinner {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid rgba(11, 15, 38, 0.35);
  border-top-color: rgba(11, 15, 38, 0.95);
  display: inline-block;
  vertical-align: middle;
  animation: spin 0.8s linear infinite;
  margin-right: 8px;
}

.miniSpin {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid rgba(11, 15, 38, 0.35);
  border-top-color: rgba(11, 15, 38, 0.95);
  display: inline-block;
  vertical-align: middle;
  animation: spin 0.8s linear infinite;
  margin-right: 8px;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.pill {
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
}
.small {
  font-size: 12px;
  color: var(--muted);
  margin-right: auto;
}

.rcaText h2 {
  margin: 22px 0 10px;
  padding-bottom: 6px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: #e6e9ff;
}
.rcaText h3 {
  margin: 18px 0 8px;
  font-size: 0.95rem;
  font-weight: 500;
  color: #c7ccff;
}
.fact {
  color: #6ee7b7;
}
.assumption {
  color: #fbbf24;
}
.inference {
  color: #a78bfa;
}

.causal-step {
  margin-bottom: 0.6rem;
}

#countdown {
  font-weight: 900;
  color: var(--accent2);
}

.mailLink {
  color: #7aa2ff;
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px solid rgba(122, 162, 255, 0.35);
  padding-bottom: 1px;
  transition: all 0.2s ease;
}
.mailLink:hover {
  color: #9bc4ff;
  border-bottom-color: rgba(155, 196, 255, 0.8);
  text-shadow: 0 0 6px rgba(122, 162, 255, 0.5);
}
.mailLink:active {
  opacity: 0.8;
}

@media (max-width: 980px) {
  .hero {
    grid-template-columns: 1fr;
  }

  .nav {
    flex-direction: column;
    align-items: stretch;
    gap: 14px;
  }

  .nav .navlinks {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
  }

  .nav .cta {
    width: 100%;
    justify-content: center;
  }

  .nav .cta .btn {
    flex: 1;
  }

  .form .actions {
    align-items: flex-start;
  }

  .form .actions .actionsRight {
    justify-content: flex-end;
    width: 100%;
  }
}

@media (max-width: 640px) {
  .form .row {
    grid-template-columns: 1fr;
  }

  .lockOverlay .unlockCard .unlockActions {
    flex-direction: column;
    align-items: stretch;
  }

  .lockOverlay .unlockCard .unlockActions .uBtn {
    width: 100%;
  }

  .lockOverlay .unlockCard .unlockActions .trustRow {
    width: 100%;
    justify-content: center;
  }

  .outWrap .rcaBlock .rcaHead {
    flex-direction: column;
    align-items: flex-start;
  }

  .btn {
    width: 100%;
  }

  .uBtn {
    width: 100%;
  }
}
