/* ========================================
   CSS Reset & Base
   ======================================== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: "Source Han Sans CN", "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
    background-color: #FFFFFF;
    color: #333333;
    line-height: 1.5;
    min-width: 320px;
}

a {
    text-decoration: none;
    color: inherit;
}

button {
    border: none;
    background: none;
    cursor: pointer;
    font-family: inherit;
}

img {
    display: block;
    max-width: 100%;
    height: auto;
}

/* ========================================
   Page Layout
   ======================================== */
.page-wrapper {
    width: 100%;
    background-color: #FFFFFF;
}

.content-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 0;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* ========================================
   Title Section
   ======================================== */
.title-section {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 30px;
    height: 43px;
}

.title-decoration {
    position: relative;
    width: 309px;
    height: 11px;
    display: flex;
    align-items: flex-end;
}

.deco-line {
    width: 306px;
    height: 1px;
    background: linear-gradient(90deg, rgba(31, 109, 232, 0) 0%, #1f6de8 100%);
    position: absolute;
    bottom: 0;
    left: 0;
}

.deco-chevron {
    position: absolute;
    width: 19px;
    height: 7px;
    background-color: #1f6de8;
    clip-path: polygon(21% 0%, 100% 0%, 79% 100%, 0% 100%);
}

.title-decoration-left .chevron-1 {
    right: 4px;
    bottom: 2px;
    opacity: 0.36;
}

.title-decoration-left .chevron-2 {
    right: -1px;
}

.title-decoration-right {
    transform: scaleX(-1);
}

.title-decoration-right .chevron-1 {
    right: 4px;
    bottom: 2px;
    opacity: 0.36;
}

.title-decoration-right .chevron-2 {
    right: -1px;
}

.title-text {
    font-size: 30px;
    font-weight: 700;
    color: #333333;
    line-height: 1;
    text-align: center;
    letter-spacing: 0;
}

/* ========================================
   Login Cards Section
   ======================================== */
.login-section {
    display: flex;
    gap: 24px;
    width: 100%;
}

.login-card {
    position: relative;
    width: 384px;
    height: 116px;
    border-radius: 4px;
    background-color: #eff4ff;
    overflow: hidden;
    display: flex;
    align-items: center;
    padding-left: 24px;
    flex-shrink: 0;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
    border: 1px solid #e0e0e0;
}

.login-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(31, 109, 232, 0.15);
    border: 2px solid #1f6de8;
}

.login-card:hover .card-title-pic {
    color: #1f6de8;
}

.login-card-primary {
    border: 2px solid #1f6de8;
}

.login-card-default {
    border: 1px solid #e0e0e0;
}

.card-bg {
    position: absolute;
    top: 0;
    right: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.card-bg img {
    position: absolute;
    top: 0;
    right: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.card-title-pic {
    position: relative;
    z-index: 1;
    font-size: 16px;
    font-weight: 700;
    color: #000000;
    line-height: 1.5;
    transition: color 0.25s ease;
}

.login-card-primary .card-title-pic {
    font-size: 18px;
    color: #1f6de8;
    line-height: 1.333;
}

/* ========================================
   Brand Carousel Section
   ======================================== */
.brand-section {
    position: relative;
    width: 100%;
    height: 210px;
    border-radius: 4px;
    background-color: #eef2fb;
    overflow: hidden;
    display: flex;
}

/* Supplier Banner (Left) */
.supplier-banner {
    position: relative;
    width: 148px;
    height: 100%;
    flex-shrink: 0;
    overflow: hidden;
}

.banner-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;;
}

.banner-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

 .banner-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 148px;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.15);
    pointer-events: none;
    z-index: 1;
}

.banner-decor {
    position: absolute;
    left: 58px;
    top: 111px;
    width: 94px;
    height: 103px;
    opacity: 0.3;
    pointer-events: none;
}

.banner-decor img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.banner-content {
    position: absolute;
    top: 13px;
    left: 14px;
    display: flex;
    flex-direction: column;
    gap: 11px;
    z-index: 2;
}

.banner-title {
    font-size: 22px;
    font-weight: 700;
    color: #ffffff;
    line-height: 1;
}

.banner-divider {
    width: 31px;
    height: 3px;
    background-color: #ffffff;
    border-radius: 1.5px;
}

.banner-tags {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.banner-tags span {
    font-size: 14px;
    font-weight: 400;
    color: #374e6d;
    line-height: 1.286;
}

.banner-btn {
    position: absolute;
    bottom: 39px;
    left: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    height: 30px;
    padding: 0 12px;
    border-radius: 15px;
    background-color: #1f6de8;
    color: #ffffff;
    font-size: 14px;
    font-weight: 400;
    line-height: 1;
    z-index: 2;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.banner-btn:hover {
    background-color: #1958c0;
    transform: translateX(2px);
}

/* Carousel Wrapper */
.carousel-wrapper {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 10px 16px;
    min-width: 0;
}

.carousel-arrow {
    flex-shrink: 0;
    width: 16px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #d7e2f2;
    border-radius: 2px;
    transition: background-color 0.2s ease;
}

.carousel-arrow:hover {
    background-color: #c2d3ec;
}

.carousel-arrow svg {
    display: block;
}

.carousel-viewport {
    flex: 1;
    overflow: hidden;
    min-width: 0;
    padding-top: 3px;
    margin-top: -3px;
}

.carousel-track {
    display: flex;
    gap: 16px;
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Brand Cards */
.brand-card {
    flex-shrink: 0;
    width: 178px;
    height: 160px;
    border-radius: 4px;
    background-color: #ffffff;
    padding: 10px 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    transition: transform 0.25s ease, box-shadow 0.25s ease, outline-color 0.25s ease;
    cursor: pointer;
    outline: 1px solid transparent;
    outline-offset: -1px;
}

.brand-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
    outline: 1px solid #1f6de8;
}

.brand-card-active {
    outline: 1px solid #1f6de8;
}

.brand-img-wrap {
    width: 150px;
    height: 83px;
    background-color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-radius: 2px;
}

.brand-img-wrap img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.brand-info {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    text-align: center;
}

.brand-name {
    font-size: 14px;
    font-weight: 700;
    color: #333333;
    line-height: 1.286;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

.brand-slogan {
    font-size: 13px;
    font-weight: 400;
    color: #999999;
    line-height: 1.846;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

/* More Button */
.more-btn {
    position: absolute;
    top: 0;
    right: 0;
    width: 49px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(136deg, #438df9 0%, #206de9 100%);
    border-radius: 0 4px 0 15px;
    color: #ffffff;
    font-size: 14px;
    font-weight: 400;
    line-height: 1;
    z-index: 3;
    transition: opacity 0.2s ease;
}

.more-btn:hover {
    opacity: 0.9;
}

.more-btn-text {
    margin-left: -4px;
}

/* ========================================
   Responsive Design
   ======================================== */

/* Tablet: 768px - 1199px */
@media screen and (max-width: 1199px) {
    .content-container {
        padding: 32px 24px;
        gap: 20px;
    }

    .title-decoration {
        width: 200px;
    }

    .deco-line {
        width: 197px;
    }

    .login-section {
        flex-wrap: wrap;
        justify-content: center;
    }

    .login-card {
        width: calc(50% - 12px);
    }

    .brand-section {
        height: auto;
        flex-direction: column;
    }

    .supplier-banner {
        width: 100%;
        height: 120px;
    }

    .banner-bg {
        width: 100%;
        height: 100%;
    }

    .banner-bg img {
        object-position: center top;
    }

    .banner-decor {
        width: 80px;
        height: 88px;
    }

    .banner-content {
        top: 16px;
        left: 20px;
        gap: 8px;
    }

    .banner-tags {
        flex-direction: row;
        gap: 12px;
    }

    .banner-btn {
        bottom: auto;
        top: 16px;
        right: 20px;
        left: auto;
    }

    .carousel-wrapper {
        padding: 16px;
    }

    .brand-card {
        width: 160px;
    }
}

/* Mobile: < 768px */
@media screen and (max-width: 767px) {
    .content-container {
        padding: 24px 16px;
        gap: 16px;
    }

    .title-section {
        gap: 16px;
        height: auto;
    }

    .title-decoration {
        width: 60px;
    }

    .deco-line {
        width: 57px;
    }

    .deco-chevron {
        display: none;
    }

    .title-text {
        font-size: 24px;
    }

    .login-section {
        flex-direction: column;
        gap: 12px;
    }

    .login-card {
        width: 100%;
        height: 96px;
        padding-left: 20px;
    }

    .login-card-primary .card-title-pic {
        font-size: 16px;
    }

    .login-card-default .card-title-pic {
        font-size: 15px;
    }

    .brand-section {
        border-radius: 8px;
    }

    .supplier-banner {
        height: 100px;
    }

    .banner-title {
        font-size: 18px;
    }

    .banner-tags span {
        font-size: 12px;
    }

    .banner-btn {
        height: 26px;
        padding: 0 10px;
        font-size: 12px;
    }

    .carousel-wrapper {
        padding: 12px;
        gap: 8px;
    }

    .carousel-arrow {
        width: 28px;
        height: 28px;
        border-radius: 50%;
    }

    .brand-card {
        width: 140px;
        height: 140px;
        padding: 8px;
    }

    .brand-img-wrap {
        width: 120px;
        height: 66px;
    }

    .brand-name {
        font-size: 12px;
    }

    .brand-slogan {
        font-size: 11px;
    }

    .more-btn {
        width: 44px;
        height: 26px;
        font-size: 12px;
        border-radius: 0 4px 0 12px;
    }
}

/* Small Mobile: < 480px */
@media screen and (max-width: 479px) {
    .title-section {
        gap: 12px;
    }

    .title-text {
        font-size: 20px;
    }

    .title-decoration {
        width: 40px;
    }

    .deco-line {
        width: 37px;
    }

    .login-card {
        height: 88px;
    }

    .brand-card {
        width: 120px;
        height: 128px;
    }

    .brand-img-wrap {
        width: 100px;
        height: 55px;
    }

    .carousel-wrapper {
        gap: 6px;
        padding: 10px 8px;
    }

    .carousel-arrow {
        width: 24px;
        height: 24px;
    }
}

/* ========================================
   Utility / Animation
   ======================================== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.page-wrapper {
    animation: fadeInUp 0.5s ease-out;
}
