/* =============================================================================
   PRESET «skymall» — Skymall (site 800). Loaded after `style.css` (§13 = shared token mapping).
   Brand = the old «shop» theme (Stroyka) taken further: Rubik · logo red #e51b23 (buttons, prices, accents) ·
   black top bar, category button and footer · the home on a light grey page (#f2f3f7) with white panels.
   ⚠️ Bootstrap redefines colour tokens on every `[data-bs-theme]` ⇒ set them on both `.preset-skymall` and its descendants.
   ============================================================================= */

.preset-skymall {
    --bs-body-font-family: 'Rubik', system-ui, -apple-system, 'Segoe UI', sans-serif;
    --sky-page: #f2f3f7;
    /* Skymall brand tokens — the brand's own colours live here as --sky-*; new brand touches use these, not Bootstrap's --bs-* */
    --sky-primary: #e51b23;
    --sky-primary-deep: #b3141b;
    --sky-ink: #141519;
    --sky-shadow: 0 .75rem 1.75rem rgba(20, 21, 25, .08);
}

/* One corner scale for the whole site: controls (buttons · fields · arrows) .5rem, surfaces (banner · panels · cards ·
   tiles · menus) 1rem — Bootstrap's own variables, so the `rounded-*` utilities in the markup follow too.
   The header and footer re-declare them in their own `data-bs-theme` scope ⇒ set there as well. */
.preset-skymall,
.preset-skymall [data-bs-theme] {
    --sky-radius: 1rem;
    --bs-border-radius: .5rem;
    --bs-border-radius-sm: .5rem;
    --bs-border-radius-lg: var(--sky-radius);
    --bs-border-radius-xl: var(--sky-radius);
    --bs-border-radius-xxl: var(--sky-radius);
    --bs-border-radius-2xl: var(--sky-radius);
}

/* Controls re-declare the corner and border on themselves (extra form-button.css: .75rem · 2px) ⇒ pinned here */
.preset-skymall .btn,
.preset-skymall .form-control,
.preset-skymall .form-select,
.preset-skymall .input-group-text,
.preset-skymall .form-option {
    --bs-border-radius-sm: .5rem;
    --bs-border-radius: .5rem;
    --bs-border-radius-lg: .5rem;
    --bs-btn-border-radius: .5rem;
    --bs-border-width: 1px;   /* extra: 2px — every button and field on a hairline */
    --bs-btn-border-width: 1px;
}


/* §1 Colour */
.preset-skymall,
.preset-skymall [data-bs-theme="light"] {
    --bs-primary: #e51b23;
    --bs-primary-rgb: 229, 27, 35;
    --bs-primary-bg-subtle: #fde8e9;
    --bs-primary-border-subtle: #f7b9bc;
    --bs-primary-text-emphasis: #b3141b;
    --bs-danger: #e51b23;
    --bs-danger-rgb: 229, 27, 35;
    --bs-link-color: #e51b23;
    --bs-link-color-rgb: 229, 27, 35;
    --bs-link-hover-color: #b3141b;
    --bs-link-hover-color-rgb: 179, 20, 27;
    --bs-body-color: #26282d;
    --bs-body-color-rgb: 38, 40, 45;
    --bs-secondary-color: #6b6f76;
    --bs-tertiary-bg: #f2f3f7;
    --bs-tertiary-bg-rgb: 242, 243, 247;
    --bs-border-color: #e6e8ee;
}

.preset-skymall [data-bs-theme="dark"] {
    --bs-primary: #ff4d54;
    --bs-primary-rgb: 255, 77, 84;
    --bs-link-color: #ffffff;
    --bs-link-color-rgb: 255, 255, 255;
}

/* Red buttons with white text; hover a shade deeper */
.preset-skymall .btn-primary {
    --bs-btn-color: #ffffff;
    --bs-btn-bg: #e51b23;
    --bs-btn-border-color: #e51b23;
    --bs-btn-hover-color: #ffffff;
    --bs-btn-hover-bg: #c8161d;
    --bs-btn-hover-border-color: #c8161d;
    --bs-btn-active-color: #ffffff;
    --bs-btn-active-bg: #b3141b;
    --bs-btn-active-border-color: #b3141b;
}


/* §2 Section titles — semibold with a short red bar in front, one size for every row of the home (the product rows carry `fs-5`,
   the card blocks a plain h2) */
.preset-skymall main section .heading-row > .heading-main > h2 {
    display: flex;
    align-items: center;
    gap: .625rem;
    font-weight: 600;
}

.preset-skymall.page-home #main section .heading-row > .heading-main > h2 {
    font-size: 1.125rem !important;
    line-height: 1.3;
}

@media (min-width: 768px) {
    .preset-skymall.page-home #main section .heading-row > .heading-main > h2 {
        font-size: 1.375rem !important;
    }
}

.preset-skymall.page-home #main .heading-row.heading-centered {
    align-items: flex-start !important;
    margin-left: 0 !important;
    text-align: left;
}

.preset-skymall.page-home #main .heading-row.heading-centered .heading-main {
    align-items: flex-start !important;
}

.preset-skymall main section .heading-row > .heading-main > h2::before {
    content: "";
    flex-shrink: 0;
    width: .3125rem;
    height: 1.1em;
    background-color: var(--sky-primary);
    border-radius: 50rem;
}



/* §3 Product cards — white tile with a hairline, lifts with a soft shadow on hover; price in black (on sale: green); «Сагсанд» a tinted button
   that fills red. `#main` outranks the product rows' own block CSS (an id selector). */
.preset-skymall #main .product-item {
    height: 100%;
    background-color: #ffffff;
    border: var(--bs-border-width) solid var(--bs-border-color);
    border-radius: var(--sky-radius);
    overflow: hidden;
    transition: box-shadow .35s ease, transform .35s ease, border-color .35s ease;
}

.preset-skymall #main .product-item:hover {
    border-color: transparent;
    box-shadow: var(--sky-shadow);
    transform: translateY(-.25rem);
}

.preset-skymall #main .product-item .item-image {
    background-color: #f7f8fa;
    border: 0 !important;
    border-radius: 0 !important;
}

.preset-skymall #main .product-item .item-details {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    gap: .375rem;
    padding: .875rem .875rem 1rem !important;
}

.preset-skymall #main .product-item .item-title {
    font-size: .875rem;
    line-height: 1.35;
}

.preset-skymall .item-price .h4 {
    color: var(--sky-ink) !important;
    font-size: 1.0625rem;
    font-weight: 700;
}

/* A discounted price (an old price beside it) in green, as on the product page (`text-success`) */
.preset-skymall .item-price:has(.item-price-old:not(.d-none)) .h4 {
    color: var(--bs-success) !important;
}

.preset-skymall #main .product-item .item-price {
    margin-top: auto;
}

/* The shared `.btn-primary` pins its fills with !important (form-button.css) ⇒ the tint needs !important too */
.preset-skymall .product-item .item-action .btn:not(:where(.product-qty .btn)) {
    width: 100%;
    --bs-btn-color: var(--sky-primary);
    --bs-btn-bg: var(--bs-primary-bg-subtle) !important;
    --bs-btn-border-color: transparent !important;
    --bs-btn-hover-color: #ffffff;
    --bs-btn-hover-bg: var(--sky-primary) !important;
    --bs-btn-hover-border-color: var(--sky-primary) !important;
    --bs-btn-active-color: #ffffff;
    --bs-btn-active-bg: var(--sky-primary-deep) !important;
    --bs-btn-active-border-color: var(--sky-primary-deep) !important;
}

/* Footer: every text but the titles at .875rem — the columns (titles, icons and buttons carry their own size) and the copyright line
   (its neighbour is already `.small`) */
.preset-skymall .footer-market .footer-middle,
.preset-skymall .footer-market .footer-deep > p:not(.small) {
    font-size: .875rem;
}

/* A card never grows past its slide or grid cell: the one-line category label (`text-truncate`) would otherwise set its minimum width */
.preset-skymall .col-item {
    min-width: 0;
}

/* The product list's price range in the brand red (the list paints it with Bootstrap's blue) */
.preset-skymall .products-page .range-dual {
    --bs-blue: var(--sky-primary);
}

/* Corner labels: the sale percentage in brand red, «Шинэ» in black (two different colours side by side) */
.preset-skymall .item-badge-sale {
    background-color: var(--sky-primary) !important;
    color: #ffffff !important;
}

.preset-skymall .item-badge-new {
    background-color: var(--sky-ink) !important;
    color: #ffffff !important;
}

/* Product rows: room for the hover shadow inside the carousel's clipping box */
.preset-skymall #main [data-type="last_products"] .swiper-main {
    padding: .375rem .375rem 1.25rem;
    margin: -.375rem -.375rem -1.25rem;
    width: calc(100% + .75rem) !important;
}


/* §4 Carousel arrows — white rounded squares with a red chevron, red when hovered; dots = small grey, the current one a red pill */
.preset-skymall .swiper-button {
    width: 2.75rem;
    height: 2.75rem;
    border: 0;
    border-radius: var(--bs-border-radius);
    background-color: #ffffff;
    color: var(--sky-primary);
    box-shadow: 0 .375rem 1rem rgba(20, 21, 25, .14);
}

.preset-skymall .swiper-button::before {
    width: .875rem;
    height: .875rem;
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' fill='none' stroke='%23000' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 1.5l4.5 4.5L4 10.5'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' fill='none' stroke='%23000' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 1.5l4.5 4.5L4 10.5'/%3E%3C/svg%3E");
}

.preset-skymall .swiper-button:hover {
    border-color: var(--sky-primary);
    background-color: var(--sky-primary);
    color: #ffffff;
}

.preset-skymall .swiper-button.swiper-next:hover::before {
    transform: translateX(.125rem);
}

.preset-skymall .swiper-button.swiper-prev:hover::before {
    transform: scaleX(-1) translateX(.125rem);
}

.preset-skymall .swiper-pagination-bullet {
    width: .5rem;
    height: .5rem;
    background: rgba(255, 255, 255, .75);
    box-shadow: 0 0 0 1px rgba(20, 21, 25, .08);
}

.preset-skymall .swiper-pagination-bullet-active {
    width: 1.5rem;
    background: var(--sky-primary);
    box-shadow: none;
}


/* §5 Header — the nav row = «Бүх ангилал» button + info pages (red on hover) */
.preset-skymall .header-market nav.navbar .nav-link {
    padding-inline: .625rem !important;
    font-size: .8125rem;
    font-weight: 500 !important;
    line-height: 1.25;
}

.preset-skymall .header-market nav.navbar .nav-link:hover,
.preset-skymall .header-market nav.navbar .nav-link.show {
    color: var(--sky-primary) !important;
}

/* «Бүх ангилал» at the start of the nav row = a plain `btn btn-primary`: the nav-link sizes and the red hover text step aside */
.preset-skymall .header-market nav.navbar .dropdown-categories {
    margin-block: .5rem;
    margin-right: 1rem;
}

.preset-skymall .header-market nav.navbar .dropdown-categories > .nav-link.btn {
    padding: var(--bs-btn-padding-y) var(--bs-btn-padding-x) !important;
    font-size: var(--bs-btn-font-size);
    font-weight: var(--bs-btn-font-weight) !important;
    line-height: var(--bs-btn-line-height);
    color: var(--bs-btn-color) !important;
    background-color: var(--bs-btn-bg) !important;
    border: var(--bs-btn-border-width) solid var(--bs-btn-border-color) !important;
    border-radius: var(--bs-btn-border-radius) !important;
}

.preset-skymall .header-market nav.navbar .dropdown-categories > .nav-link.btn:hover,
.preset-skymall .header-market nav.navbar .dropdown-categories > .nav-link.btn.show {
    color: var(--bs-btn-hover-color) !important;
    background-color: var(--bs-btn-hover-bg) !important;
    border-color: var(--bs-btn-hover-border-color) !important;
}

/* The nav row reads as a category bar, on one line: the two quick links, a hairline, then the main categories spread over the rest
   (preset `nav_limit` keeps them to what fits from xl) */
.preset-skymall .header-market nav.navbar.d-xl-block .nav-link {
    padding-inline: .5rem !important;
}

.preset-skymall .header-market nav.navbar.d-xl-block .navbar-nav.me-auto {
    position: relative;
    padding-right: 1rem;
}

.preset-skymall .header-market nav.navbar.d-xl-block .navbar-nav.me-auto::after {
    content: "";
    position: absolute;
    top: 50%;
    right: 0;
    height: 1.25rem;
    border-right: var(--bs-border-width) solid var(--bs-border-color);
    transform: translateY(-50%);
}

/* The info links packed to the right, «Бүх ангилал» alone on the left */
.preset-skymall .header-market nav.navbar.d-xl-block .navbar-nav:not(.me-auto) {
    margin-left: auto;
    gap: .5rem;
}

/* Top bar — the info pages on one line. The phone is already in the header («Тусламж»); the e-mail and the socials step out
   where the six links need the room (xl: e-mail · lg: the whole right side) */
.preset-skymall .header-market .header-topbar .topbar {
    font-size: .75rem;
    white-space: nowrap;
}

.preset-skymall .header-market .header-topbar .container > .d-flex > div:first-child {
    gap: .875rem !important;
}

.preset-skymall .header-market .header-topbar .top-link[href^="tel:"] {
    display: none !important;
}

@media (max-width: 1199.98px) {
    .preset-skymall .header-market .header-topbar .container > .d-flex > div:last-child {
        display: none !important;
    }
}

@media (min-width: 1200px) {
    .preset-skymall .header-market .header-topbar .container > .d-flex > div:first-child {
        gap: 1.25rem !important;
    }
}

@media (max-width: 1399.98px) {
    .preset-skymall .header-market .header-topbar .container > .d-flex > div:last-child > div:first-child,
    .preset-skymall .header-market .header-topbar .container > .d-flex > div:last-child > .vr {
        display: none !important;
    }
}


/* §6 Home — light grey page; the banner boxed with round corners; service notes in one white strip under it;
   category icons on white tiles; product rows in white panels; one red «deal» panel (`style=deal`).
   `#main` outranks style.css §9 (it zeroes the top padding of a plain section that follows another) */
.preset-skymall.page-home main {
    background-color: var(--sky-page);
}

.preset-skymall.page-home #main > section.bg-body {
    background-color: transparent !important;
}

/* Banner */
.preset-skymall.page-home #main > section[data-type="slider"][data-v="1"] {
    padding-top: 1rem;
}

.preset-skymall.page-home #main > section[data-type="slider"][data-v="1"] .swiper-main {
    width: min(100% - 1.5rem, 1296px) !important;
    margin-inline: auto;
    border-radius: var(--sky-radius);
}

@media (min-width: 768px) {
    .preset-skymall.page-home #main > section[data-type="slider"][data-v="1"] {
        padding-top: 1.5rem;
    }

    .preset-skymall.page-home #main > section[data-type="slider"][data-v="1"] .swiper-main {
        border-radius: var(--sky-radius);
    }
}

.preset-skymall [data-type="slider"][data-v="1"] .swiper-slide img {
    aspect-ratio: 16 / 5;
    object-fit: cover;
}

/* Product rows in white panels */
.preset-skymall.page-home #main > section[data-type="last_products"] {
    padding-block: .75rem;
}

.preset-skymall.page-home #main > section[data-type="last_products"] > .container {
    padding: 1.25rem 1rem !important;
    background-color: #ffffff;
    border-radius: var(--sky-radius);
}

@media (max-width: 575.98px) {
    .preset-skymall.page-home #main > section[data-type="last_products"] > .container {
        width: calc(100% - 1.5rem);
    }
}

@media (min-width: 992px) {
    .preset-skymall.page-home #main > section[data-type="last_products"] > .container {
        padding: 1.75rem 2rem !important;
        border-radius: var(--sky-radius);
    }
}

/* The «deal» panel — brand red, white title and link, white cards */
.preset-skymall.page-home #main > section.lp-deal > .container {
    background: linear-gradient(120deg, var(--sky-primary) 0%, var(--sky-primary-deep) 100%);
}

.preset-skymall #main section.lp-deal .heading-row h2,
.preset-skymall #main section.lp-deal .heading-desc {
    color: #ffffff !important;
}

.preset-skymall #main section.lp-deal .heading-row > .heading-main > h2::before {
    background-color: #ffffff;
}

/* «Бүгдийг үзэх» on the red panel = a white button with red lettering (the shared .btn-primary pins its fills with !important) */
.preset-skymall #main section.lp-deal .block-action .btn {
    --bs-btn-color: var(--sky-primary);
    --bs-btn-bg: #ffffff !important;
    --bs-btn-border-color: #ffffff !important;
    --bs-btn-hover-color: var(--sky-primary);
    --bs-btn-hover-bg: rgba(255, 255, 255, .88) !important;
    --bs-btn-hover-border-color: transparent !important;
    --bs-btn-active-color: var(--sky-primary);
    --bs-btn-active-bg: rgba(255, 255, 255, .8) !important;
    --bs-btn-active-border-color: transparent !important;
}

.preset-skymall #main section.lp-deal .product-item {
    border-color: transparent;
}

/* The two card blocks sit on the grey page between panels: the same 1.5rem rhythm as the panels, a little more air above the title.
   `#main` + !important outrank the zeroed top padding of a plain section that follows another (style.css §9) */
.preset-skymall.page-home #main > section[data-type="card"] > .container {
    padding-top: 1.75rem !important;
    padding-bottom: .75rem !important;
}

.preset-skymall.page-home #main > section[data-type="card"]:last-of-type > .container {
    padding-bottom: 3rem !important;
}

@media (min-width: 992px) {
    .preset-skymall.page-home #main > section[data-type="card"] > .container {
        padding-top: 2.25rem !important;
    }

    .preset-skymall.page-home #main > section[data-type="card"]:last-of-type > .container {
        padding-bottom: 4rem !important;
    }
}

/* Category icons — white tiles, 3 a row on phones, 5 on tablets, 7 from lg (14 = two rows); red title and lift on hover */
.preset-skymall [data-type="card"][data-v="3"] .items-wrapper {
    --bs-gutter-x: .75rem;
    --bs-gutter-y: .75rem;
}

.preset-skymall [data-type="card"][data-v="3"] .items-wrapper > .col-item {
    flex: 0 0 auto;
    width: calc(100% / 3);
}

@media (min-width: 768px) {
    .preset-skymall [data-type="card"][data-v="3"] .items-wrapper > .col-item {
        width: 20%;
    }
}

@media (min-width: 992px) {
    .preset-skymall [data-type="card"][data-v="3"] .items-wrapper {
        --bs-gutter-x: 1rem;
        --bs-gutter-y: 1rem;
    }

    .preset-skymall [data-type="card"][data-v="3"] .items-wrapper > .col-item {
        width: calc(100% / 7);
    }
}

.preset-skymall.page-home [data-type="card"][data-v="3"] .feature-item {
    height: 100%;
    padding: 1rem .5rem;
    background-color: #ffffff;
    border-radius: var(--sky-radius);
    transition: box-shadow .35s ease, transform .35s ease;
}

.preset-skymall.page-home [data-type="card"][data-v="3"] .feature-item:hover {
    box-shadow: var(--sky-shadow);
    transform: translateY(-.25rem);
}

.preset-skymall [data-type="card"][data-v="3"] .item-title {
    font-size: .8125rem;
    font-weight: 500;
    line-height: 1.3;
    transition: color .3s ease;
}

.preset-skymall [data-type="card"][data-v="3"] .feature-item:hover .item-title {
    color: var(--sky-primary);
}

/* Service notes (rich text in old two-column rows) — one white strip: 4 in a row from md (icon beside the text),
   2 × 2 on phones (icon above). Both row levels become grids, so the old col-* widths no longer apply */
.preset-skymall .typography .row:has(> [class*="col-"] > .two-col) {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    margin: 0;
    padding: 1.25rem 1rem;
    background-color: #ffffff;
    border-radius: var(--sky-radius);
}

.preset-skymall .typography .two-col {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
    margin: 0;
}

.preset-skymall .typography .row:has(> [class*="col-"] > .two-col) > [class*="col-"],
.preset-skymall .typography .two-col > [class*="col-"] {
    width: auto;
    max-width: none;
    margin: 0;
    padding: 0;
}

.preset-skymall .typography .two-col img {
    display: block;
    width: 3rem;
    height: auto;
    margin: 0 auto .5rem;
}

.preset-skymall .typography .two-col p {
    margin-bottom: 0;
    font-size: .8125rem;
    font-weight: 500;
    line-height: 1.4;
    text-align: center !important;
}

@media (min-width: 768px) {
    .preset-skymall .typography .row:has(> [class*="col-"] > .two-col) {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        padding: 1.25rem 1.75rem;
    }

    .preset-skymall .typography .two-col > [class*="col-"] {
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: .875rem;
    }

    .preset-skymall .typography .two-col > [class*="col-"] > p:first-child {
        flex-shrink: 0;
    }

    .preset-skymall .typography .two-col img {
        width: 2.75rem;
        margin: 0;
    }

    .preset-skymall .typography .two-col p {
        text-align: left !important;
    }
}

.preset-skymall.page-home #main > section[data-type="html"] > .container {
    padding-block: .75rem !important;
}

/* «Хэрэглэгчийн булан» — white cards, the caption in small capitals */
.preset-skymall.page-home [data-type="card"][data-v="4"] .card-item {
    height: 100%;
    background-color: #ffffff;
    border-radius: var(--sky-radius);
    overflow: hidden;
    transition: box-shadow .35s ease, transform .35s ease;
}

.preset-skymall.page-home [data-type="card"][data-v="4"] .card-item:hover {
    box-shadow: var(--sky-shadow);
    transform: translateY(-.25rem);
}

.preset-skymall.page-home [data-type="card"][data-v="4"] .item-image {
    border-radius: 0 !important;
}

.preset-skymall.page-home [data-type="card"][data-v="4"] .item-details {
    padding: 1rem;
    text-align: center;
}

.preset-skymall.page-home [data-type="card"][data-v="4"] .item-title {
    font-size: .875rem;
    font-weight: 600;
    letter-spacing: .02em;
    text-transform: uppercase;
}


/* §7 Footer — black (the logo's red and black; the logo itself in its white-lettered version, preset `logo_dark`),
   small spaced capitals for the column titles (one of them is an all-caps page title), grey links that turn white */
.preset-skymall .footer-market.bg-black {
    background-color: var(--sky-ink) !important;
}

.preset-skymall .footer-market .widget-title {
    font-size: .8125rem !important;
    letter-spacing: .08em;
    text-transform: uppercase;
}

/* Rubik's medium reads bold on black — links, address and the copyright line in the regular weight */
.preset-skymall .footer-market .fw-medium,
.preset-skymall .footer-market .fw-semibold {
    font-weight: 400 !important;
}

.preset-skymall .footer-market .footer-link:hover {
    color: #ffffff !important;
}


/* Search — the field and its button on the control corner (the markup's `rounded-pill` / `btn-circle`) */
.preset-skymall .header-market .market-search .form-control {
    border-radius: var(--bs-border-radius) !important;
}

.preset-skymall .header-market .market-search .btn {
    border-radius: .375rem !important;
}


/* Sidebar lists and the contact details at .875rem — the product list's «Ангилал», the info pages' link widget, the contact column */
.preset-skymall .widget-category ul a,
.preset-skymall [aria-labelledby="widgetLinksTitle"] ul a,
.preset-skymall .contact-v1 .col-lg-5 ul li,
.preset-skymall .contact-v1 .col-lg-5 ul address {
    font-size: .875rem;
}


/* Header: the help phone and the cart total in the brand colour */
.preset-skymall .header-market [data-help-phone],
.preset-skymall .header-market [data-cart-sum] {
    color: var(--sky-primary);
}


/* /stores: a little air between a branch's rows (address · phone · e-mail · hours) */
.preset-skymall.stores-page .item-list {
    display: flex;
    flex-direction: column;
    gap: .5rem;
}
