/* ========================================= */
/* SITE-WIDE KIOSK STYLES (site_kiosk_styles.css) */
/* Combines Kiosk/Admin UI Styles */
/* ========================================= */

/* --- 0. Base Variables and Reset --- */
:root {
    --primary-text: #000;
    --secondary-text: #333;
    --background-color: #fff;
    --border-color: #ccc;
    --light-grey-bg: #f4f4f4;
    --mc-green: #279244;
    --mc-yellow: #f7a01a;
    --admin-blue: #007bff; /* New Admin Action Color */
    --hover-color: #5a6268;
    }


* {
    box-sizing: border-box;
    font-family: Arial, sans-serif;
}

body {
    margin: 0;
    padding: 0;
    background-color: var(--background-color);
    color: var(--primary-text);
}

/* Global H2 and H3 styles, which can be overridden by specific sections */
h2 {
    color: var(--secondary-text);
}


/* --- 1. Header & Search Bar (Desktop Default) --- */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px;
    height: 60px;
    border-bottom: 2px solid var(--mc-yellow);
    background-color: var(--light-grey-bg);
}

.header h1 {
    font-size: 30px;
    font-weight: bold;
    margin: 0;
}

.search-bar-container {
    display: flex;
    flex-grow: 1;
    max-width: 500px;
    margin-left: 20px;
}

.search-input {
    padding: 8px 10px;
    border: 1px solid var(--border-color);
    width: 100%;
    font-size: 14px;
}

.search-button {
    padding: 8px 15px;
    border-radius: 4px;
    margin-left: 10px;
    border: 1px solid var(--primary-text);
    background-color: var(--primary-text);
    color: var(--background-color);
    font-weight: bold;
    cursor: pointer;
    font-size: 14px;
    white-space: nowrap;
}
.search-button:hover {

    background-color: var(--hover-color);

}
.footer {
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding-top: 30px;
    border-top: 2px solid var(--mc-yellow);
    background-color: var(--primary-text);
}
.footer p {
    font-size: 12px;
    color: var(--secondary-text);
    color: var(--background-color);
}

/* --- 2. Admin Dashboard Layout (Two Columns) --- */
.main-content {
    display: flex;
    min-height: calc(100vh - 42px); /* Assuming header height is around 42px */
}

/* Sidebar (Navigation) */
.back-link {
            font-size: 14px;
            color: var(--primary-text);
            text-decoration: underline;
            cursor: pointer;
        }
.sidebar {
    width: 250px;
    padding: 20px;
    border-right: 1px solid var(--border-color);
    background-color: var(--light-grey-bg);
    flex-shrink: 0;
}

.sidebar h2 {
    font-size: 16px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 5px;
    margin-top: 0;
}

.sidebar h2 .toggle-icon {
    font-size: 1.2em;
    float: right;
    margin-right: 5px;
    font-weight: normal;
}

.nav-list, .sub-list {
    list-style: none;
    padding: 0;
    margin: 0 0 15px 0;
}

.nav-item a {
    display: block;
    padding: 5px 0;
    color: var(--primary-text);
    text-decoration: none;
    font-weight: bold;
    font-size: 14px;
}

.sub-list {
    margin: 5px 0 5px 15px;
    display: none; 
}

.sub-list li a {
    font-weight: normal;
    font-size: 13px;
    color: var(--secondary-text);
}

.nav-item a:hover {
    background-color: #ddd;
}

/* Content Area */
.content-area {
    flex-grow: 1;
    padding: 20px;
}

.content-area h2 {
    font-size: 24px;
    margin-top: 0;
    margin-bottom: 15px;
}


/* --- 3. Kiosk/Admin UI Components --- */

/* Status Boxes */
.status-box-container {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
}

.status-box {
    border: 1px solid var(--border-color);
    border-left: 5px solid var(--mc-green);
    padding: 15px;
    width: 33.3%;
    background-color: var(--background-color);
    flex-grow: 1;
}

.status-box h3 {
    margin: 0 0 5px 0;
    font-size: 16px;
    color: var(--secondary-text);
}

.status-box p {
    margin: 0;
    font-size: 28px;
    line-height: 1;
}

.status-box .detail {
    font-size: 12px;
    color: #666;
    margin-top: 5px;
}

/* Data Table */
.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
    margin-top: 15px;
}

.data-table th, .data-table td {
    border: 1px solid var(--border-color);
    padding: 8px 10px;
    text-align: left;
}

.data-table th {
    background-color: var(--light-grey-bg);
    font-weight: bold;
    color: var(--secondary-text);
    border-top: 3px solid var(--primary-text);
}
/* Data Table */
.filter-table {
    width: 300px;
    border-collapse: collapse;
    font-size: 13px;
    margin-top: 15px;
}

.filter-table th, .filter-table td {
    border: 1px solid var(--border-color);
    padding: 8px 10px;
    text-align: left;
}

.filter-table th {
    background-color: var(--light-grey-bg);
    font-weight: bold;
    color: var(--secondary-text);
    border-top: 3px solid var(--primary-text);
}


/* Status Tags */
.status-tag {
    display: inline-block;
    padding: 3px 6px;
    font-weight: bold;
    border: 1px solid;
    font-size: 10px;
}

.status-tag.success {
    color: var(--mc-green);
    border-color: var(--mc-green);
    background-color: #e9f5e9;
}

.status-tag.warning {
    color: var(--mc-yellow);
    border-color: var(--mc-yellow);
    background-color: #fff8e8;
}

.status-tag.error {
    color: #d9534f;
    border-color: #d9534f;
    background-color: #fbe9e9;
}


/* --- 4. Admin Login Page Specific Styles (NEW) --- */
.login-body { /* Used for admin_login.html body to center content */
    background-color: var(--light-grey-bg);
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
}

.login-container {
    background-color: var(--background-color);
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 400px;
    text-align: center;
}

.login-container h2 {
    color: var(--secondary-text);
    margin-bottom: 25px;
}

.input-group {
    margin-bottom: 20px;
    text-align: left;
}
.custom-input-style{
    margin-bottom: 20px;
    text-align: left;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #555;
}

.login-input {
    /* Combined styling for search and form inputs */
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    box-sizing: border-box; 
    font-size: 16px;
    color: var(--primary-text);
}


.login-container button {
    padding: 8px 15px;
    border: 1px solid var(--primary-text);
    background-color: var(--primary-text);
    color: var(--background-color);
    font-weight: bold;
    cursor: pointer;
    white-space: nowrap;
    border-radius: 4px;
    cursor: pointer;
    font-size: 18px;
}
.login-container button:hover {
    background-color: var(--hover-color);
}
.checkbox-group {
    display: flex;
    align-items: center; /* Vertically centers the checkbox and label */
    gap: 8px;            /* Adds space between the box and the text */
}

#statusMessage {
    margin-top: 20px;
    padding: 10px;
    border-radius: 4px;
    font-weight: bold;
    min-height: 20px; 
    color: var(--mc-yellow);
}
.scanner
{
    display: none !important; 
}

/* ========================================================== */
/* 📱 MEDIA QUERIES FOR MOBILE/iOS SCREENS (max-width: 768px) */
/* ========================================================== */

@media (max-width: 768px) {
    
    /* 1. Header Stacking */
    .header {
        height: 35px;
        flex-direction: column;
        align-items: flex-start;
        padding: 10px;
    }
    .scanner
    {
        display: block !important; 
    }
    .back-link {
        display: none;
    }

    .header h1 {
        font-size: 18px;
        margin-bottom: 10px;
        text-align: center;
        width: 100%;
    }

    .search-bar-container {
        width: 100%;
        margin-left: 0;
        max-width: none;
    }

    /* 2. Main Layout Stacking */
    .main-content {
        flex-direction: column;
        min-height: auto;
    }

    .sidebar {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid var(--border-color);
        padding: 10px 20px;
    }

    /* Mobile Navigation Overrides */
    .sidebar h2 {
        font-size: 14px;
        margin-bottom: 5px;
        cursor: pointer; 
    }

    .nav-list {
        display: block !important; 
        margin-bottom: 0;
    }
    
    .nav-item {
        border-bottom: 1px dashed var(--border-color);
    }

    /* 3. Status Box Stacking */
    .status-box-container {
        flex-direction: column;
        gap: 10px;
    }

    .status-box {
        width: 100%;
    }
    
    .status-box p {
        font-size: 24px;
    }

    /* 4. Data Table Responsiveness (Horizontal Scroll) */
    .data-table {
        display: block;
        width: 100%;
        overflow-x: auto;
        white-space: nowrap;
    }
    
    /* Login Overrides */
    .login-container {
        padding: 20px;
        box-shadow: none;
    }
}
        /* Report specific styles (optional, for filters) */
        .report-controls {
            display: flex;
            gap: 15px;
            margin-bottom: 20px;
            align-items: center;
        }

        .report-controls label {
            font-weight: bold;
            color: #555;
        }

        .report-controls select, .report-controls button {
            padding: 8px;
            border: 1px solid var(--border-color);
            border-radius: 4px;
            font-size: 14px;
        }

        .report-controls button {
            padding: 8px 15px;
            border: 1px solid var(--primary-text);
            background-color: var(--primary-text);
            color: var(--background-color);
            font-weight: bold;
            cursor: pointer;
            font-size: 14px;
            white-space: nowrap;
        
        }

        .report-controls button:hover {
            background-color: var(--hover-color);
        }
        
        /* The Print Button will use the standard action button style */
        .print-btn {
            background-color: #6c757d; /* Darker grey for Print */
        }
/* --- Data Table Sorting Styles (New) --- */
.data-table th {
    cursor: pointer;
    position: relative; /* Needed for positioning the arrow */
    user-select: none; /* Prevent text selection on click */
}

/* Arrow container and base style */
.data-table th::after {
    content: '';
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    opacity: 0; /* Hidden by default */
    font-size: 8px;
    transition: opacity 0.2s;
}

/* Ascending sort: Up arrow */
.data-table th.sort-asc::after {
    content: '▲';
    opacity: 1;
}

/* Descending sort: Down arrow */
.data-table th.sort-desc::after {
    content: '▼';
    opacity: 1;
}

/* Subtle visual cue when hovering over a sortable column */
.data-table th:hover {
    background-color: #e8e8e8;
}        
/* ========================================= */
/* 🖨️ PRINT STYLES */
/* Hides all elements except the main report content/table */
/* ========================================= */

@page {
        size: letter; /* Set A4 paper in landscape orientation */
        margin: 1cm; /* Set 1cm margins on all sides */
    }

@media print {
    /* Hide specific non-essential elements */
    .hide-on-print,
    .search-bar-container,
    .menu-toggle,
    .sidebar,
    .report-controls,
    .content-area h2,
    .fixed-input-container,
    .form-actions,
    .print-btn /* Hide sort arrows */ {
        display: none !important;
    }

    /* Make the entire body and the main content printable, resetting layout */
    body {
        width: 100%;
        margin: 0;
        padding: 0;
        background-color: white !important; /* Force white background */
    }

    /* Make the content area take up the full page width */
    .main-content, 
    .content-area,
    .cart-area {
        display: block !important;
        width: 100% !important;
        padding: 0 !important;
        margin: 0 !important;
    }

    /* Force table to render correctly */
    .data-table {
        margin-top: 10px;
        width: 100%;
        border-collapse: collapse;
        overflow: visible;
        font-size: 10pt; /* Use standard print font size */
    }
    
    .data-table th, .data-table td {
        padding: 5px 8px;
        border: 1px solid #000; /* Ensure borders are black for printing */
    }

    /* Print only the table and its immediate header */
    #inventoryReportWrapper {
        display: block !important;
        padding: 0;
    }
    .footer {
        background-color: var(--background-color);
    }
    .footer p {
        color: var(--primary-text);
    }
}        
        /* --- Form Layout --- */
        .edit-container {
            max-width: 900px;
            margin: 20px auto;
            padding: 20px;
            border: 1px solid var(--border-color);
        }
        
        .edit-container h2 {
            font-size: 24px;
            margin-top: 0;
        }
        
        /* Two-Column Specification Grid */
        .spec-grid {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 20px;
            margin-bottom: 30px;
        }

        .input-group {
            margin-bottom: 15px;
        }

        .input-group label {
            display: block;
            font-weight: bold;
            margin-bottom: 5px;
            font-size: 14px;
        }

        .input-group input[type="text"],
        .input-group input[type="number"],
        .input-group input[type="password"],
        .input-group select {
            width: calc(100%);
            padding: 8px 10px;
            border: 1px solid var(--border-color);
            font-size: 14px;
            background-color: var(--background-color);
        }
        
        /* Full Width Section */
        .full-width-section {
            grid-column: 1 / -1;
        }
        textarea {
            width: calc(100% - 22px);
            height: 100px;
            padding: 8px 10px;
            border: 1px solid var(--border-color);
            font-size: 14px;
            resize: vertical;
        }
        
        /* --- Action Buttons --- */
        .form-actions {
            border-top: 1px solid var(--border-color);
            padding-top: 20px;
            display: flex;
            justify-content: flex-end;
            gap: 15px;
        }

        .form-actions button {
            padding: 10px 20px;
            font-size: 16px;
            font-weight: bold;
            cursor: pointer;
            border: 1px solid;
        }
        
        .save-btn {
            background-color: var(--mc-green);
            color: white;
            border-color: var(--mc-green);
        }

        .cancel-btn {
            color: var(--primary-text);
            border-color: var(--primary-text);
        }
        
        /* --- Mobile Responsiveness --- */
        @media (max-width: 768px) {
            .edit-container {
                padding: 10px;
                margin: 10px;
            }
            
            .spec-grid {
                grid-template-columns: 1fr;
                gap: 0;
            }
            
            .full-width-section {
                width: calc(100% - 5px);
                grid-column: 1 / 1; 
            }
            
            .form-actions {
                flex-direction: column;
                gap: 10px;
            }

            .form-actions button {
                width: 100%;
            }
        }
        /* --- Main Content Layout --- */
        .detail-container {
            width: 100%;
            display: flex;
            padding: 20px;
            gap: 20px;
        }
        
        /* --- Left Column: Details & Specs --- */
        .detail-column-left {
            flex: 2; /* Takes up two-thirds of the space */
            min-width: 400px;
        }
        
        /* Item Title and Part Number */
        .item-header {
            margin-bottom: 20px;
        }

        .item-header h2 {
            font-size: 28px;
            margin: 0 0 5px 0;
        }

        .item-header p {
            font-size: 16px;
            margin: 0;
            color: var(--secondary-text);
            font-weight: bold;
        }

        /* Specification Table (High density) */
        .spec-table {
            width: 100%;
            border-collapse: collapse;
            font-size: 14px;
            margin-top: 15px;
        }

        .spec-table th, .spec-table td {
            padding: 8px 10px;
            border-bottom: 1px solid var(--border-color);
        }

        .spec-table th {
            text-align: left;
            background-color: var(--light-grey-bg);
            width: 35%; /* Keep labels aligned */
            
        }
        
        /* Description Box */
        .description-box {
            margin-top: 30px;
            padding: 15px;
            border: 1px solid var(--border-color);
            background-color: #fcfcfc;
        }
        
        /* --- Right Column: Inventory & Actions --- */
        .detail-column-right {
            flex: 1; /* Takes up one-third of the space */
            border-left: 1px solid var(--border-color);
            padding-left: 20px;
        }
        
        /* Inventory Status Box */
        .inventory-status {
            border: 1px solid var(--primary-text);
            padding: 15px;
            margin-bottom: 20px;
            background-color: var(--light-grey-bg);
            text-align: center;
        }
        
        .inventory-status h3 {
            margin-top: 0;
            font-size: 18px;
        }
        .inventory-status button {
            padding: 10px 20px;
            font-size: 16px;
            font-weight: bold;
            cursor: pointer;
            margin: 10px;
            border: 1px solid var(--primary-text);
            color: var(--background-color);
        }
        .qty-adjust
        {
            width: 100px;
            padding: 15px;
            border: 1px solid var(--border-color);
            font-size: 14px;
            text-align: center;
            background-color: var(--background-color);
            margin-bottom: 10px;
        }      
        .pull-button
        {
            background-color: var(--mc-yellow);
            
        } 
        .loan-button
        {
            background-color: #5bc0de;


        }
        
        .stock-level {
            font-size: 48px;
            font-weight: bold;
            color: var(--mc-green); /* Green for sufficient stock */
            line-height: 1;
        }
        
        .stock-location {
            font-size: 14px;
            color: #666;
            margin-top: 5px;
        }
        
        /* Action Buttons */
        .action-buttons {
            display: flex;
            flex-direction: column;
            gap: 10px;
        }
        
        .action-buttons button {
            padding: 10px;
            font-size: 14px;
            font-weight: bold;
            border: 1px solid var(--primary-text);
            cursor: pointer;
            background-color: var(--background-color);
        }
        
        .action-buttons button:hover {
            background-color: #ddd;
        }
        
        .delete-btn {
            color: #d9534f;
            border-color: #d9534f;
            margin-top: 15px;
        }

        /* --- Recent Activity/Log Table (Same as Dashboard) --- */
        .log-table {
            width: 100%;
            border-collapse: collapse;
            font-size: 13px;
            margin-top: 20px;
        }

        .log-table th, .log-table td {
            border: 1px solid var(--border-color);
            padding: 8px 10px;
            text-align: left;
        }

        .log-table th {
            background-color: var(--light-grey-bg);
            font-weight: bold;
            color: var(--secondary-text);
            border-top: 3px solid var(--primary-text);
        }

        /* --- Mobile Responsiveness (Stacking) --- */
        @media (max-width: 768px) {
            .detail-container {
                flex-direction: column;
                padding: 10px;
            }
            
            .detail-column-left, .detail-column-right {
                min-width: 100%;
                padding-left: 0;
                border-left: none;
            }
            
            .detail-column-right {
                border-top: 1px solid var(--border-color);
                padding-top: 20px;
            }
        }
/* ========================================= */
/* 🆕 FIXED QUICK SCAN INPUT */
/* ========================================= */
@media (max-width: 1024px) {
    

    /* NEW RULE: Hide Fixed Quick Scan Input on Mobile */
    .fixed-input-container {
        display: none !important;
    }
}

.fixed-input-container {
    /* Pin the container to the bottom right of the viewport */
    position: fixed;
    bottom: 20px; /* Distance from the bottom edge */
    right: 20px;  /* Distance from the right edge */
    
    /* Styling */
    background-color: var(--light-grey-bg);
    border: 1px solid var(--border-color);
    padding: 10px 15px;
    border-radius: 6px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
    z-index: 1000; /* Ensure it stays above other content */
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.fixed-input-container label {
    font-weight: bold;
    font-size: 13px;
    margin-bottom: 5px;
    color: var(--secondary-text);
}

.quick-scan-input {
    /* Reuse standard input styling but fix width */
    padding: 8px 10px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    width: 200px; /* Fixed width for consistent look */
    font-size: 16px;
}
table-item-image
.table-item-image {
    width: 50px;
    height: 50px;
    object-fit: cover;
    border-radius: 4px;
}
/* Add/Update inside your @media (max-width: 768px) block in style.css */

/* Ensure the toggle is hidden on desktop by default */
.menu-toggle {
    display: none;
}

@media (max-width: 768px) {
    /* 1. Header Stacking */
    .header {
        height: auto !important;
        flex-direction: column !important;
        align-items: center !important; /* Centers the top-bar and search-container */
        padding: 15px;
        gap: 15px;
        text-align: center;
    }

    .top-bar {
        display: flex;
        width: 100%;
        justify-content: space-between; /* Keeps logo left, hamburger right */
        align-items: center;
    }

    .menu-toggle {
        display: block;
        background: var(--primary-text);
        color: white;
        border: none;
        padding: 8px 12px;
        font-size: 20px;
        border-radius: 4px;
        cursor: pointer;
    }

    /* 2. Search Bar takes full width below the header */
    .search-bar-container {
        width: 90%; /* Prevents it from touching the very edges */
        margin-left: 0;
        display: flex;
        justify-content: center; /* Centers the input and button inside the container */
    }
    .search-input {
        flex-grow: 1; /* Allows input to take up available space */
        max-width: 300px; /* Keeps it from getting too wide on tablets */
    }
    /* 3. Hide sidebar and only show when active */
    .sidebar {
        display: none;
        width: 100%;
    }

    .sidebar.mobile-active {
        display: block;
    }
}
.img-fluid {
    max-width: 100%;
    height: auto;
}
label.required:after {
    content: " *";
    color: red;
}
label.required:after {
    content: " *";
    color: red;
}
/* Styling the "YES" input to stand out */
#confirmInput {
    font-weight: bold;
    border: 2px solid #dee2e6;
    text-align: center;
    letter-spacing: 2px;
}

/* Change input border color when 'YES' is typed correctly */
#confirmInput:valid, #confirmInput:not(:placeholder-shown) {
    border-color: #dc3545; /* Bootstrap Red */
}

/* Optional: Make the item name pop in the modal body */
#itemName {
    color: #dc3545;
    text-decoration: underline;
}

/* Add a subtle shake animation if the user tries to click while disabled (optional) */
#confirmDeleteBtn:disabled {
    cursor: not-allowed;
    opacity: 0.6;
}
/* --- Modal Display Logic --- */

/* Hide the modal by default */
.modal {
    display: none; 
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1055; /* Higher than header/sidebar */
    width: 100%;
    height: 100%;
    overflow-x: hidden;
    overflow-y: auto;
    outline: 0;
    background-color: rgba(0, 0, 0, 0.5); /* This creates the dark backdrop */
}

/* Bootstrap uses the .show class to make it visible via JavaScript */
.modal.show {
    display: block;
}

/* Modal Dialog Box Styling */
.modal-dialog {
    position: relative;
    width: auto;
    margin: 1.75rem auto;
    max-width: 500px; /* Standard width */
    background-color: var(--background-color);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
}

.modal-content {
    display: flex;
    flex-direction: column;
    padding: 20px;
}

.modal-header, .modal-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border-color);
}

.modal-footer {
    border-bottom: none;
    border-top: 1px solid var(--border-color);
    padding-top: 15px;
    margin-top: 15px;
    justify-content: flex-end;
    gap: 10px;
}
/* Hide the qtyModal by default */
.qtyModal {
    display: none; 
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1055; /* Higher than header/sidebar */
    width: 100%;
    height: 100%;
    overflow-x: hidden;
    overflow-y: auto;
    outline: 0;
    background-color: rgba(0, 0, 0, 0.5); /* This creates the dark backdrop */
}

/* Bootstrap uses the .show class to make it visible via JavaScript */
.qtyModal.show {
    display: block;
}

/* Modal Dialog Box Styling */
.qtyModal-dialog {
    position: relative;
    width: auto;
    margin: 1.75rem auto;
    max-width: 500px; /* Standard width */
    background-color: var(--background-color);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
}

.qtyModal-content {
    display: flex;
    flex-direction: column;
    padding: 20px;
}

.qtyModal-header, .modal-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border-color);
}

.qtyModal-footer {
    border-bottom: none;
    border-top: 1px solid var(--border-color);
    padding-top: 15px;
    margin-top: 15px;
    justify-content: flex-end;
    gap: 10px;
}
/* Container for horizontal layout */
.radio-button-group {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 5px;
}

/* Hide the actual radio input */
.radio-button-group input[type="radio"] {
    display: none;
}

/* Style the label to look like a button */
.radio-button-group label {
    display: inline-block;
    padding: 10px 20px;
    border: 2px solid var(--border-color);
    background-color: var(--background-color);
    color: var(--secondary-text);
    font-weight: bold;
    font-size: 14px;
    cursor: pointer;
    border-radius: 4px;
    transition: all 0.2s ease;
    text-align: center;
    flex: 1; /* Makes buttons equal width */
    min-width: 100px;
}

/* Hover effect */
.radio-button-group label:hover {
    background-color: var(--light-grey-bg);
    border-color: var(--primary-text);
}

/* Selected State: When the hidden radio is checked, style the adjacent label */
.radio-button-group input[type="radio"]:checked + label {
    background-color: var(--mc-green);
    border-color: var(--mc-green);
    color: white;
}

/* Specific Emergency color if you want to highlight it */
.radio-button-group input[value="emergency"]:checked + label {
    background-color: #d9534f; /* Error/Red color */
    border-color: #d9534f;
}

/* Status Tags */
.maintenance-tag {
    display: inline-block;
    padding: 3px 6px;
    font-weight: bold;
    border: 1px solid;
    font-size: 10px;
    width: 100px;
    text-align: center;
}

.maintenance-tag.medium {
    color: var(--mc-green);
    border-color: var(--mc-green);
    background-color: #e9f5e9;
}

.maintenance-tag.high {
    color: var(--mc-yellow);
    border-color: var(--mc-yellow);
    background-color: #fff8e8;
}

.maintenance-tag.emergency {
    color: #d9534f;
    border-color: #d9534f;
    background-color: #fbe9e9;
}

.maintenance-tag.low {
    color: var(--background-color);
    border-color: var(--mc-green);
    background-color: #5bc0de;
}
.maintenance-tag.completed {
    color: var(--background-color);
    border-color: var(--mc-green);
    background-color: var(--mc-green);
}
.maintenance-tag.pending {
    color: var(--background-color);
    border-color: var(--mc-yellow);
    background-color: var(--mc-yellow);
}
.maintenance-tag.closed {
    color: var(--background-color);
    border-color: var(--mc-grey);
    background-color: var(--mc-grey);
}   
.maintenance-tag.open {
    color: var(--background-color);
    border-color: #d9534f;
    background-color: #d9534f;
}

        /* Specification Table (High density) */
        .maintenance-table {
            width: 100%;
            border-collapse: collapse;
            font-size: 14px;
            margin-top: 15px;
        }

        .maintenance-table th, .maintenance-table td {
            padding: 8px 10px;
            border-bottom: 1px solid var(--border-color);
        }

        .maintenance-table th {
            text-align: left;
            background-color: var(--light-grey-bg);
            width: 150px; /* Keep labels aligned */
            
        }

.cart-container {
  position: relative;
  display: inline-block;
  cursor: pointer;
}

.cart-icon {
  width: 30px;
  height: 30px;
  color: #333;
}

.cart-badge {
  position: absolute;
  top: -5px;
  right: -5px;
  background-color: #ff4757; /* Eye-catching red */
  color: white;
  font-size: 12px;
  font-weight: bold;
  font-family: Arial, sans-serif;
  padding: 2px 6px;
  border-radius: 50%; /* Makes it a circle */
  min-width: 14px;
  text-align: center;
  box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}
        .cart-delete-cell {
            display: flex;
            justify-content: center;
            gap: 15px;
        }
        .cart-delete-cell button {
            padding: 10px 20px;
            font-size: 16px;
            font-weight: bold;
            cursor: pointer;
            border: 1px solid;
        }

/* Content Area */
.cart-area {
    flex-grow: 1;
    padding: 20px;
}

.cart-area h2 {
    font-size: 24px;
    margin-top: 0;
    margin-bottom: 15px;
}
.strength-meter-container {
    background-color: #eee;
    width: 100%;
    border-radius: 5px;
    margin-top: 5px;
    height: 10px;
    overflow: hidden;
}

#strength-bar {
    height: 100%;
    width: 0%;
    transition: width 0.3s ease, background-color 0.3s ease;
}

#match-message {
    min-height: 1.2em; /* Prevents layout jump when text appears */
}
/* The spinning animation */
@keyframes spin {
  to { transform: rotate(360deg); }
}

.spinner {
  display: inline-block;
  width: 14px;
  height: 14px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  border-top-color: #fff; /* The "moving" part of the circle */
  animation: spin 0.8s linear infinite;
  margin-right: 8px;
  vertical-align: middle;
}

/* Style for the disabled state */
.save-btn:disabled {
  background-color: #6c757d;
  cursor: not-allowed;
}