/* ═══════════════════════════════════════════════════════════════
   LUNAR INSPECTIONS — SCHEDULE INSPECTION FORM
   Dark-theme native request form (replaces Spectora iframe).
   Extends site-core.css tokens. Loaded AFTER schedule-inspection.css
   so its section-scoped styles win inside .schedule-form-section.
   ═══════════════════════════════════════════════════════════════ */

/* ─── Section shell (dark aerospace surface) ─────────────────── */
.schedule-form-section {
  background:
    radial-gradient(720px 380px at 12% 8%, rgba(66,133,244,0.10), transparent 60%),
    radial-gradient(620px 320px at 92% 100%, rgba(34,211,238,0.06), transparent 65%),
    linear-gradient(180deg, #02030a 0%, #060912 60%, #02030a 100%);
  color: var(--text-primary);
  padding: clamp(56px, 7vw, 96px) 0;
}
.schedule-form-section .container { position: relative; }
.schedule-form-header { max-width: 780px; margin: 0 auto clamp(28px, 3.4vw, 40px); text-align: center; }
.schedule-form-header .eyebrow { justify-content: center; color: var(--accent-light); }
.schedule-form-header h2 { font-size: clamp(28px, 3.6vw, 44px); color: #fff; letter-spacing: -0.02em; }
.schedule-form-header p { font-size: 16.5px; color: var(--text-tertiary); margin-top: 14px; line-height: 1.65; }

.schedule-status-banner {
  display: flex; align-items: flex-start; gap: 14px;
  max-width: 940px; margin: 0 auto clamp(24px, 2.6vw, 30px);
  padding: 16px 20px; border-radius: var(--radius-md);
  background: rgba(66,133,244,0.09);
  border: 1px solid rgba(66,133,244,0.32);
  color: var(--text-secondary);
}
.schedule-status-banner i { flex: none; margin-top: 3px; font-size: 15px; color: var(--accent-light); }
.schedule-status-banner p { margin: 0; font-size: 14.5px; line-height: 1.6; color: var(--text-secondary); }

/* ─── The form card ───────────────────────────────────────────── */
.schedule-form-card {
  max-width: 980px; margin: 0 auto;
  background: linear-gradient(180deg, rgba(15,20,36,0.85), rgba(9,13,26,0.85));
  border: 1px solid var(--border-card);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-glass), 0 30px 80px rgba(0,0,0,0.55);
  padding: clamp(24px, 3vw, 40px);
  backdrop-filter: blur(18px) saturate(1.2);
  -webkit-backdrop-filter: blur(18px) saturate(1.2);
  position: relative;
  overflow: hidden;
}
.schedule-form-card::before {
  content: ''; position: absolute; inset: 0; pointer-events: none; border-radius: inherit;
  background: linear-gradient(135deg, rgba(255,255,255,0.05), transparent 42%);
}
.schedule-form-card > * { position: relative; }

/* Honeypot: visually hidden but not display:none (bots skip display:none) */
.honeypot {
  position: absolute !important;
  left: -10000px !important; top: auto !important;
  width: 1px !important; height: 1px !important;
  overflow: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

/* ─── Fieldset / section grouping ────────────────────────────── */
.form-section { border: 0; padding: 0; margin: 0 0 clamp(28px, 3vw, 40px); }
.form-section + .form-section { border-top: 1px solid var(--border-subtle); padding-top: clamp(28px, 3vw, 36px); }
.form-section > legend { padding: 0; }
.form-section-head {
  display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap;
  margin-bottom: clamp(16px, 1.8vw, 22px);
}
.form-section-num {
  display: inline-grid; place-items: center;
  width: 30px; height: 30px; border-radius: 50%;
  font-family: var(--font-display); font-size: 13px; font-weight: 600; color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-electric));
  box-shadow: 0 4px 14px rgba(66,133,244,0.35);
  flex: none;
}
.form-section-title {
  font-family: var(--font-display);
  font-size: clamp(18px, 2vw, 22px);
  color: #fff; letter-spacing: -0.015em;
  font-weight: 600;
}
.form-section-hint { flex-basis: 100%; font-size: 13.5px; color: var(--text-tertiary); line-height: 1.55; margin-top: 2px; }

/* ─── Fields ─────────────────────────────────────────────────── */
.f-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 18px; }
.f-grid .f-span-2 { grid-column: 1 / -1; }
@media (max-width: 640px) { .f-grid { grid-template-columns: 1fr; } }

.f-field { display: block; margin: 0; }
.f-field > .f-label {
  display: block; font-size: 11.5px; letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--text-tertiary); font-weight: 600; margin-bottom: 7px;
}
.f-field > .f-label .req { color: var(--accent-cyan); margin-left: 3px; }
.f-field > .f-label .opt { color: var(--text-muted); font-weight: 500; text-transform: none; letter-spacing: 0; margin-left: 6px; font-size: 11px; }

.f-input,
.f-select,
.f-textarea {
  width: 100%;
  padding: 12px 14px;
  font-family: inherit; font-size: 14.5px; color: #fff;
  background: rgba(0,0,0,0.42);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  transition: border-color .18s ease, box-shadow .18s ease, background .18s ease;
  outline: none;
  -webkit-appearance: none; appearance: none;
}
.f-textarea { min-height: 120px; resize: vertical; font-family: inherit; line-height: 1.55; }
.f-input::placeholder, .f-textarea::placeholder { color: var(--text-muted); }
.f-input:focus, .f-select:focus, .f-textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
  background: rgba(0,0,0,0.52);
}
.f-select {
  appearance: none; -webkit-appearance: none; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M2 4l4 4 4-4' stroke='%238ab4f8' stroke-width='1.6' fill='none'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center;
  padding-right: 36px;
}
.f-select option { background: #0b0e18; color: #fff; }

.f-input[aria-invalid="true"],
.f-select[aria-invalid="true"],
.f-textarea[aria-invalid="true"] {
  border-color: #f87171;
  box-shadow: 0 0 0 3px rgba(248,113,113,0.18);
}
.f-error {
  display: none; font-size: 12.5px; color: #fca5a5; margin-top: 6px; line-height: 1.4;
}
.f-error.is-visible { display: block; }
.f-help { font-size: 12.5px; color: var(--text-muted); margin-top: 6px; line-height: 1.45; }

/* Toggle (switch) */
.f-toggle {
  display: flex; align-items: center; gap: 14px;
  padding: 14px 16px;
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-sm);
  cursor: pointer;
  user-select: none;
  transition: background .18s ease, border-color .18s ease;
}
.f-toggle:hover { background: rgba(255,255,255,0.06); border-color: rgba(255,255,255,0.22); }
.f-toggle-input { position: absolute; opacity: 0; pointer-events: none; }
.f-toggle-switch {
  position: relative; width: 42px; height: 24px; flex: none;
  background: rgba(255,255,255,0.15); border-radius: 999px;
  transition: background .2s ease;
}
.f-toggle-switch::after {
  content: ''; position: absolute; top: 3px; left: 3px;
  width: 18px; height: 18px; border-radius: 50%;
  background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,0.5);
  transition: transform .2s ease;
}
.f-toggle-input:checked + .f-toggle-switch { background: var(--accent); }
.f-toggle-input:checked + .f-toggle-switch::after { transform: translateX(18px); }
.f-toggle-input:focus-visible + .f-toggle-switch { box-shadow: 0 0 0 3px var(--accent-glow); }
.f-toggle-text { display: flex; flex-direction: column; gap: 3px; }
.f-toggle-text .t-title { font-size: 14.5px; color: #fff; font-weight: 600; letter-spacing: -0.005em; }
.f-toggle-text .t-sub { font-size: 12.5px; color: var(--text-tertiary); line-height: 1.45; }

/* Collapsible conditional section */
.f-conditional {
  display: grid; grid-template-rows: 0fr;
  transition: grid-template-rows .35s var(--ease-out), margin .35s var(--ease-out), opacity .3s ease;
  opacity: 0;
  margin-top: 0;
}
.f-conditional > .f-conditional-inner {
  min-height: 0; overflow: hidden;
}
.f-conditional.is-open {
  grid-template-rows: 1fr;
  opacity: 1;
  margin-top: 18px;
}

/* Service chips */
.f-chips {
  display: flex; flex-wrap: wrap; gap: 8px;
  margin-bottom: 14px;
}
.f-chip {
  position: relative;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 14px 9px 12px;
  font-size: 13px; font-weight: 500; color: var(--text-secondary);
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-pill);
  cursor: pointer; user-select: none;
  transition: background .15s ease, border-color .15s ease, color .15s ease;
}
.f-chip:hover { background: rgba(255,255,255,0.08); color: #fff; }
.f-chip-input {
  position: absolute; opacity: 0; pointer-events: none; width: 0; height: 0;
}
.f-chip .chip-dot {
  width: 14px; height: 14px; border-radius: 50%;
  border: 1.5px solid rgba(255,255,255,0.35);
  display: grid; place-items: center;
  transition: background .15s ease, border-color .15s ease;
  flex: none;
}
.f-chip .chip-dot::after {
  content: ''; width: 6px; height: 6px; border-radius: 50%;
  background: #fff; transform: scale(0); transition: transform .18s ease;
}
.f-chip-input:checked + .chip-dot {
  background: var(--accent); border-color: var(--accent);
}
.f-chip-input:checked + .chip-dot::after { transform: scale(1); }
.f-chip:has(.f-chip-input:checked) {
  background: rgba(66,133,244,0.14);
  border-color: rgba(66,133,244,0.55);
  color: #fff;
}
.f-chip-input:focus-visible + .chip-dot { box-shadow: 0 0 0 3px var(--accent-glow); }

/* Consent + reCAPTCHA notice */
.f-consent {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 16px 18px;
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  margin-top: 8px;
}
.f-consent-input { flex: none; margin-top: 3px; width: 18px; height: 18px; accent-color: var(--accent); cursor: pointer; }
.f-consent-input:focus-visible { outline: 2px solid var(--accent-light); outline-offset: 3px; }
.f-consent-text { font-size: 13px; color: var(--text-tertiary); line-height: 1.6; }
.f-consent-text strong { color: var(--text-secondary); font-weight: 600; }

.f-recaptcha-notice {
  font-size: 11.5px; color: var(--text-muted); line-height: 1.6;
  margin: 18px 0 0; text-align: center;
}
.f-recaptcha-notice a { color: var(--accent-light); text-decoration: underline; text-underline-offset: 2px; }
.f-recaptcha-notice a:hover { color: #fff; }

.f-privacy-microcopy {
  font-size: 12.5px; color: var(--text-muted); line-height: 1.6;
  margin: 18px 0 0; text-align: center; max-width: 680px; margin-left: auto; margin-right: auto;
}

/* Submit row */
.f-submit-row {
  margin-top: 26px; display: flex; flex-direction: column; align-items: center; gap: 10px;
}
.f-submit {
  min-width: 260px;
  padding: 16px 34px;
  font-family: var(--font-primary); font-weight: 600; font-size: 15.5px; letter-spacing: 0.01em;
  color: #fff;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-electric) 100%);
  border: 0; border-radius: var(--radius-pill);
  box-shadow: 0 12px 32px var(--accent-glow), inset 0 1px 0 rgba(255,255,255,0.25);
  cursor: pointer;
  transition: transform .18s ease, box-shadow .18s ease, opacity .18s ease;
  position: relative;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
}
.f-submit:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 16px 40px var(--accent-glow), inset 0 1px 0 rgba(255,255,255,0.3); }
.f-submit:disabled { opacity: 0.72; cursor: not-allowed; }
.f-submit .spinner {
  display: none; width: 16px; height: 16px; border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.35); border-top-color: #fff;
  animation: f-spin .7s linear infinite;
}
.f-submit.is-loading .btn-label { opacity: 0.7; }
.f-submit.is-loading .spinner { display: inline-block; }
@keyframes f-spin { to { transform: rotate(360deg); } }

/* Form-level status banner (submission errors) */
.f-status {
  display: none;
  padding: 14px 18px;
  border-radius: var(--radius-md);
  font-size: 14px; line-height: 1.55;
  margin-top: 18px;
}
.f-status.is-visible { display: block; }
.f-status.is-error {
  color: #fecaca;
  background: rgba(239,68,68,0.12);
  border: 1px solid rgba(239,68,68,0.35);
}
.f-status.is-info {
  color: var(--text-secondary);
  background: rgba(66,133,244,0.10);
  border: 1px solid rgba(66,133,244,0.32);
}

/* ─── Success state ─────────────────────────────────────────── */
.f-success {
  display: none;
  text-align: center;
  padding: clamp(28px, 4vw, 44px) clamp(20px, 3vw, 32px);
}
.f-success.is-visible { display: block; }
.f-success .check {
  width: 68px; height: 68px; margin: 0 auto 22px;
  border-radius: 50%;
  display: grid; place-items: center;
  font-size: 30px;
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-electric));
  box-shadow: 0 12px 40px rgba(66,133,244,0.4);
}
.f-success h3 {
  font-family: var(--font-display); font-size: clamp(22px, 2.6vw, 28px);
  color: #fff; margin-bottom: 14px; letter-spacing: -0.015em;
}
.f-success p { font-size: 15px; color: var(--text-tertiary); line-height: 1.65; max-width: 620px; margin: 0 auto 12px; }
.f-success .success-actions {
  display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; margin-top: 22px;
}

/* Global helper – hide visually when needed */
.f-visually-hidden {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
