/*
 * File: erp.sesautomations.com/assets/css/admin.css
 * Project: erp.sesautomations.com
 * Author: AI Assistant
 * Version: 15.7 (Final Consolidated Version)
 * Generated on: 2025-08-10 10:20:00 IST
 *
 * Description:
 * This is the definitive, consolidated stylesheet. It includes all necessary
 * styles for the application layout and all component features, including the
 * red/green highlighting for the clone modal.
 */

/* =========================================================================
   1. DESIGN SYSTEM & CSS VARIABLES
   ========================================================================= */
:root {
    --sidebar-bg-dark: #2c3034;
    --sidebar-text-color: #adb5bd;
    --sidebar-hover-text: #ffffff;
    --sidebar-active-bg: #fd7e14; /* Orange accent */
    --sidebar-active-text: #ffffff;
    --sidebar-width-expanded: 260px;
    --sidebar-width-collapsed: 80px;
}

/* =========================================================================
   2. CORE LAYOUT & SIDEBAR
   ========================================================================= */
body { overflow-x: hidden; }
.dashboard-wrapper { display: flex; }
#sidebar-wrapper { width: var(--sidebar-width-expanded); min-height: 100vh; background-color: var(--sidebar-bg-dark); color: var(--sidebar-text-color); transition: width 0.3s ease; display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; }
.sidebar-content { flex-grow: 1; overflow-y: auto; overflow-x: hidden; }
.sidebar-heading { padding: 1rem; border-bottom: 1px solid rgba(255,255,255,0.1); }
.sidebar-brand { display: flex; align-items: center; text-decoration: none; color: #fff; }
.sidebar-logo-icon { height: 50px; width: 50px; object-fit: contain; margin-right: 15px; transition: margin 0.3s ease; }
.sidebar-brand-text { font-size: 1.2rem; font-weight: bold; white-space: nowrap; }

/* Scoped Sidebar Menu Items */
#sidebar-wrapper .list-group-item { background: transparent; border: none; color: var(--sidebar-text-color); padding: 0.9rem 1.5rem; transition: all 0.2s; white-space: nowrap; overflow: hidden; display: flex; align-items: center; }
#sidebar-wrapper .list-group-item i { font-size: 1.2rem; width: 30px; text-align: center; margin-right: 15px; transition: margin 0.3s ease; }
#sidebar-wrapper .list-group-item:hover { background: rgba(255,255,255,0.08); color: var(--sidebar-hover-text); }
#sidebar-wrapper .list-group-item.active { background-color: var(--sidebar-active-bg); color: var(--sidebar-active-text); border-radius: 8px; margin: 0.25rem 1rem; padding: 0.9rem 1.5rem; }

/* Sidebar Footer & Toggle Button */
.sidebar-footer { padding: 0.5rem 1rem; border-top: 1px solid rgba(255,255,255,0.1); flex-shrink: 0; text-align: right; }
#sidebar-collapse-btn { color: var(--sidebar-text-color); font-size: 1.5rem; border: none; background: none; transition: color 0.2s; }
#sidebar-collapse-btn:hover { color: var(--sidebar-hover-text); }
#sidebar-collapse-btn i { transition: transform 0.3s ease; }
#page-content-wrapper { flex: 1; min-width: 0; }

/* =========================================================================
   3. COLLAPSIBLE & MOBILE SIDEBAR
   ========================================================================= */
body.sidebar-collapsed #sidebar-wrapper { width: var(--sidebar-width-collapsed); }
body.sidebar-collapsed .link-text, body.sidebar-collapsed .sidebar-brand-text { display: none; }
body.sidebar-collapsed .sidebar-logo-icon { margin-right: 0; }
body.sidebar-collapsed #sidebar-wrapper .list-group-item { justify-content: center; }
body.sidebar-collapsed #sidebar-wrapper .list-group-item i { margin-right: 0; }
body.sidebar-collapsed #sidebar-wrapper .list-group-item.active { margin: 0.25rem 0.5rem; padding: 0.9rem; }
body.sidebar-collapsed .sidebar-footer { text-align: center; }
body.sidebar-collapsed #sidebar-collapse-btn i { transform: rotate(180deg); }
.sidebar-overlay { position: fixed; top: 0; left: 0; width: 100vw; height: 100vh; background-color: rgba(0, 0, 0, 0.6); z-index: 1030; opacity: 0; visibility: hidden; transition: opacity 0.3s, visibility 0.3s; }
@media (max-width: 767.98px) { #sidebar-wrapper { position: fixed; margin-left: -260px; z-index: 1032; transition: margin-left 0.3s ease-in-out; } #sidebar-wrapper.active { margin-left: 0; } body.sidebar-open .sidebar-overlay { opacity: 1; visibility: visible; } #page-content-wrapper .navbar-top { position: relative; z-index: 1031; } .sidebar-footer { display: none; } }

/* =========================================================================
   4. CONSOLIDATED FEATURE STYLES
   ========================================================================= */

/* --- A) Clone Component Highlighting --- */
.clone-highlight-unconfirmed { border-color: #dc3545 !important; box-shadow: 0 0 0 0.25rem rgba(220, 53, 69, 0.25) !important; }
.clone-highlight-confirmed { border-color: #198754 !important; box-shadow: 0 0 0 0.25rem rgba(25, 135, 84, 0.25) !important; }

/* --- B) Dense Component Inventory Table Layout --- */
.component-info-cell { font-size: 0.9rem; line-height: 1.4; }
.component-info-type { font-weight: 600; display: block; color: #000; }
.component-info-mfr, .component-info-status { font-size: 0.85em; color: #6c757d; display: block; }

/* --- C) Internal P/N Cell Attributes --- */
.internal-pn-attributes { font-size: 0.85em; color: #6c757d; display: block; font-weight: normal; }

/* --- D) Attribute Tooltip on Part Number --- */
.component-tooltip .tooltip-inner { max-width: 400px; text-align: left; background-color: #e7f5fe; color: #0a58ca; border: 1px solid #b6d4fe; }
.component-tooltip .tooltip-arrow::before { border-top-color: #e7f5fe; }
.component-tooltip ul { list-style: none; padding-left: 0; margin-bottom: 0; }
.component-tooltip .attr-name { font-weight: 600; }