/*
 * Blumine Module Dedicated Stylesheet
 * Scoped styles and UI enhancements for Blumine
 */

/* General & Layout Enhancements */
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: #2d3748;
    background-color: #f7fafc;
}

/* Navbar */
.site-header .navbar {
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
}

.site-header .navbar-brand {
    display: flex;
    align-items: center;
}

.site-header .navbar-nav .nav-link {
    font-size: 0.95rem;
    font-weight: 500;
    padding: 0.5rem 0.85rem;
    border-radius: 0.25rem;
    transition: all 0.2s ease-in-out;
}

.site-header .navbar-nav .nav-link:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.site-header .navbar-nav .nav-link.active {
    background-color: rgba(255, 255, 255, 0.2);
    color: #ffffff;
    border-bottom: none;
}

/* Sidebar Styling */
.sidebar {
    background: linear-gradient(180deg, #2b6cb0 0%, #1a4971 100%);
    box-shadow: 2px 0 6px rgba(0, 0, 0, 0.06);
    border-right: 1px solid rgba(0, 0, 0, 0.05);
}

.sidebar h4, .sidebar-header {
    color: #ffffff;
    font-size: 1.1rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 0 1rem;
    margin-bottom: 1rem;
}

.sidebar-link-wrapper .btn,
.sidebar .btn {
    display: block;
    width: calc(100% - 1.5rem);
    margin: 0.25rem 0.75rem;
    padding: 0.5rem 0.85rem;
    color: #e2e8f0 !important;
    font-size: 0.9rem;
    font-weight: 500;
    text-align: left;
    border-radius: 0.35rem;
    border: none;
    border-left: 3px solid transparent;
    transition: all 0.2s ease;
    background: transparent;
}

.sidebar-link-wrapper .btn:hover,
.sidebar .btn:hover {
    background-color: rgba(255, 255, 255, 0.15) !important;
    color: #ffffff !important;
    margin-left: 0.75rem;
    transform: translateX(3px);
}

.sidebar-link-wrapper .btn.sidebar-active,
.sidebar .btn.sidebar-active {
    background-color: rgba(255, 255, 255, 0.25) !important;
    color: #ffffff !important;
    border-left: 3px solid #63b3ed;
    font-weight: 600;
}

/* Cards & Panels */
.blumine-dashboard-card,
.card {
    border: 1px solid #e2e8f0;
    border-radius: 0.5rem;
    background-color: #ffffff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.blumine-dashboard-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transform: translateY(-2px);
}

.card-header {
    background-color: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    font-weight: 600;
    color: #2d3748;
}

/* Tables */
.table {
    margin-bottom: 0;
    color: #2d3748;
}

.table th {
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #718096;
    border-top: none;
    border-bottom: 2px solid #e2e8f0;
    padding: 0.75rem 1rem;
    vertical-align: middle;
}

.table td {
    padding: 0.75rem 1rem;
    vertical-align: middle;
    border-top: 1px solid #edf2f7;
    font-size: 0.9rem;
}

.table-hover tbody tr:hover {
    background-color: #f7fafc;
}

/* Job ID Cell Wrapping */
.job-id-cell {
    width: 170px;
    min-width: 140px;
    max-width: 200px;
    white-space: normal !important;
    word-break: break-all;
    overflow-wrap: anywhere;
}

/* Auth Cards */
.blumine-auth-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: calc(100vh - 200px);
    padding: 2rem 1rem;
}

.blumine-auth-card {
    width: 100%;
    max-width: 440px;
    border-radius: 0.75rem;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.blumine-card-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 1.5rem;
    line-height: 1;
}

.blumine-icon-blue {
    background-color: #ebf8ff;
    color: #3182ce;
}

.blumine-icon-green {
    background-color: #f0fff4;
    color: #38a169;
}

.blumine-icon-red {
    background-color: #fff5f5;
    color: #e53e3e;
}

/* Form Controls */
.form-control {
    border-radius: 0.375rem;
    border: 1px solid #cbd5e0;
    font-size: 0.95rem;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.form-control:focus {
    border-color: #3182ce;
    box-shadow: 0 0 0 0.2rem rgba(49, 130, 206, 0.2);
}

/* Buttons */
.btn-primary {
    background-color: #3182ce;
    border-color: #3182ce;
    font-weight: 500;
}

.btn-primary:hover,
.btn-primary:focus {
    background-color: #2b6cb0;
    border-color: #2b6cb0;
}

.btn-outline-primary {
    color: #3182ce;
    border-color: #3182ce;
    font-weight: 500;
}

.btn-outline-primary:hover,
.btn-outline-primary:focus {
    background-color: #3182ce;
    border-color: #3182ce;
    color: #ffffff;
}

/* Badges */
.badge {
    font-weight: 600;
    padding: 0.35em 0.65em;
    border-radius: 0.25rem;
}

.badge-success {
    background-color: #38a169;
}

.badge-warning {
    background-color: #dd6b20;
    color: #ffffff;
}

.badge-info {
    background-color: #3182ce;
}

/* Order Item Card (replaces fieldset.order-item) */
.order-item-card {
    border: 1px solid #e2e8f0;
    border-radius: 0.5rem;
    margin-bottom: 1.25rem;
    background: #ffffff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.order-item-card .card-header {
    background-color: #f8fafc;
    font-weight: 600;
    padding: 0.75rem 1.25rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Truncate helpers */
.truncate {
    max-width: 200px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
