/* ==================================================
   Contact Page
   Calm utility layout for direct communication
   ================================================== */

.contact-page {
  --contact-walnut: #7a5a3a;
  overflow: clip;
}

.contact-hero {
  position: relative;
  padding: clamp(56px, 7vw, 82px) 0 clamp(50px, 6vw, 70px);
  overflow: hidden;
  background:
    radial-gradient(circle at 82% 35%, rgba(197, 154, 74, 0.12), transparent 27%),
    linear-gradient(135deg, #fbf7ef 0%, #f8f3ea 62%, #eef5f2 100%);
  border-bottom: 1px solid rgba(51, 47, 45, 0.07);
}

.contact-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
  align-items: center;
  gap: clamp(38px, 7vw, 88px);
}

.contact-hero-copy {
  max-width: 760px;
}

.contact-hero-copy h1 {
  margin-bottom: 18px;
  font-size: clamp(2.75rem, 5vw, 4.7rem);
}

.contact-hero-copy > p:last-child {
  max-width: 690px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: clamp(1rem, 1.5vw, 1.1rem);
}

.contact-hero-visual {
  position: relative;
  display: grid;
  justify-self: end;
  place-items: center;
  width: min(43vw, 540px);
  min-height: 300px;
  isolation: isolate;
}

.contact-hero-visual::before {
  position: absolute;
  inset: 10% 2% 2%;
  z-index: -1;
  background: radial-gradient(circle at 50% 48%, rgba(225, 193, 126, 0.24) 0%, rgba(244, 226, 188, 0.16) 42%, rgba(47, 125, 120, 0.05) 64%, transparent 78%);
  border-radius: 50%;
  content: "";
  filter: blur(14px);
  opacity: 0;
  transform: scale(0.76);
  animation: contact-hero-bloom-reveal 1100ms cubic-bezier(0.2, 0.7, 0.2, 1) 90ms forwards;
  pointer-events: none;
}

.contact-hero-reveal {
  display: grid;
  place-items: center;
  width: 100%;
}

.contact-hero-image {
  display: block;
  width: min(100%, 530px);
  max-height: 320px;
  object-fit: contain;
  filter: drop-shadow(0 20px 24px rgba(51, 47, 45, 0.14));
}

@keyframes contact-hero-bloom-reveal {
  from {
    opacity: 0;
    transform: scale(0.76);
  }

  to {
    opacity: 0.9;
    transform: scale(1);
  }
}
.contact-main-section {
  background: var(--white);
}

.contact-main-grid {
  display: grid;
  grid-template-columns: minmax(280px, 0.82fr) minmax(0, 1.18fr);
  grid-template-areas: "help form";
  align-items: start;
  gap: clamp(28px, 5vw, 64px);
}

.contact-help-panel {
  grid-area: help;
  padding: clamp(28px, 4vw, 42px);
  background:
    linear-gradient(145deg, rgba(251, 247, 239, 0.96), rgba(241, 232, 216, 0.72));
  border: 1px solid rgba(51, 47, 45, 0.08);
  border-radius: var(--radius-large);
  box-shadow: 0 18px 48px rgba(51, 47, 45, 0.07);
}

.contact-help-panel h2,
.contact-form-panel h2 {
  margin-bottom: 16px;
  font-size: clamp(2rem, 3.3vw, 3rem);
}

.contact-help-copy > p:last-child,
.contact-answer-block > p {
  color: var(--muted);
}

.contact-email-block,
.contact-answer-block {
  padding-top: 26px;
  margin-top: 28px;
  border-top: 1px solid rgba(51, 47, 45, 0.1);
}

.contact-small-label {
  margin-bottom: 7px;
  color: var(--contact-walnut);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.contact-email-link {
  display: inline-flex;
  max-width: 100%;
  color: var(--teal-dark);
  font-weight: 700;
  overflow-wrap: anywhere;
  text-decoration: underline;
  text-decoration-color: rgba(47, 125, 120, 0.3);
  text-underline-offset: 4px;
}

.contact-email-link:hover {
  color: var(--gold-dark);
  text-decoration-color: currentColor;
}

.contact-email-link:focus-visible,
.contact-future-link:focus-visible,
.contact-social-link:focus-visible {
  outline: 3px solid rgba(47, 125, 120, 0.28);
  outline-offset: 4px;
  border-radius: 6px;
}

.contact-answer-block h3 {
  margin-bottom: 8px;
  font-family: var(--font-display);
  font-size: 1.35rem;
}

.contact-answer-block > p {
  margin-bottom: 18px;
  font-size: 0.92rem;
}

.contact-future-links {
  display: grid;
  gap: 9px;
}

.contact-future-link {
  display: flex;
  min-height: 44px;
  padding: 10px 12px;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--text);
  background: rgba(255, 255, 255, 0.68);
  border: 1px solid rgba(51, 47, 45, 0.08);
  border-radius: 12px;
}

.contact-future-link small {
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.contact-form-panel {
  grid-area: form;
  min-width: 0;
  padding: clamp(28px, 4vw, 46px);
  background: var(--cream);
  border: 1px solid rgba(51, 47, 45, 0.09);
  border-radius: var(--radius-large);
  box-shadow: var(--shadow);
}

.contact-form-heading {
  margin-bottom: 28px;
}

.contact-form-heading h2 {
  margin-bottom: 0;
}

.contact-form {
  display: grid;
  gap: 21px;
}

.contact-field {
  display: grid;
  gap: 8px;
}

.contact-field label {
  color: var(--text);
  font-size: 0.9rem;
  font-weight: 800;
}

.contact-required {
  color: var(--coral);
}

.contact-field input,
.contact-field select,
.contact-field textarea {
  width: 100%;
  min-height: 50px;
  padding: 12px 14px;
  color: var(--text);
  background: var(--white);
  border: 1px solid rgba(51, 47, 45, 0.18);
  border-radius: 12px;
  font: inherit;
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.contact-field textarea {
  min-height: 168px;
  resize: vertical;
}

.contact-field input:hover,
.contact-field select:hover,
.contact-field textarea:hover {
  border-color: rgba(47, 125, 120, 0.38);
}

.contact-field input:focus-visible,
.contact-field select:focus-visible,
.contact-field textarea:focus-visible {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 4px rgba(47, 125, 120, 0.13);
}

.contact-field [aria-invalid="true"] {
  border-color: var(--coral);
  background: rgba(214, 123, 104, 0.045);
}

.contact-field [aria-invalid="true"]:focus-visible {
  box-shadow: 0 0 0 4px rgba(214, 123, 104, 0.12);
}

.contact-field-error {
  color: #9a4d40;
  font-size: 0.8rem;
  font-weight: 600;
}

.contact-submit {
  width: fit-content;
  min-width: 158px;
  min-height: 48px;
  margin-top: 2px;
}

.contact-form-status {
  padding: 15px 17px;
  margin-top: 2px;
  border: 1px solid rgba(51, 47, 45, 0.1);
  border-radius: 12px;
  font-size: 0.9rem;
  line-height: 1.55;
}

.contact-form-status strong {
  display: block;
  margin-bottom: 3px;
}

.contact-form-status[data-state="preview"] {
  color: #5f503d;
  background: rgba(197, 154, 74, 0.1);
  border-color: rgba(197, 154, 74, 0.25);
}

.contact-form-status[data-state="success"] {
  color: var(--teal-dark);
  background: rgba(47, 125, 120, 0.08);
  border-color: rgba(47, 125, 120, 0.23);
}

.contact-form-status[data-state="error"] {
  color: #8f463b;
  background: rgba(214, 123, 104, 0.08);
  border-color: rgba(214, 123, 104, 0.24);
}

.contact-social-section {
  background: var(--cream-deep);
  border-top: 1px solid rgba(51, 47, 45, 0.07);
}

.contact-social-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 36px;
}

.contact-social-inner h2 {
  margin-bottom: 0;
  font-size: clamp(1.9rem, 3vw, 2.8rem);
}

.contact-social-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.contact-social-link {
  display: inline-flex;
  min-width: 48px;
  min-height: 48px;
  padding: 9px 13px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: var(--charcoal);
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(51, 47, 45, 0.1);
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 700;
  transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}

.contact-social-link svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

@media (hover: hover) and (pointer: fine) {
  .contact-help-panel,
  .contact-form-panel {
    transition: transform 180ms ease, box-shadow 180ms ease;
  }

  .contact-help-panel:hover,
  .contact-form-panel:hover {
    transform: translateY(-2px);
  }

  .contact-social-link:hover {
    transform: translateY(-2px);
    border-color: rgba(47, 125, 120, 0.28);
    box-shadow: 0 10px 24px rgba(51, 47, 45, 0.08);
  }
}

@media (max-width: 900px) {
  .contact-hero-grid {
    grid-template-columns: minmax(0, 1fr) minmax(280px, 0.9fr);
    gap: 30px;
  }

  .contact-hero-visual {
    width: min(42vw, 430px);
    min-height: 250px;
  }

  .contact-hero-image {
    max-height: 280px;
  }

  .contact-main-grid {
    grid-template-columns: minmax(240px, 0.78fr) minmax(0, 1.22fr);
    gap: 26px;
  }
}

@media (max-width: 720px) {
  .contact-hero {
    padding: 48px 0 44px;
  }

  .contact-hero-grid {
    grid-template-columns: 1fr;
    gap: 22px;
  }

  .contact-hero-visual {
    width: min(100%, 460px);
    min-height: 230px;
    justify-self: center;
  }

  .contact-hero-image {
    max-height: 260px;
  }

  .contact-main-grid {
    grid-template-columns: 1fr;
    grid-template-areas:
      "form"
      "help";
    gap: 24px;
  }

  .contact-form-panel,
  .contact-help-panel {
    padding: 26px 22px;
    border-radius: 24px;
  }

  .contact-submit {
    width: 100%;
  }

  .contact-social-inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .contact-social-links {
    justify-content: flex-start;
  }
}

@media (max-width: 420px) {
  .contact-hero-copy h1 {
    font-size: clamp(2.55rem, 13vw, 3.35rem);
  }

  .contact-hero-visual {
    min-height: 205px;
  }

  .contact-hero-image {
    max-height: 225px;
  }

  .contact-future-link {
    align-items: flex-start;
    flex-direction: column;
    gap: 2px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .contact-help-panel,
  .contact-form-panel,
  .contact-social-link,
  .contact-field input,
  .contact-field select,
  .contact-field textarea {
    transition: none;
  }

  .contact-hero-visual::before {
    animation: none;
    opacity: 0.9;
    transform: none;
  }
}

/* Contact form delivery/security helpers */
.contact-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;
}

.contact-turnstile {
  width: 100%;
  min-height: 0;
}

.contact-turnstile:not([hidden]) {
  margin-top: 2px;
}

.contact-submit[disabled] {
  cursor: wait;
  opacity: 0.72;
}

.contact-form.is-submitting input,
.contact-form.is-submitting select,
.contact-form.is-submitting textarea {
  cursor: wait;
}

@media (prefers-reduced-motion: reduce) {
  .contact-submit {
    transition: none;
  }
}
