/* ==========================================================================
   zejneba.com — Contact section (<contact-section>, "Let’s See How I Can Help")
   --------------------------------------------------------------------------
   Shared: it sits at the end of every page, after the FAQ. Markup: ContactSection in
   js/components.js. Form, dropdown and "Talk about this": js/contact.js.

   1. Section layout, tabs, form, book a call
   2. Check circles
   3. Responsive
   ========================================================================== */

contact-section {
  display: block;
}


/* 1. Section layout
   --------------------------------------------------------------------------
   Left: heading, promises and the tabs that switch the box on the right
   between the form and booking a call.
   ========================================================================== */

.hiw-contact {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  align-items: start;
  gap: 64px;
  width: min(1106px + var(--content-extra), 100% - 48px);
  margin: 0 auto;
  padding: 150px 0 90px;
}

/* Right after the FAQ (How I work) or the About section (home), which already
   leave 150px below themselves */
faq-section + contact-section .hiw-contact,
.about + contact-section .hiw-contact {
  padding-top: 60px;
}

.hiw-contact h2 {
  color: var(--base-black);
}

.hiw-contact__intro {
  max-width: 440px;
  margin-top: 20px;
  color: var(--neutral-muted);
}

/* Tabs: big titles on a thin line, the selected one gets a dark bar and its note */
.hiw-ways {
  display: flex;
  flex-direction: column;
  margin-top: 56px;
  border-left: 1px solid var(--neutral-line);
}

.hiw-ways__tab {
  position: relative;
  padding: 8px 0 8px 26px;
  border: 0;
  background: none;
  color: #c3c3bd;
  font-family: var(--font-heading);
  font-size: clamp(24px, 2.4vw, 30px);
  font-weight: 500;
  line-height: 1.25;
  letter-spacing: -0.025em;
  text-align: left;
  cursor: pointer;
  transition: color 0.25s ease;
}

.hiw-ways__tab:hover {
  color: var(--neutral-muted);
}

.hiw-ways__tab[aria-selected="true"] {
  color: var(--base-black);
}

.hiw-ways__tab::before {
  content: "";
  position: absolute;
  top: 14px;
  bottom: 14px;
  left: -1px;
  width: 2px;
  background: var(--base-black);
  transform: scaleY(0);
  transition: transform 0.3s var(--ease-out);
}

.hiw-ways__tab[aria-selected="true"]::before {
  transform: scaleY(1);
}

.hiw-ways__tab small {
  display: block;
  max-height: 0;
  overflow: hidden;
  color: var(--neutral-subtle);
  font-family: var(--font-body);
  font-size: 13.5px;
  font-weight: 400;
  line-height: 20px;
  letter-spacing: 0;
  transition: max-height 0.3s var(--ease-out);
}

.hiw-ways__tab[aria-selected="true"] small {
  max-height: 30px;
}

/* Box: light grey with a hairline border; the fields stay white on it */
.hiw-contact__box {
  padding: 32px 40px;
  border: 1px solid var(--neutral-grey-100);
  border-radius: var(--radius-2xl);
  background: #fbfbfa; /* lighter than --neutral-grey-50 */
}

.hiw-contact__panels {
  width: 100%;
}

.hiw-contact__panel {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  color: var(--base-black);
}

.hiw-contact__panel[hidden] {
  display: none;
}

.hiw-contact__lead {
  margin: 2px 0 24px;
  color: var(--neutral-muted);
}

.hiw-form-wrap,
.hiw-form {
  width: 100%;
}

.hiw-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.hiw-form__two {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.hiw-form__send {
  width: 100%;
}

.hiw-form__send[disabled] {
  cursor: progress;
  opacity: 0.7;
}

.hiw-form__status {
  color: var(--accent-orange-text);
  text-align: center;
}

.hiw-form__status:empty {
  display: none;
}

.hiw-form__fine {
  margin-top: -6px;
  color: var(--neutral-muted);
  text-align: center;
}

.hiw-form__fine a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.hiw-form-done {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 36px 8px 20px;
  text-align: center;
}

.hiw-form-done[hidden] {
  display: none;
}

.hiw-form-done .mock-check {
  margin-bottom: 12px;
  animation: hiw-pop 0.45s cubic-bezier(0.3, 1.4, 0.5, 1);
}

.hiw-form-done p {
  max-width: 360px;
  margin-bottom: 16px;
  color: var(--neutral-muted);
}

@keyframes hiw-pop {
  from {
    opacity: 0;
    scale: 0.5;
  }
}

/* Form fields */
.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.field__label {
  color: var(--base-black);
  font-size: 14px;
  font-weight: 500;
  line-height: 20px;
}

/* Required fields (the input itself carries required for screen readers) */
.field__req {
  margin-left: 2px;
  color: var(--accent-orange-text);
}

.field__label em {
  color: var(--neutral-subtle);
  font-style: normal;
  font-weight: 400;
}

.field__input {
  width: 100%;
  height: 46px;
  padding: 0 14px;
  border: 1px solid #dcdcd6;
  border-radius: var(--radius-m);
  outline: none;
  background: var(--base-white);
  box-shadow: 0 1px 2px rgba(20, 20, 20, 0.04);
  color: var(--base-black);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.45;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

textarea.field__input {
  height: auto;
  min-height: 112px;
  padding: 12px 14px;
  resize: vertical;
}

.field__input::placeholder {
  color: #aaaaa4;
}

.field__input:hover {
  border-color: #c4c4bd;
}

.field__input:focus {
  border-color: var(--base-black);
  box-shadow: 0 0 0 4px rgba(20, 20, 20, 0.07);
}

.field.is-invalid .field__input {
  border-color: var(--accent-orange-text);
}

.field.is-invalid .field__input:focus {
  box-shadow: 0 0 0 4px rgba(194, 65, 12, 0.12);
}

.field__error {
  display: none;
  color: var(--accent-orange-text);
  font-size: 13px;
  font-style: normal;
}

.field.is-invalid .field__error {
  display: block;
}

/* Dropdown questions: a native select dressed like the other fields, chevron on the right */
.field__select {
  position: relative;
  display: block;
}

.field__select select {
  padding-right: 44px;
  appearance: none;
  cursor: pointer;
}

/* "Select an option" reads like a placeholder until an answer is picked */
.field__select select:has(option[value=""]:checked) {
  color: #aaaaa4;
}

.field__select option {
  color: var(--base-black);
}

.field__select z-icon {
  position: absolute;
  top: 50%;
  right: 14px;
  color: var(--neutral-muted);
  pointer-events: none;
  translate: 0 -50%;
}

/* Book a call: host, three facts, the agenda in one white card, one button */
.hiw-call {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  width: 100%;
}

/* Calendly-style: big photo on top, then who, what, how long */
.hiw-call__photo img {
  display: block;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  corner-shape: round;
  object-fit: cover;
}

.hiw-call__host {
  margin-top: 24px;
  color: var(--neutral-muted);
  font-size: 15px;
  font-weight: 600;
  line-height: 20px;
}

.hiw-call__title {
  margin-top: 6px;
  color: var(--base-black);
}

.hiw-call__facts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin: 20px 0 0;
  padding: 0;
  list-style: none;
}

.hiw-call__facts li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--neutral-muted);
  font-size: 15px;
  font-weight: 600;
  line-height: 20px;
}

.hiw-call__facts z-icon {
  color: var(--neutral-muted);
}

.hiw-call__desc {
  max-width: 44ch;
  margin: 20px 0 32px;
  color: var(--neutral-body);
}

.hiw-call__cta {
  width: 100%;
}


/* 2. Check circles
   ========================================================================== */

/* Moss circle with a white check (also used in the contact section) */
.mock-check {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  corner-shape: round;
  background: var(--brand-moss);
  color: var(--base-white);
}

.mock-check--big {
  width: 56px;
  height: 56px;
}


/* 3. Responsive
   ========================================================================== */

@media (max-width: 1100px) {
  .hiw-contact {
    grid-template-columns: 1fr;
    gap: 48px;
  }
}

@media (max-width: 860px) {
  .hiw-contact {
    padding: 96px 0 40px;
  }

  faq-section + contact-section .hiw-contact,
  .about + contact-section .hiw-contact {
    padding-top: 40px;
  }

  .hiw-contact h2 {
    font-size: 32px;
    line-height: 38px;
  }
}

@media (max-width: 640px) {
  .hiw-contact__box {
    padding: 24px 16px;
  }

  .hiw-contact {
    gap: 16px;
  }

  /* The two ways in become segmented tabs right above the box */
  .hiw-ways {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4px;
    margin-top: 32px;
    padding: 4px;
    border: 1px solid var(--neutral-line);
    border-left: 1px solid var(--neutral-line);
    border-radius: var(--radius-xl);
    background: #fbfbfa;
  }

  .hiw-ways__tab {
    min-height: 44px;
    padding: 10px 8px;
    border-radius: var(--radius-l);
    color: var(--neutral-muted);
    font-family: var(--font-body);
    font-size: 15px;
    font-weight: 500;
    line-height: 20px;
    letter-spacing: -0.005em;
    text-align: center;
    transition: color 0.25s ease, background-color 0.25s ease, box-shadow 0.25s ease;
  }

  .hiw-ways__tab[aria-selected="true"] {
    background: var(--base-black);
    box-shadow: var(--shadow-raised);
    color: var(--base-white);
  }

  .hiw-ways__tab::before,
  .hiw-ways__tab small,
  .hiw-ways__long {
    display: none;
  }

  .hiw-form__two {
    grid-template-columns: 1fr;
  }

  /* 16px keeps iPhones from zooming in when a field is tapped */
  .field__input {
    font-size: 16px;
  }
}
