/* 
   BLUESOAP PORTAL DESIGN SYSTEM (Muse Standard)
   Role: Visual Core for CEO Command Center.
   Theme: "Digital Cleanse" - Deep Navy, Vibrant Blue, Glassmorphism.
*/

@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;600;700;800&family=Open+Sans:wght@400;600&display=swap');

:root {
    /* Brand Palette */
    --bs-navy: #0F172A;
    --bs-blue: #006994;
    /* BlueSoap Primary */
    --bs-teal: #008080;
    --bs-light: #F8FAFC;
    --bs-glass: rgba(255, 255, 255, 0.95);

    /* Status Colors */
    --status-active: #10B981;
    /* Green */
    --status-idle: #F59E0B;
    /* Amber */
    --status-offline: #64748B;
    /* Slate */

    /* Dimensions */
    --sidebar-width: 280px;
    --header-height: 80px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Open Sans', sans-serif;
    background-color: #F1F5F9;
    /* Off-white background */
    color: #334155;
    height: 100vh;
    display: flex;
    overflow: hidden;
}

/* TYPOGRAPHY */
h1,
h2,
h3,
h4 {
    font-family: 'Montserrat', sans-serif;
}

.brand-logo {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--bs-blue);
    text-transform: uppercase;
    letter-spacing: 1px;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* SIDEBAR */
.sidebar {
    width: var(--sidebar-width);
    background: white;
    border-right: 1px solid #E2E8F0;
    padding: 30px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
    z-index: 100;
}

.nav-menu {
    margin-top: 60px;
    list-style: none;
}

.nav-item {
    margin-bottom: 10px;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px 20px;
    color: #64748B;
    text-decoration: none;
    border-radius: 12px;
    font-weight: 600;
    transition: all 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
    background: #E0F2FE;
    color: var(--bs-blue);
}

.nav-icon {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

/* MAIN CONTENT */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    position: relative;
}

/* HEADER */
.top-header {
    height: var(--header-height);
    padding: 0 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(241, 245, 249, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.page-title {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--bs-navy);
}

.ceo-profile {
    display: flex;
    align-items: center;
    gap: 15px;
}

.ceo-avatar {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: var(--bs-navy);
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: 700;
    font-size: 1.2rem;
}

/* DASHBOARD GRID */
.dashboard-grid {
    padding: 40px;
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    grid-template-rows: auto auto;
    gap: 30px;
    overflow-y: auto;
    height: 100%;
}

/* CARDS */
.card {
    background: white;
    border-radius: 20px;
    padding: 25px;
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.08);
    /* Soft Shadow */
    transition: transform 0.2s;
    border: 1px solid rgba(255, 255, 255, 0.5);
}

.card:hover {
    transform: translateY(-3px);
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.12);
}

.card-header {
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--bs-navy);
}

/* AGENT STATUS SECTION (Top Row) */
.agent-status-section {
    grid-column: span 12;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.agent-card {
    display: flex;
    align-items: center;
    gap: 20px;
}

.agent-avatar {
    width: 60px;
    height: 60px;
    border-radius: 16px;
    background: #E2E8F0;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.5rem;
    position: relative;
}

.agent-avatar::after {
    content: '';
    position: absolute;
    bottom: -2px;
    right: -2px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 3px solid white;
}

.status-active .agent-avatar::after {
    background-color: var(--status-active);
}

.status-idle .agent-avatar::after {
    background-color: var(--status-idle);
}

.status-offline .agent-avatar::after {
    background-color: var(--status-offline);
}

.agent-info h3 {
    font-size: 1rem;
    font-weight: 700;
}

.agent-info p {
    font-size: 0.8rem;
    color: #64748B;
    margin-top: 4px;
}

/* CHAT SECTION (Left Main) */
.chat-section {
    grid-column: span 8;
    height: 500px;
    display: flex;
    flex-direction: column;
}

.chat-messages {
    flex: 1;
    overflow-y: auto;
    padding-right: 15px;
    margin-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.message {
    margin-bottom: 20px;
    display: flex;
    gap: 15px;
}

.msg-content {
    background: #F8FAFC;
    padding: 15px;
    border-radius: 0 12px 12px 12px;
    max-width: 80%;
}

.msg-header {
    font-weight: 700;
    font-size: 0.8rem;
    margin-bottom: 5px;
    color: var(--bs-blue);
}

.msg-text {
    font-size: 0.9rem;
    line-height: 1.5;
}

.chat-input-area {
    display: flex;
    gap: 15px;
}

.chat-input {
    flex: 1;
    padding: 15px;
    border: 2px solid #E2E8F0;
    border-radius: 12px;
    font-family: inherit;
    outline: none;
    transition: border-color 0.2s;
}

.chat-input:focus {
    border-color: var(--bs-blue);
}

.send-btn {
    background: var(--bs-blue);
    color: white;
    border: none;
    padding: 0 25px;
    border-radius: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s;
}

.send-btn:hover {
    background: #004e6e;
    /* Darker Blue */
}

/* FILES SECTION (Right Main) */
.files-section {
    grid-column: span 4;
    height: 500px;
}

.file-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.file-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 10px;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.1s;
}

.file-item:hover {
    background: #F8FAFC;
}

.file-icon {
    width: 40px;
    height: 40px;
    background: #E0F2FE;
    border-radius: 8px;
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--bs-blue);
}

.file-info h4 {
    font-size: 0.9rem;
}

.file-info span {
    font-size: 0.75rem;
    color: #94A3B8;
}