.qr-code-list {
    display: flex;
    flex-direction: row;
    justify-content: flex-start;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    width: 100%;
    overflow: auto;
    max-height: 400px;
}

.qr-code-list .qr-code-item {
    flex: 1;
    max-width: 100%;
    min-width: fit-content;
}

.qr-code-list .qr-code-item label {
    display: flex;
    flex-direction: row;
    align-items: center;
    white-space: nowrap;
    gap: 1rem;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    cursor: pointer;
    border: 4px solid var(--ColorRow);
    background-color: var(--ColorContainer);
    color: var(--ColorText);
    height: 4.5rem;
}

.form-container .qr-code-list .qr-code-item label {
    border: 4px solid var(--ColorBackground);
}

.qr-code-list .qr-code-item label span {
    text-align: center;
}

.qr-code-list .qr-code-item label.qr {
    background-color: white;
    color: #212121;
}

.qr-code-list .qr-code-item label.qr span {
    text-align: left;
}

.qr-code-list .qr-code-item.square label {
    border-radius: 0px;
}

.qr-code-list .qr-code-item.rounded label {
    border-radius: 0.5rem;
}

.qr-code-list .qr-code-item.circular label {
    border-radius: 2.5rem;
}

.qr-code-list .qr-code-item label:hover {
    border-color: var(--ColorRowHover);
}

.qr-code-list .qr-code-item input {
    display: none;
}

.qr-code-list .qr-code-item input:checked ~ label{
    border-color: var(--ColorBlue);
}

@media screen and (max-width: 750px) {
    .qr-code-list {
        flex-direction: column;
    }
    
    .qr-code-list .qr-code-item {
        width: 100%;
    }
}

.popup-qr .popup-content,
.popup-content.popup-qr {
    max-width: 900px;
}
.qr-selector-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 240px;
    gap: var(--Gap);
    align-items: start;
    width: 100%;
}
.qr-selector-layout .qr-code-list {
    max-height: 320px;
}
.qr-preview {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}
.qr-preview img {
    width: 240px;
    height: 240px;
    box-shadow: var(--Shadow);
    background: #fff;
    transition: opacity 0.2s;
}
.qr-preview img.loading {
    opacity: 0.4;
}
.qr-preview .muted {
    color: var(--ColorTextAlt);
    font-size: var(--FontSize-s);
}
@media screen and (max-width: 750px) {
    .qr-selector-layout {
        grid-template-columns: 1fr;
    }
}

.qr-template-thumb {
    width: 72px;
    height: 72px;
    display: block;
    border-radius: 0 !important; 
    object-fit: contain;
    margin: 0.25rem 0.5rem;
}
.qr-color-dot {
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 50%;
    border: 2px solid var(--ColorRow);
    display: inline-block;
}
.qr-template-form .qr-remove-logo {
    margin-top: 0.5rem;
    cursor: pointer;
}
.qr-template-form .qr-remove-logo input {
    width: auto;
}

.qr-edit-preview {
    flex: 0 0 340px;
    align-items: center;
}
.qr-edit-preview img {
    width: 300px;
    height: 300px;
    box-shadow: var(--Shadow);
    background: #fff;
    transition: opacity 0.2s;
}
.qr-edit-preview img.loading {
    opacity: 0.4;
}
.qr-current-logo {
    margin-bottom: 0.5rem;
}
.qr-current-logo img {
    width: 56px;
    height: 56px;
    border-radius: var(--BorderRadius);
    box-shadow: var(--Shadow2);
}
@media screen and (max-width: 900px) {
    .qr-edit-preview {
        flex: 1 1 auto;
    }
}

.container-link-edit .block form .column > .column,
.qr-template-form .column > .column {
    flex: 0 0 auto;
}

.qr-choice-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: calc(var(--Gap) / 2);
    width: 100%;
    max-height: 340px;
    overflow: auto;
    padding: 2px;
}
.qr-choice {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4rem;
    padding: 0.6rem;
    border-radius: var(--BorderRadius);
    border: 3px solid var(--ColorRow);
    background-color: var(--ColorContainer);
    cursor: pointer;
    transition: var(--Transition);
}
.qr-choice:hover {
    border-color: var(--ColorRowHover);
}
.qr-choice input {
    display: none;
}
.qr-choice:has(input:checked) {
    border-color: var(--ColorBlue);
}
.qr-choice img {
    width: 96px;
    height: 96px;
    display: block;
    border-radius: 0;
}
.qr-choice-name {
    font-size: var(--FontSize-s);
    text-align: center;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.qr-choice:has(input:checked) .qr-choice-name {
    color: var(--ColorBlue);
    font-weight: bold;
}
.qr-manage-link {
    font-size: var(--FontSize-s);
    align-self: flex-start;
}