:root {
    --primary-color: #ffb800;
    --primary-hover: #e5a600;
    --dark-blue: #1e293b;
    --text-main: #333333;
    --text-muted: #6b7280;
    --bg-light: #f8fafc;
    --border-color: #e5e7eb;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', 'Prompt', sans-serif;
}

html {
    overflow-y: scroll;
    scrollbar-gutter: stable;
}

body {
    background-color: #ffffff;
    color: var(--text-main);
    min-height: 100vh;
}

header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: #ffffff;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

.top-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

.logo-area {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: #e11d48;
    font-weight: 700;
    font-size: 1.5rem;
}
.logo-area span { color: #2563eb; }

.search-bar {
    display: flex;
    align-items: center;
    flex: 1;
    max-width: 500px;
    margin: 0 2rem;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    overflow: hidden;
}
.search-bar input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: none;
    outline: none;
}
.search-bar button {
    background: white;
    border: none;
    padding: 0.75rem 1rem;
    cursor: pointer;
    color: var(--text-muted);
}

.header-links {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}
.header-links a {
    color: var(--text-main);
    text-decoration: none;
    font-size: 0.9rem;
}

.cart-btn {
    background-color: var(--primary-color);
    color: #000;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
}
.cart-badge {
    background: #000;
    color: #fff;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
}

/* Dark Nav */
.dark-nav {
    background-color: var(--dark-blue);
    height: 50px;
    width: 100%;
}

/* Features Bar */
.features-bar {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    padding: 2rem;
    max-width: 1400px;
    margin: 0 auto;
    border-bottom: 1px solid var(--border-color);
}
.feature-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}
.feature-item i {
    color: #3b82f6;
    font-size: 1.5rem;
    margin-top: 0.25rem;
}
.feature-text h4 {
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
}
.feature-text p {
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* Container */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}
.section-header h2 {
    font-size: 1.15rem;
    color: var(--dark-blue);
}
.section-header a {
    color: #3b82f6;
    text-decoration: none;
    font-size: 0.85rem;
}

/* Category Grid */
.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 0.75rem;
}

.category-card {
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 0.75rem 0.5rem;
    text-align: center;
    text-decoration: none;
    color: var(--text-main);
    transition: all 0.25s ease;
    background: white;
}
.category-card:hover {
    box-shadow: 0 6px 12px -2px rgba(0, 0, 0, 0.08);
    border-color: #3b82f6;
    transform: translateY(-2px);
}
.category-img {
    width: 60px;
    height: 60px;
    margin: 0 auto 0.4rem auto;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--bg-light);
    border-radius: 6px;
}
.category-img i {
    font-size: 2rem;
    color: #94a3b8;
}
.category-card h3 {
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 0.15rem;
    line-height: 1.25;
}
.category-card p {
    font-size: 0.7rem;
    color: var(--text-muted);
}

/* Form Styles */
.form-group { margin-bottom: 1.5rem; }
.form-label { display: block; margin-bottom: 0.5rem; font-weight: 500; }
.form-control {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 4px;
}
.btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 500;
}
.btn-primary { background: #3b82f6; color: white; }
/* Glassmorphism utilities & Backend Styles */
.glass-panel {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: 1rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

/* Forms */
.form-group {
    margin-bottom: 1.5rem;
}
.form-label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-muted);
}
.form-control {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    color: var(--text-main);
    font-size: 1rem;
    transition: all 0.3s ease;
}
.form-control:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
}

/* Utilities */
.w-full { width: 100%; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.text-center { text-align: center; }
.d-flex { display: flex; }
.justify-between { justify-content: space-between; }
.align-center { align-items: center; }
.gap-2 { gap: 0.5rem; }
.gap-4 { gap: 1rem; }

/* Responsive Filter Bar */
.filter-bar-form {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr;
    border-radius: 999px;
    max-width: 1000px;
    margin: 0 auto;
    box-shadow: 0 10px 25px -5px rgba(0,0,0,0.1);
    background: #ffffff;
}
@media (max-width: 767px) {
    .filter-bar-form {
        grid-template-columns: 1fr;
        border-radius: 1rem;
    }
    .filter-bar-form > div.filter-col {
        border-right: none !important;
        border-bottom: 1px solid var(--border-color) !important;
    }
    .filter-bar-form > div.filter-col:last-of-type {
        border-bottom: none !important;
    }
}


.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1.5rem;
}
.part-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transition: transform 0.3s ease;
}
.part-card:hover {
    transform: translateY(-5px);
}
.part-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    background-color: var(--bg-light);
}
.part-content {
    padding: 1.5rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}
.part-title { font-size: 1.125rem; font-weight: 600; margin-bottom: 0.5rem; }
.part-code { font-size: 0.75rem; color: #3b82f6; background: rgba(59, 130, 246, 0.1); padding: 0.25rem 0.5rem; border-radius: 999px; display: inline-block; margin-bottom: 0.5rem; }
.part-desc { color: var(--text-muted); font-size: 0.875rem; margin-bottom: 1rem; flex: 1; }
.part-footer { display: flex; justify-content: space-between; align-items: center; padding-top: 1rem; border-top: 1px solid var(--border-color); }
.part-price { font-weight: 600; color: #10b981; }
.part-stock { font-size: 0.875rem; }
.part-stock.low { color: #f59e0b; }
.part-stock.out { color: #ef4444; }
.part-stock.in { color: #10b981; }

/* Navbar (Dashboard) */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    border-bottom: 1px solid var(--border-color);
    background: #ffffff;
}
.nav-brand { font-size: 1.25rem; font-weight: 700; color: var(--dark-blue); text-decoration: none; }
.nav-links { display: flex; gap: 1.5rem; align-items: center; }
.nav-link { color: var(--text-muted); text-decoration: none; transition: color 0.3s ease; }
.nav-link:hover, .nav-link.active { color: #3b82f6; }

/* Login specific */
body.login-body {
    background-color: #ffffff;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

.login-page-wrapper {
    display: flex;
    min-height: 100vh;
    width: 100%;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.login-modal-container {
    display: flex;
    width: 100%;
    max-width: 900px;
    min-height: 550px;
    background: #ffffff;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    border: 1px solid #e2e8f0;
}

.login-cover-side {
    flex: 1.1;
    background-color: #f1f5f9;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
}

.login-form-side {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    position: relative;
    background: #ffffff;
}

.login-card-clean {
    width: 100%;
    max-width: 380px;
}

.login-header { text-align: center; margin-bottom: 2rem; }
.login-header h1 { font-size: 1.5rem; font-weight: 700; color: var(--dark-blue); margin-bottom: 0.5rem; }
.error-message { background-color: rgba(239, 68, 68, 0.1); color: #ef4444; padding: 0.75rem; border-radius: 0.5rem; text-align: center; margin-bottom: 1.5rem;}

.password-toggle-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.password-toggle-icon {
    position: absolute;
    right: 1rem;
    color: #94a3b8;
    cursor: pointer;
    transition: color 0.2s;
}
.password-toggle-icon:hover {
    color: #475569;
}

@media (max-width: 991px) {
    .login-modal-container {
        flex-direction: column;
        max-width: 500px;
        min-height: auto;
    }
    .login-cover-side {
        display: none;
    }
    .login-form-side {
        padding: 3rem 2rem;
    }
}

/* Mobile Menu Toggle Bottom */
.mobile-menu-btn-bottom {
    display: none;
}
.close-menu-btn {
    display: none;
}

@media (max-width: 1199px) { /* iPad Landscape and Mobile */
    .mobile-menu-btn-bottom {
        display: inline-block !important;
    }
    
    .desktop-bars-icon {
        display: none !important;
    }
    
    .close-menu-btn {
        display: block;
        align-self: flex-end;
        font-size: 1.5rem;
        color: var(--text-main);
        margin-bottom: 0.5rem;
    }
    
    .desktop-main-menu a:not(.cart-icon-wrapper) {
        display: none !important;
    }
    .desktop-categories {
        display: none !important;
    }
    .mobile-main-menu {
        display: flex !important;
    }
    a[href="logout.php"].btn {
        display: none !important;
    }
}

@media (min-width: 768px) and (max-width: 1199px) { /* iPad navigation sizing */
    .dark-nav {
        height: auto !important;
        padding: 0.55rem 0 !important;
    }

    .dark-nav > .container {
        padding: 0 1rem !important;
        gap: 0.5rem 1rem !important;
    }

    .dark-nav .mobile-main-menu {
        gap: 0.55rem !important;
        justify-content: space-between !important;
    }

    .dark-nav .mobile-main-menu a,
    .dark-nav .mobile-main-menu > div > a {
        font-size: 0.82rem !important;
        white-space: nowrap;
    }

    /* Keep the iPad navigation consistent with the sales report header. */
    .dark-nav > .container {
        width: 100% !important;
        max-width: none !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
        box-sizing: border-box;
    }

    .dark-nav .mobile-main-menu {
        display: flex !important;
        flex-wrap: nowrap !important;
        justify-content: space-around !important;
        align-items: center !important;
        gap: 0 !important;
        width: 100% !important;
    }

    .dark-nav .mobile-main-menu > a,
    .dark-nav .mobile-main-menu > div {
        flex: 1 1 0;
        min-width: 0;
        text-align: center;
    }

    .dark-nav .mobile-main-menu > a,
    .dark-nav .mobile-main-menu > div > a {
        display: block;
        overflow: hidden;
        text-overflow: ellipsis;
        font-size: 0.82rem !important;
        white-space: nowrap;
    }
}

@media (max-width: 767px) { /* Mobile */
    .top-header {
        flex-wrap: wrap;
    }
    
    .search-bar, .search-and-cart {
        order: 3;
        max-width: 100%;
        margin: 1rem 0 0 0 !important;
        width: 100%;
    }
    
    .search-and-cart {
        flex-direction: row-reverse;
    }
}

/* Drawer menu (replaces header-links on mobile) */
.drawer-menu {
    display: flex;
    position: fixed;
    top: 0;
    left: -320px;
    width: 280px;
    bottom: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 1.5rem;
    margin-top: 0;
    background: #ffffff;
    padding: 1.5rem 1.5rem 2rem 1.5rem;
    border-radius: 0;
    box-shadow: 4px 0 15px rgba(0,0,0,0.15);
    transition: left 0.3s ease;
    z-index: 2000;
    overflow: hidden;
}
.drawer-menu.active {
    left: 0;
}

/* Drawer Overlay Backdrop */
.drawer-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    z-index: 1999;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}
.drawer-overlay.active {
    display: block;
    opacity: 1;
}

/* List View Table */
.list-view-container {
    overflow-x: auto;
    background: #ffffff;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}
.list-view-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 600px;
}
.list-view-table th {
    background: #f8fafc;
    color: var(--text-main);
    font-weight: 600;
    font-size: 0.9rem;
    padding: 1.2rem 1rem;
    text-align: center;
    border-bottom: 1px solid var(--border-color);
}
.list-view-table th.text-left { text-align: left; }
.list-view-table td {
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
    vertical-align: middle;
}
.list-view-table tr:last-child td {
    border-bottom: none;
}
.list-view-table tr:hover {
    background: #f8fafc;
}

.list-img-cell {
    width: 90px;
    text-align: center;
}
.list-img-cell img {
    width: 64px;
    height: 64px;
    object-fit: contain;
    border-radius: 8px;
    background: white;
    border: 1px solid var(--border-color);
    padding: 0.25rem;
}
.list-img-cell .placeholder {
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #cbd5e1;
    border-radius: 8px;
    color: white;
    margin: 0 auto;
}
.list-name-cell {
    width: 25%;
}
.list-name-cell .title {
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.2rem;
    font-size: 1rem;
    text-decoration: none;
    display: block;
}
.list-name-cell .title:hover {
    color: #3b82f6;
}
.list-name-cell .code {
    font-size: 0.75rem;
    color: var(--text-muted);
}
.list-desc-cell {
    width: 30%;
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.4;
}
.list-status-cell {
    text-align: center;
    width: 12%;
}
.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.3rem 0.6rem;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 500;
}
.status-badge.in { background: rgba(16, 185, 129, 0.1); color: #10b981; }
.status-badge.low { background: rgba(245, 158, 11, 0.1); color: #f59e0b; }
.status-badge.out { background: rgba(239, 68, 68, 0.1); color: #ef4444; }

.list-price-cell {
    text-align: center;
    font-weight: 700;
    color: #3b82f6; /* Blue like the example image */
    font-size: 1.1rem;
    width: 13%;
}
.list-action-cell {
    text-align: center;
    width: 10%;
}
.list-action-group {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
}
.list-action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: white;
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    text-decoration: none;
    transition: all 0.2s;
}
.list-action-btn:hover {
    background: #f8fafc;
    color: #3b82f6;
    border-color: #3b82f6;
}

/* View Toggle Buttons */
.view-toggle {
    display: flex;
    background: var(--bg-light);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    overflow: hidden;
}
.view-btn {
    background: transparent;
    border: none;
    padding: 0.4rem 0.6rem;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.2s;
}
.view-btn:hover {
    color: #3b82f6;
}
.view-btn.active {
    background: #ffffff;
    color: #3b82f6;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

/* Cart Badge and Animation */
.cart-badge {
    background: #ef4444;
    color: white;
    border-radius: 50%;
    padding: 0.1rem 0.4rem;
    font-size: 0.75rem;
    font-weight: bold;
    position: absolute;
    top: -8px;
    right: -8px;
}
.cart-icon-wrapper {
    position: relative;
    display: inline-flex;
    align-items: center;
}
/* Flying Cart Animation */
.flying-img {
    position: fixed;
    z-index: 9999;
    border-radius: 0.25rem;
    object-fit: cover;
    transition: all 0.7s cubic-bezier(0.25, 1, 0.5, 1);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    pointer-events: none;
    cursor: auto !important;
    user-select: none;
}

/* Cart Badge */
.cart-icon-wrapper {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.cart-badge {
    position: absolute;
    top: -8px;
    right: -10px;
    background-color: #ef4444;
    color: white;
    font-size: 0.7rem;
    font-weight: bold;
    padding: 0.1rem 0.4rem;
    border-radius: 999px;
    border: 2px solid white;
    transition: transform 0.3s ease;
}

/* Toast Notification */
#toast-container {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: center;
    pointer-events: none;
}
.toast-message {
    background: rgba(0, 0, 0, 0.5);
    color: white;
    padding: 1.5rem 2.5rem;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.25);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-weight: 600;
    font-size: 1.25rem;
    animation: popInCenter 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    opacity: 1;
    transition: opacity 0.4s ease;
    text-align: center;
    backdrop-filter: blur(4px);
}
.toast-message i {
    font-size: 3rem;
    margin-bottom: 0.25rem;
}
.toast-message.fade-out {
    opacity: 0;
    transform: scale(0.8);
}
@keyframes popInCenter {
    0% { transform: scale(0.5); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

/* Add to Cart Button Customization */
.btn-cart-blue {
    background-color: #3b82f6 !important;
    color: white !important;
    transition: all 0.3s ease;
}
.btn-cart-blue:hover {
    background-color: #ef4444 !important;
    color: white !important;
}

.btn-cart-icon-blue {
    color: #3b82f6 !important;
    border-color: #e2e8f0 !important;
}
.btn-cart-icon-blue:hover {
    color: #ef4444 !important;
    border-color: #ef4444 !important;
}

/* Mini Cart Dropdown */
.cart-dropdown-container {
    position: relative;
    display: inline-block;
}
.mini-cart-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    right: -10px;
    width: 300px;
    max-height: 500px;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.12);
    border: 1px solid #e5e7eb;
    padding: 1rem 0.8rem;
    z-index: 1050;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
}
.cart-dropdown-container:hover .mini-cart-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
/* Invisible bridge so hover doesn't break when moving mouse down */
.mini-cart-dropdown::before {
    content: '';
    position: absolute;
    top: -15px;
    left: 0;
    right: 0;
    height: 15px;
}
.mini-cart-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}
.mini-cart-empty-icon {
    font-size: 5rem;
    color: #e2e8f0;
    margin-bottom: 1.5rem;
}
.mini-cart-empty-text {
    color: #1e3a8a; /* Dark blue matching the image */
    font-weight: 500;
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
}
.mini-cart-btn-shop {
    background-color: #0d47a1; /* Deep blue button */
    color: white;
    border-radius: 99px; /* Pill shape */
    padding: 0.6rem 2rem;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s;
    display: inline-block;
}
.mini-cart-btn-shop:hover {
    background-color: #1565c0;
    color: white;
}
.mini-cart-has-items-text {
    color: #1e3a8a;
    font-weight: 500;
    font-size: 1.1rem;
    margin-bottom: 1rem;
    text-align: center;
}

/* Custom Scrollbar for Mini Cart */
.custom-scrollbar::-webkit-scrollbar {
    width: 6px;
}
.custom-scrollbar::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 4px;
}
.custom-scrollbar::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}
.custom-scrollbar::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* === Swipe-to-Edit: List View Rows === */
.list-row-wrapper td {
    padding: 0 !important;
}

/* Clip wrapper div — Safari ignores overflow:hidden on <td> */
.list-row-clip {
    position: relative;
    overflow: hidden;
}

/* Hidden by default — only visible when swiping */
.list-row-action-behind {
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 90px;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: white;
    text-decoration: none;
    z-index: 0;
    gap: 0.3rem;
    font-size: 0.85rem;
    font-weight: 600;
    transition: background 0.2s, visibility 0s, opacity 0.15s;
    visibility: hidden;
    opacity: 0;
}
/* Show only when actively swiping or swiped open */
.list-row-clip.swiping .list-row-action-behind {
    visibility: visible;
    opacity: 1;
}
.list-row-action-behind:hover {
    background: linear-gradient(135deg, #d97706, #b45309);
}
.list-row-action-behind i {
    font-size: 1.2rem;
}

.list-row-swipeable {
    display: flex;
    align-items: center;
    background: #ffffff;
    position: relative;
    z-index: 1;
    transition: transform 0.25s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    width: 100%;
    border-bottom: 1px solid var(--border-color);
}
.list-row-wrapper:last-child .list-row-swipeable {
    border-bottom: none;
}
.list-row-swipeable:hover {
    background: #f8fafc;
}

/* Swipeable row cells mimic table columns */
.list-row-swipeable .list-cell-img {
    width: 90px;
    min-width: 90px;
    text-align: center;
    padding: 1rem;
}
.list-row-swipeable .list-cell-name {
    width: 25%;
    min-width: 150px;
    padding: 1rem;
}
.list-row-swipeable .list-cell-desc {
    width: 30%;
    min-width: 120px;
    padding: 1rem;
    flex: 1;
}
.list-row-swipeable .list-cell-status {
    width: 12%;
    min-width: 80px;
    text-align: center;
    padding: 1rem;
}
.list-row-swipeable .list-cell-price {
    width: 13%;
    min-width: 80px;
    text-align: center;
    padding: 1rem;
}
.list-row-swipeable .list-cell-action {
    width: 10%;
    min-width: 80px;
    text-align: center;
    padding: 1rem;
}

/* Swipe hint indicator on touch devices */
@media (hover: none) and (pointer: coarse) {
    .list-row-swipeable::after {
        content: '';
        position: absolute;
        right: 4px;
        top: 50%;
        transform: translateY(-50%);
        width: 3px;
        height: 24px;
        background: #cbd5e1;
        border-radius: 2px;
        opacity: 0.5;
        transition: opacity 0.3s;
    }
    .list-row-swipeable:active::after {
        opacity: 0;
    }
}

@media (max-width: 1199px) {
    .list-view-table, .receive-report-table, .sales-report-table {
        min-width: 100%;
    }
    .list-view-table th, .list-view-table td,
    .receive-report-table th, .receive-report-table td,
    .sales-report-table th, .sales-report-table td {
        padding: 0.5rem 0.4rem !important;
        font-size: 0.8rem;
    }
    .list-name-cell .title {
        font-size: 0.9rem;
    }
    .list-desc-cell {
        font-size: 0.75rem;
    }
    .list-price-cell {
        font-size: 0.9rem;
    }
    .list-img-cell {
        width: 70px;
    }
    .list-img-cell img, .list-img-cell .placeholder {
        width: 50px;
        height: 50px;
    }
    .list-action-group {
        flex-wrap: wrap;
    }
    
    /* Swipeable row responsive */
    .list-row-swipeable .list-cell-img {
        width: 70px;
        min-width: 70px;
        padding: 0.5rem 0.4rem;
    }
    .list-row-swipeable .list-cell-name,
    .list-row-swipeable .list-cell-desc,
    .list-row-swipeable .list-cell-status,
    .list-row-swipeable .list-cell-price,
    .list-row-swipeable .list-cell-action {
        padding: 0.5rem 0.4rem;
    }
    .list-row-action-behind {
        width: 75px;
        font-size: 0.8rem;
    }
    
    /* Hide edit button on tablet — swipe-to-edit is available instead */
    .list-edit-btn {
        display: none !important;
    }
}