/* HyperTechno_HomeBanners — frontend banner regions */
.ht-banner { margin: 0 0 20px; }
.ht-banner-item {
    position: relative;
    display: block;
    overflow: hidden;
    border-radius: 6px;
    text-decoration: none;
}
.ht-banner-pic { display: block; }
.ht-banner-img {
    display: block;
    width: 100%;
    height: auto;
}

/* Video creatives (YouTube embed or uploaded file): responsive 16:9 box that fills its cell. */
.ht-banner-item--video { display: block; }
.ht-banner-video {
    position: relative;
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000;
    overflow: hidden;
}
/* aspect-ratio fallback for older browsers */
@supports not (aspect-ratio: 16 / 9) {
    .ht-banner-video { height: 0; padding-bottom: 56.25%; }
}
.ht-banner-video iframe,
.ht-banner-video video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
    object-fit: cover;
}

/* Overlay text + badge */
.ht-banner-overlay {
    position: absolute;
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 12px 16px;
    max-width: 70%;
    color: #fff;
    pointer-events: none;
}
.ht-banner-title { font-size: 22px; font-weight: 700; line-height: 1.2; }
.ht-banner-subtitle { font-size: 15px; }
.ht-badge {
    align-self: flex-start;
    padding: 2px 10px;
    border-radius: 3px;
    background: #c0392b;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .03em;
}
.ht-banner-cta {
    align-self: flex-start;
    margin-top: 4px;
    padding: 8px 18px;
    border-radius: 4px;
    background: #c0392b;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    pointer-events: auto;
}

/* Nine-point overlay placement.
   Uses logical inset/text-align (start/end) so left/right positions mirror
   automatically on RTL (Arabic) store views — identical to physical on LTR. */
.ht-pos-top-left { top: 0; inset-inline-start: 0; align-items: flex-start; text-align: start; }
.ht-pos-top-center { top: 0; left: 50%; transform: translateX(-50%); align-items: center; text-align: center; }
.ht-pos-top-right { top: 0; inset-inline-end: 0; align-items: flex-end; text-align: end; }
.ht-pos-middle-left { top: 50%; inset-inline-start: 0; transform: translateY(-50%); align-items: flex-start; text-align: start; }
.ht-pos-middle-center { top: 50%; left: 50%; transform: translate(-50%, -50%); align-items: center; text-align: center; }
.ht-pos-middle-right { top: 50%; inset-inline-end: 0; transform: translateY(-50%); align-items: flex-end; text-align: end; }
.ht-pos-bottom-left { bottom: 0; inset-inline-start: 0; align-items: flex-start; text-align: start; }
.ht-pos-bottom-center { bottom: 0; left: 50%; transform: translateX(-50%); align-items: center; text-align: center; }
.ht-pos-bottom-right { bottom: 0; inset-inline-end: 0; align-items: flex-end; text-align: end; }

/* promo_grid */
.ht-mode-promo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 14px;
}

/* split_hero_tiles */
.ht-mode-split-hero {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 14px;
    align-items: stretch;
}
.ht-mode-split-hero .ht-split-tiles {
    display: grid;
    grid-template-rows: repeat(auto-fit, minmax(0, 1fr));
    gap: 14px;
}
.ht-mode-split-hero .ht-banner-item,
.ht-mode-split-hero .ht-banner-pic,
.ht-mode-split-hero .ht-banner-img { height: 100%; }
.ht-mode-split-hero .ht-banner-img { object-fit: cover; }

/* flash_sale */
.ht-flash-timer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    flex-wrap: wrap;
    padding: 10px 16px;
    margin-bottom: 12px;
    border-radius: 6px;
    background: #2c3e50;
    color: #fff;
}
.ht-flash-label { font-weight: 700; text-transform: uppercase; letter-spacing: .03em; }
.ht-cd { display: inline-flex; gap: 8px; }
.ht-cd-unit {
    display: inline-flex;
    align-items: baseline;
    gap: 2px;
    padding: 4px 8px;
    border-radius: 4px;
    background: #c0392b;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}
.ht-cd-unit em { font-style: normal; font-size: 11px; opacity: .85; }
.ht-mode-flash-sale .ht-flash-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 14px;
}

/* Hero-only navigation: always visible when enabled, without covering copy on mobile. */
.ht-mode-hero-carousel .ht-owl {
    position: relative;
}
.ht-mode-hero-carousel .ht-owl .owl-stage-outer {
    border-radius: var(--ht-radius-lg, 16px);
    touch-action: pan-y;
}
.ht-mode-hero-carousel .ht-owl .owl-nav {
    position: absolute;
    inset: 0 16px 56px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 0;
    pointer-events: none;
}
.ht-mode-hero-carousel .ht-owl .owl-nav > button {
    position: static;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    min-width: 44px;
    margin: 0;
    padding: 0;
    border: 1px solid var(--ht-color-line, #d9dde3);
    border-radius: var(--ht-radius-sm, 8px);
    background: var(--ht-color-surface, #fff);
    color: var(--ht-color-ink, #111313);
    box-shadow: 0 2px 8px rgba(17, 19, 19, .12);
    opacity: 1;
    visibility: visible;
    transform: none;
    cursor: pointer;
    pointer-events: auto;
}
.ht-mode-hero-carousel .ht-owl .ht-carousel-icon {
    display: block;
    width: 24px;
    height: 24px;
}
.ht-mode-hero-carousel .ht-owl .owl-prev .ht-carousel-icon,
.ht-mode-hero-carousel .ht-owl.owl-rtl .owl-next .ht-carousel-icon {
    transform: rotate(180deg);
}
.ht-mode-hero-carousel .ht-owl.owl-rtl .owl-prev .ht-carousel-icon {
    transform: none;
}
.ht-mode-hero-carousel .ht-owl .owl-nav > button:hover:not(:disabled) {
    border-color: var(--ht-color-primary, #d71920);
    background: var(--ht-color-primary, #d71920);
    color: var(--ht-color-white, #fff);
}
.ht-mode-hero-carousel .ht-owl .owl-nav > button:disabled {
    color: var(--ht-color-disabled, #858a91);
    box-shadow: none;
    cursor: default;
}
.ht-mode-hero-carousel .ht-owl .owl-dots {
    position: static;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    min-height: 44px;
    margin: 12px 0 0;
    padding: 0;
    text-align: center;
}
.ht-mode-hero-carousel .ht-owl .owl-dot {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: var(--ht-radius-sm, 8px);
    background: transparent;
    cursor: pointer;
}
.ht-mode-hero-carousel .ht-owl .owl-dot > span {
    display: block;
    width: 8px;
    height: 8px;
    margin: 0;
    border: 0;
    border-radius: 999px;
    background: var(--ht-color-disabled, #858a91);
}
.ht-mode-hero-carousel .ht-owl.owl-carousel .owl-dot.active > span {
    width: 24px;
    background: var(--ht-color-primary, #d71920);
}
.ht-mode-hero-carousel .ht-owl.owl-carousel .owl-dot:hover > span {
    background: var(--ht-color-primary-dark, #aa1419);
}
.ht-mode-hero-carousel .ht-owl .owl-nav > button:focus-visible,
.ht-mode-hero-carousel .ht-owl .owl-dot:focus-visible {
    outline: 2px solid var(--ht-color-primary, #d71920);
    outline-offset: 2px;
}
.ht-mode-hero-carousel .ht-owl .owl-nav.disabled,
.ht-mode-hero-carousel .ht-owl .owl-dots.disabled {
    display: none;
}
.ht-mode-hero-carousel .ht-owl.ht-carousel--no-dots .owl-nav {
    bottom: 0;
}

@media (max-width: 767px) {
    .ht-mode-hero-carousel .ht-owl.owl-loaded {
        display: grid;
        grid-template-columns: 44px minmax(0, 1fr) 44px;
        column-gap: 8px;
    }
    .ht-mode-hero-carousel .ht-owl .owl-stage-outer {
        grid-column: 1 / -1;
        grid-row: 1;
        min-width: 0;
    }
    .ht-mode-hero-carousel .ht-owl .owl-nav {
        position: static;
        grid-column: 1 / -1;
        grid-row: 2;
        margin-block-start: 12px;
    }
    .ht-mode-hero-carousel .ht-owl .owl-dots {
        grid-column: 2;
        grid-row: 2;
        z-index: 1;
    }
    .ht-mode-hero-carousel .ht-owl .owl-nav > button {
        box-shadow: none;
    }
}

/* Mobile */
@media (max-width: 767px) {
    .ht-mode-split-hero { grid-template-columns: 1fr; }
    .ht-banner-title { font-size: 18px; }
    .ht-banner-overlay { max-width: 85%; padding: 10px 12px; }
}
