:root {
    --step-active: #244270;
    /* Primary */
    --step-inactive: #bec3ca;
    /* Softer inactive */
    --body-bg: #5482d9;
    /* Body background */

    --gr-1: #6e9cff;
    --gr-2: #244270;

    --my-white: #ffffff;
    --my-gray: #6c757d;
    --my-gray-2: #bebebe;
    --input-bg: #f0f3f8;
    --input-border: #ced4da;
    --input-border-focus: var(--step-active);
    --input-shadow-focus: rgba(36, 66, 112, 0.3);
    --success: #9ee6ae;
    --success-dark: #218838;
    --text-dark: #2c3e50;
    --text-dark-strong: #22313f;
    --text-muted: #daecff;
    --text-muted-light: #ffffff;

    --input-bg: rgba(255, 255, 255, 0.12);
    --input-border: rgba(255, 255, 255, 0.25);
    --input-border-focus: #6e9cff;
    --input-shadow-focus: rgba(110, 156, 255, 0.4);

    --text-danger: #ff8994;

}

.invalid-feedback {
    color: var(--text-danger) !important;
}

.form-control.is-invalid,
.was-validated .form-control:invalid,
.form-select.is-invalid,
.was-validated .form-select:invalid,
.ts-wrapper.form-select.single.required.invalid {
    border-color: var(--text-danger) !important;
}

.required-star {
    color: var(--text-danger) !important;
}

/* Global body and container */
body {
    /* background: linear-gradient(var(--gr-1),var(--gr-2)); */
    background: url('../assets/images/bg-2.jpg') no-repeat center center fixed;
    background-size: cover;
    background-repeat: no-repeat;
    min-height: 100vh;
    color: var(--my-white);
    font-family: "Gilroy", Poppins, Geneva, Verdana, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    margin: 120px;
}

.container-full {
    /* min-width: 80vw; */
    margin: 0 auto;
    box-shadow: 0 8px 24px rgba(36, 66, 112, 0.15);
}

/* Unified container width and style */
/* #student-mock-result-form,
.mt-5 {
    background: var(--my-white);
    padding-block: 40px;
    border-radius: 12px;
    color: var(--text-dark);
    font-weight: 500;
} */

#student-mock-result-form,
.mt-5 {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding-block: 40px;
    border-radius: 12px;
    color: var(--text-dark);
    font-weight: 500;
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}


/* Progress bar container */
#progressbar {
    display: flex;
    justify-content: space-between;
    margin-bottom: 50px;
    align-items: center;
    padding: 0;
    counter-reset: step;
    position: relative;
}

#progressbar li {
    list-style: none;
    position: relative;
    text-align: center;
    flex: 1;
    font-weight: 500;
    color: var(--my-gray);
    transition: color 0.3s ease;
}

#progressbar li img{
    position: absolute;
    left: 12px;
    top: 11px;
    width: 20px;
}

#progressbar li::before {
    content: '';
    counter-increment: step;
    width: 44px;
    height: 44px;
    line-height: 44px;
    border-radius: 50%;
    background: transparent;
    border: 2px solid white;
    display: block;
    color: var(--step-active);
    font-weight: 700;
    font-size: 1.2rem;
    box-shadow: 0 2px 8px rgba(36, 66, 112, 0.1);
    transition: background-color 0.3s ease, color 0.3s ease;
    position: relative;
    z-index: 1;
}

#progressbar li::after {
    content: '';
    position: absolute;
    width: 85%;
    height: 4px;
    background: var(--step-inactive);
    top: 20px;
    left: 44px;
    z-index: 0;
    border-radius: 4px;
    transition: background-color 0.3s ease;
}

#progressbar li:last-child {
    flex: unset;
}

#progressbar li:last-child::after {
    content: none;
}

#progressbar li.active,
#progressbar li.done {
    color: var(--step-active);
}

#progressbar li.active::before,
#progressbar li.done::before {
    background: var(--gr-2);
    color: var(--step-active);
    box-shadow: 0 4px 12px rgba(36, 66, 112, 0.4);
    z-index: 0;
}

#progressbar li.done::after,
#progressbar li.active::after {
    background: var(--my-white);
}

.steps-image {
    width: 100%;
    object-fit: cover;
    border-radius: 24px;
    border: 10px solid var(--step-active);
}

.steps-image img {
    border-radius: 14px;
}

/* Fieldset styling */
fieldset {
    border: 1.5px solid var(--input-border);
    border-radius: 12px;
    padding: 24px 20px 20px 20px;
    margin-bottom: 30px;
    background-color: #ffffff1c;
    box-shadow: 0 3px 10px rgba(84, 130, 217, 0.1);
    position: relative;
    transition: border-color 0.3s ease;
}

fieldset:focus-within {
    border-color: var(--input-border-focus);
    box-shadow: 0 6px 14px var(--input-shadow-focus);
}

fieldset legend {
    font-weight: 600;
    font-size: 1.15rem;
    color: var(--step-active);
    padding: 0 10px;
    margin-bottom: 12px;
    width: auto;
    float: unset;
    border-bottom: none;
}

/* Inputs inside fieldset */
.ts-control,
.ts-wrapper.single.input-active .ts-control {
    background: none !important;
    border: none !important;
    font-size: 0.9rem !important;
    font-weight: 500 !important;
}
.ts-dropdown, .ts-control, .ts-control input{
    color: white !important;
}

/* .form-control,
.form-select {
    border-radius: 8px;
    border: 1.5px solid var(--input-border);
    padding: 10px 14px;
    background-color: var(--input-bg);
    color: #333;
    font-weight: 500;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    box-shadow: none;
    outline-offset: 0;
} */

/* ===========================
   INPUTS / FORMS
=========================== */
.form-control,
.form-select {
    background: rgba(255, 255, 255, 0.12);
    border: 1.5px solid var(--input-border);
    padding: 12px 14px;
    border-radius: 10px;
    color: white;
    font-weight: 500;
    transition: 0.25s ease;
}

.form-control::placeholder {
    color: #cdd4e0;
}

.form-control:focus,
.form-select:focus {
    border-color: var(--input-border-focus);
    box-shadow: 0 0 12px var(--input-shadow-focus);
    background: rgba(255, 255, 255, 0.18);
    color: white;
    outline: none;
}

/* Fix: options du <select> (menu déroulant) lisibles */
#student-mock-result-form .form-select option {
    color: #22313f;          /* texte sombre dans la liste */
    background-color: #fff;  /* fond blanc (par défaut sur Windows) */
}

/* Optionnel: placeholder grisé (si tu as une <option value="" disabled selected>) */
#student-mock-result-form .form-select option[disabled] {
    color: #6c757d;
}

.form-control:disabled {
    background-color: #2d2d2d2b;
    opacity: 1;
}

/* Invalid */
.is-invalid {
    border-color: #dc3545 !important;
}

/* Row spacing in fieldsets */
fieldset .row+.row {
    margin-top: 20px;
}

/* Invalid field styling (Bootstrap compatible) */
.is-invalid {
    border-color: #dc3545 !important;
    padding-right: 2.25rem !important;
    background-image: url('data:image/svg+xml,%3csvg xmlns=%22http://www.w3.org/2000/svg%22 fill=%22%23dc3545%22 viewBox=%220 0 12 12%22%3e%3cpath d=%22M6 0a6 6 0 100 12A6 6 0 006 0zm0 9a.75.75 0 11-.75-.75A.75.75 0 016 9zm.25-6a.25.25 0 00-.5 0v3a.25.25 0 00.5 0V3z%22/%3e%3c/svg%3e') !important;
    background-repeat: no-repeat !important;
    background-position: right calc(0.375em + 0.1875rem) center !important;
    background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem) !important;
}

/* Text and label colors inside main container */
#student-mock-result-form,
#student-mock-result-form label,
#student-mock-result-form legend,
#student-mock-result-form p,
#student-mock-result-form .form-control,
#student-mock-result-form .form-select,
#student-mock-result-form .form-check-label {
    color: var(--my-white);
    font-weight: 500;
}

#student-mock-result-form label,
#student-mock-result-form legend,
#student-mock-result-form .form-check-label {
    font-weight: 600;
    color: var(--my-white);
}

/* Card styling general (applies to result and thank you card as well) */
.card {
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(36, 66, 112, 0.15);
    border: none;
    background-color: var(--my-white);
    color: var(--text-dark);
    font-family: "Gilroy", Poppins, Geneva, Verdana, sans-serif;
}

/* Card header */
.card-header.bg-success {
    background-color: var(--success) !important;
    color: var(--my-white) !important;
    font-weight: 700;
    font-size: 1.4rem;
    border-top-left-radius: 12px;
    border-top-right-radius: 12px;
    box-shadow: inset 0 -3px 8px rgba(0, 0, 0, 0.15);
}

/* Headings with success color inside card body */
.card-body h4.text-success,
h2.fw-bold.text-success,
.text-success.mb-3 i.bi-check-circle-fill {
    color: var(--success) !important;
}

/* Success icon */
.text-success.mb-3 i.bi-check-circle-fill {
    font-size: 3rem;
    filter: drop-shadow(0 2px 3px rgba(40, 167, 69, 0.4));
}

/* Large heading for thank-you */
h2.fw-bold.text-success {
    font-weight: 700;
    font-size: 2.5rem;
}

/* Paragraph styling in card body */
.card-body p {
    line-height: 1.5;
    margin-bottom: 1rem;
    color: var(--text-muted) !important;
    font-weight: 500;
    /* max-width: 520px; */
    /* margin-left: auto;
    margin-right: auto; */
}

.h5,
h5 {
    color: var(--text-muted-light) !important;
}

/* Lead paragraph special */
p.lead.mt-3 {
    font-size: 1.25rem;
    color: var(--text-muted);
}

/* Muted small text (thank you page) */
p.text-muted.mb-4 {
    color: var(--text-muted-light);
    font-size: 1rem;
}

a {
    color: var(--text-muted) !important;
    /* text-decoration: underline !important; */
}

small.form-text.text-muted {
    color: var(--text-muted) !important;
}

/* Lists inside card body */
.card-body ul {
    padding-left: 1.25rem;
    color: var(--text-muted);
}

.card-body ul li {
    margin-bottom: 0.5rem;
    font-weight: 500;
}

/* Table styling */
.table.table-bordered {
    border: 1px solid var(--input-border);
    border-radius: 8px;
    overflow: hidden;
}

.table.table-bordered thead {
    /* background-color:var(--my-white); */
    background-color: rgba(255, 255, 255, 0.3);
}

.table.table-bordered th,
.table.table-bordered td {
    background-color: rgba(255, 255, 255, 0.15);
    color: white !important;
}

.table.table-bordered th,
.table.table-bordered td {
    vertical-align: middle;
    text-align: center;
    font-weight: 600;
    color: var(--text-dark);
}

/* Buttons container */
.d-flex.justify-content-end {
    margin-top: 20px;
}

/* Specific thank-you card tweaks */
.card.shadow-sm.border-0 {
    border-radius: 12px;
    box-shadow: 0 8px 28px rgba(36, 66, 112, 0.12);
}

/* Card body padding for thank-you */
.card-body.py-5 {
    padding-top: 3rem !important;
    padding-bottom: 3rem !important;
}

/* Buttons override */
/* ===========================
   GLASS BUTTONS
=========================== */
.glass-btn,
.btn-primary,
.btn-secondary,
.btn-success {
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(12px) saturate(150%);
    -webkit-backdrop-filter: blur(12px) saturate(150%);

    color: #fff;
    padding: 0.65rem 1.4rem;
    border-radius: 12px;
    font-weight: 600;
    letter-spacing: 0.03em;
    transition: all 0.25s ease;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);

    display: inline-flex;
    align-items: center;
    gap: 8px;
}

/* Hover effect */
.glass-btn:hover,
.btn-primary:hover,
.btn-secondary:hover,
.btn-success:hover {
    background: rgba(255, 255, 255, 0.22);
    border-color: rgba(255, 255, 255, 0.35);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.45);
    transform: translateY(-2px);
}

/* Pressed effect */
.glass-btn:active,
.btn-primary:active,
.btn-secondary:active,
.btn-success:active {
    transform: translateY(1px) scale(0.97);
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.3);
}

/* Focus ring */
.glass-btn:focus,
.btn-primary:focus,
.btn-secondary:focus,
.btn-success:focus {
    outline: none;
    box-shadow: 0 0 0 4px rgba(110, 156, 255, 0.35);
}

/* ===========================
   COLOR VARIANTS (glass-tinted)
=========================== */

/* Primary (blue-tinted glass) */
.btn-primary {
    background: rgba(36, 66, 112, 0.45);
    border-color: rgba(255, 255, 255, 0.28);
}

/* Secondary (silver glass) */
.btn-secondary {
    background: rgba(255, 255, 255, 0.20);
}

/* Success (green-tinted glass) */
.btn-success {
    background: rgba(40, 167, 69, 0.35);
}

.lottie-container {
    height: 400px;
    width: 100%;
}

/* Control (input box) */
/* .ts-control {
    background: rgba(255,255,255,0.12) !important;
    border: 1px solid rgba(255,255,255,0.25) !important;
    backdrop-filter: blur(10px);
    color: white !important;
    border-radius: 12px !important;
} */
.ts-wrapper.single .ts-control,
.ts-wrapper.single .ts-control input::placeholder,
.item {
    color: white !important;
    font-size: 1rem !important;
    font-weight: 500 !important;
}

/* Dropdown */
.ts-dropdown {
    background: var(--my-white) !important;


    backdrop-filter: blur(12px);
    border-radius: 12px !important;
    border: 1px solid rgba(255, 255, 255, 0.25);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
}


/* Options */
.ts-dropdown .option,
.ts-dropdown-content {
    padding: 10px 12px;
    border-radius: 8px;
    font-size: 1rem !important;
    font-weight: 500 !important;
    color: black !important;
}

.ts-dropdown .option:hover

/* .ts-dropdown-content:hover  */
    {
    background: var(--my-gray-2) !important;
}

/* “Add new” row */
.glass-option {
    background: rgba(255, 255, 255, 0.15);
    padding: 10px;
    border-radius: 8px;
    color: white;
}
.result-card,
.result-card .text-muted{
    color: white !important;
}



/* Responsive tweaks */
@media (max-width: 767px) {
    fieldset {
        padding: 20px 15px;
    }

    fieldset legend {
        font-size: 1rem;
    }

    #student-mock-result-form,
    .container.mt-5 {
        padding-block: 30px;
        margin: 1rem auto;
    }

    .card-body p,
    p.lead {
        font-size: 1.1rem;
        max-width: 100%;
    }
}

