/* ===== CONTACT (full CSS) ==============================================
   Uses :root palette with --color1 & --color5 accents
   - Centered section header
   - Animated gradient border on form panel (and light variant on cards)
   - Cards are flex-wrapped, grow/shrink, and last orphan centers
   - Email/text never overflows on small screens
========================================================================= */

/* Section */
.contact {
  background: #fff;
  padding: 64px 0;
}
.contact__container {
  max-width: 1600px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Centered header above content */
.contact__header {
  text-align: center;
  max-width: 900px;
  margin: 0 auto 28px;
}
.contact__title {
  font-size: clamp(28px, 3vw, 36px);
  margin: 0 0 8px;
  color: var(--text-color-dark, #000);
  font-weight: 800;
}
.contact__lead {
  color: var(--text-color, #555);
  margin: 0 auto;
}

/* Content wrap (cards + form) */
.contact__wrap {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 36px;
  align-items: start;
  margin-top: 8px;
}

/* --- Info cards -------------------------------------------------------- */
.contact__cards {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;          /* center each row incl. last orphan */
  align-items: stretch;
}

/* Base card */
.contact__card {
  position: relative;
  flex: 1 1 280px;                  /* grow & shrink nicely */
  max-width: 420px;
  min-width: 260px;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 14px 14px;
  border-radius: 14px;
  border: 1px solid rgba(29,110,147,0.22);       /* color5 hint */
  background:
    linear-gradient(0deg, #fff, #fff) padding-box,
    linear-gradient(135deg, rgba(24,147,105,0.22), rgba(29,110,147,0.32)) border-box; /* color1→color5 */
  box-shadow: 0 4px 16px rgba(0,0,0,.05);
}

/* Light animated border for cards (subtle) */
.is-animated-border--light {
  --_angle: 0deg;
  border: 2px solid transparent;
  background:
    linear-gradient(#fff, #fff) padding-box,
    conic-gradient(from var(--_angle),
      rgba(24,147,105,0.35),       /* color1 */
      rgba(29,110,147,0.50),       /* color5 */
      rgba(24,147,105,0.35)) border-box;
  animation: contactBorderSpin 8s linear infinite;
}

/* Card icon with soft accent chip */
.contact__icon {
  color: var(--color5, #1D6E93);
  flex: 0 0 auto;
  background: linear-gradient(135deg, rgba(24,147,105,0.12), rgba(29,110,147,0.12));
  border-radius: 10px;
  padding: 6px;
}

/* Card body aligns label + content like other cards */
.contact__card-body {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.contact__label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: #64748b;
}

.contact__link,
.contact__text {
  display: block;
  font-weight: 700;
  color: #0f172a;
  text-decoration: none;
  overflow-wrap: anywhere;  /* prevent overflow on small screens */
  word-break: break-word;
}
.contact__link:hover {
  color: var(--color5);
  text-decoration: underline;
}

.contact__note {
  margin-top: 14px;
  font-size: 14px;
  color: #475569;
}

/* Hours list — match look of other card text */
.contact__hours {
  list-style: none;
  margin: 2px 0 0;
  padding: 0;
  display: grid;
  gap: 6px;
}

.contact__hour-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  column-gap: 12px;
}

.contact__day {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: #64748b; /* same tone as label */
  flex: 0 0 auto;
}

.contact__time {
  font-weight: 700;           /* same as .contact__text */
  color: #0f172a;
  overflow-wrap: anywhere;
  word-break: break-word;
  font-variant-numeric: tabular-nums; /* neat time alignment */
  text-align: right;
}

/* --- Form panel with animated border ---------------------------------- */
.contact__form-panel {
  position: relative;
  border-radius: 16px;
  padding: 20px;
  background: #fff;
  z-index: 0;
}

/* Animated gradient border (prominent) */
.is-animated-border {
  --_angle: 0deg;
  border: 2px solid transparent;
  background:
    linear-gradient(#fff, #fff) padding-box,
    conic-gradient(from var(--_angle),
      var(--color1),
      var(--color5),
      var(--color1)) border-box;
  animation: contactBorderSpin 6s linear infinite;
}
@keyframes contactBorderSpin {
  to { --_angle: 360deg; }
}

/* Form layout */
.contact__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 16px;
}
.contact__grid .field--full {
  grid-column: 1 / -1;
}

/* Field styling (matches your site forms) */
.contact .field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.contact .field label {
  font-weight: 600;
  color: var(--text-color-dark, #000);
  font-size: 0.95rem;
}
.contact .field input,
.contact .field textarea {
  background: #fff;
  height: 52px;
  border-radius: 10px;
  border: 1px solid #e6e7eb;
  padding: 0 14px;
  font: inherit;
  box-sizing: border-box;
}
.contact .field textarea {
  min-height: 112px;
  height: auto;
  padding: 12px 14px;
  resize: vertical;
}
.contact .field input:focus,
.contact .field textarea:focus {
  outline: 0;
  border-color: var(--color5);
  box-shadow: 0 0 0 3px rgba(29,110,147,0.15);
}

/* Required star */
.contact label .required {
  color: #e63946;
  margin-left: 4px;
  font-weight: bold;
}

/* Actions */
.contact__actions {
  margin-top: 16px;
  display: flex;
  gap: 12px;
  align-items: center;
}
.contact__status {
  min-height: 20px;
  font-size: 14px;
  color: #0f172a;
}

/* Button theme alignment */
.contact .btn.btn--primary {
  background: var(--color5);
  color: #fff;
  border: 2px solid transparent;
}
.contact .btn.btn--primary:hover {
  background: var(--primary-color-dark, #005fa3);
}

/* --- Responsive -------------------------------------------------------- */
@media (max-width: 1024px) {
  .contact__wrap { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .contact__cards { justify-content: center; }
  .contact__grid { grid-template-columns: 1fr; }
  .contact__hour-row { column-gap: 8px; }
}

/* Reduced motion accessibility */
@media (prefers-reduced-motion: reduce) {
  .is-animated-border,
  .is-animated-border--light {
    animation: none !important;
  }
}

#ct-message-hint {
  font-size: 0.85rem;
  color: #64748b;
}