/* Storage UI Design */

/* Enhanced Color Palette */
:root {
    --primary: #1C3563;
    --primary-dark: #1245a8;
    --primary-light: #2C3F50;
    --primary-jp: #1C3563;
    --primary-jp-light: #3297DB;
    --secondary: #64748b;
    --accent: #f59e0b;
    --success: #10b981;
    --warning: #f59e0b;
    --error: #ef4444;

    --gray-50: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-600: #475569;
    --gray-700: #334155;
    --gray-800: #1e293b;
    --gray-900: #0f172a;

    --bg-gradient: linear-gradient(135deg, var(--primary-jp) 0%, var(--primary-dark) 100%);
    --card-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    --card-shadow-hover: 0 20px 40px rgba(0, 0, 0, 0.15);
    --text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);

    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 9999px;

    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);

    /* Storage Specific Overrides/Additions */
    --storage-primary: #1C3563;
    --storage-text-primary: #1C3563;
    /* Explicit text color */
    --storage-primary-hover: #1245a8;
    --storage-blue-light: rgba(28, 53, 99, 0.05);
    --storage-border: #e2e8f0;
    --storage-radius: 12px;
}

/* Storage Typography */
.storage-ui {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
    color: var(--gray-800);
}

.text-storage-primary {
    color: var(--storage-text-primary);
}

/* Storage Gradient Backgrounds */
.storage-gradient-bg {
    /* Match homepage exactly: linear-gradient(135deg, var(--primary-jp) 0%, var(--primary-dark) 50%, var(--primary-light) 100%) */
    background: linear-gradient(135deg, #2a3f5c 0%, #2c4d85 50%, #3a4a5a 100%);
    position: relative;
    overflow: hidden;
}

.storage-gradient-bg::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    /* Subtle radial overlay */
    background: radial-gradient(circle at 20% 80%, rgba(255, 255, 255, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 255, 255, 0.05) 0%, transparent 50%);
}

.storage-bg-light-blue {
    background-color: #eff6ff;
    /* blue-50 */
}

.storage-card-white {
    background-color: white;
    border-radius: 1rem;
    /* rounded-2xl */
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    /* shadow-sm */
    border: 1px solid #f1f5f9;
    /* gray-100 */
    padding: 1.5rem;
    /* p-6 */
    transition: all 0.3s ease;
}

.storage-card-white:hover {
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    /* shadow-md */
    transform: translateY(-2px);
}


.storage-gradient-bg-light {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 50%, #e2e8f0 100%);
    min-height: 100vh;
}

/* Enhanced animations */
@keyframes storageFadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes storageSlideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.storage-fade-in-up {
    animation: storageFadeInUp 0.6s ease-out;
}

.storage-slide-in-left {
    animation: storageSlideInLeft 0.6s ease-out;
}

/* Storage glassmorphism effects */
.storage-glass {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

/* Storage Feature Cards */
.storage-feature-card {
    background: white;
    border-radius: var(--radius-xl);
    padding: 40px 32px;
    box-shadow: var(--card-shadow);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.storage-feature-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--card-shadow-hover);
}

.storage-feature-card__icon {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--primary-jp) 0%, var(--primary-dark) 100%);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 24px;
    color: white;
    font-size: 1.5rem;
}

.storage-feature-card__title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--gray-900);
}

.storage-feature-card__link {
    color: var(--primary-jp);
    text-decoration: none;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition);
}

/* Storage Buttons */
.storage-btn {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 16px 32px;
    border-radius: var(--radius-full);
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.storage-btn--primary {
    background: linear-gradient(135deg, var(--primary-jp) 0%, var(--primary-dark) 100%);
    color: white;
    box-shadow: 0 4px 20px rgba(28, 53, 99, 0.3);
}

.storage-btn--primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(28, 53, 99, 0.4);
}

/* --- Storage Specific Styles --- */

/* Inventory Table Styles */
.inventory-table-container {
    border: 1px solid var(--storage-border);
    border-radius: var(--storage-radius);
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

#inventory-table-body tr {
    border-bottom: 1px solid var(--storage-border);
}

#inventory-table-body tr:last-child {
    border-bottom: none;
}

#inventory-table-body tr:hover {
    background-color: var(--storage-blue-light);
}

/* Category Filter Buttons - Modern Pill Style */
.storage-filter-btn {
    border-radius: 9999px;
    padding: 6px 16px;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.2s ease;
    border: 1px solid var(--storage-border);
    background-color: white;
    color: #475569;
}

.storage-filter-btn:hover {
    background-color: #f8fafc;
    border-color: #cbd5e1;
}

.storage-filter-btn.active {
    background-color: var(--storage-primary) !important;
    color: white !important;
    border-color: var(--storage-primary) !important;
    box-shadow: 0 2px 4px rgba(28, 53, 99, 0.2);
}



/* Search Input Focus */
/* Search Input Focus */
.storage-search-input {
    border-radius: 9999px;
    padding-left: 2.5rem;
}

.storage-search-input:focus {
    border-color: var(--storage-primary);
    outline: none;
    box-shadow: 0 0 0 2px rgba(28, 53, 99, 0.1);
}

/* Action Links */
.storage-action-link {
    color: var(--storage-primary);
    font-weight: 600;
    text-decoration: none;
    font-size: 0.875rem;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.storage-action-link:hover {
    color: var(--storage-primary-hover);
    text-decoration: underline;
}

/* Card Hover Effects */
/* Storage Badges */
.storage-badge {
    display: inline-flex;
    align-items: center;
    padding: 2px 10px;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 500;
    line-height: 1;
}

.storage-badge--instock {
    background-color: #eff6ff;
    /* blue-50 */
    color: var(--storage-primary);
    border: 1px solid #dbeafe;
    /* blue-100 */
}

.storage-badge--allocated {
    background-color: #f1f5f9;
    /* slate-100 */
    color: #334155;
    /* slate-700 */
    border: 1px solid #e2e8f0;
    /* slate-200 */
}

.storage-badge--shortage {
    background-color: white;
    color: var(--storage-primary);
    border: 1px solid var(--storage-primary);
    font-weight: 700;
}

.storage-badge--low {
    background-color: #f9fafb;
    /* gray-50 */
    color: #4b5563;
    /* gray-600 */
    border: 1px solid #e5e7eb;
    /* gray-200 */
}

.storage-badge--eol {
    background-color: #f9fafb;
    color: #9ca3af;
    /* gray-400 */
    text-decoration: line-through;
}

.storage-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    margin-right: 6px;
}

.storage-dot--instock {
    background-color: #3b82f6;
}

/* blue-500 */
.storage-dot--allocated {
    background-color: #64748b;
}

/* slate-500 */
.storage-dot--shortage {
    background-color: var(--storage-primary);
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

.storage-dot--low {
    background-color: #9ca3af;
}

/* gray-400 */

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: .5;
    }
}

/* Storage Pills (Tags) */
.storage-pill {
    display: inline-flex;
    align-items: center;
    padding: 2px 10px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 500;
}

.storage-pill--primary {
    background-color: #eff6ff;
    color: var(--storage-primary);
    border: 1px solid #dbeafe;
}

.storage-pill--secondary {
    background-color: #f9fafb;
    color: #334155;
    border: 1px solid #f1f5f9;
}

/* Storage Icon Box */
.storage-icon-box {
    width: 9rem;
    height: 9rem;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: white;
    border: 1px solid #e5e7eb;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    border-radius: 1.5rem;
    overflow: hidden;
    padding: 1rem;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.storage-icon-box svg {
    width: 3.5rem;
    height: 3.5rem;
}

/* Storage Stat Card */
.storage-stat-card {
    padding: 1.25rem 2rem;
    background-color: white;
    border-radius: 1rem;
    border: 1px solid #f1f5f9;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    text-align: center;
    min-width: 140px;
    transition: all 0.3s ease;
}

.storage-stat-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

.storage-stat-label {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: #64748b;
    margin-top: 4px;
}