/*
 * Ifatis — Layout (self-owned grid + utilities, replaces bootstrap.full.min.css)
 * Loaded on every page, first. Faithfully reimplements ONLY the Bootstrap 4
 * grid + the utility classes the theme actually uses, at the same breakpoints
 * (sm 576 / md 768 / lg 992 / xl 1200) and same behaviour — so nothing shifts —
 * plus a compact reboot to replace the parts of Bootstrap Reboot the theme relies on.
 * Gutters are driven by a single token (--grid-gutter) for consistency.
 */

:root { --grid-gutter: 15px; }

/* ============================================================
   Mini reboot (only what the theme depended on from Bootstrap)
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; }
img, svg { vertical-align: middle; }
h1, h2, h3, h4, h5, h6 { margin-top: 0; margin-bottom: 0.5rem; }
p { margin-top: 0; margin-bottom: 1rem; }
ul, ol, dl { margin-top: 0; margin-bottom: 1rem; }
figure { margin: 0 0 1rem; }
button { margin: 0; }
[hidden] { display: none !important; }

/* ============================================================
   Containers
   ============================================================ */
.container, .container-fluid {
    width: 100%;
    margin-inline: auto;
    padding-inline: var(--grid-gutter);
}
@media (min-width: 576px)  { .container { max-width: 540px; } }
@media (min-width: 768px)  { .container { max-width: 720px; } }
@media (min-width: 992px)  { .container { max-width: 960px; } }
@media (min-width: 1200px) { .container { max-width: 1140px; } }

/* ============================================================
   Grid — flex row + columns (Bootstrap-4-faithful)
   ============================================================ */
.row {
    display: flex;
    flex-wrap: wrap;
    margin-inline: calc(-1 * var(--grid-gutter));
}
.col, .col-auto,
[class*="col-"] {
    position: relative;
    width: 100%;
    min-height: 1px;
    padding-inline: var(--grid-gutter);
}
.col { flex: 1 0 0%; max-width: 100%; }
.col-auto { flex: 0 0 auto; width: auto; max-width: 100%; }

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

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

/* ============================================================
   Display utilities (base + responsive; !important like Bootstrap,
   ordered ascending so responsive overrides base)
   ============================================================ */
.d-none         { display: none !important; }
.d-inline       { display: inline !important; }
.d-inline-block { display: inline-block !important; }
.d-block        { display: block !important; }
.d-flex         { display: flex !important; }
.d-inline-flex  { display: inline-flex !important; }
@media (min-width: 576px)  { .d-sm-none{display:none!important} .d-sm-inline-block{display:inline-block!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-inline-block{display:inline-block!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-inline-block{display:inline-block!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-inline-block{display:inline-block!important} .d-xl-block{display:block!important} .d-xl-flex{display:flex!important} }

/* ============================================================
   Flex utilities
   ============================================================ */
.flex-row     { flex-direction: row !important; }
.flex-column  { flex-direction: column !important; }
.flex-wrap    { flex-wrap: wrap !important; }
.justify-content-start   { justify-content: flex-start !important; }
.justify-content-center  { justify-content: center !important; }
.justify-content-end     { justify-content: flex-end !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-center  { align-items: center !important; }
.align-items-end     { align-items: flex-end !important; }

/* ============================================================
   Sizing + spacing utilities (Bootstrap-4 scale; !important)
   ============================================================ */
.w-100 { width: 100% !important; }
.h-100 { height: 100% !important; }

.m-0  { margin: 0 !important; }
.mt-1 { margin-top: 0.25rem !important; }
.mt-2 { margin-top: 0.5rem  !important; }
.mt-3 { margin-top: 1rem    !important; }
.mb-3 { margin-bottom: 1rem !important; }
.mb-5 { margin-bottom: 3rem !important; }
.mx-1 { margin-left: 0.25rem !important; margin-right: 0.25rem !important; }
.my-1 { margin-top: 0.25rem !important; margin-bottom: 0.25rem !important; }
.my-3 { margin-top: 1rem !important; margin-bottom: 1rem !important; }
.mx-auto { margin-left: auto !important; margin-right: auto !important; }

.p-0  { padding: 0 !important; }
.px-0 { padding-left: 0 !important; padding-right: 0 !important; }
.px-4 { padding-left: 1.5rem !important; padding-right: 1.5rem !important; }
.py-3 { padding-top: 1rem !important; padding-bottom: 1rem !important; }
.pt-3 { padding-top: 1rem !important; }
.pt-5 { padding-top: 3rem !important; }
.pb-3 { padding-bottom: 1rem !important; }
.pb-5 { padding-bottom: 3rem !important; }

/* responsive spacing actually used */
@media (min-width: 768px) { .mb-md-0 { margin-bottom: 0 !important; } .mb-md-5 { margin-bottom: 3rem !important; } }
@media (min-width: 992px) { .mt-lg-3 { margin-top: 1rem !important; } }

/* ============================================================
   Text alignment
   ============================================================ */
.text-left   { text-align: left !important; }
.text-right  { text-align: right !important; }
.text-center { text-align: center !important; }

/* ============================================================
   .btn base (theme uses `.btn.btn-ifatis`; .btn-ifatis fully styled in base.css)
   ============================================================ */
.btn {
    display: inline-block;
    font-weight: 400;
    text-align: center;
    vertical-align: middle;
    user-select: none;
    border: 1px solid transparent;
    padding: 0.375rem 0.75rem;
    line-height: 1.5;
    border-radius: 0.25rem;
    background: transparent;
    cursor: pointer;
}
.btn:focus, .btn:hover { text-decoration: none; }
