/* Car of the Day — Banner Zone (wide & short).
 *
 * Same idea as the main zone, scaled down for a banner-top/bottom
 * strip: yellow car idling on a horizontal road (asphalt with
 * scrolling dashes + passing scenery blocks), photo as the right-cell
 * background, theme accent driving the cell border and truck hue. */

.cars-banner-wrap {
    width: 100cqw;
    height: 100cqh;
    container-type: size;
    display: flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    overflow: hidden;
    position: relative;
    color: var(--text);
    font-family: 'Geist Mono', 'Roboto Mono', monospace;
    background: #2a2a2a;
}

/* Scenery strips at top and bottom of the slide. */
.cars-banner-scenery {
    position: absolute;
    left: 0;
    right: 0;
    height: 5%;
    background:
        repeating-linear-gradient(
            to right,
            #d9b300 0,
            #d9b300 14cqw,
            #2e2e2e 14cqw,
            #2e2e2e 28cqw,
            #f5c400 28cqw,
            #f5c400 42cqw,
            #1a1a1a 42cqw,
            #1a1a1a 56cqw
        );
    background-size: 56cqw 100%;
    animation: cars-banner-scenery-scroll 3s linear infinite;
    pointer-events: none;
    z-index: 0;
}

.cars-banner-scenery-top    { top: 0; }
.cars-banner-scenery-bottom { bottom: 0; }

@keyframes cars-banner-scenery-scroll {
    from { background-position: 0 0; }
    to   { background-position: 56cqw 0; }
}

/* Asphalt road — thinner band centered vertically. */
.cars-banner-road {
    position: absolute;
    left: 0;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    height: 90%;
    background:
        linear-gradient(to bottom, #5a5a5a, #4a4a4a 50%, #5a5a5a);
    border-top: 0.5cqh solid #f5f5f5;
    border-bottom: 0.5cqh solid #f5f5f5;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

/* Dashed white center line, scrolling left→right. */
.cars-banner-dashes {
    position: absolute;
    left: -10%;
    top: 50%;
    height: 4cqh;
    width: 200%;
    transform: translateY(-50%);
    background: repeating-linear-gradient(
        to right,
        #f5f5f5 0,
        #f5f5f5 8cqw,
        transparent 8cqw,
        transparent 14cqw
    );
    animation: cars-banner-road-scroll 1.5s linear infinite;
}

@keyframes cars-banner-road-scroll {
    from { transform: translateY(-50%) translateX(-14cqw); }
    to   { transform: translateY(-50%) translateX(0); }
}

/* Paper holds the two halves (yellow car + photo cell). Transparent
 * so the road shows behind the truck. */
.cars-banner-paper {
    position: relative;
    z-index: 1;
    width: 90%;
    height: 80%;
    display: flex;
    align-items: stretch;
    background: transparent;
    box-sizing: border-box;
    overflow: visible;
}

.cars-banner-left {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    box-sizing: border-box;
    position: relative;
    z-index: 1;
}

.cars-banner-wrap .cars-banner-yallowcar {
    height: 80cqh;
    width: auto;
    max-width: none;
    max-height: none;
    display: block;
    animation: cars-banner-truck-shake 1s ease-in-out infinite;
    transform-origin: center;
}

@keyframes cars-banner-truck-shake {
    0%, 100% { transform: translate(0, 0) rotate(0); }
    20%      { transform: translate(0, -2px) rotate(-0.3deg); }
    40%      { transform: translate(0, 1.5px) rotate(0.3deg); }
    60%      { transform: translate(0, -1.5px) rotate(-0.2deg); }
    80%      { transform: translate(0, 1.5px) rotate(0.2deg); }
}

/* Right cell — photo as background, themed border + inner ring,
 * line-by-line dark text on top. */
.cars-banner-right {
    flex: 1 1 auto;
    display: flex;
    align-items: stretch;
    justify-content: stretch;
    min-width: 0;
    background: #FFF center / cover no-repeat;
    border: 2cqmin inset var(--text);
    border-radius: 4cqmin;
    box-shadow: inset 0 0 0 0.8cqmin var(--bg);
    position: relative;
    z-index: 1;
}

.cars-banner-wrap .cars-banner-right img {
    max-width: none;
    max-height: none;
}

.cars-banner-cell {
    width: 100%;
    height: 100%;
    padding: 1cqmin 2.5cqw;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    color: var(--text);
    overflow: hidden;
}

/* Line-by-line dark highlight on text pills. */
.cars-banner-wrap .cars-banner-header,
.cars-banner-wrap .cars-banner-headline,
.cars-banner-wrap .cars-banner-text {
    display: inline;
    box-decoration-break: clone;
    -webkit-box-decoration-break: clone;
    background-color: color-mix(in srgb, var(--text) 75%, transparent);
    padding: 0.1em 0.4em;
}

.cars-banner-wrap .cars-banner-body {
    font-size: inherit;
    line-height: 1.35;
    font-family: 'Georgia', serif;
    text-align: start;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
}

.cars-banner-wrap .cars-banner-body > * {
    margin-bottom: 0.25em;
}

.cars-banner-wrap .cars-banner-header {
    font-family: 'Geist Mono', 'Roboto Mono', monospace;
    font-size: 0.7em;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.25em;
    color: #fff;
    opacity: 0.85;
    line-height: 1.6;
    text-shadow: 0 0.2cqmin 0.5cqmin rgba(0, 0, 0, 0.7);
}

.cars-banner-wrap .cars-banner-headline {
    font-family: 'Cormorant Garamond', 'Georgia', serif;
    font-size: 1.7em;
    font-weight: 700;
    line-height: 1.5;
    color: #fff;
    letter-spacing: -0.005em;
    text-shadow: 0 0.2cqmin 0.5cqmin rgba(0, 0, 0, 0.6);
}

.cars-banner-wrap .cars-banner-text {
    font-family: 'Georgia', serif;
    font-size: 1em;
    line-height: 1.7;
    color: #fff;
    text-shadow: 0 0.2cqmin 0.5cqmin rgba(0, 0, 0, 0.7);
    white-space: nowrap;
}
