/* ============================================
   GROUP COACHING INTEREST FORM
   Custom-styled form to match the brand.
   Submission goes to MailerLite via JavaScript.
   ============================================ */

.gci-form-wrap {
  background: var(--paper);
  padding: var(--s-7) var(--s-6);
  border: 1px solid var(--whisper);
  max-width: 32rem;
  margin: var(--s-7) auto;
}

.gci-form {
  margin: 0;
}

.gci-field {
  margin-bottom: var(--s-5);
}

.gci-field--checkboxes {
  border: none;
  padding: 0;
  margin-bottom: var(--s-5);
}

.gci-field--consent {
  margin-bottom: var(--s-5);
}

.gci-label {
  display: block;
  font-family: var(--font-eyebrow);
  font-size: var(--t-eyebrow);
  font-weight: var(--w-medium);
  letter-spacing: var(--ls-wide);
  text-transform: uppercase;
  color: var(--ink);
  margin: 0 0 var(--s-3);
  line-height: 1.4;
}

.gci-label__optional {
  font-weight: var(--w-regular);
  color: var(--quiet);
  text-transform: none;
  letter-spacing: 0;
  font-size: 0.85em;
  font-style: italic;
}

.gci-input,
.gci-textarea {
  width: 100%;
  padding: var(--s-3) var(--s-4);
  font-family: var(--font-body);
  font-size: var(--t-body);
  line-height: var(--lh-snug);
  color: var(--ink);
  background: var(--cream);
  border: 1px solid var(--whisper);
  border-radius: 2px;
  transition: border-color 0.2s ease;
  box-sizing: border-box;
}

.gci-input:focus,
.gci-textarea:focus {
  outline: none;
  border-color: var(--sage);
}

.gci-input.is-error,
.gci-textarea.is-error {
  border-color: var(--umber);
}

.gci-textarea {
  resize: vertical;
  min-height: 6rem;
}

/* Checkbox list */
.gci-checkbox-list {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
}

.gci-checkbox {
  display: flex;
  align-items: flex-start;
  gap: var(--s-3);
  cursor: pointer;
  padding: var(--s-2) 0;
  -webkit-tap-highlight-color: transparent;
}

.gci-checkbox input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  width: 18px;
  height: 18px;
  border: 1px solid var(--whisper);
  border-radius: 2px;
  background: var(--cream);
  cursor: pointer;
  flex-shrink: 0;
  margin: 0;
  margin-top: 2px;
  position: relative;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.gci-checkbox input[type="checkbox"]:hover {
  border-color: var(--sage);
}

.gci-checkbox input[type="checkbox"]:focus-visible {
  outline: 2px solid var(--sage);
  outline-offset: 2px;
}

.gci-checkbox input[type="checkbox"]:checked {
  background: var(--sage);
  border-color: var(--sage);
}

.gci-checkbox input[type="checkbox"]:checked::after {
  content: '';
  position: absolute;
  left: 5px;
  top: 1px;
  width: 5px;
  height: 10px;
  border: solid var(--cream);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.gci-checkbox__label {
  font-family: var(--font-body);
  font-size: var(--t-body);
  line-height: var(--lh-snug);
  color: var(--ink);
  user-select: none;
}

.gci-checkbox--consent .gci-checkbox__label {
  font-size: var(--t-small);
  color: var(--muted);
}

/* Error and success states */
.gci-error {
  background: rgba(139, 74, 48, 0.08);
  border-left: 3px solid var(--umber);
  padding: var(--s-3) var(--s-4);
  margin-bottom: var(--s-4);
  font-family: var(--font-body);
  font-size: var(--t-small);
  color: var(--umber);
}

/* Submit button */
.gci-submit {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--s-4) var(--s-5);
  font-family: var(--font-eyebrow);
  font-size: var(--t-eyebrow);
  font-weight: var(--w-semibold);
  letter-spacing: var(--ls-wide);
  text-transform: uppercase;
  color: var(--cream);
  background: var(--umber);
  border: none;
  border-radius: 2px;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.gci-submit:hover {
  background: var(--umber-deep);
}

.gci-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.gci-fineprint {
  font-family: var(--font-eyebrow);
  font-size: var(--t-tiny);
  color: var(--quiet);
  text-align: center;
  margin: var(--s-4) 0 0;
  line-height: var(--lh-relaxed);
}

.gci-fineprint a {
  color: var(--sage);
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}

.gci-fineprint a:hover {
  color: var(--sage-deep);
}

/* Success state */
.gci-success {
  text-align: center;
  padding: var(--s-5) 0;
}

.gci-success__title {
  font-family: var(--font-display);
  font-size: var(--t-h3);
  font-weight: var(--w-regular);
  color: var(--ink);
  margin: 0 0 var(--s-4);
}

.gci-success__text {
  font-family: var(--font-body);
  font-size: var(--t-body);
  line-height: var(--lh-relaxed);
  color: var(--ink);
  margin: 0 0 var(--s-5);
}

.gci-success__signoff {
  font-family: var(--font-display);
  font-size: var(--t-small);
  font-style: italic;
  color: var(--sage);
  margin: 0;
}

@media (max-width: 640px) {
  .gci-form-wrap {
    padding: var(--s-5) var(--s-4);
  }

  .gci-checkbox__label {
    font-size: var(--t-small);
  }
}
