/* Contact Dev — Lead Generation page */

.rig-contact-dev-page {
  background: #fff;
  overflow-x: hidden;
}

.rig-contact-dev-page .sub-title {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  color: #0278AE;
  font-size: 14px;
  font-weight: 500;
}

/* ---------- Hero ---------- */
.rig-contact-hero {
  padding: 144px 0 56px;
  background:
    radial-gradient(circle at top right, rgba(2, 120, 174, 0.08), transparent 42%),
    linear-gradient(180deg, #f7fbff 0%, #ffffff 100%);
}

.rig-contact-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 40px;
  align-items: center;
}

.rig-contact-hero-copy .section-title {
  max-width: 640px;
  margin-bottom: 16px !important;
}

.rig-contact-hero-text {
  max-width: 540px;
  font-size: 17px;
  line-height: 1.7;
  color: #4a4a4a;
  margin: 0 0 28px;
}

.rig-contact-hero-actions .btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.rig-contact-hero-media {
  min-width: 0;
}

.rig-contact-hero-media img {
  width: 100%;
  height: 100%;
  max-height: 460px;
  object-fit: cover;
  border-radius: 24px;
  box-shadow: 0 18px 40px rgba(2, 120, 174, 0.12);
}

/* ---------- Section heads ---------- */
.rig-contact-section-head {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 40px;
}

.rig-contact-section-head .section-title {
  margin-bottom: 12px;
}

.rig-contact-section-head .text-details {
  margin: 0 auto;
  max-width: 640px;
}

/* ---------- Value cards ---------- */
.rig-contact-value {
  padding-top: 40px;
  padding-bottom: 56px;
}

.rig-contact-value-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}

.rig-contact-value-card {
  background: #f7fbff;
  border: 1px solid #e5eef4;
  border-radius: 20px;
  padding: 28px 24px;
  text-align: left;
  min-width: 0;
}

.rig-contact-value-icon {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  overflow: hidden;
  flex-shrink: 0;
}

.rig-contact-value-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.rig-contact-value-icon-fa,
.rig-contact-value-icon-fallback {
  color: #0278AE;
  font-size: 22px;
}

.rig-contact-value-icon-fa i {
  line-height: 1;
}

.rig-contact-value-card h3 {
  font-size: 22px;
  margin: 0 0 10px;
  color: #221E20;
}

.rig-contact-value-card p {
  margin: 0;
  color: #555;
  line-height: 1.65;
  font-size: 15px;
}

/* ---------- Gallery (featured first image) ---------- */
.rig-contact-gallery {
  padding: 24px 0 64px;
}

.rig-contact-gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-auto-rows: 270px;
  gap: 16px;
  column-gap: 16px;
  row-gap: 16px;
}

.rig-contact-gallery-item {
  margin: 0;
  border-radius: 18px;
  overflow: hidden;
  background: #f2f2f2;
  height: 270px;
  min-width: 0;
}

.rig-contact-gallery-item:first-child {
  grid-column: span 2;
  grid-row: span 2;
  /* Match 2 small images (270 + 270) + row gap (16) — no extra bottom space */
  height: calc(270px + 270px + 16px);
  align-self: stretch;
}

.rig-contact-gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.rig-contact-form-empty {
  padding: 20px;
  background: #f7f7f7;
  border-radius: 12px;
  color: #666;
}

/* Form side image — match form column height, cap at 765px */
.rig-contact-dev-page .contact-form-content-section .grid-div {
  align-items: stretch;
}

.rig-contact-dev-page .contact-form-content-section .lets-walk-div {
  min-width: 0;
}

.rig-contact-dev-page .contact-form-content-section .contact-img-div {
  min-width: 0;
  min-height: 0;
  height: 100%;
  max-height: 765px;
  overflow: hidden;
  border-radius: 24px;
  align-self: stretch;
}

.rig-contact-dev-page .contact-form-content-section .contact-img-div img {
  width: 100%;
  height: 100%;
  max-height: 765px;
  object-fit: cover;
  object-position: center;
  border-radius: 24px;
  display: block;
}

.rig-contact-dev-page .contact-form-content-section .form-class {
  max-width: 100%;
  width: 100%;
  height: 100%;
  box-sizing: border-box;
}

/* ========== Tablet (≤1199px) ========== */
@media screen and (max-width: 1199px) {
  .rig-contact-hero-grid {
    gap: 32px;
  }

  .rig-contact-hero-media img {
    max-height: 400px;
  }
}

/* ========== Tablet / small laptop (≤991px) ========== */
@media screen and (max-width: 991px) {
  .rig-contact-hero {
    padding: 132px 0 40px;
  }

  .rig-contact-hero-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .rig-contact-hero-copy .section-title,
  .rig-contact-hero-text {
    max-width: 100%;
  }

  .rig-contact-hero-media img {
    max-height: 360px;
    border-radius: 20px;
  }

  .rig-contact-value {
    padding-top: 24px;
    padding-bottom: 40px;
  }

  .rig-contact-value-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .rig-contact-section-head {
    margin-bottom: 28px;
  }

  .rig-contact-gallery {
    padding: 16px 0 48px;
  }

  .rig-contact-gallery-grid {
    grid-template-columns: 1fr 1fr;
    grid-auto-rows: 200px;
    gap: 12px;
  }

  .rig-contact-gallery-item {
    height: 200px;
    border-radius: 14px;
  }

  .rig-contact-gallery-item:first-child {
    grid-column: span 2;
    grid-row: span 1;
    height: 360px;
  }

  .rig-contact-dev-page .contact-form-content-section .contact-img-div {
    max-height: 560px;
    height: auto;
    min-height: 400px;
  }

  .rig-contact-dev-page .contact-form-content-section .contact-img-div img {
    max-height: 560px;
    height: 560px;
  }
}

/* ========== Mobile (≤767px) ========== */
@media screen and (max-width: 767px) {
  .rig-contact-hero {
    padding: 120px 0 32px;
  }

  .rig-contact-hero-text {
    font-size: 16px;
    margin-bottom: 22px;
  }

  .rig-contact-hero-actions .btn-primary {
    width: 100%;
    justify-content: center;
  }

  .rig-contact-hero-media img {
    max-height: 280px;
    border-radius: 16px;
  }

  .rig-contact-value-card {
    padding: 22px 18px;
  }

  .rig-contact-value-card h3 {
    font-size: 20px;
  }

  .rig-contact-gallery-grid {
    grid-auto-rows: 180px;
  }

  .rig-contact-gallery-item {
    height: 180px;
  }

  .rig-contact-gallery-item:first-child {
    height: 280px;
  }
}

/* ========== Small phone (≤575px) ========== */
@media screen and (max-width: 575px) {
  .rig-contact-hero {
    padding: 112px 0 28px;
  }

  .rig-contact-hero-media img {
    max-height: 240px;
  }

  .rig-contact-section-head {
    margin-bottom: 24px;
  }

  .rig-contact-value {
    padding-bottom: 32px;
  }

  .rig-contact-gallery {
    padding-bottom: 40px;
  }

  .rig-contact-gallery-grid {
    grid-template-columns: 1fr;
    grid-auto-rows: auto;
    gap: 12px;
  }

  .rig-contact-gallery-item,
  .rig-contact-gallery-item:first-child {
    grid-column: auto;
    grid-row: auto;
    height: 220px;
  }

  .rig-contact-dev-page .contact-form-content-section .form-class {
    padding: 20px 16px;
    border-radius: 16px;
  }

  .rig-contact-dev-page .contact-form-content-section .contact-img-div {
    max-height: 380px;
    min-height: 320px;
    border-radius: 16px;
  }

  .rig-contact-dev-page .contact-form-content-section .contact-img-div img {
    max-height: 380px;
    height: 380px;
    border-radius: 16px;
  }
}
