/* ============================================================
   Authentication page - premium redesign
   Royal Fishing Flies Kenya · theme pflat · page_name authentication
   ============================================================ */

body#authentication #center_column {
  padding-top: 6px;
}

body#authentication .page-heading {
  margin: 0 0 22px;
  padding: 30px 32px;
  border-radius: 18px 18px 0 0;
  background:
    radial-gradient(120% 140% at 88% -10%, rgba(108, 194, 74, .30) 0%, rgba(108, 194, 74, 0) 55%),
    linear-gradient(135deg, #0b2418 0%, #16452a 42%, #2f7d3c 100%);
  color: #fff;
  font-size: 30px;
  line-height: 1.2;
  letter-spacing: -.02em;
  font-weight: 700;
  box-shadow: 0 18px 40px rgba(13, 42, 27, .22);
}

body#authentication .box {
  border: 1.5px solid #d5dded !important;
  border-radius: 20px !important;
  background: linear-gradient(180deg, #ffffff, #fcfdff) !important;
  box-shadow: 0 1px 2px rgba(16, 24, 40, .05), 0 30px 64px -36px rgba(15, 23, 42, .32) !important;
  padding: 30px 32px 26px !important;
  margin: 0 0 20px !important;
  position: relative;
  overflow: hidden;
}

body#authentication .box::before {
  content: "";
  position: absolute;
  left: 0; right: 0; top: 0;
  height: 4px;
  background: linear-gradient(90deg, #2f7d3c, #6cc24a 55%, #eaf7e0);
  opacity: .95;
}

body#authentication .page-subheading {
  font-size: 14px !important;
  font-weight: 900 !important;
  letter-spacing: .16em !important;
  text-transform: uppercase !important;
  color: #0b1220 !important;
  margin: 0 0 22px !important;
  padding: 0 0 12px !important;
  position: relative;
  border-bottom: 0 !important;
  /* the theme floats .page-subheading left at width:100%; that float then
     squeezes the form-group flex boxes below it to zero width and pushes
     them outside the card (email field ends up off-screen). */
  float: none !important;
  width: auto !important;
}

body#authentication .page-subheading::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 52px; height: 4px;
  border-radius: 4px;
  background: linear-gradient(90deg, #2f7d3c, #6cc24a);
}

body#authentication .page-subheading .title_cat {
  color: inherit;
  /* .title_cat is floated by the theme too; keeping it floated would collapse
     the height of the (now unfloated) heading and drop the green rule on the
     title text. */
  float: none !important;
}

body#authentication .form-group {
  margin-bottom: 18px !important;
}

body#authentication label {
  display: block !important;
  font-size: 12px !important;
  font-weight: 800 !important;
  letter-spacing: .08em !important;
  text-transform: uppercase !important;
  color: #243247 !important;
  margin: 0 0 7px !important;
}

body#authentication .form-control,
body#authentication input.form-control,
body#authentication select.form-control,
body#authentication textarea.form-control {
  display: block;
  width: 100% !important;
  height: 48px !important;
  padding: 11px 14px !important;
  font-size: 14.5px !important;
  line-height: 22px !important;
  font-weight: 600 !important;
  color: #0b1220 !important;
  background: #fff !important;
  border: 2px solid #c3cede !important;
  border-radius: 12px !important;
  box-shadow: inset 0 1px 2px rgba(16, 24, 40, .05) !important;
  transition: border-color .2s ease, box-shadow .2s ease, background .2s ease !important;
}

body#authentication .form-control:hover {
  border-color: #8fa0b8 !important;
}

body#authentication .form-control:focus {
  border-color: #2f7d3c !important;
  outline: 0 !important;
  box-shadow: 0 0 0 4px rgba(47, 125, 60, .16), inset 0 1px 2px rgba(16, 24, 40, .05) !important;
}

body#authentication textarea.form-control {
  min-height: 120px !important;
  height: auto !important;
}

body#authentication .button-medium,
body#authentication .btn.button-medium {
  display: inline-flex !important;
  align-items: center;
  gap: 6px;
  padding: 11px 20px !important;
  border: 0 !important;
  border-radius: 999px !important;
  background: #2f7d3c !important;
  color: #fff !important;
  font-size: 11px !important;
  font-weight: 700 !important;
  letter-spacing: .07em !important;
  text-transform: uppercase !important;
  cursor: pointer;
  transition: background .18s ease, transform .18s ease;
}

body#authentication .button-medium:hover {
  background: #256530 !important;
  transform: translateY(-1px);
}

body#authentication .button-red {
  background: #fa6900 !important;
}

body#authentication .button-red:hover {
  background: #ff7d1f !important;
}

body#authentication .lost_password a {
  color: #2f7d3c;
  font-size: 12.5px;
  font-weight: 600;
  text-decoration: none;
}

body#authentication .lost_password a:hover {
  text-decoration: underline;
  color: #1e5c29;
}

body#authentication .radio-inline label {
  text-transform: none !important;
  font-weight: 600 !important;
  letter-spacing: 0 !important;
  font-size: 13px !important;
}

@media (max-width: 767px) {
  body#authentication .box {
    padding: 22px 18px !important;
  }
  body#authentication .page-heading {
    padding: 24px 20px;
    font-size: 24px;
  }
}

/* text in front of overlay bar */
body#authentication .page-heading { position: relative; z-index: 1; }
body#authentication .page-subheading { position: relative; z-index: 1; }
body#authentication .box::before { z-index: 0; }
body#authentication .form_content { position: relative; z-index: 1; }
/* labels and fields on one row */
body#authentication .form-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 16px;
}

body#authentication .form-group > label {
  flex: 0 0 150px;
  margin-bottom: 0 !important;
  margin-right: 0 !important;
}

body#authentication .form-group > .form-control,
body#authentication .form-group > input.form-control,
body#authentication .form-group > select.form-control,
body#authentication .form-group > textarea.form-control {
  flex: 1 1 220px;
  min-width: 0;
}

body#authentication .form-group.date-select > label {
  flex: 0 0 150px;
  margin: 0 !important;
}

body#authentication .form-group.date-select > .row {
  flex: 1 1 220px;
  min-width: 0;
}

body#authentication .gender-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 16px;
}

body#authentication .gender-line > label {
  flex: 0 0 150px;
  margin: 0 !important;
}

body#authentication .gender-line .radio-inline {
  flex: 0 0 auto;
}

body#authentication .checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px !important;
}

body#authentication .checkbox label {
  flex: 0 0 auto;
  text-transform: none !important;
  font-weight: 600 !important;
  letter-spacing: 0 !important;
  font-size: 13px !important;
  margin: 0 !important;
}

@media (max-width: 767px) {
  body#authentication .form-group,
  body#authentication .gender-line {
    flex-direction: column;
    align-items: stretch;
  }
  body#authentication .form-group > label,
  body#authentication .gender-line > label {
    flex: 0 0 auto;
    width: 100%;
  }
  body#authentication .form-group > .form-control,
  body#authentication .form-group > input.form-control,
  body#authentication .form-group > select.form-control,
  body#authentication .form-group > textarea.form-control,
  body#authentication .form-group.date-select > .row {
    flex: 1 1 auto;
    width: 100%;
  }
}
/* width tuning: avoid edge-push, widen country */
body#authentication .form-group > .form-control,
body#authentication .form-group > input.form-control,
body#authentication .form-group > select.form-control,
body#authentication .form-group > textarea.form-control {
  width: auto !important;
  flex: 0 1 360px;
  max-width: 420px;
}

body#authentication .form-group.date-select > .row {
  width: auto !important;
  flex: 0 1 360px;
  max-width: 420px;
}

body#authentication select#id_country,
body#authentication select[name="id_country"],
body#authentication select[name="id_country_invoice"] {
  flex: 1 1 420px;
  max-width: 100%;
  width: auto !important;
}
/* overflow fix: narrow auth boxes + wide registration form */
body#authentication #create-account_form .form-group,
body#authentication #login_form .form-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 16px;
  max-width: 100%;
}

body#authentication #create-account_form .form-group > label,
body#authentication #login_form .form-group > label {
  flex: 0 0 120px;
  margin-bottom: 0 !important;
  margin-right: 0 !important;
}

body#authentication #create-account_form .form-group > .form-control,
body#authentication #create-account_form .form-group > input.form-control,
body#authentication #login_form .form-group > .form-control,
body#authentication #login_form .form-group > input.form-control {
  flex: 0 1 280px;
  min-width: 0;
  max-width: 320px;
  width: auto !important;
}

body#authentication #login_form .form-group > span {
  flex: 0 1 280px;
  min-width: 0;
  max-width: 320px;
  display: block;
}

body#authentication #login_form .form-group > span > .form-control,
body#authentication #login_form .form-group > span > input.form-control {
  width: 100% !important;
  max-width: 100% !important;
}

body#authentication #new_account_form .form-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 16px;
  max-width: 100%;
}

body#authentication #new_account_form .form-group > label {
  flex: 0 0 150px;
  margin-bottom: 0 !important;
  margin-right: 0 !important;
}

body#authentication #new_account_form .form-group > .form-control,
body#authentication #new_account_form .form-group > input.form-control,
body#authentication #new_account_form .form-group > select.form-control,
body#authentication #new_account_form .form-group > textarea.form-control {
  flex: 1 1 0;
  min-width: 0;
  max-width: 480px;
  width: auto !important;
}

body#authentication #new_account_form .form-group.date-select > .row {
  flex: 1 1 0;
  min-width: 0;
  max-width: 480px;
}

body#authentication #new_account_form select#id_country,
body#authentication #new_account_form select[name="id_country"],
body#authentication #new_account_form select[name="id_country_invoice"] {
  flex: 1 1 0;
  min-width: 0;
  max-width: 480px;
  width: auto !important;
}

body#authentication .accent-lines {
  display: flex;
  gap: 8px;
  margin: 12px 0 20px;
}

body#authentication .accent-lines .orange-line {
  width: 30px;
  height: 4px;
  background: #fa6900;
  border-radius: 2px;
}

body#authentication .accent-lines .green-line {
  width: 20px;
  height: 4px;
  background: #2f7d3c;
  border-radius: 2px;
}

/* Password input with light blue background */
body#authentication .form-group.passwd-input .form-control {
  background: #e8edf5 !important;
  border-color: #a0a8b6 !important;
}

/* Email input on top right - light blue/grey */
body#authentication .form-group.email-input .form-control {
  background: #e8edf5 !important;
  border-color: #a0a8b6 !important;
  border-radius: 12px !important;
}

/* Small screens: the form-groups stack into a column, where the 280px
   flex-basis used on desktop becomes the input HEIGHT (giant boxes) and the
   fields keep their desktop width instead of filling the card. */
@media (max-width: 767px) {
  body#authentication #create-account_form .form-group > label,
  body#authentication #login_form .form-group > label {
    flex: 0 0 auto;
    width: 100%;
    margin-bottom: 0 !important;
    margin-right: 0 !important;
  }

  body#authentication #create-account_form .form-group > .form-control,
  body#authentication #create-account_form .form-group > input.form-control,
  body#authentication #create-account_form .form-group > select.form-control,
  body#authentication #create-account_form .form-group > textarea.form-control,
  body#authentication #login_form .form-group > .form-control,
  body#authentication #login_form .form-group > input.form-control,
  body#authentication #login_form .form-group > select.form-control,
  body#authentication #login_form .form-group > textarea.form-control,
  body#authentication #login_form .form-group > span {
    flex: 0 0 auto;
    width: 100% !important;
    max-width: 100%;
  }

  body#authentication #login_form .form-group > span > .form-control,
  body#authentication #login_form .form-group > span > input.form-control {
    width: 100% !important;
    max-width: 100%;
  }
}

/* Registration address: uniform select wrappers must match the text inputs */
body#authentication #account-creation_form .form-group > div.selector {
  flex: 0 1 360px;
  width: 360px !important;
  max-width: 100%;
  height: 48px !important;
  line-height: 44px !important;
  padding: 0 14px !important;
  border: 2px solid #c3cede;
  border-radius: 12px;
  background: #fff !important;
  background-image: none !important;
  box-shadow: inset 0 1px 2px rgba(16, 24, 40, .05);
  box-sizing: border-box;
  position: relative;
  overflow: hidden;
}
body#authentication #account-creation_form .form-group > div.selector > span {
  display: block !important;
  float: none !important;
  width: 100% !important;
  height: 44px !important;
  line-height: 44px !important;
  margin: 0 !important;
  padding: 0 24px 0 0 !important;
  font-size: 14.5px !important;
  color: #0b1220 !important;
  background: none !important;
  text-overflow: ellipsis;
  overflow: hidden;
  white-space: nowrap;
}
body#authentication #account-creation_form .form-group > div.selector > select {
  top: 0 !important;
  left: 0 !important;
  width: 100% !important;
  height: 48px !important;
}
body#authentication #account-creation_form .form-group > div.selector::after {
  content: "";
  position: absolute;
  right: 17px;
  top: 50%;
  width: 8px;
  height: 8px;
  border-right: 2px solid #8b95a7;
  border-bottom: 2px solid #8b95a7;
  transform: translateY(-70%) rotate(45deg);
  pointer-events: none;
}
@media (max-width: 767px) {
  body#authentication #account-creation_form .form-group > div.selector {
    flex: 1 1 auto;
    width: 100% !important;
  }
}

/* Mobile: the desktop flex-basis (360px) becomes a HEIGHT in the column layout */
@media (max-width: 767px) {
  body#authentication .form-group > .form-control,
  body#authentication .form-group > input.form-control,
  body#authentication .form-group > select.form-control,
  body#authentication .form-group > textarea.form-control {
    flex: 0 0 auto !important;
    width: 100% !important;
    max-width: 100%;
    height: auto;
  }
  body#authentication .form-group > input.form-control,
  body#authentication .form-group > select.form-control {
    height: 48px !important;
  }
  body#authentication .form-group > textarea.form-control {
    height: auto !important;
    min-height: 110px;
  }
  body#authentication .form-group > div.selector {
    flex: 0 0 auto !important;
    width: 100% !important;
    height: 48px !important;
  }
}
