/* ==========================================================
   CAREER (SINGLE JOB) PAGE
   ========================================================== */

html { overflow-x: clip; }

/* ===== Job header ===== */
.ibe-career-intro {
  background: #FAF5EE;
  padding: clamp(5rem, 9vw, 8rem) 2rem clamp(2rem, 4vw, 3rem);
  text-align: center;
}
.ibe-career-intro__inner {
  max-width: 780px;
  margin: 0 auto;
}
.ibe-career-intro__title {
  font-family: 'Zalando Sans Expanded', sans-serif;
  font-weight: 400;
  font-size: clamp(1.9rem, 3.4vw, 2.7rem);
  color: #434142;
  letter-spacing: 0;
  margin: 0 0 0.9rem 0;
}
.ibe-career-intro__loc {
  font-family: 'Zalando Sans Expanded', sans-serif;
  font-weight: 400;
  font-size: 0.88rem;
  color: rgba(26, 26, 26, 0.65);
  margin: 0 0 1.5rem 0;
  letter-spacing: 0;
}
.ibe-career-intro__lede {
  font-family: 'Zalando Sans Expanded', sans-serif;
  font-weight: 400;
  font-size: 0.92rem;
  line-height: 1.8;
  color: rgba(26, 26, 26, 0.78);
  margin: 0 auto;
  max-width: 620px;
}

/* ===== Details — two columns ===== */
.ibe-career-details {
  background: #FAF5EE;
  padding: clamp(1.5rem, 3vw, 2.5rem) 2rem clamp(4rem, 7vw, 6rem);
}
.ibe-career-details__grid {
  max-width: 960px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 4vw, 4rem);
}
.ibe-career-details__col h3 {
  font-family: 'Zalando Sans Expanded', sans-serif;
  font-weight: 600;
  font-size: 0.95rem;
  color: #434142;
  margin: 0 0 1rem 0;
  letter-spacing: 0;
}
.ibe-career-details__col ul {
  list-style: disc;
  padding-left: 1.1rem;
  margin: 0;
}
.ibe-career-details__col li {
  font-family: 'Zalando Sans Expanded', sans-serif;
  font-weight: 400;
  font-size: 0.88rem;
  line-height: 1.75;
  color: rgba(26, 26, 26, 0.82);
  margin-bottom: 0.5rem;
}
[dir="rtl"] .ibe-career-details__col ul { padding-left: 0; padding-right: 1.1rem; }

@media (max-width: 760px) {
  .ibe-career-details__grid { grid-template-columns: 1fr; gap: 2rem; }
}

/* ===== Application form — dark band ===== */
.ibe-apply {
  background: #434142;
  color: #FFFAF6;
  padding: clamp(3rem, 6vw, 5rem) 2rem clamp(3.5rem, 6vw, 5.5rem);
}
.ibe-apply__inner {
  max-width: 1120px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: clamp(2rem, 5vw, 5rem);
}
.ibe-apply__title {
  font-family: 'Zalando Sans Expanded', sans-serif;
  font-weight: 400;
  font-size: clamp(1.8rem, 3vw, 2.25rem);
  line-height: 1.15;
  color: #FFFAF6;
  letter-spacing: 0;
  margin: 0;
}

/* Form */
.ibe-apply__form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem 2.5rem;
}

.ibe-apply__field {
  position: relative;
  display: block;
}
.ibe-apply__field--full { grid-column: 1 / -1; }

.ibe-apply__field input,
.ibe-apply__field textarea {
  background: transparent;
  border: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.35);
  color: #FFFAF6;
  font-family: 'Zalando Sans Expanded', sans-serif;
  font-weight: 400;
  font-size: 0.95rem;
  padding: 1.35rem 0 0.55rem;
  transition: border-color 0.3s var(--ibe-transition);
  border-radius: 0;
  outline: none;
  resize: none;
  width: 100%;
  display: block;
  box-sizing: border-box;
}
.ibe-apply__field textarea { min-height: 80px; line-height: 1.5; }
.ibe-apply__field--notes textarea { border-bottom: 1px solid rgba(255, 255, 255, 0.2); }
.ibe-apply__field input:focus,
.ibe-apply__field textarea:focus { border-bottom-color: #FFFAF6; }
.ibe-apply__field--notes textarea:focus { border-bottom-color: transparent; }

.ibe-apply__field input::placeholder,
.ibe-apply__field textarea::placeholder { color: transparent; }

/* Floating label */
.ibe-apply__field label {
  position: absolute;
  left: 0;
  top: 1.35rem;
  font-family: 'Zalando Sans Expanded', sans-serif;
  font-weight: 400;
  font-size: 0.9375rem;
  color: #FFFAF6;
  letter-spacing: 0;
  pointer-events: none;
  transform-origin: left top;
  transition: transform 0.25s var(--ibe-transition), color 0.25s var(--ibe-transition);
}
[dir="rtl"] .ibe-apply__field label { left: auto; right: 0; transform-origin: right top; }

.ibe-apply__field input:focus ~ label,
.ibe-apply__field input:not(:placeholder-shown) ~ label,
.ibe-apply__field textarea:focus ~ label,
.ibe-apply__field textarea:not(:placeholder-shown) ~ label,
.ibe-apply__field:has(input:focus) label,
.ibe-apply__field:has(input:not(:placeholder-shown)) label,
.ibe-apply__field:has(textarea:focus) label,
.ibe-apply__field:has(textarea:not(:placeholder-shown)) label,
.ibe-apply__field.is-focused label,
.ibe-apply__field.has-value label {
  transform: translateY(-1.15rem) scale(0.78);
  color: rgba(255, 255, 255, 0.7);
}

/* CF7 compatibility in apply section */
.ibe-apply__field .wpcf7-form-control-wrap { display: block; }

/* CF7 grid layout for apply form */
.ibe-apply__cf7-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem 2.5rem;
}

/* Override CF7 placeholder so floating labels work */
.ibe-apply__cf7 .ibe-apply__field input::placeholder,
.ibe-apply__cf7 .ibe-apply__field textarea::placeholder { color: transparent; }

@media (max-width: 860px) {
  .ibe-apply__cf7-grid { grid-template-columns: 1fr; gap: 1.5rem; }
}

/* CV upload — CF7 form-control-wrap must overlay the full label area */
.ibe-apply__cv .wpcf7-form-control-wrap {
  position: absolute;
  inset: 0;
  display: block;
}
.ibe-apply__cv .wpcf7-form-control-wrap input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  width: 100%;
  height: 100%;
  border: 0;
  padding: 0;
}

/* CV upload */
.ibe-apply__cv {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 1.1rem 0 0.65rem;
  cursor: pointer;
  position: relative;
}
.ibe-apply__cv input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}
.ibe-apply__cv-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px; height: 28px;
  color: rgba(255, 255, 255, 0.75);
  font-size: 1.8rem;
  transform: rotate(45deg);
}
.ibe-apply__cv-label {
  font-family: 'Zalando Sans Expanded', sans-serif;
  font-weight: 500;
  font-size: 0.82rem;
  color: #FFFAF6;
  letter-spacing: 0;
  display: block;
  margin-bottom: 0.15rem;
}
.ibe-apply__cv-hint {
  font-family: 'Zalando Sans Expanded', sans-serif;
  font-weight: 400;
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.5);
  letter-spacing: 0;
}

/* Submit button */
.ibe-apply__submit {
  grid-column: 1 / -1;
  margin-top: 0.75rem;
  align-self: flex-start;
}
.ibe-apply__submit button {
  position: relative;
  background: none;
  border: 0;
  color: #FFFAF6;
  font-family: 'Zalando Sans Expanded', sans-serif;
  font-weight: 500;
  font-size: 0.82rem;
  letter-spacing: 0;
  text-transform: uppercase;
  padding: 0 0 8px 0;
  cursor: pointer;
  transition: color 0.35s var(--ibe-transition);
}
.ibe-apply__submit button::before {
  content: '';
  position: absolute;
  left: 0; bottom: 0;
  height: 1px;
  width: 64px;
  background: #FFFAF6;
  transition: width 0.45s var(--ibe-transition);
}
.ibe-apply__submit button:hover::before { width: 100%; }
[dir="rtl"] .ibe-apply__submit button::before { left: auto; right: 0; }

/* ===== Form feedback (inside dark apply band) ===== */
.ibe-apply__form .ibe-form__feedback {
  grid-column: 1 / -1;
  font-family: 'Zalando Sans Expanded', sans-serif;
  font-size: 0.85rem;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.85);
  margin-top: 0.5rem;
}
.ibe-apply__form .ibe-form__feedback--err { color: rgba(255, 160, 160, 0.9); }

/* ===== CF7 in dark apply section ===== */
.ibe-apply__cf7 .wpcf7 { width: 100%; }
.ibe-apply__cf7 .wpcf7-form {
  margin-top: -45px;
  display: flex;
  flex-direction: column;
  gap: 2rem;
}
.ibe-apply__cf7 .ibe-cf7-name-email,
.ibe-apply__cf7 .ibe-cf7-position-phone {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}
.ibe-apply__cf7 .wpcf7-form-control-wrap { display: block; }

.ibe-apply__cf7 input[type="text"],
.ibe-apply__cf7 input[type="email"],
.ibe-apply__cf7 input[type="tel"],
.ibe-apply__cf7 textarea {
  background: transparent;
  border: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.35);
  color: #FFFAF6;
  font-family: 'Zalando Sans Expanded', sans-serif;
  font-weight: 400;
  font-size: 0.95rem;
  padding: 1.35rem 0 0.55rem;
  transition: border-color 0.3s var(--ibe-transition);
  border-radius: 0;
  outline: none;
  resize: none;
  width: 100%;
  box-sizing: border-box;
}
.ibe-apply__cf7 textarea { line-height: 1.5; height: 110px; }
.ibe-apply__field p { margin-bottom: 0; }
.ibe-apply__cf7 input[type="text"]:focus,
.ibe-apply__cf7 input[type="email"]:focus,
.ibe-apply__cf7 input[type="tel"]:focus,
.ibe-apply__cf7 textarea:focus { border-bottom-color: #fff; }
.ibe-apply__cf7 input::placeholder,
.ibe-apply__cf7 textarea::placeholder { color: rgba(255, 255, 255, 0.55); }

.ibe-apply__cf7 input[type="file"] {
  border-bottom: 1px solid rgba(255, 255, 255, 0.18);
  color: rgba(255, 255, 255, 0.7);
  font-family: 'Zalando Sans Expanded', sans-serif;
  font-size: 0.82rem;
  padding: 0.85rem 0 0.55rem;
  width: 100%;
  box-sizing: border-box;
  background: transparent;
  cursor: pointer;
}

.ibe-apply__cf7 input[type="submit"],
.ibe-apply__cf7 .wpcf7-submit {
  background-color: transparent;
  background-image: linear-gradient(#FFFAF6, #FFFAF6);
  background-size: 64px 1px;
  background-repeat: no-repeat;
  background-position: 0 100%;
  border: 0;
  color: #FFFAF6;
  font-family: 'Zalando Sans Expanded', sans-serif;
  font-weight: 500;
  font-size: 0.82rem;
  letter-spacing: 0;
  text-transform: uppercase;
  padding: 0 0 8px 0;
  cursor: pointer;
  transition: background-size 0.45s var(--ibe-transition), color 0.35s var(--ibe-transition);
  display: inline-block;
}
.ibe-apply__cf7 input[type="submit"]:hover,
.ibe-apply__cf7 .wpcf7-submit:hover {
  background-size: 100% 1px;
  color: rgba(255, 255, 255, 0.85);
}

.ibe-apply__cf7 .wpcf7-not-valid { border-bottom-color: rgba(255, 120, 120, 0.9) !important; }
.ibe-apply__cf7 .wpcf7-not-valid-tip {
  font-size: 0.72rem;
  color: rgba(255, 200, 200, 0.9);
  margin-top: 3px;
  display: block;
}
.ibe-apply__cf7 .wpcf7-response-output {
  font-size: 0.85rem;
  margin-top: 1.5rem;
  padding: 0.75rem 1rem;
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #FFFAF6;
  border-radius: 0;
  margin-left: 0;
}
.ibe-apply__cf7 .wpcf7-response-output:empty { display: none; }

/* ===== Responsive ===== */
@media (max-width: 860px) {
  .ibe-apply__inner { grid-template-columns: 1fr; gap: 2rem; }
  .ibe-apply__form { grid-template-columns: 1fr; gap: 1.5rem; }
  .ibe-apply__cf7 .ibe-cf7-name-email,
  .ibe-apply__cf7 .ibe-cf7-position-phone { grid-template-columns: 1fr; gap: 1.5rem; }
}
