/* ==========================================================================
   Cerej Contact Page Styles (Figma Match)
   ========================================================================== */

/* 1. Hero Section */
.contact-hero {
  background-color: var(--color-creme); /* Same as header background */
  padding: 100px 80px 60px;
  position: relative;
  overflow: visible;
}

.contact-hero-container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
}

.contact-hero-title {
  font-family: var(--font-reddit);
  font-size: 72px;
  font-weight: 500;
  line-height: 72px;
  color: var(--color-red);
  margin: 0;
}

/* 2. Info Section */
.contact-info-section {
  background-color: var(--color-dark-green);
  padding: 100px 80px;
  color: var(--color-white);
}

.contact-info-container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
}

.contact-info-header {
  position: relative;
  width: fit-content;
  margin-bottom: 50px;
}

.contact-section-title {
  font-family: var(--font-ultra);
  font-size: 28px;
  font-weight: 400;
  line-height: 1.2;
  margin: 0;
  text-transform: capitalize;
}

.text-lime {
  color: var(--color-lime);
}

.text-red {
  color: var(--color-red);
}

.decor-icon {
  position: absolute;
  left: calc(100% + 8px);
  bottom: -8px; /* Clean gap of 8px from the text baseline */
  width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.decor-icon svg {
  display: block;
}

.contact-info-grid {
  display: flex;
  flex-flow: row wrap;
  gap: 80px;
}

.info-group {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 15px;
}

.info-label {
  font-family: var(--font-reddit);
  font-size: 20px;
  font-weight: 400;
  color: var(--color-gray);
  margin: 0;
}

.info-underline {
  line-height: 0;
  margin-bottom: 5px;
}

.info-underline svg {
  display: block;
}

.info-value {
  font-family: var(--font-reddit);
  font-size: 20px;
  font-weight: 600;
  color: var(--color-green);
  text-decoration: none;
  transition: var(--transition-smooth);
}

.info-value:hover {
  opacity: 0.85;
  transform: translateX(4px);
}

/* 3. Form Section */
.contact-form-section {
  background-color: var(--color-gray);
  padding: 100px 80px;
  position: relative;
  overflow: hidden;
}

.contact-form-container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  position: relative;
  z-index: 5;
}

.contact-form-header {
  position: relative;
  width: fit-content;
  margin-bottom: 50px;
}

.message-form {
  display: flex;
  flex-direction: column;
  gap: 48px;
}

.form-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

/* Floating labels style */
.input-field {
  position: relative;
  border-bottom: 1px solid #CACACA;
  padding-top: 20px;
  padding-bottom: 12px;
  display: flex;
  flex-direction: column;
  transition: var(--transition-smooth);
}

.input-field input,
.input-field textarea {
  width: 100%;
  border: none;
  background: transparent;
  outline: none;
  font-family: var(--font-reddit);
  font-size: 18px;
  font-weight: 500;
  color: #555555;
  padding: 5px 0 0 0;
}

.input-field label {
  position: absolute;
  left: 0;
  bottom: 16px;
  font-family: var(--font-reddit);
  font-size: 18px;
  font-weight: 500;
  color: #767676;
  pointer-events: none;
  transition: all 0.25s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* Float visual effect on focus/active */
.input-field input:focus ~ label,
.input-field input:not(:placeholder-shown) ~ label {
  transform: translateY(-30px);
  font-size: 14px;
  color: var(--color-red);
}

/* Textarea group height / design */
.textarea-field {
  padding-bottom: 40px;
  margin-top: 10px;
}

.textarea-field textarea {
  resize: vertical;
  min-height: 100px;
  line-height: 1.5;
}

.textarea-field label {
  bottom: auto;
  top: 25px;
}

.textarea-field textarea:focus ~ label,
.textarea-field textarea:not(:placeholder-shown) ~ label {
  transform: translateY(-26px);
  font-size: 14px;
  color: var(--color-red);
}

/* Highlight bottom border on focus */
.input-field:focus-within {
  border-bottom-color: var(--color-red);
}

/* Submit Button styling */
.submit-button {
  align-self: flex-start;
  height: 56px;
  padding: 17px 26px;
  background-color: var(--color-dark-green);
  border: none;
  border-radius: 83px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: var(--transition-smooth);
}

.submit-button span {
  font-family: var(--font-reddit);
  font-size: 18px;
  font-weight: 500;
  color: var(--color-gray);
  line-height: 1;
}

.submit-button svg {
  display: block;
}

.submit-button svg path {
  stroke: var(--color-gray);
  transition: var(--transition-smooth);
}

.submit-button:hover {
  transform: scale(1.04);
  background-color: var(--color-green);
}

.submit-button:hover span {
  color: var(--color-dark-green);
}

.submit-button:hover svg path {
  stroke: var(--color-dark-green);
}

/* Decorative Hero Leaf positioning (at the boundary) */
.contact-hero-leaf {
  position: absolute;
  bottom: -140px; /* Centered on the boundary line between hero and info section */
  right: calc(50% - 640px + 80px);
  width: 280px;
  height: 280px;
  z-index: 10;
  pointer-events: none;
}

.contact-hero-leaf svg {
  width: 100%;
  height: 100%;
  display: block;
}

/* ==========================================================================
   Media Queries & Responsive Layouts
   ========================================================================== */

/* Medium Laptops & Tablets (1200px and down) */
@media (max-width: 1200px) {
  .contact-hero {
    padding: 80px 40px 40px;
  }
  .contact-hero-title {
    font-size: 56px;
    line-height: 56px;
  }
  .contact-info-section,
  .contact-form-section {
    padding: 80px 40px;
  }
  .contact-hero-leaf {
    right: 40px;
    width: 200px;
    height: 200px;
    bottom: -100px;
  }
}

/* Portrait Tablets (992px and down) */
@media (max-width: 992px) {
  .form-row {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .message-form {
    gap: 36px;
  }
}

/* Mobile Screens (768px and down) */
@media (max-width: 768px) {
  .contact-hero {
    padding: 40px 20px 20px;
  }
  .contact-hero-title {
    font-size: 44px;
    line-height: 44px;
    text-align: left;
  }
  .contact-info-section,
  .contact-form-section {
    padding: 60px 20px;
  }
  .contact-info-header,
  .contact-form-header {
    margin: 0 auto 30px;
  }
  .contact-info-grid {
    justify-content: center;
    text-align: center;
    gap: 40px;
  }
  .info-group {
    align-items: center;
  }
  .submit-button {
    align-self: center;
    width: 100%;
    justify-content: center;
  }
  .contact-hero-leaf {
    right: 20px;
    width: 140px;
    height: 140px;
    bottom: -70px;
  }
}

/* Small Screens (480px and down) */
@media (max-width: 480px) {
  .contact-hero-title {
    font-size: 36px;
    line-height: 36px;
  }
  .contact-section-title {
    font-size: 24px;
  }
}