:root {
    --marketplace-primary: #e11d48;
    --marketplace-primary-dark: #be123c;
    --marketplace-dark: #0f172a;
    --marketplace-muted: #64748b;
    --marketplace-border: #e2e8f0;
    --marketplace-surface: #f1f5f9;
    --marketplace-card: #ffffff;
}

.aiz-marketplace {
    background: var(--marketplace-surface);
}

.marketplace-home {
    color: #1e293b;
    font-family: "Public Sans", sans-serif;
    padding: 24px 0 64px;
}

.marketplace-home *,
.marketplace-home *::before,
.marketplace-home *::after {
    box-sizing: border-box;
}

.marketplace-shell {
    width: min(1400px, calc(100% - 32px));
    margin: 0 auto;
}

.marketplace-hero-grid {
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr) 260px;
    gap: 16px;
    min-height: 420px;
    margin-bottom: 24px;
}

.marketplace-category-panel,
.marketplace-account-card,
.marketplace-shortcuts,
.marketplace-flash-section,
.marketplace-dynamic-products,
.marketplace-recommended-section {
    border: 1px solid var(--marketplace-border);
    border-radius: 14px;
    background: var(--marketplace-card);
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.04);
}

.marketplace-category-panel {
    display: flex;
    min-width: 0;
    flex-direction: column;
    overflow: hidden;
}

.marketplace-panel-title {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 15px 17px;
    border-bottom: 1px solid #f1f5f9;
    color: var(--marketplace-dark);
    font-size: 14px;
    font-weight: 800;
}

.marketplace-panel-title i {
    color: var(--marketplace-primary);
    font-size: 19px;
}

.marketplace-category-list {
    flex: 1;
    margin: 0;
    padding: 7px 0 0;
    list-style: none;
}

.marketplace-category-list a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 36px;
    padding: 7px 15px;
    color: #475569;
    font-size: 12px;
    font-weight: 600;
    transition: 0.2s ease;
}

.marketplace-category-list a:hover {
    background: #fff1f2;
    color: var(--marketplace-primary);
}

.marketplace-category-list a > i {
    color: #cbd5e1;
    font-size: 10px;
}

.marketplace-category-label {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 9px;
}

.marketplace-category-label span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.marketplace-category-label > i,
.marketplace-category-icon {
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
    object-fit: contain;
    color: #94a3b8;
    font-size: 17px;
    text-align: center;
}

.marketplace-view-all {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    border-top: 1px solid #f1f5f9;
    color: var(--marketplace-primary);
    font-size: 12px;
    font-weight: 800;
}

.marketplace-hero-slider {
    min-width: 0;
    height: 420px;
    overflow: hidden;
    border-radius: 14px;
    background: var(--marketplace-dark);
    box-shadow: 0 3px 12px rgba(15, 23, 42, 0.08);
}

.marketplace-hero-slider .slick-list,
.marketplace-hero-slider .slick-track,
.marketplace-hero-slider .slick-slide,
.marketplace-hero-slider .slick-slide > div {
    height: 100%;
}

.marketplace-hero-slide {
    display: block !important;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.marketplace-hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.marketplace-hero-fallback {
    position: relative;
    background:
        radial-gradient(circle at 80% 30%, rgba(225, 29, 72, 0.82), transparent 32%),
        linear-gradient(125deg, #0f172a 15%, #1e293b 55%, #881337);
}

.marketplace-hero-fallback > div {
    display: flex;
    height: 100%;
    max-width: 620px;
    flex-direction: column;
    justify-content: center;
    padding: 48px;
    color: #fff;
}

.marketplace-hero-fallback span {
    margin-bottom: 10px;
    color: #fbbf24;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.marketplace-hero-fallback h1 {
    margin: 0 0 24px;
    color: #fff;
    font-size: clamp(28px, 4vw, 48px);
    font-weight: 900;
    line-height: 1.08;
}

.marketplace-hero-fallback strong {
    width: fit-content;
    padding: 11px 18px;
    border-radius: 999px;
    background: #fff;
    color: var(--marketplace-dark);
    font-size: 13px;
}

.marketplace-hero-slider .slick-arrow {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.88);
    color: var(--marketplace-dark);
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.14);
}

.marketplace-hero-slider .slick-dots {
    bottom: 15px;
}

.marketplace-side-column {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 12px;
}

.marketplace-account-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 16px;
    text-align: center;
}

.marketplace-avatar {
    display: flex;
    width: 48px;
    height: 48px;
    align-items: center;
    justify-content: center;
    margin-bottom: 8px;
    border-radius: 50%;
    background: #f1f5f9;
    color: #94a3b8;
    font-size: 25px;
}

.marketplace-account-card p {
    margin: 0;
    color: var(--marketplace-muted);
    font-size: 12px;
}

.marketplace-account-card strong {
    max-width: 100%;
    overflow: hidden;
    color: var(--marketplace-dark);
    font-size: 13px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.marketplace-account-actions {
    display: grid;
    width: 100%;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: 12px;
}

.marketplace-account-actions a {
    padding: 8px 6px;
    border-radius: 8px;
    background: #fff1f2;
    color: var(--marketplace-primary);
    font-size: 11px;
    font-weight: 800;
}

.marketplace-account-actions a.is-primary {
    background: var(--marketplace-primary);
    color: #fff;
}

.marketplace-promo-card {
    position: relative;
    display: block;
    min-height: 0;
    flex: 1;
    overflow: hidden;
    border-radius: 13px;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.08);
}

.marketplace-promo-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.marketplace-promo-card:hover img {
    transform: scale(1.04);
}

.marketplace-promo-fallback {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 17px;
    color: #fff;
}

.marketplace-promo-fallback.is-deal {
    background: linear-gradient(135deg, #f59e0b, #fbbf24);
    color: #0f172a;
}

.marketplace-promo-fallback.is-delivery {
    background: linear-gradient(135deg, #0369a1, #0ea5e9);
}

.marketplace-promo-fallback i {
    position: absolute;
    top: 14px;
    right: 14px;
    font-size: 30px;
    opacity: 0.35;
}

.marketplace-promo-fallback span {
    font-size: 15px;
    font-weight: 900;
}

.marketplace-promo-fallback strong {
    font-size: 11px;
    opacity: 0.8;
}

.marketplace-shortcuts {
    display: grid;
    grid-template-columns: repeat(8, minmax(0, 1fr));
    margin-bottom: 32px;
    padding: 22px 16px;
}

.marketplace-shortcuts > a {
    display: flex;
    min-width: 0;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 4px 8px;
    color: #334155;
    text-align: center;
}

.marketplace-shortcuts strong {
    width: 100%;
    overflow: hidden;
    font-size: 11px;
    font-weight: 700;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.marketplace-shortcut-icon {
    display: flex;
    width: 48px;
    height: 48px;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-radius: 50%;
    font-size: 22px;
    transition: transform 0.2s ease;
}

.marketplace-shortcuts a:hover .marketplace-shortcut-icon {
    transform: translateY(-3px) scale(1.05);
}

.marketplace-shortcut-icon img {
    width: 27px;
    height: 27px;
    object-fit: contain;
}

.marketplace-shortcut-icon.is-red { background: #fff1f2; color: #e11d48; }
.marketplace-shortcut-icon.is-blue { background: #eff6ff; color: #2563eb; }
.marketplace-shortcut-icon.is-green { background: #f0fdf4; color: #16a34a; }
.marketplace-shortcut-icon.is-purple { background: #faf5ff; color: #9333ea; }
.marketplace-shortcut-icon.is-category-0 { background: #fff7ed; color: #ea580c; }
.marketplace-shortcut-icon.is-category-1 { background: #f0fdfa; color: #0d9488; }
.marketplace-shortcut-icon.is-category-2 { background: #fdf2f8; color: #db2777; }
.marketplace-shortcut-icon.is-category-3 { background: #f8fafc; color: #475569; }

.marketplace-flash-section,
.marketplace-dynamic-products,
.marketplace-recommended-section {
    margin-bottom: 30px;
    overflow: hidden;
}

.marketplace-section-header {
    display: flex;
    min-height: 68px;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 14px 20px;
}

.marketplace-section-header.is-flash {
    background: linear-gradient(105deg, #be123c, #f43f5e);
    color: #fff;
}

.marketplace-section-header > a {
    padding: 8px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.16);
    color: #fff;
    font-size: 12px;
    font-weight: 800;
}

.marketplace-flash-heading {
    display: flex;
    align-items: center;
    gap: 28px;
}

.marketplace-flash-heading h2 {
    margin: 0;
    color: #fff;
    font-size: 22px;
    font-style: italic;
    font-weight: 900;
    letter-spacing: -0.02em;
}

.marketplace-flash-heading h2 i {
    color: #fbbf24;
}

.marketplace-flash-countdown {
    display: flex;
    align-items: center;
    gap: 9px;
    font-size: 12px;
}

.marketplace-flash-countdown .aiz-count-down {
    gap: 4px;
}

.marketplace-flash-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 18px;
    padding: 20px;
}

.marketplace-flash-card {
    min-width: 0;
}

.marketplace-flash-image {
    position: relative;
    display: flex;
    aspect-ratio: 1 / 1;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border: 1px solid #f1f5f9;
    border-radius: 10px;
    background: #f8fafc;
}

.marketplace-flash-image > span {
    position: absolute;
    top: 8px;
    right: 8px;
    z-index: 2;
    padding: 4px 8px;
    border-radius: 999px;
    background: var(--marketplace-primary);
    color: #fff;
    font-size: 10px;
    font-weight: 800;
}

.marketplace-flash-image img {
    width: 100%;
    height: 100%;
    padding: 10px;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.marketplace-flash-card:hover img {
    transform: scale(1.06);
}

.marketplace-flash-card h3 {
    height: 39px;
    margin: 10px 0 5px;
    overflow: hidden;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.55;
}

.marketplace-flash-card h3 a {
    color: #334155;
}

.marketplace-flash-price {
    display: flex;
    align-items: baseline;
    gap: 6px;
}

.marketplace-flash-price strong {
    color: var(--marketplace-primary);
    font-size: 16px;
    font-weight: 900;
}

.marketplace-flash-price del {
    color: #94a3b8;
    font-size: 11px;
}

.marketplace-ajax-section:empty {
    display: none;
}

.marketplace-section-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 19px 20px 15px;
}

.marketplace-section-heading > div {
    display: flex;
    align-items: center;
    gap: 10px;
}

.marketplace-section-heading > div > span {
    width: 5px;
    height: 24px;
    border-radius: 999px;
    background: var(--marketplace-primary);
}

.marketplace-section-heading h2 {
    margin: 0;
    color: var(--marketplace-dark);
    font-size: 21px;
    font-weight: 900;
    letter-spacing: -0.02em;
}

.marketplace-section-heading > a {
    color: var(--marketplace-primary);
    font-size: 12px;
    font-weight: 800;
}

.marketplace-product-carousel {
    padding: 0 12px 20px;
}

.marketplace-product-carousel .carousel-box {
    height: 100%;
    padding: 0 8px 4px;
}

.marketplace-product-card {
    display: flex;
    height: 100%;
    min-height: 365px;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid var(--marketplace-border);
    border-radius: 12px;
    background: #fff;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.marketplace-product-card:hover {
    transform: translateY(-3px);
    border-color: rgba(225, 29, 72, 0.28);
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.1);
}

.marketplace-product-media {
    position: relative;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background: #f8fafc;
}

.marketplace-product-media > a {
    display: flex;
    width: 100%;
    height: 100%;
    align-items: center;
    justify-content: center;
}

.marketplace-product-media img {
    width: 100%;
    height: 100%;
    padding: 14px;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.marketplace-product-card:hover .marketplace-product-media img {
    transform: scale(1.04);
}

.marketplace-product-badges {
    position: absolute;
    top: 10px;
    left: 10px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 5px;
}

.marketplace-product-badges span {
    padding: 4px 7px;
    border-radius: 5px;
    color: #fff;
    font-size: 9px;
    font-weight: 800;
}

.marketplace-product-badges .is-discount { background: var(--marketplace-primary); }
.marketplace-product-badges .is-wholesale { background: #0f766e; }

.marketplace-wishlist-button {
    position: absolute;
    top: 9px;
    right: 9px;
    display: flex;
    width: 34px;
    height: 34px;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.94);
    color: #64748b;
    font-size: 18px;
    box-shadow: 0 3px 10px rgba(15, 23, 42, 0.1);
    transition: 0.2s ease;
}

.marketplace-wishlist-button:hover {
    background: var(--marketplace-primary);
    color: #fff;
}

.marketplace-product-content {
    display: flex;
    flex: 1;
    flex-direction: column;
    padding: 13px;
}

.marketplace-product-content h3 {
    display: -webkit-box;
    height: 42px;
    margin: 0 0 7px;
    overflow: hidden;
    color: #334155;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.55;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.marketplace-product-content h3 a {
    color: inherit;
}

.marketplace-product-content h3 a:hover {
    color: var(--marketplace-primary);
}

.marketplace-product-rating {
    display: flex;
    min-height: 18px;
    align-items: center;
    gap: 5px;
    margin-bottom: 10px;
}

.marketplace-product-rating .rating i {
    color: #f59e0b;
    font-size: 10px;
}

.marketplace-product-rating small {
    color: #94a3b8;
    font-size: 10px;
}

.marketplace-product-bottom {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 8px;
    margin-top: auto;
}

.marketplace-product-price {
    display: flex;
    min-width: 0;
    flex-direction: column;
}

.marketplace-product-price strong {
    color: var(--marketplace-dark);
    font-size: 17px;
    font-weight: 900;
    line-height: 1.2;
}

.marketplace-product-price del {
    color: #94a3b8;
    font-size: 11px;
}

.marketplace-add-button {
    display: flex;
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 50%;
    background: #fff1f2;
    color: var(--marketplace-primary);
    font-size: 19px;
    transition: 0.2s ease;
}

.marketplace-add-button:hover {
    background: var(--marketplace-primary);
    color: #fff;
    transform: rotate(4deg) scale(1.05);
}

.marketplace-recommended-section {
    padding-bottom: 20px;
}

.marketplace-recommended-section .products-wrapper-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 16px;
    padding: 0 20px;
}

.marketplace-recommended-section .grid-item {
    min-width: 0;
}

.marketplace-ajax-section .container {
    max-width: none;
    padding: 0;
}

.marketplace-ajax-section > section {
    margin-bottom: 30px !important;
}

.marketplace-ajax-section .home-category-banner {
    border-radius: 12px;
}

.marketplace-ajax-section .home-category {
    border-radius: 12px;
    background: #fff;
}

@media (max-width: 1199.98px) {
    .marketplace-hero-grid {
        grid-template-columns: 210px minmax(0, 1fr);
    }

    .marketplace-side-column {
        display: none;
    }

    .marketplace-flash-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .marketplace-flash-card:nth-child(n + 5) {
        display: none;
    }

    .marketplace-recommended-section .products-wrapper-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

@media (max-width: 991.98px) {
    .marketplace-home {
        padding-top: 16px;
    }

    .marketplace-hero-grid {
        grid-template-columns: 1fr;
        min-height: 340px;
    }

    .marketplace-category-panel {
        display: none;
    }

    .marketplace-hero-slider {
        height: 340px;
    }

    .marketplace-shortcuts {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        row-gap: 18px;
    }

    .marketplace-recommended-section .products-wrapper-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 767.98px) {
    .marketplace-shell {
        width: min(100% - 20px, 1400px);
    }

    .marketplace-hero-grid {
        min-height: 260px;
        margin-bottom: 16px;
    }

    .marketplace-hero-slider {
        height: 260px;
        border-radius: 10px;
    }

    .marketplace-hero-fallback > div {
        padding: 28px;
    }

    .marketplace-shortcuts {
        margin-bottom: 22px;
        padding: 17px 8px;
    }

    .marketplace-shortcut-icon {
        width: 42px;
        height: 42px;
        font-size: 20px;
    }

    .marketplace-flash-heading {
        align-items: flex-start;
        flex-direction: column;
        gap: 5px;
    }

    .marketplace-flash-heading h2 {
        font-size: 18px;
    }

    .marketplace-section-header {
        min-height: 84px;
        padding: 12px 14px;
    }

    .marketplace-flash-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 14px;
        padding: 14px;
    }

    .marketplace-flash-card:nth-child(n + 5) {
        display: block;
    }

    .marketplace-section-heading {
        padding: 16px 14px 13px;
    }

    .marketplace-section-heading h2 {
        font-size: 18px;
    }

    .marketplace-section-heading > a {
        font-size: 11px;
    }

    .marketplace-recommended-section .products-wrapper-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
        padding: 0 10px;
    }

    .marketplace-product-carousel {
        padding-right: 5px;
        padding-left: 5px;
    }

    .marketplace-product-carousel .carousel-box {
        padding-right: 5px;
        padding-left: 5px;
    }

    .marketplace-product-card {
        min-height: 315px;
        border-radius: 10px;
    }

    .marketplace-product-media img {
        padding: 8px;
    }

    .marketplace-product-content {
        padding: 10px;
    }

    .marketplace-product-content h3 {
        height: 38px;
        font-size: 12px;
    }

    .marketplace-product-price strong {
        font-size: 14px;
    }

    .marketplace-add-button {
        width: 34px;
        height: 34px;
        flex-basis: 34px;
        font-size: 17px;
    }
}

@media (max-width: 479.98px) {
    .marketplace-hero-slider {
        height: 210px;
    }

    .marketplace-hero-grid {
        min-height: 210px;
    }

    .marketplace-hero-fallback h1 {
        margin-bottom: 16px;
        font-size: 24px;
    }

    .marketplace-shortcuts strong {
        font-size: 10px;
    }

    .marketplace-product-card {
        min-height: 290px;
    }
}
