/* =====================================================================
   ShopiPersia Vendor Manager — Product Lists
   Styles moved out of includes/product-lists.php (inline <style>) so the
   browser can cache them and the markup stays small.
   Enqueued by spvm_product_lists_enqueue_styles().
   ===================================================================== */

/* ============================ Product form ============================ */

/* ===== General styles ===== */
.spui-rtl { direction: rtl; }
.spui-rtl .spui-label { text-align: right; }

.spui-box { 
    border: 1px solid #e9e9e9; 
    border-radius: 12px; 
    padding: 20px; 
    background: #fff; 
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif; 
    color: #222;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    position: relative;
}

.spvm-step-section {
    background: #fff;
    border-radius: 16px;
    padding: 24px 28px;
    margin-bottom: 28px;
    border: 1px solid #eef2f6;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
    position: relative;
    transition: border-color 0.3s ease;
}
.spvm-step-section:hover {
    border-color: #d1d9e6;
}
.spvm-step-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid #f1f4f8;
}
.spvm-step-header h2 {
    font-size: 18px;
    font-weight: 600;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 10px;
    color: #0f1724;
}
.spvm-step-header .step-icon {
    font-size: 22px;
    line-height: 1;
}

.spvm-step-body {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* ===== AI Section ===== */
.spvm-ai-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 16px;
    padding: 14px 18px;
    background: linear-gradient(135deg, #f8f5ff 0%, #f0edff 100%);
    border-radius: 12px;
    border: 1px solid #e8e0f5;
}
.spvm-ai-header .ai-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
    font-size: 15px;
    color: #5b21b6;
}
.spvm-ai-header .ai-title .ai-icon { font-size: 24px; }
.spvm-ai-header .ai-subtitle { font-size: 13px; color: #6b7a8a; }
.spvm-ai-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}
.spvm-ai-btn {
    padding: 7px 20px;
    border-radius: 30px;
    font-size: 13px;
    font-weight: 500;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #f1f4f8;
    color: #1e293b;
}
.spvm-ai-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}
.spvm-ai-btn-export { background: #8B5CF6; color: #fff; }
.spvm-ai-btn-export:hover { background: #7c3aed; }
.spvm-ai-btn-import { background: #10b981; color: #fff; }
.spvm-ai-btn-import:hover { background: #059669; }
.spvm-ai-btn-ask { background: #f59e0b; color: #fff; }
.spvm-ai-btn-ask:hover { background: #d97706; }
.spvm-ai-btn svg { width: 16px; height: 16px; }

/* ===== Toast notification ===== */
.spvm-toast {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: #1e293b;
    color: #fff;
    padding: 14px 24px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 500;
    box-shadow: 0 8px 30px rgba(0,0,0,0.2);
    z-index: 99999;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease;
    pointer-events: none;
}
.spvm-toast.show { opacity: 1; transform: translateY(0); }
.spvm-toast .toast-icon { margin-right: 8px; }

/* ===== Error toast ===== */
.spvm-error-toast {
    position: fixed;
    top: 30px;
    right: 30px;
    background: #10b981;
    color: #fff;
    padding: 18px 28px;
    border-radius: 16px;
    font-size: 15px;
    font-weight: 500;
    box-shadow: 0 8px 40px rgba(16,185,129,0.4);
    z-index: 99999;
    opacity: 0;
    transform: translateY(-20px) scale(0.95);
    transition: all 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
    pointer-events: none;
    max-width: 480px;
    border: 1px solid rgba(255,255,255,0.2);
    backdrop-filter: blur(4px);
}
.spvm-error-toast.show { opacity: 1; transform: translateY(0) scale(1); }
.spvm-error-toast .error-icon { font-size: 20px; margin-right: 12px; }
.spvm-error-toast .error-messages {
    list-style: none;
    margin: 6px 0 0 0;
    padding: 0;
    font-weight: 400;
    font-size: 14px;
}
.spvm-error-toast .error-messages li {
    padding: 2px 0 2px 20px;
    position: relative;
}
.spvm-error-toast .error-messages li::before {
    content: "•";
    position: absolute;
    left: 0;
    font-weight: 700;
}
.spvm-error-toast .error-heading {
    font-weight: 600;
    font-size: 15px;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* ===== Other styles ===== */
.spui-item { 
    display: flex; 
    justify-content: space-between; 
    gap: 25px; 
    align-items: flex-start; 
    padding: 12px 0; 
    border-bottom: 1px dashed #eee; 
    position: relative;
}
.spui-item:last-child { border-bottom: none; }
.spui-label { flex: 0 0 28%; max-width: 28%; }
.spui-label strong { 
    display: block; 
    font-size: 14px; 
    color: #333; 
    margin-bottom: 4px; 
    font-weight: 600;
}
.spui-label .spui-note { 
    font-size: 12px; 
    color: #777; 
    margin-top: 2px; 
    line-height: 1.4;
}
.spui-value { 
    flex: 0 0 68%; 
    max-width: 68%;
    color: #555; 
    font-size: 14px; 
    position: relative; 
}
.spui-value input[type="text"], 
.spui-value input[type="number"], 
.spui-value textarea, 
.spui-value select { 
    width: 100%; 
    padding: 10px 12px; 
    border: 1px solid #ddd; 
    border-radius: 8px; 
    box-sizing: border-box;
    font-size: 14px;
    transition: all 0.3s ease;
}
.spui-value input:focus,
.spui-value textarea:focus,
.spui-value select:focus {
    border-color: #8B5CF6;
    outline: none;
    box-shadow: 0 0 0 3px rgba(139,92,246,0.1);
}
.spui-value textarea { min-height: 80px; resize: vertical; }

/* ===== Stock management ===== */
.stock-management-row {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}
.stock-management-row .stock-checkbox {
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 500;
    font-size: 14px;
    color: #333;
    cursor: pointer;
}
.stock-management-row .stock-checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin: 0;
    cursor: pointer;
}
.stock-management-row .stock-input { flex: 1; min-width: 120px; }
.stock-management-row .stock-input input {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
}
.stock-management-row .stock-input input:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* ===== Gallery & upload ===== */
.spui-upload-card { 
    width: 140px; 
    height: 140px; 
    border: 2px dashed #ccc; 
    border-radius: 12px; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    position: relative; 
    cursor: pointer; 
    background: #fafafa; 
    overflow: hidden;
    transition: all 0.3s ease;
}
.spui-upload-card:hover { border-color: #8B5CF6; background: #f8f5ff; }
.spui-upload-card .plus { font-size: 36px; color: #ccc; }
.spui-upload-card img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gallery-thumbs { 
    display: flex; 
    gap: 10px; 
    flex-wrap: wrap; 
    align-items: center; 
    margin-bottom: 8px;
}
.gallery-thumb { 
    position: relative;
    width: 75px; 
    height: 75px; 
    border: 1px solid #eee; 
    border-radius: 8px; 
    overflow: hidden; 
    background: #f5f5f5;
}
.gallery-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gallery-thumb .remove-thumb {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 20px;
    height: 20px;
    background: rgba(0,0,0,0.6);
    border-radius: 50%;
    cursor: pointer;
    padding: 0;
    transition: all 0.2s;
    z-index: 10;
}
.gallery-thumb .remove-thumb:hover { background: #e74c3c; transform: scale(1.1); }
.spui-actions { 
    margin-top: 10px; 
    display: flex; 
    gap: 10px; 
    flex-wrap: wrap;
}
.spui-edit-btn { 
    background: #8B5CF6; 
    border: none; 
    border-radius: 8px; 
    color: #fff; 
    padding: 8px 18px; 
    font-size: 13px; 
    font-weight: 500;
    cursor: pointer; 
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.spui-edit-btn:hover { background: #7c3aed; transform: translateY(-1px); }
.spui-edit-btn:disabled { opacity: 0.5 !important; cursor: not-allowed !important; transform: none !important; }
.spui-edit-btn-danger { background: #ef4444; }
.spui-edit-btn-danger:hover { background: #dc2626; }
.spui-edit-btn-secondary { background: #e2e8f0; color: #1e293b; }
.spui-edit-btn-secondary:hover { background: #cbd5e1; }

/* ===== Feature rows ===== */
.feature-row {
    background: #f8fafc;
    padding: 10px 14px;
    border-radius: 8px;
    margin-bottom: 8px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    transition: background 0.2s;
}
.feature-row:hover { background: #f1f4f8; }
.feature-select-wrapper { flex: 1; min-width: 140px; }
.feature-value-wrapper { flex: 1; display: flex; align-items: center; gap: 10px; }
.feature-value-wrapper input { flex: 1; }
.feature-value-wrapper .remove-feature {
    flex: 0 0 auto;
    width: 24px;
    height: 24px;
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.2s;
}
.feature-value-wrapper .remove-feature:hover { opacity: 1; }

/* ===== Attributes ===== */
#attributes-container { margin-top: 10px; margin-bottom: 10px; }
.attribute-item {
    background: #f8fafc;
    border: 1px solid #e9ecef;
    border-radius: 10px;
    padding: 10px 14px;
    margin-bottom: 10px;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    flex-wrap: wrap;
    transition: all 0.2s ease;
}
.attribute-item:hover { box-shadow: 0 2px 8px rgba(0,0,0,0.06); }
.attribute-name-col { flex: 0 0 180px; min-width: 160px; max-width: 200px; }
.attribute-name {
    font-weight: 600;
    background: #e9ecef;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 13px;
    color: #333;
    display: block;
    width: 100%;
    margin: 0;
    box-sizing: border-box;
}
.attribute-value-col { flex: 1; min-width: 160px; }
.attribute-value-select {
    width: 100%;
    padding: 6px 10px;
    border: 1px solid #ddd;
    border-radius: 6px;
    background: white;
    font-size: 13px;
    cursor: pointer;
}
.custom-attr-wrapper { margin-top: 6px; }
.custom-attr-wrapper label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    cursor: pointer;
}
.custom-attr-input {
    display: block;
    width: 100%;
    margin-top: 4px;
    padding: 6px 10px;
    border: 1px solid #ddd;
    border-radius: 6px;
    box-sizing: border-box;
}
.attributes-loading {
    text-align: center;
    padding: 30px;
    color: #888;
    background: #fafafa;
    border-radius: 10px;
    font-size: 13px;
}

/* ===== Submit button ===== */
.spvm-submit-wrapper {
    text-align: right;
    padding-top: 16px;
    border-top: 2px solid #f1f4f8;
    margin-top: 8px;
}
.spvm-submit-btn {
    background: #8B5CF6;
    border: none;
    border-radius: 10px;
    color: #fff;
    padding: 14px 40px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}
.spvm-submit-btn:hover {
    background: #7c3aed;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(139,92,246,0.3);
}

/* ===== MODAL ===== */
.spvm-modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    backdrop-filter: blur(4px);
    z-index: 9999;
    justify-content: center;
    align-items: center;
}
.spvm-modal-overlay.active { display: flex; }
.spvm-modal {
    background: #fff;
    border-radius: 24px;
    max-width: 700px;
    width: 92%;
    padding: 40px 36px 32px;
    box-shadow: 0 24px 64px rgba(0,0,0,0.2);
    max-height: 90vh;
    overflow-y: auto;
    animation: spvmModalFadeIn 0.3s ease;
    position: relative;
}
@keyframes spvmModalFadeIn {
    from { opacity: 0; transform: scale(0.95) translateY(20px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}
.spvm-modal-icon { font-size: 56px; margin-bottom: 12px; text-align: center; }
.spvm-modal h3 {
    font-size: 22px;
    font-weight: 700;
    margin: 0 0 8px;
    color: #0f1724;
    text-align: center;
}
.spvm-modal p {
    font-size: 15px;
    color: #4a5568;
    line-height: 1.6;
    margin: 0 0 16px;
    text-align: center;
}
.spvm-modal .spvm-modal-btn {
    background: #8B5CF6;
    border: none;
    border-radius: 10px;
    color: #fff;
    padding: 12px 40px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}
.spvm-modal .spvm-modal-btn:hover { background: #7c3aed; }
.spvm-modal textarea {
    width: 100%;
    min-height: 120px;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-family: monospace;
    font-size: 13px;
    resize: vertical;
}
.spvm-modal .import-step {
    margin-top: 16px;
    border-top: 1px solid #eef2f6;
    padding-top: 16px;
}
.spvm-modal .import-step h4 {
    font-size: 16px;
    font-weight: 600;
    margin: 0 0 8px;
    color: #0f1724;
}
.spvm-modal .import-step .step-status {
    margin-top: 8px;
    font-size: 14px;
    color: #059669;
}
.spvm-modal .product-type-list {
    max-height: 200px;
    overflow-y: auto;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 8px;
    background: #fafafa;
    margin: 8px 0 12px;
}
.spvm-modal .product-type-list label {
    display: block;
    padding: 6px 10px;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.15s;
}
.spvm-modal .product-type-list label:hover { background: #e9ecef; }
.spvm-modal .product-type-list input[type="radio"] { margin-right: 8px; }

/* ===== Pending notice ===== */
.pending-notice {
    background: #fef3c7;
    border: 1px solid #f59e0b;
    border-radius: 12px;
    padding: 15px 20px;
    margin-bottom: 20px;
    color: #92400e;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}
.pending-notice strong { color: #78350f; }

/* ===== Category overlay (edit mode) ===== */
.category-item { position: relative; }
.category-item-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 135, 255, 0.29);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100;
    backdrop-filter: blur(2px);
}
.category-overlay-content {
    background: white;
    border-radius: 16px;
    padding: 25px 30px;
    max-width: 400px;
    text-align: center;
    box-shadow: 0 20px 35px rgba(0,0,0,0.2);
    animation: fadeInScale 0.3s ease-out;
    margin: 20px;
}
@keyframes fadeInScale {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}
.category-overlay-content h3 {
    margin: 0 0 15px 0;
    color: #e74c3c;
    font-size: 20px;
}
.category-overlay-content p {
    margin: 0 0 25px 0;
    color: #555;
    line-height: 1.6;
    font-size: 14px;
}
.category-overlay-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
}
.btn-confirm-category {
    background: #e74c3c;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}
.btn-confirm-category:hover { background: #c0392b; transform: translateY(-1px); }
.btn-cancel-category {
    background: #95a5a6;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}
.btn-cancel-category:hover { background: #7f8c8f; transform: translateY(-1px); }

/* ===== Domestic shipping rows ===== */
.method-disabled { opacity: 0.4; pointer-events: none; }
.price-disabled { opacity: 0.5; cursor: not-allowed !important; }

/* ===== MULTIPACK FIELDS (corrected semantics) ===== */
.spvm-multipack-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    padding: 12px 16px;
    background: #f8fafc;
    border-radius: 10px;
    border: 1px solid #e2e8f0;
    transition: all 0.2s;
}
.spvm-multipack-toggle:hover {
    background: #f1f4f8;
    border-color: #cbd5e1;
}
.spvm-multipack-toggle input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    margin: 0;
}
.spvm-multipack-toggle span {
    font-weight: 600;
    color: #1e293b;
    font-size: 14px;
}
.spvm-multipack-fields {
    display: none;
    margin-top: 14px;
    padding: 16px 18px;
    background: linear-gradient(135deg, #f0f9ff 0%, #e0f2fe 100%);
    border: 1px solid #bae6fd;
    border-radius: 12px;
}
.spvm-multipack-fields.is-active {
    display: block;
    animation: mpFadeIn 0.25s ease;
}
@keyframes mpFadeIn {
    from { opacity: 0; transform: translateY(-6px); }
    to { opacity: 1; transform: translateY(0); }
}
.spvm-multipack-fields .mp-help {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin-bottom: 14px;
    font-size: 13px;
    color: #0369a1;
    font-weight: 500;
    line-height: 1.5;
}
.spvm-multipack-fields .mp-help .mp-help-icon {
    font-size: 18px;
    flex-shrink: 0;
}
.spvm-multipack-fields .mp-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 14px;
}
.spvm-multipack-fields .mp-field-label {
    display: block;
    font-weight: 600;
    font-size: 13px;
    margin-bottom: 6px;
    color: #334155;
}
.spvm-multipack-fields input.multipack-input {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid #ddd;
    border-radius: 8px;
    box-sizing: border-box;
    font-size: 14px;
    background: #fff;
    transition: all 0.2s;

    /* Numeric/value content must remain LTR on both RTL and LTR websites. */
    direction: ltr;
    text-align: left;
    unicode-bidi: plaintext;
}

/* Placeholder follows the website language direction, not the input value direction. */
:dir(rtl) .spvm-multipack-fields input.multipack-input::placeholder {
    direction: rtl;
    text-align: right;
}

:dir(ltr) .spvm-multipack-fields input.multipack-input::placeholder {
    direction: ltr;
    text-align: left;
}

.spvm-multipack-fields input.multipack-input:focus {
    border-color: #0ea5e9;
    outline: none;
    box-shadow: 0 0 0 3px rgba(14,165,233,0.15);
}
.spvm-multipack-fields .mp-field-desc {
    display: block;
    margin-top: 5px;
    color: #64748b;
    font-size: 11.5px;
    line-height: 1.5;
}
.spvm-multipack-fields .mp-tip {
    margin-top: 14px;
    padding: 10px 12px;
    background: rgba(255,255,255,0.7);
    border-radius: 8px;
    font-size: 12px;
    color: #475569;
    line-height: 1.6;
    border-left: 3px solid #0ea5e9;
}
.spvm-multipack-fields .mp-tip strong {
    color: #0369a1;
}

/* ================================================================
   PRODUCT KIND SELECTOR
   ================================================================ */

.spvm-product-kind-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 36, 0.7);
    backdrop-filter: blur(8px);
    z-index: 99998;
    justify-content: center;
    align-items: center;
    padding: 20px;
}
.spvm-product-kind-overlay.active { display: flex; }
.spvm-product-kind-box {
    background: #fff;
    border-radius: 24px;
    padding: 44px 40px 36px;
    max-width: 620px;
    width: 100%;
    text-align: center;
    box-shadow: 0 30px 80px rgba(0,0,0,0.3);
    animation: spvmKindFadeIn 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}
@keyframes spvmKindFadeIn {
    from { opacity: 0; transform: scale(0.9) translateY(20px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}
.spvm-kind-hero-icon { font-size: 60px; margin-bottom: 8px; line-height: 1; }
.spvm-product-kind-box h2 {
    margin: 0 0 10px;
    font-size: 26px;
    font-weight: 700;
    color: #0f1724;
    letter-spacing: -0.3px;
}
.spvm-product-kind-box > p {
    margin: 0 0 28px;
    color: #64748b;
    font-size: 15px;
    line-height: 1.6;
}
.spvm-kind-choices {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
}
@media (max-width: 520px) {
    .spvm-kind-choices { grid-template-columns: 1fr; }
    .spvm-product-kind-box { padding: 32px 22px 28px; }
    .spvm-product-kind-box h2 { font-size: 20px; }
}
.spvm-kind-btn {
    background: #fff;
    border: 2px solid #e2e8f0;
    border-radius: 18px;
    padding: 26px 20px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    transition: all 0.25s ease;
    text-align: center;
    font-family: inherit;
}
.spvm-kind-btn:hover {
    border-color: #8B5CF6;
    background: #f8f5ff;
    transform: translateY(-3px);
    box-shadow: 0 12px 28px rgba(139,92,246,0.18);
}
.spvm-kind-btn.spvm-kind-btn-disabled,
.spvm-kind-btn[disabled] {
    opacity: 0.55;
    cursor: not-allowed;
    pointer-events: none;
    filter: grayscale(0.45);
    transform: none !important;
    box-shadow: none !important;
    border-color: #e2e8f0 !important;
    background: #f8fafc !important;
    position: relative;
}
.spvm-kind-btn.spvm-kind-btn-disabled:hover {
    border-color: #e2e8f0 !important;
    background: #f8fafc !important;
    transform: none !important;
    box-shadow: none !important;
}
.spvm-kind-btn .kind-disabled-label {
    display: inline-block;
    margin-top: 8px;
    padding: 3px 10px;
    background: #fecaca;
    color: #991b1b;
    font-size: 11px;
    font-weight: 700;
    border-radius: 20px;
    letter-spacing: 0.2px;
}

.spvm-kind-notice {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    background: #fef3c7;
    border: 1px solid #fbbf24;
    border-left: 4px solid #f59e0b;
    color: #78350f;
    padding: 12px 16px;
    border-radius: 10px;
    margin: 0 0 22px;
    font-size: 13.5px;
    line-height: 1.6;
}
.spvm-kind-notice .notice-icon {
    font-size: 20px;
    line-height: 1;
    flex-shrink: 0;
    margin-top: 1px;
}
.spvm-kind-notice .notice-text strong { color: #7c2d12; }

.spvm-kind-btn:focus {
    outline: none;
    border-color: #8B5CF6;
    box-shadow: 0 0 0 4px rgba(139,92,246,0.15);
}
.spvm-kind-btn .kind-icon { font-size: 44px; line-height: 1; }
.spvm-kind-btn strong {
    font-size: 16px;
    color: #0f1724;
    font-weight: 600;
    display: block;
}
.spvm-kind-btn small {
    font-size: 12.5px;
    color: #64748b;
    line-height: 1.5;
    display: block;
}

.spvm-kind-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    background: #f1f4f8;
    border-radius: 30px;
    font-size: 12.5px;
    font-weight: 600;
    color: #1e293b;
    margin-top: 6px;
}
.spvm-kind-badge.digital {
    background: linear-gradient(135deg, #ede9fe, #ddd6fe);
    color: #5b21b6;
}
.spvm-kind-badge.physical {
    background: linear-gradient(135deg, #dbeafe, #bfdbfe);
    color: #1e40af;
}
.spvm-kind-badge button {
    background: transparent;
    border: none;
    color: inherit;
    font-size: 11.5px;
    font-weight: 600;
    text-decoration: underline;
    cursor: pointer;
    padding: 0;
    font-family: inherit;
}
.spvm-kind-badge button:hover { color: #7c3aed; }

.spvm-digital-upload-notice {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    border-left: 4px solid #3b82f6;
    color: #1e3a8a;
    padding: 12px 16px;
    border-radius: 10px;
    margin-top: 14px;
    font-size: 13.5px;
    line-height: 1.7;
    box-shadow: 0 1px 3px rgba(59, 130, 246, 0.08);
}
.spvm-digital-upload-notice svg {
    flex-shrink: 0;
    margin-top: 3px;
    color: #2563eb;
    width: 20px;
    height: 20px;
}
.spvm-digital-upload-notice span {
    flex: 1;
}
.spvm-digital-upload-notice strong {
    color: #1d4ed8;
    font-weight: 700;
}
@media (max-width: 768px) {
    .spvm-digital-upload-notice {
        font-size: 12.5px;
        padding: 10px 12px;
    }
}

.spvm-digital-mode .spui-item-digital-hide {
    display: none !important;
}

.spvm-digital-only {
    display: none !important;
}
.spvm-digital-mode .spvm-digital-only {
    display: block !important;
}

.spvm-digital-mode-banner {
    display: none;
    background: linear-gradient(135deg, #ede9fe 0%, #e0e7ff 100%);
    border-left: 4px solid #8B5CF6;
    border-radius: 12px;
    padding: 14px 18px;
    margin-bottom: 20px;
    align-items: center;
    gap: 12px;
    color: #4c1d95;
    font-size: 13.5px;
    line-height: 1.6;
}
.spvm-digital-mode-banner.show { display: flex; }
.spvm-digital-mode-banner .banner-icon {
    font-size: 24px;
    flex-shrink: 0;
}

/* ADD-ONS */
#spvm_flat_addons_list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
#shpa_blocks_wrapper {
    display: flex;
    flex-direction: column;
    gap: 14px;
}
.sh-block-box {
    border: 2px solid #c4b5fd;
    background: #faf5ff;
    border-radius: 10px;
    overflow: hidden;
    box-sizing: border-box;
}
.sh-block-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    background: #f3e8ff;
    border-bottom: 1px solid #ddd6fe;
    cursor: pointer;
    box-sizing: border-box;
    flex-wrap: wrap;
}
.sh-block-header .sh-block-title-input {
    flex: 1;
    min-width: 180px;
    padding: 6px 10px;
    border: 1px solid #d8b4fe;
    border-radius: 6px;
    background: #fff;
    font-weight: 600;
    box-sizing: border-box;
    font-size: 13px;
}
.sh-block-controls {
    display: flex;
    align-items: center;
    gap: 10px;
}
.sh-block-toggle {
    font-size: 14px;
    color: #666;
    user-select: none;
}
.sh-remove-block {
    color: #d63638;
    font-size: 13px;
    cursor: pointer;
    font-weight: 500;
}
.sh-remove-block:hover { text-decoration: underline; }
.sh-block-body {
    padding: 12px 15px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    background: #fff;
    box-sizing: border-box;
}
.sh-block-box.collapsed .sh-block-body { display: none; }
.sh-block-subtitle textarea {
    width: 100%;
    min-height: 50px;
    resize: vertical;
    padding: 8px 10px;
    box-sizing: border-box;
    border: 1px solid #ddd;
    border-radius: 6px;
    background: #fff;
    font-family: inherit;
    font-size: 13px;
}
.sh-block-addons {
    border-top: 1px dashed #ddd6fe;
    padding-top: 10px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.sh-block-addons-empty {
    padding: 12px 15px;
    text-align: center;
    color: #888;
    font-size: 13px;
    border: 1px dashed #ddd;
    border-radius: 6px;
    background: #fafafa;
}
.sh-add-addon-to-block { align-self: flex-start; }

.sh-addon-box {
    border: 1px solid #e0e0e0;
    background: #fdfdfd;
    border-radius: 8px;
    overflow: hidden;
    box-sizing: border-box;
}
.sh-addon-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    background: #f7f7fa;
    border-bottom: 1px solid #ececf1;
    cursor: pointer;
    flex-wrap: wrap;
    box-sizing: border-box;
}
.sh-addon-header .sh-addon-type {
    min-width: 150px;
    padding: 6px 8px;
    box-sizing: border-box;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #fff;
    font-size: 13px;
}
.sh-addon-header .sh-addon-title-input {
    flex: 1;
    min-width: 140px;
    padding: 6px 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-sizing: border-box;
    background: #fff;
    font-size: 13px;
}
.sh-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}
.sh-toggle { font-size: 13px; color: #666; user-select: none; }
.sh-remove-addon { color: #d63638; font-size: 13px; cursor: pointer; }
.sh-remove-addon:hover { text-decoration: underline; }
.sh-addon-body {
    padding: 10px 14px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    box-sizing: border-box;
    background: #fff;
}
.sh-addon-box.collapsed .sh-addon-body { display: none; }
.sh-addon-subtitle textarea {
    width: 100%;
    min-height: 55px;
    resize: vertical;
    padding: 8px 10px;
    box-sizing: border-box;
    border: 1px solid #ddd;
    border-radius: 6px;
    background: #fff;
    font-family: inherit;
    font-size: 13px;
}
.sh-addon-required-row {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 4px;
}
.sh-addon-required-row label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    cursor: pointer;
}
.sh-options-wrapper {
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
    box-sizing: border-box;
}
.sh-option-row {
    display: grid;
    grid-template-columns: 2fr 1fr 40px;
    gap: 10px;
    align-items: center;
    width: 100%;
    box-sizing: border-box;
}
.sh-option-row input[type="text"],
.sh-option-row input[type="number"] {
    width: 100%;
    padding: 6px 10px;
    box-sizing: border-box;
    border: 1px solid #ddd;
    border-radius: 6px;
    background: #fff;
    font-size: 13px;
}
.sh-remove {
    color: #c7383a;
    cursor: pointer;
    text-align: center;
    font-weight: bold;
    padding: 6px 8px;
    border-radius: 4px;
    user-select: none;
}
.sh-remove:hover { background: #fee2e2; }
.sh-add-option {
    align-self: flex-start;
    padding: 6px 14px;
    font-size: 13px;
}
.sh-textbox-price {
    display: none;
    gap: 8px;
    align-items: center;
}
.sh-textbox-price label { min-width: 90px; margin-right: 8px; font-size: 13px; }
.sh-textbox-price input {
    width: 200px;
    max-width: 100%;
    padding: 6px 10px;
    box-sizing: border-box;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 13px;
}

.spvm-addon-blocks-toggle {
    display: none;
    margin-bottom: 16px;
    padding: 12px 16px;
    background: linear-gradient(135deg, #f0f9ff, #e0e7ff);
    border: 1px solid #bae6fd;
    border-radius: 10px;
}
.spvm-digital-mode .spvm-addon-blocks-toggle {
    display: block;
}
.spvm-addon-blocks-toggle label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 14px;
}
.spvm-addon-blocks-toggle label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}
.spvm-addon-blocks-toggle .toggle-note {
    margin-top: 6px;
    font-size: 12.5px;
    color: #475569;
    line-height: 1.5;
}

.spvm-addons-note {
    background: #f0f9ff;
    border: 1px solid #bae6fd;
    border-radius: 8px;
    padding: 10px 14px;
    color: #0c4a6e;
    font-size: 13px;
    line-height: 1.6;
    margin-bottom: 14px;
}

/* FAQ */
#shqa_faq_items {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.shqa-faq-box {
    border: 1px solid #d6e4f0;
    background: #f9fbfd;
    border-radius: 8px;
    overflow: hidden;
    box-sizing: border-box;
}
.shqa-faq-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    background: #eaf2f9;
    border-bottom: 1px solid #d6e4f0;
    cursor: pointer;
    box-sizing: border-box;
}
.shqa-faq-header .shqa-faq-index {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 28px;
    height: 24px;
    padding: 0 8px;
    border-radius: 4px;
    background: #8B5CF6;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
}
.shqa-faq-header .shqa-faq-preview {
    flex: 1;
    min-width: 0;
    font-weight: 600;
    color: #1d2327;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 13px;
}
.shqa-faq-controls {
    display: flex;
    align-items: center;
    gap: 10px;
}
.shqa-faq-toggle {
    font-size: 13px;
    color: #666;
    user-select: none;
}
.shqa-faq-remove {
    color: #d63638;
    font-size: 13px;
    cursor: pointer;
}
.shqa-faq-remove:hover { text-decoration: underline; }
.shqa-faq-body {
    padding: 12px 14px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    background: #fff;
    box-sizing: border-box;
}
.shqa-faq-box.collapsed .shqa-faq-body { display: none; }
.shqa-faq-body label {
    display: block;
    font-weight: 600;
    font-size: 13px;
    color: #1d2327;
    margin-bottom: 4px;
}
.shqa-faq-body textarea {
    width: 100%;
    min-height: 60px;
    resize: vertical;
    padding: 8px 10px;
    box-sizing: border-box;
    border: 1px solid #ddd;
    border-radius: 6px;
    background: #fff;
    font-family: inherit;
    font-size: 13px;
    line-height: 1.5;
}
.shqa-faq-body textarea:focus {
    border-color: #8B5CF6;
    box-shadow: 0 0 0 3px rgba(139,92,246,0.1);
    outline: none;
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
    .spui-item { flex-direction: column; gap: 8px; }
    .spui-label, .spui-value { flex: none; width: 100%; max-width: 100%; }
    .spui-upload-card { width: 100%; max-width: 160px; height: auto; min-height: 140px; }
    .spvm-step-section { padding: 16px 18px; }
    .spvm-step-header h2 { font-size: 16px; }
    .spvm-ai-header { flex-direction: column; align-items: stretch; }
    .spvm-ai-header .ai-title { flex-wrap: wrap; }
    .spvm-ai-header .ai-title .ai-subtitle {
        flex-basis: 100%;
        margin-top: 4px;
        margin-left: 0;
        font-size: 12px;
    }
    .spvm-ai-actions { justify-content: center; }
    .spvm-ai-btn { justify-content: center; flex: 1; }
    .stock-management-row { flex-direction: column; align-items: stretch; }
    .attribute-item { flex-direction: column; }
    .attribute-name-col { flex: none; width: 100%; max-width: 100%; }
    .attribute-value-col { width: 100%; }
    .feature-row { flex-direction: column; }
    .feature-select-wrapper, .feature-value-wrapper { width: 100%; }
    .gallery-thumbs { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 8px; }
    .gallery-thumb { flex-shrink: 0; }
    .spvm-modal { padding: 30px 20px; }
    .spvm-toast { bottom: 20px; right: 20px; left: 20px; text-align: center; }
    .spvm-error-toast { top: 20px; right: 20px; left: 20px; max-width: none; }
    .domestic-shipping-row { flex-direction: column; align-items: stretch !important; }
    .domestic-shipping-row .method-label { min-width: 0; width: 100%; }
    .domestic-shipping-row .method-fields {
        flex-direction: column;
        align-items: stretch !important;
        gap: 8px;
        width: 100%;
    }
    .domestic-shipping-row .method-fields .price-field { min-width: 0; width: 100%; }
    .domestic-shipping-row .method-fields .cod-field {
        white-space: normal;
        width: 100%;
        justify-content: flex-start;
        flex-wrap: wrap;
        word-break: break-word;
    }
    .sh-option-row { grid-template-columns: 1fr; }
    .sh-remove { grid-column: 1 / -1; text-align: left; }
    .sh-addon-header { flex-direction: column; align-items: stretch; gap: 8px; }
    .sh-addon-header .sh-addon-type,
    .sh-addon-header .sh-addon-title-input { width: 100%; }
}
@media (max-width: 480px) {
    .spvm-step-header { flex-direction: column; align-items: flex-start; gap: 4px; }
}

/* ======================= Product listing table ======================== */

.spvm-product-listing {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
}
.spvm-product-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}
.spvm-product-table th {
    background: #f8fafc;
    padding: 12px 15px;
    text-align: left;
    font-weight: 600;
    color: #1e293b;
    border-bottom: 2px solid #e2e8f0;
}
.spvm-product-table td {
    padding: 12px 15px;
    border-bottom: 1px solid #e2e8f0;
    vertical-align: middle;
}
.spvm-product-table tr:hover td {
    background: #f8fafc;
}
.spvm-product-image {
    width: 50px;
    height: 50px;
    object-fit: cover;
    border-radius: 8px;
}
.spvm-product-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}
.spvm-btn {
    padding: 6px 14px;
    border: none;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}
.spvm-btn-edit {
    background: #fbbf24;
    color: #1a1a2e;
}
.spvm-btn-edit:hover {
    background: #f59e0b;
    transform: translateY(-1px);
}
.spvm-btn-delete {
    background: #ef4444;
    color: white;
}
.spvm-btn-delete:hover {
    background: #dc2626;
    transform: translateY(-1px);
}
.spvm-btn-view {
    background: #3b82f6;
    color: white;
}
.spvm-btn-view:hover {
    background: #2563eb;
    transform: translateY(-1px);
}
.spvm-status {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    display: inline-block;
}
.spvm-status-publish {
    background: #d1fae5;
    color: #065f46;
}
.spvm-status-draft {
    background: #fef3c7;
    color: #92400e;
}
.spvm-status-pending {
    background: #fce4ec;
    color: #c62828;
}
.spvm-status-revised {
    background: #fef3c7;
    color: #92400e;
    border: 1px solid #f59e0b;
}
.spvm-no-products {
    text-align: center;
    padding: 40px;
    color: #64748b;
    font-size: 16px;
}
@media (max-width: 768px) {
    .spvm-product-table {
        font-size: 14px;
    }
    .spvm-product-table th,
    .spvm-product-table td {
        padding: 8px 10px;
    }
    .spvm-product-actions {
        flex-direction: column;
        gap: 4px;
    }
    .spvm-btn {
        font-size: 12px;
        padding: 4px 10px;
    }
}

/* ======================= Manual mode notice =========================
   Shown when "I cannot find a suitable category" or "I cannot find the
   product type" is checked: the attributes / features sections are hidden
   and our specialists take over the product classification. */
.spvm-manual-review-notice {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin: 18px 0 4px;
    padding: 18px 20px;
    border-radius: 14px;
    border: 1px solid #dbeafe;
    border-right: 4px solid #3b82f6;
    border-inline-start: 4px solid #3b82f6;
    background: linear-gradient(135deg, #eff6ff 0%, #f8fafc 100%);
    color: #1e293b;
}
.spvm-manual-review-icon {
    font-size: 26px;
    line-height: 1;
    flex: 0 0 auto;
}
.spvm-manual-review-body h3 {
    margin: 0 0 6px;
    font-size: 16px;
    font-weight: 700;
    color: #1d4ed8;
}
.spvm-manual-review-body p {
    margin: 0;
    font-size: 14px;
    line-height: 1.9;
    color: #334155;
}
@media (max-width: 600px) {
    .spvm-manual-review-notice { flex-direction: column; gap: 10px; }
}

/* ===== Manual mode ("cannot find category / type"): locked sections =====
   وقتی یکی از دو چک‌باکس تیک بخورد، هر دو بخش «دسته‌بندی» و «نوع محصول»
   قفل می‌شوند تا محصول بدون ابهام برای بررسی کارشناسان برود. */
#product_category_select:disabled,
#product_type_select:disabled,
#product_category_search:disabled,
#category_search_clear:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

/* =====================================================================
   SUBMISSION PROGRESS MODAL (AJAX upload progress + result)
   ===================================================================== */
.spvm-proc-overlay {
    position: fixed;
    inset: 0;
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(15, 23, 42, 0.55);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}
.spvm-proc-overlay.is-active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}
body.spvm-proc-open { overflow: hidden; }

.spvm-proc-card {
    position: relative;
    width: min(440px, 94vw);
    padding: 34px 30px 30px;
    background: #fff;
    border: 1px solid rgba(99, 102, 241, 0.14);
    border-radius: 26px;
    box-shadow: 0 30px 80px -24px rgba(49, 46, 129, 0.55), 0 8px 24px -12px rgba(15, 23, 42, 0.25);
    overflow: hidden;
    text-align: center;
    transform: translateY(16px) scale(0.97);
    opacity: 0;
    transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.25s ease;
}
.spvm-proc-overlay.is-active .spvm-proc-card {
    transform: translateY(0) scale(1);
    opacity: 1;
}

.spvm-proc-glow {
    position: absolute;
    top: -90px;
    inset-inline-start: 50%;
    width: 260px;
    height: 260px;
    margin-inline-start: -130px;
    background: radial-gradient(circle at 50% 50%, rgba(139, 92, 246, 0.35), rgba(99, 102, 241, 0.12) 45%, transparent 70%);
    filter: blur(8px);
    pointer-events: none;
}

.spvm-proc-state { position: relative; z-index: 1; }
.spvm-proc-state[hidden] { display: none; }

/* ---------- progress ring ---------- */
.spvm-proc-ring {
    position: relative;
    width: 150px;
    height: 150px;
    margin: 0 auto 8px;
}
.spvm-proc-ring svg {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}
.spvm-proc-ring-track,
.spvm-proc-ring-bar {
    fill: none;
    stroke-width: 9;
    stroke-linecap: round;
}
.spvm-proc-ring-track { stroke: #eef2ff; }
.spvm-proc-ring-bar {
    stroke: #6366f1;
    filter: drop-shadow(0 0 7px rgba(99, 102, 241, 0.45));
    transition: stroke-dashoffset 0.3s ease;
}
.spvm-proc-percent {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 27px;
    font-weight: 800;
    color: #1e293b;
    letter-spacing: -0.5px;
    font-variant-numeric: tabular-nums;
}

.spvm-proc-title {
    margin: 6px 0 6px;
    font-size: 18px;
    font-weight: 800;
    color: #0f172a;
    line-height: 1.5;
}
.spvm-proc-status {
    margin: 0 0 18px;
    font-size: 13.5px;
    line-height: 1.8;
    color: #64748b;
    min-height: 22px;
}

/* ---------- step chips ---------- */
.spvm-proc-steps {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    margin: 0 0 16px;
}
.spvm-proc-step {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 11px;
    border-radius: 999px;
    background: #f8fafc;
    border: 1px solid #eef2f7;
    color: #94a3b8;
    font-size: 12px;
    font-weight: 600;
    transition: color 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}
.spvm-proc-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #cbd5e1;
    flex: 0 0 auto;
    transition: background 0.2s ease;
}
.spvm-proc-step.is-active {
    background: #eef2ff;
    border-color: #c7d2fe;
    color: #4338ca;
}
.spvm-proc-step.is-active .spvm-proc-dot {
    background: #6366f1;
    animation: spvmProcPulse 1.2s ease-in-out infinite;
}
.spvm-proc-step.is-done {
    background: #ecfdf5;
    border-color: #a7f3d0;
    color: #047857;
}
.spvm-proc-step.is-done .spvm-proc-dot { background: #10b981; }

.spvm-proc-hint {
    margin: 0;
    font-size: 11.5px;
    line-height: 1.8;
    color: #94a3b8;
}

/* ---------- result ---------- */
.spvm-proc-result { padding-bottom: 4px; }
.spvm-proc-result-icon {
    width: 78px;
    height: 78px;
    margin: 4px auto 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: #fff;
    font-size: 34px;
    font-weight: 800;
    line-height: 1;
    animation: spvmProcPop 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}
.spvm-proc-result.is-success .spvm-proc-result-icon {
    background: linear-gradient(135deg, #34d399, #059669);
    box-shadow: 0 14px 32px -10px rgba(16, 185, 129, 0.65);
}
.spvm-proc-result.is-error .spvm-proc-result-icon {
    background: linear-gradient(135deg, #fb7185, #e11d48);
    box-shadow: 0 14px 32px -10px rgba(225, 29, 72, 0.6);
}
.spvm-proc-result.is-error .spvm-proc-title { color: #be123c; }
.spvm-proc-result.is-success .spvm-proc-title { color: #047857; }

.spvm-proc-errors {
    margin: 0 0 16px;
    padding: 10px 14px 10px 32px;
    padding-inline-start: 32px;
    padding-inline-end: 14px;
    border-radius: 12px;
    background: #fff1f2;
    border: 1px solid #fecdd3;
    color: #9f1239;
    font-size: 12.5px;
    line-height: 1.9;
    text-align: start;
}
.spvm-proc-errors:empty { display: none; }
.spvm-proc-errors li + li { margin-top: 4px; }

.spvm-proc-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin-top: 4px;
}
.spvm-proc-btn {
    padding: 11px 22px;
    border: none;
    border-radius: 12px;
    font-size: 13.5px;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.2s ease, background 0.2s ease;
}
.spvm-proc-btn[hidden] { display: none; }
.spvm-proc-btn-primary {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    color: #fff;
    box-shadow: 0 10px 24px -10px rgba(99, 102, 241, 0.85);
}
.spvm-proc-btn-primary:hover { transform: translateY(-1px); box-shadow: 0 14px 28px -10px rgba(99, 102, 241, 0.95); }
.spvm-proc-btn-ghost {
    background: #f8fafc;
    color: #475569;
    border: 1px solid #e2e8f0;
}
.spvm-proc-btn-ghost:hover { background: #f1f5f9; }

/* ---------- bottom meter ---------- */
.spvm-proc-meter {
    position: absolute;
    inset-inline: 0;
    bottom: 0;
    height: 4px;
    background: #f1f5f9;
}
.spvm-proc-meter span {
    display: block;
    width: 0;
    height: 100%;
    border-radius: 0 4px 4px 0;
    background: linear-gradient(90deg, #6366f1, #8b5cf6, #ec4899);
    transition: width 0.25s ease;
}

/* ---------- submit button loading ---------- */
.spvm-submit-btn.is-loading {
    opacity: 0.75;
    cursor: progress;
    transform: none !important;
    box-shadow: none !important;
}

@keyframes spvmProcPulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(99, 102, 241, 0.45); }
    50% { box-shadow: 0 0 0 6px rgba(99, 102, 241, 0); }
}
@keyframes spvmProcPop {
    from { transform: scale(0.6); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

@media (max-width: 480px) {
    .spvm-proc-card { padding: 26px 20px 24px; border-radius: 22px; }
    .spvm-proc-ring { width: 128px; height: 128px; }
    .spvm-proc-percent { font-size: 23px; }
    .spvm-proc-steps { gap: 6px; }
    .spvm-proc-step { font-size: 11px; padding: 5px 9px; }
}

@media (prefers-reduced-motion: reduce) {
    .spvm-proc-card,
    .spvm-proc-overlay,
    .spvm-proc-step,
    .spvm-proc-dot,
    .spvm-proc-result-icon { transition: none !important; animation: none !important; }
}