
/* Newsletter responsive styles */
section[style*="background-color:rgb(247,247,247)"] {
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
    overflow-x: hidden;
    box-sizing: border-box;
}

/* Desktop styles - fixed width */
@media (min-width: 769px) {
    section[style*="background-color:rgb(247,247,247)"] {
        width: 800px;
        max-width: 800px;
    }
}

/* Mobile styles - prevent horizontal scroll */
@media (max-width: 768px) {
    /* Global prevention of horizontal scroll */
    html, body {
        overflow-x: hidden !important;
        max-width: 100vw !important;
        width: 100% !important;
    }
    
    section[style*="background-color:rgb(247,247,247)"] {
        width: 100% !important;
        max-width: 100% !important;
        overflow-x: hidden !important;
        transform: none !important;
        box-sizing: border-box !important;
    }
    
    /* Force all tables to be responsive */
    section[style*="background-color:rgb(247,247,247)"] table {
        width: 100% !important;
        max-width: 100% !important;
        min-width: auto !important;
        transform: none !important;
        table-layout: auto !important;
    }
    
    /* Force all table cells to be responsive */
    section[style*="background-color:rgb(247,247,247)"] td,
    section[style*="background-color:rgb(247,247,247)"] th {
        width: auto !important;
        max-width: 100% !important;
        min-width: auto !important;
        word-wrap: break-word !important;
        overflow-wrap: break-word !important;
        overflow: hidden !important;
        white-space: normal !important;
    }
    
    /* Force all divs to be responsive */
    section[style*="background-color:rgb(247,247,247)"] div {
        width: auto !important;
        max-width: 100% !important;
        overflow: hidden !important;
        box-sizing: border-box !important;
    }
    
    /* Force all images to be responsive */
    section[style*="background-color:rgb(247,247,247)"] img {
        max-width: 100% !important;
        height: auto !important;
        width: auto !important;
    }
    
    /* Remove any fixed widths */
    section[style*="background-color:rgb(247,247,247)"] [style*="width: 660px"] {
        width: 100% !important;
        max-width: 100% !important;
    }
    
    section[style*="background-color:rgb(247,247,247)"] [style*="width:660px"] {
        width: 100% !important;
        max-width: 100% !important;
    }
    
    /* Force all elements with any width to be responsive */
    section[style*="background-color:rgb(247,247,247)"] [style*="width"] {
        max-width: 100% !important;
        box-sizing: border-box !important;
    }
    
    /* Adjust padding for mobile */
    section[style*="background-color:rgb(247,247,247)"] [style*="padding-right: 30px"],
    section[style*="background-color:rgb(247,247,247)"] [style*="padding-left: 30px"] {
        padding-right: 15px !important;
        padding-left: 15px !important;
    }
}

/* Very small screens */
@media (max-width: 480px) {
    section[style*="background-color:rgb(247,247,247)"] [style*="padding-right: 30px"],
    section[style*="background-color:rgb(247,247,247)"] [style*="padding-left: 30px"] {
        padding-right: 10px !important;
        padding-left: 10px !important;
    }
}