/* ============================================================
   page-contact.css — Contact Page
   B.I.Y Corporate Design System
   ============================================================ */

.contact-hero { padding-bottom: 100px; }

/* ── Form Card ─────────────────────────────────────────── */
.contact-form-section {
  background-color: var(--color-bg-cream);
}

.contact-form-card {
  background: var(--color-white);
  padding: 72px 80px;
  border: 1px solid var(--color-border-soft);
  position: relative;
  box-shadow: var(--shadow-sm);
}

.contact-form-card::before,
.contact-form-card::after {
  content: "";
  position: absolute;
  width: 20px;
  height: 20px;
  border: 1px solid var(--color-gold);
}

.contact-form-card::before {
  top: -1px;
  left: -1px;
  border-right: none;
  border-bottom: none;
}

.contact-form-card::after {
  bottom: -1px;
  right: -1px;
  border-left: none;
  border-top: none;
}

.contact-form-card__header {
  text-align: center;
  margin-bottom: 56px;
}

.contact-form-card__eyebrow {
  display: inline-block;
  font-family: var(--font-serif-en);
  font-size: var(--fs-xs);
  letter-spacing: var(--tracking-widest);
  text-transform: uppercase;
  color: var(--color-gold);
  margin-bottom: 16px;
  font-weight: var(--fw-medium);
}

.contact-form-card__title {
  font-family: var(--font-serif-ja);
  font-size: var(--fs-h3);
  font-weight: var(--fw-bold);
  color: var(--color-navy);
  letter-spacing: 0.08em;
  margin-bottom: 20px;
}

.contact-form-card__rule {
  width: 40px;
  height: 1px;
  background: var(--color-gold);
  margin: 0 auto;
}

/* ── Form internals ────────────────────────────────────── */
.contact-form__divider {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 16px 0 32px;
}

.contact-form__divider-line {
  flex: 1;
  height: 1px;
  background: var(--color-border-soft);
}

.contact-form__divider-label {
  font-family: var(--font-serif-en);
  font-size: var(--fs-xs);
  letter-spacing: var(--tracking-widest);
  text-transform: uppercase;
  color: var(--color-gold);
  font-weight: var(--fw-medium);
}

.wpcf7 .contact-form__divider > p {
  display: contents;
}

.wpcf7 .contact-form__divider br {
  display: none;
}

.form-field__counter {
  text-align: right;
  font-size: 11px;
  color: var(--color-text-muted);
  letter-spacing: var(--tracking-wide);
  margin-top: 6px;
  font-family: var(--font-serif-en);
}

.contact-form__submit {
  margin-top: 48px;
  text-align: center;
}

.contact-form__submit-btn {
  width: 100%;
  max-width: 480px;
  padding: 22px 40px;
  font-size: var(--fs-md);
}

.contact-form__privacy {
  margin-top: 24px;
  font-size: var(--fs-xs);
  color: var(--color-text-light);
  letter-spacing: 0.04em;
  line-height: 1.8;
}

.contact-form__privacy-link {
  color: var(--color-gold);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.contact-form__privacy-link:hover { color: var(--color-gold-deep); }

/* ── Contact Form 7 ────────────────────────────────────── */
.wpcf7 form.contact-form--cf7 {
  display: block;
}

.wpcf7 form.contact-form--cf7 > fieldset {
  display: none;
}

.wpcf7 form.contact-form--cf7 > p {
  margin: 0;
}

.wpcf7 form.contact-form--cf7 label {
  display: block;
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  color: var(--color-navy);
  letter-spacing: var(--tracking-wide);
  line-height: 1.6;
}

.wpcf7 form.contact-form--cf7 label br {
  display: none;
}

.wpcf7 form.contact-form--cf7 .wpcf7-form-control-wrap {
  display: block;
}

.cf7-field-row {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 28px;
  align-items: center;
  margin-bottom: 28px;
}

.cf7-field-row--textarea {
  align-items: start;
}

.cf7-field-row__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-width: 0;
}

.cf7-field-row__label {
  color: var(--color-navy);
  font-size: var(--fs-sm);
  font-weight: var(--fw-bold);
  letter-spacing: var(--tracking-wide);
  line-height: 1.6;
}

.cf7-field-row__badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  min-width: 42px;
  padding: 4px 9px;
  background: var(--color-gold);
  color: var(--color-white);
  font-size: 11px;
  font-weight: var(--fw-bold);
  letter-spacing: 0.08em;
  line-height: 1.3;
}

.cf7-field-row__body {
  min-width: 0;
}

.cf7-field-row__body--pair {
  display: block;
}

.cf7-field-row__body--pair > p {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin: 0;
}

.cf7-field-row__body--pair .wpcf7-form-control-wrap {
  min-width: 0;
}

.cf7-field-row .form-field__counter {
  margin-top: 8px;
}

.wpcf7 form.contact-form--cf7 input[type="text"],
.wpcf7 form.contact-form--cf7 input[type="email"],
.wpcf7 form.contact-form--cf7 input[type="tel"],
.wpcf7 form.contact-form--cf7 input[type="url"],
.wpcf7 form.contact-form--cf7 select,
.wpcf7 form.contact-form--cf7 textarea {
  min-height: 58px;
  background-color: #fffdfa;
  border-color: var(--color-border-soft);
  box-shadow: inset 0 1px 0 rgba(4, 16, 35, 0.02);
}

.wpcf7 form.contact-form--cf7 textarea {
  height: 190px;
  min-height: 160px;
}

.wpcf7 form.contact-form--cf7 input[type="submit"] {
  display: block;
  align-items: center;
  justify-content: center;
  width: min(100%, 420px);
  min-height: 64px;
  margin: 18px auto 0;
  padding: 20px 40px;
  background-color: var(--color-gold);
  border: 1px solid var(--color-gold);
  border-radius: var(--radius-none);
  color: var(--color-white);
  font-family: var(--font-sans-ja);
  font-size: var(--fs-md);
  font-weight: var(--fw-medium);
  letter-spacing: var(--tracking-wider);
  line-height: 1;
  cursor: pointer;
  transition: transform var(--transition-base), background-color var(--transition-base), box-shadow var(--transition-base);
  box-shadow: var(--shadow-gold);
  appearance: none;
  -webkit-appearance: none;
}

.wpcf7 form.contact-form--cf7 input[type="submit"]:hover {
  background-color: var(--color-gold-soft);
  transform: translateY(-2px);
  box-shadow: 0 16px 32px rgba(200, 168, 74, 0.32);
}

.wpcf7 form.contact-form--cf7 input[type="submit"]:disabled {
  opacity: 0.65;
  cursor: wait;
  transform: none;
}

.wpcf7 form.contact-form--cf7 .wpcf7-spinner {
  margin: 20px 0 0 16px;
}

.wpcf7 form.contact-form--cf7 .wpcf7-not-valid {
  border-color: #b94b4b;
  box-shadow: 0 0 0 3px rgba(185, 75, 75, 0.1);
}

.wpcf7 form.contact-form--cf7 .wpcf7-not-valid-tip {
  margin-top: 8px;
  font-size: var(--fs-xs);
  color: #b94b4b;
  letter-spacing: var(--tracking-wide);
}

.wpcf7 form.contact-form--cf7 .wpcf7-response-output {
  margin: 8px 0 0;
  padding: 16px 20px;
  border: 1px solid var(--color-gold-line);
  background: rgba(200, 168, 74, 0.08);
  color: var(--color-navy);
  font-size: var(--fs-sm);
  line-height: 1.8;
}

.contact-form__privacy--cf7 {
  max-width: 680px;
  margin: 28px auto 0;
  text-align: center;
}

/* ── Other contacts ────────────────────────────────────── */
.contact-other__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  max-width: 1080px;
  margin: 0 auto;
}

.contact-other__card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 56px 32px;
  background: var(--color-bg-cream);
  border: 1px solid var(--color-border-soft);
  position: relative;
  transition: border-color var(--transition-base), transform var(--transition-base), box-shadow var(--transition-base);
  color: inherit;
}

a.contact-other__card:hover {
  border-color: var(--color-gold);
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.contact-other__icon {
  width: 56px;
  height: 56px;
  margin-bottom: 24px;
  background: var(--color-navy);
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px;
  color: var(--color-gold);
}

.contact-other__icon svg {
  width: 100%;
  height: 100%;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
}

.contact-other__label {
  font-family: var(--font-serif-en);
  font-size: var(--fs-xs);
  letter-spacing: var(--tracking-widest);
  text-transform: uppercase;
  color: var(--color-gold);
  margin-bottom: 8px;
}

.contact-other__title {
  font-family: var(--font-sans-ja);
  font-size: var(--fs-sm);
  color: var(--color-text-light);
  letter-spacing: var(--tracking-wide);
  margin-bottom: 18px;
}

.contact-other__value {
  font-family: var(--font-serif-en);
  font-size: 28px;
  color: var(--color-navy);
  font-weight: var(--fw-semibold);
  letter-spacing: 0.04em;
  margin-bottom: 16px;
  line-height: 1.2;
}

.contact-other__value--mail {
  font-size: 22px;
  word-break: break-all;
}

.contact-other__qr {
  width: 140px;
  height: 140px;
  background: var(--color-white);
  border: 1px solid var(--color-border);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px;
  margin-bottom: 18px;
}

.contact-other__qr img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.contact-other__sub {
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
  line-height: 1.8;
  letter-spacing: var(--tracking-wide);
}

/* ── Responsive ────────────────────────────────────────── */
.md-only { display: none; }

@media screen and (max-width: 992px) {
  .contact-form-card { padding: 56px 48px; }
  .contact-other__grid { grid-template-columns: 1fr; max-width: 480px; }
  .md-only { display: inline; }
}

@media screen and (max-width: 768px) {
  .contact-form-card { padding: 40px 28px; }
  .cf7-field-row {
    grid-template-columns: 1fr;
    gap: 12px;
    margin-bottom: 26px;
  }
  .cf7-field-row__head {
    justify-content: flex-start;
  }
  .cf7-field-row__body--pair {
    display: block;
  }
  .cf7-field-row__body--pair > p {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .wpcf7 form.contact-form--cf7 input[type="submit"] { min-height: 58px; }
  .form-row-pair { grid-template-columns: 1fr; gap: 0; }
  .form-row-pair .form-field { margin-bottom: 32px; }
  .contact-other__card { padding: 40px 24px; }
  .contact-other__value { font-size: 24px; }
  .contact-other__value--mail { font-size: 18px; }
}
