/* Estilos públicos de SM Demo Plugins */

.sm-demo-plugins-container {
    max-width: 100%;
    margin: 0 auto;
    padding: 20px;
}

/* Layout principal */
.sm-demo-layout {
    display: flex;
    gap: 20px;
    min-height: 600px;
}

/* Sidebar de la tienda de plugins */
.sm-demo-sidebar {
    width: 300px;
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.sm-plugin-card {
    background: white;
    padding: 15px;
    margin-bottom: 15px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.sm-plugin-card:hover {
    border-color: #0073aa;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.sm-plugin-card.active {
    border-color: #0073aa;
    background: #e7f5ff;
}

.sm-plugin-card h3 {
    margin: 0 0 10px 0;
    font-size: 16px;
    color: #333;
}

.sm-plugin-card p {
    margin: 0;
    font-size: 13px;
    color: #666;
}

/* Área de widgets disponibles */
.sm-widgets-panel {
    width: 250px;
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.sm-widget-item {
    background: white;
    padding: 12px;
    margin-bottom: 10px;
    border-radius: 6px;
    cursor: move;
    border: 2px solid #ddd;
    transition: all 0.3s ease;
}

.sm-widget-item:hover {
    border-color: #0073aa;
    transform: scale(1.05);
}

.sm-widget-item h4 {
    margin: 0 0 5px 0;
    font-size: 14px;
}

.sm-widget-item p {
    margin: 0;
    font-size: 12px;
    color: #666;
}

/* Canvas del editor */
.sm-demo-canvas {
    flex: 1;
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    min-height: 600px;
    position: relative;
}

.sm-canvas-dropzone {
    min-height: 500px;
    border: 2px dashed #ddd;
    border-radius: 8px;
    padding: 20px;
}

.sm-canvas-dropzone.drag-over {
    border-color: #0073aa;
    background: #f0f8ff;
}

.sm-canvas-empty {
    text-align: center;
    padding: 100px 20px;
    color: #999;
}

.sm-canvas-empty h3 {
    font-size: 24px;
    margin-bottom: 10px;
}

/* Widget en el canvas */
.sm-canvas-widget {
    background: white;
    padding: 20px;
    margin-bottom: 15px;
    border: 2px solid #ddd;
    border-radius: 6px;
    position: relative;
    cursor: move;
    transition: all 0.3s ease;
}

.sm-canvas-widget:hover {
    border-color: #0073aa;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.sm-canvas-widget.selected {
    border-color: #0073aa;
    box-shadow: 0 0 0 3px rgba(0, 115, 170, 0.1);
}

.sm-widget-controls {
    position: absolute;
    top: 10px;
    right: 10px;
    display: flex;
    gap: 5px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.sm-canvas-widget:hover .sm-widget-controls {
    opacity: 1;
}

.sm-widget-btn {
    background: white;
    border: 1px solid #ddd;
    padding: 5px 10px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
}

.sm-widget-btn:hover {
    background: #0073aa;
    color: white;
    border-color: #0073aa;
}

/* Panel de propiedades */
.sm-properties-panel {
    width: 300px;
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.sm-property-group {
    margin-bottom: 20px;
}

.sm-property-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    font-size: 13px;
    color: #333;
}

.sm-property-group input,
.sm-property-group textarea,
.sm-property-group select {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 13px;
}

.sm-property-group textarea {
    min-height: 80px;
    resize: vertical;
}

/* Botones de acción */
.sm-action-buttons {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.sm-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.sm-btn-primary {
    background: #0073aa;
    color: white;
}

.sm-btn-primary:hover {
    background: #005a87;
}

.sm-btn-secondary {
    background: #f0f0f0;
    color: #333;
}

.sm-btn-secondary:hover {
    background: #ddd;
}

/* Carrito flotante */
.sm-cart-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: #0073aa;
    color: white;
    padding: 15px 25px;
    border-radius: 50px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    cursor: pointer;
    z-index: 1000;
    transition: all 0.3s ease;
}

.sm-cart-float:hover {
    background: #005a87;
    transform: scale(1.05);
}

.sm-cart-count {
    background: #ff5722;
    color: white;
    border-radius: 50%;
    padding: 2px 8px;
    font-size: 12px;
    font-weight: bold;
    margin-left: 10px;
}

/* Modal de checkout */
.sm-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 10000;
    align-items: center;
    justify-content: center;
}

.sm-modal.active {
    display: flex;
}

.sm-modal-content {
    background: white;
    padding: 30px;
    border-radius: 12px;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
}

.sm-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #f0f0f0;
}

.sm-modal-close {
    cursor: pointer;
    font-size: 24px;
    color: #999;
}

.sm-modal-close:hover {
    color: #333;
}

/* Responsive */
@media (max-width: 1200px) {
    .sm-demo-layout {
        flex-wrap: wrap;
    }

    .sm-demo-sidebar,
    .sm-widgets-panel,
    .sm-properties-panel {
        width: 100%;
    }
}