:root {
  --ink: #181816;
  --muted: #6f706b;
  --paper: #f4f1e9;
  --surface: #fffefb;
  --line: rgba(24, 24, 22, 0.13);
  --accent: #d9ff65;
  --danger: #b42318;
  --danger-bg: #fff1ef;
  --success: #287a3d;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
  font-family: "DM Sans", "Noto Sans SC", Arial, sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 7% 11%, rgba(217, 255, 101, 0.22), transparent 27rem),
    var(--paper);
  -webkit-font-smoothing: antialiased;
}

button,
input,
select {
  font: inherit;
}

a {
  color: inherit;
  text-decoration: none;
}

.signup-page {
  min-height: 100vh;
  padding: 0 24px;
}

.signup-header,
.signup-layout,
.signup-footer {
  width: min(1240px, 100%);
  margin-inline: auto;
}

.signup-header {
  min-height: 92px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  font-size: 23px;
  font-weight: 700;
  letter-spacing: -0.04em;
}

.logo-mark {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  background: var(--accent);
  font-size: 18px;
}

.back-link {
  color: #545550;
  font-size: 13px;
  font-weight: 700;
  transition: opacity 160ms ease;
}

.back-link:hover {
  opacity: 0.58;
}

.signup-layout {
  min-height: 760px;
  border: 1px solid rgba(255, 255, 255, 0.74);
  border-radius: 34px;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(520px, 1.1fr);
  overflow: hidden;
  background: rgba(255, 254, 251, 0.7);
  box-shadow: 0 28px 80px rgba(55, 51, 35, 0.11);
  backdrop-filter: blur(18px);
}

.signup-intro {
  position: relative;
  padding: clamp(42px, 5.5vw, 74px);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 44px;
  overflow: hidden;
  color: white;
  background:
    radial-gradient(circle at 78% 20%, rgba(217, 255, 101, 0.29), transparent 20rem),
    linear-gradient(150deg, #242420, #11110f 76%);
}

.signup-intro::after {
  content: "";
  position: absolute;
  right: -130px;
  bottom: -170px;
  width: 410px;
  height: 410px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 50%;
  box-shadow:
    0 0 0 45px rgba(255, 255, 255, 0.025),
    0 0 0 90px rgba(255, 255, 255, 0.018);
  pointer-events: none;
}

.eyebrow,
.step-label,
.success-eyebrow {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.18em;
}

.eyebrow {
  margin-bottom: 24px;
  color: rgba(255, 255, 255, 0.55);
}

.signup-intro h1 {
  max-width: 540px;
  margin: 0;
  font-size: clamp(44px, 5vw, 68px);
  line-height: 1.01;
  letter-spacing: -0.06em;
}

.signup-intro > div:first-child > p {
  max-width: 540px;
  margin: 23px 0 0;
  color: rgba(255, 255, 255, 0.65);
  font-size: 16px;
  line-height: 1.75;
}

.plan-summary {
  position: relative;
  z-index: 1;
  padding: 25px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.07);
  backdrop-filter: blur(14px);
}

.plan-summary-top {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 24px;
}

.plan-summary-top span {
  color: rgba(255, 255, 255, 0.54);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.07em;
}

.plan-summary h2 {
  margin: 8px 0 0;
  font-size: 28px;
  letter-spacing: -0.045em;
}

.plan-summary-price {
  display: flex;
  align-items: baseline;
  gap: 6px;
  text-align: right;
}

.plan-summary-price strong {
  font-size: 31px;
  letter-spacing: -0.055em;
}

.plan-summary-price small {
  color: rgba(255, 255, 255, 0.56);
  font-size: 11px;
}

.plan-summary > p {
  margin: 20px 0 0;
  color: rgba(255, 255, 255, 0.66);
  font-size: 13px;
}

.plan-summary ul {
  margin: 20px 0 0;
  padding: 18px 0 0;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  display: grid;
  gap: 10px;
  list-style: none;
}

.plan-summary li {
  position: relative;
  padding-left: 21px;
  color: rgba(255, 255, 255, 0.83);
  font-size: 13px;
}

.plan-summary li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: 700;
}

.security-note {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: flex-start;
  gap: 13px;
}

.security-icon {
  width: 28px;
  height: 28px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--ink);
  background: var(--accent);
  font-size: 13px;
  font-weight: 700;
}

.security-note strong {
  font-size: 13px;
}

.security-note p {
  max-width: 460px;
  margin: 5px 0 0;
  color: rgba(255, 255, 255, 0.52);
  font-size: 11px;
  line-height: 1.6;
}

.form-panel {
  position: relative;
  padding: clamp(42px, 5.5vw, 76px);
  background: var(--surface);
}

.form-heading {
  margin-bottom: 30px;
}

.step-label {
  color: #8a8b84;
}

.form-heading h2,
.success-panel h2 {
  margin: 11px 0 0;
  font-size: 34px;
  letter-spacing: -0.045em;
}

.form-heading p {
  margin: 9px 0 0;
  color: var(--muted);
  font-size: 14px;
}

.form-alert {
  margin-bottom: 22px;
  padding: 13px 15px;
  border: 1px solid rgba(180, 35, 24, 0.17);
  border-radius: 12px;
  color: var(--danger);
  background: var(--danger-bg);
  font-size: 13px;
  line-height: 1.55;
}

.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
}

.field {
  margin-bottom: 18px;
}

.field label {
  margin-bottom: 8px;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  font-size: 12px;
  font-weight: 700;
}

.field label span {
  color: #999a94;
  font-size: 10px;
  font-weight: 500;
}

.field input,
.field select {
  width: 100%;
  min-height: 52px;
  padding: 0 15px;
  border: 1px solid var(--line);
  border-radius: 13px;
  color: var(--ink);
  background: #fbfaf6;
  outline: 0;
  transition: border-color 150ms ease, box-shadow 150ms ease, background 150ms ease;
}

.field input::placeholder {
  color: #aaa9a2;
}

.field input:hover,
.field select:hover {
  border-color: rgba(24, 24, 22, 0.27);
}

.field input:focus,
.field select:focus {
  border-color: #5c692e;
  background: white;
  box-shadow: 0 0 0 4px rgba(217, 255, 101, 0.28);
}

.field.has-error input,
.field.has-error select,
.check-row.has-error input {
  border-color: var(--danger);
  box-shadow: 0 0 0 3px rgba(180, 35, 24, 0.08);
}

.select-wrap {
  position: relative;
}

.select-wrap::after {
  content: "⌄";
  position: absolute;
  top: 50%;
  right: 16px;
  color: #777872;
  pointer-events: none;
  transform: translateY(-58%);
}

select {
  appearance: none;
}

.password-wrap {
  position: relative;
}

.password-wrap input {
  padding-right: 72px;
}

.show-password {
  position: absolute;
  top: 50%;
  right: 11px;
  padding: 7px 8px;
  border: 0;
  border-radius: 8px;
  color: #63645f;
  background: transparent;
  cursor: pointer;
  font-size: 11px;
  font-weight: 700;
  transform: translateY(-50%);
}

.show-password:hover {
  background: rgba(24, 24, 22, 0.05);
}

.password-requirements {
  margin-top: 9px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  color: #92938d;
  font-size: 10px;
}

.password-requirements span {
  position: relative;
  padding-left: 13px;
}

.password-requirements span::before {
  content: "•";
  position: absolute;
  left: 0;
}

.password-requirements span.valid {
  color: var(--success);
}

.password-requirements span.valid::before {
  content: "✓";
}

.field-error {
  min-height: 0;
  margin: 6px 0 0;
  color: var(--danger);
  font-size: 11px;
  line-height: 1.45;
}

.field-error:empty {
  display: none;
}

.check-row {
  margin-top: 2px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: #444540;
  cursor: pointer;
  font-size: 11px;
  line-height: 1.55;
}

.check-row input {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
  margin: 1px 0 0;
  accent-color: var(--ink);
}

.check-row-muted {
  margin-top: 13px;
  color: #777873;
}

.checkbox-error {
  margin-left: 26px;
}

.submit-button,
.success-button {
  width: 100%;
  min-height: 55px;
  margin-top: 25px;
  border: 0;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: var(--ink);
  background: var(--accent);
  box-shadow: 0 13px 28px rgba(168, 205, 51, 0.23);
  cursor: pointer;
  font-weight: 700;
  transition: transform 160ms ease, background 160ms ease;
}

.submit-button:hover,
.success-button:hover {
  background: #c9f64a;
  transform: translateY(-2px);
}

.submit-button:disabled {
  cursor: wait;
  opacity: 0.72;
  transform: none;
}

.spinner {
  width: 16px;
  height: 16px;
  border: 2px solid rgba(24, 24, 22, 0.25);
  border-top-color: var(--ink);
  border-radius: 50%;
  display: none;
  animation: spin 700ms linear infinite;
}

.submit-button.is-loading .spinner {
  display: block;
}

.payment-note {
  margin: 12px 0 0;
  color: #8a8b85;
  text-align: center;
  font-size: 10px;
}

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

.success-panel {
  min-height: 610px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  text-align: center;
}

.success-panel[hidden] {
  display: none;
}

.success-mark {
  width: 68px;
  height: 68px;
  margin-bottom: 24px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--accent);
  font-size: 29px;
  font-weight: 700;
  box-shadow: 0 15px 35px rgba(168, 205, 51, 0.22);
}

.success-eyebrow {
  color: #898a84;
}

.success-panel > p {
  max-width: 420px;
  margin: 13px 0 0;
  color: var(--muted);
  line-height: 1.65;
}

.success-details {
  width: min(390px, 100%);
  margin-top: 28px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 15px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: #f8f6f0;
  font-size: 12px;
}

.success-details span {
  color: var(--muted);
}

.success-details strong {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 11px;
}

.success-button {
  width: min(390px, 100%);
  text-decoration: none;
}

.signup-footer {
  min-height: 98px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
  color: #777873;
  font-size: 11px;
}

.signup-footer p {
  margin: 0;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 3px solid rgba(40, 78, 255, 0.28);
  outline-offset: 3px;
}

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

@media (max-width: 940px) {
  .signup-layout {
    grid-template-columns: 1fr;
  }

  .signup-intro {
    min-height: 640px;
  }
}

@media (max-width: 620px) {
  .signup-page {
    padding: 0 14px;
  }

  .signup-header {
    min-height: 78px;
  }

  .logo {
    font-size: 20px;
  }

  .back-link {
    max-width: 130px;
    text-align: right;
    line-height: 1.35;
  }

  .signup-layout {
    border-radius: 25px;
  }

  .signup-intro,
  .form-panel {
    padding: 36px 25px;
  }

  .signup-intro {
    min-height: 610px;
  }

  .signup-intro h1 {
    font-size: 44px;
  }

  .plan-summary-top {
    flex-direction: column;
  }

  .plan-summary-price {
    text-align: left;
  }

  .field-row {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .signup-footer {
    padding: 28px 0;
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
  }
}

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