/* ============================================================
   Online Credit - Documents Required Table
   Styles the #required-document section table loaded from DB
   ============================================================ */

#required-document {
  margin-top: 20px;
}

#required-document h2,
#required-document h3,
#required-document h4 {
  text-align: center;
  color: #074EA2;
  margin-bottom: 20px;
}

#required-document table {
  width: 100%;
  max-width: 100%;
  margin-bottom: 30px;
  border-collapse: collapse;
}

#required-document table thead tr th,
#required-document table thead tr td {
  background-color: #074EA2;
  color: #ffffff;
  text-align: center;
  vertical-align: middle;
  padding: 12px 10px;
  font-weight: 500;
  border: 1px solid #074EA2;
}

#required-document table tbody tr {
  background-color: #dce6f5;
  transition: background-color 600ms ease;
}

#required-document table tbody tr:nth-child(even) {
  background-color: #eef3fb;
}

#required-document table tbody tr:hover {
  background-color: #b8d0f0;
  transition: background-color 600ms ease;
}

#required-document table tbody tr td,
#required-document table tbody tr th {
  padding: 10px;
  vertical-align: middle;
  text-align: center;
  border: 1px solid #c5d5ea;
  line-height: 1.42857143;
}

#required-document table tbody tr td:first-child {
  text-align: left;
}

/* ============================================================
   Congratulations Card — Eligibility Success Message
   ============================================================ */

.congrats-wrapper {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 30px 16px;
}

.congrats-card {
  background: #d5ecd6;
  border-radius: 10px;
  max-width: 580px;
  width: 100%;
  padding: 36px 40px 32px;
  text-align: center;
}

.congrats-heading {
  font-size: 22px;
  font-weight: 700;
  color: #1a5a3a;
  margin: 0 0 18px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.congrats-text {
  font-size: 15px;
  color: #333;
  line-height: 1.75;
  margin: 0 0 16px;
}

.congrats-apply-btn {
  display: inline-block;
  background: #0d3b7a;
  color: #ffffff !important;
  font-size: 15px;
  font-weight: 500;
  padding: 11px 38px;
  border-radius: 50px;
  text-decoration: none;
  margin-top: 8px;
  transition: background 0.25s ease, transform 0.2s ease;
}

.congrats-apply-btn:hover {
  background: #1557b0;
  transform: translateY(-2px);
  text-decoration: none;
  color: #ffffff !important;
}

/* ============================================================
   General Information Form — Step Navigation & Layout
   ============================================================ */

/* Step navigation bar */
.stepsForm .sf-steps.step-circles {
  background: #f0f4fa;
  border-bottom: 2px solid #dce6f5;
  padding: 20px 0 18px;
}

/* Ensure steps render horizontally */
.stepsForm .sf-steps-content {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: wrap;
  counter-reset: step;
}

.stepsForm .sf-steps-content > div {
  flex-grow: 1;
  flex-basis: 0;
  text-align: center;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.4px;
  color: #074EA2;
  padding-top: 44px;
  position: relative;
  z-index: 1;
}

.stepsForm .sf-steps-content > div:after {
  content: counter(step);
  counter-increment: step;
  display: block;
  height: 36px;
  width: 36px;
  margin: 0 auto 8px;
  background-color: #074EA2;
  color: #fff;
  line-height: 36px;
  font-size: 14px;
  border-radius: 50%;
  font-weight: bold;
  position: absolute;
  z-index: 1;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
}

.stepsForm .sf-steps-content > div.sf-active:after {
  width: 44px;
  height: 44px;
  line-height: 44px;
  background-color: #d2a12a;
  top: -4px;
}

.stepsForm .sf-steps-content > div:before {
  width: 100%;
  height: 3px;
  position: absolute;
  top: 16px;
  left: -50%;
  margin-left: 18px;
  content: '';
  background-color: #dce6f5;
  z-index: -1;
}

.stepsForm .sf-steps-content > div:first-child:before {
  content: none;
}

.stepsForm .sf-steps-content > div.sf-active {
  color: #d2a12a;
}

.stepsForm .sf-steps-content > div a.circle-link {
  color: #074EA2;
  text-decoration: none;
}

.stepsForm .sf-steps-content > div a.circle-link:hover {
  text-decoration: underline;
}

/* Form section wrapper */
.stepsForm .sf-steps-form {
  background: #ffffff;
}

.stepsForm .sf-content {
  list-style: none;
  padding: 0;
  margin: 0;
}

.stepsForm .sf-content > li {
  padding: 0;
}


/* Form inner padding — applies to all credit card form steps */
.general-information-form,
.personal-information-form,
.credit-eligibility,
.additional-services-form,
.documents-form,
.review-form {
  padding: 24px 28px 16px;
}

/* Section headings (h6.title) — applied globally across all credit card form steps */
.sf-steps-form h6.title,
.sf-steps-form .title {
  display: block;
  width: 100%;
  background-color: #0c4da2;
  color: #ffffff !important;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  text-align: center;
  padding: 8px 12px;
  border-radius: 4px;
  margin: 20px 0 18px;
  border-bottom: none;
}

.sf-steps-form h6.title:first-child,
.sf-steps-form .title:first-child {
  margin-top: 4px;
}

/* Legacy selectors — keep for backward compat */
.general-information-form h6.title,
.general-information-form .title {
  background-color: #0c4da2;
  color: #ffffff !important;
  text-align: center;
  padding: 8px 12px;
  border-radius: 4px;
  border-bottom: none;
}

/* Fix: convert inline flex label+input rows to stacked layout */
.general-information-form .align-items-center.d-lg-flex {
  display: block !important;
  flex-direction: column;
}

.general-information-form .align-items-center.d-lg-flex label {
  display: block !important;
  text-align: left !important;
  font-size: 12px;
  font-weight: 600;
  color: #444;
  margin-bottom: 5px;
  white-space: normal;
  width: auto !important;
  min-width: unset !important;
}

.general-information-form .align-items-center.d-lg-flex .form-control,
.general-information-form .align-items-center.d-lg-flex .select-control {
  width: 100% !important;
  border-radius: 6px;
  border: 1px solid #c8d6e8;
  background: #f7faff;
  color: #333;
  font-size: 13.5px;
  height: 40px;
  padding: 6px 10px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.general-information-form .align-items-center.d-lg-flex .form-control:focus {
  border-color: #074EA2;
  box-shadow: 0 0 0 3px rgba(7, 78, 162, 0.10);
  outline: none;
  background: #fff;
}

.general-information-form .align-items-center.d-lg-flex .form-control[readonly],
.general-information-form .align-items-center.d-lg-flex .form-control[disabled] {
  background: #eef1f7;
  color: #555;
  cursor: default;
}

/* Form group spacing */
.general-information-form .form-group {
  margin-bottom: 6px;
}

.general-information-form .col-lg-6,
.general-information-form .col-xl-4 {
  margin-bottom: 12px;
}

/* form-error inline */
.general-information-form .form-error {
  font-size: 11px;
  margin-top: 3px;
  margin-bottom: 0;
}

/* Action buttons row */
.general-information-form .col-12.text-right {
  padding-top: 10px;
  border-top: 1px solid #e8eef7;
  margin-top: 10px;
}

.general-information-form #btn-save-and-continue,
.general-information-form .btn-primary {
  background: #074EA2;
  border: none;
  border-radius: 6px;
  padding: 10px 28px;
  font-size: 14px;
  font-weight: 600;
  color: #fff;
  transition: background 0.25s ease, transform 0.15s ease;
}

.general-information-form #btn-save-and-continue:hover,
.general-information-form .btn-primary:hover {
  background: #1565c0;
  transform: translateY(-1px);
}

.general-information-form #btn-save-and-send,
.general-information-form .btn-danger {
  border-radius: 6px;
  padding: 10px 22px;
  font-size: 14px;
  font-weight: 600;
  transition: opacity 0.2s ease;
  margin-right: 8px;
}

/* Outer card border */
.stepsForm.border {
  border-radius: 10px !important;
  overflow: hidden;
  border-color: #dce6f5 !important;
  box-shadow: 0 4px 20px rgba(7, 78, 162, 0.07);
}

/* ============================================================
   Global styles for ALL credit card form steps (label-flex-wrapper)
   Extends general-information-form rules to all form steps
   ============================================================ */

/* Stacked label+input layout across all forms */
.label-flex-wrapper .align-items-center.d-lg-flex {
  display: block !important;
  flex-direction: column;
}

.label-flex-wrapper .align-items-center.d-lg-flex label {
  display: block !important;
  text-align: left !important;
  font-size: 12px;
  font-weight: 600;
  color: #444;
  margin-bottom: 5px;
  white-space: normal;
  width: auto !important;
  min-width: unset !important;
}

.label-flex-wrapper .align-items-center.d-lg-flex .form-control,
.label-flex-wrapper .align-items-center.d-lg-flex .select-control {
  width: 100% !important;
  text-align: left !important;
  border-radius: 6px;
  border: 1px solid #c8d6e8;
  background: #f7faff;
  color: #333;
  font-size: 13.5px;
  height: 40px;
  padding: 6px 10px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.label-flex-wrapper .align-items-center.d-lg-flex .form-control:focus {
  border-color: #074EA2;
  box-shadow: 0 0 0 3px rgba(7, 78, 162, 0.10);
  outline: none;
  background: #fff;
}

/* Select2 widget text left-aligned (overrides text-lg-right on parent) */
.label-flex-wrapper .select2-container {
  text-align: left !important;
}
.label-flex-wrapper .select2-selection__rendered {
  text-align: left !important;
}

.label-flex-wrapper .align-items-center.d-lg-flex .form-control[readonly],
.label-flex-wrapper .align-items-center.d-lg-flex .form-control[disabled] {
  background: #eef1f7;
  color: #555;
  cursor: default;
}

/* Form group & column spacing */
.label-flex-wrapper .form-group {
  margin-bottom: 6px;
}

.label-flex-wrapper .col-lg-6,
.label-flex-wrapper .col-xl-4,
.label-flex-wrapper .col-lg-4,
.label-flex-wrapper .col-md-6 {
  margin-bottom: 12px;
}

/* Inline validation error — override global span.error absolute positioning */
.label-flex-wrapper span.error,
.label-flex-wrapper span.form-error,
.label-flex-wrapper label.error,
.label-flex-wrapper label.form-error,
.sf-steps-form span.error,
.sf-steps-form span.form-error,
.sf-steps-form label.error,
.sf-steps-form label.form-error {
  position: static !important;
  display: block;
  color: #ef0000;
  font-size: 11px;
  font-weight: 400;
  margin-top: 3px;
  margin-bottom: 0;
  text-align: left;
  width: 100%;
}

/* Action buttons row */
.label-flex-wrapper .col-12.text-right {
  padding-top: 10px;
  border-top: 1px solid #e8eef7;
  margin-top: 10px;
}

.label-flex-wrapper #btn-save-and-continue,
.label-flex-wrapper .btn-save-and-continue {
  background: #074EA2;
  border: none;
  border-radius: 6px;
  padding: 10px 28px;
  font-size: 14px;
  font-weight: 600;
  color: #fff;
  transition: background 0.25s ease, transform 0.15s ease;
}

.label-flex-wrapper #btn-save-and-continue:hover,
.label-flex-wrapper .btn-save-and-continue:hover {
  background: #1565c0;
  transform: translateY(-1px);
}

.label-flex-wrapper #btn-save-and-send,
.label-flex-wrapper .btn-save-draft {
  border-radius: 6px;
  padding: 10px 22px;
  font-size: 14px;
  font-weight: 600;
  transition: opacity 0.2s ease;
  margin-right: 8px;
}


.select2-container--default .select2-selection--multiple .select2-selection__rendered li:before {
  display: none;
}
