/* MG 3D Viewer Frontend Styles */
.mg-3d-viewer-wrapper {
    position: relative;
}

.mg-3d-viewer-container {
    position: relative;
    width: 100%;
    height: 400px;
    border: 1px solid #ddd;
    border-radius: 4px;
    overflow: hidden;
    background: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mg-3d-viewer-container canvas {
    display: block;
    max-width: 100%;
    max-height: 100%;
    cursor: grab;
}
.mg-3d-viewer-container canvas:active {
    cursor: grabbing;
}

.mg-3d-loading, .mg-3d-error {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    color: #555;
    padding: 10px 15px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 4px;
    display: flex;
    align-items: center;
}

.mg-3d-error {
    color: #d63638;
}

.mg-3d-loading span {
    width: 16px;
    height: 16px;
    border: 2px solid rgba(0,0,0,0.1);
    border-top-color: #007cba;
    border-radius: 50%;
    animation: mg-3d-spin 1s linear infinite;
    margin-right: 8px;
}

/* AR Button */
.mg-3d-ar-button {
    position: absolute;
    bottom: 15px;
    right: 15px;
    padding: 8px 12px;
    background-color: rgba(0, 0, 0, 0.6);
    color: white;
    text-decoration: none;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 500;
    transition: background-color 0.2s;
}
.mg-3d-ar-button:hover {
    background-color: rgba(0, 0, 0, 0.8);
}

/* Responsive design */
@media (max-width: 768px) {
    .mg-3d-viewer-container {
        height: 300px;
    }
}

@media (max-width: 480px) {
    .mg-3d-viewer-container {
        height: 250px;
    }
}

@keyframes mg-3d-spin {
    to { transform: rotate(360deg); }
}
