/* Oxcore lead capture — matches high-converting landing mockups */

:root {
  --ink: #0f172a;
  --muted: #64748b;
  --border: #e2e8f0;
  --surface: #ffffff;
  --page: #ffffff;
  --cta: #ff7a20;
  --cta-hover: #e86812;
  --cta-text: #ffffff;
  --accent-bar: #fde6d2;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 18px 50px rgba(15, 23, 42, 0.08);
  --shadow-icon: 0 12px 28px rgba(255, 122, 32, 0.35);
  --radius: 12px;
  --radius-sm: 8px;
  --font: "Outfit", system-ui, -apple-system, sans-serif;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --dur: 0.45s;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100dvh;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--page);
  -webkit-font-smoothing: antialiased;
}

.page-wrap {
  min-height: 100dvh;
  padding: clamp(1rem, 4vw, 2rem);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  position: relative;
  overflow-x: hidden;
}

@media (min-width: 720px) {
  .page-wrap {
    align-items: center;
    padding: 2rem 1.5rem 3rem;
  }
}

/* Entrance */
.capture-card {
  width: 100%;
  max-width: 520px;
  animation: cardEnter 0.7s var(--ease-out) both;
}

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

.capture-card.is-leaving {
  animation: cardLeave 0.35s var(--ease-out) forwards;
}

@keyframes cardLeave {
  to {
    opacity: 0;
    transform: translateY(-12px) scale(0.98);
  }
}

.brand-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
}

.brand {
  font-weight: 800;
  font-size: 1.125rem;
  letter-spacing: -0.02em;
  color: var(--ink);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.brand-mark {
  width: 26px;
  height: 26px;
  object-fit: contain;
  display: block;
}

.admin-link {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--muted);
  text-decoration: none;
  padding: 0.35rem 0.5rem;
  border-radius: 6px;
  transition: color 0.2s, background 0.2s;
}

.admin-link:hover {
  color: var(--ink);
  background: rgba(15, 23, 42, 0.05);
}

.headline {
  font-size: clamp(1.5rem, 5.2vw, 1.85rem);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.03em;
  margin: 0 0 0.75rem;
  color: var(--ink);
}

.subheading {
  margin: 0 0 1.5rem;
  font-size: 0.9375rem;
  color: var(--muted);
  font-weight: 500;
  max-width: 46ch;
}

/* Before / after */
.before-after {
  margin: 0 0 1.5rem;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
  animation: fadeRise 0.65s var(--ease-out) 0.1s both;
}

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

.ba-single {
  position: relative;
  display: block;
  width: 100%;
  line-height: 0;
}

.ba-single img {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
}

.ba-badge {
  position: absolute;
  bottom: 12px;
  left: 12px;
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #fff;
  background: rgba(15, 23, 42, 0.78);
  padding: 0.4rem 0.6rem;
  border-radius: 6px;
  backdrop-filter: blur(6px);
  line-height: 1;
}

.ba-badge-after {
  left: auto;
  right: 12px;
  background: rgba(255, 122, 32, 0.94);
}

/* Form card */
.lead-form {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: clamp(1.25rem, 4vw, 1.5rem);
  box-shadow: var(--shadow-md);
  display: flex;
  flex-direction: column;
  gap: 1rem;
  animation: fadeRise 0.65s var(--ease-out) 0.18s both;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.field-label {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--ink);
}

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.875rem;
}

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

.lead-form input,
.lead-form select {
  width: 100%;
  font: inherit;
  font-size: 1rem;
  padding: 0.8125rem 0.9375rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--ink);
  transition: border-color 0.2s, box-shadow 0.2s;
  min-height: 48px;
}

.lead-form input::placeholder {
  color: #94a3b8;
}

.lead-form input:hover,
.lead-form select:hover {
  border-color: #cbd5e1;
}

.lead-form input:focus,
.lead-form select:focus {
  outline: none;
  border-color: rgba(255, 122, 32, 0.55);
  box-shadow: 0 0 0 3px rgba(255, 122, 32, 0.18);
}

.select-wrap {
  position: relative;
}

.select-wrap::after {
  content: "";
  position: absolute;
  right: 14px;
  top: 50%;
  width: 8px;
  height: 8px;
  border-right: 2px solid var(--muted);
  border-bottom: 2px solid var(--muted);
  transform: translateY(-65%) rotate(45deg);
  pointer-events: none;
}

.lead-form select {
  appearance: none;
  padding-right: 2.5rem;
  cursor: pointer;
}

.form-error {
  margin: 0;
  font-size: 0.875rem;
  color: #dc2626;
  font-weight: 500;
}

.form-error.hidden {
  display: none;
}

.btn-submit {
  margin-top: 0.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  min-height: 52px;
  padding: 0.875rem 1.25rem;
  border: none;
  border-radius: var(--radius-sm);
  background: var(--cta);
  color: var(--cta-text);
  font: inherit;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  cursor: pointer;
  transition: background 0.2s, transform 0.2s var(--ease-out), box-shadow 0.2s;
  box-shadow: 0 4px 14px rgba(255, 122, 32, 0.35);
}

.btn-submit:hover {
  background: var(--cta-hover);
  transform: translateY(-1px);
  box-shadow: 0 8px 22px rgba(255, 122, 32, 0.4);
}

.btn-submit:active {
  transform: translateY(0);
}

.btn-submit:disabled {
  opacity: 0.65;
  cursor: not-allowed;
  transform: none;
}

.btn-arrow {
  font-size: 1.125rem;
  line-height: 1;
  transition: transform 0.25s var(--ease-out);
}

.btn-submit:hover:not(:disabled) .btn-arrow {
  transform: translateX(4px);
}

/* Loading */
.loading-screen {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  z-index: 100;
  animation: overlayIn 0.35s var(--ease-out) both;
}

.loading-screen.hidden {
  display: none !important;
}

@keyframes overlayIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.loading-card {
  text-align: center;
  max-width: 280px;
  animation: popIn 0.45s var(--ease-out) 0.05s both;
}

@keyframes popIn {
  from {
    opacity: 0;
    transform: scale(0.94);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.loader-ring {
  width: 52px;
  height: 52px;
  margin: 0 auto 1.25rem;
  border-radius: 50%;
  border: 3px solid var(--border);
  border-top-color: var(--cta);
  animation: spin 0.75s linear infinite;
}

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

.loading-title {
  margin: 0 0 0.35rem;
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--ink);
  animation: pulseText 1.2s ease-in-out infinite;
}

.loading-sub {
  margin: 0;
  font-size: 0.875rem;
  color: var(--muted);
  font-weight: 500;
}

@keyframes pulseText {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.72;
  }
}

/* Approved */
.approved-screen {
  min-height: 100dvh;
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1.25rem;
  text-align: center;
  animation: overlayIn 0.4s var(--ease-out) both;
}

.approved-screen.hidden {
  display: none !important;
}

.approved-inner {
  animation: approvedRise 0.65s var(--ease-out) both;
}

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

.success-icon {
  width: 88px;
  height: 88px;
  margin: 0 auto 1.5rem;
  border-radius: 50%;
  background: var(--cta);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-icon);
  animation: iconPop 0.55s var(--ease-out) 0.12s both;
}

@keyframes iconPop {
  from {
    opacity: 0;
    transform: scale(0.5);
  }
  70% {
    transform: scale(1.06);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.check-svg {
  width: 44px;
  height: 44px;
}

.check-path {
  stroke-dasharray: 48;
  stroke-dashoffset: 48;
  animation: drawCheck 0.5s var(--ease-out) 0.45s forwards;
}

@keyframes drawCheck {
  to {
    stroke-dashoffset: 0;
  }
}

.approved-title {
  margin: 0 0 0.75rem;
  font-size: clamp(1.5rem, 5vw, 1.75rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--ink);
  animation: fadeRise 0.5s var(--ease-out) 0.2s both;
}

.approved-line1,
.approved-line2 {
  margin: 0;
  font-size: 0.9375rem;
  color: var(--muted);
  font-weight: 500;
  max-width: 36ch;
  margin-left: auto;
  margin-right: auto;
}

.approved-line1 {
  animation: fadeRise 0.5s var(--ease-out) 0.28s both;
}

.approved-line2 {
  margin-top: 0.5rem;
  animation: fadeRise 0.5s var(--ease-out) 0.36s both;
}

.approved-accent {
  width: 56px;
  height: 4px;
  border-radius: 999px;
  background: var(--accent-bar);
  margin: 1.75rem auto 0;
  animation: fadeRise 0.5s var(--ease-out) 0.44s both;
}

.hidden {
  display: none !important;
}

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

  .loader-ring {
    animation: none;
    border-top-color: var(--cta);
  }

  .check-path {
    stroke-dashoffset: 0;
  }
}
