Global border-box collapsed the banner's height:0 + padding-bottom aspect box to zero, so slides rendered but took no space. Prefer aspect-ratio (with content-box fallback) and make .new-swiper honor data-swiper-config so autoplay/loop/navigation from templates apply.
501 lines
11 KiB
CSS
501 lines
11 KiB
CSS
/* Search keywords row */
|
|
.header-components-search__keywords {
|
|
display: flex;
|
|
flex-wrap: wrap;
|
|
gap: 6px;
|
|
margin-top: 10px;
|
|
justify-content: center;
|
|
}
|
|
|
|
.header-components-search__kw-tag {
|
|
display: inline-block;
|
|
padding: 3px 10px;
|
|
font-size: 12px;
|
|
line-height: 1.4;
|
|
border-radius: 100px;
|
|
background: rgba(255, 255, 255, 0.2);
|
|
backdrop-filter: blur(6px);
|
|
color: inherit;
|
|
text-decoration: none;
|
|
transition: background 0.2s;
|
|
}
|
|
|
|
.header-components-search__kw-tag:hover {
|
|
background: rgba(255, 255, 255, 0.4);
|
|
}
|
|
|
|
@media (max-width: 991px) {
|
|
.header-components {
|
|
height: var(--pc-height);
|
|
}
|
|
|
|
.header-components-search {
|
|
top: calc(50% + 44px);
|
|
max-width: 560px;
|
|
}
|
|
}
|
|
|
|
@media (max-width: 767px) {
|
|
.header-components {
|
|
height: var(--m-height);
|
|
}
|
|
|
|
.header-components__content.slide-text {
|
|
width: calc(100% - 28px);
|
|
max-width: 480px;
|
|
top: 40%;
|
|
padding-top: 0;
|
|
}
|
|
|
|
.header-components__content.slide-text .slide-title {
|
|
font-size: clamp(1.25rem, 5vw, 1.75rem);
|
|
margin-bottom: 10px;
|
|
}
|
|
|
|
.header-components__content[style*="--hero-text-size-m"] .slide-title {
|
|
font-size: var(--hero-text-size-m);
|
|
}
|
|
|
|
.header-components__content.slide-text .slide-desc {
|
|
font-size: 0.875rem;
|
|
line-height: 1.5;
|
|
}
|
|
|
|
.header-components-search {
|
|
top: calc(50% + 20px);
|
|
width: calc(100% - 24px);
|
|
max-width: 420px;
|
|
padding: 0 12px;
|
|
font-size: 12px;
|
|
}
|
|
|
|
.card-1 .header-components-search,
|
|
.card-2 .header-components-search {
|
|
top: calc(50% + 46px);
|
|
}
|
|
|
|
.card-5 .header-components-search,
|
|
.card-6 .header-components-search {
|
|
top: calc(50% - 22px);
|
|
}
|
|
|
|
.card-7 .header-components-search,
|
|
.card-8 .header-components-search {
|
|
top: calc(50% - 52px);
|
|
}
|
|
|
|
.header-components-search .line-form {
|
|
font-size: 14px;
|
|
padding: 4px 12px;
|
|
}
|
|
|
|
.header-components-search .scale-placeholder.is-focus,
|
|
.header-components-search .line-form-input:focus ~ .scale-placeholder {
|
|
transform: translateY(-32px);
|
|
font-size: 12px;
|
|
color: #fff;
|
|
}
|
|
|
|
.header-components-card {
|
|
margin-top: -35px;
|
|
}
|
|
|
|
.header-components-card__container {
|
|
padding: 0 10px;
|
|
}
|
|
|
|
.header-components-card__row {
|
|
flex-wrap: wrap;
|
|
gap: 6px;
|
|
}
|
|
|
|
.header-components-card__item {
|
|
flex: 0 0 calc(50% - 3px);
|
|
}
|
|
|
|
.header-components-card__item-bg {
|
|
padding: 8px 10px;
|
|
}
|
|
|
|
.header-components-card__wrap--shared {
|
|
padding: 6px;
|
|
}
|
|
|
|
.icon-cover-card {
|
|
gap: 6px;
|
|
padding: 4px;
|
|
min-height: 52px;
|
|
border-radius: 6px;
|
|
}
|
|
|
|
.icon-cover-icon {
|
|
width: 30px;
|
|
height: 30px;
|
|
min-width: 30px;
|
|
font-size: 14px;
|
|
}
|
|
|
|
.icon-cover-title {
|
|
font-size: 12px;
|
|
}
|
|
|
|
.icon-cover-subtitle {
|
|
display: none;
|
|
}
|
|
}
|
|
|
|
@media (max-width: 480px) {
|
|
.header-components {
|
|
height: var(--m-height);
|
|
}
|
|
|
|
.header-components__content.slide-text .slide-title {
|
|
font-size: clamp(1.1rem, 5.4vw, 1.4rem);
|
|
margin-bottom: 8px;
|
|
}
|
|
|
|
.header-components__content.slide-text .slide-desc {
|
|
font-size: 0.8125rem;
|
|
}
|
|
|
|
.header-components-search {
|
|
top: calc(50% + 26px);
|
|
width: calc(100% - 20px);
|
|
padding: 0 10px;
|
|
}
|
|
|
|
.card-5 .header-components-search,
|
|
.card-6 .header-components-search {
|
|
top: calc(50% - 12px);
|
|
}
|
|
|
|
.card-7 .header-components-search,
|
|
.card-8 .header-components-search {
|
|
top: calc(50% - 40px);
|
|
}
|
|
|
|
.header-components-search .search-input-text {
|
|
padding-right: 40px;
|
|
}
|
|
|
|
.header-components-search__submit {
|
|
width: 34px;
|
|
height: 34px;
|
|
}
|
|
}
|
|
|
|
.site-nav.nav-transparent {
|
|
background-color: transparent;
|
|
border-bottom-color: transparent;
|
|
color: #fff;
|
|
}
|
|
|
|
.site-nav.nav-transparent .site-brand,
|
|
.site-nav.nav-transparent .site-brand__name {
|
|
color: #fff;
|
|
}
|
|
|
|
.site-nav.nav-transparent .icon-btn {
|
|
color: rgba(255, 255, 255, 0.9);
|
|
}
|
|
|
|
.site-nav.nav-transparent .icon-btn:hover {
|
|
background: rgba(255, 255, 255, 0.15);
|
|
color: #fff;
|
|
}
|
|
|
|
.site-nav.nav-transparent ul.nav-desktop a {
|
|
color: rgba(255, 255, 255, 0.85);
|
|
}
|
|
|
|
.site-nav.nav-transparent ul.nav-desktop a:hover {
|
|
color: #fff;
|
|
background: rgba(255, 255, 255, 0.15);
|
|
}
|
|
|
|
.site-nav.nav-transparent ul.nav-desktop .current-menu-item > a,
|
|
.site-nav.nav-transparent ul.nav-desktop .current_page_item > a {
|
|
background: rgba(255, 255, 255, 0.2);
|
|
color: #fff;
|
|
}
|
|
|
|
.site-nav.nav-transparent .nav-auth .btn-outline {
|
|
border-color: rgba(255, 255, 255, 0.6);
|
|
color: #fff;
|
|
}
|
|
|
|
.site-nav.nav-transparent .nav-auth .btn-outline:hover {
|
|
background: rgba(255, 255, 255, 0.15);
|
|
border-color: #fff;
|
|
}
|
|
|
|
.site-nav.nav-transparent .nav-user__toggle {
|
|
border-color: rgba(255, 255, 255, 0.5);
|
|
}
|
|
|
|
/* 滚动后恢复实心 */
|
|
.site-nav.nav-transparent.is-scrolled {
|
|
background-color: var(--surface-page);
|
|
border-bottom-color: var(--color-line);
|
|
color: var(--color-ink);
|
|
}
|
|
|
|
.site-nav.nav-transparent.is-scrolled .site-brand,
|
|
.site-nav.nav-transparent.is-scrolled .site-brand__name {
|
|
color: var(--color-ink);
|
|
}
|
|
|
|
.site-nav.nav-transparent.is-scrolled .icon-btn {
|
|
color: var(--color-ink-3);
|
|
}
|
|
|
|
.site-nav.nav-transparent.is-scrolled ul.nav-desktop a {
|
|
color: var(--color-ink-3);
|
|
}
|
|
|
|
.site-nav.nav-transparent.is-scrolled .nav-auth .btn-outline {
|
|
border-color: var(--color-line);
|
|
color: var(--color-ink);
|
|
}
|
|
|
|
.site-nav.nav-transparent.is-scrolled .nav-user__toggle {
|
|
border-color: var(--color-line);
|
|
}
|
|
|
|
/* ============================================================
|
|
* Header Slider — Swiper Navigation & Pagination (Zibll-style)
|
|
* ============================================================ */
|
|
.header-components .swiper-button-prev,
|
|
.header-components .swiper-button-next {
|
|
width: 30px;
|
|
height: 40px;
|
|
color: #fff;
|
|
text-shadow: 0 0 6px #444;
|
|
opacity: 0;
|
|
transition: opacity 0.3s, background-color 0.3s;
|
|
z-index: 10;
|
|
}
|
|
|
|
.header-components .swiper-button-prev::after,
|
|
.header-components .swiper-button-next::after {
|
|
font-size: 16px;
|
|
font-weight: 700;
|
|
}
|
|
|
|
.header-slider:hover .swiper-button-prev,
|
|
.header-slider:hover .swiper-button-next {
|
|
opacity: 0.8;
|
|
}
|
|
|
|
.header-components .swiper-button-prev:hover,
|
|
.header-components .swiper-button-next:hover {
|
|
opacity: 1;
|
|
background-color: rgba(0, 0, 0, 0.3);
|
|
}
|
|
|
|
.header-components .swiper-pagination-bullet {
|
|
width: 10px;
|
|
height: 10px;
|
|
background: transparent;
|
|
border: 2px solid rgba(255, 255, 255, 0.6);
|
|
opacity: 0.7;
|
|
border-radius: 20px;
|
|
transition: 0.4s;
|
|
}
|
|
|
|
.header-components .swiper-pagination-bullet-active {
|
|
background: #fff;
|
|
border-color: #fff;
|
|
opacity: 1;
|
|
}
|
|
|
|
@media (max-width: 640px) {
|
|
.header-components .swiper-button-prev,
|
|
.header-components .swiper-button-next {
|
|
display: none;
|
|
}
|
|
}
|
|
|
|
/* ============================================================
|
|
* Banner Module — 1:1 Zibll (.s-desc / widget slider card)
|
|
* 圆角 = --main-radius,阴影 = main-shadow,文案底渐变条
|
|
* ============================================================ */
|
|
.banner-module {
|
|
position: relative;
|
|
width: 100%;
|
|
border-radius: var(--main-radius, var(--radius, 8px));
|
|
overflow: hidden;
|
|
box-shadow: 0 0 10px var(--main-shadow, rgba(116, 116, 116, 0.08));
|
|
margin-bottom: 20px;
|
|
background: var(--main-bg-color, var(--surface-1));
|
|
}
|
|
|
|
/*
|
|
* Aspect-ratio card height.
|
|
* Global reset uses box-sizing:border-box, so the classic
|
|
* height:0 + padding-bottom trick collapses to 0 unless we
|
|
* force content-box (or use aspect-ratio).
|
|
*/
|
|
.banner-module__swiper {
|
|
position: relative;
|
|
width: 100%;
|
|
height: auto;
|
|
aspect-ratio: 5 / 2; /* 40% */
|
|
overflow: hidden;
|
|
}
|
|
|
|
@supports not (aspect-ratio: 1 / 1) {
|
|
.banner-module__swiper {
|
|
height: 0;
|
|
padding-bottom: 40%;
|
|
box-sizing: content-box;
|
|
}
|
|
}
|
|
|
|
.banner-module__swiper .swiper-wrapper {
|
|
position: absolute;
|
|
inset: 0;
|
|
width: 100%;
|
|
height: 100% !important;
|
|
}
|
|
|
|
.banner-module__swiper .swiper-slide {
|
|
position: relative;
|
|
overflow: hidden;
|
|
cursor: pointer;
|
|
width: 100%;
|
|
height: 100% !important;
|
|
}
|
|
|
|
.banner-module__slide-bg {
|
|
position: absolute;
|
|
inset: 0;
|
|
width: 100%;
|
|
height: 100%;
|
|
}
|
|
|
|
.banner-module__slide-bg img,
|
|
.banner-module__slide-bg .fit-cover {
|
|
display: block;
|
|
width: 100%;
|
|
height: 100%;
|
|
max-width: none;
|
|
object-fit: cover;
|
|
border-radius: 0;
|
|
}
|
|
|
|
.banner-module__slide-fallback {
|
|
width: 100%;
|
|
height: 100%;
|
|
background: linear-gradient(135deg, var(--color-primary), var(--color-primary-active, var(--color-primary-dark)));
|
|
}
|
|
|
|
.banner-module__slide-overlay {
|
|
position: absolute;
|
|
left: 0;
|
|
right: 0;
|
|
bottom: 0;
|
|
top: auto;
|
|
height: 45%;
|
|
background: linear-gradient(0deg, rgba(0, 0, 0, 0.2), transparent);
|
|
pointer-events: none;
|
|
border-radius: 0 0 var(--main-radius, 8px) var(--main-radius, 8px);
|
|
z-index: 1;
|
|
}
|
|
|
|
.banner-module__content {
|
|
position: absolute;
|
|
bottom: 0;
|
|
left: 0;
|
|
right: 0;
|
|
z-index: 2;
|
|
color: #fff;
|
|
max-width: none;
|
|
padding: 1.8em 2.5em;
|
|
font-size: 16px;
|
|
text-shadow: 0 0 8px rgba(0, 0, 0, 0.3);
|
|
}
|
|
|
|
.banner-module__title {
|
|
font-family: var(--font-ui);
|
|
font-size: 16px;
|
|
font-weight: normal;
|
|
margin: 0 0 4px;
|
|
line-height: 1.4;
|
|
text-shadow: 0 0 8px rgba(0, 0, 0, 0.3);
|
|
}
|
|
|
|
.banner-module__subtitle {
|
|
font-size: 14px;
|
|
margin: 0;
|
|
opacity: 0.95;
|
|
line-height: 1.5;
|
|
text-shadow: 0 0 8px rgba(0, 0, 0, 0.3);
|
|
}
|
|
|
|
.banner-module .swiper-button-prev,
|
|
.banner-module .swiper-button-next {
|
|
width: 30px;
|
|
height: 40px;
|
|
border-radius: 0;
|
|
background: transparent;
|
|
color: #fff;
|
|
text-shadow: 0 0 6px #444;
|
|
opacity: 0;
|
|
pointer-events: none;
|
|
z-index: 10;
|
|
transition: opacity 0.3s, background-color 0.3s;
|
|
}
|
|
|
|
.banner-module .swiper-button-prev::after,
|
|
.banner-module .swiper-button-next::after {
|
|
font-size: 16px;
|
|
font-weight: 700;
|
|
}
|
|
|
|
.banner-module:hover .swiper-button-prev,
|
|
.banner-module:hover .swiper-button-next {
|
|
opacity: 0.8;
|
|
pointer-events: auto;
|
|
}
|
|
|
|
.banner-module .swiper-button-prev:hover,
|
|
.banner-module .swiper-button-next:hover {
|
|
opacity: 1;
|
|
background-color: rgba(0, 0, 0, 0.3);
|
|
transform: none;
|
|
}
|
|
|
|
@media (max-width: 767px) {
|
|
.banner-module {
|
|
border-radius: var(--main-radius, 8px);
|
|
}
|
|
|
|
.banner-module__swiper {
|
|
aspect-ratio: 2 / 1; /* 50% */
|
|
height: auto;
|
|
}
|
|
|
|
@supports not (aspect-ratio: 1 / 1) {
|
|
.banner-module__swiper {
|
|
height: 0;
|
|
padding-bottom: 50%;
|
|
box-sizing: content-box;
|
|
}
|
|
}
|
|
|
|
.banner-module__content {
|
|
padding: 1em 1.2em;
|
|
font-size: 14px;
|
|
}
|
|
|
|
.banner-module__title {
|
|
font-size: 14px;
|
|
}
|
|
|
|
.banner-module .swiper-button-prev,
|
|
.banner-module .swiper-button-next {
|
|
display: none;
|
|
}
|
|
}
|