/* ==========================================================================
   Shivganga — Contact Us
   Page-specific components only; tokens, resets, utilities, the page hero
   and the closing CTA band come from page.css, which must load first.
   Scoped under .sg-ct.
   ========================================================================== */

.sg-ct-grid {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: clamp(28px, 4.5vw, 64px);
  align-items: start;
}

/* ==========================================================================
   FORM
   The form this replaces had no labels at all — every field was identified by
   a placeholder, which disappears as soon as anyone types into it and is not
   reliably announced. Real labels here, kept visible.
   ========================================================================== */
.sg-ct-form {
  background: var(--sg-white);
  border: 1px solid var(--sg-cream-2);
  border-radius: var(--sg-radius-lg);
  box-shadow: var(--sg-shadow);
  padding: clamp(24px, 3.4vw, 44px);
}
.sg-ct-form__rows { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(14px, 1.8vw, 22px); }
.sg-ct-field { display: flex; flex-direction: column; }
.sg-ct-field--wide { grid-column: 1 / -1; }

.sg-ct-field label {
  font-family: var(--sg-font-head); font-weight: 600;
  font-size: .84rem; letter-spacing: .02em;
  color: var(--sg-ink); margin-bottom: .45rem;
}
.sg-ct-field label .req { color: var(--sg-orange-dark); margin-left: .15rem; }

.sg-ct-field input,
.sg-ct-field select,
.sg-ct-field textarea {
  font-family: var(--sg-font-body); font-size: .98rem;
  color: var(--sg-ink);
  background: var(--sg-paper);
  border: 1.5px solid var(--sg-cream-2);
  border-radius: 10px;
  padding: .8rem 1rem;
  width: 100%;
  transition: border-color .18s ease, box-shadow .18s ease, background .18s ease;
}
.sg-ct-field textarea { min-height: 148px; resize: vertical; line-height: 1.6; }
.sg-ct-field select {
  appearance: none; -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath fill='none' stroke='%235C6A64' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round' d='M1 1.5 6 6.5l5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  background-size: 12px 8px;
  padding-right: 2.6rem;
}
.sg-ct-field input:hover,
.sg-ct-field select:hover,
.sg-ct-field textarea:hover { border-color: var(--sg-green-soft); }
.sg-ct-field input:focus,
.sg-ct-field select:focus,
.sg-ct-field textarea:focus {
  outline: none;
  background: var(--sg-white);
  border-color: var(--sg-green);
  box-shadow: 0 0 0 3px rgba(14,107,87,.14);
}
.sg-ct-field input::placeholder,
.sg-ct-field textarea::placeholder { color: var(--sg-muted-2); opacity: .75; }

/* Validation state is driven by a class, not by :invalid, so a field is not
   marked red before anyone has had a chance to fill it in. */
.sg-ct-field.is-bad input,
.sg-ct-field.is-bad select,
.sg-ct-field.is-bad textarea { border-color: #C4551A; background: var(--sg-orange-pale); }
.sg-ct-field__err {
  font-size: .8rem; color: #A5450F; margin-top: .35rem;
  min-height: 1.1em;
}
.sg-ct-field__count { font-size: .78rem; color: var(--sg-muted-2); margin-top: .35rem; text-align: right; }
.sg-ct-field__count.is-near { color: #A5450F; }

/* A honeypot: a real field, positioned out of sight, that only a bot fills. */
.sg-ct-hp {
  position: absolute; left: -9999px;
  width: 1px; height: 1px; overflow: hidden;
}

.sg-ct-form__foot {
  display: flex; flex-wrap: wrap; align-items: center; gap: 1rem;
  margin-top: clamp(18px, 2.4vw, 26px);
}
.sg-ct-form__note { font-size: .84rem; color: var(--sg-muted-2); margin: 0; }

/* The reply from the server. The form this replaces used alert(), and its
   script wrote into #err and #preview, neither of which existed on the page. */
.sg-ct-status {
  margin-top: 1.1rem; border-radius: 10px;
  padding: .9rem 1.1rem; font-size: .93rem;
  display: none;
}
.sg-ct-status.is-on { display: block; }
.sg-ct-status.is-ok  { background: var(--sg-green-tint); color: var(--sg-green-dark); border: 1px solid var(--sg-green-pale); }
.sg-ct-status.is-err { background: var(--sg-orange-pale); color: #A5450F; border: 1px solid #F0C4A4; }

.sg-ct-form button[disabled] { opacity: .6; cursor: progress; }

/* ==========================================================================
   CONTACT DETAILS
   ========================================================================== */
.sg-ct-cards { display: grid; gap: clamp(14px, 1.8vw, 20px); }
.sg-ct-card {
  background: var(--sg-white);
  border: 1px solid var(--sg-cream-2);
  border-radius: var(--sg-radius);
  padding: clamp(20px, 2.4vw, 28px);
  display: grid; grid-template-columns: 46px minmax(0, 1fr);
  gap: 1rem; align-items: start;
}
.sg-ct-card__icon {
  width: 46px; height: 46px; border-radius: 12px;
  background: var(--sg-green-tint); color: var(--sg-green);
  display: grid; place-items: center;
}
.sg-ct-card__icon svg { width: 22px; height: 22px; }
.sg-page .sg-ct-card h3 {
  font-size: .78rem; font-weight: 700; letter-spacing: .12em;
  text-transform: uppercase; color: var(--sg-green);
  margin-bottom: .5em;
}
.sg-ct-card address {
  font-style: normal; font-size: .95rem; line-height: 1.65;
  color: var(--sg-muted); margin: 0;
}
.sg-ct-card address b { color: var(--sg-ink); font-weight: 600; }
.sg-page .sg-ct-card a { color: var(--sg-green); font-weight: 600; }
.sg-page .sg-ct-card a:hover { color: var(--sg-green-dark); text-decoration: underline; }

.sg-ct-social { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .8rem; }
/* These SVGs are dark artwork that the footer inverts to white on its dark
   ground. On a light card they need the same treatment, so the disc carries
   the colour and the mark is inverted on top of it. */
.sg-ct-social a {
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--sg-green);
  display: grid; place-items: center;
  transition: background .18s ease, transform .18s ease;
}
.sg-ct-social a:hover { background: var(--sg-green-dark); transform: translateY(-2px); }
.sg-ct-social img {
  width: 16px; height: 16px; display: block;
  object-fit: contain;
  filter: brightness(0) invert(1);
}

/* ==========================================================================
   MAP
   ========================================================================== */
.sg-ct-map {
  border-radius: var(--sg-radius-lg);
  overflow: hidden;
  box-shadow: var(--sg-shadow-lg);
  border: 1px solid var(--sg-cream-2);
  background: var(--sg-green-tint);
  aspect-ratio: 21 / 9;
}
.sg-ct-map iframe { width: 100%; height: 100%; border: 0; display: block; }

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 980px) {
  .sg-ct-grid { grid-template-columns: 1fr; }
}
@media (max-width: 700px) {
  .sg-ct-map { aspect-ratio: 4 / 3; }
}
@media (max-width: 620px) {
  .sg-ct-form__rows { grid-template-columns: 1fr; }
  .sg-ct-card { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  .sg-ct-field input, .sg-ct-field select, .sg-ct-field textarea, .sg-ct-social a { transition: none; }
  .sg-ct-social a:hover { transform: none; }
}
