/* Form controls: the contact and auth form cards, inputs and errors. */

.website-contact-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: 48px;
  align-items: start;
}

.website-form-card {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 32px;
  background: #fff;
}
.website-form-card h2 {
  margin: 0 0 24px;
  font-size: 26px;
  color: var(--green);
}

/* A disabled fieldset is how a form renders before its island mounts, so it
   must not look broken -- only quietly inactive. */
.website-form-card fieldset {
  border: 0;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 18px;
}
.website-form-card fieldset[disabled] {
  opacity: 0.6;
}

.website-form-card label {
  display: grid;
  gap: 7px;
  font-weight: 700;
  font-size: 14px;
}
.website-form-card input,
.website-form-card textarea,
.website-form-card select {
  width: 100%;
  padding: 13px 15px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-weight: 400;
}
.website-form-card textarea {
  resize: vertical;
  min-height: 120px;
}
.website-form-card input:focus-visible,
.website-form-card textarea:focus-visible,
.website-form-card select:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 1px;
  border-color: var(--green);
}
/* Only after the browser has judged the field, so an untouched form is not
   covered in red. */
.website-form-card input:user-invalid,
.website-form-card textarea:user-invalid {
  border-color: #b3261e;
}
.website-form-card button[type='submit'] {
  justify-self: start;
}

.website-form-note {
  margin: 16px 0 0;
  font-size: 13px;
  color: var(--muted);
  line-height: 1.6;
}

.website-notice.is-error {
  border-color: #f0c8c4;
  background: #fdf3f2;
  color: #8c1d18;
}

@media (max-width: 900px) {
  .website-contact-layout {
    grid-template-columns: minmax(0, 1fr);
    gap: 32px;
  }
  .website-form-card {
    padding: 24px 20px;
  }
  .website-form-card h2 {
    font-size: 22px;
  }
}

/* ---------------------------------------------------------------------------
   Member area and auth pages
   Server-rendered in the same shell as the public site, so signing in does
   not drop the visitor into a different-looking application.
   --------------------------------------------------------------------------- */

/* The sign-in, sign-up and password pages share one shell: the form card and,
   on a wide screen, a panel saying what the account is for. Selectors are
   written with the `.website` root so the public theme -- which restyles
   `.website-form-card` from a later stylesheet -- does not win back the
   borders this layout removes. */
.website-auth {
  padding-block: clamp(28px, 5vw, 64px);
}
.website-auth-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  max-width: 1000px;
  margin-inline: auto;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: 0 18px 50px rgba(15, 23, 42, 0.07);
  overflow: hidden;
}
.website .website-auth-shell .website-auth-card {
  padding: clamp(26px, 4vw, 44px);
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}
.website .website-auth-shell .website-auth-card h2 {
  margin-bottom: 6px;
  font-size: clamp(22px, 2.4vw, 28px);
}
/* The form sits under the heading, so the heading needs the breathing room
   the fieldset gap used to provide on its own. */
.website-auth-card > .website-prose,
.website-auth-card > form,
.website-auth-card > [data-island='auth-form'] {
  margin-top: 18px;
}
/* The public theme turns a notice into a tall centred panel, which is right
   for an empty catalogue and wrong for "wrong password" above a field. */
.website .website-auth-card .website-notice {
  min-height: 0;
  margin-top: 18px;
  padding: 13px 15px;
  justify-content: flex-start;
  text-align: start;
}
.website-auth-card fieldset {
  gap: 16px;
}
.website-auth-card button[type='submit'] {
  justify-self: stretch;
  width: 100%;
  justify-content: center;
  margin-top: 4px;
  padding-block: 14px;
}
.website-auth-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
}
/* A checkbox is not a field: it must not stretch to the width of one, and its
   label belongs beside it rather than above it. */
.website-form-card .website-checkbox {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 13px;
  font-weight: 600;
}
.website-form-card .website-checkbox input[type='checkbox'] {
  width: 17px;
  height: 17px;
  flex-shrink: 0;
  padding: 0;
  accent-color: var(--green);
}
.website-auth-switch {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font-size: 14px;
}
.website-auth-back {
  margin-top: 20px;
  text-align: center;
}

.website-auth-panel {
  display: grid;
  align-content: center;
  gap: 14px;
  order: -1;
  padding: clamp(28px, 4vw, 44px);
  background: linear-gradient(160deg, #0b5a46 0%, #06332a 100%);
  color: #fff;
}
.website-auth-panel img {
  width: 58px;
  height: 62px;
  object-fit: contain;
}
.website-auth-panel-brand {
  margin: 0;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.5px;
}
.website-auth-panel h3 {
  margin: 0;
  font-size: clamp(19px, 2vw, 24px);
  line-height: 1.3;
  color: #fff;
}
.website-auth-panel ul {
  display: grid;
  gap: 11px;
  margin: 6px 0 0;
  padding: 0;
  list-style: none;
  font-size: 14px;
  line-height: 1.5;
  color: rgba(240, 253, 244, 0.86);
}
.website-auth-panel li {
  display: grid;
  grid-template-columns: 18px 1fr;
  gap: 10px;
  align-items: start;
}
.website-auth-panel li::before {
  content: '✓';
  display: grid;
  place-items: center;
  width: 18px;
  height: 18px;
  margin-top: 2px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.16);
  font-size: 10px;
  color: #fff;
}

@media (max-width: 760px) {
  /* The panel becomes a header strip: the promise is worth one line, the
     list would push the first field off the screen. */
  .website-auth-shell {
    grid-template-columns: minmax(0, 1fr);
    border-radius: 16px;
  }
  .website-auth-panel {
    gap: 8px;
    padding: 20px 22px;
    grid-template-columns: auto 1fr;
    align-items: center;
  }
  .website-auth-panel img {
    width: 40px;
    height: 44px;
    grid-row: span 2;
  }
  .website-auth-panel-brand {
    font-size: 17px;
    align-self: end;
  }
  .website-auth-panel h3 {
    font-size: 15px;
    font-weight: 600;
    align-self: start;
    color: rgba(240, 253, 244, 0.86);
  }
  .website-auth-panel ul {
    display: none;
  }
}
