/* ===== Desktop & Mobile Global Tweaks ===== */
body {
    overflow-x: hidden;
}

/* Ensure images don't break layout */
img {
    max-width: 100%;
    height: auto;
}

/* Sidebar behavior */
@media (max-width: 768px) {
    /* Mobile par sidebar ko overlay banayenge */
    .side-nav {
        display: none; /* Default band */
        position: fixed !important;
        top: 60px; /* Header height */
        left: 0;
        width: 260px;
        height: calc(100% - 60px);
        z-index: 1050;
        background: #fff;
        overflow-y: auto;
    }
    
    /* Jab active ho (JS handle karegi) */
    .side-nav.is-active {
        left: 0;
    }
    
    /* Content ka margin reset */
    .page-container {
        padding-left: 0 !important;
    }
}
    
/* Responsive Table Full Fix */
    .table-responsive {
    display: block;
        width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    }

.table {
    width: 100% !important;

    margin-bottom: 1rem;
    color: #212529;


    table-layout: auto; 
}

.table th, .table td {
    padding: 8px;
    vertical-align: middle;



    font-size: 13px;
}

/* Card Improvements */
.card {
    border: none;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

/* Buttons for mobile */
.btn {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
}

@media (max-width: 576px) {
    .btn {
        width: 100%;
        margin-bottom: 5px;
    }
}

/* ===== CustomerLedger/AdminCpv UI Fixes ===== */
.action-buttons-flex {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.action-buttons-flex a img {
    width: 20px;
    height: 20px;
    opacity: 0.7;
    transition: opacity 0.2s;
}

.action-buttons-flex a:hover img {
    opacity: 1;
}

@media (max-width: 768px) {
    .row.g-3 > div {
        margin-bottom: 10px;
    }
}
