/* Mobile styles for price-editor */
/* Enable horizontal scroll for wide tables on small screens */
@media (max-width: 768px) {

    #sec-line-1,
    #sec-line-2,
    #sec-line-3 {
        width: 95%;
    }

    /* Container to allow horizontal scrolling */
    .table-wrapper {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    /* Increase readable font size on mobile */
    body {
        font-size: 16px;
        /* default readable size */
        line-height: 1.4;
    }

    /* Ensure table cells have adequate padding and font size */
    .price-page tbody td {
        font-size: 6.5pt;
        padding: 0.5rem 0;
    }

    /* Keep native table layout but prevent columns from collapsing */
    .price-page,
    .log-table {
        display: table;
        width: 100%;
        /* Preserve original cell spacing (cellspacing="7") */
        border-collapse: separate;
        border-spacing: 3px;
        min-width: 600px;
        /* enough width for all 6 columns */
    }

    /* Allow horizontal scroll while keeping header visible */
    .price-page thead {
        display: table-header-group;
    }

    .price-page tbody tr {
        display: table-row;
    }

    .price-page tbody td, .log-table tbody td {
        display: table-cell;
        text-align: left;
        padding: 0.5rem;

    }

    /* Hide editing controls */
    .edit-btn,
    input[type="text"],
    select {
        display: none !important;
    }

    .contacts-grid {
        grid-template-columns: 1fr;
    }
}

/* Restore desktop layout */
@media (min-width: 769px) {

    .edit-btn,
    input[type="text"],
    select {
        display: inline-block !important;
    }
}