/* 板塊背景色帶、SVG 波浪過渡與背景裝飾。
   板塊位於 1100px 的 .container 內，色帶與裝飾以 100vw 滿版延伸（html/body 已 overflow-x: hidden）。 */
:root {
    --band-white: #ffffff;
    --band-tint: #f1eeea;
    --band-accent: #cd0000;
    --wave-height: clamp(48px, 7vw, 110px);
}

/* ---------- 板塊色帶 ---------- */
.band {
    position: relative;
    isolation: isolate;
}

.band--tint {
    margin-top: 0;
    margin-bottom: 0;
}

.band--tint::before {
    content: "";
    position: absolute;
    z-index: -2;
    top: 0;
    bottom: 0;
    left: 50%;
    width: 100vw;
    transform: translateX(-50%);
    background: var(--band-tint);
    pointer-events: none;
}

/* ---------- 板塊之間的波浪過渡 ---------- */
/* 上方路徑填入上一個板塊的顏色，div 底色為下一個板塊的顏色。 */
.wave {
    display: block;
    position: relative;
    width: 100vw;
    height: var(--wave-height);
    margin-left: calc(50% - 50vw);
    background: var(--wave-to);
    line-height: 0;
    pointer-events: none;
}

.wave svg {
    display: block;
    width: 100%;
    height: 100%;
}

.wave path {
    fill: var(--wave-from);
}

.wave .wave__back {
    opacity: 0.45;
}

.wave--flip svg {
    transform: scaleX(-1);
}

.wave--to-tint {
    --wave-from: var(--band-white);
    --wave-to: var(--band-tint);
}

.wave--to-white {
    --wave-from: var(--band-tint);
    --wave-to: var(--band-white);
}

/* ---------- 首屏底部波浪 ---------- */
.hero {
    position: relative;
}

.hero-wave {
    position: absolute;
    left: -15px; /* 蓋過 .hero 左側 15px 紅色邊框 */
    bottom: -1px;
    width: calc(100% + 15px);
    height: var(--wave-height);
    pointer-events: none;
}

.hero-wave path {
    fill: var(--band-white);
}

.hero-wave .wave__back {
    opacity: 0.5;
}

/* ---------- 背景裝飾 ---------- */
.deco {
    position: absolute;
    z-index: -1;
    pointer-events: none;
    overflow: visible;
}

.deco path,
.deco circle {
    fill: none;
    vector-effect: non-scaling-stroke;
}

/* 滿版大圓弧 */
.deco--arc {
    left: 50%;
    width: 100vw;
    transform: translateX(-50%);
    top: 0;
    height: min(320px, 70%);
}

.deco--arc path {
    stroke: var(--band-accent);
    stroke-opacity: 0.12;
    stroke-width: 10;
}

.deco--arc-white path {
    stroke: #ffffff;
    stroke-opacity: 1;
    stroke-width: 14;
}

/* 等高線般的多條波浪線 */
.deco--contours {
    width: min(560px, 60vw);
    height: auto;
    /* 讓線條靠內側的一端淡出，不會在畫面中間突然截斷 */
    -webkit-mask-image: linear-gradient(to right, transparent, #000 55%);
    mask-image: linear-gradient(to right, transparent, #000 55%);
}

.deco--contours path {
    stroke: var(--band-accent);
    stroke-opacity: 0.1;
    stroke-width: 1.5;
}

.deco--bottom-right {
    right: calc(50% - 50vw);
    bottom: 0;
}

.deco--top-left {
    left: calc(50% - 50vw);
    top: 0;
    transform: scale(-1, -1);
}

/* 半出畫面的同心圓 */
.deco--rings {
    width: clamp(260px, 32vw, 440px);
    height: auto;
    top: 40px;
}

.deco--rings .ring-outline {
    stroke: var(--band-accent);
    stroke-opacity: 0.12;
    stroke-width: 2;
}

.deco--rings .ring-fill {
    fill: var(--band-tint);
}

.band--tint .deco--rings .ring-fill {
    fill: #ffffff;
    fill-opacity: 0.7;
}

.deco--right {
    right: calc(50% - 50vw - clamp(90px, 10vw, 150px));
}

.deco--left {
    left: calc(50% - 50vw - clamp(90px, 10vw, 150px));
}

@media (max-width: 768px) {
    .deco--arc {
        height: 200px;
    }

    .deco--rings {
        opacity: 0.6;
    }
}
