/* ============================================================
   Custom Utility Framework — Bootstrap 5 Style Classes
   ============================================================ */

/* --- CSS Variables (Theme) --- */
:root {
    --primary: #0d6efd;
    --primary-hover: #0b5ed7;
    --secondary: #6c757d;
    --secondary-hover: #5c636a;
    --success: #198754;
    --success-hover: #157347;
    --danger: #dc3545;
    --danger-hover: #bb2d3b;
    --warning: #ffc107;
    --warning-hover: #ffca2c;
    --info: #0dcaf0;
    --info-hover: #31d2f2;
    --light: #f8f9fa;
    --dark: #212529;
    --body-bg: #ffffff;
    --body-color: #212529;
    --border-color: #dee2e6;
    --border-radius: 0.375rem;
    --border-radius-sm: 0.25rem;
    --border-radius-lg: 0.5rem;
    --input-focus-border: #86b7fe;
    --input-focus-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
    --font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

/* ============================================================
   1. MARGIN — m-{0..5}, m-auto, directions, negative
   ============================================================ */
.m-0 {
    margin: 0 !important;
}
.m-1 {
    margin: 0.25rem !important;
}
.m-2 {
    margin: 0.5rem !important;
}
.m-3 {
    margin: 1rem !important;
}
.m-4 {
    margin: 1.5rem !important;
}
.m-5 {
    margin: 3rem !important;
}
.m-auto {
    margin: auto !important;
}

.mt-0 {
    margin-top: 0 !important;
}
.mt-1 {
    margin-top: 0.25rem !important;
}
.mt-2 {
    margin-top: 0.5rem !important;
}
.mt-3 {
    margin-top: 1rem !important;
}
.mt-4 {
    margin-top: 1.5rem !important;
}
.mt-5 {
    margin-top: 3rem !important;
}
.mt-auto {
    margin-top: auto !important;
}

.mb-0 {
    margin-bottom: 0 !important;
}
.mb-1 {
    margin-bottom: 0.25rem !important;
}
.mb-2 {
    margin-bottom: 0.5rem !important;
}
.mb-3 {
    margin-bottom: 1rem !important;
}
.mb-4 {
    margin-bottom: 1.5rem !important;
}
.mb-5 {
    margin-bottom: 3rem !important;
}
.mb-auto {
    margin-bottom: auto !important;
}

.ms-0 {
    margin-left: 0 !important;
}
.ms-1 {
    margin-left: 0.25rem !important;
}
.ms-2 {
    margin-left: 0.5rem !important;
}
.ms-3 {
    margin-left: 1rem !important;
}
.ms-4 {
    margin-left: 1.5rem !important;
}
.ms-5 {
    margin-left: 3rem !important;
}
.ms-auto {
    margin-left: auto !important;
}

.me-0 {
    margin-right: 0 !important;
}
.me-1 {
    margin-right: 0.25rem !important;
}
.me-2 {
    margin-right: 0.5rem !important;
}
.me-3 {
    margin-right: 1rem !important;
}
.me-4 {
    margin-right: 1.5rem !important;
}
.me-5 {
    margin-right: 3rem !important;
}
.me-auto {
    margin-right: auto !important;
}

.mx-0 {
    margin-left: 0 !important;
    margin-right: 0 !important;
}
.mx-1 {
    margin-left: 0.25rem !important;
    margin-right: 0.25rem !important;
}
.mx-2 {
    margin-left: 0.5rem !important;
    margin-right: 0.5rem !important;
}
.mx-3 {
    margin-left: 1rem !important;
    margin-right: 1rem !important;
}
.mx-4 {
    margin-left: 1.5rem !important;
    margin-right: 1.5rem !important;
}
.mx-5 {
    margin-left: 3rem !important;
    margin-right: 3rem !important;
}
.mx-auto {
    margin-left: auto !important;
    margin-right: auto !important;
}

.my-0 {
    margin-top: 0 !important;
    margin-bottom: 0 !important;
}
.my-1 {
    margin-top: 0.25rem !important;
    margin-bottom: 0.25rem !important;
}
.my-2 {
    margin-top: 0.5rem !important;
    margin-bottom: 0.5rem !important;
}
.my-3 {
    margin-top: 1rem !important;
    margin-bottom: 1rem !important;
}
.my-4 {
    margin-top: 1.5rem !important;
    margin-bottom: 1.5rem !important;
}
.my-5 {
    margin-top: 3rem !important;
    margin-bottom: 3rem !important;
}
.my-auto {
    margin-top: auto !important;
    margin-bottom: auto !important;
}

/* Negative margins */
.mt-n1 {
    margin-top: -0.25rem !important;
}
.mt-n2 {
    margin-top: -0.5rem !important;
}
.mt-n3 {
    margin-top: -1rem !important;
}
.mb-n1 {
    margin-bottom: -0.25rem !important;
}
.mb-n2 {
    margin-bottom: -0.5rem !important;
}
.mb-n3 {
    margin-bottom: -1rem !important;
}

/* ============================================================
   2. PADDING — p-{0..5}, directions
   ============================================================ */
.p-0 {
    padding: 0 !important;
}
.p-1 {
    padding: 0.25rem !important;
}
.p-2 {
    padding: 0.5rem !important;
}
.p-3 {
    padding: 1rem !important;
}
.p-4 {
    padding: 1.5rem !important;
}
.p-5 {
    padding: 3rem !important;
}

.pt-0 {
    padding-top: 0 !important;
}
.pt-1 {
    padding-top: 0.25rem !important;
}
.pt-2 {
    padding-top: 0.5rem !important;
}
.pt-3 {
    padding-top: 1rem !important;
}
.pt-4 {
    padding-top: 1.5rem !important;
}
.pt-5 {
    padding-top: 3rem !important;
}

.pb-0 {
    padding-bottom: 0 !important;
}
.pb-1 {
    padding-bottom: 0.25rem !important;
}
.pb-2 {
    padding-bottom: 0.5rem !important;
}
.pb-3 {
    padding-bottom: 1rem !important;
}
.pb-4 {
    padding-bottom: 1.5rem !important;
}
.pb-5 {
    padding-bottom: 3rem !important;
}

.ps-0 {
    padding-left: 0 !important;
}
.ps-1 {
    padding-left: 0.25rem !important;
}
.ps-2 {
    padding-left: 0.5rem !important;
}
.ps-3 {
    padding-left: 1rem !important;
}
.ps-4 {
    padding-left: 1.5rem !important;
}
.ps-5 {
    padding-left: 3rem !important;
}

.pe-0 {
    padding-right: 0 !important;
}
.pe-1 {
    padding-right: 0.25rem !important;
}
.pe-2 {
    padding-right: 0.5rem !important;
}
.pe-3 {
    padding-right: 1rem !important;
}
.pe-4 {
    padding-right: 1.5rem !important;
}
.pe-5 {
    padding-right: 3rem !important;
}

.px-0 {
    padding-left: 0 !important;
    padding-right: 0 !important;
}
.px-1 {
    padding-left: 0.25rem !important;
    padding-right: 0.25rem !important;
}
.px-2 {
    padding-left: 0.5rem !important;
    padding-right: 0.5rem !important;
}
.px-3 {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
}
.px-4 {
    padding-left: 1.5rem !important;
    padding-right: 1.5rem !important;
}
.px-5 {
    padding-left: 3rem !important;
    padding-right: 3rem !important;
}

.py-0 {
    padding-top: 0 !important;
    padding-bottom: 0 !important;
}
.py-1 {
    padding-top: 0.25rem !important;
    padding-bottom: 0.25rem !important;
}
.py-2 {
    padding-top: 0.5rem !important;
    padding-bottom: 0.5rem !important;
}
.py-3 {
    padding-top: 1rem !important;
    padding-bottom: 1rem !important;
}
.py-4 {
    padding-top: 1.5rem !important;
    padding-bottom: 1.5rem !important;
}
.py-5 {
    padding-top: 3rem !important;
    padding-bottom: 3rem !important;
}

/* ============================================================
   3. GAP — g-{0..5}
   ============================================================ */
.g-0 {
    gap: 0 !important;
}
.g-1 {
    gap: 0.25rem !important;
}
.g-2 {
    gap: 0.5rem !important;
}
.g-3 {
    gap: 1rem !important;
}
.g-4 {
    gap: 1.5rem !important;
}
.g-5 {
    gap: 3rem !important;
}

/* ============================================================
   4. GRID SYSTEM — row, col-{1..12}, responsive breakpoints
   ============================================================ */
.row {
    display: flex;
    flex-wrap: wrap;
    margin-left: -0.75rem;
    margin-right: -0.75rem;
}

.row > [class*="col-"] {
    padding-left: 0.75rem;
    padding-right: 0.75rem;
}

.col {
    flex: 1 0 0%;
    max-width: 100%;
}
.col-1 {
    flex: 0 0 auto;
    width: 8.333333%;
}
.col-2 {
    flex: 0 0 auto;
    width: 16.666667%;
}
.col-3 {
    flex: 0 0 auto;
    width: 25%;
}
.col-4 {
    flex: 0 0 auto;
    width: 33.333333%;
}
.col-5 {
    flex: 0 0 auto;
    width: 41.666667%;
}
.col-6 {
    flex: 0 0 auto;
    width: 50%;
}
.col-7 {
    flex: 0 0 auto;
    width: 58.333333%;
}
.col-8 {
    flex: 0 0 auto;
    width: 66.666667%;
}
.col-9 {
    flex: 0 0 auto;
    width: 75%;
}
.col-10 {
    flex: 0 0 auto;
    width: 83.333333%;
}
.col-11 {
    flex: 0 0 auto;
    width: 91.666667%;
}
.col-12 {
    flex: 0 0 auto;
    width: 100%;
}

/* Responsive: sm ≥ 576px */
@media (min-width: 576px) {
    .col-sm {
        flex: 1 0 0%;
        max-width: 100%;
    }
    .col-sm-1 {
        flex: 0 0 auto;
        width: 8.333333%;
    }
    .col-sm-2 {
        flex: 0 0 auto;
        width: 16.666667%;
    }
    .col-sm-3 {
        flex: 0 0 auto;
        width: 25%;
    }
    .col-sm-4 {
        flex: 0 0 auto;
        width: 33.333333%;
    }
    .col-sm-5 {
        flex: 0 0 auto;
        width: 41.666667%;
    }
    .col-sm-6 {
        flex: 0 0 auto;
        width: 50%;
    }
    .col-sm-7 {
        flex: 0 0 auto;
        width: 58.333333%;
    }
    .col-sm-8 {
        flex: 0 0 auto;
        width: 66.666667%;
    }
    .col-sm-9 {
        flex: 0 0 auto;
        width: 75%;
    }
    .col-sm-10 {
        flex: 0 0 auto;
        width: 83.333333%;
    }
    .col-sm-11 {
        flex: 0 0 auto;
        width: 91.666667%;
    }
    .col-sm-12 {
        flex: 0 0 auto;
        width: 100%;
    }
}

/* Responsive: md ≥ 768px */
@media (min-width: 768px) {
    .col-md {
        flex: 1 0 0%;
        max-width: 100%;
    }
    .col-md-1 {
        flex: 0 0 auto;
        width: 8.333333%;
    }
    .col-md-2 {
        flex: 0 0 auto;
        width: 16.666667%;
    }
    .col-md-3 {
        flex: 0 0 auto;
        width: 25%;
    }
    .col-md-4 {
        flex: 0 0 auto;
        width: 33.333333%;
    }
    .col-md-5 {
        flex: 0 0 auto;
        width: 41.666667%;
    }
    .col-md-6 {
        flex: 0 0 auto;
        width: 50%;
    }
    .col-md-7 {
        flex: 0 0 auto;
        width: 58.333333%;
    }
    .col-md-8 {
        flex: 0 0 auto;
        width: 66.666667%;
    }
    .col-md-9 {
        flex: 0 0 auto;
        width: 75%;
    }
    .col-md-10 {
        flex: 0 0 auto;
        width: 83.333333%;
    }
    .col-md-11 {
        flex: 0 0 auto;
        width: 91.666667%;
    }
    .col-md-12 {
        flex: 0 0 auto;
        width: 100%;
    }
}

/* Responsive: lg ≥ 992px */
@media (min-width: 992px) {
    .col-lg {
        flex: 1 0 0%;
        max-width: 100%;
    }
    .col-lg-1 {
        flex: 0 0 auto;
        width: 8.333333%;
    }
    .col-lg-2 {
        flex: 0 0 auto;
        width: 16.666667%;
    }
    .col-lg-3 {
        flex: 0 0 auto;
        width: 25%;
    }
    .col-lg-4 {
        flex: 0 0 auto;
        width: 33.333333%;
    }
    .col-lg-5 {
        flex: 0 0 auto;
        width: 41.666667%;
    }
    .col-lg-6 {
        flex: 0 0 auto;
        width: 50%;
    }
    .col-lg-7 {
        flex: 0 0 auto;
        width: 58.333333%;
    }
    .col-lg-8 {
        flex: 0 0 auto;
        width: 66.666667%;
    }
    .col-lg-9 {
        flex: 0 0 auto;
        width: 75%;
    }
    .col-lg-10 {
        flex: 0 0 auto;
        width: 83.333333%;
    }
    .col-lg-11 {
        flex: 0 0 auto;
        width: 91.666667%;
    }
    .col-lg-12 {
        flex: 0 0 auto;
        width: 100%;
    }
}

/* Responsive: xl ≥ 1200px */
@media (min-width: 1200px) {
    .col-xl {
        flex: 1 0 0%;
        max-width: 100%;
    }
    .col-xl-1 {
        flex: 0 0 auto;
        width: 8.333333%;
    }
    .col-xl-2 {
        flex: 0 0 auto;
        width: 16.666667%;
    }
    .col-xl-3 {
        flex: 0 0 auto;
        width: 25%;
    }
    .col-xl-4 {
        flex: 0 0 auto;
        width: 33.333333%;
    }
    .col-xl-5 {
        flex: 0 0 auto;
        width: 41.666667%;
    }
    .col-xl-6 {
        flex: 0 0 auto;
        width: 50%;
    }
    .col-xl-7 {
        flex: 0 0 auto;
        width: 58.333333%;
    }
    .col-xl-8 {
        flex: 0 0 auto;
        width: 66.666667%;
    }
    .col-xl-9 {
        flex: 0 0 auto;
        width: 75%;
    }
    .col-xl-10 {
        flex: 0 0 auto;
        width: 83.333333%;
    }
    .col-xl-11 {
        flex: 0 0 auto;
        width: 91.666667%;
    }
    .col-xl-12 {
        flex: 0 0 auto;
        width: 100%;
    }
}

/* ============================================================
   5. DISPLAY
   ============================================================ */
.d-none {
    display: none !important;
}
.d-block {
    display: block !important;
}
.d-inline {
    display: inline !important;
}
.d-inline-block {
    display: inline-block !important;
}
.d-flex {
    display: flex !important;
}
.d-inline-flex {
    display: inline-flex !important;
}
.d-grid {
    display: grid !important;
}

/* ============================================================
   6. FLEX UTILITIES
   ============================================================ */
.flex-row {
    flex-direction: row !important;
}
.flex-column {
    flex-direction: column !important;
}
.flex-wrap {
    flex-wrap: wrap !important;
}
.flex-nowrap {
    flex-wrap: nowrap !important;
}
.flex-grow-0 {
    flex-grow: 0 !important;
}
.flex-grow-1 {
    flex-grow: 1 !important;
}

.justify-content-start {
    justify-content: flex-start !important;
}
.justify-content-end {
    justify-content: flex-end !important;
}
.justify-content-center {
    justify-content: center !important;
}
.justify-content-between {
    justify-content: space-between !important;
}
.justify-content-around {
    justify-content: space-around !important;
}

.align-items-start {
    align-items: flex-start !important;
}
.align-items-end {
    align-items: flex-end !important;
}
.align-items-center {
    align-items: center !important;
}
.align-items-baseline {
    align-items: baseline !important;
}
.align-items-stretch {
    align-items: stretch !important;
}

.align-self-start {
    align-self: flex-start !important;
}
.align-self-end {
    align-self: flex-end !important;
}
.align-self-center {
    align-self: center !important;
}
.align-self-stretch {
    align-self: stretch !important;
}

/* ============================================================
   7. TEXT UTILITIES
   ============================================================ */
.text-start {
    text-align: left !important;
}
.text-center {
    text-align: center !important;
}
.text-end {
    text-align: right !important;
}

.text-primary {
    color: var(--primary) !important;
}
.text-secondary {
    color: var(--secondary) !important;
}
.text-success {
    color: var(--success) !important;
}
.text-danger {
    color: var(--danger) !important;
}
.text-warning {
    color: var(--warning) !important;
}
.text-info {
    color: var(--info) !important;
}
.text-muted {
    color: #6c757d !important;
}
.text-white {
    color: #fff !important;
}

.fw-normal {
    font-weight: 400 !important;
}
.fw-bold {
    font-weight: 700 !important;
}
.fw-bolder {
    font-weight: bolder !important;
}

.fs-1 {
    font-size: 2.5rem !important;
}
.fs-2 {
    font-size: 2rem !important;
}
.fs-3 {
    font-size: 1.75rem !important;
}
.fs-4 {
    font-size: 1.5rem !important;
}
.fs-5 {
    font-size: 1.25rem !important;
}
.fs-6 {
    font-size: 1rem !important;
}
.fs-sm {
    font-size: 0.875rem !important;
}

/* ============================================================
   8. WIDTH / HEIGHT
   ============================================================ */
.w-25 {
    width: 25% !important;
}
.w-50 {
    width: 50% !important;
}
.w-75 {
    width: 75% !important;
}
.w-100 {
    width: 100% !important;
}
.w-auto {
    width: auto !important;
}

.h-100 {
    height: 100% !important;
}
.h-auto {
    height: auto !important;
}

/* ============================================================
   9. BORDERS
   ============================================================ */
.border {
    border: 1px solid var(--border-color) !important;
}
.border-0 {
    border: 0 !important;
}
.border-top {
    border-top: 1px solid var(--border-color) !important;
}
.border-bottom {
    border-bottom: 1px solid var(--border-color) !important;
}

.rounded {
    border-radius: var(--border-radius) !important;
}
.rounded-sm {
    border-radius: var(--border-radius-sm) !important;
}
.rounded-lg {
    border-radius: var(--border-radius-lg) !important;
}
.rounded-circle {
    border-radius: 50% !important;
}
.rounded-0 {
    border-radius: 0 !important;
}

/* ============================================================
   10. BACKGROUNDS
   ============================================================ */
.bg-primary {
    background-color: var(--primary) !important;
}
.bg-secondary {
    background-color: var(--secondary) !important;
}
.bg-success {
    background-color: var(--success) !important;
}
.bg-danger {
    background-color: var(--danger) !important;
}
.bg-warning {
    background-color: var(--warning) !important;
}
.bg-info {
    background-color: var(--info) !important;
}
.bg-light {
    background-color: var(--light) !important;
}
.bg-dark {
    background-color: var(--dark) !important;
}
.bg-white {
    background-color: #fff !important;
}
.bg-transparent {
    background-color: transparent !important;
}

/* ============================================================
   11. CARD
   ============================================================ */
.card {
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    word-wrap: break-word;
    background-color: #fff;
    background-clip: border-box;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
}

.card-header {
    padding: 1rem 1.25rem;
    margin-bottom: 0;
    background-color: rgba(0, 0, 0, 0.03);
    border-bottom: 1px solid var(--border-color);
}

.card-header:first-child {
    border-radius: calc(var(--border-radius) - 1px)
        calc(var(--border-radius) - 1px) 0 0;
}

.card-body {
    flex: 1 1 auto;
    padding: 1.25rem;
}

.card-footer {
    padding: 1rem 1.25rem;
    background-color: rgba(0, 0, 0, 0.03);
    border-top: 1px solid var(--border-color);
}

.card-footer:last-child {
    border-radius: 0 0 calc(var(--border-radius) - 1px)
        calc(var(--border-radius) - 1px);
}

.card-title {
    margin-bottom: 0.75rem;
    font-size: 1.25rem;
    font-weight: 500;
}

.card-text {
    margin-bottom: 1rem;
    line-height: 1.6;
}

.card-img-top {
    width: 100%;
    border-top-left-radius: calc(var(--border-radius) - 1px);
    border-top-right-radius: calc(var(--border-radius) - 1px);
}

/* ============================================================
   12. BUTTONS
   ============================================================ */
.btn {
    display: inline-block;
    font-family: var(--font-family);
    font-weight: 400;
    line-height: 1.5;
    text-align: center;
    text-decoration: none;
    vertical-align: middle;
    cursor: pointer;
    user-select: none;
    border: 1px solid transparent;
    padding: 0.5rem 1rem;
    font-size: 1rem;
    border-radius: var(--border-radius);
    transition:
        color 0.15s ease-in-out,
        background-color 0.15s ease-in-out,
        border-color 0.15s ease-in-out,
        box-shadow 0.15s ease-in-out;
}

.btn:disabled,
.btn.disabled {
    opacity: 0.65;
    pointer-events: none;
}

/* Sizes */
.btn-sm {
    padding: 0.35rem 0.75rem;
    font-size: 0.875rem;
    border-radius: var(--border-radius-sm);
}
.btn-lg {
    padding: 0.75rem 1.5rem;
    font-size: 1.25rem;
    border-radius: var(--border-radius-lg);
}

/* Variants */
.btn-primary {
    color: #fff;
    background-color: var(--primary);
    border-color: var(--primary);
}
.btn-primary:hover {
    color: #fff;
    background-color: var(--primary-hover);
    border-color: var(--primary-hover);
}

.btn-secondary {
    color: #fff;
    background-color: var(--secondary);
    border-color: var(--secondary);
}
.btn-secondary:hover {
    color: #fff;
    background-color: var(--secondary-hover);
    border-color: var(--secondary-hover);
}

.btn-success {
    color: #fff;
    background-color: var(--success);
    border-color: var(--success);
}
.btn-success:hover {
    color: #fff;
    background-color: var(--success-hover);
    border-color: var(--success-hover);
}

.btn-danger {
    color: #fff;
    background-color: var(--danger);
    border-color: var(--danger);
}
.btn-danger:hover {
    color: #fff;
    background-color: var(--danger-hover);
    border-color: var(--danger-hover);
}

.btn-warning {
    color: #212529;
    background-color: var(--warning);
    border-color: var(--warning);
}
.btn-warning:hover {
    color: #212529;
    background-color: var(--warning-hover);
    border-color: var(--warning-hover);
}

.btn-info {
    color: #212529;
    background-color: var(--info);
    border-color: var(--info);
}
.btn-info:hover {
    color: #212529;
    background-color: var(--info-hover);
    border-color: var(--info-hover);
}

.btn-light {
    color: #212529;
    background-color: var(--light);
    border-color: var(--light);
}
.btn-light:hover {
    color: #212529;
    background-color: #e2e6ea;
    border-color: #dae0e5;
}

.btn-dark {
    color: #fff;
    background-color: var(--dark);
    border-color: var(--dark);
}
.btn-dark:hover {
    color: #fff;
    background-color: #1c1f23;
    border-color: #1a1e21;
}

/* Outline variants */
.btn-outline-primary {
    color: var(--primary);
    border-color: var(--primary);
    background-color: transparent;
}
.btn-outline-primary:hover {
    color: #fff;
    background-color: var(--primary);
}

.btn-outline-secondary {
    color: var(--secondary);
    border-color: var(--secondary);
    background-color: transparent;
}
.btn-outline-secondary:hover {
    color: #fff;
    background-color: var(--secondary);
}

.btn-outline-success {
    color: var(--success);
    border-color: var(--success);
    background-color: transparent;
}
.btn-outline-success:hover {
    color: #fff;
    background-color: var(--success);
}

.btn-outline-danger {
    color: var(--danger);
    border-color: var(--danger);
    background-color: transparent;
}
.btn-outline-danger:hover {
    color: #fff;
    background-color: var(--danger);
}

.btn-block {
    display: block;
    width: 100%;
}

/* ============================================================
   13. FORM INPUTS
   ============================================================ */
.form-label {
    display: inline-block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.form-control {
    display: block;
    width: 100%;
    padding: 0.5rem 0.75rem;
    font-size: 1rem;
    font-weight: 400;
    line-height: 1.5;
    color: var(--body-color);
    background-color: var(--body-bg);
    background-clip: padding-box;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    transition:
        border-color 0.15s ease-in-out,
        box-shadow 0.15s ease-in-out;
    appearance: none;
}

.form-control:focus {
    color: var(--body-color);
    background-color: var(--body-bg);
    border-color: var(--input-focus-border);
    outline: 0;
    box-shadow: var(--input-focus-shadow);
}

.form-control::placeholder {
    color: #6c757d;
    opacity: 1;
}

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

.form-control-sm {
    padding: 0.3rem 0.6rem;
    font-size: 0.875rem;
    border-radius: var(--border-radius-sm);
}

.form-control-lg {
    padding: 0.75rem 1rem;
    font-size: 1.25rem;
    border-radius: var(--border-radius-lg);
}

textarea.form-control {
    min-height: calc(1.5em + 1rem + 2px);
}

select.form-control {
    padding-right: 2.25rem;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23343a40' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 16px 12px;
}

/* Readonly */
.form-control[readonly] {
    background-color: #e9ecef;
    opacity: 1;
}

/* ============================================================
   14. FORM VALIDATION — is-valid / is-invalid + feedback
   ============================================================ */
.is-valid {
    border-color: var(--success) !important;
    padding-right: calc(1.5em + 0.75rem);
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3e%3cpath fill='%23198754' d='M2.3 6.73.6 4.53c-.4-1.04.46-1.4 1.1-.8l1.1 1.4 3.4-3.8c.6-.63 1.6-.27 1.2.7l-4 4.6c-.43.5-.8.4-1.1.1z'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right calc(0.375em + 0.1875rem) center;
    background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}

.is-valid:focus {
    border-color: var(--success);
    box-shadow: 0 0 0 0.25rem rgba(25, 135, 84, 0.25);
}

.is-invalid {
    border-color: var(--danger) !important;
    padding-right: calc(1.5em + 0.75rem);
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' width='12' height='12' fill='none' stroke='%23dc3545'%3e%3ccircle cx='6' cy='6' r='4.5'/%3e%3cpath stroke-linejoin='round' d='M5.8 3.6h.4L6 6.5z'/%3e%3ccircle cx='6' cy='8.2' r='.6' fill='%23dc3545' stroke='none'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right calc(0.375em + 0.1875rem) center;
    background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}

.is-invalid:focus {
    border-color: var(--danger);
    box-shadow: 0 0 0 0.25rem rgba(220, 53, 69, 0.25);
}

/* Feedback text */
.valid-feedback {
    display: none;
    width: 100%;
    margin-top: 0.25rem;
    font-size: 0.875rem;
    color: var(--success);
}

.invalid-feedback {
    display: none;
    width: 100%;
    margin-top: 0.25rem;
    font-size: 0.875rem;
    color: var(--danger);
}

.is-valid ~ .valid-feedback,
.was-validated .form-control:valid ~ .valid-feedback {
    display: block;
}

.is-invalid ~ .invalid-feedback,
.was-validated .form-control:invalid ~ .invalid-feedback {
    display: block;
}

/* ============================================================
   15. FORM CHECK (Radio / Checkbox)
   ============================================================ */
.form-check {
    display: block;
    min-height: 1.5rem;
    padding-left: 1.75em;
    margin-bottom: 0.125rem;
}

.form-check-input {
    width: 1em;
    height: 1em;
    margin-top: 0.25em;
    margin-left: -1.75em;
    vertical-align: top;
}

.form-check-label {
    margin-bottom: 0;
}

/* ============================================================
   16. ALERTS
   ============================================================ */
.alert {
    position: relative;
    padding: 1rem 1.25rem;
    margin-bottom: 1rem;
    border: 1px solid transparent;
    border-radius: var(--border-radius);
}

.alert-dismissible {
    padding-right: 3.5rem;
}

.alert-dismissible .btn-close {
    position: absolute;
    top: 0;
    right: 0;
    z-index: 2;
    padding: 1.25rem 1.25rem;
    background: transparent;
    border: 0;
    font-size: 1.25rem;
    cursor: pointer;
    color: inherit;
    opacity: 0.5;
}
.alert-dismissible .btn-close:hover {
    opacity: 0.75;
}

.alert-primary {
    color: #084298;
    background-color: #cfe2ff;
    border-color: #b6d4fe;
}

.alert-secondary {
    color: #41464b;
    background-color: #e2e3e5;
    border-color: #d3d6d8;
}

.alert-success {
    color: #0f5132;
    background-color: #d1e7dd;
    border-color: #badbcc;
}

.alert-danger {
    color: #842029;
    background-color: #f8d7da;
    border-color: #f5c2c7;
}

.alert-warning {
    color: #664d03;
    background-color: #fff3cd;
    border-color: #ffecb5;
}

.alert-info {
    color: #055160;
    background-color: #cff4fc;
    border-color: #b6effb;
}

.alert-light {
    color: #636464;
    background-color: #fefefe;
    border-color: #fdfdfe;
}

.alert-dark {
    color: #141619;
    background-color: #d3d3d4;
    border-color: #bcbebf;
}

/* ============================================================
   17. BADGES
   ============================================================ */
.badge {
    display: inline-block;
    padding: 0.35em 0.65em;
    font-size: 0.75em;
    font-weight: 700;
    line-height: 1;
    text-align: center;
    white-space: nowrap;
    vertical-align: baseline;
    border-radius: var(--border-radius);
}

.badge-primary {
    color: #fff;
    background-color: var(--primary);
}
.badge-secondary {
    color: #fff;
    background-color: var(--secondary);
}
.badge-success {
    color: #fff;
    background-color: var(--success);
}
.badge-danger {
    color: #fff;
    background-color: var(--danger);
}
.badge-warning {
    color: #212529;
    background-color: var(--warning);
}
.badge-info {
    color: #212529;
    background-color: var(--info);
}

/* ============================================================
   18. TABLES
   ============================================================ */
.table {
    width: 100%;
    margin-bottom: 1rem;
    color: var(--body-color);
    vertical-align: top;
    border-collapse: collapse;
}

.table th,
.table td {
    padding: 0.75rem;
    border-bottom: 1px solid var(--border-color);
    text-align: left;
}

.table thead th {
    border-bottom-width: 2px;
    font-weight: 700;
}

.table tbody tr:hover {
    background-color: rgba(0, 0, 0, 0.025);
}

.table-striped tbody tr:nth-of-type(odd) {
    background-color: rgba(0, 0, 0, 0.035);
}

.table-bordered {
    border: 1px solid var(--border-color);
}
.table-bordered th,
.table-bordered td {
    border: 1px solid var(--border-color);
}

/* ============================================================
   19. SPINNER
   ============================================================ */
.spinner-border {
    display: inline-block;
    width: 2rem;
    height: 2rem;
    vertical-align: -0.125em;
    border: 0.25em solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: spinner-border 0.75s linear infinite;
}

.spinner-border-sm {
    width: 1rem;
    height: 1rem;
    border-width: 0.2em;
}

@keyframes spinner-border {
    to {
        transform: rotate(360deg);
    }
}

/* ============================================================
   20. SHADOWS
   ============================================================ */
.shadow-none {
    box-shadow: none !important;
}
.shadow-sm {
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075) !important;
}
.shadow {
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15) !important;
}
.shadow-lg {
    box-shadow: 0 1rem 3rem rgba(0, 0, 0, 0.175) !important;
}

/* ============================================================
   21. VISIBILITY & OVERFLOW
   ============================================================ */
.visible {
    visibility: visible !important;
}
.invisible {
    visibility: hidden !important;
}

.overflow-auto {
    overflow: auto !important;
}
.overflow-hidden {
    overflow: hidden !important;
}

/* ============================================================
   22. POSITION
   ============================================================ */
.position-relative {
    position: relative !important;
}
.position-absolute {
    position: absolute !important;
}
.position-fixed {
    position: fixed !important;
}
.position-sticky {
    position: sticky !important;
}

.top-0 {
    top: 0 !important;
}
.bottom-0 {
    bottom: 0 !important;
}
.start-0 {
    left: 0 !important;
}
.end-0 {
    right: 0 !important;
}

/* ============================================================
   23. IMAGE
   ============================================================ */
.img-fluid {
    max-width: 100%;
    height: auto;
}
.img-thumbnail {
    padding: 0.25rem;
    background-color: #fff;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    max-width: 100%;
    height: auto;
}

/* ============================================================
   24. UTILITY — object-fit, user-select, etc.
   ============================================================ */
.object-fit-cover {
    object-fit: cover !important;
}
.object-fit-contain {
    object-fit: contain !important;
}

.user-select-none {
    user-select: none !important;
}
.user-select-all {
    user-select: all !important;
}

.cursor-pointer {
    cursor: pointer !important;
}

/* ============================================================
   25. RESPONSIVE DISPLAY HELPERS
   ============================================================ */
@media (min-width: 576px) {
    .d-sm-none {
        display: none !important;
    }
    .d-sm-block {
        display: block !important;
    }
    .d-sm-flex {
        display: flex !important;
    }
}
@media (min-width: 768px) {
    .d-md-none {
        display: none !important;
    }
    .d-md-block {
        display: block !important;
    }
    .d-md-flex {
        display: flex !important;
    }
}
@media (min-width: 992px) {
    .d-lg-none {
        display: none !important;
    }
    .d-lg-block {
        display: block !important;
    }
    .d-lg-flex {
        display: flex !important;
    }
}
@media (min-width: 1200px) {
    .d-xl-none {
        display: none !important;
    }
    .d-xl-block {
        display: block !important;
    }
    .d-xl-flex {
        display: flex !important;
    }
}

/* ============================================================
   26. AUTH PAGES — Login, Register, Forgot/Reset Password
   ============================================================ */
.auth-page {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px 60px;
}

.auth-hero {
    text-align: center;
    margin-bottom: 40px;
    padding: 60px 20px 50px;
    background: linear-gradient(135deg, #f0f7ff 0%, #dce8f8 100%);
    border-radius: 24px;
    position: relative;
    overflow: hidden;
}

.auth-hero h1 {
    font-size: 2.6rem;
    font-weight: 800;
    color: #1a2a4a;
    margin-bottom: 12px;
    letter-spacing: -0.02em;
}

.auth-hero h1 span {
    background: linear-gradient(135deg, #0080ff 0%, #0044aa 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.auth-hero p {
    font-size: 1.1rem;
    color: #4a5a6f;
    max-width: 550px;
    margin: 0 auto;
    line-height: 1.6;
}

.auth-card {
    max-width: 480px;
    margin: 0 auto;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    border: 1px solid #eef2f6;
}

.auth-card-header {
    background: linear-gradient(135deg, #0080ff 0%, #0044aa 100%);
    padding: 28px 30px;
    text-align: center;
}

.auth-card-header .auth-icon {
    width: 56px;
    height: 56px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: #fff;
    margin-bottom: 14px;
}

.auth-card-header h3 {
    color: #fff;
    font-size: 1.35rem;
    font-weight: 700;
    margin: 0 0 4px;
}

.auth-card-header p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
    margin: 0;
}

.auth-card-body {
    padding: 32px 30px;
}

.auth-form .form-group {
    margin-bottom: 20px;
}

.auth-form .form-label {
    display: block;
    font-weight: 600;
    color: #1a2a4a;
    margin-bottom: 6px;
    font-size: 0.9rem;
}

.auth-form .form-control {
    width: 100%;
    padding: 12px 16px;
    font-size: 0.95rem;
    border: 1.5px solid #dee2e6;
    border-radius: 10px;
    transition:
        border-color 0.2s,
        box-shadow 0.2s;
    background: #f9fafb;
}

.auth-form .form-control:focus {
    outline: none;
    border-color: #0080ff;
    box-shadow: 0 0 0 3px rgba(0, 128, 255, 0.1);
    background: #fff;
}

.auth-form .form-control.is-invalid {
    border-color: #dc3545;
}

.auth-form .invalid-feedback {
    color: #dc3545;
    font-size: 0.82rem;
    margin-top: 4px;
    display: block;
}

/* Login-specific: remember-me row */
.auth-form .form-check {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    color: #4a5a6f;
}

.auth-form .form-check-input {
    width: 18px;
    height: 18px;
    accent-color: #0080ff;
    cursor: pointer;
}

.auth-form .form-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.auth-form .forgot-link {
    color: #0080ff;
    font-size: 0.88rem;
    font-weight: 500;
    text-decoration: none;
}

.auth-form .forgot-link:hover {
    text-decoration: underline;
}

/* Status alert (forgot password success) */
.auth-alert {
    padding: 14px 18px;
    border-radius: 10px;
    font-size: 0.9rem;
    margin-bottom: 20px;
    background: #d1fae5;
    color: #065f46;
    border: 1px solid #a7f3d0;
}

.auth-btn {
    width: 100%;
    padding: 13px;
    font-size: 1rem;
    font-weight: 600;
    color: #fff;
    background: linear-gradient(135deg, #0080ff 0%, #0044aa 100%);
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition:
        transform 0.2s,
        box-shadow 0.2s;
}

.auth-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 24px rgba(0, 128, 255, 0.3);
}

.auth-footer {
    text-align: center;
    padding: 0 30px 28px;
    color: #6b6b80;
    font-size: 0.92rem;
}

.auth-footer a {
    color: #0080ff;
    font-weight: 600;
    text-decoration: none;
}

.auth-footer a:hover {
    text-decoration: underline;
}

@media (max-width: 576px) {
    .auth-hero {
        padding: 40px 16px 30px;
    }

    .auth-hero h1 {
        font-size: 2rem;
    }

    .auth-card-body {
        padding: 24px 18px;
    }
}

/* ── Plan Summary Card (onboarding sidebar) ── */
.plan-summary-card {
    background: #f8f9fc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 24px;
    height: 100%;
}

.plan-summary-title {
    font-size: 1.15rem;
    font-weight: 700;
    color: #1a1a2e;
    margin-bottom: 8px;
}

.plan-summary-price {
    font-size: 2rem;
    font-weight: 800;
    color: #0080ff;
    margin-bottom: 2px;
}

.plan-summary-duration {
    font-size: 0.85rem;
    color: #6b6b80;
    margin-bottom: 4px;
}

.plan-summary-card hr {
    border-color: #e2e8f0;
    margin: 14px 0;
}

.plan-summary-detail {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 0;
    font-size: 0.9rem;
    color: #4a4a60;
}

.plan-summary-detail strong {
    color: #1a1a2e;
}

/* ── Step Indicator (onboarding progress) ── */
.step-dot {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    font-size: 0.75rem;
    font-weight: 700;
    background: #e2e8f0;
    color: #6b6b80;
    transition: all 0.3s ease;
}

.step-dot.active {
    background: linear-gradient(135deg, #0080ff 0%, #0044aa 100%);
    color: #fff;
    box-shadow: 0 2px 8px rgba(0, 128, 255, 0.3);
}

.step-dot.done {
    background: #10b981;
    color: #fff;
}

.step-line {
    display: inline-block;
    width: 40px;
    height: 2px;
    background: #e2e8f0;
    flex-shrink: 0;
}
