/* =========================================================================
   i2 Ministries — Contact Page Phase 4.6 Polish
   Loads AFTER inline <style>. home.css also linked for shared patterns.
   PRESERVES honeypot + time-gate + math-challenge + FormSubmit logic.
   ========================================================================= */

/* -------------------------------------------------------------------------
   PAGE HERO — "Contact Us"
   ------------------------------------------------------------------------- */
.page-hero {
  padding: clamp(6.5rem, 5rem + 5vw, 9rem) 0 clamp(2rem, 1.5rem + 1.5vw, 3.5rem);
}
.page-hero-inner {
  max-width: 780px;
}
.page-hero h1 {
  font-size: clamp(3rem, 2rem + 4vw, 5rem);
  line-height: 1.04;
  letter-spacing: -0.025em;
  font-weight: 400;
  margin-bottom: 20px;
  text-wrap: balance;
}
.page-hero h1 em {
  font-style: italic;
  color: var(--color-accent);
}
.page-hero .subtitle {
  font-size: clamp(1.0625rem, 0.95rem + 0.4vw, 1.25rem);
  line-height: 1.65;
  max-width: 54ch;
  margin-inline: auto;
  color: var(--color-text-muted);
}

/* -------------------------------------------------------------------------
   CONTACT GRID — form (left, wider) + sidebar (right)
   ------------------------------------------------------------------------- */
.contact-section {
  padding: clamp(1rem, 1rem + 1vw, 2rem) 0 clamp(5rem, 3rem + 4vw, 8rem);
}
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 0.75fr;
  gap: clamp(2rem, 1.5rem + 2vw, 3.5rem);
  align-items: start;
  max-width: 1100px;
  margin-inline: auto;
}

/* -------------------------------------------------------------------------
   FORM CARD — refined surface, generous padding, clearer hierarchy
   ------------------------------------------------------------------------- */
.form-card {
  background: var(--color-surface-raised, #FFFFFF);
  border: 1px solid rgba(138, 90, 36, 0.12);
  border-radius: 20px;
  padding: clamp(2.25rem, 1.75rem + 2vw, 3.5rem) clamp(1.75rem, 1.25rem + 1.5vw, 3rem);
  box-shadow:
    0 2px 8px rgba(36, 28, 18, 0.04),
    0 24px 56px rgba(36, 28, 18, 0.08);
}
.form-card h2 {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 1.15rem + 1.2vw, 1.875rem);
  line-height: 1.2;
  letter-spacing: -0.015em;
  font-weight: 400;
  color: var(--color-text);
  margin-bottom: 10px;
}
.form-card > p {
  font-size: 0.9375rem;
  line-height: 1.65;
  color: var(--color-text-muted);
  margin-bottom: clamp(1.75rem, 1.25rem + 1.5vw, 2.5rem);
  max-width: 48ch;
}

/* Form groups */
.form-group {
  margin-bottom: clamp(1.125rem, 1rem + 0.4vw, 1.5rem);
}
.form-row {
  grid-template-columns: 1fr 1fr;
  gap: clamp(0.75rem, 0.5rem + 1vw, 1.25rem);
}

/* Labels */
.form-group label {
  display: block;
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-text);
  margin-bottom: 10px;
}

/* Inputs — refined focus ring, better placeholder, cleaner border */
.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 14px 18px;
  background: var(--color-bg);
  border: 1.5px solid rgba(138, 90, 36, 0.14);
  border-radius: 12px;
  font-size: 1rem;
  font-family: var(--font-body);
  color: var(--color-text);
  outline: none;
  transition:
    border-color 0.3s ease,
    box-shadow 0.3s ease,
    background 0.3s ease;
  -webkit-appearance: none;
}
.form-group input:hover:not(:focus),
.form-group textarea:hover:not(:focus),
.form-group select:hover:not(:focus) {
  border-color: rgba(138, 90, 36, 0.28);
}
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  border-color: var(--color-accent);
  box-shadow: 0 0 0 4px rgba(138, 90, 36, 0.12);
  background: #FFFFFF;
}
.form-group input::placeholder,
.form-group textarea::placeholder {
  color: rgba(107, 101, 96, 0.72);
}
.form-group textarea {
  min-height: 160px;
  resize: vertical;
  line-height: 1.6;
}
.form-group select {
  background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%238A5A24' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 48px;
  cursor: pointer;
}

/* -------------------------------------------------------------------------
   MATH VERIFICATION — keep it visible, refine presentation
   (The logic is intentional and must not be removed — it's anti-bot)
   ------------------------------------------------------------------------- */
.verify-row {
  gap: 12px;
  align-items: flex-end;
}
.verify-question {
  padding: 14px 18px;
  background: rgba(138, 90, 36, 0.08);
  border: 1.5px solid rgba(138, 90, 36, 0.22);
  border-radius: 12px;
  font-family: var(--font-display);
  font-size: 1.1875rem;
  font-weight: 400;
  color: var(--color-accent);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
  min-width: 140px;
  height: 52px;
}

/* -------------------------------------------------------------------------
   SUBMIT BUTTON — confident, primary, good tap target
   ------------------------------------------------------------------------- */
.form-submit {
  width: 100%;
  padding: 18px 32px;
  background: var(--color-accent);
  color: #FFFFFF;
  border: none;
  border-radius: 12px;
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-family: var(--font-body);
  cursor: pointer;
  margin-top: 12px;
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease,
    background 0.3s ease;
  min-height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}
.form-submit:hover {
  transform: translateY(-2px);
  background: var(--color-accent-deep, #6E481E);
  box-shadow: 0 12px 32px rgba(138, 90, 36, 0.32);
}
.form-submit:active { transform: translateY(0); }

/* -------------------------------------------------------------------------
   SIDEBAR — info-card + follow-card
   ------------------------------------------------------------------------- */
.contact-sidebar {
  display: flex;
  flex-direction: column;
  gap: clamp(1rem, 0.75rem + 0.75vw, 1.5rem);
}
.info-card {
  background: var(--color-surface);
  border: 1px solid rgba(138, 90, 36, 0.12);
  border-radius: 16px;
  padding: clamp(1.75rem, 1.25rem + 1.5vw, 2.5rem);
}
.info-card h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  line-height: 1.2;
  font-weight: 400;
  color: var(--color-text);
  margin-bottom: clamp(1rem, 0.75rem + 0.75vw, 1.5rem);
}
.info-card > div {
  margin-bottom: 18px;
}
.info-card > div:last-child {
  margin-bottom: 0;
}
.info-label {
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin-bottom: 6px;
  display: block;
}
.info-value {
  font-size: 1rem;
  color: var(--color-text);
  line-height: 1.5;
}
.info-value a {
  color: var(--color-accent);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
}
.info-value a:hover {
  text-decoration-thickness: 2px;
}

/* Follow-our-work card — keep the warm dark treatment; refine typography */
.follow-card {
  background: var(--color-accent-deep, #6E481E);
  color: #FAF7F2;
  border-radius: 16px;
  padding: clamp(1.75rem, 1.25rem + 1.5vw, 2.5rem);
  position: relative;
  overflow: hidden;
}
.follow-card h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 400;
  color: #FAF7F2;
  margin-bottom: 12px;
}
.follow-card p {
  font-size: 0.9375rem;
  line-height: 1.6;
  color: rgba(250, 247, 242, 0.85);
  margin-bottom: clamp(1rem, 0.75rem + 0.75vw, 1.5rem);
  max-width: 32ch;
}
.social-links {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.social-link {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: rgba(250, 247, 242, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #FAF7F2;
  transition:
    background 0.3s ease,
    transform 0.3s ease;
}
.social-link:hover {
  background: rgba(250, 247, 242, 0.2);
  transform: translateY(-2px);
}
.social-link svg {
  width: 18px;
  height: 18px;
}

/* -------------------------------------------------------------------------
   SUCCESS STATE (Message Sent!) — refined confirmation
   ------------------------------------------------------------------------- */
.form-success {
  text-align: center;
  padding: clamp(2rem, 1.5rem + 2vw, 3.5rem) 0;
}
.form-success h3 {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 1.25rem + 1vw, 2rem);
  font-weight: 400;
  color: var(--color-accent);
  margin-bottom: 12px;
}
.form-success p {
  font-size: 1rem;
  color: var(--color-text-muted);
  line-height: 1.6;
  max-width: 42ch;
  margin-inline: auto;
}

/* -------------------------------------------------------------------------
   MOBILE
   ------------------------------------------------------------------------- */
@media (max-width: 900px) {
  .contact-grid {
    grid-template-columns: 1fr;
    max-width: 640px;
  }
}
@media (max-width: 560px) {
  .form-row {
    grid-template-columns: 1fr;
  }
  .verify-row {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }
  .verify-question {
    min-width: 0;
    width: 100%;
  }
}
