.od-qr-codes {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 14px;
}

.od-qr-item {
    display: flex;
    flex-wrap: wrap;
    margin: 12px 0;
    border: 1px solid #dcdcde;
    border-radius: 6px;
    background: #fff;
    box-shadow: 0 1px 2px rgba(0, 0, 0, .04);
    overflow: hidden;
}

.od-qr-item > .od-qr-toggle {
    flex: 1 1 0;
    box-sizing: border-box;
    width: auto;
    min-width: 0;
    min-height: 48px;
    padding: 10px 14px;
    background: #f6f7f7;
    color: #1d2327;
    cursor: pointer;
    font-weight: 600;
    line-height: 1.4;
    user-select: none;
    transition: background-color .15s ease, color .15s ease;
}

.od-qr-item > .od-qr-toggle:hover {
    background: #eef0f1;
}

.od-qr-item-actions > .od-qr-remove {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 32px;
    padding: 0 11px;
    border: 1px solid #dba6a6;
    border-radius: 4px;
    background: #fff;
    color: #a12626;
    font-size: 12px;
    text-decoration: none;
    margin: 0;
    line-height: 1.5;
    transition: background-color .15s ease, border-color .15s ease, color .15s ease;
}

.od-qr-item-actions > .od-qr-remove:hover,
.od-qr-item-actions > .od-qr-remove:focus-visible {
    border-color: #b32d2e;
    background: #b32d2e;
    color: #fff;
}

.od-qr-item-actions {
    display: flex;
    flex: 0 0 100%;
    box-sizing: border-box;
    justify-content: flex-end;
    padding: 8px 14px;
    border-top: 1px solid #dcdcde;
    background: #f6f7f7;
}

.od-qr-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
    list-style: none;
    text-align: left;
}

.od-qr-toggle:focus-visible,
.od-qr-item-actions > .od-qr-remove:focus-visible {
    position: relative;
    z-index: 1;
    outline: 2px solid #2271b1;
    outline-offset: -2px;
}

.od-qr-toggle::-webkit-details-marker {
    display: none;
}

.od-qr-toggle-title {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.od-qr-toggle-icon {
    width: 10px;
    height: 10px;
    flex: none;
    margin-top: -4px;
    border-right: 2px solid #646970;
    border-bottom: 2px solid #646970;
    transform-origin: center;
    transform: rotate(45deg) translateY(-2px);
    transition: transform .15s ease;
}

.od-qr-item:not([open]) .od-qr-toggle-icon {
    transform: rotate(-45deg) translateY(-2px);
}

@media (max-width: 480px) {
    .od-qr-item > .od-qr-toggle {
        min-height: 44px;
        padding: 9px 10px;
    }
}

.od-qr-item-fields {
    flex: 0 0 100%;
    box-sizing: border-box;
    padding: 4px 14px 12px;
    border-top: 1px solid #dcdcde;
}

.od-qr-item-fields[hidden] {
    display: none !important;
}

.od-qr-item-fields p {
    margin: 12px 0;
}

.od-qr-item-fields label {
    display: block;
    color: #3c434a;
    font-weight: 500;
}

.od-qr-item-fields input,
.od-qr-item-fields select,
.od-qr-item-fields textarea {
    margin-top: 4px;
}

.od-qr-preview {
    padding: 5px;
    border: 1px solid #dcdcde;
    border-radius: 4px;
    background: #fff;
}

.od-qr-list + p {
    margin-top: 12px;
}

.od-qr-code-item {
    min-width: 0;
    border-radius: 6px;
    background: var(--od-card, #fff);
    text-align: center;
}

.od-qr-code-image {
    display: block;
    width: 100%;
    max-width: 180px;
    aspect-ratio: 1;
    margin: 0 auto 8px;
    padding: 5px;
    border: 1px solid var(--od-line, #e5e7eb);
    border-radius: 4px;
    overflow: hidden;
    background: #fff;
    transition: border-color .15s ease, box-shadow .15s ease;
}

a.od-qr-code-image:hover {
    border-color: var(--od-primary, #e84b81);
    box-shadow: 0 2px 8px rgba(0, 0, 0, .08);
}

.od-qr-code-image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.od-qr-code-copy span {
    display: block;
    overflow-wrap: anywhere;
}

.od-qr-copy-button {
    max-width: 100%;
    padding: 6px 14px;
    border: 1px solid var(--od-primary, #e84b81);
    border-radius: 4px;
    background: var(--od-primary, #e84b81);
    color: #fff;
    font: inherit;
    font-size: 14px;
    line-height: 1.4;
    overflow-wrap: anywhere;
    cursor: pointer;
    transition: filter .15s ease, transform .15s ease;
}

.od-qr-copy-button:hover:not(:disabled) {
    filter: brightness(.94);
    transform: translateY(-1px);
}

.od-qr-copy-button:focus-visible,
.od-qr-code-image:focus-visible {
    outline: 2px solid var(--od-primary, #e84b81);
    outline-offset: 2px;
}

.od-qr-copy-button:disabled {
    border-color: var(--od-line, #ddd);
    background: var(--od-line, #ddd);
    color: var(--od-muted, #777);
    cursor: not-allowed;
}

.od-qr-code-copy span {
    margin-top: 3px;
    color: var(--od-muted, #888);
    font-size: 12px;
}
