/* 3dp-v2 app.css */

/* ── Color tokens ─────────────────────────────────────────── */

:root {
    --primary        : #4f46e5;
    --primary-hover  : #4338ca;
    --primary-light  : #eef2ff;
    --primary-text   : #4f46e5;

    --navbar-bg      : #ffffff;
    --navbar-border  : #e5e7eb;
    --navbar-height  : 58px;

    --body-bg        : #f8fafc;
    --card-bg        : #ffffff;
    --border-color   : #e5e7eb;

    --text-primary   : #111827;
    --text-secondary : #6b7280;
    --text-muted     : #9ca3af;

    --success        : #059669;
    --success-light  : #d1fae5;
    --danger         : #dc2626;
    --danger-light   : #fee2e2;
    --warning        : #d97706;
    --warning-light  : #fef3c7;
    --info           : #0891b2;
    --info-light     : #cffafe;
}

/* ── Base ─────────────────────────────────────────────────── */

body, .modal-content {
    font-family      : system-ui, -apple-system, "Segoe UI", sans-serif;
}

body {
    background-color : var(--body-bg);
    font-size        : 0.9rem;
    color            : var(--text-primary);
}

/* ── Top navbar ───────────────────────────────────────────── */

.app-navbar {
    position         : sticky;
    top              : 0;
    z-index          : 1000;
    background-color : var(--navbar-bg);
    border-bottom    : 1px solid var(--navbar-border);
    height           : var(--navbar-height);
}

.app-navbar-inner {
    display         : flex;
    align-items     : center;
    height          : 100%;
    padding         : 0 1.25rem;
    gap             : 1.5rem;
}

/* Brand */
.app-brand {
    display         : flex;
    align-items     : center;
    gap             : 0.5rem;
    text-decoration : none;
    flex-shrink     : 0;
}

.brand-square {
    display          : flex;
    align-items      : center;
    justify-content  : center;
    width            : 32px;
    height           : 32px;
    background-color : var(--primary);
    color            : #fff;
    font-weight      : 700;
    font-size        : 0.8rem;
    border-radius    : 6px;
    letter-spacing   : -0.5px;
}

.brand-name {
    font-weight : 700;
    font-size   : 1rem;
    color       : var(--text-primary);
    letter-spacing: -0.3px;
}

/* Primary nav links */
.app-nav {
    display    : flex;
    align-items: center;
    gap        : 0.25rem;
    list-style : none;
    margin     : 0;
    padding    : 0;
    flex       : 1;
}

.app-nav-link {
    display         : inline-flex;
    align-items     : center;
    gap             : 0.35rem;
    padding         : 0.375rem 0.75rem;
    border-radius   : 6px;
    font-size       : 0.875rem;
    font-weight     : 500;
    color           : var(--text-secondary);
    text-decoration : none;
    border          : none;
    background      : transparent;
    cursor          : pointer;
    white-space     : nowrap;
    transition      : background 0.15s, color 0.15s;
}

.app-nav-link:hover {
    background-color : #f3f4f6;
    color            : var(--text-primary);
}

.app-nav-link.active {
    background-color : var(--primary-light);
    color            : var(--primary-text);
    font-weight      : 600;
}



/* More dropdown */
.nav-more .dropdown-menu {
    min-width   : 200px;
    border      : 1px solid var(--border-color);
    border-radius: 8px;
    box-shadow  : 0 4px 16px rgba(0,0,0,0.08);
    padding     : 0.4rem;
    margin-top  : 0.35rem;
}

.nav-more .dropdown-item {
    border-radius: 5px;
    font-size    : 0.875rem;
    padding      : 0.45rem 0.75rem;
    color        : var(--text-primary);
}

.nav-more .dropdown-item:hover {
    background-color: var(--primary-light);
    color           : var(--primary-text);
}

.nav-more .dropdown-item.active {
    background-color: var(--primary-light);
    color           : var(--primary-text);
    font-weight     : 600;
}

.nav-more .dropdown-header {
    font-size      : 0.7rem;
    font-weight    : 700;
    text-transform : uppercase;
    letter-spacing : 0.06em;
    color          : var(--text-muted);
    padding        : 0.5rem 0.75rem 0.25rem;
}

.nav-more .dropdown-divider {
    margin: 0.35rem 0;
}

/* Navbar right section */
.navbar-right {
    display    : flex;
    align-items: center;
    gap        : 0.5rem;
    flex-shrink: 0;
    margin-left: auto;
}

/* Mobile hamburger - hidden on desktop */
.mobile-menu-btn {
    display         : none;
    align-items     : center;
    justify-content : center;
    width           : 36px;
    height          : 36px;
    background      : none;
    border          : 1px solid var(--border-color);
    border-radius   : 6px;
    font-size       : 1.2rem;
    color           : var(--text-secondary);
    cursor          : pointer;
    flex-shrink     : 0;
}

/* Mobile offcanvas nav */
.mobile-nav { display: flex; flex-direction: column; }

.mobile-nav-link {
    display        : flex;
    align-items    : center;
    gap            : 0.65rem;
    padding        : 0.65rem 1.25rem;
    font-size      : 0.9rem;
    color          : var(--text-secondary);
    text-decoration: none;
    transition     : background 0.12s, color 0.12s;
}
.mobile-nav-link:hover, .mobile-nav-link.active {
    background : var(--body-bg, #f9fafb);
    color      : var(--primary, #4f46e5);
}
.mobile-nav-link i { font-size: 1rem; width: 1.1rem; flex-shrink: 0; }

.mobile-nav-section {
    font-size    : 0.65rem;
    font-weight  : 700;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    color        : var(--text-muted);
    padding      : 1rem 1.25rem 0.35rem;
}

/* Search bar */
.nav-search {
    display         : flex;
    align-items     : center;
    background-color: #f3f4f6;
    border          : 1px solid transparent;
    border-radius   : 6px;
    padding         : 0.35rem 0.65rem;
    font-size       : 0.8rem;
    color           : var(--text-secondary);
    width           : 200px;
    gap             : 0.4rem;
    cursor          : pointer;
    transition      : border-color 0.15s;
}

.nav-search:focus-within {
    border-color    : var(--primary);
    background-color: #fff;
}

.nav-search input {
    background  : transparent;
    border      : none;
    outline     : none;
    font-size   : 0.8rem;
    color       : var(--text-primary);
    flex        : 1;
    min-width   : 0;
}

.nav-search input::placeholder {
    color: var(--text-muted);
}

.nav-search .search-kbd {
    font-size       : 0.65rem;
    color           : var(--text-muted);
    background-color: #e5e7eb;
    border-radius   : 3px;
    padding         : 1px 5px;
    font-family     : inherit;
    flex-shrink     : 0;
}

/* Search dropdown */
.nav-search { position: relative; }

.search-drop {
    position        : absolute;
    top             : calc(100% + 6px);
    left            : 50%;
    transform       : translateX(-50%);
    width           : 340px;
    background      : var(--surface-color, #fff);
    border          : 1px solid var(--border-color, #e2e8f0);
    border-radius   : 10px;
    box-shadow      : 0 8px 24px rgba(0,0,0,0.10);
    z-index         : 1060;
    overflow        : hidden;
    max-height      : 420px;
    overflow-y      : auto;
}

.search-drop-label {
    padding         : 0.5rem 0.875rem 0.25rem;
    font-size       : 0.68rem;
    font-weight     : 700;
    text-transform  : uppercase;
    letter-spacing  : 0.08em;
    color           : var(--text-muted, #94a3b8);
}

.search-drop-row {
    display         : flex;
    align-items     : center;
    transition      : background 0.1s;
}

.search-drop-row:hover,
.search-drop-row.is-active {
    background      : var(--bg-subtle, #f8fafc);
}

.search-drop-main {
    display         : flex;
    align-items     : center;
    gap             : 0.625rem;
    padding         : 0.55rem 0.5rem 0.55rem 0.875rem;
    text-decoration : none;
    color           : inherit;
    flex            : 1;
    min-width       : 0;
}

.search-drop-actions {
    display         : flex;
    align-items     : center;
    gap             : 0.125rem;
    padding-right   : 0.5rem;
    flex-shrink     : 0;
    opacity         : 0;
    transition      : opacity 0.15s;
}

.search-drop-row:hover .search-drop-actions,
.search-drop-row.is-active .search-drop-actions {
    opacity         : 1;
}

.search-drop-action {
    display         : flex;
    align-items     : center;
    gap             : 0.2rem;
    font-size       : 0.72rem;
    font-weight     : 600;
    padding         : 0.25rem 0.5rem;
    border-radius   : 5px;
    border          : 1px solid var(--border-color, #e2e8f0);
    background      : var(--surface-color, #fff);
    color           : var(--text-secondary, #475569);
    cursor          : pointer;
    text-decoration : none;
    white-space     : nowrap;
    line-height     : 1;
}

.search-drop-action:hover {
    background      : var(--primary, #4f46e5);
    border-color    : var(--primary, #4f46e5);
    color           : #fff;
}

.search-drop-avatar {
    width           : 30px;
    height          : 30px;
    border-radius   : 50%;
    background      : var(--primary, #4f46e5);
    color           : #fff;
    display         : flex;
    align-items     : center;
    justify-content : center;
    font-size       : 0.75rem;
    font-weight     : 700;
    flex-shrink     : 0;
}

.search-drop-avatar--prospect {
    background      : #0891b2;
}

.search-drop-info { flex: 1; min-width: 0; }

.search-drop-name {
    font-size       : 0.85rem;
    font-weight     : 600;
    color           : var(--text-primary, #0f172a);
    white-space     : nowrap;
    overflow        : hidden;
    text-overflow   : ellipsis;
}

.search-drop-sub {
    font-size       : 0.75rem;
    color           : var(--text-muted, #94a3b8);
    white-space     : nowrap;
    overflow        : hidden;
    text-overflow   : ellipsis;
    margin-top      : 1px;
}

.search-drop-empty {
    padding         : 1.25rem 0.875rem;
    font-size       : 0.85rem;
    color           : var(--text-muted, #94a3b8);
    text-align      : center;
}

/* Icon buttons (bell, etc.) */
.btn-icon {
    display         : flex;
    align-items     : center;
    justify-content : center;
    width           : 34px;
    height          : 34px;
    border-radius   : 6px;
    border          : none;
    background      : transparent;
    color           : var(--text-secondary);
    font-size       : 1.1rem;
    cursor          : pointer;
    position        : relative;
    transition      : background 0.15s;
}

.btn-icon:hover {
    background-color: #f3f4f6;
    color           : var(--text-primary);
}

.btn-icon .badge-dot {
    position        : absolute;
    top             : 5px;
    right           : 5px;
    width           : 8px;
    height          : 8px;
    background-color: #ef4444;
    border-radius   : 50%;
    border          : 2px solid #fff;
}

/* User avatar */
.user-avatar-btn {
    display         : flex;
    align-items     : center;
    gap             : 0.35rem;
    padding         : 0.2rem 0.35rem 0.2rem 0.2rem;
    border-radius   : 6px;
    border          : none;
    background      : transparent;
    cursor          : pointer;
    transition      : background 0.15s;
}

.user-avatar-btn:hover {
    background-color: #f3f4f6;
}

.user-avatar {
    width            : 30px;
    height           : 30px;
    border-radius    : 50%;
    background-color : var(--primary);
    color            : #fff;
    font-size        : 0.7rem;
    font-weight      : 700;
    display          : flex;
    align-items      : center;
    justify-content  : center;
    flex-shrink      : 0;
}

.user-avatar-btn .bi-chevron-down {
    font-size : 0.65rem;
    color     : var(--text-muted);
}

/* ── Page wrapper ─────────────────────────────────────────── */

.page-wrapper {
    padding : 1.75rem 1.5rem;
    max-width: 1400px;
    margin  : 0 auto;
    width   : 100%;
}

/* ── Page header ──────────────────────────────────────────── */

.page-header {
    display         : flex;
    align-items     : flex-start;
    justify-content : space-between;
    margin-bottom   : 1.5rem;
}

.page-title {
    font-size   : 1.6rem;
    font-weight : 700;
    color       : var(--text-primary);
    margin      : 0 0 0.25rem;
    letter-spacing: -0.5px;
}

.page-subtitle {
    font-size : 0.875rem;
    color     : var(--text-secondary);
    margin    : 0;
}

.page-date {
    font-size  : 0.875rem;
    color      : var(--text-secondary);
    white-space: nowrap;
    padding-top: 0.25rem;
}

/* ── KPI cards ────────────────────────────────────────────── */

.kpi-card {
    background-color : var(--card-bg);
    border           : 1px solid var(--border-color);
    border-radius    : 10px;
    padding          : 1.1rem 1.25rem;
    position         : relative;
}

.kpi-top {
    display         : flex;
    align-items     : flex-start;
    justify-content : space-between;
    margin-bottom   : 0.75rem;
}

.kpi-icon {
    width           : 36px;
    height          : 36px;
    border-radius   : 8px;
    display         : flex;
    align-items     : center;
    justify-content : center;
    font-size       : 1rem;
}

.kpi-icon--purple { background-color: #ede9fe; color: #7c3aed; }
.kpi-icon--green  { background-color: #d1fae5; color: #059669; }
.kpi-icon--amber  { background-color: #fef3c7; color: #d97706; }
.kpi-icon--rose   { background-color: #fce7f3; color: #db2777; }

.kpi-delta {
    font-size   : 0.75rem;
    font-weight : 600;
}

.kpi-delta--up   { color: #059669; }
.kpi-delta--down { color: #dc2626; }
.kpi-delta--warn { color: #d97706; }

.kpi-label {
    font-size   : 0.8rem;
    color       : var(--text-secondary);
    margin-bottom: 0.2rem;
}

.kpi-value {
    font-size    : 1.65rem;
    font-weight  : 700;
    color        : var(--text-primary);
    line-height  : 1.1;
    letter-spacing: -0.5px;
    margin-bottom: 0.2rem;
}

.kpi-context {
    font-size : 0.75rem;
    color     : var(--text-muted);
}

/* ── Panel cards ──────────────────────────────────────────── */

.panel {
    background-color : var(--card-bg);
    border           : 1px solid var(--border-color);
    border-radius    : 10px;
    overflow         : hidden;
}

.panel-header {
    display         : flex;
    align-items     : center;
    justify-content : space-between;
    padding         : 1rem 1.25rem;
    border-bottom   : 1px solid var(--border-color);
}

.panel-title {
    font-size   : 0.95rem;
    font-weight : 600;
    color       : var(--text-primary);
    margin      : 0;
}

.panel-subtitle {
    font-size : 0.8rem;
    color     : var(--text-muted);
    margin    : 0;
}

.panel-link {
    font-size   : 0.8rem;
    font-weight : 500;
    color       : var(--primary);
    text-decoration: none;
}

.panel-link:hover {
    color: var(--primary-hover);
}

/* ── Page header ─────────────────────────────────────────────
   Standard top-of-page title row used on every section index.
   Usage: <div class="page-header"> + <h1 class="page-title"> + <p class="page-subtitle">
   ────────────────────────────────────────────────────────── */

.page-title {
    font-size   : 1.4rem;
    font-weight : 700;
    color       : var(--text-primary);
    margin      : 0 0 0.2rem;
}

.page-subtitle {
    font-size : 0.85rem;
    color     : var(--text-muted);
    margin    : 0;
}

/* ── Empty state ─────────────────────────────────────────────
   Centered placeholder shown when a list or panel has no data.
   Usage:
     <div class="empty-state">
       <i class="bi bi-inbox empty-state-icon"></i>
       <p class="empty-state-text">No items yet.</p>
       <a class="btn btn-primary btn-sm">Add one</a>
     </div>
   ────────────────────────────────────────────────────────── */

.empty-state {
    padding    : 3rem;
    text-align : center;
}

.empty-state-icon {
    font-size     : 2rem;
    color         : var(--text-muted);
    display       : block;
    margin-bottom : 0.75rem;
}

.empty-state-text {
    font-size     : 0.875rem;
    color         : var(--text-muted);
    margin-bottom : 1rem;
}

/* ── Section label ───────────────────────────────────────────
   Small uppercase label used above groups of fields or rows.
   Usage: <div class="section-label">Label Text</div>
   ────────────────────────────────────────────────────────── */

.section-label {
    font-size      : 0.75rem;
    font-weight    : 600;
    text-transform : uppercase;
    letter-spacing : 0.05em;
    color          : var(--text-muted);
    margin-bottom  : 0.5rem;
}

/* ── Form label (small) ──────────────────────────────────────
   Compact label above form fields inside panels and modals.
   Usage: <label class="form-label-sm">Field Name</label>
   ────────────────────────────────────────────────────────── */

.form-label-sm {
    font-size     : 0.8rem;
    font-weight   : 500;
    color         : var(--text-secondary);
    display       : block;
    margin-bottom : 0.3rem;
}

/* ── Table header cell ───────────────────────────────────────
   Standard <th> style used in all data tables.
   Usage: <th class="table-th">Column</th>
   ────────────────────────────────────────────────────────── */

.table-th {
    padding        : 0.6rem 1rem;
    font-size      : 0.72rem;
    font-weight    : 600;
    text-transform : uppercase;
    letter-spacing : 0.05em;
    color          : var(--text-muted);
    text-align     : left;
    border-bottom  : 1px solid var(--border-color);
    background     : var(--bg-subtle, #f8f9fa);
}

/* ── Table data cell ─────────────────────────────────────────
   Standard <td> padding for all data tables.
   Usage: <td class="table-td">Value</td>
   ────────────────────────────────────────────────────────── */

.table-td {
    padding     : 0.75rem 1rem;
    font-size   : 0.875rem;
    color       : var(--text-primary);
    border-bottom: 1px solid var(--border-color);
    vertical-align: middle;
}

/* ── Text utilities ──────────────────────────────────────────
   Semantic colour classes for common states.
   ────────────────────────────────────────────────────────── */

.text-error   { color: #dc2626; }
.text-success { color: #059669; }
.text-warn    { color: #d97706; }
.text-info    { color: #0891b2; }

/* ── Flex helpers ────────────────────────────────────────────
   Shortcuts for the most common flex combinations.
   ────────────────────────────────────────────────────────── */

.flex-between {
    display         : flex;
    align-items     : center;
    justify-content : space-between;
    gap             : 0.75rem;
    flex-wrap       : wrap;
}

.flex-center {
    display     : flex;
    align-items : center;
    gap         : 0.5rem;
}

/* ── Task list ────────────────────────────────────────────── */

.task-list {
    list-style : none;
    margin     : 0;
    padding    : 0;
}

.task-item {
    display     : flex;
    align-items : center;
    gap         : 0.65rem;
    padding     : 0.7rem 1.25rem;
    border-bottom: 1px solid #f3f4f6;
}

.task-item:last-child {
    border-bottom: none;
}

.task-item input[type="checkbox"] {
    flex-shrink: 0;
    width      : 16px;
    height     : 16px;
    accent-color: var(--primary);
    cursor     : pointer;
}

.task-icon {
    width           : 28px;
    height          : 28px;
    border-radius   : 6px;
    display         : flex;
    align-items     : center;
    justify-content : center;
    font-size       : 0.8rem;
    flex-shrink     : 0;
}

.task-icon--blue   { background-color: #eff6ff; color: #3b82f6; }
.task-icon--green  { background-color: #f0fdf4; color: #22c55e; }
.task-icon--purple { background-color: #faf5ff; color: #a855f7; }
.task-icon--orange { background-color: #fff7ed; color: #f97316; }
.task-icon--pink   { background-color: #fdf2f8; color: #ec4899; }

.task-body {
    flex    : 1;
    min-width: 0;
}

.task-name {
    font-size   : 0.85rem;
    font-weight : 500;
    color       : var(--text-primary);
    display     : flex;
    align-items : center;
    gap         : 0.4rem;
    flex-wrap   : wrap;
}

.task-person {
    font-size : 0.78rem;
    color     : var(--text-muted);
}

.task-time {
    font-size  : 0.78rem;
    color      : var(--text-muted);
    white-space: nowrap;
    flex-shrink: 0;
}

.badge-urgent {
    font-size       : 0.65rem;
    font-weight     : 600;
    color           : #dc2626;
    background-color: #fee2e2;
    padding         : 1px 6px;
    border-radius   : 4px;
}

/* ── Schedule list ────────────────────────────────────────── */

.schedule-list {
    list-style: none;
    margin    : 0;
    padding   : 0;
}

.schedule-item {
    display     : flex;
    align-items : center;
    gap         : 0.75rem;
    padding     : 0.7rem 1.25rem;
    border-bottom: 1px solid #f3f4f6;
}

.schedule-item:last-child {
    border-bottom: none;
}

.schedule-item.is-now {
    background-color: var(--primary-light);
    border-left     : 3px solid var(--primary);
}

.schedule-item.is-now .schedule-time {
    color: var(--primary);
}

.schedule-time {
    font-size   : 0.8rem;
    font-weight : 600;
    color       : var(--text-secondary);
    width       : 52px;
    flex-shrink : 0;
}

.schedule-icon {
    width           : 28px;
    height          : 28px;
    border-radius   : 6px;
    display         : flex;
    align-items     : center;
    justify-content : center;
    font-size       : 0.8rem;
    flex-shrink     : 0;
    background-color: #f3f4f6;
    color           : var(--text-secondary);
}

.schedule-body {
    flex    : 1;
    min-width: 0;
}

.schedule-title {
    font-size   : 0.85rem;
    font-weight : 500;
    color       : var(--text-primary);
}

.schedule-duration {
    font-size : 0.75rem;
    color     : var(--text-muted);
}

.badge-now {
    font-size       : 0.65rem;
    font-weight     : 700;
    color           : #fff;
    background-color: var(--primary);
    padding         : 2px 7px;
    border-radius   : 4px;
    flex-shrink     : 0;
}

/* ── Pipeline table ───────────────────────────────────────── */

.pipeline-table {
    width           : 100%;
    border-collapse : collapse;
}

.pipeline-table th {
    font-size      : 0.7rem;
    font-weight    : 700;
    text-transform : uppercase;
    letter-spacing : 0.05em;
    color          : var(--text-muted);
    padding        : 0.65rem 1rem;
    border-bottom  : 1px solid var(--border-color);
    text-align     : left;
    background-color: #fafafa;
}

.pipeline-table td {
    padding      : 0.75rem 1rem;
    border-bottom: 1px solid #f3f4f6;
    vertical-align: middle;
}

.pipeline-table tr:last-child td {
    border-bottom: none;
}

.pipeline-table tr:hover td {
    background-color: #fafafa;
}

/* Agent cell */
.agent-cell {
    display    : flex;
    align-items: center;
    gap        : 0.6rem;
}

.agent-avatar {
    width            : 32px;
    height           : 32px;
    border-radius    : 50%;
    display          : flex;
    align-items      : center;
    justify-content  : center;
    font-size        : 0.7rem;
    font-weight      : 700;
    color            : #fff;
    flex-shrink      : 0;
}

.agent-avatar--indigo  { background-color: #6366f1; }
.agent-avatar--emerald { background-color: #10b981; }
.agent-avatar--violet  { background-color: #8b5cf6; }
.agent-avatar--sky     { background-color: #0ea5e9; }
.agent-avatar--rose    { background-color: #f43f5e; }

.agent-name {
    font-size  : 0.875rem;
    font-weight: 500;
    color      : var(--text-primary);
}

/* Stage pills */
.stage-pill {
    display         : inline-flex;
    align-items     : center;
    padding         : 2px 10px;
    border-radius   : 20px;
    font-size       : 0.75rem;
    font-weight     : 500;
}

.stage-pill--interview { background-color: #ede9fe; color: #6d28d9; }
.stage-pill--training  { background-color: #d1fae5; color: #065f46; }
.stage-pill--at-risk   { background-color: #fee2e2; color: #991b1b; }
.stage-pill--active    { background-color: #dcfce7; color: #166534; }
.stage-pill--offer     { background-color: #fef3c7; color: #92400e; }

/* Score bar */
.score-bar-wrap {
    display    : flex;
    align-items: center;
    gap        : 0.6rem;
}

.score-bar {
    flex         : 1;
    height       : 6px;
    border-radius: 3px;
    background   : #e5e7eb;
    overflow     : hidden;
    min-width    : 80px;
    max-width    : 120px;
}

.score-bar-fill {
    height       : 100%;
    border-radius: 3px;
    background   : var(--primary);
}

.score-bar-fill--danger {
    background: #ef4444;
}

.score-num {
    font-size  : 0.825rem;
    font-weight: 600;
    color      : var(--text-primary);
    min-width  : 22px;
}

/* Value cell */
.value-cell {
    font-size  : 0.875rem;
    font-weight: 600;
    color      : var(--text-primary);
}

/* Row actions */
.row-actions {
    color      : var(--text-muted);
    cursor     : pointer;
    font-size  : 1.1rem;
    background : none;
    border     : none;
    padding    : 0 0.25rem;
}

.row-actions:hover {
    color: var(--text-primary);
}

/* Role text */
.role-text {
    font-size : 0.825rem;
    color     : var(--text-secondary);
}

/* ── Login layout ─────────────────────────────────────────── */

.login-body {
    background-color : var(--body-bg);
    min-height       : 100vh;
    display          : flex;
    align-items      : center;
    justify-content  : center;
}

.login-wrapper {
    width     : 100%;
    max-width : 420px;
    padding   : 1rem;
}

/* ── Mobile nav ───────────────────────────────────────────── */

@media (max-width: 767px) {

    /* ── Navbar ── */
    .app-navbar-inner {
        padding: 0 1rem;
        gap    : 0.5rem;
    }
    .app-nav    { display: none; }
    .brand-name { display: none; }
    .mobile-menu-btn { display: flex; }
    .nav-search { width: 120px; }
    .search-kbd { display: none; }

    /* ── Page wrapper ── */
    .page-wrapper { padding: 1rem 0.85rem; }
    .page-date    { display: none; }

    /* ── Page header ── */
    .page-title-row {
        flex-wrap : wrap;
        gap       : 0.5rem;
    }
    .page-title-row .btn-toolbar,
    .page-title-row .d-flex {
        flex-wrap: wrap;
        gap: 0.4rem;
    }

    /* ── Panels & cards ── */
    .panel { border-radius: 8px; }

    /* ── Tables - horizontal scroll ── */
    .table-responsive-mobile {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    .panel > table,
    .panel > .table-wrap > table {
        min-width: 600px;
    }

    /* ── Tabs (campaigns, agent detail, etc.) ── */
    .nav-tabs .nav-link {
        font-size : 0.78rem;
        padding   : 0.4rem 0.6rem;
    }

    /* ── Form layout ── */
    .row.g-3 > [class*="col-md-"] { flex: 0 0 100%; max-width: 100%; }

    /* ── Developer docs sidebar ── */
    .dev-wrap    { flex-direction: column; margin: -1rem -0.85rem; }
    .dev-sidebar {
        position    : static;
        width       : 100%;
        max-height  : none;
        border-right: none;
        border-bottom: 1px solid var(--border-color);
        padding     : 0.75rem 0;
        display     : none; /* collapsed by default on mobile */
    }
    .dev-content { padding: 1.25rem 1rem; max-width: 100%; }

    /* ── Softphone modal ── */
    .modal-dialog { margin: 0.5rem auto; }

    /* ── Sloane chat ── */
    .sloane-panel { width: 100% !important; right: 0 !important; border-radius: 0 !important; }

    /* ── KPI cards grid ── */
    .kpi-grid { grid-template-columns: repeat(2, 1fr) !important; }

    /* ── Agent/prospect cards in lists ── */
    .prospect-card-actions,
    .agent-card-actions {
        flex-wrap: wrap;
        gap: 0.3rem;
    }

    /* ── Notification dropdown ── */
    .notif-dropdown {
        width     : calc(100vw - 1rem) !important;
        max-width : 360px;
    }
}

/* ── Merge token chips ───────────────────────────────────────
   Clickable pill buttons for inserting template tokens into
   email/SMS compose fields. Used on template form, campaigns,
   and the office message blast modal.
   ────────────────────────────────────────────────────────── */

.suggest-label {
    font-size      : 0.75rem;
    color          : var(--text-muted);
    margin-bottom  : 0.25rem;
    display        : block;
}

.suggest-chip {
    display        : inline-block;
    font-size      : 0.78rem;
    line-height    : 1.4;
    background     : var(--body-bg, #f9fafb);
    border         : 1px solid var(--border-color);
    border-radius  : 4px;
    padding        : 0.2rem 0.55rem;
    cursor         : pointer;
    color          : var(--text-secondary);
    transition     : background 0.1s, border-color 0.1s, color 0.1s;
    font-family    : inherit;
    margin-bottom  : 0.2rem;
}

.suggest-chip:hover {
    background    : var(--primary-light, #ede9fe);
    border-color  : var(--primary, #4f46e5);
    color         : var(--primary, #4f46e5);
}

/* ── Attachment chips ────────────────────────────────────────
   Pill showing an attached file with a remove button.
   ────────────────────────────────────────────────────────── */

.attach-chip {
    display     : inline-flex;
    align-items : center;
    gap         : 0.3rem;
    font-size   : 0.75rem;
    padding     : 0.15rem 0.5rem;
    background  : var(--body-bg);
    border      : 1px solid var(--border-color);
    border-radius : 12px;
    color       : var(--text-secondary);
}

.attach-chip a { color: inherit; text-decoration: underline; }

.attach-chip button {
    background  : none;
    border      : none;
    padding     : 0;
    cursor      : pointer;
    color       : var(--text-muted);
    line-height : 1;
    font-size   : 0.8rem;
}

.attach-chip button:hover { color: var(--danger, #dc3545); }
