.kgsc {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    width: 100%;
    min-width: 0;
}

.kgsc-preview {
    position: relative;
    width: min(100%, calc(min(66vh, 640px) * 9 / 16));
    min-width: 0;
}

.kgsc-canvas {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 9 / 16;
    border-radius: 14px;
    border: 1px solid rgba(212, 175, 55, 0.28);
    background: #140a0e;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
}

.kgsc-status {
    margin: 10px 0 0;
    color: rgba(243, 237, 226, 0.72);
    font-size: 13px;
    line-height: 1.45;
    text-align: center;
}

.kgsc-status[hidden] {
    display: none;
}

.kgsc-posters {
    width: 100%;
    min-width: 0;
}

.kgsc-posters[hidden] {
    display: none;
}

.kgsc-posters-label {
    margin: 0 0 8px;
    color: rgba(243, 237, 226, 0.7);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    text-align: center;
}

.kgsc-poster-row {
    display: flex;
    gap: 8px;
    padding: 4px 2px 8px;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scrollbar-width: thin;
    justify-content: safe center;
}

.kgsc-poster {
    flex: 0 0 auto;
    width: 52px;
    height: 78px;
    padding: 0;
    border-radius: 8px;
    border: 2px solid transparent;
    background: rgba(255, 255, 255, 0.06);
    overflow: hidden;
    cursor: pointer;
    opacity: 0.72;
    transition: opacity .15s ease, border-color .15s ease, transform .15s ease;
}

.kgsc-poster img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.kgsc-poster:hover {
    opacity: 1;
}

.kgsc-poster[aria-checked="true"] {
    opacity: 1;
    border-color: #dcb85a;
    transform: translateY(-2px);
}

.kgsc-poster:focus-visible {
    outline: 2px solid #dcb85a;
    outline-offset: 2px;
}

.kgsc-note {
    margin: 10px 0 0;
    min-height: 18px;
    color: rgba(243, 237, 226, 0.72);
    font-size: 13px;
    line-height: 1.45;
    text-align: center;
}

@media (max-width: 480px) {
    .kgsc-preview {
        width: min(100%, calc(min(62vh, 560px) * 9 / 16));
    }
}

@media (prefers-reduced-motion: reduce) {
    .kgsc-poster {
        transition: none;
    }
}
