/* ------------------------------------------------------------------
 Page-level composition only — every value reads from a myt token.
 ------------------------------------------------------------------ */

/* breathing room between the site menu and footer */
.pre { background: var(--od-grey-100); padding: 150px 0 60px; display: flex; align-items: center; }
.pre__in { max-width: 1260px; margin: 0 auto; padding: 0 24px; width: 100%; }

.pcard {
  display: grid; grid-template-columns: .84fr 1.16fr;
  background: var(--myt-white); border-radius: var(--r-lg); overflow: hidden;
  box-shadow: 0 34px 80px rgba(19,20,58,.14);
}
.pcard > * { min-width: 0; }

/* ---------- left: light panel, title then image ---------- */
.pview {
  position: relative; overflow: hidden; color: var(--od-ink);
  background: #f6f5fa;
  display: flex; flex-direction: column; align-items: stretch;
  padding: 46px 44px 30px;
}
.pview__badge {
  display: inline-block; align-self: flex-start;
  background-color: var(--od-paleblue); color: var(--od-ink);
  border-radius: var(--r-pill); padding: 5px 26px; margin-bottom: 22px;margin-top: 15px;
  font-size: 14px; font-weight: var(--fw-bold); letter-spacing: .18em; text-transform: uppercase;
}
.pview h1 {
  color: var(--od-ink); font-size: clamp(30px, 3.2vw, 44px); font-weight: var(--fw-bold);
  line-height: 1.06; letter-spacing: -1.4px; margin: 0 0 12px;
}
.pview__sub { color: var(--od-grey-700); font-size: 18px; margin: 0; }
.pview__img {
  margin: 34px 0 0; flex: 0 0 auto;
  display: flex; justify-content: center; align-items: flex-start;
}
.pview__img img {
  width: auto; height: 404px; max-width: 100%;
  object-fit: contain; display: block;
}

/* campaign visual behind the left panel */
.bg-row {
  background-image: url(https://imgcdn.myt.mu/myt-home/srm-image-2.jpg);
  background-repeat: no-repeat;
  background-size: cover;
  background-position: center;
}

/* ---------- right: the form ---------- */
.pform { padding: 50px 60px 50px; }

.panel__head { margin-bottom: 24px; padding-bottom: 22px; border-bottom: 1px solid var(--od-grey-200); }
.panel__head h2 { font-size: clamp(22px, 1.9vw, 27px); font-weight: var(--fw-medium); letter-spacing: -.7px; margin: 0 0 5px; }
.panel__head p { font-size: 15px; color: var(--od-grey-700); margin: 0; }

/* error banner */
.alertbox {
  display: none; align-items: flex-start; gap: 12px; margin-bottom: 16px;
  background: #fdecec; border: 1px solid rgba(235,93,91,.45); border-radius: var(--r-sm);
  padding: 13px 18px; color: #a8302e; font-size: 14px; line-height: 1.5;
}
.alertbox.is-on { display: flex; }
.alertbox svg { width: 22px; height: 22px; flex-shrink: 0; margin-top: 1px; }
.alertbox b { display: block; font-weight: var(--fw-semibold); margin-bottom: 2px; }

/* fields — let grid tracks shrink so inputs size to the column */
.pform .fe-grid { gap: 20px 22px; }
.pform .fe-grid > .field { min-width: 0; }
.pform .input { width: 100%; font-size: 18px; padding: 11px 16px; border-radius: 13px; }
.pform textarea.input { resize: vertical; min-height: 110px; }
.field label { font-size: 14px; font-weight: var(--fw-semibold); margin-bottom: 1px; }
.field .hint { font-size: 13px; color: var(--od-grey-600); }
.field .err { font-size: 13.5px; font-weight: var(--fw-medium); color: var(--myt-coral); display: none; }
.field.is-bad .input { border-color: var(--myt-coral); }
.field.is-bad .err { display: block; }
.opt-tag { font-weight: 400; color: var(--od-grey-600); }

.preorderterms { font-size: 13px; color: #000; }

/* reCAPTCHA */
.capwrap { margin-top: 22px; }
.capwrap .err { font-size: 13.5px; font-weight: var(--fw-semibold); color: var(--myt-coral); display: none; margin-top: 6px; }
.capwrap.is-bad .err { display: block; }
.g-recaptcha { max-width: 100%; }

.nav { display: flex; align-items: center; justify-content: flex-end; gap: 18px; flex-wrap: wrap; margin-top: 28px; }
.nav .btn { font-size: 15px; padding: 14px 28px; }
.nav--split { justify-content: space-between; }
.required { color: var(--myt-coral); }

/* server-side error message above the form */
.srvmsg { margin-bottom: 18px; }

/* ---------- review step ---------- */
.rev {
  list-style: none; padding: 0; margin: 0 0 6px;
  border: 1px solid var(--od-grey-200); border-radius: var(--r-sm); overflow: hidden;
}
.rev li {
  display: flex; justify-content: space-between; gap: 16px;
  padding: 13px 18px; border-top: 1px solid var(--od-grey-200); font-size: 15px;
}
.rev li:first-child { border-top: 0; }
.rev li > span { color: var(--od-grey-700); flex-shrink: 0; }
.rev b { font-weight: var(--fw-medium); text-align: right; overflow-wrap: anywhere; }

/* server response (after submit) */
.done { text-align: center; padding: 30px 10px; }
.done__tick { width: 88px; height: 88px; border-radius: 50%; margin: 0 auto 26px; display: grid; place-items: center; background: var(--od-mint); color: var(--od-teal); }
.done__tick svg { width: 42px; height: 42px; }
.done__msg { color: var(--od-grey-700); font-size: 16px; }
.done__cta { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; margin-top: 28px; }

/* ---------- responsive ---------- */
@media (max-width: 991.98px) {
  .pre { padding: 130px 0 56px; }
  .pcard { grid-template-columns: 1fr; }
  .pview { padding: 34px 28px 26px; }
  .pview__img img { height: 300px; }
  .pview__img { margin-top: 24px; }
  .pform { padding: 38px 28px 42px; }
}

/* mobile: heading sits on the white card, ABOVE the image, not on top of it */
@media (max-width: 767px) {
  .pview.bg-row { background: none; padding: 0; }
  .pview__head { padding: 26px 22px 20px; }
  .pview__img { display: none; }
  .pview__mob {
    display: block; width: 100%;
    height: 260px;              /* adjust to taste */
    object-fit: cover;          /* fill the box without stretching */
    object-position: center 60%; /* crop from the bottom, keep the head */
  }
}

@media (max-width: 560px) {
  .pre { padding: 130px 0 40px; }
  .pre__in { padding: 0 14px; }
  .pcard { border-radius: var(--r-md); }
  .pform { padding: 28px 22px 34px; }
  .pform .fe-grid { grid-template-columns: 1fr; }
  .nav .btn { width: 100%; justify-content: center; }
  .rev li { flex-direction: column; gap: 2px; }
  .rev b { text-align: left; }
}

/* the reCAPTCHA iframe is a fixed 304px — scale it on very narrow phones */
@media (max-width: 360px) {
  .g-recaptcha { transform: scale(.88); transform-origin: 0 0; }
}

/* region dropdown: bigger arrow, set in from the right */
.pform select.input {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;                       /* hide the browser's own arrow */
  background-color: var(--myt-white);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2313143a' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 20px center; /* distance from the right edge */
  background-size: 20px 20px;              /* arrow size */
  padding-right: 56px;                     /* keeps text clear of the arrow */
  cursor: pointer;
}

.field.is-bad select.input { border-color: var(--myt-coral); }

.preorderterms a {
  display: inline-flex;
  align-items: center;
  gap: 4px;                 /* space between text and arrow */
}
.preorderterms a svg {
  width: 14px;              /* arrow size */
  height: 14px;
  flex-shrink: 0;
}

/* after submit: no left panel, message centred in a narrower card */
.pcard--done {
  grid-template-columns: 1fr;
  max-width: 680px;
  margin: 0 auto;
}
.pcard--done .pform {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 420px;          /* gives the message room to sit in the middle */
  padding: 56px 40px;
}
.pcard--done .done {
  width: 100%;
  text-align: center;
  padding: 0;
}
.pcard--done .done__msg img { margin: 0 auto; display: block; }  /* tick image from PHP */

@media (max-width: 560px) {
  .pcard--done .pform { min-height: 0; padding: 40px 22px; }
}