/**
 * Waita Market Add-on - Elementor Canvas Full Width Styles
 * This file ensures all market pages work properly with Elementor Canvas template
 */

/* Force Elementor Canvas behavior */
body.elementor-template-canvas {
    margin: 0 !important;
    padding: 0 !important;
    background: var(--wma-bg-secondary);
}

/* Remove theme styles that might interfere */
body.elementor-template-canvas * {
    box-sizing: border-box;
}

/* Elementor Canvas Container Overrides */
.elementor-template-canvas .elementor-section {
    width: 100vw !important;
    margin-left: calc(-50vw + 50%) !important;
    min-height: 100vh;
}

.elementor-template-canvas .elementor-container {
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    width: 100%;
}

.elementor-template-canvas .elementor-column {
    width: 100% !important;
}

.elementor-template-canvas .elementor-widget-wrap {
    padding: 0 !important;
}

/* Market Component Base Styles */
.wma-list-builder,
.wma-shopper-dashboard,
.wma-wallet,
.wma-order-tracking,
.wma-chat,
.wma-shopper-login-container {
    width: 100%;
    min-height: calc(100vh - 64px); /* Account for header height */
    padding: 20px;
    box-sizing: border-box;
    font-family: var(--wma-font-text);
}

/* Specific Background - Use Theme Colors */
.wma-list-builder {
    background: var(--wma-bg-secondary);
}

.wma-shopper-dashboard {
    background: var(--wma-bg-secondary);
}

.wma-wallet {
    background: var(--wma-bg-secondary);
}

.wma-order-tracking {
    background: var(--wma-bg-secondary);
}

.wma-chat {
    background: var(--wma-bg);
    display: flex;
    align-items: center;
    justify-content: center;
}

.wma-shopper-login-container {
    background: var(--wma-bg);
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Content Containers */
.wma-content-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Adjust for header when logged in */
body.logged-in .wma-content-container {
    padding-top: 0; /* Header handles spacing */
}

/* Responsive Design */
@media (max-width: 768px) {
    .wma-list-builder,
    .wma-shopper-dashboard,
    .wma-wallet,
    .wma-order-tracking,
    .wma-chat,
    .wma-shopper-login-container {
        padding: 20px 15px;
    }
    
    .wma-content-container {
        padding: 0 15px;
    }
}

/* Remove any theme interference */
.elementor-template-canvas .site-header,
.elementor-template-canvas .site-footer,
.elementor-template-canvas .site-navigation,
.elementor-template-canvas .breadcrumb,
.elementor-template-canvas .sidebar {
    display: none !important;
}

/* Ensure full width */
.elementor-template-canvas .container,
.elementor-template-canvas .wrap,
.elementor-template-canvas .content-area {
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
}