.artx-qr-wrap {
    max-width: 900px;
    margin: 20px auto;
    direction: rtl;
    text-align: right;
}

.artx-qr-title {
    text-align: center;
    margin-bottom: 20px;
}

.artx-qr-card {
    background: #ffffff;
    border-radius: 10px;
    padding: 20px 16px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.06);
    border: 1px solid #ececec;
}

.artx-qr-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}

.artx-qr-label {
    font-weight: 600;
    min-width: 90px;
}

.artx-mode-dropdown {
    position: relative;
    min-width: 220px;
}

.artx-mode-trigger {
    width: 100%;
    text-align: right;
    padding: 8px 12px;
    border-radius: 6px;
    border: 1px solid #ccc;
    background: #fff;
    font-size: 14px;
    cursor: pointer;
}

.artx-mode-options {
    list-style: none;
    margin: 4px 0 0;
    padding: 0;
    position: absolute;
    right: 0;
    left: 0;
    background: #fff;
    border-radius: 6px;
    border: 1px solid #ccc;
    box-shadow: 0 4px 10px rgba(0,0,0,0.08);
    max-height: 200px;
    overflow-y: auto;
    display: none;
    z-index: 9999;
}

.artx-mode-options li {
    padding: 8px 10px;
    font-size: 14px;
    cursor: pointer;
}

.artx-mode-options li:hover {
    background: #f2f2f2;
}

.artx-mode-dropdown.open .artx-mode-options {
    display: block;
}

.artx-input-modes {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.artx-input-mode-btn {
    padding: 6px 10px;
    border-radius: 20px;
    border: 1px solid #ccc;
    background: #f7f7f7;
    font-size: 13px;
    cursor: pointer;
}

.artx-input-mode-btn.active {
    background: #2271b1;
    color: #fff;
    border-color: #2271b1;
}

.artx-qr-current {
    margin-top: 8px;
    margin-bottom: 12px;
}

.artx-current-mode-label {
    color: #2271b1;
    margin-right: 4px;
}

.artx-qr-input-hidden {
    opacity: 0;
    position: absolute;
    left: -9999px;
}

.artx-camera-wrapper {
    margin-top: 12px;
}

.artx-qr-camera-box {
    position: relative;
    width: 90vw;
    max-width: 320px;
    height: 90vw;
    max-height: 320px;
    margin: 0 auto;
    border-radius: 10px;
    overflow: hidden;
    border: 2px solid #ccc;
    background: #000;
}

.artx-qr-camera-inner {
    width: 100%;
    height: 100%;
}

.artx-qr-camera-frame {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 70%;
    height: 70%;
    transform: translate(-50%, -50%);
    border: 3px solid rgba(255,255,255,0.8);
    border-radius: 8px;
    box-sizing: border-box;
    pointer-events: none;
}

.artx-camera-wrapper.ready .artx-qr-camera-frame {
    border-color: #33cc33;
}

.artx-camera-wrapper.done .artx-qr-camera-frame {
    border-color: #2271b1;
}

.artx-camera-hint {
    font-size: 12px;
    color: #555;
    margin-top: 6px;
    text-align: center;
}

.artx-camera-hint.artx-camera-success {
    color: #0b4f7b;
    font-weight: 700;
}

.artx-camera-controls {
    margin-top: 8px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    align-items: center;
}

.artx-qr-hint {
    display: inline-flex;
    align-items: center;
    margin-top: 8px;
    font-size: 13px;
    color: #666;
}

.artx-qr-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
    margin-left: 6px;
    background: #ffb100;
}

.artx-qr-subtitle {
    margin-top: 24px;
    margin-bottom: 12px;
}

/* قائمة العمليات الرأسية */
.artx-qr-log-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.artx-log-item {
    background: #ffffff;
    border-radius: 10px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.05);
    border: 1px solid #ececec;
    padding: 10px 12px;
}

.artx-log-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 4px 0;
    border-bottom: 2px solid #000;
}

.artx-log-row:last-child {
    border-bottom: none;
}

.artx-log-label {
    font-size: 13px;
    font-weight: 500;
    color: #333;
    margin-left: 10px;
}

.artx-log-value {
    font-size: 13px;
    font-weight: 700;
    color: #0b4f7b; /* أزرق غامق */
    text-align: left;
    direction: ltr;
}

.artx-log-row:nth-child(3) .artx-log-value {
    white-space: normal;
    text-align: right;
    direction: rtl;
}

.artx-success {
    color: #1a7f37;
}

.artx-error {
    color: #b3261e;
}

/* موبايل */
@media (max-width: 600px) {
    .artx-qr-card {
        padding: 16px 12px;
    }
    .artx-qr-label {
        min-width: auto;
    }
    .artx-mode-dropdown {
        min-width: 100%;
    }
}
