/* ==========================================================================
   Khimbus Webtools - Scoped Design System & Stylesheet
   ========================================================================== */

/* Page Background & Global Typography */
body {
    background-color: #f7fafc !important;
    color: #2d3748;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* Steel Blue Brand Styling */
.bg-steel {
    background-color: #2b6cb0 !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
}

.navbar-dark .navbar-nav .nav-link {
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.95rem;
    font-weight: 500;
    padding: 0.5rem 0.85rem;
    border-radius: 4px;
    transition: background-color 0.15s ease, color 0.15s ease;
}

.navbar-dark .navbar-nav .nav-link:hover {
    color: #ffffff;
    background-color: rgba(255, 255, 255, 0.12);
    margin-top: 0;
}

.navbar-dark .navbar-nav .nav-link.active {
    color: #ffffff;
    background-color: rgba(255, 255, 255, 0.2);
    border-bottom: none;
    margin-top: 0;
}

.webtools-brand-badge {
    display: inline-block;
    background: rgba(255, 255, 255, 0.2);
    color: #ffffff;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    margin-left: 0.5rem;
    vertical-align: middle;
}

/* Card System */
.card {
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    background-color: #ffffff;
    margin-bottom: 1.5rem;
}

.card-header {
    background-color: #ffffff;
    border-bottom: 1px solid #edf2f7;
    font-weight: 600;
    color: #2d3748;
    padding: 1rem 1.25rem;
    border-top-left-radius: 8px !important;
    border-top-right-radius: 8px !important;
}

.card-header-primary {
    background: linear-gradient(135deg, #2b6cb0 0%, #2c5282 100%);
    color: #ffffff !important;
    border-bottom: none;
}

.card-header-primary h1,
.card-header-primary h2,
.card-header-primary h3,
.card-header-primary h4,
.card-header-primary h5 {
    color: #ffffff !important;
}

/* Interactive Dashboard Cards */
.webtools-dashboard-card {
    transition: transform 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    height: 100%;
}

.webtools-dashboard-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -2px rgba(0, 0, 0, 0.04);
    border-color: #cbd5e0;
}

.webtools-card-icon {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    margin-bottom: 1rem;
}

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

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

.webtools-icon-purple {
    background-color: #faf5ff;
    color: #805ad5;
}

.webtools-icon-amber {
    background-color: #fffaf0;
    color: #dd6b20;
}

.webtools-icon-teal {
    background-color: #e6fffa;
    color: #319795;
}

/* Breadcrumb Navigation */
.breadcrumb {
    background-color: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 0.65rem 1rem;
    font-size: 0.9rem;
    margin-bottom: 1.25rem;
}

.breadcrumb-item + .breadcrumb-item::before {
    content: "\f054";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    font-size: 0.65rem;
    color: #a0aec0;
    vertical-align: middle;
}

.breadcrumb-item a {
    color: #3182ce;
    text-decoration: none;
}

.breadcrumb-item a:hover {
    color: #2b6cb0;
    text-decoration: underline;
}

.breadcrumb-item.active {
    color: #718096;
    font-weight: 500;
}

/* Status Badges & Pills */
.badge-status {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.35em 0.65em;
    border-radius: 50rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

/* Responsive Tables */
.table-hover tbody tr:hover {
    background-color: #f8fafc;
}

.table th {
    font-weight: 600;
    color: #4a5568;
    border-top: none;
    background-color: #f7fafc;
}

.table td {
    vertical-align: middle;
}

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

.job-id-cell code {
    white-space: normal !important;
    word-break: break-all;
    overflow-wrap: anywhere;
    display: inline-block;
}

/* Code & Preformatted Viewers */
.webtools-log-box {
    background-color: #1a202c;
    color: #e2e8f0;
    font-family: SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    font-size: 0.85rem;
    padding: 1rem;
    border-radius: 6px;
    max-height: 240px;
    overflow-y: auto;
    white-space: pre-wrap;
    word-break: break-word;
}

.webtools-clipboard-box {
    background-color: #edf2f7;
    border-left: 4px solid #3182ce;
    padding: 0.75rem 1rem;
    border-radius: 4px;
    font-family: monospace;
    font-size: 0.95rem;
    color: #2d3748;
}

/* Centered Authentication Layout */
.webtools-auth-wrapper {
    min-height: calc(80vh - 120px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 0;
}

.webtools-auth-card {
    width: 100%;
    max-width: 440px;
    border-radius: 10px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.07), 0 2px 4px -1px rgba(0, 0, 0, 0.04);
}

/* Action Bars & Headers */
.webtools-page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #e2e8f0;
}

.webtools-page-header h1,
.webtools-page-header h2,
.webtools-page-header h3 {
    margin: 0;
    color: #1a202c;
    font-weight: 700;
}

/* Buttons */
.btn-steel {
    background-color: #2b6cb0;
    border-color: #2b6cb0;
    color: #ffffff;
}

.btn-steel:hover {
    background-color: #2c5282;
    border-color: #2c5282;
    color: #ffffff;
}

.btn-rounded {
    border-radius: 50rem;
}

/* Subtle Step Badges */
.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background-color: #3182ce;
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 700;
    margin-right: 0.5rem;
}
