body.template-catalog-wall {
    background: #080808;
}

.catalog-wall-app {
    position: relative;
    overflow: hidden;
    background: #080808;
    display: grid;
    place-items: center;
    isolation: isolate;
    filter: none !important;
}

/* =========================================================
   ADMIN MODE 1: FULL-COLOUR RUNNING RELEASE CATALOG
   ========================================================= */
.catalog-motion {
    position: absolute;
    inset: -3%;
    display: flex;
    flex-direction: column;
    gap: 7px;
    transform: rotate(-1.4deg) scale(1.045);
    background: #080808;
}

.catalog-motion-row {
    min-height: 0;
    flex: 1 1 0;
    overflow: hidden;
}

.catalog-motion-track {
    width: max-content;
    height: 100%;
    display: flex;
    gap: 7px;
    will-change: transform;
    animation-name: catalogMoveLeft;
    animation-duration: 84s;
    animation-timing-function: linear;
    animation-iteration-count: infinite;
}

.catalog-motion-row:nth-child(even) .catalog-motion-track {
    animation-name: catalogMoveRight;
}

.catalog-speed-slow .catalog-motion-track {
    animation-duration: 128s;
}

.catalog-speed-fast .catalog-motion-track {
    animation-duration: 52s;
}

.catalog-motion-row:nth-child(2) .catalog-motion-track {
    animation-delay: -18s;
}

.catalog-motion-row:nth-child(3) .catalog-motion-track {
    animation-delay: -37s;
}

.catalog-motion-row:nth-child(4) .catalog-motion-track {
    animation-delay: -9s;
}

.catalog-motion-row:nth-child(5) .catalog-motion-track {
    animation-delay: -29s;
}

.catalog-motion-tile {
    height: 100%;
    aspect-ratio: 1 / 1;
    flex: 0 0 auto;
    margin: 0;
    overflow: hidden;
    border: 1px solid rgba(255,255,255, .08);
    border-radius: 9px;
    background: #171717;
    box-shadow: 0 10px 30px rgba(0,0,0, .24);
}

.catalog-motion-tile img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    filter: none !important;
    transform: translateZ(0);
}

.catalog-motion-fallback {
    display: grid;
    place-items: center;
    color: rgba(255,255,255, .76);
    background: linear-gradient(135deg, #111, #4a4a4a);
}

.catalog-motion-fallback span,
.catalog-motion-fallback svg {
    width: 34px;
    height: 34px;
}

@keyframes catalogMoveLeft {
    from { transform: translate3d(0, 0, 0); }
    to { transform: translate3d(calc(-50% - 3.5px), 0, 0); }
}

@keyframes catalogMoveRight {
    from { transform: translate3d(calc(-50% - 3.5px), 0, 0); }
    to { transform: translate3d(0, 0, 0); }
}

/* =========================================================
   ADMIN MODE 2 + 3: FULL BACKGROUND IMAGE OR GIF
   ========================================================= */
.studio-full-media {
    position: absolute;
    inset: 0;
    overflow: hidden;
    background: #080808;
}

.studio-full-media img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    object-position: center center;
    filter: none !important;
}

.catalog-wall-shade {
    position: absolute;
    inset: 0;
    z-index: 1;
    background:
        radial-gradient(circle at center, rgba(0,0,0, .12), rgba(0,0,0, .48) 58%, rgba(0,0,0, .76)),
        linear-gradient(180deg, rgba(0,0,0, .20), rgba(0,0,0, .34));
    backdrop-filter: blur(.25px);
}

.studio-background-image .catalog-wall-shade,
.studio-background-gif .catalog-wall-shade {
    background:
        radial-gradient(circle at center, rgba(0,0,0, .18), rgba(0,0,0, .50) 60%, rgba(0,0,0, .72)),
        linear-gradient(90deg, rgba(0,0,0, .24), rgba(0,0,0, .12));
}

/* =========================================================
   LOGIN CARD REMAINS STRICT BLACK + WHITE
   ========================================================= */
.catalog-wall-card {
    position: relative;
    z-index: 2;
    width: min(510px, calc(100vw - 28px));
    max-height: calc(var(--cdm-screen-height) - 24px);
    padding: clamp(22px, 3vh, 34px) clamp(24px, 3.2vw, 40px);
    overflow: hidden;
    border: 1px solid rgba(255,255,255, .14);
    border-radius: 24px;
    background: rgba(7,7,7, .965);
    color: #fff;
    box-shadow: 0 32px 90px rgba(0,0,0, .68);
    backdrop-filter: blur(18px);
}

.catalog-wall-brand {
    display: flex;
    justify-content: center;
    margin-bottom: 14px;
}

.catalog-wall-logo {
    width: 150px;
    max-height: 50px;
    object-fit: contain;
    filter: grayscale(1) brightness(1.12) contrast(1.1);
}

.catalog-wall-kicker {
    display: block;
    color: rgba(255,255,255, .56);
    text-align: center;
    font-size: 9px;
    font-weight: 900;
    letter-spacing: .16em;
    text-transform: uppercase;
}

.catalog-wall-card h1 {
    margin: 12px 0 0;
    color: #fff;
    text-align: center;
    font-size: clamp(27px, 3vw, 38px);
    line-height: 1;
    font-weight: 850;
    letter-spacing: -.035em;
}

.catalog-wall-card > p {
    margin: 9px 0 18px;
    color: rgba(255,255,255, .66);
    text-align: center;
    font-size: 12px;
    font-weight: 600;
}

.catalog-wall-card .cdm-alert {
    margin-bottom: 12px;
    background: #f1f1f1;
    color: #111;
    border-color: rgba(255,255,255, .25);
}

.catalog-wall-card .cdm-reference-field label {
    color: rgba(255,255,255, .62);
}

.catalog-wall-card .cdm-reference-control {
    border-color: rgba(255,255,255, .17);
    background: #101010;
}

.catalog-wall-card .cdm-reference-control:focus-within {
    border-color: #fff;
    background: #151515;
    box-shadow: 0 0 0 3px rgba(255,255,255, .06);
}

/* Keep Chrome/Safari autofill and browser credential UI inside the dark field. */
.catalog-wall-card .cdm-reference-control {
    overflow: hidden;
}

.catalog-wall-card .cdm-reference-control input {
    flex: 1 1 auto;
    width: 100%;
    min-width: 0;
    height: 46px;
    padding: 0 12px 0 0;
    border: 0;
    border-radius: 0;
    outline: 0;
    appearance: none;
    -webkit-appearance: none;
    background: #101010 !important;
    background-color: #101010 !important;
    background-image: none !important;
    color: #fff !important;
    caret-color: #fff;
    -webkit-text-fill-color: #fff !important;
    box-shadow: 0 0 0 1000px #101010 inset !important;
    -webkit-box-shadow: 0 0 0 1000px #101010 inset !important;
}

.catalog-wall-card .cdm-reference-control:focus-within input {
    background: #151515 !important;
    background-color: #151515 !important;
    box-shadow: 0 0 0 1000px #151515 inset !important;
    -webkit-box-shadow: 0 0 0 1000px #151515 inset !important;
}

.catalog-wall-card .cdm-reference-control input:-webkit-autofill,
.catalog-wall-card .cdm-reference-control input:-webkit-autofill:hover,
.catalog-wall-card .cdm-reference-control input:-webkit-autofill:focus,
.catalog-wall-card .cdm-reference-control input:-webkit-autofill:active {
    background: #101010 !important;
    background-color: #101010 !important;
    background-image: none !important;
    color: #fff !important;
    caret-color: #fff !important;
    -webkit-text-fill-color: #fff !important;
    box-shadow: 0 0 0 1000px #101010 inset !important;
    -webkit-box-shadow: 0 0 0 1000px #101010 inset !important;
    transition: background-color 9999s ease-out 0s;
}

.catalog-wall-card .cdm-reference-control:focus-within input:-webkit-autofill,
.catalog-wall-card .cdm-reference-control:focus-within input:-webkit-autofill:hover,
.catalog-wall-card .cdm-reference-control:focus-within input:-webkit-autofill:focus,
.catalog-wall-card .cdm-reference-control:focus-within input:-webkit-autofill:active {
    box-shadow: 0 0 0 1000px #151515 inset !important;
    -webkit-box-shadow: 0 0 0 1000px #151515 inset !important;
}

.catalog-wall-card .cdm-reference-control input::-webkit-contacts-auto-fill-button,
.catalog-wall-card .cdm-reference-control input::-webkit-credentials-auto-fill-button,
.catalog-wall-card .cdm-reference-control input::-webkit-caps-lock-indicator,
.catalog-wall-card .cdm-reference-control input::-webkit-strong-password-auto-fill-button {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
}

.catalog-wall-card .cdm-reference-control input::placeholder {
    color: rgba(255,255,255, .32);
    -webkit-text-fill-color: rgba(255,255,255, .32);
}

.catalog-wall-card .cdm-reference-control > span,
.catalog-wall-card .cdm-reference-eye {
    color: rgba(255,255,255, .55);
}

.catalog-wall-card .cdm-reference-eye:hover {
    background: rgba(255,255,255, .07);
    color: #fff;
}

.catalog-wall-card .cdm-reference-meta label,
.catalog-wall-card .cdm-reference-meta a {
    color: rgba(255,255,255, .72);
}

.catalog-wall-card .cdm-reference-meta input {
    accent-color: #fff;
}

.catalog-wall-card .cdm-reference-submit {
    background: #fff;
    color: #050505;
    box-shadow: none;
}

.catalog-wall-card .cdm-reference-separator {
    color: rgba(255,255,255, .42);
}

.catalog-wall-card .cdm-reference-separator::before,
.catalog-wall-card .cdm-reference-separator::after {
    background: rgba(255,255,255, .10);
}

.catalog-wall-card .cdm-reference-access {
    border-color: rgba(255,255,255, .12);
    background: #161616;
}

.catalog-wall-card .cdm-reference-access span {
    color: rgba(255,255,255, .50);
}

.catalog-wall-card .cdm-reference-access strong {
    color: #fff;
}

.catalog-wall-card footer {
    margin-top: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    color: rgba(255,255,255, .45);
    font-size: 9px;
    font-weight: 700;
}

.catalog-wall-card footer a:hover {
    color: #fff;
}

@media (max-width: 900px) {
    .catalog-motion {
        inset: -2%;
        gap: 5px;
        transform: rotate(-1deg) scale(1.035);
    }

    .catalog-motion-tile {
        border-radius: 7px;
    }

    .catalog-wall-card {
        width: min(440px, calc(100vw - 20px));
        padding: 22px 20px;
        border-radius: 20px;
    }
}

@media (max-width: 480px) {
    .catalog-motion {
        inset: -3% -22%;
        gap: 4px;
    }

    .catalog-motion-track {
        gap: 4px;
    }

    .catalog-wall-card {
        padding: 18px 15px;
    }

    .catalog-wall-brand {
        margin-bottom: 10px;
    }

    .catalog-wall-logo {
        width: 128px;
    }

    .catalog-wall-card h1 {
        font-size: 28px;
    }

    .catalog-wall-card > p {
        margin-bottom: 14px;
    }
}

@media (max-height: 680px) {
    .catalog-wall-card {
        padding-top: 16px;
        padding-bottom: 16px;
    }

    .catalog-wall-brand {
        margin-bottom: 7px;
    }

    .catalog-wall-logo {
        width: 120px;
        max-height: 37px;
    }

    .catalog-wall-kicker {
        display: none;
    }

    .catalog-wall-card h1 {
        margin-top: 3px;
        font-size: 25px;
    }

    .catalog-wall-card > p {
        margin: 5px 0 10px;
    }

    .catalog-wall-card footer {
        display: none;
    }
}

@media (max-height: 560px) {
    .catalog-wall-card > p,
    .catalog-wall-card .cdm-reference-access,
    .catalog-wall-card .cdm-reference-separator {
        display: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .catalog-motion-track {
        animation-play-state: paused !important;
    }
}
