/* Loader container */
#zen-loader,
.loader-container {
    position: fixed;
    inset: 0;                 /* ersätter top/left/width/height */
    background-color: rgba(255, 255, 255, 0.95);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

/* Ring loader */
#zen-loader .loader,
.loader-container .loader {
    width: 100px;
    height: 100px;
    border-top-color: transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0%   { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Fade-out på själva containern */
#zen-loader.fade-out,
.loader-container.fade-out {
    opacity: 0;
    transition: opacity 0.5s ease;
    pointer-events: none;
}


/* Check password strength */
  .pw-meter .list-group-item{padding:.35rem .75rem}
  .pw-meter .ok i{color:#198754}
  .pw-meter .ok span{color:#198754}
  
    /* Inga Bootstrap-background-ikoner i inputs som har öga */
  .form-control.has-toggle.is-valid,
  .form-control.has-toggle.is-invalid {
    background-image: none !important;
    padding-right: 2.25rem; /* utrymme för ögat */
  }

.password-component .invalid-feedback {
    display: none;
}

.password-component input.is-invalid ~ .invalid-feedback {
    display: block;
}


/* Gör telefon-kontrollen exakt lika bred som .form-control */
.iti input.form-control{width:100%}
.iti--separate-dial-code .iti__selected-flag{background-color:transparent}
/* Säkerställ att landlistan inte klipps eller hamnar under annat */
.iti__country-list{z-index:2000}
.iti{width:100%} .iti__flag-container{z-index:5} /* så dropdownen inte hamnar under */


/* === Gemensamt fÃ¶r single & multiple === */
.select2-container--default .select2-selection--single,
.select2-container--default .select2-selection--multiple {
    border: 1px solid #e4e7ea !important;
    border-radius: 0.375rem !important;
    padding: 0.375rem 0.75rem !important;
    font-size: 1rem !important;
    line-height: 1.5 !important;
    background-color: #fff !important;
    min-height: 2.375rem !important;
}

/* === Fokus === */
.select2-container--default.select2-container--focus .select2-selection {
    border-color: #86b7fe !important;
    box-shadow: 0 0 0 0.25rem rgba(13,110,253,.25) !important;
    outline: 0 !important;
}

/* === Single select === */
.select2-container--default .select2-selection--single {
    position: relative !important;
}

.select2-container--default .select2-selection--single .select2-selection__rendered {
    display: flex !important;
    align-items: center !important;
    height: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
    color: #212529 !important;
    line-height: 2.375rem !important;
}

.select2-container--default .select2-selection--single .select2-selection__arrow {
    position: absolute !important;
    top: 48% !important; /* ðŸ”º LÃ¤tt upp */
    right: 0.75rem !important;
    transform: translateY(-50%) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    pointer-events: none !important;
}

/* === Multiple select === */
.select2-container--default .select2-selection--multiple .select2-selection__rendered {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 0.25rem !important;
    padding: 0 !important;
    margin: 0 !important;
}

/* === Tagg-bubbla (val) === */
.select2-container--default .select2-selection--multiple .select2-selection__choice {
    background-color: #e9ecef !important;
    border: 1px solid #e4e7ea !important;
    border-radius: 0.25rem !important;
    padding: 0.25rem 0.625rem 0.25rem 0.5rem !important; /* lite mer luft */
    font-size: 0.875rem !important;
    color: #212529 !important;
    display: inline-flex !important;
    align-items: center !important;
    line-height: 1.25rem !important;
    height: auto !important;
}

/* === X:et i tagg-bubblan === */
.select2-container--default .select2-selection--multiple .select2-selection__choice__remove {
    margin-left: -0.25rem !important;
    margin-right: 0.5rem !important; /* ðŸ”º mer luft mellan X och text */
    color: #6c757d !important;
    font-weight: bold !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    cursor: pointer !important;
}

.select2-container--default .select2-selection--multiple .select2-selection__choice__display {
    padding-left: 28px!important;
}

.select2-container--default .select2-selection--multiple .select2-selection__choice__remove {
    line-height: 26px!important;
}

.select2-container--default .select2-selection--multiple .select2-selection__choice__remove {
    padding: 0 10px!important;
}

.select2-container--default .select2-selection--single .select2-selection__clear {
    margin-top: -3px!important;
}

.select2-container .select2-search--inline .select2-search__field {
    margin-top: 2px !important;
    line-height: 0.8rem !important;
    vertical-align: middle !important;
    color: #5b5d60!important;
    margin-left: -1px!important;
    font-size: 0.8rem !important;
    font-weight: 400 !important;

}

.select2-container--default .select2-selection--single .select2-selection__placeholder {
    color: #5b5d60!important;
}

/* === Justera textstil till Bootstrap-standard === */
.select2-container--default .select2-selection--single .select2-selection__rendered,
.select2-container--default .select2-selection--multiple .select2-selection__rendered,
.select2-container .select2-search--inline .select2-search__field {
    font-size: 1rem !important;
    font-weight: 400 !important;
    color: #212529 !important;
}

.form-switch .form-check-input.custom-switch-lg {
    width: 3rem;
    height: 1.5rem;
}

.form-switch .form-check-input.custom-switch-lg:checked {
    background-position: right center;
}

.form-switch .form-check-input.custom-switch-lg::before {
    transform: scale(1.5); /* GÃ¶r "knappen" stÃ¶rre */
}
    
.form-switch .form-check-label {
    margin-left: 0.5rem !important; /* lite space mellan switch och text */
    position: relative;
    top: 2px; /* ðŸ”» flytta texten nedÃ¥t en aning */
}

/* Återställ Bootstraps default som verkar vara överskriven */
.modal .modal-header {
  display: flex!important;
  align-items: center!important;
  justify-content: space-between!important;
}

/* Se till att krysset verkligen trycks till höger */
.modal .modal-header .btn-close {
  margin-left: auto!important;
}

/* Footer/site-logo: undvik skev proportion om HTML har t.ex. height="50" utan matchande bredd */
img.sa-footer-logo {
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: 5rem;
  object-fit: contain;
}

/* WCAG 2.4.1 — hoppa till huvudinnehåll */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0.5rem;
  z-index: 10000;
  padding: 0.625rem 1rem;
  background: #fff;
  color: #111;
  border: 2px solid currentColor;
  border-radius: 0.375rem;
  font-weight: 600;
  text-decoration: none;
}
.skip-link:focus {
  left: 0.5rem;
  outline: 2px solid var(--brand-primary, #1E3A8A);
  outline-offset: 2px;
}

