/* =========================================================
   Compulsory Motor Insurance – Form Styles
   ========================================================= */

   .contact-form .row.gy-3 {
    --bs-gutter-x: 3.2rem;
    row-gap: 24px;
  }
  
  .contact-form .col-md-6 .form_group {
    max-width: 500px;
  }
  

.contact-form .form_control,
.contact-form select.wide,
.contact-form .nice-select {
    border-radius: 10px;
}

/* Limit native select dropdown height when nice-select is disabled */
.contact-form select.no-nice-select {
    max-height: 60px;
    height: 60px;
    line-height: 60px;
}

/* Nice-select dropdown scrolling */
.nice-select .list {
    max-height: 240px;
    overflow-y: auto;
}

.contact-form .main-btn.primary-btn {
    width: 25%;
    min-width: 180px;
    display: block;
    margin: 0 auto;
}

/* Input wrapper for required star inside */
.contact-form .input-wrapper {
    position: relative;
    display: inline-block;
    width: 100%;
}

.contact-form .input-wrapper .form_control,
.contact-form .input-wrapper select {
    width: 100%;
    padding-right: 30px;
}

.contact-form .input-wrapper .required-star {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #ff0000;
    font-size: 16px;
    font-weight: bold;
    pointer-events: none;
}

.contact-form .form_group label .required-star {
    color: #ff0000;
    font-size: 14px;
    font-weight: bold;
    margin-left: 3px;
}

/* Form label styling */
.contact-form .form_group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #333;
}

.contact-form .form_group.required-field label::after {
    content: "";
}

/* =========================================================
   Input Wrapper (base)
   ========================================================= */

.contact-form .input-wrapper {
    position: relative;
    width: 100%;
}

/* =========================================================
   Base form controls (input + select)
   ========================================================= */

.contact-form .form_control {
    display: block;
    width: 100%;
    height: 60px;

    padding: 19px 20px;
    border-radius: 10px;
    border: 1px solid rgba(9, 8, 8, 0.1);
    background: #fff;

    font: 500 18px "DM Sans", sans-serif;
    line-height: 25px;
    color: #111;

    transition: all .25s ease-out;
    outline: none;
    box-shadow: 0 6px 18px rgba(0,0,0,0.04);
}

.contact-form .form_control:hover {
    border-color: rgba(9, 8, 8, 0.18);
    box-shadow: 0 10px 26px rgba(0,0,0,0.06);
}

.contact-form .form_control:focus {
    border-color: rgba(9, 8, 8, 0.22);
    box-shadow: 0 12px 30px rgba(15,118,110,0.12);
}

/* =========================================================
   Required star (before label text)
   ========================================================= */

.contact-form .required-star {
    position: static !important;
    display: inline-block;
    margin-right: 6px;
    left: auto !important;
    right: auto !important;
    top: auto !important;
    transform: none !important;
    font-size: 15px;
    font-weight: 700;
    color: #e63946;
    line-height: 1;
    vertical-align: middle;
    pointer-events: none;
}

.driver-license-field-wrapper.disabled-star .required-star {
    display: none;
}

/* =========================================================
   NICE SELECT (theme default – untouched)
   ========================================================= */

.contact-form .nice-select {
    height: 60px;
    line-height: 60px;
    padding-left: 20px;
    padding-right: 44px;
    border-radius: 10px;
    border: 1px solid rgba(9, 8, 8, 0.1);
    box-shadow: 0 6px 18px rgba(0,0,0,0.04);
    font: 500 18px "DM Sans", sans-serif;
}

.contact-form .nice-select:after {
    right: 18px;
}

/* Validation states */
.contact-form .form_control.is-invalid {
    border-color: #dc3545;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.1);
    color: #dc3545;
}

.contact-form .form_control.is-invalid:focus {
    border-color: #dc3545;
    box-shadow: 0 0 0 0.25rem rgba(220, 53, 69, 0.18);
}

.contact-form .errorlist.ajax-error {
    margin-top: 6px;
}

/* Success alert */
.success-alert {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 18px;
    border-radius: 10px;
    background: #e8f5e9;
    border: 1px solid #c8e6c9;
    color: #1b5e20;
    font-weight: 600;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.05);
    margin: 0 auto;
}

.success-alert .success-icon {
    display: inline-flex;
    width: 22px;
    height: 22px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #1b5e20;
    color: #fff;
    font-size: 13px;
    font-weight: 700;
}

.contact-form .errorlist {
    list-style: none;
    margin: 6px 0 0;
    padding: 0;
    font-size: 13px;
    font-weight: 600;
    color: #c92a2a;
}

/* Select2 dropdown width control */
.select2-container--default .select2-dropdown {
    width: 100% !important;
}

.contact-form .select2-container {
    width: 100% !important;
    min-width: 100% !important;
    display: block !important;
    max-width: 100% !important;
}

.contact-form .select2 {
    width: 100% !important;
    min-width: 100% !important;
    display: block !important;
    max-width: 100% !important;
}

.contact-form .select2 .selection {
    display: block !important;
    width: 100% !important;
}

/* Hide original select once Select2 attaches */
.contact-form .select2-hidden-accessible {
    display: none !important;
}

/* Select2 single selection styling to match inputs */
.contact-form .select2-container--default .select2-selection--single {
    display: flex;
    align-items: center;
    height: 60px;
    padding: 19px 44px 19px 20px;
    border: 2px solid rgba(9, 8, 8, 0.1);
    border-radius: 10px;
    box-shadow: 0 6px 18px rgba(0,0,0,0.04);
    background: #fff;
    font: 500 18px "DM Sans", sans-serif;
    color: #111;
    width: 100% !important;
    box-sizing: border-box;
}

.contact-form .select2-container--default .select2-selection__rendered {
    padding: 0;
    margin: 0;
    line-height: 1.2;
    color: inherit;
}

.contact-form .select2-container--default .select2-selection__arrow {
    height: 18px;
    width: 18px;
    right: 10px !important;
    top: 37% !important;
    transform: translateY(-50%) !important;
}

.contact-form .select2-container--default .select2-selection__arrow b {
    border-width: 6px 5px 0 5px !important;
    margin-left: -5px !important;
}

/* reCAPTCHA sizing (slightly smaller on desktop) */
/* reCAPTCHA sizing reset */
.captcha-submit-row .g-recaptcha {
    transform: none;
    height: auto;
}
