/* ShopGlut Quick View Admin CSS */

/* Remove blue focus borders on quickview elements */
.shopglut-quickview button:focus,
.shopglut-quickview .button:focus,
.shopglut-quickview a:focus,
.shopglut-quickview .nav-tab:focus,
.shopglut-quickview input:focus,
.shopglut-quickview select:focus,
.shopglut-quickview-admin button:focus,
.shopglut-quickview-admin .button:focus,
.shopglut-quickview-admin a:focus,
.shopglut-quickview-admin .nav-tab:focus,
.shopglut-editor-tab:focus,
.shopglut-quickview-modal button:focus,
.shopglut-quickview-modal .button:focus,
.shopglut-quickview-modal a:focus {
    outline: none !important;
    box-shadow: none !important;
    border-color: initial !important;
}

/* Prevent body scroll when modal is open */
body.shopglut-modal-open {
    overflow: hidden;
}

.shopglut-quickview-list {
    background: white;
    border: 1px solid #ccd0d4;
    border-radius: 4px;
    margin-top: 20px;
}

.shopglut-quickview-item {
    display: flex;
    align-items: center;
    padding: 15px 20px;
    border-bottom: 1px solid #f0f0f1;
    transition: background-color 0.2s;
}

.shopglut-quickview-item:last-child {
    border-bottom: none;
}

.shopglut-quickview-item:hover {
    background-color: #f6f7f7;
}

.shopglut-quickview-info {
    flex: 1;
}

.shopglut-quickview-name {
    font-weight: 600;
    font-size: 16px;
    margin-bottom: 5px;
    color: #1d2327;
}

.shopglut-quickview-description {
    color: #646970;
    font-size: 14px;
    margin-bottom: 8px;
}

.shopglut-quickview-features {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.shopglut-quickview-feature {
    font-size: 12px;
    color: #646970;
    background: #f0f0f1;
    padding: 3px 8px;
    border-radius: 3px;
}

.shopglut-quickview-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

.shopglut-quickview-status {
    position: relative;
}

.shopglut-toggle-switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
}

.shopglut-toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.shopglut-toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: 0.3s;
    border-radius: 24px;
}

.shopglut-toggle-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}

input:checked + .shopglut-toggle-slider {
    background-color: #0073aa;
}

input:checked + .shopglut-toggle-slider:before {
    transform: translateX(26px);
}

.shopglut-edit-quickview-btn {
    background: #0073aa;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    text-decoration: none;
    font-size: 13px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: background-color 0.2s;
}

.shopglut-edit-quickview-btn:hover {
    background: #005a87;
    color: white;
    text-decoration: none;
}

/* Modal overlay background */
.shopglut-quickview-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
}

.shopglut-quickview-editor {
    background: white;
    border: 1px solid #ccd0d4;
    border-radius: 8px;
    padding: 0;
    max-width: 800px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    position: relative;
}

.shopglut-editor-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 20px 15px 20px;
    border-bottom: 1px solid #f0f0f1;
    background: #f9f9f9;
    border-radius: 8px 8px 0 0;
    margin-bottom: 0;
}

.shopglut-editor-title {
    font-size: 20px;
    font-weight: 600;
    margin: 0;
    color: #1d2327;
}

.shopglut-close-editor {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    padding: 8px;
    color: #646970;
    border-radius: 4px;
    transition: all 0.2s;
    line-height: 1;
}

.shopglut-close-editor:hover {
    color: #d63638;
    background: rgba(0, 0, 0, 0.1);
}

.shopglut-editor-tabs {
    display: flex;
    border-bottom: 1px solid #ccd0d4;
    margin-bottom: 0;
    background: white;
    padding: 0 20px;
}

.shopglut-editor-tab {
    padding: 12px 20px;
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    cursor: pointer;
    font-weight: 500;
    color: #646970;
    transition: all 0.2s;
}

.shopglut-editor-tab.active {
    color: #0073aa;
    border-bottom-color: #0073aa;
}

.shopglut-editor-tab:hover {
    color: #0073aa;
}

.shopglut-editor-content {
    display: none;
    padding: 20px;
}

.shopglut-editor-content.active {
    display: block;
}

.shopglut-form-group {
    margin-bottom: 20px;
}

.shopglut-form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #1d2327;
}

.shopglut-form-control {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #8c8f94;
    border-radius: 4px;
    font-size: 14px;
}

.shopglut-form-control:focus {
    border-color: #0073aa;
    box-shadow: 0 0 0 1px #0073aa;
    outline: none;
}

.shopglut-checkbox-group {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
}

.shopglut-checkbox-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.shopglut-checkbox-item input[type="checkbox"] {
    margin: 0;
}

.shopglut-checkbox-item label {
    margin: 0;
    font-weight: normal;
    cursor: pointer;
}

.shopglut-editor-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 0;
    padding: 20px;
    border-top: 1px solid #f0f0f1;
    background: #f9f9f9;
    border-radius: 0 0 8px 8px;
}

.shopglut-save-quickview {
    background: #00a32a;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
}

.shopglut-save-quickview:hover {
    background: #008a20;
}

.shopglut-quickview-preview {
    padding: 20px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #f9f9f9;
    margin-top: 20px;
}

.shopglut-quickview-preview h4 {
    margin-top: 0;
    margin-bottom: 15px;
    color: #1d2327;
}

.shopglut-preview-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid #eee;
}

.shopglut-preview-item:last-child {
    border-bottom: none;
}

.shopglut-preview-label {
    font-weight: 500;
    color: #646970;
}

.shopglut-preview-value {
    color: #0073aa;
    font-weight: 500;
}

.shopglut-color-picker {
    display: flex;
    align-items: center;
    gap: 10px;
}

.shopglut-color-input {
    width: 50px !important;
    height: 35px;
    padding: 2px;
    border-radius: 4px;
}

.shopglut-dimension-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.shopglut-help-text {
    font-size: 12px;
    color: #646970;
    margin-top: 5px;
    font-style: italic;
}

@media (max-width: 768px) {
    .shopglut-quickview-item {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
    }
    
    .shopglut-quickview-actions {
        justify-content: space-between;
    }
    
    .shopglut-quickview-modal-overlay {
        padding: 10px;
    }
    
    .shopglut-quickview-editor {
        max-width: 100%;
        max-height: 95vh;
        margin: 0;
    }
    
    .shopglut-editor-header {
        padding: 15px;
    }
    
    .shopglut-editor-tabs {
        flex-wrap: wrap;
        padding: 0 15px;
    }
    
    .shopglut-editor-content {
        padding: 15px;
    }
    
    .shopglut-editor-actions {
        padding: 15px;
    }
    
    .shopglut-checkbox-group {
        grid-template-columns: 1fr;
    }
    
    .shopglut-dimension-group {
        grid-template-columns: 1fr;
    }
}