/*
 * Dawn Bread UI fixes (header, hero, cards, sections, filters, container widget).
 * Loaded after the theme stylesheet from layouts/base.blade.php.
 * Source copy: platform/themes/nest/public/css/dawn-ui.css
 */

:root {
    --dawn-topbar-h: 34px;
    --dawn-dark: #2a0507;
    --dawn-yellow: #fdc040;
    --dawn-gap: 32px;
    --dawn-hero-h: clamp(280px, 30vw, 400px);
}

/* ------------------------------------------------------------------ */
/* Header: one sticky block, the thin top strip scrolls away smoothly  */
/* ------------------------------------------------------------------ */
.dawn-header {
    position: sticky;
    top: calc(var(--dawn-topbar-h) * -1);
    z-index: 1000;
    background: #fff;
    border-bottom: 1px solid #ececec !important;
    min-height: 0 !important;
}

.dawn-topbar {
    height: var(--dawn-topbar-h);
    background: var(--color-brand-dark, #9e1218);
    color: #fff;
    font-size: 12px;
    overflow: hidden;
}

.dawn-topbar-inner {
    height: var(--dawn-topbar-h);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.dawn-shipping {
    display: flex;
    align-items: center;
    gap: 18px;
    min-width: 0;
    white-space: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
}

.dawn-shipping::-webkit-scrollbar { display: none; }

.dawn-shipping strong {
    font-weight: 600;
    opacity: .8;
}

.dawn-shipping > span + span {
    padding-left: 18px;
    border-left: 1px solid rgba(255, 255, 255, .3);
}

.dawn-topbar-btn {
    flex: none;
    height: 24px;
    padding: 0 12px;
    border: 1px solid rgba(255, 255, 255, .7);
    border-radius: 999px;
    background: transparent;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    line-height: 22px;
    cursor: pointer;
    transition: background .2s, color .2s;
}

.dawn-topbar-btn:hover {
    background: #fff;
    color: var(--color-brand-dark, #9e1218);
}

/* Middle row: logo | search | cart + account */
.dawn-header .header-middle-ptb-1 {
    padding: 8px 0 !important;
}

.dawn-header .header-wrap {
    min-height: 0;
}

.dawn-header .logo.logo-width-1 {
    flex: none;
    margin-right: 24px;
}

.dawn-header .logo a img {
    max-height: 60px !important;
    width: auto;
}

.dawn-header .header-right {
    gap: 20px;
}

.dawn-header .search-style-2 {
    flex: 1 1 auto;
    min-width: 0;
    max-width: 760px;
}

.dawn-header .search-style-2 form input {
    width: 100%;
    min-width: 0;
}

/* the theme hides cart/account below 1200px; the compact header has room for them */
@media (min-width: 992px) {
    .dawn-header .header-middle .header-action-right {
        display: flex !important;
        flex: none;
    }
}

.dawn-header .search-style-2 form {
    max-width: none;
    width: 100%;
}

.dawn-header .header-action-2 {
    display: flex;
    align-items: center;
    gap: 18px;
}

.dawn-header .header-action-2 .header-action-icon-2,
.dawn-header .header-action-2 .header-action-icon-2:last-child {
    display: flex;
    align-items: center;
    padding: 0;
}

.dawn-header .header-action-2 .header-action-icon-2 > a {
    display: inline-flex;
    align-items: center;
}

.dawn-header .header-action-2 .header-action-icon-2 span.lable {
    margin: 0 0 0 6px;
    font-size: 14px;
    line-height: 1;
}

/* Menu row: one line, shorter */
.dawn-header .header-bottom .header-wrap {
    min-height: 44px;
}

.dawn-header .main-menu.main-menu-lh-2 > nav > ul > li {
    line-height: 44px;
}

.dawn-header .main-menu.main-menu-padding-1 > nav > ul {
    display: flex;
    flex-wrap: nowrap;
}

.dawn-header .main-menu.main-menu-padding-1 > nav > ul > li {
    padding: 0 12px;
    white-space: nowrap;
}

.dawn-header .main-menu.main-menu-padding-1 > nav > ul > li:first-child {
    padding-left: 0;
}

.dawn-header .main-menu > nav > ul > li > a {
    font-size: 14px;
}

@media (max-width: 1199.98px) {
    .dawn-header .main-menu.main-menu-padding-1 > nav > ul > li { padding: 0 5px; }
    .dawn-header .main-menu > nav > ul > li > a { font-size: 12.5px; }
    .dawn-header .header-action-2 .header-action-icon-2 span.lable { display: none !important; }
}

/* Mobile / tablet header (≤991px): logo + burger + cart */
@media (max-width: 991.98px) {
    .dawn-header .header-bottom .header-wrap { min-height: 56px; }

    .dawn-header .header-bottom .logo.logo-width-1 { margin-right: auto; }

    .dawn-header .header-bottom .logo a img { max-height: 50px !important; }

    .dawn-header .header-bottom .header-action-icon-2.d-block { order: -1; margin-right: 12px; }
}

@media (max-width: 575.98px) {
    :root { --dawn-topbar-h: 30px; }

    .dawn-topbar { font-size: 11px; }

    .dawn-shipping { gap: 10px; }

    .dawn-shipping > span + span { padding-left: 10px; }

    .dawn-topbar-btn { height: 22px; padding: 0 9px; font-size: 11px; line-height: 20px; }
}

/* Breadcrumb: compact */
.page-header.breadcrumb-wrap {
    padding: 10px 0;
    font-size: 13px;
}

.page-header.breadcrumb-wrap .breadcrumb {
    font-size: 13px;
}

/* ------------------------------------------------------------------ */
/* Hero slider: dark panel + copy on the left, artwork on the right    */
/* ------------------------------------------------------------------ */
.home-slider.mt-30 {
    margin-top: 16px !important;
    margin-bottom: 0 !important;
}

.home-slider .home-slide-cover.mt-30 {
    margin-top: 0 !important;
}

.hero-slider-1.style-4 .single-hero-slider.single-animation-wrap {
    position: relative;
    height: var(--dawn-hero-h);
    border-radius: 20px;
    overflow: hidden;
    background-color: var(--dawn-dark);
    background-repeat: no-repeat;
    background-size: auto 100%;
    background-position: right center;
}

.hero-slider-1.style-4 .single-hero-slider::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    /* the 2:1 artwork is height-fitted to the right; fade over its first 180px */
    width: calc(100% - var(--dawn-hero-h) * 2 + 180px);
    z-index: 1;
    pointer-events: none;
    background: linear-gradient(90deg, var(--dawn-dark) 0, var(--dawn-dark) calc(100% - 180px), rgba(42, 5, 7, .6) calc(100% - 90px), rgba(42, 5, 7, 0) 100%);
}

.hero-slider-1 .slick-dots:has(li:only-child) {
    display: none !important;
}

.hero-slider-1.style-4 .slider-content {
    z-index: 2;
    left: 4.5%;
    width: 36%;
    max-width: 480px;
}

.dawn-hero-text {
    color: #fff;
}

.dawn-hero-eyebrow {
    display: inline-block;
    margin-bottom: 10px;
    color: var(--dawn-yellow);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.dawn-hero-text h1 {
    margin: 0 0 10px;
    color: #fff;
    font-size: clamp(22px, 2.3vw, 34px);
    line-height: 1.2;
}

.dawn-hero-text h1 em {
    color: var(--dawn-yellow);
    font-style: normal;
}

.hero-slider-1 .slider-content .dawn-hero-text p {
    margin: 0 0 18px !important;
    color: rgba(255, 255, 255, .8);
    font-size: 15px;
    line-height: 1.5;
}

.dawn-hero-cta {
    display: inline-block;
    padding: 10px 22px;
    border-radius: 999px;
    background: var(--dawn-yellow);
    color: #2a0507 !important;
    font-size: 14px;
    font-weight: 700;
    transition: transform .2s, box-shadow .2s;
}

.dawn-hero-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, .25);
}

.hero-slider-1.style-4 .slider-content .newsletter {
    margin-top: 16px;
}

.hero-slider-1.style-4 .slider-content .form-subscribe {
    max-width: 360px;
    margin-bottom: 0;
}

.hero-slider-1.style-4 .slider-content .form-subscribe input {
    height: 44px;
    font-size: 14px;
}

.hero-slider-1.style-4 .slider-content .form-subscribe button {
    padding: 0 20px !important;
    height: 44px;
    font-size: 14px;
}

@media (max-width: 1199.98px) {
    .hero-slider-1 .slider-content .dawn-hero-text p { display: none; }
    .hero-slider-1.style-4 .slider-content .newsletter { margin-top: 12px; }
}

/* Tablet / phone: full artwork on top, copy underneath on the dark panel */
@media (max-width: 991.98px) {
    .hero-slider-1.style-4 .single-hero-slider.single-animation-wrap {
        height: auto;
        padding-top: 50%;
        background-size: 100% auto;
        background-position: top center;
        border-radius: 16px;
    }

    .hero-slider-1.style-4 .single-hero-slider::before { display: none; }

    .hero-slider-1.style-4 .slider-content {
        position: static;
        transform: none;
        width: auto;
        max-width: none;
        padding: 18px 20px 22px;
    }

    .hero-slider-1 .slider-content .dawn-hero-text p { display: block; font-size: 14px; }

    .hero-slider-1.style-4 .slider-content .form-subscribe { max-width: none; width: 100%; }

    .hero-slider-1.style-4 .slider-content .form-subscribe input { flex: 1 1 auto; min-width: 0; width: auto; }

    .hero-slider-1.style-4 .slider-content .form-subscribe button { flex: none; }

    .home-slider .slider-arrow { display: none; }
}

/* ------------------------------------------------------------------ */
/* Equal spacing between homepage sections                             */
/* ------------------------------------------------------------------ */
.popular-categories.section-padding,
section.banners,
section.product-tabs,
section.top-products-group,
section.featured.section-padding {
    padding-top: var(--dawn-gap) !important;
    padding-bottom: var(--dawn-gap) !important;
    margin-top: 0 !important;
    margin-bottom: 0 !important;
}

section.newsletter {
    padding-top: var(--dawn-gap);
    margin-bottom: var(--dawn-gap) !important;
}

.popular-categories .section-title,
.product-tabs .heading-tab,
.top-products-group .section-title {
    margin-bottom: 20px !important;
}

/* Promo banners: a little smaller */
section.banners > .container > .row {
    max-width: 1080px;
    margin-left: auto;
    margin-right: auto;
}

section.banners .banner-img {
    margin-bottom: 16px;
}

/* ------------------------------------------------------------------ */
/* Product cards: same height, whole image visible, buttons aligned    */
/* ------------------------------------------------------------------ */
.row > [class*="col"]:has(> .product-cart-wrap) {
    display: flex;
    flex-direction: column;
    margin-bottom: 24px !important;
}

.product-cart-wrap {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    margin-bottom: 0 !important;
}

.product-cart-wrap .product-img-action-wrap .product-img a {
    display: block;
    aspect-ratio: 1 / 1;
    background: #fff;
}

.product-cart-wrap .product-img-action-wrap .product-img a img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 8px;
}

.product-cart-wrap .product-content-wrap {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
}

.product-cart-wrap .product-content-wrap .product-card-bottom {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.product-cart-wrap .product-content-wrap .product-card-bottom:last-child {
    margin-top: auto;
    padding-top: 10px;
}

.product-cart-wrap .product-content-wrap .product-card-bottom .add-cart .add {
    margin-top: 0 !important;
}

.product-cart-wrap .product-category {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

@media (max-width: 575.98px) {
    .product-cart-wrap .product-content-wrap .product-card-bottom:not(:last-child) {
        flex-wrap: wrap;
    }

    .product-cart-wrap .product-price,
    .product-cart-wrap .product-price span {
        font-size: 14px !important;
    }

    .product-cart-wrap .product-price {
        min-width: 0;
        white-space: normal;
    }
}

/* Trending / Recently added: one section each, cards in a row */
.top-products-card {
    display: flex;
    align-items: center;
    gap: 14px;
    height: 100%;
    padding: 12px;
    border: 1px solid #ececec;
    border-radius: 12px;
    background: #fff;
}

.top-products-card figure {
    flex: 0 0 84px;
}

.top-products-card figure img {
    width: 84px;
    height: 84px;
    object-fit: contain;
    border-radius: 8px;
}

.top-products-card-body {
    min-width: 0;
}

.top-products-card-body .h6 {
    margin-bottom: 6px;
    font-size: 14px;
}

/* ------------------------------------------------------------------ */
/* Category page filter panel: compact                                 */
/* ------------------------------------------------------------------ */
.shop-product-filter-header {
    padding: 18px 22px !important;
    margin-bottom: 20px !important;
}

.shop-product-filter-header > .row {
    display: flex;
    flex-wrap: wrap;
    gap: 16px 48px;
    margin: 0;
}

.shop-product-filter-header > .row > .widget-filter-item {
    flex: 0 1 300px;
    width: auto;
    max-width: 100%;
    padding: 0;
    margin-bottom: 0 !important;
}

.shop-product-filter-header .widget__title {
    margin-bottom: 10px !important;
}

.shop-product-filter-header .custome-checkbox,
.shop-product-filter-header .ps-custom-scrollbar {
    max-height: 180px;
    overflow-y: auto;
}

.shop-product-filter-header .show-advanced-filters {
    margin: 14px 0 0;
}

.shop-product-filter-header .advanced-search-widgets {
    margin: 12px 0 0;
}

.shop-product-filter-header > .widget {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
}

.shop-product-filter-header > .widget .clear_all_filter {
    margin: 0 !important;
}

/* ------------------------------------------------------------------ */
/* Floating container load widget: one compact line                    */
/* ------------------------------------------------------------------ */
.boc {
    position: fixed;
    left: 16px;
    bottom: 16px;
    z-index: 999;
    display: flex;
    align-items: center;
    gap: 10px;
    max-width: calc(100vw - 32px);
    padding: 7px 16px 9px 12px;
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, .08);
    border-radius: 999px;
    /* background fills left-to-right with the container load (--fill) */
    background: linear-gradient(90deg, rgba(var(--color-brand-rgb, 236, 28, 36), .22) var(--fill, 0%), transparent 0), #fff;
    box-shadow: 0 6px 18px rgba(0, 0, 0, .14);
    transition: background .3s;
    color: #253d4e;
    font-size: 12px;
    line-height: 1.3;
}

.boc img {
    flex: none;
    width: auto;
    height: 22px;
}

.boc-stats {
    display: flex;
    gap: 14px;
    white-space: nowrap;
}

.boc-stats > span + span {
    padding-left: 14px;
    border-left: 1px solid #e5e5e5;
}

.boc-stats b {
    color: #000;
    font-weight: 800;
}

.boc-bar {
    position: absolute;
    left: 0;
    bottom: 0;
    height: 3px;
    width: var(--fill, 0%);
    background: var(--color-brand, #ec1c24);
    transition: width .3s;
}

/* keep the widget above the mobile bottom navigation bar */
@media (max-width: 991.98px) {
    .boc { bottom: 72px; }
}

@media (max-width: 575.98px) {
    .boc {
        left: 8px;
        right: 8px;
        max-width: none;
        justify-content: center;
        gap: 8px;
        padding: 6px 10px 8px;
        border-radius: 12px;
        font-size: 11px;
    }

    .boc img { height: 18px; }

    .boc-stats { gap: 8px; }

    .boc-stats > span + span { padding-left: 8px; }
}

@media (max-width: 379.98px) {
    .boc img { display: none; }
}
