/*
 * Alf Theme — Contact Form Section
 * Figma node: 631:4808
 *
 * Cream background, white card with drop-shadow.
 * CF7 form fields are styled here to match the Figma input designs.
 */

/* ═══════════════════════════════════════════════════════════════════
   SECTION
   ═══════════════════════════════════════════════════════════════════ */
.contact-form {
  background-color: var(--color-bg, #f8faf0);
  padding-top: 80px;
  padding-bottom: 80px;
}

/* ── Card ───────────────────────────────────────────────────────── */
.cform__card {
  background: #ffffff;
  border-radius: 10px;
  box-shadow: 0 10px 7.5px rgba(0, 0, 0, 0.1), 0 4px 3px rgba(0, 0, 0, 0.1);
  padding: 48px;
  display: flex;
  flex-direction: column;
  gap: 40px;
}

/* ═══════════════════════════════════════════════════════════════════
   HEADER
   ═══════════════════════════════════════════════════════════════════ */
.cform__header {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

/* D Semi Bold H2 */
.cform__title {
  font-size: 36px;
  font-weight: 600;
  line-height: 1;
  color: var(--color-dark, #252525);
  margin: 0;
}

/* D Regular H4 */
.cform__desc {
  font-size: 20px;
  font-weight: 400;
  line-height: 1;
  color: #ababab;
  margin: 0;
}

.cform__notice {
  color: #ababab;
  font-size: 14px;
}

/* ═══════════════════════════════════════════════════════════════════
   CONTACT FORM 7 — FORM LAYOUT
   ═══════════════════════════════════════════════════════════════════ */

/* Remove CF7 default paragraph spacing */
.cform__card .wpcf7 p,
.cform__card .wpcf7 br {
  display: none;
}

.cform__card .wpcf7-form {
  display: flex;
  flex-direction: column;
  gap: 24px;
  width: 100%;
}

.cform__card .wpcf7-form-control-wrap {
  display: block;
  width: 100%;
}

/* ── Field group: label + input ─────────────────────────────────── */
.cform__field-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1 0 0;
  min-width: 226px;
}

/* ── Two fields side by side ────────────────────────────────────── */
.cform__row {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  align-items: flex-start;
}

/* ── Label ──────────────────────────────────────────────────────── */
.cform__label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 16px;
  font-weight: 600;
  color: var(--color-dark, #252525);
  line-height: 1;
}

/* ── Label icon (SVG) ───────────────────────────────────────────── */
.cform__label-icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  /* Resolve Figma SVG CSS variables */
  --stroke-0: #cd261d;
  --fill-0: #cd261d;
}

/* ═══════════════════════════════════════════════════════════════════
   INPUTS
   ═══════════════════════════════════════════════════════════════════ */
.cform__card .wpcf7-text,
.cform__card .wpcf7-email,
.cform__card .wpcf7-tel,
.cform__card .wpcf7-select,
.cform__card input[type="text"],
.cform__card input[type="email"],
.cform__card input[type="tel"],
.cform__card select {
  width: 100%;
  height: 50px;
  padding: 12px 16px;
  border: 1.27px solid #ababab;
  border-radius: 10px;
  font-size: 16px;
  font-weight: 400;
  font-family: inherit;
  color: var(--color-dark, #252525);
  background: #fff;
  outline: none;
  appearance: none;
  transition: border-color 0.2s;
  box-sizing: border-box;
}

.cform__card .wpcf7-text::placeholder,
.cform__card .wpcf7-email::placeholder,
.cform__card .wpcf7-tel::placeholder,
.cform__card input::placeholder {
  color: #ababab;
}

.cform__card .wpcf7-text:focus,
.cform__card .wpcf7-email:focus,
.cform__card .wpcf7-tel:focus,
.cform__card input:focus,
.cform__card select:focus {
  border-color: var(--color-primary, #cd261d);
}

/* ── Select: custom dropdown arrow ─────────────────────────────── */
.cform__select-wrap {
  position: relative;
  width: 100%;
}

.cform__select-wrap::after {
  content: '';
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none'%3E%3Cpath d='M6 9l6 6 6-6' stroke='%23252525' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-size: contain;
  pointer-events: none;
}

.cform__select-wrap select {
  padding-right: 48px;
  cursor: pointer;
  width: 100%;
}

/* ── Textarea ───────────────────────────────────────────────────── */
.cform__card .wpcf7-textarea,
.cform__card textarea {
  width: 100%;
  height: 170px;
  padding: 12px 16px;
  border: 1.27px solid #ababab;
  border-radius: 10px;
  font-size: 16px;
  font-weight: 400;
  font-family: inherit;
  color: var(--color-dark, #252525);
  background: #fff;
  outline: none;
  resize: vertical;
  transition: border-color 0.2s;
  box-sizing: border-box;
}

.cform__card .wpcf7-textarea::placeholder,
.cform__card textarea::placeholder {
  color: #ababab;
}

.cform__card .wpcf7-textarea:focus,
.cform__card textarea:focus {
  border-color: var(--color-primary, #cd261d);
}

/* ── Submit button — uses alf-btn animation system ──────────────── */
.cform__submit {
  background: var(--color-primary, #cd261d);
  color: var(--color-bg, #f8faf0);
  border: none;
  border-radius: 8px;
  padding: 14px 24px;
  min-width: 200px;
  max-width: 343px;
  font-size: 16px;
  font-weight: 400;
  font-family: inherit;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  cursor: pointer;
  /* alf-btn layout (flex row, gap, height auto) */
  display: inline-flex;
  align-items: center;
  gap: var(--spacing-xs, 8px);
  line-height: 1;
  white-space: nowrap;
  transition: opacity 0.2s;
}

.cform__submit:hover {
  opacity: 0.88;
}

/* ── Validation messages ────────────────────────────────────────── */
.cform__card .wpcf7-not-valid-tip {
  color: var(--color-primary, #cd261d);
  font-size: 13px;
  margin-top: 4px;
  display: block;
}

.cform__card .wpcf7-response-output {
  border: none;
  padding: 12px 16px;
  border-radius: 8px;
  font-size: 14px;
  margin-top: 0;
}

.cform__card .wpcf7-mail-sent-ok {
  background: #e8f5e9;
  color: #2e7d32;
}

.cform__card .wpcf7-mail-sent-ng,
.cform__card .wpcf7-spam-blocked,
.cform__card .wpcf7-acceptance-missing {
  background: #fdecea;
  color: var(--color-primary, #cd261d);
}

/* ═══════════════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════════════ */
@media (max-width: 900px) {
  .cform__card {
    padding: 40px 32px;
  }

  .cform__title {
    font-size: 28px;
  }

  .cform__desc {
    font-size: 18px;
  }
}

@media (max-width: 640px) {
  .contact-form {
    padding-top: 48px;
    padding-bottom: 48px;
  }

  .cform__card {
    padding: 24px 20px;
    gap: 28px;
  }

  .cform__header {
    gap: 16px;
  }

  .cform__title {
    font-size: 24px;
  }

  .cform__desc {
    font-size: 16px;
  }

  .cform__row {
    flex-direction: column;
    gap: 16px;
  }

  .cform__field-group {
    min-width: unset;
    width: 100%;
  }
}