/* Enterprise Portal - Custom Styles */

:root {
    --ent-primary: #0066cc;
    --ent-secondary: #6c757d;
    --ent-success: #28a745;
    --ent-danger: #dc3545;
    --ent-warning: #ffc107;
    --ent-info: #17a2b8;
    --ent-dark: #1a1d20;
    --ent-light: #f8f9fa;
    --ent-border: #dee2e6;
    --ent-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    --ent-shadow-lg: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    --ent-ai-message-bg: #2c5aa0;
}

/* General Body Styles */
.ent-body {
    background-color: #f5f7fa;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    height: 100vh;
    overflow: hidden; /* Prevent browser scrollbar */
    display: flex;
    flex-direction: column;
    padding-top: 72px; /* Space for fixed navbar */
	/* no bottom padding here; layout below handles viewport fit */
}

.ent-container {
	/* Fill remaining viewport below fixed navbar; no page scroll */
	height: calc(100vh - 72px);
	min-height: 0;
	overflow: hidden;
	flex: 1 1 auto;
}

/* Login Page Styles */
.ent-login-body {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.ent-login-container {
    width: 100%;
    max-width: 450px;
}

.ent-login-card {
    background: white;
    border-radius: 16px;
    padding: 3rem 2.5rem;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.ent-login-logo {
    width: 120px;
    height: 120px;
    border-radius: 20px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

/* Navigation Styles */
.navbar-dark {
    background-color: var(--ent-dark) !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1030;
}

.navbar-brand {
    font-size: 1.25rem;
}

.navbar-brand img {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.nav-link {
    font-weight: 500;
    transition: all 0.2s ease;
    border-radius: 8px;
    margin: 0 0.25rem;
}

.nav-link:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.nav-link.active {
    background-color: rgba(255, 255, 255, 0.15);
    font-weight: 600;
}

/* Card Styles */
.card {
    border-radius: 12px;
}

.card-header {
    background-color: white;
    border-bottom: 1px solid var(--ent-border);
    border-radius: 12px 12px 0 0 !important;
}

/* Improve section legibility */
.card-header h5,
.card-header h6 {
	font-weight: 700;
}
.card-header { background-color: #f7f9fc; }
.form-label {
	font-weight: 600;
	color: #334155;
}
.card { box-shadow: var(--ent-shadow-lg); border: 1px solid #e5e7eb; }

/* Inputs - modern look */
.form-control,
.form-select {
	background-color: #fcfdff;
	border-color: #d0d7e2;
	color: #111827;
}
.form-control::placeholder { color: #94a3b8; }
.form-control:focus,
.form-select:focus {
	border-color: #2563eb;
	box-shadow: 0 0 0 .2rem rgba(37, 99, 235, .15);
}

/* Section titles */
.card-header .bi { color: #2563eb; }
.card-header { border-bottom: 1px solid #e5e7eb; }

/* Ensure the Calls History split row fills the viewport within the container */
.ent-container .row.g-3.flex-grow-1 {
	height: 100%;
	min-height: 0;
	padding-bottom: 30px;
}

/* Stat Cards */
/* No hover effects */

.ent-stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

/* Agent Cards */
/* No hover effects */

.ent-agent-card .badge {
    font-size: 0.75rem;
    padding: 0.35rem 0.75rem;
    font-weight: 600;
}

/* Call List Item */
.call-item {
    border-left: 3px solid transparent;
	border: 1px solid transparent;
	border-radius: 12px;
	margin: 2px 4px;
    transition: all 0.2s ease;
}

.call-item:hover {
    background-color: #f8f9fa;
    border-left-color: var(--ent-primary);
}

.call-item.active {
    background-color: #e7f3ff;
    border-left-color: var(--ent-primary);
	border-color: #2563eb;
	border-width: 2px;
	box-shadow: 0 0 0 2px rgba(37,99,235,.08);
}
/* Selected item typography */
.call-item.active .call-number { color:#111 !important; font-weight:700; font-size: 1.05rem; }
.call-item.active small,
.call-item.active .badge { font-weight:600; color:#1f2937 !important; }

/* Transcript area background */
#callTranscript {
	background-color: #f0f7ff;
}

/* Form Styles */
.form-label {
    font-weight: 500;
    color: #495057;
    margin-bottom: 0.5rem;
}

.form-control:focus,
.form-select:focus {
    border-color: var(--ent-primary);
    box-shadow: 0 0 0 0.2rem rgba(0, 102, 204, 0.25);
}

textarea.form-control {
    resize: vertical;
    min-height: 80px;
}

/* Button Styles */
.btn {
    border-radius: 8px;
    font-weight: 500;
    padding: 0.5rem 1.25rem;
    transition: all 0.2s ease;
	display: inline-flex;
	align-items: center;
	gap: .5rem;
}

.btn-primary {
    background-color: var(--ent-primary);
    border-color: var(--ent-primary);
}

.btn-primary:hover {
    background-color: #0052a3;
    border-color: #0052a3;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 102, 204, 0.3);
}

.btn-lg {
    padding: 0.75rem 1.5rem;
    font-size: 1.1rem;
}

/* Footer */
.ent-footer {
    flex-shrink: 0;
    position: relative;
}

/* Utility Classes */
.font-monospace {
    font-family: 'Courier New', Courier, monospace;
}

.text-uppercase-small {
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.5px;
    font-weight: 600;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .ent-login-card {
        padding: 2rem 1.5rem;
    }
    
    .ent-stat-card {
        margin-bottom: 1rem;
    }
}

/* Loading Spinner */
.spinner-border-sm {
    width: 1rem;
    height: 1rem;
}

/* Badge Enhancements */
.badge {
    font-weight: 600;
    padding: 0.35em 0.65em;
}

/* Smooth Transitions */
* {
    transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

a {
    text-decoration: none;
}

a:hover {
    text-decoration: none;
}

/* Sticky Elements (for cards that need to stick below navbar) */
.ent-sticky-card {
    position: sticky;
    top: 90px;
    z-index: 1020;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* Alert Improvements */
.alert {
    border-radius: 10px;
    border: none;
}

.alert-info {
    background-color: #e7f3ff;
    color: #004085;
}

.alert-success {
    background-color: #d4edda;
    color: #155724;
}

.alert-danger {
    background-color: #f8d7da;
    color: #721c24;
}

/* List Group Enhancements */
.list-group-item {
    border-radius: 8px !important;
    margin-bottom: 0.5rem;
}

/* Modal Enhancements */
.modal-content {
    border-radius: 12px;
    border: none;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

.modal-header {
    border-top-left-radius: 12px;
    border-top-right-radius: 12px;
}

/* Code Display */
code {
    background-color: #f8f9fa;
    padding: 2px 6px;
    border-radius: 4px;
    color: #e83e8c;
    font-size: 0.9em;
}

/* Transcript Chat Bubbles */
.ent-ai-message {
    background-color: var(--ent-ai-message-bg) !important;
    color: white !important;
}

.ent-caller-message {
    background-color: #f0e19c !important;
    color: #212529 !important;
}

/* Breadcrumb Styling */
.breadcrumb {
    background-color: transparent;
    padding: 0;
    margin-bottom: 0;
}

.breadcrumb-item + .breadcrumb-item::before {
    content: "›";
    color: #6c757d;
}

.breadcrumb-item a {
    color: var(--ent-primary);
    text-decoration: none;
}

.breadcrumb-item a:hover {
    text-decoration: underline;
}

.breadcrumb-item.active {
    color: #6c757d;
}

