﻿body {
    padding-top: 120px; /* Account for fixed header height */
    padding-bottom: 70px;
}

/* Thumbnail red border for damaged items */
.img-thumbnail-red {
    border: 3px solid #dc3545 !important;
    border-radius: 0.25rem;
    padding: 0.25rem;
    background-color: #fff;
}

/* Gallery item container with relative positioning for overlay */
.gallery-item-wrapper {
    position: relative;
    display: inline-block;
    width: 120px;
}

/* Hover effect matching ItemList */
.gallery-item-wrapper img {
    transition: all 0.3s ease;
    opacity: 1;
}

.gallery-item-wrapper img:hover {
    opacity: 0.8;
    transform: scale(1.05);
}

/* Broken glass overlay for damaged items */
.damage-overlay {
    position: absolute;
    top: 8px;
    left: 8px;
    background-color: rgba(220, 53, 69, 0.95);
    color: white;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    z-index: 10;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
    pointer-events: none;
}

/* Set padding to keep content from hitting the edges */
.body-content {
    padding-left: 15px;
    padding-right: 15px;
}

/* Sticky Header - Make both navbars stick together */
#top_navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1030;
    background-color: #f8f8f8;
}

#bottom_navbar {
    position: fixed;
    top: 50px; /* Adjust based on top_navbar height */
    left: 0;
    right: 0;
    z-index: 1029;
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* Set width on the form input elements since they're 100% wide by default */
input,
select,
textarea {
    max-width: 280px;
}

.custom-input-sm {
    height: 25px; /* or any other value that suits your design */
    padding: 2px 2px; /* adjust internal spacing */
    font-size: 12px; /* you may want to reduce font size as well */
}

.nav-item a:hover {
    background-color: cornflowerblue;
    color: white; /* Optional: You might want to change the text color upon hover for better readability */
}

.nav-link.active:hover {
    background-color: #f8f9fa; /* Lighter shade for hover, change as needed */
    color: #0056b3; /* Bootstrap primary color for link text on hover, change as needed */
}

/* Sticky Header - Make entire header sticky together */
.top-bar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 20px;
    background-color: #fcfdff;
    color: white;
    padding: 2px 0px;
    z-index: 1002;
}

    .top-bar a {
        color: #4a7bb0 !important;
        font-size: 12px;
    }

.top-bar a:hover {
    color: #e8f1fa !important;
}

/* Make main header sticky and blue */
#header {
    position: fixed !important;
    top: 0;
    left: 0;
    width: 100%;
    background-color: #fcfdff;
    z-index: 1001;
    padding-top: 10px !important;
    padding-bottom: 10px !important;
}

    /* soft fade under header */
    #header::after {
        content: "";
        position: absolute;
        left: 0;
        top: 100%;
        width: 100%;
        height: 10px; /* adjust fade depth */
        pointer-events: none;
        background: linear-gradient( to bottom, rgba(252, 253, 255, 1) 0%, rgba(252, 253, 255, 0) 100% );
    }

#header .navbar-brand img {
    max-height: 60px;
    width: auto !important;
    object-fit: contain !important;
}

#header .navbar-nav {
    margin-top: 0 !important;
    padding-top: 0 !important;
}

    #header .nav-link {
        color: #4a7bb0 !important;
        padding: 8px 15px !important;
    }

#header .nav-link:hover {
    background-color: rgba(255,255,255,0.15);
    border-radius: 4px;
}

/* Add padding to main content to account for fixed header */
main#content {
    padding-top: 20px;
}

body {
    padding-top: 0;
}

/* Adjust gradient overlay */
.gradient-y-three-sm-primary {
    margin-top: 60px;
}








.footer {
    position: fixed;
    left: 0;
    bottom: 0;
    width: 100%;
    background-color: #ffffff;
    color: black;
    text-align: center;
    padding: 10px;
}

.bg-footer {
    background-color: #dfe5e9 !important;
}

.thumbnail {
    display: inline-block;
    display: block;
    height: auto;
    max-width: 100%;
    padding: 4px;
    line-height: 1.428571429;
    background-color: #ffffff;
    border: 1px solid #dddddd;
    border-radius: 4px;
    -webkit-transition: all 0.2s ease-in-out;
    transition: all 0.2s ease-in-out;
}

    .thumbnail > img {
        display: block;
        height: auto;
        max-width: 100%;
    }

a.thumbnail:hover,
a.thumbnail:focus {
    border-color: #428bca;
}

.thumbnail > img {
    margin-right: auto;
    margin-left: auto;
}

.thumbnail .caption {
    padding: 9px;
    color: #333333;
}





.zoomEffect {
    padding: 20px;
}

    .zoomEffect .lightbox img {
        width: 100%;
        margin-bottom: 30px;
        transition: 0.1s ease-in-out;
        box-shadow: 0 2px 3px rgba(0,0,0,0.2);
    }


        .zoomEffect .lightbox img:hover {
            transform: scale(1.02);
            box-shadow: 0 8px 15px rgba(0,0,0,0.3);
        }

/* Table rows semi-transparent - Override Bootstrap CSS variables */
.table,
.grid-mvc .table,
.grid-mvc table {
    --bs-table-bg: transparent !important;
    --bs-table-striped-bg: rgba(247, 250, 255, 0.4) !important;
    --bs-table-hover-bg: rgba(245, 245, 245, 0.5) !important;
    --bs-table-accent-bg: transparent !important;
    background-color: transparent !important;
}

/* Force all table rows and cells to be transparent */
.grid-mvc table tbody tr,
.grid-mvc table tbody tr td,
.grid-mvc .table tbody tr,
.grid-mvc .table tbody tr td,
.table tbody tr,
.table tbody tr td {
    background-color: transparent !important;
}

/* Override striped rows */
.grid-mvc table tbody tr:nth-of-type(odd) > *,
.grid-mvc .table tbody tr:nth-of-type(odd) > *,
.table tbody tr:nth-of-type(odd) > * {
    background-color: rgba(247, 250, 255, 0.4) !important;
}

/* Override even rows */
.grid-mvc table tbody tr:nth-of-type(even) > *,
.grid-mvc .table tbody tr:nth-of-type(even) > *,
.table tbody tr:nth-of-type(even) > * {
    background-color: rgba(255, 255, 255, 0.3) !important;
}

/* Hover effect */
.grid-mvc table tbody tr:hover,
.grid-mvc table tbody tr:hover td,
.grid-mvc .table tbody tr:hover,
.grid-mvc .table tbody tr:hover td,
.table tbody tr:hover,
.table tbody tr:hover td {
    background-color: rgba(245, 245, 245, 0.5) !important;
}

/* Make jumbotron container transparent */
.jumbotron {
    background-color: rgba(255, 255, 255, 0.3) !important;
}
    .zoomEffect img {
        border-radius: 12px;
    }













.form-signin {
    max-width: 380px;
    padding: 15px 35px 45px;
    margin: 0 auto;
    background-color: #fff;
    border: 1px solid rgba(0, 0, 0, 0.1);
}

    .form-signin .form-signin-heading,
    .form-signin .checkbox {
        margin-bottom: 30px;
    }

    .form-signin .checkbox {
        font-weight: normal;
    }

    .form-signin .form-control {
        position: relative;
        font-size: 16px;
        height: auto;
        padding: 10px;
        -webkit-box-sizing: border-box;
        -moz-box-sizing: border-box;
        box-sizing: border-box;
    }

        .form-signin .form-control:focus {
            z-index: 2;
        }

    .form-signin input[type="text"] {
        margin-bottom: -1px;
        border-bottom-left-radius: 0;
        border-bottom-right-radius: 0;
    }

    .form-signin input[type="password"] {
        margin-bottom: 20px;
        border-top-left-radius: 0;
        border-top-right-radius: 0;
    }

.wrapper {
    margin-top: 80px;
    margin-bottom: 80px;
}

.galleryx {
    display: flex;
    flex-wrap: wrap;
}

    .galleryx a {
        position: relative; /* anchor tag must be positioned */
        display: block; /* make the anchor tag a block element to occupy full width */
    }

    .galleryx img {
        display: block; /* remove default inline styling for images */
        max-width: 100%; /* make sure image doesn't overflow parent */
    }

.favorite-icon,
.damaged-icon {
    display: block;
    width: 25px;
    height: 25px;
    position: absolute;
    top: 0;
    left: 0;
    pointer-events: none;
}

.favorite-icon {
    background: url('../Images/fave_tiny_icon.png') no-repeat;
}

.damaged-icon {
    background: url('../Images/damage_tiny_icon.png') no-repeat;
    left: 25px; /* position the damaged icon to the right of the favorite icon */
}

.editmode {
    background-color: #bfdaff9e;
}

.selected {
    border: 4px solid #EFA31D;
}

.badge {
    position: absolute;
    min-width: 10px;
    font-size: 11px;
    font-weight: bold;
    color: #fff;
    white-space: nowrap;
    vertical-align: top;
}

input[type="search"]::-webkit-search-cancel-button {
    -webkit-appearance: searchfield-cancel-button;
}

.badge-circle {
    border-radius: 50%;
    width: 16px; /* Width of the badge */
    height: 16px; /* Height of the badge */
    display: inline-flex;
    justify-content: center;
    align-items: center;
    margin-left: 0px;
    margin-top: -35px;
}



.badge-primary {
    background-color: #007bff;
}

.badge-secondary {
    background-color: #6c757d;
}

.badge-success {
    background-color: #28a745;
}

.badge-danger {
    background-color: #dc3545;
}

.badge-warning {
    background-color: #ffc107;
}

.badge-info {
    background-color: #17a2b8;
}

.badge-light {
    background-color: #f8f9fa;
}

.badge-dark {
    background-color: #343a40;
}

.badge-disabled {
    background-color: rgba(0,0,0,0.3);
}

/* ===== INVENTORY TABLE STYLES ===== */

/* Make table container responsive and match card width */
.inventory-table-container {
    width: 100%;
    overflow-x: auto;
    background-color: #00000000;
    padding: 0px;
    border-radius: 8px;
}

/* Reduce table font size for tighter design */
.grid-mvc,
.grid-mvc table,
.grid-mvc tbody,
.grid-mvc thead {
    font-size: 0.75rem !important;
}

.grid-mvc table {
    width: 100%;
    margin-bottom: 0;
}

.grid-mvc th {
    font-size: 0.75rem !important;
    padding: 6px 8px !important;
    white-space: nowrap;
    font-weight: 600;
}

.grid-mvc td {
    font-size: 0.75rem !important;
    padding: 6px 8px !important;
    vertical-align: middle;
}

.grid-mvc td p {
    font-size: 0.75rem !important;
    margin: 0;
}

.grid-mvc td a {
    font-size: 0.75rem !important;
}

/* Center the pager and style it */
.grid-mvc .grid-pager {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    margin-top: 20px !important;
    width: 100%;
}

.grid-mvc .grid-pager ul.pagination {
    margin: 0 auto !important;
    display: flex;
    justify-content: center;
}

.grid-mvc .grid-pager .pagination li {
    display: inline-block;
    margin: 0 2px;
}

.grid-mvc .grid-pager .pagination li a,
.grid-mvc .grid-pager .pagination li span {
    display: block;
    padding: 6px 12px;
    font-size: 0.875rem;
    color: #007bff;
    background-color: #fff;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    text-decoration: none;
}

.grid-mvc .grid-pager .pagination li.active span {
    background-color: #007bff;
    color: #fff;
    border-color: #007bff;
}

.grid-mvc .grid-pager .pagination li a:hover {
    background-color: #e9ecef;
    border-color: #dee2e6;
}

/* Responsive column hiding - Mobile first */
/* Ensure Thumbnail (col 1) and Description (col 3) ALWAYS show on all screen sizes */
.grid-mvc th:nth-child(1),
.grid-mvc td:nth-child(1),
.grid-mvc th:nth-child(3),
.grid-mvc td:nth-child(3),
table.grid-table th:nth-child(1),
table.grid-table td:nth-child(1),
table.grid-table th:nth-child(3),
table.grid-table td:nth-child(3) {
    display: table-cell !important;
}

@media (max-width: 575px) {
    /* On extra small screens, hide Status (col 2) and all columns 4+ */
    .grid-mvc th:nth-child(2),
    .grid-mvc td:nth-child(2),
    table.grid-table th:nth-child(2),
    table.grid-table td:nth-child(2),
    .grid-mvc th:nth-child(n+4),
    .grid-mvc td:nth-child(n+4),
    table.grid-table th:nth-child(n+4),
    table.grid-table td:nth-child(n+4) {
        display: none !important;
    }
}

@media (min-width: 576px) and (max-width: 767px) {
    /* On small screens, hide columns 4+ */
    .grid-mvc th:nth-child(n+4),
    .grid-mvc td:nth-child(n+4),
    table.grid-table th:nth-child(n+4),
    table.grid-table td:nth-child(n+4) {
        display: none !important;
    }
}

@media (min-width: 768px) and (max-width: 991px) {
    /* On medium screens, hide columns 5+ */
    .grid-mvc th:nth-child(n+5),
    .grid-mvc td:nth-child(n+5),
    table.grid-table th:nth-child(n+5),
    table.grid-table td:nth-child(n+5) {
        display: none !important;
    }
}

@media (min-width: 992px) {
    /* On large screens, show all columns */
}

/* Improve table readability */
.grid-mvc tbody tr:hover {
    background-color: rgba(233, 236, 239, 0.6) !important;
}

.grid-mvc .grid-filter {
    font-size: 0.75rem !important;
}

.grid-mvc .grid-filter input {
    font-size: 0.75rem !important;
    padding: 4px 6px !important;
}

/* Compact grid header */
.grid-mvc thead th {
    background-color: #f8f9fa;
    border-bottom: 2px solid #dee2e6;
}





.modal-backdrop.show {
    z-index: 1040; /* or a value less than your modal's z-index */
}

.modal {
    z-index: 1050; /* or a value higher than the backdrop's z-index */
}

.img-fluid.outstanding {
    /*box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.5);*/ /* Add shadow for 3D effect */
}




.gradient-y-three-sm-primary::before,
.gradient-y-three-sm-primary::after {
    content: "";
    position: absolute;
    top: -20%; /* Adjusted to center vertically after scaling */
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 800 200"><defs><linearGradient id="cloudGradient" x1="0" y1="0" x2="0" y2="1"><stop offset="0%" stop-color="%23ffffff"/><stop offset="100%" stop-color="%23ffffff00"/></linearGradient></defs><path d="M0 100 Q 50 50 100 100 T 200 100 T 300 100 T 400 100 T 500 100 T 600 100 T 700 100 T 800 100 V 200 H 0 Z" fill="url(%23cloudGradient)"/></svg>'); /* your SVG background */
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
    opacity: 0.3;
    z-index: -1;
    /* Add transform to scale vertically */
    transform: translateY(-80%) scaleY(0.20);
}

.gradient-y-three-sm-primary::before {
    top: -12%;
    left: 0;
    transform: translateY(-20%) scaleY(0.20);
}

.gradient-y-three-sm-primary::after {
    top: calc(60%); /* 50 pixels lower */
    left: 0px; /* 100 pixels to the left */
    transform: translateY(-50%) scaleY(0.4) translateX(0px);
    opacity: 0.5;
}


.form-control {
    box-sizing: border-box; /* Include padding and borders in the element's width */
}

.password-strength {
    display: flex;
    gap: 0px;
    padding: 0; /* Remove padding if you have any */
    margin-top: 0px; /* Adjust as needed */
    border: none; /* Remove border if you have any, or adjust it to match the password input field */
}

.strength-line {
    height: 2px;
    flex-grow: 1;
    background-color: #b4b4b4; /* Starting color, weak password */
    transition: background-color 0.3s; /* Optional: smooth transition for color change */
}


/* Change the background colors based on the password strength */
.weak .strength-line:nth-child(1),
.medium .strength-line:nth-child(1),
.strong .strength-line:nth-child(1),
.very-strong .strength-line:nth-child(1) {
    background-color: #f98a95; /* red */
}

.medium .strength-line:nth-child(2),
.strong .strength-line:nth-child(2),
.very-strong .strength-line:nth-child(2) {
    background-color: #fad568; /* yellow */
}

.strong .strength-line:nth-child(3),
.very-strong .strength-line:nth-child(3) {
    background-color: #60cd79; /* green */
}

.very-strong .strength-line:nth-child(4) {
    background-color: #60cd79; /* green */
}


.custom-tooltip {
    position: relative;
    display: inline-block;
}

    .custom-tooltip::after {
        content: attr(data-title);
        white-space: pre-line;
        position: absolute;
        bottom: 100%;
        left: 50%;
        transform: translateX(-50%);
        background-color: rgba(0, 0, 0, 0.75);
        color: #fff;
        padding: 5px;
        border-radius: 3px;
        z-index: 1000;
        width: max-content;
        max-width: 200px;
        text-align: center;
        font-size: 12px;
        line-height: 1.2;
        display: none;
    }

    .custom-tooltip:hover::after {
        display: block;
    }







/* Timeline container */
.timeline-container {
    position: relative;
    margin: 0;
    padding: 0;
}

    /* Vertical line */
    .timeline-container::before {
        content: '';
        position: absolute;
        left: 50px; /* Adjust to position the line within the narrower panel */
        top: 0;
        bottom: 0;
        width: 2px;
        background-color: #dee2e6;
    }

    .timeline-container::before {
        left: 85px;
        transform: translateX(-50%);
    }

/* Timeline event */
.timeline-event {
    position: relative;
    display: flex;
    align-items: center;
    margin-bottom: 5px; /* Reduced from 20px to make events closer */
}

/* Timeline circle */
.timeline-circle {
    position: absolute;
    left: 50px; /* Same as vertical line */
    top: 50%;
    transform: translateY(-50%);
    width: 8px;
    height: 8px;
    background-color: #0d6efd;
    border-radius: 50%;
    z-index: 1;
}

/* First event - remove line above */
.timeline-event:first-child::before {
    top: 7px; /* Half the circle height */
}

/* Last event - remove line below */
.timeline-event:last-child::before {
    bottom: 7px; /* Half the circle height */
}

/* Timeline date */
.timeline-date {
    width: 70px;
    text-align: right;
    margin-right: 10px;
    font-style:italic;
    font-size: 10px;
    color: #6c757d;
}

.timeline-details {
    flex: 1;
    margin-left: 15px; /* Adjusted for tighter spacing */
    font-size: 10px;
}

/* Optional: Adjust circle position */
.timeline-circle {
    flex-shrink: 0;
}


@media (max-width: 576px) {
    .timeline-event {
        flex-direction: column;
        align-items: flex-start;
    }

    .timeline-date,
    .timeline-details {
        margin: 5px 0;
        text-align: left;
    }

    .timeline-circle {
        margin: 10px 0;
    }

    .timeline-container {
        padding-left: 20px;
    }
}

.timeline-circle:hover {
    background-color: #0a58ca; /* Darker shade */
    cursor: pointer;
}

.timeline-details:hover {
    text-decoration: underline;
    cursor: pointer;
}


.timeline-circle {
    position: absolute;
    left: 81px;
    top: 50%; /* Center vertically within the event */
    transform: translateY(-50%);
}

    .timeline-circle i {
        font-size: 10px;
    }


.history-content {
    max-width: 100%; /* Adjust as needed */
    margin: 0 0; /* Centers the content within the td */
    padding: 10px; /* Optional: adjust for desired padding */
    background-color:  aliceblue; /* Optional: to distinguish the panel */
    border-radius: 5px; /* Optional: adds rounded corners */
    text-align: left;

}


/* Centered spinner */
#loadingSpinner {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 1001; /* Ensure it's above the overlay */
}


#overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.5;
    background-color: #000;
    z-index: 9998;
}


.disabled {
    pointer-events: none; /* Disables all mouse interactions */
    opacity: 0.5; /* Makes the element appear faded */
    cursor: not-allowed; /* Changes the cursor to indicate non-interactivity */
}

/* Optional: Specific styling for icons within disabled links */
a.disabled .nav-icon {
    color: #6c757d; /* Bootstrap's secondary color for muted text */
}


/* Full-page overlay */
#tableOverlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5); /* Semi-transparent black */
    z-index: 1000; /* Ensure it's above everything */
    display: none; /* Hidden by default */
}

.error-highlight {
    background-color: #f8d7da !important; /* Light red background */
}

/* ===== GRID FILTER PANEL COMPACT STYLES ===== */
/* Make filter dropdown popup more compact to match grid design */
.grid-dropdown {
    min-width: 150px !important;
    font-size: 0.75rem !important;
}

.grid-dropdown-inner {
    padding: 8px !important;
}

/* Compact form controls in filter panel */
.grid-dropdown .form-control,
.grid-dropdown select,
.grid-dropdown input[type="text"],
.grid-dropdown input[type="number"],
.grid-filter-input {
    font-size: 0.75rem !important;
    padding: 4px 8px !important;
    height: auto !important;
    min-height: 28px !important;
    max-width: 100% !important;
}

/* Compact dropdown/select in filter */
.grid-dropdown select.form-control,
.grid-dropdown select {
    padding: 4px 6px !important;
    font-size: 0.75rem !important;
    height: 28px !important;
}

/* Compact Apply button in filter panel */
.grid-dropdown .btn,
.grid-dropdown button,
.grid-filter-buttons .btn {
    font-size: 0.7rem !important;
    padding: 4px 12px !important;
    min-height: 26px !important;
    line-height: 1.2 !important;
}

/* Filter labels */
.grid-dropdown label,
.grid-dropdown .grid-filter-type-label {
    font-size: 0.7rem !important;
    margin-bottom: 2px !important;
    font-weight: 600;
    color: #495057;
}

/* Spacing between filter elements */
.grid-dropdown .form-group,
.grid-dropdown .grid-filter-type,
.grid-dropdown .grid-filter-value {
    margin-bottom: 6px !important;
}

/* Filter menu list items */
.grid-dropdown ul.menu-list li a {
    font-size: 0.75rem !important;
    padding: 3px 5px !important;
}

/* Fix: Clear Filter link - compact font and icon size */
.grid-dropdown-inner ul.menu-list li a.grid-filter-clear {
    font-size: 0.75rem !important;
    padding-left: 18px !important;
    background-size: 10px 10px !important;
    background-position: 3px center !important;
}

/* Fix: Sort arrow sizes - make both consistent and smaller */
table.grid-table .grid-header .sorted-asc .grid-sort-arrow:after,
table.grid-table .grid-header .sorted-desc .grid-sort-arrow:after {
    font-size: 0.75rem !important;
    font-weight: normal !important;
}

/* Also target the grid-sort-arrow span directly */
table.grid-table .grid-header .grid-sort-arrow {
    font-size: 0.75rem !important;
}

/* ===== INVENTORY THUMBNAIL STYLES ===== */
/* Style thumbnail images in grid to match Item page */
/* Note: Using high specificity to override inline styles */
.grid-mvc table td img.img-rounded,
.grid-mvc table td a img.img-rounded,
.grid-mvc table td img,
.grid-mvc table td a img,
table.grid-table td img.img-rounded,
table.grid-table td a img.img-rounded,
table.grid-table td img,
table.grid-table td a img {
    width: 80px !important;
    max-width: 80px !important;
    min-width: 80px !important;
    height: 80px !important;
    min-height: 80px !important;
    object-fit: contain !important;
    border: 1px solid #dddddd !important;
    border-radius: 8px !important;
    padding: 3px !important;
    background-color: #ffffff !important;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1) !important;
    transition: all 0.2s ease-in-out !important;
}

.grid-mvc table td a img:hover,
.grid-mvc table td a img.img-rounded:hover,
table.grid-table td a img:hover,
table.grid-table td a img.img-rounded:hover {
    border-color: #5b8fc9 !important;
    box-shadow: 0 3px 8px rgba(0,0,0,0.15) !important;
    transform: scale(1.02);
}

/* Fallback/default image - slightly smaller inside container */
.grid-mvc table td img[src*="box-120x60"],
.grid-mvc table td a img[src*="box-120x60"],
table.grid-table td img[src*="box-120x60"],
table.grid-table td a img[src*="box-120x60"] {
    padding: 4px !important; /* More padding = smaller image inside */
    object-fit: contain !important;
}

/* Status icons (inside p inside td) */
.grid-mvc table td p img,
table.grid-table td p img {
    width: auto !important;
    max-width: 22px !important;
    min-width: auto !important;
    height: 22px !important;
    min-height: auto !important;
    object-fit: unset !important;
    border: none !important;
    border-radius: 0 !important;
    padding: 0 !important;
    background-color: transparent !important;
    box-shadow: none !important;
}

/* Status cell layout - icon on top, text on bottom */
.grid-mvc table td p,
table.grid-table td p {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    gap: 2px !important;
}

/* ===== GRID ROW SELECTION FIX ===== */
/* Fix: When row is selected, ensure all text remains readable */
table.grid-table tr.grid-row-selected td,
table.grid-table tr.grid-row-selected td p,
table.grid-table tr.grid-row-selected td a,
table.grid-table tr.grid-row-selected td span {
    color: white !important;
}

/* Disable row selection styling to prevent white text issue */
table.grid-table tr.grid-row-selected td {
    background: transparent !important;
    color: inherit !important;
}

table.grid-table tr.grid-row-selected td p,
table.grid-table tr.grid-row-selected td a,
table.grid-table tr.grid-row-selected td span {
    color: inherit !important;
}

/* ===== HEADER ALERT BOX STYLES ===== */
/* Remove vertical divider line in alert header */
.alert.alert-light {
    border: none !important;
}

.alert.alert-light .col-md-6 {
    border: none !important;
    border-left: none !important;
    border-right: none !important;
}

/* Remove any pseudo-element borders */
.alert.alert-light .col-md-6::before,
.alert.alert-light .col-md-6::after {
    display: none !important;
}