/* =============================================================================
   MERIDIAN POOLS — contact.css
   MigsFlow Web Design

   Contact page specific styles only.
   global.css + components.css + animations.css must load before this file.

   MOBILE FIRST — base styles target mobile.

   TABLE OF CONTENTS
   01. Page Hero (image override only — layout in components.css)
   02. Contact Section (to be built)
============================================================================= */


/* =============================================================================
   01 — PAGE HERO IMAGE OVERRIDE
============================================================================= */

/* No overrides needed — components.css handles everything. */


/* =============================================================================
   02 — CONTACT SECTION
   Styles will be added here as sections are built.
============================================================================= */

/* =============================================================================
   02 — CONTACT SECTION
============================================================================= */

#contact-main {
  background-color: var(--bg-100);
  overflow: hidden;
}

/* ── Layout — mobile: stacked, desktop: 2 col ────────────────────────────── */
.contact-inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-3xl);
  align-items: start;
}

@media (min-width: 1025px) {
  .contact-inner {
    grid-template-columns: 1fr 420px;
    gap: var(--space-4xl);
    align-items: stretch; /* change from start to stretch */
  }
}

/* ── Form wrap ───────────────────────────────────────────────────────────── */
.contact-form-wrap {
  background-color: var(--bg-300);
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: var(--radius-card);
  padding: var(--space-2xl);
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  gap: var(--space-xl);
  min-width: 0;
}

/* Form header */
.contact-form-header {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

.contact-eyebrow::before {
  content: '';
  display: inline-block;
  width: 5px;
  height: 5px;
  background-color: var(--blue);
  flex-shrink: 0;
  margin-right: var(--space-xs);
}

/* ── Form ────────────────────────────────────────────────────────────────── */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

/* 2-col row on tablet+ */
.contact-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-md);
}

@media (min-width: 600px) {
  .contact-row {
    grid-template-columns: 1fr 1fr;
  }
}

/* Individual field */
.contact-field {
  position: relative;
  display: flex;
  flex-direction: column;
}

/* Input + textarea shared styles */
.contact-form input,
.contact-form select,
.contact-form textarea {
  width: 100%;
  font-family: var(--font-body);
  font-size: var(--fs-body-sm);
  color: var(--text-600);
  background-color: var(--bg-100);
  border: 1.5px solid rgba(0, 0, 0, 0.15);
  border-radius: 10px;
  padding: 0.875rem 1rem;
  outline: none;
  transition:
    border-color var(--transition-base),
    box-shadow var(--transition-base);
  appearance: none;
  -webkit-appearance: none;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: var(--text-700);
}

.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(5, 107, 240, 0.12);
}

/* Select — custom arrow */
.contact-field-select {
  position: relative;
}

.contact-form select {
  cursor: pointer;
  padding-right: 2.5rem;
  color: var(--text-700);
}

.contact-form select:focus {
  color: var(--text-600);
}

.contact-select-arrow {
  position: absolute;
  right: 0.875rem;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  color: var(--blue);
  display: flex;
  align-items: center;
}

.contact-select-arrow svg {
  width: 1rem;
  height: 1rem;
}

/* Textarea */
.contact-form textarea {
  resize: vertical;
  min-height: 160px;
  line-height: var(--lh-body);
}

/* Submit button — full width */
.contact-submit {
  width: 100%;
  justify-content: center;
  margin-top: var(--space-xs);
}

/* ── Info cards — right column ───────────────────────────────────────────── */
.contact-info-wrap {
  background-color: var(--bg-300);
  border: 1px solid rgba(0, 0, 0, 0.2);
  border-radius: var(--radius-card);
  padding: var(--space-2xl);
  box-shadow: var(--shadow-card);
  display: flex;
  justify-content: center;
  flex-direction: column;
  gap: 0;
  min-width: 0;
}

/* Individual info card */
.contact-info-card {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
  padding-block: var(--space-xl);
}

/* Divider */
.contact-info-divider {
  width: 100%;
  height: 1px;
  background-color: rgba(0, 0, 0, 0.2);
}

/* Blue icon square */
.contact-info-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 4rem;
  height: 4rem;
  border-radius: 12px;
  background-color: var(--blue);
  color: var(--white);
  flex-shrink: 0;
}

.contact-info-icon svg {
  width: 1.5rem;
  height: 1.5rem;
}

/* Text */
.contact-info-text {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
  min-width: 0;
}

.contact-info-text h4 {
  font-family: var(--font-heading);
  font-size: var(--fs-h5);
  color: var(--text-100);
  letter-spacing: var(--ls-heading);
  line-height: 1.1;
}

.contact-info-text a,
.contact-info-text address {
  font-size: var(--fs-body-sm);
  color: var(--text-700);
  text-decoration: none;
  font-style: normal;
  line-height: var(--lh-body);
  transition: color var(--transition-base);
}

.contact-info-text a:hover {
  color: var(--blue);
}

.bold {
    color: var(--blue);
    font-weight: bold;
    font-style: italic;
    text-decoration: underline;
}



/* =============================================================================
   03 — SERVICE AREA MAP
============================================================================= */

#service-map {
  background-color: var(--bg-100);
  overflow: hidden;
}

/* ── Header ──────────────────────────────────────────────────────────────── */
.map-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-3xl);
  padding-top: var(--section-padding);
}

.map-eyebrow::before {
  content: '';
  display: inline-block;
  width: 5px;
  height: 5px;
  background-color: var(--blue);
  flex-shrink: 0;
  margin-right: var(--space-xs);
}

.map-subtext {
  font-size: var(--fs-body);
  color: var(--text-700);
  max-width: 48ch;
  text-align: center;
  line-height: var(--lh-body);
}

@media (min-width: 768px) {
  .map-subtext {
    font-size: var(--fs-body-lg);
  }
}

/* ── Map wrapper — full width, rounded corners ───────────────────────────── */
.map-wrap {
  width: 100%;
  line-height: 0;
  border-radius: var(--radius-card);
  overflow: hidden;
  box-shadow: var(--shadow-card);
}

.map-wrap iframe {
  width: 100%;
  height: 360px;
  display: block;
  border: none;
}

@media (min-width: 768px) {
  .map-wrap iframe {
    height: 440px;
  }
}

@media (min-width: 1025px) {
  .map-wrap iframe {
    height: 520px;
  }
}




/* =============================================================================
   ADD TO BOTTOM OF contact.css
   Contact form success state + input error styles
============================================================================= */

/* ── Success state ───────────────────────────────────────────────────────── */
.contact-success {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: var(--space-lg);
  padding: var(--space-4xl) var(--space-2xl);
  background-color: var(--bg-100);
  border-radius: var(--radius-card);
  border: 1px solid rgb(86, 86, 86);
  min-height: 320px;
}

.contact-success-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 4rem;
  height: 4rem;
  border-radius: 50%;
  background-color: var(--blue);
  color: var(--white);
  flex-shrink: 0;
}

.contact-success-icon svg {
  width: 1.75rem;
  height: 1.75rem;
}

.contact-success h3 {
  color: var(--text-100);
}

.contact-success p {
  font-size: var(--fs-body);
  color: var(--text-700);
  max-width: 40ch;
  line-height: var(--lh-body);
}

/* ── Input error highlight ───────────────────────────────────────────────── */
.contact-form input.error,
.contact-form textarea.error {
  border-color: #E53E3E;
  box-shadow: 0 0 0 3px rgba(229, 62, 62, 0.12);
}