.home-top {
    margin-top: 20px;
}

@media (min-width: 1200px) {
    .home-top > .row {
        align-items: stretch !important;
    }

    .home-top .home-category {
        height: 100%;
    }

    .home-top > .row > .col-xl-8 {
        position: relative;
    }

    .home-top > .row > .col-xl-8 > .widget-banner {
        position: absolute;
        inset: 0 calc(var(--bs-gutter-x) * .5);
        width: auto;
        height: 100%;
    }

    .home-top .widget-banner__viewport,
    .home-top .widget-banner__item,
    .home-top .widget-banner__image {
        height: 100%;
    }
}

.home-category,
.home-user-card,
.home-notice {
    background: #fff;
    border: 1px solid var(--zz-border);
    border-radius: var(--zz-radius-md);
    padding: 14px;
    box-shadow: var(--zz-shadow-sm);
}

.home-block-title {
    position: relative;
    padding-left: 10px;
    font-size: 18px;
    font-weight: 800;
    color: var(--zz-text-main);
    margin-bottom: 12px;
}

.home-block-title::before {
    content: "";
    position: absolute;
    left: 0;
    top: 4px;
    width: 3px;
    height: 19px;
    border-radius: 3px;
    background: var(--zz-primary);
}

.home-category__list {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.home-category__group {
    position: static;
}

.home-category {
    position: relative;
    z-index: 20;
}

.home-category__trigger {
    display: flex;
    gap: 8px;
    min-height: 42px;
    padding: 0 10px;
    align-items: center;
    justify-content: space-between;
    border-radius: var(--zz-radius-sm);
    color: var(--zz-text-main);
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    list-style: none;
}

.home-category__trigger > span:first-child {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.home-category__trigger::-webkit-details-marker {
    display: none;
}

.home-category__group:hover .home-category__trigger,
.home-category__group:focus-within .home-category__trigger,
.home-category__group[open] .home-category__trigger {
    color: var(--zz-primary);
    background: var(--zz-primary-soft);
}

.home-category__arrow {
    flex: 0 0 auto;
    color: var(--zz-text-light);
    font-size: 20px;
    transition: transform 0.2s ease;
}

.home-category__group[open] .home-category__arrow {
    transform: rotate(90deg);
}

.home-category__panel {
    position: absolute;
    top: 0;
    left: calc(100% - 1px);
    z-index: 50;
    width: 620px;
    min-height: 100%;
    max-height: min(480px, calc(100vh - 160px));
    padding: 22px;
    overflow-y: auto;
    visibility: hidden;
    border: 1px solid var(--zz-border);
    border-radius: 0 var(--zz-radius-md) var(--zz-radius-md) 0;
    background: #fff;
    box-shadow: var(--zz-shadow-md);
    opacity: 0;
    pointer-events: none;
    transform: translateX(6px);
    transition: opacity 0.16s ease, transform 0.16s ease, visibility 0.16s ease;
}

.home-category__group:hover .home-category__panel,
.home-category__group:focus-within .home-category__panel,
.home-category__group[open] .home-category__panel {
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
    transform: translateX(0);
}

.home-category__panel-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--zz-border);
}

.home-category__panel-header > div:first-child {
    min-width: 0;
}

.home-category__panel-label {
    color: var(--zz-text-secondary);
    font-size: 12px;
}

.home-category__panel-title {
    margin: 3px 0 0;
    color: var(--zz-text-main);
    font-size: 20px;
    font-weight: 800;
}

.home-category__all {
    flex: 0 0 auto;
    margin-left: 16px;
    color: var(--zz-primary);
    font-size: 13px;
    white-space: nowrap;
}

.home-category__children {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px 18px;
    padding-top: 16px;
}

.home-category__children a {
    min-width: 0;
    padding: 7px 8px;
    overflow: hidden;
    border-radius: var(--zz-radius-sm);
    color: var(--zz-text-body);
    font-size: 13px;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.home-category__children a:hover {
    color: var(--zz-primary);
    background: var(--zz-primary-soft);
}

.home-category__empty {
    padding: 30px 0;
    color: var(--zz-text-light);
    font-size: 13px;
    text-align: center;
}

.home-side {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.home-user-avatar {
    width: 40px;
    height: 40px;
    min-width: 40px;
    min-height: 40px;
    max-width: 40px;
    max-height: 40px;
    aspect-ratio: 1;
    border-radius: 50%;
    background: var(--zz-primary, #1E5BB8);
    color: #FFFFFF;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 900;
    line-height: 1;
    flex: 0 0 40px;
    overflow: hidden;
    border: 2px solid #FFFFFF;
    outline: 1px solid var(--zz-border, #E5E7EB);
    box-shadow: 0 3px 10px rgba(31, 41, 55, 0.14);
    box-sizing: border-box;
    user-select: none;
}

.home-user-avatar__image,
.home-user-avatar img {
    width: 100%;
    height: 100%;
    min-width: 100%;
    min-height: 100%;
    max-width: none;
    display: block;
    aspect-ratio: 1;
    object-fit: cover;
    object-position: center;
    border-radius: inherit;
}

.home-user-name {
    color: var(--zz-text-main, #1F2937);
    font-size: 14px;
    font-weight: 800;
    line-height: 1.3;
    max-width: 150px;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.home-user-role {
    color: var(--zz-text-secondary, #6B7280);
    font-size: 12px;
    line-height: 1.4;
}

.home-notice__list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.home-notice__list a,
.home-notice__list span {
    display: block;
    color: var(--zz-text-body);
    font-size: 13px;
    line-height: 1.6;
    padding: 4px 0;
}

.home-notice__list a:hover,
.home-notice__list a:focus-visible {
    color: var(--zz-primary);
}

.home-notice__empty {
    color: var(--zz-text-light);
    font-size: 13px;
    line-height: 1.5;
}

.home-floor {
    margin-top: 36px;
}

.home-floor__header {
    margin-bottom: 14px;
}

.floor-tabs {
    background: #fff;
    border: 1px solid var(--zz-border);
    border-radius: var(--zz-radius-md);
    padding: 12px;
    min-height: 300px;
    box-shadow: var(--zz-shadow-sm);
}

.floor-tabs a {
    display: block;
    height: 36px;
    line-height: 36px;
    border-radius: var(--zz-radius-sm);
    text-align: center;
    font-size: 13px;
    color: var(--zz-text-body);
    margin-bottom: 8px;
}

.floor-tabs a:hover {
    color: var(--zz-primary);
    background: var(--zz-primary-soft);
}

.floor-tabs a.active {
    background: var(--zz-primary);
    color: #fff;
}

.goods-card {
    position: relative;
    background: #fff;
    border: 1px solid var(--zz-border);
    border-radius: var(--zz-radius-md);
    overflow: hidden;
    height: 100%;
    transition: all 0.22s ease;
}

.goods-card__badge {
    position: absolute;
    top: 0;
    left: 0;
    z-index: 2;
    padding: 4px 10px;
    border-bottom-right-radius: 8px;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    line-height: 1.4;
}

.goods-card__badge--recommend {
    background: #f59e0b;
}

.goods-card__badge--new {
    background: var(--zz-primary);
}

.goods-card__badge--hot {
    background: #ef4444;
}

.goods-card:hover {
    border-color: var(--zz-primary);
    box-shadow: var(--zz-shadow-md);
    transform: translateY(-2px);
}

.goods-card__image {
    height: 145px;
    background: var(--zz-bg-soft);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--zz-text-light);
    font-size: 13px;
}

.goods-card__body {
    padding: 12px;
}

.goods-card__title {
    display: block;
    min-height: 40px;
    color: var(--zz-text-main);
    font-size: 14px;
    font-weight: 700;
    line-height: 1.45;
    margin-bottom: 6px;
}

.goods-card__title:hover {
    color: var(--zz-primary);
}

.goods-card__desc {
    height: 36px;
    overflow: hidden;
    color: var(--zz-text-secondary);
    font-size: 12px;
    line-height: 1.5;
    margin-bottom: 8px;
}

.cert-supplier {
    background: #fff;
    border: 1px solid var(--zz-cert-border);
    border-radius: var(--zz-radius-md);
    overflow: hidden;
    min-height: 300px;
    box-shadow: var(--zz-shadow-sm);
}

.cert-supplier__title {
    height: 42px;
    line-height: 42px;
    padding: 0 14px;
    background: var(--zz-cert-bg);
    color: var(--zz-cert-text);
    font-size: 15px;
    font-weight: 800;
    border-bottom: 1px solid #F2D675;
}

.cert-supplier__list {
    padding: 12px;
}

.cert-supplier__item {
    display: flex;
    gap: 10px;
    padding: 10px 0;
    border-bottom: 1px solid var(--zz-bg-soft);
}

.cert-supplier__item:last-child {
    border-bottom: none;
}

.cert-supplier__logo {
    width: 44px;
    height: 44px;
    flex: 0 0 44px;
    border-radius: var(--zz-radius-sm);
    background: var(--zz-bg-soft);
    color: var(--zz-text-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
}

.cert-supplier__name {
    color: var(--zz-text-main);
    font-size: 13px;
    font-weight: 700;
    line-height: 1.4;
}

@media (max-width: 991.98px) {
    .home-category__panel {
        position: static;
        display: none;
        width: auto;
        min-height: 0;
        max-height: none;
        margin-top: 4px;
        padding: 14px;
        visibility: visible;
        border-radius: var(--zz-radius-sm);
        box-shadow: none;
        opacity: 1;
        pointer-events: auto;
        transform: none;
    }

    .home-category__group:hover .home-category__panel,
    .home-category__group:focus-within .home-category__panel {
        display: none;
    }

    .home-category__group[open] .home-category__panel,
    .home-category__group[open]:focus-within .home-category__panel {
        display: block;
    }

    .home-category__children {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .floor-tabs {
        min-height: auto;
    }
}

@media (prefers-reduced-motion: reduce) {
    .home-category__arrow,
    .home-category__panel {
        transition: none;
    }
}
